source: ntrip/trunk/BNC/src/combination/bnccomb.h@ 6141

Last change on this file since 6141 was 6141, checked in by mervart, 10 years ago
File size: 3.0 KB
Line 
1
2#ifndef BNCCOMB_H
3#define BNCCOMB_H
4
5#include <fstream>
6#include <newmat.h>
7#include "bncephuser.h"
8#include "satObs.h"
9
10class bncRtnetDecoder;
11class bncSP3;
12class bncAntex;
13
14class cmbParam {
15 public:
16 enum parType {offACgps, offACglo, offACSat, clkSat};
17 cmbParam(parType type_, int index_, const QString& ac_, const QString& prn_);
18 ~cmbParam();
19 double partial(const QString& AC_, const QString& prn_);
20 QString toString() const;
21 parType type;
22 int index;
23 QString AC;
24 QString prn;
25 double xx;
26 double sig0;
27 double sigP;
28 bool epoSpec;
29 const t_eph* eph;
30};
31
32class bncComb : public bncEphUser {
33 Q_OBJECT
34
35 public:
36 bncComb();
37 virtual ~bncComb();
38 void processOrbCorrections(const QList<t_orbCorr>& orbCorrections);
39 void processClkCorrections(const QList<t_clkCorr>& clkCorrections);
40 int nStreams() const {return _ACs.size();}
41
42 public slots:
43 void slotProviderIDChanged(QString mountPoint);
44
45 signals:
46 void newMessage(QByteArray msg, bool showOnScreen);
47 void newCorrections(QStringList);
48
49 private:
50
51 enum e_method{singleEpoch, filter};
52
53 class cmbAC {
54 public:
55 cmbAC() {
56 weight = 0.0;
57 numObs = 0;
58 }
59 ~cmbAC() {}
60 QString mountPoint;
61 QString name;
62 double weight;
63 unsigned numObs;
64 };
65
66 class cmbCorr : public t_clkCorr {
67 public:
68 QString acName;
69 ColumnVector diffRao;
70 QString ID() {return acName + "_" + QString(_prn.toString().c_str());}
71 };
72
73 class cmbEpoch {
74 public:
75 cmbEpoch() {}
76 ~cmbEpoch() {
77 QVectorIterator<cmbCorr*> it(corrs);
78 while (it.hasNext()) {
79 delete it.next();
80 }
81 }
82 QVector<cmbCorr*> corrs;
83 };
84
85 void processEpoch();
86 t_irc processEpoch_filter(QTextStream& out,
87 QMap<QString, t_clkCorr*>& resCorr,
88 ColumnVector& dx);
89 t_irc processEpoch_singleEpoch(QTextStream& out,
90 QMap<QString, t_clkCorr*>& resCorr,
91 ColumnVector& dx);
92 t_irc createAmat(Matrix& AA, ColumnVector& ll, DiagonalMatrix& PP,
93 const ColumnVector& x0, QMap<QString, t_clkCorr*>& resCorr);
94 void dumpResults(const QMap<QString, t_clkCorr*>& resCorr);
95 void printResults(QTextStream& out, const QMap<QString, t_clkCorr*>& resCorr);
96 void switchToLastEph(const t_eph* lastEph, t_clkCorr* corr);
97 t_irc checkOrbits(QTextStream& out);
98
99 QVector<cmbCorr*>& corrs() {return _buffer[_resTime].corrs;}
100
101 t_irc mergeOrbitCorr(const cmbCorr* orbitCorr, cmbCorr* clkCorr);
102
103 QList<cmbAC*> _ACs;
104 bncTime _resTime;
105 QVector<cmbParam*> _params;
106 QMap<bncTime, cmbEpoch> _buffer;
107 bncRtnetDecoder* _rtnetDecoder;
108 SymmetricMatrix _QQ;
109 QByteArray _log;
110 bncAntex* _antex;
111 double _MAXRES;
112 QString _masterOrbitAC;
113 unsigned _masterMissingEpochs;
114 e_method _method;
115 bool _useGlonass;
116 int _cmbSampl;
117 QMap<QString, cmbCorr*> _orbitCorrs;
118};
119
120#endif
Note: See TracBrowser for help on using the repository browser.