Changeset 3432 in ntrip for trunk/BNC


Ignore:
Timestamp:
Sep 21, 2011, 5:35:50 PM (13 years ago)
Author:
mervart
Message:
 
Location:
trunk/BNC/combination
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/combination/bnccomb.cpp

    r3431 r3432  
    196196    delete _params[iPar-1];
    197197  }
    198   QListIterator<cmbCorr*> itCorr(_corrs);
     198  QVectorIterator<cmbCorr*> itCorr(_corrs);
    199199  while (itCorr.hasNext()) {
    200200    delete itCorr.next();
     
    281281  // ---------------------------
    282282  cmbCorr* existingCorr = 0;
    283   QListIterator<cmbCorr*> itCorr(_corrs);
     283  QVectorIterator<cmbCorr*> itCorr(_corrs);
    284284  while (itCorr.hasNext()) {
    285285    cmbCorr* hlp = itCorr.next();
     
    379379  QMap<QString, t_corr*> resCorr;
    380380
    381   QListIterator<cmbCorr*> itCorr(_corrs);
     381  QVectorIterator<cmbCorr*> itCorr(_corrs);
    382382  while (itCorr.hasNext()) {
    383383    cmbCorr* corr = itCorr.next();
     
    429429  SymmetricMatrix QQ_sav = _QQ;
    430430
    431   //  for (int ii = 1; ii < 10; ii++) {
     431  // Update and outlier detection loop
     432  // ---------------------------------
     433  for (int ii = 1; ii < 10; ii++) {
    432434    bncModel::kalman(AA, ll, PP, _QQ, dx);
    433435    ColumnVector vv = ll - AA * dx;
     
    438440    out.setRealNumberPrecision(3); 
    439441    out << _resTime.datestr().c_str() << " " << _resTime.timestr().c_str()
    440         << " Maximum Residuum " << maxRes << ' ' << endl;
    441 //        << llInfo[maxResIndex-1].AC << ' ' << llInfo[maxResIndex-1].prn;
    442 //
    443 //    if (maxRes > _MAXRES) {
    444 //      for (int iPar = 1; iPar <= _params.size(); iPar++) {
    445 //        cmbParam* pp = _params[iPar-1];
    446 //        if (pp->type == cmbParam::offACSat     &&
    447 //            pp->AC   == llInfo[maxResIndex-1].AC &&
    448 //            pp->prn  == llInfo[maxResIndex-1].prn) {
    449 //          QQ_sav.Row(iPar)    = 0.0;
    450 //          QQ_sav.Column(iPar) = 0.0;
    451 //          QQ_sav(iPar,iPar)   = pp->sig_0 * pp->sig_0;
    452 //        }
    453 //      }
    454 //
    455 //      out << "  Outlier" << endl;
    456 //      _QQ = QQ_sav;
    457 //      AA.Row(maxResIndex) = 0.0;
    458 //      ll.Row(maxResIndex) = 0.0;
    459 //    }
    460 //    else {
    461 //      out << "  OK" << endl;
    462 //      break;
    463 //    }
    464 //  }
    465 
     442        << " Maximum Residuum " << maxRes << ' '
     443        << _corrs[maxResIndex-1]->acName << ' ' << _corrs[maxResIndex-1]->prn;
     444
     445    if (maxRes > _MAXRES) {
     446      for (int iPar = 1; iPar <= _params.size(); iPar++) {
     447        cmbParam* pp = _params[iPar-1];
     448        if (pp->type == cmbParam::offACSat            &&
     449            pp->AC   == _corrs[maxResIndex-1]->acName &&
     450            pp->prn  == _corrs[maxResIndex-1]->prn) {
     451          QQ_sav.Row(iPar)    = 0.0;
     452          QQ_sav.Column(iPar) = 0.0;
     453          QQ_sav(iPar,iPar)   = pp->sig_0 * pp->sig_0;
     454        }
     455      }
     456
     457      out << "  Outlier" << endl;
     458      _QQ = QQ_sav;
     459      AA.Row(maxResIndex) = 0.0;
     460      ll.Row(maxResIndex) = 0.0;
     461    }
     462    else {
     463      out << "  OK" << endl;
     464      break;
     465    }
     466  }
     467
     468  // Update Parameter Values
     469  // -----------------------
    466470  for (int iPar = 1; iPar <= _params.size(); iPar++) {
    467471    cmbParam* pp = _params[iPar-1];
     
    482486  }
    483487
     488  // Print Results
     489  // -------------
    484490  printResults(out, resCorr);
    485491  dumpResults(resCorr);
     
    487493  emit newMessage(_log, false);
    488494
    489   QListIterator<cmbCorr*> it(_corrs);
     495  // Delete Data
     496  // -----------
     497  QVectorIterator<cmbCorr*> it(_corrs);
    490498  while (it.hasNext()) {
    491499    delete it.next();
  • trunk/BNC/combination/bnccomb.h

    r3430 r3432  
    6363  bncTime            _resTime;
    6464  QVector<cmbParam*> _params;
    65   QList<cmbCorr*>    _corrs;
     65  QVector<cmbCorr*>  _corrs;
    6666  bncRtnetDecoder*   _rtnetDecoder;
    6767  SymmetricMatrix    _QQ;
Note: See TracChangeset for help on using the changeset viewer.