Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Latest model Wmm2015 does not show exact results for same input into Online Calculator #38

Open
JOnewbie opened this issue Jul 23, 2019 · 0 comments

Comments

@JOnewbie
Copy link

Hi,
I am using version 0.14.1, and doing the following calls to get the Magnetic Field result:

DateTime dt = new DateTime(2019, 7, 19);
var a = new WmmGeomagnetismCalculator();
var b = a.TryCalculate(new Coordinate(32.9, -96.1), dt);

then I enter the same latitude, longitude , and date into the online calculator at https://www.ngdc.noaa.gov/geomag/calculators/magcalc.shtml#igrfwmm
but the values I get differ, for example:

Geo Code: Online Calculator:
D=2.68693443863361 D=2.733333
X=23172.5881478553 X=23207.2
Z=42798.7003809326 Z=42767.2

I tried to compare the Geo code with the C code used by the online calculator, and as far as I get, the values for a,b,f are identical on both; in C code they are hard-coded, in your code they are calculated as:
var a = _spheroid.EquatorialAxis / 1000;
var f = _spheroid.Flattening;
var b = a * (1.0 - f);

I need to understand why I cannot get the same values for X, Z since they are used for D. Can you help me understand why this is the case?

I am working on an application in c# that requires the values for D,X,Z to be identical to the online calculator.

Thanks,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant