Changeset 2791 in ntrip
- Timestamp:
- Dec 14, 2010, 2:06:28 PM (14 years ago)
- Location:
- trunk/BNC
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/bncmodel.cpp
r2790 r2791 296 296 297 297 QMapIterator<QString, t_satData*> it(epoData->satDataGPS); 298 int iObs = 0;298 int iObsBanc = 0; 299 299 while (it.hasNext()) { 300 ++iObs ;300 ++iObsBanc; 301 301 it.next(); 302 302 QString prn = it.key(); 303 303 t_satData* satData = it.value(); 304 BB(iObs , 1) = satData->xx(1);305 BB(iObs , 2) = satData->xx(2);306 BB(iObs , 3) = satData->xx(3);307 BB(iObs , 4) = satData->P3 + satData->clk;304 BB(iObsBanc, 1) = satData->xx(1); 305 BB(iObsBanc, 2) = satData->xx(2); 306 BB(iObsBanc, 3) = satData->xx(3); 307 BB(iObsBanc, 4) = satData->P3 + satData->clk; 308 308 } 309 309 … … 691 691 vv = ll - AA * dx; 692 692 693 ostringstream strA; 694 strA.setf(ios::fixed); 695 ColumnVector vv_code(epoData->sizeGPS()); 696 ColumnVector vv_phase(epoData->sizeGPS()); 697 ColumnVector vv_glo(epoData->sizeGlo()); 698 ColumnVector vv_gal_code(epoData->sizeGal()); 699 ColumnVector vv_gal_phase(epoData->sizeGal()); 700 701 for (unsigned iobs = 1; iobs <= epoData->sizeGPS(); ++iobs) { 702 if (_usePhase) { 703 vv_code(iobs) = vv(2*iobs-1); 704 vv_phase(iobs) = vv(2*iobs); 705 } 706 else { 707 vv_code(iobs) = vv(iobs); 708 } 709 } 710 if (_useGlonass) { 711 for (unsigned iobs = 1; iobs <= epoData->sizeGlo(); ++iobs) { 712 vv_glo(iobs) = vv(2*epoData->sizeGPS()+iobs); 713 } 714 } 715 if (_useGalileo) { 716 for (unsigned iobs = 1; iobs <= epoData->sizeGal(); ++iobs) { 717 if (_usePhase) { 718 vv_gal_code(iobs) = vv(2*iobs-1); 719 vv_gal_phase(iobs) = vv(2*iobs); 720 } 721 else { 722 vv_gal_code(iobs) = vv(iobs); 723 } 724 } 725 } 726 727 strA << "residuals code " << setw(8) << setprecision(3) << vv_code.t(); 728 if (_usePhase) { 729 strA << "residuals phase " << setw(8) << setprecision(3) << vv_phase.t(); 730 } 731 if (_useGlonass) { 732 strA << "residuals glo " << setw(8) << setprecision(3) << vv_glo.t(); 733 } 734 if (_useGalileo) { 735 strA << "Galileo code " << setw(8) << setprecision(3) << vv_gal_code.t(); 736 if (_usePhase) { 737 strA << "Galileo phase " << setw(8) << setprecision(3) << vv_gal_phase.t(); 738 } 739 } 740 _log += strA.str().c_str(); 693 // Print Residuals 694 // --------------- 695 if (true) { 696 ostringstream str; 697 str.setf(ios::fixed); 698 699 QMapIterator<QString, t_satData*> itGPS(epoData->satDataGPS); 700 while (itGPS.hasNext()) { 701 itGPS.next(); 702 t_satData* satData = itGPS.value(); 703 printRes(vv, str, satData); 704 } 705 QMapIterator<QString, t_satData*> itGlo(epoData->satDataGlo); 706 while (itGlo.hasNext()) { 707 itGlo.next(); 708 t_satData* satData = itGlo.value(); 709 printRes(vv, str, satData); 710 } 711 QMapIterator<QString, t_satData*> itGal(epoData->satDataGal); 712 while (itGal.hasNext()) { 713 itGal.next(); 714 t_satData* satData = itGal.value(); 715 printRes(vv, str, satData); 716 } 717 _log += str.str().c_str(); 718 } 741 719 742 720 } while (outlierDetection(QQsav, vv, epoData->satDataGPS, … … 1297 1275 Matrix& AA, ColumnVector& ll, DiagonalMatrix& PP) { 1298 1276 1277 // Code Observations 1278 // ----------------- 1299 1279 if (satData->system() != 'R') { 1300 1280 ++iObs; … … 1304 1284 AA(iObs, iPar) = _params[iPar-1]->partial(satData, false); 1305 1285 } 1286 satData->indexCode = iObs; 1306 1287 } 1307 1288 1289 // Phase Observations 1290 // ------------------ 1308 1291 if (_usePhase) { 1309 1292 ++iObs; … … 1317 1300 AA(iObs, iPar) = _params[iPar-1]->partial(satData, true); 1318 1301 } 1319 } 1320 } 1302 satData->indexPhase = iObs; 1303 } 1304 } 1305 1306 // 1307 /////////////////////////////////////////////////////////////////////////// 1308 void bncModel::printRes(const ColumnVector& vv, 1309 ostringstream& str, t_satData* satData) { 1310 if (satData->indexCode) { 1311 str << "RES P3 " << satData->prn.toAscii().data() << " " 1312 << setw(9) << setprecision(4) << vv(satData->indexCode) << endl; 1313 } 1314 if (satData->indexPhase) { 1315 str << "RES L3 " << satData->prn.toAscii().data() << " " 1316 << setw(9) << setprecision(4) << vv(satData->indexPhase) << endl; 1317 } 1318 } -
trunk/BNC/bncmodel.h
r2790 r2791 92 92 void addObs(unsigned& iObs, t_satData* satData, 93 93 Matrix& AA, ColumnVector& ll, DiagonalMatrix& PP); 94 void printRes(const ColumnVector& vv, 95 std::ostringstream& str, t_satData* satData); 94 96 double cmpValue(t_satData* satData, bool phase); 95 97 double delay_saast(double Ele); -
trunk/BNC/bncpppclient.h
r2788 r2791 39 39 class t_satData { 40 40 public: 41 t_satData() { 42 indexCode = 0; 43 indexPhase = 0; 44 } 45 ~t_satData() {} 41 46 QString prn; 42 47 double P1; … … 56 61 bool slipFlag; 57 62 double lambda3; 63 unsigned indexCode; 64 unsigned indexPhase; 58 65 char system() const {return prn.toAscii()[0];} 59 66 };
Note:
See TracChangeset
for help on using the changeset viewer.