CelestialCalendar 1.0.0 · unreleased development @ 67a7c4c79a4a4a6aa7e703c9e6f0039ae34bee82
Loading...
Searching...
No Matches
astro::ephemeris Namespace Reference

Namespaces

namespace  detail

Classes

struct  TargetFacts
 Target identity and provider domains; rate_node preserves the paired ascending trajectory. More...
struct  Position
 Apparent geocentric coordinates in the true ecliptic and equinox of date. More...
struct  EquatorialPosition
 Apparent geocentric equatorial coordinates of date; nodes have no physical distance. More...
struct  LongitudeRate
 A signed instantaneous longitude rate; a negative value means longitude is decreasing at that instant. More...
struct  LongitudeEvent
 A crossing or exact numerical contact at a supplied longitude. More...
struct  StationEvent
 A stationary instant of the published finite-difference rate, with its two-sided motion. More...
struct  LongitudeDifferenceEvent
 An event in the directed, canonical longitude difference first minus second. More...

Enumerations

enum class  Target : uint8_t {
  SUN , MOON , MERCURY , VENUS ,
  MARS , JUPITER , SATURN , URANUS ,
  NEPTUNE , PLUTO , MEAN_ASCENDING , MEAN_DESCENDING ,
  TRUE_ASCENDING , TRUE_DESCENDING
}
 A body or lunar node. More...
enum class  PositionSource : uint8_t {
  SUN_VSOP87D , MOON_ELP2000_82B_TRUNC , PLANET_VSOP87D , PLUTO_PLUTO95_APPARENT ,
  NODE_MEAN , NODE_TRUE_MEEUS_FIVE_TERM
}
 The computation supplying a target's apparent position. More...
enum class  DomainOrigin : uint8_t { SOURCE , IMPLEMENTATION }
 Origin of a bounded position domain; ignored when no position domain is declared. More...
enum class  EventDirection : uint8_t { INCREASING , DECREASING , TANGENT }
 Behavior of an angular level on the two sides of an event. More...
enum class  Motion : uint8_t { DIRECT , RETROGRADE }
 The sign of longitude motion away from a stationary instant. More...

Functions

constexpr auto is_target (const Target target) -> bool
 Recognize named Target values; new distinct enumerators must also enter TARGET_FACTS.
constexpr auto target_facts (const Target target) -> const TargetFacts &
 Look up a named target; unknown values are invalid arguments.
constexpr auto source_of (const Target target) -> PositionSource
 The source of a named target's apparent position.
constexpr auto position_domain (const Target target) -> std::optional< std::array< double, 2 > >
 Half-open provider domain, or no hard interval; neither implies accuracy or successful evaluation.
auto position (const Target target, const double jde_tt) -> Position
 Evaluate one target's apparent position without a rate stencil or civil policy.
auto equatorial_position (const Target target, const double jde_tt) -> EquatorialPosition
 Project one apparent ecliptic position to geocentric apparent RA/Dec of date.
constexpr auto longitude_rate_domain (const Target target) -> std::array< double, 2 >
 Return the half-open center domain of a target's longitude-rate operation.
auto longitude_rate (const Target target, const double jde_tt) -> LongitudeRate
 Instantaneous geocentric longitude rate using the target's position model.
auto longitude_events (const Target target, const toolbox::AngleDeg target_longitude, const double start_jde_tt, const double end_jde_tt) -> std::vector< LongitudeEvent >
 Return every crossing or exact numerical contact at a supplied tropical longitude.
auto stations (const Target target, const double start_jde_tt, const double end_jde_tt) -> std::vector< StationEvent >
 Return every isolated zero of ephemeris::longitude_rate in a half-open TT interval.
auto longitude_difference_events (const Target first, const Target second, const toolbox::AngleDeg target_difference, const double start_jde_tt, const double end_jde_tt) -> std::vector< LongitudeDifferenceEvent >
 Return every event at a directed longitude difference, first minus second.

Variables

constexpr auto TARGET_FACTS
 Target facts in chart order; absent position domains admit finite-input evaluation, which may fail.
constexpr auto TARGETS
 The target roster, derived from the facts table in chart order.
constexpr double EVENT_MAXIMUM_QUERY_SPAN_TT_DAYS
 Maximum nonempty event-query span in TT days.

Enumeration Type Documentation

◆ DomainOrigin

enum class astro::ephemeris::DomainOrigin : uint8_t
strong

Origin of a bounded position domain; ignored when no position domain is declared.

Enumerator
SOURCE 
IMPLEMENTATION 

◆ EventDirection

enum class astro::ephemeris::EventDirection : uint8_t
strong

Behavior of an angular level on the two sides of an event.

Enumerator
INCREASING 
DECREASING 
TANGENT 

◆ Motion

enum class astro::ephemeris::Motion : uint8_t
strong

The sign of longitude motion away from a stationary instant.

Enumerator
DIRECT 
RETROGRADE 

◆ PositionSource

enum class astro::ephemeris::PositionSource : uint8_t
strong

The computation supplying a target's apparent position.

Enumerator
SUN_VSOP87D 
MOON_ELP2000_82B_TRUNC 
PLANET_VSOP87D 
PLUTO_PLUTO95_APPARENT 
NODE_MEAN 
NODE_TRUE_MEEUS_FIVE_TERM 

Meeus' five-term approximation, not an osculating node.

◆ Target

enum class astro::ephemeris::Target : uint8_t
strong

A body or lunar node.

Enumerator
SUN 
MOON 
MERCURY 
VENUS 
MARS 
JUPITER 
SATURN 
URANUS 
NEPTUNE 
PLUTO 
MEAN_ASCENDING 
MEAN_DESCENDING 
TRUE_ASCENDING 
TRUE_DESCENDING 

Function Documentation

◆ equatorial_position()

auto astro::ephemeris::equatorial_position ( const Target target,
const double jde_tt )->EquatorialPosition
inlinenodiscard

Project one apparent ecliptic position to geocentric apparent RA/Dec of date.

Parameters
targetA named ephemeris target.
jde_ttFinite JDE(TT), within the target's declared provider window.
Returns
RA in [0, 360) and declination in [-90, 90] degrees, with physical distance where present.
Exceptions
std::invalid_argumentFor malformed or out-of-provider-domain input.
std::runtime_errorIf position evaluation or projection produces invalid coordinates.
Note
Longitude nutation and true obliquity use fixed IAU1980; no rate stencil or civil policy applies. Coordinate validity establishes neither accuracy nor physical plausibility at remote epochs.
See also
Jean Meeus, "Astronomical Algorithms", Second Edition, formulas (13.3), (13.4) and (22.2).

◆ is_target()

auto astro::ephemeris::is_target ( const Target target) ->bool
nodiscardconstexpr

Recognize named Target values; new distinct enumerators must also enter TARGET_FACTS.

◆ longitude_difference_events()

auto astro::ephemeris::longitude_difference_events ( const Target first,
const Target second,
const toolbox::AngleDeg target_difference,
const double start_jde_tt,
const double end_jde_tt )->std::vector< LongitudeDifferenceEvent >
inlinenodiscard

Return every event at a directed longitude difference, first minus second.

Parameters
firstThe first moving body or node.
secondA distinct supported target.
target_differenceA finite signed angle, canonicalized to (-180,180] degrees.
start_jde_ttInclusive start, within the intersection of the two longitude_rate_domain windows.
end_jde_ttExclusive end; the nonempty span must not exceed 3660 TT days.
Returns
Ordered crossings and exact numerical relative-station contacts, or an empty list for a constant miss.
Exceptions
std::invalid_argumentFor self-pairs, continuously satisfied relations or malformed/out-of-window inputs.
Note
Numerical uncertainty or work-limit exhaustion throws, never returns a prefix. The floating-point premises and numerical-contact equality rule are the same as for longitude_events.

◆ longitude_events()

auto astro::ephemeris::longitude_events ( const Target target,
const toolbox::AngleDeg target_longitude,
const double start_jde_tt,
const double end_jde_tt )->std::vector< LongitudeEvent >
inlinenodiscard

Return every crossing or exact numerical contact at a supplied tropical longitude.

Parameters
targetThe moving body or node.
target_longitudeA finite angle; whole-turn shifts denote the same level.
start_jde_ttInclusive start, within longitude_rate_domain.
end_jde_ttExclusive end; the nonempty span must not exceed 3660 TT days.
Returns
Chronologically ordered events, with no partial result on numerical or work-limit failure.
Note
Completeness is conditional on the floating-point and elementary-function contract in Longitude events. A tangent requires exact equality with the query-independent stationary output, not angular proximity.

◆ longitude_rate()

auto astro::ephemeris::longitude_rate ( const Target target,
const double jde_tt )->LongitudeRate
inlinenodiscard

Instantaneous geocentric longitude rate using the target's position model.

Parameters
jde_ttJDE(TT).
Returns
Longitude rate in the true ecliptic and equinox of date.
Exceptions
std::invalid_argumentFor invalid arguments, out-of-domain samples or inexact sample offsets.
std::runtime_errorIf numerical evaluation fails.
Note
Seven-point centered difference at 1/8 TT day spacing, sampling up to 3/8 TT day each way.
Center domains: Pluto [2409543.875, 2488069.125); nodes [2409542.875, 2488069.125); others [-1200954.625, 6104044.625).
Descending-node rates equal ascending-node rates.

◆ longitude_rate_domain()

auto astro::ephemeris::longitude_rate_domain ( const Target target) ->std::array< double, 2 >
nodiscardconstexpr

Return the half-open center domain of a target's longitude-rate operation.

Parameters
targetA named ephemeris target.
Returns
Inclusive start and exclusive end in JDE(TT), allowing the full sampled reach.
Exceptions
std::invalid_argumentIf the target is unknown.
Note
This window bounds the rate operation, not the target's position model. Exact sample-offset representability is checked separately by longitude_rate.

◆ position()

auto astro::ephemeris::position ( const Target target,
const double jde_tt )->Position
inlinenodiscard

Evaluate one target's apparent position without a rate stencil or civil policy.

Parameters
targetA named ephemeris target.
jde_ttFinite JDE(TT), within the provider window where one is declared.
Returns
Longitude in [0, 360), latitude in [-90, 90] degrees, and positive distance where physical.
Exceptions
std::invalid_argumentFor malformed or out-of-provider-domain input.
std::runtime_errorIf computation fails or produces invalid coordinates.
Note
Where no hard input interval is declared, finite-input evaluation gives no accuracy or plausibility guarantee.

◆ position_domain()

auto astro::ephemeris::position_domain ( const Target target) ->std::optional< std::array< double, 2 > >
nodiscardconstexpr

Half-open provider domain, or no hard interval; neither implies accuracy or successful evaluation.

◆ source_of()

auto astro::ephemeris::source_of ( const Target target) ->PositionSource
nodiscardconstexpr

The source of a named target's apparent position.

◆ stations()

auto astro::ephemeris::stations ( const Target target,
const double start_jde_tt,
const double end_jde_tt )->std::vector< StationEvent >
inlinenodiscard

Return every isolated zero of ephemeris::longitude_rate in a half-open TT interval.

Parameters
targetThe moving body or node.
start_jde_ttInclusive start, within longitude_rate_domain.
end_jde_ttExclusive end; the nonempty span must not exceed 3660 TT days.
Returns
Ordered stationary instants and the certified motion on both sides.
Note
The reported finite-difference rate need not be exactly zero. Unresolved isolation or refinement throws. The floating-point premises are the same as for longitude_events.

◆ target_facts()

auto astro::ephemeris::target_facts ( const Target target) ->constTargetFacts &
nodiscardconstexpr

Look up a named target; unknown values are invalid arguments.

Variable Documentation

◆ EVENT_MAXIMUM_QUERY_SPAN_TT_DAYS

double astro::ephemeris::EVENT_MAXIMUM_QUERY_SPAN_TT_DAYS
inlineconstexpr

Maximum nonempty event-query span in TT days.

Note
About ten years per request; an admission limit independent of evaluation/candidate exhaustion.

◆ TARGET_FACTS

auto astro::ephemeris::TARGET_FACTS
inlineconstexpr

Target facts in chart order; absent position domains admit finite-input evaluation, which may fail.

◆ TARGETS

auto astro::ephemeris::TARGETS
inlineconstexpr

The target roster, derived from the facts table in chart order.