0.2.0
Loading...
Searching...
No Matches
GalileoEphemeris.hpp
Go to the documentation of this file.
1// This file is part of INSTINCT, the INS Toolkit for Integrated
2// Navigation Concepts and Training by the Institute of Navigation of
3// the University of Stuttgart, Germany.
4//
5// This Source Code Form is subject to the terms of the Mozilla Public
6// License, v. 2.0. If a copy of the MPL was not distributed with this
7// file, You can obtain one at https://mozilla.org/MPL/2.0/.
8
13
14#pragma once
15
16#include <bitset>
17
19
20namespace NAV
21{
22
27class GalileoEphemeris final : public SatNavData
28{
29 public:
57
58 // #######################################################################################################
59 // Members
60 // #######################################################################################################
61
62 // ------------------------------------------ Time Parameters --------------------------------------------
63
66
69
83 size_t IODnav{};
84
91 std::array<double, 3> a{};
92
93 // --------------------------------------- Keplerian Parameters ------------------------------------------
94
95 double sqrt_A{};
96 double e{};
97 double i_0{};
98 double Omega_0{};
99 double omega{};
100 double M_0{};
101
102 // -------------------------------------- Pertubation Parameters -----------------------------------------
103
104 double delta_n{};
105 double Omega_dot{};
106 double i_dot{};
107 double Cus{};
108 double Cuc{};
109 double Cis{};
110 double Cic{};
111 double Crs{};
112 double Crc{};
113
114 // ----------------------------------------------- Other -------------------------------------------------
115
130 std::bitset<10> dataSource{};
131
142
146
149 double BGD_E1_E5a{};
152 double BGD_E1_E5b{};
153
154 // #######################################################################################################
155 // Functions
156 // #######################################################################################################
157
160 explicit GalileoEphemeris(const InsTime& toc);
161
188 const size_t& IODnav,
189 const std::array<double, 3>& a,
190 const double& sqrt_A, const double& e, const double& i_0, const double& Omega_0, const double& omega, const double& M_0,
191 const double& delta_n, const double& Omega_dot, const double& i_dot, const double& Cus, const double& Cuc,
192 const double& Cis, const double& Cic, const double& Crs, const double& Crc,
193 const std::bitset<10>& dataSource, const double& signalAccuracy, const SvHealth& svHealth,
194 const double& BGD_E1_E5a, const double& BGD_E1_E5b);
195
196#ifdef TESTING
235 GalileoEphemeris(int32_t year, int32_t month, int32_t day, int32_t hour, int32_t minute, double second, double svClockBias, double svClockDrift, double svClockDriftRate,
236 double IODnav, double Crs, double delta_n, double M_0,
237 double Cuc, double e, double Cus, double sqrt_A,
238 double Toe, double Cic, double Omega_0, double Cis,
239 double i_0, double Crc, double omega, double Omega_dot,
240 double i_dot, double dataSource, double GALWeek, double spare1,
241 double signalAccuracy, double svHealth, double BGD_E1_E5a, double BGD_E1_E5b,
242 double TransmissionTimeOfMessage, double spare2 = 0.0, double spare3 = 0.0, double spare4 = 0.0);
243#endif
244
246 ~GalileoEphemeris() final = default;
252 GalileoEphemeris& operator=(const GalileoEphemeris&) = delete;
254 GalileoEphemeris& operator=(GalileoEphemeris&&) = delete;
255
257 [[nodiscard]] double calcSatellitePositionVariance() const final;
258
263 [[nodiscard]] Corrections calcClockCorrections(const InsTime& recvTime, double dist, const Frequency& freq) const final;
264
266 [[nodiscard]] bool isHealthy() const final;
267
268 private:
274 [[nodiscard]] PosVelAccel calcSatelliteData(const InsTime& transTime, Orbit::Calc calc) const final;
275};
276
277} // namespace NAV
Satellite Navigation data (to calculate SatNavData and clock)
Frequency definition for different satellite systems.
Definition Frequency.hpp:59
Broadcasted ephemeris message data.
Definition GalileoEphemeris.hpp:28
InsTime toe
Time of Ephemeris.
Definition GalileoEphemeris.hpp:68
double calcSatellitePositionVariance() const final
Calculates the Variance of the satellite position in [m^2].
double Omega_0
Longitude of the ascending node at reference time [rad].
Definition GalileoEphemeris.hpp:98
double BGD_E1_E5b
E1-E5b Broadcast Group Delay [s].
Definition GalileoEphemeris.hpp:152
bool isHealthy() const final
Checks whether the signal is healthy.
double Omega_dot
Rate of change of right ascension [rad/s].
Definition GalileoEphemeris.hpp:105
Corrections calcClockCorrections(const InsTime &recvTime, double dist, const Frequency &freq) const final
Calculates clock bias and drift of the satellite.
double e
Eccentricity [-].
Definition GalileoEphemeris.hpp:96
std::bitset< 10 > dataSource
Data sources.
Definition GalileoEphemeris.hpp:130
double Cis
Amplitude of the sine harmonic correction term to the angle of inclination [rad].
Definition GalileoEphemeris.hpp:109
double omega
Argument of perigee [rad].
Definition GalileoEphemeris.hpp:99
double M_0
Mean anomaly at reference time [rad].
Definition GalileoEphemeris.hpp:100
double i_dot
Rate of change of inclination [rad/s].
Definition GalileoEphemeris.hpp:106
~GalileoEphemeris() final=default
Destructor.
double Cuc
Amplitude of the cosine harmonic correction term to the argument of latitude [rad].
Definition GalileoEphemeris.hpp:108
double Cus
Amplitude of the sine harmonic correction term to the argument of latitude [rad].
Definition GalileoEphemeris.hpp:107
double sqrt_A
Square root of the semi-major axis [m^1/2].
Definition GalileoEphemeris.hpp:95
GalileoEphemeris(const InsTime &toc)
Default Constructor.
double Cic
Amplitude of the cosine harmonic correction term to the angle of inclination [rad].
Definition GalileoEphemeris.hpp:110
size_t IODnav
Issue of Data of the nav batch.
Definition GalileoEphemeris.hpp:83
double Crc
Amplitude of the cosine harmonic correction term to the orbit radius [m].
Definition GalileoEphemeris.hpp:112
std::array< double, 3 > a
Definition GalileoEphemeris.hpp:91
double Crs
Amplitude of the sine harmonic correction term to the orbit radius [m].
Definition GalileoEphemeris.hpp:111
double delta_n
Mean motion difference from computed value [rad/s].
Definition GalileoEphemeris.hpp:104
InsTime toc
Time of Clock.
Definition GalileoEphemeris.hpp:65
double signalAccuracy
Definition GalileoEphemeris.hpp:141
double BGD_E1_E5a
E1-E5a Broadcast Group Delay [s].
Definition GalileoEphemeris.hpp:149
SvHealth svHealth
Signal Health.
Definition GalileoEphemeris.hpp:145
double i_0
Inclination angle at reference time [rad].
Definition GalileoEphemeris.hpp:97
GalileoEphemeris(const InsTime &toc, const InsTime &toe, const size_t &IODnav, const std::array< double, 3 > &a, const double &sqrt_A, const double &e, const double &i_0, const double &Omega_0, const double &omega, const double &M_0, const double &delta_n, const double &Omega_dot, const double &i_dot, const double &Cus, const double &Cuc, const double &Cis, const double &Cic, const double &Crs, const double &Crc, const std::bitset< 10 > &dataSource, const double &signalAccuracy, const SvHealth &svHealth, const double &BGD_E1_E5a, const double &BGD_E1_E5b)
Constructor.
The class is responsible for all time-related tasks.
Definition InsTime.hpp:667
Abstract satellite orbit information.
Definition Orbit.hpp:24
Calc
Calculation flags.
Definition Orbit.hpp:74
Satellite Navigation data (to calculate SatNavData and clock)
Definition SatNavData.hpp:26
@ GalileoEphemeris
Galileo Broadcast Ephemeris.
Definition SatNavData.hpp:32
Satellite clock corrections.
Definition Clock.hpp:28
Navigation Data Validity and Signal Health Status.
Definition GalileoEphemeris.hpp:33
SignalHealthStatus E5b_SignalHealthStatus
E5b Signal Health Status.
Definition GalileoEphemeris.hpp:54
SignalHealthStatus E1B_SignalHealthStatus
E1-B/C Signal Health Status.
Definition GalileoEphemeris.hpp:55
DataValidityStatus E5a_DataValidityStatus
E5a Data Validity Status.
Definition GalileoEphemeris.hpp:49
DataValidityStatus
Navigation Data Validity.
Definition GalileoEphemeris.hpp:36
@ NavigationDataValid
Navigation data valid.
Definition GalileoEphemeris.hpp:37
@ WorkingWithoutGuarantee
Working without guarantee.
Definition GalileoEphemeris.hpp:38
SignalHealthStatus E5a_SignalHealthStatus
E5a Signal Health Status.
Definition GalileoEphemeris.hpp:53
DataValidityStatus E5b_DataValidityStatus
E5b Data Validity Status.
Definition GalileoEphemeris.hpp:50
DataValidityStatus E1B_DataValidityStatus
E1-B Data Validity Status.
Definition GalileoEphemeris.hpp:51
SignalHealthStatus
Signal Health Status.
Definition GalileoEphemeris.hpp:42
@ SignalComponentCurrentlyInTest
Signal Component currently in Test.
Definition GalileoEphemeris.hpp:46
@ SignalOutOfService
Signal out of service.
Definition GalileoEphemeris.hpp:44
@ SignalOK
Signal OK.
Definition GalileoEphemeris.hpp:43
@ SignalWillBeOutOfService
Signal will be out of service.
Definition GalileoEphemeris.hpp:45
Satellite Position, Velocity and Acceleration.
Definition Orbit.hpp:39