Skip to content

Minimalistic C++ library for converting astronomical coordinates

License

Notifications You must be signed in to change notification settings

johngull/astrocoords

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 

Repository files navigation

astrocoords

Minimalistic C++ library for converting astronomical coordinates. Its aim is to be compact to be usable in embedded systems.

Warning: It is library user's responsibility to check input data correctness.

Example of usage:

astrocoords::Converter cconv;

//beta-orion in Cherkasy, UA at 22:00UTC, 17th February 2018
cconv.setLocation(astrocoords::Angle::fromDegrees(49, 26, 40),
                  astrocoords::Angle::fromDegrees(32, 03, 35)
                  );
cconv.setDateAndUTCTime(2018, 2, 17, 22, 0, 0);
//beta-orion
astrocoords::Angle alt, az;
cconv.equatorialToHorizontal(astrocoords::Angle::fromHours(5, 14, 32.27210),
                             astrocoords::Angle::fromDegrees(-8, 12, 5.8981),
                             alt, az);

//use alt.d() and az.d() to get altitude and azimuth in degrees

About

Minimalistic C++ library for converting astronomical coordinates

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages