Local Magnitude Calculation

Hi,

I am trying to understand the calculation of the local magnitude. I have found
ML = log(A)-log(A0) and -log(A0)= 3log(d)-2.92. I want to verify the magnitude by using my shake data. There was a recent 1.6 at 12 km away from my station. It looks like the P and S flags are about 4 seconds apart. It looks like the velocity maximum is about 6 um/s and the spectrogram shows a bright spot somewhere between 4 Hz and 20 Hz. I put this information into Gemini and it told me this was a -4.0 magnitude. How do I do this correctly? I want to find a sample calculation that I can show my student who is working on an honors thesis in physics. Thanks. Rob, R2113

Hello Rob,

Happy to help! Let’s take a look at this.

I looked up the event (I think it’s this one in NJ, USGS ml 1.6, 2026-10-22 09:38:26 UTC, 10 km deep) and your station’s trace, and while I’m not sure what Gemini did, I can offer you the following alternative:

  1. The first important element is that ML uses peak ground displacement, in nm, on a Wood-Anderson-equivalent record, not velocity. The trace you see on DataView, for example, is already corrected to m/s, so you need to convert it.

    You can do it via ObsPy (or similar software) or use this approximate formula: d ≈ v/(2πf), where d is displacement, v is velocity, and f is frequency. With about 7 µm/s at ~15 Hz (taken from your spectrogram data), that’s about 74 nm of displacement.

  2. On to the formula, the 3 log d − 2.92 version is simplified for long-distance events, and it can give misleading values for short-range earthquakes. You can use the Hutton & Boore (1987) formula: ML = log A + 1.11 log r + 0.00189 r − 2.09, where r is the hypocentral distance in km and A is the displacement in nm.

  3. Since we need to use the hypocentral distance, we’ll take your 12 km linear value and then combine it with the 10 km depth. The result is a distance of about 15.6 km.

    This value gives an S-P of about 2 seconds vs your 4, so some discrepancies will affect the approximate magnitude calculation, which can be normal for very close events.

  4. As a result, with r ≈ 16 km I get ML ≈ 1.1, versus the catalog 1.6. If we use a different frequency (for example, 10 Hz), this value becomes ≈ 1.3 with a different displacement of 111 nm.

  5. There are some caveats, as this is a vertical-only channel and the signal is only ~3× the noise. ML is defined on horizontals, so quote an uncertainty, e.g. from the noise level just before the event.

For your student (and best of luck for his Honors Thesis!), it could be interesting to calculate how the numbers change with different reference frequencies, or with uncertainties in the depth/distance and thus how much ML moves on the scale.

It could also be interesting to apply the same calculations to several nearby events; the more, the better, to see the offset between your student’s numbers and the official catalog ones.

Since there are other stations nearby, you could also integrate their data, if usable, to see how the ML changes with those.

Hope the above has helped. If you have other questions, you know where to find us.

Hi Storm Chaser,

This was extremely helpful. That was the event. Thank you.
My next task is I want to do one on a global scale like the 7.7 in Panama on Oct 9 or the 7.7
in Indonesia on 8/14. I think that would make an interesting comparison. I picked up both of these events with my simple 1D raspberry shake.

Gemini also told me that a report of a magnitude is actually an average of stations around the event and so stations closer to the event are going to be more accurate than stations further away.

Can you please tell me, how do I access the RAW data off of my device?

You’re more than welcome rmurawsk.

Yes, large events like those two are easily detected worldwide. And also yes, that is correct. That is why network densification is important, because it helps in acquiring more accurate data on seismic events.

There are multiple ways to download raw data, either directly from the device or via what the Shake has uploaded to our servers. You can find a summary of all available avenues here.

If you have access to the unit, direct download is probably the faster option.