Answer in brief
How is the magnitude of the earthquake related to the collapse of houses.
An earthquake occurs when the tension in the normal movements within the earth’s crust increases leading to formation of massive waves creating trembling on the earth’s surface. Movements below the earth’s surface creates tension which keeps on accumulating. High energy is released at the place where the tension mounts up creating the center of the earthquake or the focus. The point on the Earth's surface directly above the focus is called the epicenter of the earthquake. The severity of an earthquake can be expressed in terms of both intensity and magnitude. Intensity is based on the observed effects of ground shaking on people, buildings, and natural features. Magnitude is related to the amount of seismic energy released at the hypocenter of the earthquake. The magnitude of an earthquake is thus represented by a single, instrumentally determined value. This value for the magnitude of an earthquake is measured with the help of seismographs which give the value according to the Richter Scale.
Earthquakes with magnitude of about 2.0 or less are usually called microearthquakes; they are not commonly felt by people and are generally recorded only on local seismographs. Events with magnitudes of about 4.5 or greater--there are several thousand such shocks annually--are strong enough to be recorded by sensitive seismographs all over the world. Great earthquakes, such as the 1964 Good Friday earthquake in Alaska, have magnitudes of 8.0 or higher. On the average, one earthquake of such size occurs somewhere in the world each year. Although the Richter Scale has no upper limit, the largest known shocks have had magnitudes in the 8.8 to 8.9 range.
Thus, higher the Richter scale reading on a seismograph, the earthquake has more magnitude making it more devastating. Earthquakes with low magnitude would not cause houses to collapse. But those of high magnitude can cause houses to collapse.