Loading...
Searching...
No Matches
earth.c File Reference

Various functions relating to Earth position and rotation. More...

## Functions

double | era (double jd_ut1_high, double jd_ut1_low)
| Returns the value of the Earth Rotation Angle (θ) for a given UT1 Julian date.
short | geo_posvel (double jd_tt, double ut1_to_tt, enum novas_accuracy accuracy, const observer *restrict obs, double *restrict pos, double *restrict vel)
| Computes the geocentric GCRS position and velocity of an observer.
int | limb_angle (const double *pos_src, const double *pos_obs, double *restrict limb_ang, double *restrict nadir_ang)
| Determines the angle of an object above or below the Earth's limb (horizon).
int | novas_diurnal_eop (double gmst, const novas_delaunay_args *restrict delaunay, double *restrict dxp, double *restrict dyp, double *restrict dut1)
| Calculate corrections to the Earth orientation parameters (EOP) due to short term (diurnal and semidiurnal) libration and the ocean tides.
int | novas_diurnal_eop_at_time (const novas_timespec *restrict time, double *restrict dxp, double *restrict dyp, double *restrict dut1)
| Calculate corrections to the Earth orientation parameters (EOP) due to short term (diurnal and semidiurnal) libration and the ocean tides at a given astromtric time.
int | novas_diurnal_libration (double gmst, const novas_delaunay_args *restrict delaunay, double *restrict dxp, double *restrict dyp, double *restrict dut1)
| Calculate diurnal and semi-diurnal libration corrections to the Earth orientation parameters (EOP) for the non-rigid Earth.
int | novas_diurnal_ocean_tides (double gmst, const novas_delaunay_args *restrict delaunay, double *restrict dxp, double *restrict dyp, double *restrict dut1)
| Calculate corrections to the Earth orientation parameters (EOP) due to the ocean tides.
double | novas_gast (double jd_ut1, double ut1_to_tt, enum novas_accuracy accuracy)
| Returns the Greenwich Apparent Sidereal Time (GAST) for a given UT1 date.
double | novas_gmst (double jd_ut1, double ut1_to_tt)
| Returns the Greenwich Mean Sidereal Time (GMST) for a given UT1 date, using eq.
short | sidereal_time (double jd_ut1_high, double jd_ut1_low, double ut1_to_tt, enum novas_equinox_type gst_type, enum novas_earth_rotation_measure erot, enum novas_accuracy accuracy, double *restrict gst)
int | terra (const on_surface *restrict location, double gast, double *restrict pos, double *restrict vel)
| Computes the position and velocity vectors of a terrestrial observer with respect to the center of the Earth, based on the GRS80 reference ellipsoid, used for the International Terrestrial Reference Frame (ITRF) and its realizations.
int | wobble (double jd_tt, enum novas_wobble_direction direction, double xp, double yp, const double *in, double *out)
| Corrects a vector in the ITRS (rotating Earth-fixed system) for polar motion, and also corrects the longitude origin (by a tiny amount) to the Terrestrial Intermediate Origin (TIO).

## Detailed Description

Various functions relating to Earth position and rotation.

Date
  Created on Mar 6, 2025

Author
  G. Kaplan and Attila Kovacs

See also
  frames.c, itrf.c

## Function Documentation

## sidereal_time()

short sidereal_time | ( | double | jd_ut1_high,
|  | double | jd_ut1_low,
|  | double | ut1_to_tt,
|  | enum novas_equinox_type | gst_type,
|  | enum novas_earth_rotation_measure | erot,
|  | enum novas_accuracy | accuracy,
|  | double *restrict | gst )

Deprecated
  Use novas_gmst() or novas_gast() instead to get the same results simpler.

Computes the Greenwich sidereal time, either mean or apparent, at the specified Julian date. The Julian date can be broken into two parts if convenient, but for the highest precision, set 'jd_high' to be the integral part of the Julian date, and set 'jd_low' to be the fractional part.

NOTES:

1. Contains fix for known sidereal time units bug.
2. As of version 1.5.0, the function uses Eq 42 of Capitaine et al. (2003) exclusively. In prior versions, including NOVAS C the same method was provided twice, with the only difference being an unnecessary change of coordinate basis to GCRS. This latter, mor roundabout way of getting the same answer has been eliminated.<.li>

REFERENCES:

1. Capitaine, N. et al. (2003), Astronomy and Astrophysics 412, 567-586, eq. (42).
2. Kaplan, G. (2005), US Naval Observatory Circular 179.

Parameters

  | jd_ut1_high | [day] High-order part of UT1 Julian date.
  | jd_ut1_low | [day] Low-order part of UT1 Julian date. (You can leave it at zero if 'jd_high' specified the date with sufficient precision)
  | ut1_to_tt | [s] TT - UT1 Time difference in seconds
  | gst_type | NOVAS_MEAN_EQUINOX (0) or NOVAS_TRUE_EQUINOX (1), depending on whether wanting mean or apparent GST, respectively.
  | erot | Unused as of 1.5.0.
  | accuracy | NOVAS_FULL_ACCURACY (0) or NOVAS_REDUCED_ACCURACY (1)
  [out] | gst | [h] Greenwich (mean or apparent) sidereal time, in hours [0:24]. (In case the returned error code is >1 the gst value will be set to NAN.)

Returns
  0 if successful, or -1 if the 'gst' argument is NULL, 1 if 'accuracy' is

See also
  novas_gmst(), novas_gast(), novas_time_gst()
  era(), get_ut1_to_tt()

References NOVAS_FULL_ACCURACY, novas_gast(), novas_gmst(), NOVAS_REDUCED_ACCURACY, and NOVAS_TRUE_EQUINOX.