A topology optimization formulation is developed to find the stiff est structure with desirable material distribution subjected to seismic loads. Finite element models of the structures are generated and the optimality criteria method is modified using a simple penalty approach and introducing fictitious strain energy to simultaneously consider both material volume and displacement constraints. Different types of shear walls with/without opening are investigated. Additionally, the effects of shear wall-frame interaction for single and coupled shear walls are studied. Gravity and seismic loads are applied to the shear walls so that the definitions provide a practical approach for locating the critical parts of these structures. The results suggest new viewpoints for architectural and structural engineering for placement of openings