SuperNOVAS C++ API v1.6
High-precision C/C++ astrometry library
Loading...
Searching...
No Matches
supernovas::Equinox Class Reference

Equatorial coordinate system, defining the orientation of the equator and the location of the equinox, relative to which the right ascention and declination (RA/Dec) coordinates are defined. More...

#include <supernovas.h>

Inheritance diagram for supernovas::Equinox:

Public Member Functions

double epoch () const
 Returns the years of the Julian epoch that matches this system.
bool equals (const Equinox &system, const Interval &dt) const
 Checks if this equatorial system equals the equatorial system as the right-hand side, with the epochs also matching within the specified precision.
bool equals (const Equinox &system, double dt=Unit::s) const
 Checks if this equatorial system equals the equatorial system as the right-hand side, with the epochs also matching within the specified precision.
enum novas_equator_type equator_type () const
 Returns the type of equator used in this equatorial coordinate system.
bool is_icrs () const
 Checks if this equatorial system is the International Celestial Reference System (ICRS).
bool is_mod () const
 Checks if this equatorial system is a Mean-of-Date (MOD) system.
bool is_true () const
 Checks if this equatorial system is based on the true dynamical equator of date.
double jd () const
 Returns the (TT-based) Julian date that corresponds to this system instance.
double mjd () const
 Returns the (TT-based) Modified Julian Date (MJD) that corresponds to this system instance.
const std::string & name () const
 Returns a reference to the name of this system.
bool operator!= (const Equinox &system) const
 Checks if this equatorial system differs from the equatorial system as the right-hand side.
bool operator== (const Equinox &system) const
 Checks if this equatorial system equals the equatorial system as the right-hand side, with the epochs also matching to within 1 second.
enum novas_reference_system system_type () const
 Returns the coordinate reference system type for this equatorial system.
std::string to_string () const
 Provides a string representation of this system.
Public Member Functions inherited from supernovas::Validating
bool is_valid () const
 Returns the previously set 'valid' stae of the implementing instance.
 operator bool () const
 Objects that implement Validating can be used in conditionals directly, without explicitly calling is_valid().

Static Public Member Functions

static const Equinox & b1900 ()
 The system of the dynamical equator at the B1900 epoch (0 UTC, 1 January 1900).
static const Equinox & b1950 ()
 The system of the dynamical equator at the B1950 epoch (0 UTC, 1 January 1950).
static Equinox cirs (const Time &time)
 Returns a Celestial Intermediate Reference System (CIRS) equatorial system for the given (TT-based) Julian date.
static Equinox cirs (double jd_tt)
 Returns a Celestial Intermediate Reference System (CIRS) equatorial system for the given (TT-based) Julian date.
static Equinox from_string (const std::string &name)
 Returns a new equinox instance from a string, such as 'ICRS', 'J2000', 'FK5', B1950', or 'HIP'; or else {}.
static Equinox from_system_type (enum novas_reference_system system, double jd_tt=NOVAS_JD_J2000)
 Returns a new equinox instance given a coordinate reference system type and a date.
static const Equinox & hip ()
 The system of the mean dynamical equator at the J1991.25 epoch, which is adopted as the nominal mean epoch of the Hipparcos catalog.
static const Equinox & icrs ()
 International Celestial Reference System (ICRS) is the IAU standard catalog coordinate system.
static const Equinox & j2000 ()
 The system of the dynamical equator at the J2000 epoch (12 TT, 1 January 2000).
static Equinox mod (const Time &time)
 Mean-of-date (MOD) dynamical coordinate system, at the specified Julian epoch.
static Equinox mod (double jd_tt)
 Mean-of-date (MOD) dynamical coordinate system, at the specified Julian epoch.
static Equinox mod_at_besselian_epoch (double year)
 Mean-of-date (MOD) dynamical coordinate system, at the specified Besselian epoch.
static Equinox tod (const Time &time)
 Returns a True-of-Date (TOD) equatorial system for the given (TT-based) Julian date.
static Equinox tod (double jd_tt)
 Returns a True-of-Date (TOD) equatorial system for the given (TT-based) Julian date.
static const Equinox & undefined ()
 Returns a reference to a statically defined standard invalid equatorial system.

Additional Inherited Members

Protected Member Functions inherited from supernovas::Validating
 Validating ()
 dummy constructor;
Protected Attributes inherited from supernovas::Validating
bool _valid = false
 the state variable.

Detailed Description

Equatorial coordinate system, defining the orientation of the equator and the location of the equinox, relative to which the right ascention and declination (RA/Dec) coordinates are defined.

We'll simply refer to it as Equinox in this API. This class does not include the Earth co-rotating systems (TIRS and ITRS).

See also
CatalogEntry, Equatorial, Ecliptic, Apparent, Geometric

Member Function Documentation

◆ b1900()

const Equinox & supernovas::Equinox::b1900 ( )
static

The system of the dynamical equator at the B1900 epoch (0 UTC, 1 January 1900).

This was a commonly used catalog coordinate system of old.

Returns
A reference to a reusable statically allocated B1900 coordinate system instance.
See also
icrs(), mod(), Time::b1900(), NOVAS_JD_B1900, NOVAS_SYSTEM_B1900

References b1900(), and mod_at_besselian_epoch().

Referenced by b1900().

◆ b1950()

const Equinox & supernovas::Equinox::b1950 ( )
static

The system of the dynamical equator at the B1950 epoch (0 UTC, 1 January 1950).

This was a commonly used catalog coordinate system of old. It is also known as FK4, since the 4th realization of the fundamental catalog of stars used B1950 also.

B1950 is also the system used for the 4th Catalog of Fundamental Stars (FK4).

Returns
A reference to a reusable statically allocated B1950 coordinate system instance.
See also
icrs(), mod(), Time::b1950(), NOVAS_JD_B1950, NOVAS_SYSTEM_B1950

References b1950(), and mod_at_besselian_epoch().

Referenced by b1950().

◆ cirs() [1/2]

Equinox supernovas::Equinox::cirs ( const Time & time)
static

Returns a Celestial Intermediate Reference System (CIRS) equatorial system for the given (TT-based) Julian date.

It is the system on the true dynamical equator of date, with its origin at the Celestial Intermediate Origin (CIO) of date.

Parameters
Time of observation and astronomical timescalesastrometric time specifying the coordinate epoch.
Returns
the equatorial coordinate system based on the true dynamical equator, with its origin at the CIO
See also
tod()

References cirs(), and supernovas::Time::jd().

◆ cirs() [2/2]

Equinox supernovas::Equinox::cirs ( double jd_tt)
static

Returns a Celestial Intermediate Reference System (CIRS) equatorial system for the given (TT-based) Julian date.

It is the system on the true dynamical equator of date, with its origin at the Celestial Intermediate Origin (CIO) of date.

Parameters
jd_tt[day] The (TT-based) Julian date for when of the true dynamical equator and true equinox of date define the returned equatorial coordinate system,
Returns
the equatorial coordinate system based on the true dynamical equator, with its origin at the CIO
See also
tod()

References cirs(), supernovas::Validating::is_valid(), and NOVAS_CIRS.

Referenced by supernovas::Apparent::cirs(), cirs(), cirs(), and supernovas::Equatorial::to_cirs().

◆ epoch()

double supernovas::Equinox::epoch ( ) const

Returns the years of the Julian epoch that matches this system.

E.g. for both 'ICRS' and 'J2000' this will return 2000.0.

Returns
[yr] The Julian epoch year of this catalog system.
See also
jd(), mjd(), Time::epoch()

References epoch().

Referenced by epoch().

◆ equals() [1/2]

bool supernovas::Equinox::equals ( const Equinox & system,
const Interval & dt ) const

Checks if this equatorial system equals the equatorial system as the right-hand side, with the epochs also matching within the specified precision.

Parameters
systemThe equatorial system on the right-hand side.
dt[s] The tolerance to epoch differences.
Returns
true if the two equatorial systems are essentially the same, or else false.
See also
operator==()

References equals(), and supernovas::Interval::seconds().

◆ equals() [2/2]

bool supernovas::Equinox::equals ( const Equinox & system,
double dt = Unit::s ) const

Checks if this equatorial system equals the equatorial system as the right-hand side, with the epochs also matching within the specified precision.

Parameters
systemThe equatorial system on the right-hand side.
dt[s] The tolerance to epoch differences in seconds.
Returns
true if the two equatorial systems are essentially the same, or else false.
See also
operator==()

References supernovas::Unit::day, equals(), and is_mod().

Referenced by equals(), equals(), operator!=(), and operator==().

◆ equator_type()

enum novas_equator_type supernovas::Equinox::equator_type ( ) const

Returns the type of equator used in this equatorial coordinate system.

Returns
the type of equator used in this equatorial system.

References equator_type(), NOVAS_CIRS, NOVAS_GCRS, NOVAS_GCRS_EQUATOR, NOVAS_ICRS, NOVAS_J2000, NOVAS_MEAN_EQUATOR, NOVAS_MOD, NOVAS_TOD, NOVAS_TRUE_EQUATOR, and system_type().

Referenced by equator_type().

◆ from_string()

Equinox supernovas::Equinox::from_string ( const std::string & name)
static

Returns a new equinox instance from a string, such as 'ICRS', 'J2000', 'FK5', B1950', or 'HIP'; or else {}.

It is generally preferable to use one of the other static initializers, such as icrs(), or j2000(), which are guaranteed to return a valid instance.

Parameters
nameThe name that defining the type of catalog system. If only a year is give, then it prior to 1984.0 they map to Besselian epochs, e.g. '1950' → 'B1950', whereas for later dates Julian epochs are assumed, e.g. '2000' → 'J2000'.
Returns
an optional containing the corresponding valid equatorial system, or else Equinox::undefined().
See also
is_valid(), icrs(), j2000(), b1950(), b1900()

References supernovas::Unit::day, from_string(), name(), NOVAS_CIRS, novas_epoch(), NOVAS_ICRS, NOVAS_J2000, NOVAS_JD_B1950, NOVAS_JD_J2000, NOVAS_MOD, NOVAS_TOD, supernovas::Unit::s, and undefined().

Referenced by from_string().

◆ from_system_type()

Equinox supernovas::Equinox::from_system_type ( enum novas_reference_system system,
double jd_tt = NOVAS_JD_J2000 )
static

Returns a new equinox instance given a coordinate reference system type and a date.

Parameters
systemThe coordinate reference system type
jd_tt[day] The (TT-based) Julian date (for dynamical systems).
Returns
an optional containing the corresponding valid equatorial system, or else std::nullopt.

References from_system_type(), supernovas::Validating::is_valid(), NOVAS_ITRS, NOVAS_TIRS, and undefined().

Referenced by supernovas::AstrometricPosition::as_equatorial(), supernovas::Geometric::equatorial(), and from_system_type().

◆ hip()

const Equinox & supernovas::Equinox::hip ( )
static

The system of the mean dynamical equator at the J1991.25 epoch, which is adopted as the nominal mean epoch of the Hipparcos catalog.

J2000 is also the system used for the 5th Catalog of Fundamental Stars (FK5).

Returns
A reference to a reusable statically allocated Hipparcos coordinate system instance.
See also
icrs(), mod(), Time::hip() NOVAS_JD_HIP, NOVAS_SYSTEM_HIP

References hip(), NOVAS_JD_HIP, and NOVAS_MOD.

Referenced by hip(), and supernovas::Equatorial::to_hip().

◆ icrs()

const Equinox & supernovas::Equinox::icrs ( )
static

International Celestial Reference System (ICRS) is the IAU standard catalog coordinate system.

It is defined by distant quasars, and is aligned with the J2000 dynamical equator within 22 mas. In SuperNOVAS ICRS is the same as GCRS (the Geocentric Celestial Reference System) or BCRS (the Barycentric International Reference System), which have the same alignment and differ only in the location of their origin. In SuperNOVAS, the origin is determined by the Observer location, while the coordinate system defines only the orientation of the celestial pole. Thus, there is no need to distinguish between these related systems explicitly in SuperNOVAS.

ICRS is also the system used for the 6th Catalog of Fundamental Stars (FK6).

Returns
A reference to a reusable statically allocated ICRS system instance.
See also
NOVAS_ICRS, NOVAS_GCRS, NOVAS_SYSTEM_ICRS

References icrs(), NOVAS_ICRS, and NOVAS_JD_J2000.

Referenced by icrs(), supernovas::Ecliptic::system(), supernovas::Galactic::to_equatorial(), and supernovas::Equatorial::to_icrs().

◆ is_icrs()

bool supernovas::Equinox::is_icrs ( ) const

Checks if this equatorial system is the International Celestial Reference System (ICRS).

ICRS is the standard catalog system in the IAU 2000 convention.

Returns
true if this equatorial system is the ICRS, or else false.
See also
is_mod(), is_true()

References is_icrs(), and NOVAS_ICRS.

Referenced by is_icrs().

◆ is_mod()

bool supernovas::Equinox::is_mod ( ) const

Checks if this equatorial system is a Mean-of-Date (MOD) system.

MODs include precession, but not nutation, and have been commonly used for catalogs (e.g. J2000, B1950, FK4, or HIP) prior to the IAU 2000 convention, when ICRS became the new standard catalog system.

Returns
true if this equatorial system is a Mean-of-Date (MOD) catalog system, or else false.
See also
is_icrs(), is_true()

References is_mod(), NOVAS_J2000, and NOVAS_MOD.

Referenced by equals(), and is_mod().

◆ is_true()

bool supernovas::Equinox::is_true ( ) const

Checks if this equatorial system is based on the true dynamical equator of date.

If true, it may be a True-of-Date (TOD) system with the origin at the true equinox of date, or else the Celestial Intermediate Reference System (CIRS) with its origin at the Celestial Intermediate Origin (CIO).

Returns
true if this equatorial system is defined on the true dynamical equator of date, or else false.
See also
is_icrs(), is_mod()

References is_true(), NOVAS_CIRS, and NOVAS_TOD.

Referenced by is_true().

◆ j2000()

const Equinox & supernovas::Equinox::j2000 ( )
static

The system of the dynamical equator at the J2000 epoch (12 TT, 1 January 2000).

This was a commonly used catalog coordinate system before the advent of the IAU 2000 standard ICRS system. It is also known as FK5, since the 5th realization of the fundamental catalog of stars used J2000 also.

Returns
A reference to a reusable statically allocated J2000 coordinate system instance.
See also
icrs(), mod(), Time::j2000(), NOVAS_JD_J2000, NOVAS_SYSTEM_J2000

References j2000(), NOVAS_J2000, and NOVAS_JD_J2000.

Referenced by j2000(), supernovas::Ecliptic::system(), and supernovas::Equatorial::to_j2000().

◆ jd()

double supernovas::Equinox::jd ( ) const

Returns the (TT-based) Julian date that corresponds to this system instance.

That is, it returns the date for which the mean dynamical equator best matches the equator of this catalog system.

Returns
[day] the (TT-based) Julian date at which the mean dynamical equator matches this system. E.g. for 'ICRS' it will return the Julian date for the J2000.0 epoch.
See also
mjd(), epoch(), Time

References jd().

Referenced by jd().

◆ mjd()

double supernovas::Equinox::mjd ( ) const

Returns the (TT-based) Modified Julian Date (MJD) that corresponds to this system instance.

That is, it returns the MJD for which the mean dynamical equator best matches the equator of this catalog system.

Returns
[day] the (TT-based) Modified Julian Date (MJD) at which the mean dynamical equator matches this system. E.g. for 'ICRS' it will return the MJD for the J2000.0 epoch.
See also
jd(), epoch(), Time

References mjd(), and NOVAS_JD_MJD0.

Referenced by mjd().

◆ mod() [1/2]

Equinox supernovas::Equinox::mod ( const Time & time)
static

Mean-of-date (MOD) dynamical coordinate system, at the specified Julian epoch.

MOD coordinates take into account Earth's slow precession but not nutation. Julian-date based MODs were commonly used for catalogs, such as J2000, or HIP.

Parameters
Time of observation and astronomical timescalesastrometric time specifying the coordinate epoch.
Returns
A reference system with the mean dynamical equator of date, with origin at the mean equinox of date.
See also
mod_at_besselial_epoch(), j2000(), hip()

References supernovas::Time::jd(), and mod().

◆ mod() [2/2]

Equinox supernovas::Equinox::mod ( double jd_tt)
static

Mean-of-date (MOD) dynamical coordinate system, at the specified Julian epoch.

MOD coordinates take into account Earth's slow precession but not nutation. Julian-date based MODs were commonly used for catalogs, such as J2000, or HIP.

Parameters
jd_tt[day] TT-based Julian day.
Returns
A reference system with the mean dynamical equator of date, with origin at the mean equinox of date.
See also
mod_at_besselial_epoch(), j2000(), hip()

References supernovas::Validating::is_valid(), mod(), and NOVAS_MOD.

Referenced by mod(), mod(), supernovas::Ecliptic::system(), and supernovas::Equatorial::to_mod().

◆ mod_at_besselian_epoch()

Equinox supernovas::Equinox::mod_at_besselian_epoch ( double year)
static

Mean-of-date (MOD) dynamical coordinate system, at the specified Besselian epoch.

MOD coordinates take into account Earth's precession but not nutation. Besselian-date based MODs, now a historical relic, were once commonly used for catalog systems, such as B1900, or B1950.

Parameters
year[yr] UTC-based decimal calendar year.
Returns
A reference system with the mean dynamical equator of date, with origin at the mean equinox of date.
See also
at_julian_date(), b1900(), b1950()

References supernovas::Unit::besselian_year, supernovas::Unit::day, supernovas::Validating::is_valid(), mod_at_besselian_epoch(), and NOVAS_JD_B1950.

Referenced by b1900(), b1950(), mod_at_besselian_epoch(), and supernovas::Equatorial::to_mod_at_besselian_epoch().

◆ name()

const std::string & supernovas::Equinox::name ( ) const

Returns a reference to the name of this system.

Returns
A reference to the string that stores the system's name

References name().

Referenced by supernovas::CatalogSource::CatalogSource(), from_string(), and name().

◆ operator!=()

bool supernovas::Equinox::operator!= ( const Equinox & system) const

Checks if this equatorial system differs from the equatorial system as the right-hand side.

Parameters
systemThe equatorial system on the right-hand side.
Returns
true if the two equatorial systems are differ, or else false.
See also
operator==()

References equals(), and operator!=().

Referenced by operator!=().

◆ operator==()

bool supernovas::Equinox::operator== ( const Equinox & system) const

Checks if this equatorial system equals the equatorial system as the right-hand side, with the epochs also matching to within 1 second.

Parameters
systemThe equatorial system on the right-hand side.
Returns
true if the two equatorial systems are essentially the same, or else false.
See also
equals(), operator!=()

References equals(), and operator==().

Referenced by operator==().

◆ system_type()

enum novas_reference_system supernovas::Equinox::system_type ( ) const

Returns the coordinate reference system type for this equatorial system.

Returns
the coordinate reference system type

References system_type().

Referenced by equator_type(), supernovas::OrbitalSystem::orientation(), and system_type().

◆ to_string()

std::string supernovas::Equinox::to_string ( ) const

Provides a string representation of this system.

It is pretty much the same as calling name(), except it returns a copy rather than the reference.

Returns
A string identification of this catalog system.

References to_string().

Referenced by to_string().

◆ tod() [1/2]

Equinox supernovas::Equinox::tod ( const Time & time)
static

Returns a True-of-Date (TOD) equatorial system for the given (TT-based) Julian date.

It is the system on the true dynamical equator of date, with its origin at the true equinox of date.

Parameters
Time of observation and astronomical timescalesastromemtric time specifying the coordinate epoch,
Returns
the equatorial coordinate system based on the true dynamical equator and equinox of date.
See also
cirs()

References supernovas::Time::jd(), and tod().

◆ tod() [2/2]

Equinox supernovas::Equinox::tod ( double jd_tt)
static

Returns a True-of-Date (TOD) equatorial system for the given (TT-based) Julian date.

It is the system on the true dynamical equator of date, with its origin at the true equinox of date.

Parameters
jd_tt[day] The (TT-based) Julian date for when of the true dynamical equator and true equinox of date define the returned equatorial coordinate system,
Returns
the equatorial coordinate system based on the true dynamical equator and equinox of date.
See also
cirs()

References supernovas::Validating::is_valid(), NOVAS_TOD, and tod().

Referenced by supernovas::Apparent::equatorial(), supernovas::Source::equatorial_track(), supernovas::Ecliptic::system(), supernovas::Equatorial::to_tod(), tod(), and tod().

◆ undefined()

const Equinox & supernovas::Equinox::undefined ( )
static

Returns a reference to a statically defined standard invalid equatorial system.

This invalid equatorial system may be used inside any object that is invalid itself.

Returns
a reference to a static standard invalid equatorial system.

References undefined().

Referenced by from_string(), from_system_type(), supernovas::Ecliptic::system(), and undefined().