Monday, May 2, 2022

HP 32S and HP 32SII Week: Richter Scale

HP 32S and HP 32SII Week:  Richter Scale





Richter Scale


The equation calculates the massive energy given by a earthquake given the earthquake's magnitude by the Richter scale:


E = 10^(11.3 + 1.8 * M), where E is in ergs

 

with conversions:


Ergs to Joules:  multiply by 1 * 10^-7


Ergs to ft-lbs:  multiply by 7.3756 * 10^-8




Equation Modifications



Energy of an earthquake, given by Richter scale, in Joules (SI units):


E = 10^(4.3 + 1.8 * M)




Energy of an earthquake, given by Richter scale, in Foot-Pounds (US units):


E ≈ 10^(4.1678 + 1.8 * M)




HP 32S/32SII Program:  Earthquake Energy - SI Units

Size: 13.5 bytes


R01 LBL R

R02 18

R03 ×

R04 43

R05 +

R06 10

R07 ÷

R08 10^x

R09 STOP


Example:  3.4 Magnitude


Result:  26,302,679,919 J


Notes:


*  In general, each step takes 1.5 bytes.  


*  Integers 0 to 99 (HP 32S) and 0 to 254 (HP 32SII) takes 1.5 bytes while all other real numbers takes 9.5 bytes.  It could be advantageous to build numbers out of small integers than enter real number constants.  Using a real constant uses 6 steps.  


* It's supposed to be advantageous to end programs with STOP (R/S) than RTN. 



HP 32S/32SII Program:  Earthquake Energy - US Units

Size: 21.5 bytes


R01 LBL R

R02 18

R03 ×

R04 10

R05 ÷

R06 4.1678

R07 +

R08 10^x

R09 STOP


Example:  3.4 Magnitude


Result:  19,399,922,723.9 ft-lbs



Source:


Young, G.B.  "Earthquake Magnitude - Energy Conversation"  Hewlett-Packard HP-674/HP-97 User's Library Solutions:  Earth Sciences  Hewlett Packard:  Corvallis, OR.  pp. 1-4 February 1978


Download the document here, with gratitude to hpcalc.org:

https://literature.hpcalc.org/items/1015


Eddie


All original content copyright, © 2011-2022.  Edward Shore.   Unauthorized use and/or unauthorized distribution for commercial purposes without express and written permission from the author is strictly prohibited.  This blog entry may be distributed for noncommercial purposes, provided that full credit is given to the author.