source: ntrip/trunk/BNC/src/PPP/pppSatObs.h@ 7971

Last change on this file since 7971 was 7836, checked in by stuerze, 9 years ago

minor changes

  • Property svn:keywords set to Author Date Id Rev URL;svn:eol-style=native
  • Property svn:mime-type set to text/plain
File size: 3.8 KB
Line 
1#ifndef PPPSATOBS_H
2#define PPPSATOBS_H
3
4#include <string>
5#include <map>
6#include <newmat.h>
7#include "pppInclude.h"
8#include "satObs.h"
9#include "bnctime.h"
10
11namespace BNC_PPP {
12
13class t_pppStation;
14
15class t_pppSatObs {
16 public:
17 t_pppSatObs(const t_satObs& satObs);
18 ~t_pppSatObs();
19 bool isValid() const {return _valid;};
20 bool isValid(t_lc::type tLC) const;
21 const t_prn& prn() const {return _prn;}
22 const ColumnVector& xc() const {return _xcSat;}
23 const bncTime& time() const {return _time;}
24 t_irc cmpModel(const t_pppStation* station);
25 double obsValue(t_lc::type tLC, bool* valid = 0) const;
26 double cmpValue(t_lc::type tLC) const;
27 double cmpValueForBanc(t_lc::type tLC) const;
28 double rho() const {return _model._rho;}
29 double sagnac() const {return _model._sagnac;}
30 double eleSat() const {return _model._eleSat;}
31 bool modelSet() const {return _model._set;}
32 void printModel() const;
33 void lcCoeff(t_lc::type tLC,
34 std::map<t_frequency::type, double>& codeCoeff,
35 std::map<t_frequency::type, double>& phaseCoeff) const;
36 double lambda(t_lc::type tLC) const;
37 double sigma(t_lc::type tLC) const;
38 double maxRes(t_lc::type tLC) const;
39 bool outlier() const {return _outlier;}
40 void setOutlier() {_outlier = true;}
41 void setRes(t_lc::type tLC, double res);
42 double getRes(t_lc::type tLC) const;
43
44 // RINEX
45 bool slip() const {
46 for (unsigned ii = 1; ii < t_frequency::max; ii++) {
47 if (_obs[ii] && _obs[ii]->_slip) {
48 return true;
49 }
50 }
51 return false;
52 }
53
54 // RTCM
55 int slipCounter() const {
56 int cnt = -1;
57 for (unsigned ii = 1; ii < t_frequency::max; ii++) {
58 if (_obs[ii] && _obs[ii]->_slipCounter > cnt) {
59 cnt = _obs[ii]->_slipCounter;
60 }
61 }
62 return cnt;
63 }
64
65 int biasJumpCounter() const {
66 int jmp = -1;
67 for (unsigned ii = 1; ii < t_frequency::max; ii++) {
68 if (_obs[ii] && _obs[ii]->_biasJumpCounter > jmp) {
69 jmp = _obs[ii]->_biasJumpCounter;
70 }
71 }
72 return jmp;
73 }
74
75 private:
76 class t_model {
77 public:
78 t_model() {reset();}
79 ~t_model() {}
80 void reset() {
81 _set = false;
82 _rho = 0.0;
83 _eleSat = 0.0;
84 _azSat = 0.0;
85 _recClkM = 0.0;
86 _satClkM = 0.0;
87 _sagnac = 0.0;
88 _antEcc = 0.0;
89 _tropo = 0.0;
90 _tide = 0.0;
91 _windUp = 0.0;
92 for (unsigned ii = 0; ii < t_frequency::max; ii++) {
93 _antPCO[ii] = 0.0;
94 _codeBias[ii] = 0.0;
95 _phaseBias[ii] = 0.0;
96 _ionoCodeDelay[ii] = 0.0;
97 }
98 }
99 bool _set;
100 double _rho;
101 double _eleSat;
102 double _azSat;
103 double _recClkM;
104 double _satClkM;
105 double _sagnac;
106 double _antEcc;
107 double _tropo;
108 double _tide;
109 double _windUp;
110 double _antPCO[t_frequency::max];
111 double _codeBias[t_frequency::max];
112 double _phaseBias[t_frequency::max];
113 double _ionoCodeDelay[t_frequency::max];
114 };
115
116 void prepareObs(const t_satObs& satObs);
117
118 bool _valid;
119 t_frequency::type _fType1;
120 t_frequency::type _fType2;
121 t_prn _prn;
122 bncTime _time;
123 int _channel;
124 t_frqObs* _obs[t_frequency::max];
125 ColumnVector _xcSat;
126 ColumnVector _vvSat;
127 t_model _model;
128 bool _outlier;
129 std::map<t_lc::type, double> _res;
130 double _signalPropagationTime;
131};
132
133}
134
135#endif
Note: See TracBrowser for help on using the repository browser.