Earthquake: Earthquake Calculations
07-09-2019, 02:43 PM (This post was last modified: 07-09-2019 02:58 PM by StephenG1CMZ.)
Post: #4
 StephenG1CMZ Senior Member Posts: 1,032 Joined: May 2015
RE: Earthquake: Earthquake Calculations
Thanks Gamo.
It's good to see that my results match that example.

If you wanted to solve such a problem with this program - rather than directly using the HP solve on the relevant equation, here is how I checked those results.:

Code:

EXPORT EX1906()
BEGIN
LOCAL KNOWN:=8.25;
LOCAL GREATER:=105;
LOCAL SMALLER:=1/GREATER;
LOCAL CANDIDATES;
PRINT();
//
PRINT("SMALLER "+SMALLER);
//CHOOSE POSSIBLE
CANDIDATES:={KNOWN,6.22,6.23};
//LIST VALUES
PRINT(CANDIDATES);
PRINT(Amplitudes(CANDIDATES,1));
//VISUALLY CHOOSE NUMBER IN LIST
//CLOSE TO SMALLER AND VERIFY THAT IS
//GREATER
PRINT(Amplitudes(CANDIDATES,3));
//RESELECT CANDIDATES AS NECESSARY

//SIMILARLY
//PRINT(Energies({KNOWN,6.9},1));
//PRINT(Energies({KNOWN,6.9},2));

END;

Actually that uses functions from my next version, which extend the comparison of two magnitudes to a list of values.

Stephen Lewkowicz (G1CMZ)
https://my.numworks.com/python/steveg1cmz
 « Next Oldest | Next Newest »

 Messages In This Thread Earthquake: Earthquake Calculations - StephenG1CMZ - 07-07-2019, 11:14 PM RE: Quake: Earthquake Calculations - StephenG1CMZ - 07-07-2019, 11:16 PM RE: Earthquake: Earthquake Calculations - Gamo - 07-08-2019, 01:01 PM RE: Earthquake: Earthquake Calculations - StephenG1CMZ - 07-09-2019 02:43 PM RE: Earthquake: Earthquake Calculations - StephenG1CMZ - 07-09-2019, 03:34 PM RE: Earthquake: Earthquake Calculations - StephenG1CMZ - 07-15-2019, 10:54 AM

User(s) browsing this thread: 1 Guest(s)