Skip to content

Java class to calculate magnetic declination, magnetic field strength, inclination etc. for any point on the earth

License

Notifications You must be signed in to change notification settings

kanchudeep/Geomagnetism-Java

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Geomagnetism

Java class to calculate magnetic declination, magnetic field strength, inclination etc. for any point on the earth.

Usage:

// Create instance with only location and without altitude & date
Geomagnetism gm = new Geomagnetism(123.45678, 76.54321);
System.out.printf("Declination: %f\n", gm.getDeclination());

// Create a calendar for calculation
GregorianCalendar calendar = new GregorianCalendar();
calendar.set(2017, 6, 1); // 2017 July 01
// Update instance with altitude and date apart from location
gm.calculate(98.76543, 12.34567, 1234, calendar);
System.out.printf("Declination: %f\n", gm.getDeclination());

About

Java class to calculate magnetic declination, magnetic field strength, inclination etc. for any point on the earth

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages