pub struct SP3 {Show 17 fields
pub version: Version,
pub data_type: DataType,
pub coord_system: String,
pub orbit_type: OrbitType,
pub agency: String,
pub constellation: Constellation,
pub time_system: TimeScale,
pub week_counter: (u32, f64),
pub mjd_start: (u32, f64),
pub epoch: Vec<Epoch>,
pub epoch_interval: Duration,
pub sv: Vec<Sv>,
pub position: BTreeMap<Epoch, BTreeMap<Sv, (f64, f64, f64)>>,
pub clock: BTreeMap<Epoch, BTreeMap<Sv, f64>>,
pub velocities: BTreeMap<Epoch, BTreeMap<Sv, (f64, f64, f64)>>,
pub clock_rate: BTreeMap<Epoch, BTreeMap<Sv, f64>>,
pub comments: Vec<String>,
}Fields§
§version: VersionFile revision
data_type: DataTypeData Type used in this file. If DataType == Velocity, you know that velocities record will be provided. Otherwise, that is not garanteed and kind of rare.
coord_system: StringCoordinates system used in this file.
orbit_type: OrbitTypeType of Orbit contained in this file.
agency: StringAgency providing this data
constellation: ConstellationType of constellations encountered in this file. For example “GPS” means only GPS vehicles are present.
time_system: TimeScaleFile original time system, either UTC or time source from which we converted to UTC.
week_counter: (u32, f64)Initial week counter, in time_system
mjd_start: (u32, f64)Initial MJD, in time_system
epoch: Vec<Epoch>Epochs where at least one position
or one clock data is provided. Epochs are expressed UTC time,
either directly if provided as such, or internally converted.
epoch_interval: DurationReturns sampling interval, ie., time between successive Epochs.
sv: Vec<Sv>Satellite Vehicles
position: BTreeMap<Epoch, BTreeMap<Sv, (f64, f64, f64)>>Positions expressed in km, with 1mm precision, per Epoch and Sv.
clock: BTreeMap<Epoch, BTreeMap<Sv, f64>>Clock estimates in microseconds, with 1E-12 precision per Epoch and Sv.
velocities: BTreeMap<Epoch, BTreeMap<Sv, (f64, f64, f64)>>Velocities (Position derivative estimates) in 10^-1 m/s with 0.1 um/s precision.
clock_rate: BTreeMap<Epoch, BTreeMap<Sv, f64>>Rate of change of clock correction in 0.1 ns/s with 0.1 fs/s precision.
comments: Vec<String>File header comments, stored as is.
Implementations§
source§impl SP3
impl SP3
sourcepub fn from_file(path: &str) -> Result<Self, Errors>
pub fn from_file(path: &str) -> Result<Self, Errors>
Parses given SP3 file, with possible seamless .gz decompression, if compiled with the “flate2” feature.
sourcepub fn epoch(&self) -> impl Iterator<Item = Epoch> + '_
pub fn epoch(&self) -> impl Iterator<Item = Epoch> + '_
Returns a unique Epoch iterator where either Position or Clock data is provided.
sourcepub fn first_epoch(&self) -> Option<Epoch>
pub fn first_epoch(&self) -> Option<Epoch>
Returns first epoch
sourcepub fn last_epoch(&self) -> Option<Epoch>
pub fn last_epoch(&self) -> Option<Epoch>
Returns last epoch
sourcepub fn sv_position(
&self
) -> impl Iterator<Item = (Epoch, Sv, (f64, f64, f64))> + '_
pub fn sv_position( &self ) -> impl Iterator<Item = (Epoch, Sv, (f64, f64, f64))> + '_
Returns an Iterator over Sv position estimates, in km with 1mm precision.
sourcepub fn sv_velocities(
&self
) -> impl Iterator<Item = (Epoch, Sv, (f64, f64, f64))> + '_
pub fn sv_velocities( &self ) -> impl Iterator<Item = (Epoch, Sv, (f64, f64, f64))> + '_
Returns an Iterator over Sv velocities estimates, in 10^-1 m/s with 0.1 um/s precision.
sourcepub fn sv_clock(&self) -> impl Iterator<Item = (Epoch, Sv, f64)> + '_
pub fn sv_clock(&self) -> impl Iterator<Item = (Epoch, Sv, f64)> + '_
Returns an Iterator over Clock error estimates, in microseconds with 1E-12 precision.
sourcepub fn sv_clock_change(&self) -> impl Iterator<Item = (Epoch, Sv, f64)> + '_
pub fn sv_clock_change(&self) -> impl Iterator<Item = (Epoch, Sv, f64)> + '_
Returns an Iterator over Clock rate of change estimates, in 0.1 ns/s with 0.1 fs/s precision.
sourcepub fn comments(&self) -> impl Iterator<Item = &String> + '_
pub fn comments(&self) -> impl Iterator<Item = &String> + '_
Returns an Iterator over [Comments] contained in this file
sourcepub fn sv_position_interpolate(
&self,
sv: Sv,
t: Epoch,
order: usize
) -> Option<(f64, f64, f64)>
pub fn sv_position_interpolate( &self, sv: Sv, t: Epoch, order: usize ) -> Option<(f64, f64, f64)>
Interpolate SV position, expressed in kilometers ECEF at desired Epoch t.
For typical SP3 files with 15’ epoch interval,
an interpolation order of at least 11 is recommended to preserve
data precision.
For an evenly spaced SP3 file, operation is feasible on Epochs
contained in the interval ](N +1)/2 * τ; T - (N +1)/2 * τ],
where N is the interpolation order, τ the epoch interval and T
the last Epoch in this file. See [Bibliography::Japhet2021].