Cached precise-ephemeris interpolant and batched satellite-state queries.
A parsed SP3 product or a sample-built precise source can be converted into a persistent interpolant handle. The handle copies the interpolation nodes once, then serves repeated GNSS satellite-state queries without re-gathering the nodes from the source product.
State batches return satellite positions in ITRF/IGS ECEF metres and satellite clocks in seconds. Query epochs are seconds since J2000 in the source's own time scale.
Summary
Functions
Build a cached interpolant from a sample-backed precise ephemeris source.
Build a cached interpolant directly from precise ephemeris samples.
Build a cached interpolant from a parsed SP3 product.
Return the satellite ids available in the cached interpolant.
Evaluate states for parallel satellite and epoch arrays.
Evaluate states for many satellites at one shared J2000-second epoch.
Return the source time-scale abbreviation, such as "GPST".
Types
@type source() :: Sidereon.GNSS.SP3.t() | Sidereon.GNSS.PreciseEphemeris.t() | t()
Functions
@spec from_precise_ephemeris_samples(Sidereon.GNSS.PreciseEphemeris.t()) :: {:ok, t()} | {:error, term()}
Build a cached interpolant from a sample-backed precise ephemeris source.
This reuses the already validated Sidereon.GNSS.PreciseEphemeris handle and
copies its prepared interpolation nodes.
@spec from_samples([Sidereon.GNSS.PreciseEphemerisSample.t()]) :: {:ok, t()} | {:error, term()}
Build a cached interpolant directly from precise ephemeris samples.
Samples are Sidereon.GNSS.PreciseEphemerisSample structs. They must use one
time scale, be grouped into at least two strictly increasing epochs per
satellite, and carry finite positions and clocks. Validation reasons match
Sidereon.GNSS.PreciseEphemeris.from_samples/1.
@spec from_sp3(Sidereon.GNSS.SP3.t()) :: {:ok, t()} | {:error, term()}
Build a cached interpolant from a parsed SP3 product.
The SP3 product is already parsed and held by the BEAM. This function copies
its interpolation nodes into a second read-only handle. Returns
{:ok, %Sidereon.GNSS.PreciseEphemeris.Interpolant{}}.
Return the satellite ids available in the cached interpolant.
The ids are canonical SP3/RINEX tokens such as "G01" and are sorted in core
satellite order.
@spec states_at_j2000_s(source(), [String.t()], [number()]) :: {:ok, Sidereon.GNSS.PreciseEphemeris.StateBatch.t()} | {:error, term()}
Evaluate states for parallel satellite and epoch arrays.
satellites[i] is evaluated at epochs_j2000_s[i]. The lists must have the
same length. The returned StateBatch is index-aligned with the inputs and
preserves each scalar result in batch.results.
Return the source time-scale abbreviation, such as "GPST".