Identification of material properties and optimal design of magnetically shielded rooms