[6135] | 1 | #ifndef SATOBS_H
|
---|
| 2 | #define SATOBS_H
|
---|
| 3 |
|
---|
| 4 | #include <string>
|
---|
| 5 | #include <vector>
|
---|
| 6 | #include <newmat.h>
|
---|
| 7 |
|
---|
[6455] | 8 | #include <QtCore>
|
---|
| 9 |
|
---|
[6135] | 10 | #include "bncconst.h"
|
---|
| 11 | #include "bnctime.h"
|
---|
| 12 | #include "t_prn.h"
|
---|
| 13 |
|
---|
| 14 | class t_frqObs {
|
---|
| 15 | public:
|
---|
| 16 | t_frqObs() {
|
---|
[7611] | 17 | _code = 0.0;
|
---|
| 18 | _codeValid = false;
|
---|
| 19 | _phase = 0.0;
|
---|
| 20 | _phaseValid = false;
|
---|
| 21 | _doppler = 0.0;
|
---|
| 22 | _dopplerValid = false;
|
---|
| 23 | _snr = 0.0;
|
---|
| 24 | _snrValid = false;
|
---|
| 25 | _slip = false;
|
---|
| 26 | _slipCounter = 0;
|
---|
[6135] | 27 | _biasJumpCounter = 0;
|
---|
| 28 | }
|
---|
[7611] | 29 | std::string _rnxType2ch;
|
---|
| 30 | double _code;
|
---|
| 31 | bool _codeValid;
|
---|
| 32 | double _phase;
|
---|
| 33 | bool _phaseValid;
|
---|
| 34 | double _doppler;
|
---|
| 35 | bool _dopplerValid;
|
---|
| 36 | double _snr;
|
---|
| 37 | bool _snrValid;
|
---|
| 38 | bool _slip;
|
---|
| 39 | int _slipCounter;
|
---|
[6135] | 40 | int _biasJumpCounter;
|
---|
| 41 | };
|
---|
| 42 |
|
---|
| 43 | class t_satObs {
|
---|
| 44 | public:
|
---|
| 45 | t_satObs() {}
|
---|
[6137] | 46 | t_satObs(const t_satObs& old) { // copy constructor (deep copy)
|
---|
| 47 | _staID = old._staID;
|
---|
| 48 | _prn = old._prn;
|
---|
| 49 | _time = old._time;
|
---|
| 50 | for (unsigned ii = 0; ii < old._obs.size(); ii++) {
|
---|
| 51 | _obs.push_back(new t_frqObs(*old._obs[ii]));
|
---|
| 52 | }
|
---|
| 53 | }
|
---|
[6812] | 54 | /**
|
---|
| 55 | * Destructor of satellite measurement storage class
|
---|
| 56 | */
|
---|
| 57 | ~t_satObs()
|
---|
| 58 | {
|
---|
| 59 | clear();
|
---|
| 60 | }
|
---|
[6581] | 61 |
|
---|
[6812] | 62 | /**
|
---|
| 63 | * Cleanup function resets all elements to initial state.
|
---|
| 64 | */
|
---|
| 65 | inline void clear(void)
|
---|
| 66 | {
|
---|
| 67 | for (unsigned ii = 0; ii < _obs.size(); ii++)
|
---|
| 68 | delete _obs[ii];
|
---|
| 69 | _obs.clear();
|
---|
| 70 | _obs.resize(0);
|
---|
| 71 | _time.reset();
|
---|
| 72 | _prn.clear();
|
---|
| 73 | _staID.clear();
|
---|
| 74 | }
|
---|
| 75 |
|
---|
[6137] | 76 | std::string _staID;
|
---|
[6135] | 77 | t_prn _prn;
|
---|
| 78 | bncTime _time;
|
---|
| 79 | std::vector<t_frqObs*> _obs;
|
---|
| 80 | };
|
---|
| 81 |
|
---|
| 82 | class t_orbCorr {
|
---|
| 83 | public:
|
---|
[6466] | 84 | t_orbCorr();
|
---|
[6455] | 85 | static void writeEpoch(std::ostream* out, const QList<t_orbCorr>& corrList);
|
---|
[6499] | 86 | static void readEpoch(const std::string& epoLine, std::istream& in, QList<t_orbCorr>& corrList);
|
---|
[6141] | 87 | std::string _staID;
|
---|
[6135] | 88 | t_prn _prn;
|
---|
[7169] | 89 | unsigned int _iod;
|
---|
[6135] | 90 | bncTime _time;
|
---|
[6556] | 91 | unsigned int _updateInt;
|
---|
[6135] | 92 | char _system;
|
---|
[6157] | 93 | ColumnVector _xr;
|
---|
[7611] | 94 | ColumnVector _dotXr;
|
---|
[6135] | 95 | };
|
---|
| 96 |
|
---|
| 97 | class t_clkCorr {
|
---|
| 98 | public:
|
---|
[6466] | 99 | t_clkCorr();
|
---|
[6455] | 100 | static void writeEpoch(std::ostream* out, const QList<t_clkCorr>& corrList);
|
---|
[6499] | 101 | static void readEpoch(const std::string& epoLine, std::istream& in, QList<t_clkCorr>& corrList);
|
---|
[6141] | 102 | std::string _staID;
|
---|
[6135] | 103 | t_prn _prn;
|
---|
[7169] | 104 | unsigned int _iod;
|
---|
[6135] | 105 | bncTime _time;
|
---|
[6556] | 106 | unsigned int _updateInt;
|
---|
[6135] | 107 | double _dClk;
|
---|
| 108 | double _dotDClk;
|
---|
| 109 | double _dotDotDClk;
|
---|
| 110 | };
|
---|
| 111 |
|
---|
[8483] | 112 | class t_URA {
|
---|
| 113 | public:
|
---|
| 114 | t_URA();
|
---|
| 115 | static void writeEpoch(std::ostream* out, const QList<t_URA>& corrList);
|
---|
| 116 | static void readEpoch(const std::string& epoLine, std::istream& in, QList<t_URA>& corrList);
|
---|
| 117 | std::string _staID;
|
---|
| 118 | t_prn _prn;
|
---|
| 119 | unsigned int _iod;
|
---|
| 120 | bncTime _time;
|
---|
| 121 | unsigned int _updateInt;
|
---|
| 122 | double _ura;
|
---|
| 123 | };
|
---|
| 124 |
|
---|
[6463] | 125 | class t_frqCodeBias {
|
---|
[6135] | 126 | public:
|
---|
[6463] | 127 | t_frqCodeBias() {
|
---|
[7611] | 128 | _value = 0.0;
|
---|
[6135] | 129 | }
|
---|
| 130 | std::string _rnxType2ch;
|
---|
[6463] | 131 | double _value;
|
---|
[6135] | 132 | };
|
---|
| 133 |
|
---|
[6463] | 134 | class t_satCodeBias {
|
---|
[6135] | 135 | public:
|
---|
[6475] | 136 | static void writeEpoch(std::ostream* out, const QList<t_satCodeBias>& biasList);
|
---|
[6499] | 137 | static void readEpoch(const std::string& epoLine, std::istream& in, QList<t_satCodeBias>& biasList);
|
---|
[6463] | 138 | std::string _staID;
|
---|
| 139 | t_prn _prn;
|
---|
| 140 | bncTime _time;
|
---|
[6556] | 141 | unsigned int _updateInt;
|
---|
[6463] | 142 | std::vector<t_frqCodeBias> _bias;
|
---|
[6135] | 143 | };
|
---|
| 144 |
|
---|
[6481] | 145 | class t_frqPhaseBias {
|
---|
| 146 | public:
|
---|
| 147 | t_frqPhaseBias() {
|
---|
[7611] | 148 | _value = 0.0;
|
---|
[6481] | 149 | _fixIndicator = 0;
|
---|
| 150 | _fixWideLaneIndicator = 0;
|
---|
| 151 | _jumpCounter = 0;
|
---|
| 152 | }
|
---|
| 153 | std::string _rnxType2ch;
|
---|
| 154 | double _value;
|
---|
| 155 | int _fixIndicator;
|
---|
| 156 | int _fixWideLaneIndicator;
|
---|
| 157 | int _jumpCounter;
|
---|
| 158 | };
|
---|
| 159 |
|
---|
| 160 | class t_satPhaseBias {
|
---|
| 161 | public:
|
---|
| 162 | t_satPhaseBias() {
|
---|
[6589] | 163 | _updateInt = 0;
|
---|
[6857] | 164 | _dispBiasConstistInd = 0;
|
---|
| 165 | _MWConsistInd = 0;
|
---|
[6481] | 166 | _yawDeg = 0.0;
|
---|
| 167 | _yawDegRate = 0.0;
|
---|
| 168 | }
|
---|
| 169 | static void writeEpoch(std::ostream* out, const QList<t_satPhaseBias>& biasList);
|
---|
[6499] | 170 | static void readEpoch(const std::string& epoLine, std::istream& in, QList<t_satPhaseBias>& biasList);
|
---|
[6481] | 171 | std::string _staID;
|
---|
| 172 | t_prn _prn;
|
---|
| 173 | bncTime _time;
|
---|
[6857] | 174 | unsigned int _updateInt; // not satellite specific
|
---|
| 175 | unsigned int _dispBiasConstistInd; // not satellite specific
|
---|
| 176 | unsigned int _MWConsistInd; // not satellite specific
|
---|
[6481] | 177 | double _yawDeg;
|
---|
| 178 | double _yawDegRate;
|
---|
| 179 | std::vector<t_frqPhaseBias> _bias;
|
---|
| 180 | };
|
---|
| 181 |
|
---|
[6482] | 182 | class t_vTecLayer {
|
---|
| 183 | public:
|
---|
[7611] | 184 | t_vTecLayer() {
|
---|
| 185 | _height = 0.0;
|
---|
| 186 | }
|
---|
[6482] | 187 | double _height;
|
---|
| 188 | Matrix _C;
|
---|
| 189 | Matrix _S;
|
---|
| 190 | };
|
---|
| 191 |
|
---|
| 192 | class t_vTec {
|
---|
| 193 | public:
|
---|
| 194 | static void write(std::ostream* out, const t_vTec& vTec);
|
---|
[6499] | 195 | static void read(const std::string& epoLine, std::istream& in, t_vTec& vTec);
|
---|
[6482] | 196 | std::string _staID;
|
---|
| 197 | bncTime _time;
|
---|
[6556] | 198 | unsigned int _updateInt;
|
---|
[6482] | 199 | std::vector<t_vTecLayer> _layers;
|
---|
| 200 | };
|
---|
| 201 |
|
---|
[6498] | 202 | class t_corrSSR {
|
---|
| 203 | public:
|
---|
[8483] | 204 | enum e_type {clkCorr, orbCorr, codeBias, phaseBias, vTec, URA, unknown};
|
---|
[6501] | 205 | static e_type readEpoLine(const std::string& line, bncTime& epoTime,
|
---|
[6556] | 206 | unsigned int& updateInt, int& numEntries, std::string& staID);
|
---|
[6498] | 207 | };
|
---|
| 208 |
|
---|
[6135] | 209 | #endif
|
---|