MRTKLIB 0.7.14
Modernized GNSS Positioning Library
Loading...
Searching...
No Matches
mrtk_astro.h File Reference

MRTKLIB Astronomy Module — Sun and moon position computation. More...

Include dependency graph for mrtk_astro.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void sunmoonpos_eci (gtime_t tut, double *rsun, double *rmoon)
 Compute sun and moon position in ECI.
void sunmoonpos (gtime_t tutc, const double *erpv, double *rsun, double *rmoon, double *gmst)
 Compute sun and moon position in ECEF.

Detailed Description

MRTKLIB Astronomy Module — Sun and moon position computation.

This header provides functions for computing the positions of the Sun and Moon in ECI and ECEF coordinate frames, extracted from rtkcmn.c with zero algorithmic changes.

Note
Functions declared here are implemented in mrtk_astro.c.

Definition in file mrtk_astro.h.

Function Documentation

◆ sunmoonpos()

void sunmoonpos ( gtime_t tutc,
const double * erpv,
double * rsun,
double * rmoon,
double * gmst )

Compute sun and moon position in ECEF.

Parameters
[in]tutcTime in UTC (GPST)
[in]erpvERP value {xp,yp,ut1_utc,lod} (rad,rad,s,s/d)
[out]rsunSun position in ECEF (m) (NULL: not output)
[out]rmoonMoon position in ECEF (m) (NULL: not output)
[out]gmstGMST (rad) (NULL: not output)

Definition at line 135 of file mrtk_astro.c.

References eci2ecef(), matmul(), sunmoonpos_eci(), time_str(), timeadd(), and trace().

Referenced by satantoff(), tidedisp(), and windupcorr().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ sunmoonpos_eci()

void sunmoonpos_eci ( gtime_t tut,
double * rsun,
double * rmoon )

Compute sun and moon position in ECI.

Parameters
[in]tutTime in UT1 (GPST)
[out]rsunSun position in ECI (m) (NULL: not output)
[out]rmoonMoon position in ECI (m) (NULL: not output)
Note
See reference [4] 5.1.1, 5.2.1

Definition at line 78 of file mrtk_astro.c.

References ast_args(), AU, D2R, epoch2time(), RE_WGS84, time_str(), timediff(), and trace().

Referenced by sunmoonpos().

Here is the call graph for this function:
Here is the caller graph for this function: