Loading...
Searching...
No Matches
Time of observation and astronomical timescales

Defining the precise time of observation, and support for all relevant astronomical timescales, such as UT1, UTC, TAI, GPS, TT, TDB, TCG, TCB. More...

## Classes

class | supernovas::Calendar
| Type of calendar used for representing dates, such as Gregorian, Roman, or astronomical. More...
class | supernovas::CalendarDate
| A time specified in a specific type of calendar (Gregorian, Roman, or astronomical). More...
class | supernovas::Time
| Precise astronomical time specification, supporting all relevant astronomical timescales (UT1, UTC, TAI, GPS, TT, TDB, TCG, and TCB). More...

## Enumerations

enum | novas_timescale { NOVAS_TCB = 0 , NOVAS_TDB , NOVAS_TCG , NOVAS_TT , NOVAS_TAI , NOVAS_GPS , NOVAS_UTC , NOVAS_UT1 }
| Constants to reference various astronomical timescales used. More...

## Functions

const Time & | supernovas::AstrometricPosition::emit_time () const
| Returns the time at which the observed light was emitted from this position, that is antedated from the time of observation by the time it takes for light to travel to the observer.
enum novas_timescale | novas_timescale_for_string (const char *restrict str)
| Returns the timescale constant for a string that denotes the timescale in with a standard abbreviation (case insensitive).
Time | supernovas::AstrometricPosition::obs_time () const
| Returns the reference time at which this position was observed by an observer at the reference location.
Time | supernovas::Source::rises_above (const Angle &el, const Frame &frame, RefractionModel ref=NULL, const Weather &weather=Weather::standard()) const
| Returns the time when the source rises above the specified elevation next for an observer located on or near Earth's surface, or else an undefined (invalid) time if the observer is not near Earth's surface.
Time | supernovas::Source::sets_below (const Angle &el, const Frame &frame, RefractionModel ref=NULL, const Weather &weather=Weather::standard()) const
| Returns the time when the source sets below the specified elevation next for an observer located on or near Earth's surface, or else an undefined (invalid) time if the observer is not near Earth's surface.
Time | supernovas::Source::transits_in (const Frame &frame) const
| Returns the time when the source transits for an observer located on or near Earth's surface, or else an undefined (invalid) time if the observer is not near Earth's surface.
double | tt2tdb_fp (double jd_tt, double limit)
| Returns the TDB-TT time difference with flexible precision.

## Detailed Description

Defining the precise time of observation, and support for all relevant astronomical timescales, such as UT1, UTC, TAI, GPS, TT, TDB, TCG, TCB.

## Enumeration Type Documentation

## novas_timescale

enum novas_timescale

Constants to reference various astronomical timescales used.

Since
  1.1

See also
  novas_set_time(), novas_get_time(), novas_diff_time(), novas_clock_skew(), NOVAS_TIMESCALES
  timescale.c

Enumerator
NOVAS_TCB | Barycentric Coordinate Time (TCB).
NOVAS_TDB | Barycentric Dynamical Time (TDB).
NOVAS_TCG | Geocentric Coordinate Time (TCG).
NOVAS_TT | Terrestrial Time (TT).
NOVAS_TAI | International Atomic Time (TAI).
NOVAS_GPS | GPS Time.
NOVAS_UTC | Universal Coordinated Time (UTC).
NOVAS_UT1 | UT1 earth rotation time, based on the measured Earth orientation parameters published in IERS Bulletin A.

## Function Documentation

## emit_time()

const Time & supernovas::AstrometricPosition::emit_time | ( |  | ) | const

Returns the time at which the observed light was emitted from this position, that is antedated from the time of observation by the time it takes for light to travel to the observer.

Returns
  the time at which observed light was emitted from this position.

Since
  1.6

See also
  obs_time()

## novas_timescale_for_string()

enum novas_timescale novas_timescale_for_string | ( | const char *restrict | str | ) |

Returns the timescale constant for a string that denotes the timescale in with a standard abbreviation (case insensitive).

The following values are recognised: "UTC", "UT", "UT0", "UT1", "GMT", "TAI", "GPS", "TT", "ET", "TCG", "TCB", and "TDB".

Parameters

  str | String specifying an astronomical timescale

Returns
  The SuperNOVAS timescale constant (<=0), or else -1 if the string was NULL, empty, or could not be matched to a timescale value (errno will be set to EINVAL also).

Since
  1.3

Author
  Attila Kovacs

See also
  novas_parse_timescale(), novas_set_str_time(), novas_print_timescale()

References NOVAS_GPS, NOVAS_TAI, NOVAS_TCB, NOVAS_TCG, NOVAS_TDB, NOVAS_TT, NOVAS_UT1, and NOVAS_UTC.

Referenced by novas_parse_timescale().

## obs_time()

Time supernovas::AstrometricPosition::obs_time | ( |  | ) | const

Returns the reference time at which this position was observed by an observer at the reference location.

Returns
  the time at which this position is observed.

Since
  1.6

See also
  emit_time(), reference()

References supernovas::Constant::c, supernovas::Position::distance(), supernovas::Validating::is_valid(), and supernovas::Coordinate::m().

Referenced by referenced_to(), to_equatorial(), and to_interferometric().

## rises_above()

Time supernovas::Source::rises_above | ( | const Angle & | el,
|  | const Frame & | frame,
|  | RefractionModel | ref = NULL,
|  | const Weather & | weather = Weather::standard() ) const

Returns the time when the source rises above the specified elevation next for an observer located on or near Earth's surface, or else an undefined (invalid) time if the observer is not near Earth's surface.

The returned value may also be NAN if the source does not cross the specified elevation threshold within a day of the specified time of observation.

Parameters

  el | elevation threshold angle
  frame | observing frame (observer location and the lower bound for the returned time).
  ref | atmospheric refraction model to assume
  weather | local weather parameters for the refraction calculation

Returns
  the next time the source rises above the specified elevation after the frame's observing time. It may be NAN if the source does not cross (rises above or sets below) the elevation threshold within a day of the specified time of observation. For observers non near Earth's surface, Time::undefined() will be returned.

Since
  1.6

See also
  sets_below(), transits_in()

References supernovas::Frame::_novas_frame(), _object, supernovas::Angle::deg(), supernovas::Frame::eop(), supernovas::Validating::is_valid(), and novas_rises_above().

## sets_below()

Time supernovas::Source::sets_below | ( | const Angle & | el,
|  | const Frame & | frame,
|  | RefractionModel | ref = NULL,
|  | const Weather & | weather = Weather::standard() ) const

Returns the time when the source sets below the specified elevation next for an observer located on or near Earth's surface, or else an undefined (invalid) time if the observer is not near Earth's surface.

The returned value may also be NAN if the source does not cross the specified elevation threshold within a day of the specified time of observation.

Parameters

  el | elevation threshold angle
  frame | observing frame (observer location and the lower bound for the returned time).
  ref | atmospheric refraction model to assume
  weather | local weather parameters for the refraction calculation

Returns
  the next time the source sets the specified elevation after the frame's observing time. It may be NAN if the source does not cross (rises above or sets below) the elevation threshold within a day of the specified time of observation. For observers not near Earth's surface, Time::undefined() will be returned.

Since
  1.6

See also
  rises_above(), transits_in()

References supernovas::Frame::_novas_frame(), _object, supernovas::Angle::deg(), supernovas::Frame::eop(), supernovas::Validating::is_valid(), and novas_sets_below().

## transits_in()

Time supernovas::Source::transits_in | ( | const Frame & | frame | ) | const

Returns the time when the source transits for an observer located on or near Earth's surface, or else an undefined (invalid) time if the observer is not near Earth's surface.

Parameters

  frame | observing frame (observer location and the lower bound for the returned time).

Returns
  the next time the source transits after the frame's observing time, or else Time::undefined() if the observer is not near Earth's surface .

Since
  1.6

See also
  sets_below(), transits_in()

References supernovas::Frame::_novas_frame(), _object, supernovas::Frame::eop(), supernovas::Validating::is_valid(), and novas_transit_time().

## tt2tdb_fp()

double tt2tdb_fp | ( | double | jd_tt,
|  | double | limit )

Returns the TDB-TT time difference with flexible precision.

This implementation uses the series expansion by Fairhead & Bretagnon 1990, terminating the terms at or below the specified limiting amplitude.

REFERENCES:

1. Fairhead, L., & Bretagnon, P. (1990) A&A, 229, 240

Parameters

  jd_tt | [day] Terrestrial Time (TT) based Julian date, but Barycentric Dynamical Time (TDB)
  limit | [us] Amplitude of limiting term to include in series. 0 or negative values will include all terms, producing the same result as tt2tdb_hp().

Returns
  [s] TDB - TT time difference.

Since
  1.4

Author
  Attila Kovacs

See also
  tt2tdb_hp(), tt2tdb()

References NOVAS_JD_J2000.

Referenced by tt2tdb_hp().