Index: trunk/BNC/src/PPP/pppEphPool.cpp
===================================================================
--- trunk/BNC/src/PPP/pppEphPool.cpp	(revision 7203)
+++ 	(revision )
@@ -1,132 +1,0 @@
-/* -------------------------------------------------------------------------
- * BKG NTRIP Client
- * -------------------------------------------------------------------------
- *
- * Class:      t_pppEphPool
- *
- * Purpose:    Buffer with satellite ephemerides
- *
- * Author:     L. Mervart
- *
- * Created:    29-Jul-2014
- *
- * Changes:    
- *
- * -----------------------------------------------------------------------*/
-
-#include <iostream>
-#include "pppEphPool.h"
-#include "pppInclude.h"
-#include "pppClient.h"
-
-using namespace BNC_PPP;
-using namespace std;
-
-//
-/////////////////////////////////////////////////////////////////////////////
-void t_pppEphPool::putEphemeris(t_eph* eph) {
-  if (eph && eph->checkState() != t_eph::bad) {
-    _satEphPool[eph->prn().toInt()].putEphemeris(_maxQueueSize, eph);
-  }
-  else {
-    delete eph;
-  }
-}
-
-//
-/////////////////////////////////////////////////////////////////////////////
-void t_pppEphPool::putOrbCorrection(t_orbCorr* corr) {
-  if (corr) {
-    _satEphPool[corr->_prn.toInt()].putOrbCorrection(corr);
-  }
-}
-
-//
-/////////////////////////////////////////////////////////////////////////////
-void t_pppEphPool::putClkCorrection(t_clkCorr* corr) {
-  if (corr) {
-    _satEphPool[corr->_prn.toInt()].putClkCorrection(corr);
-  }
-}
-
-//
-/////////////////////////////////////////////////////////////////////////////
-t_irc t_pppEphPool::getCrd(const t_prn& prn, const bncTime& tt, 
-                             ColumnVector& xc, ColumnVector& vv) const {
-  return _satEphPool[prn.toInt()].getCrd(tt, xc, vv);
-}
-
-//
-/////////////////////////////////////////////////////////////////////////////
-int t_pppEphPool::getChannel(const t_prn& prn) const {
-  return _satEphPool[prn.toInt()].getChannel();
-}
-
-//
-/////////////////////////////////////////////////////////////////////////////
-void t_pppEphPool::t_satEphPool::putEphemeris(unsigned maxQueueSize, t_eph* eph) {
-  if (_ephs.empty() || eph->isNewerThan(_ephs.front())) {
-    _ephs.push_front(eph);
-    if (maxQueueSize > 0 && _ephs.size() > maxQueueSize) {
-      delete _ephs.back();
-      _ephs.pop_back();
-    }
-  }
-  else {
-    delete eph;
-  }
-}
-
-//
-/////////////////////////////////////////////////////////////////////////////
-void t_pppEphPool::t_satEphPool::putOrbCorrection(t_orbCorr* corr) {
-  for (unsigned ii = 0; ii < _ephs.size(); ii++) {
-    t_eph* eph = _ephs[ii];
-    if (eph->IOD() == corr->_iod) {
-      eph->setOrbCorr(corr); 
-      return;
-    }
-  }
-  delete corr;
-}
-
-//
-/////////////////////////////////////////////////////////////////////////////
-void t_pppEphPool::t_satEphPool::putClkCorrection(t_clkCorr* corr) {
-  for (unsigned ii = 0; ii < _ephs.size(); ii++) {
-    t_eph* eph = _ephs[ii];
-    if (eph->IOD() == corr->_iod) {
-      eph->setClkCorr(corr); 
-    }
-  }
-  delete corr;
-}
-
-//
-/////////////////////////////////////////////////////////////////////////////
-t_irc t_pppEphPool::t_satEphPool::getCrd(const bncTime& tt, ColumnVector& xc,
-                                           ColumnVector& vv) const {
-  for (unsigned ii = 0; ii < _ephs.size(); ii++) {
-    t_eph* eph = _ephs[ii];
-    t_irc irc = eph->getCrd(tt, xc, vv, OPT->useOrbClkCorr());
-    if (irc == success) {
-      if (eph->prn().system() == 'R') {
-        double age = tt - eph->TOC();
-        if (fabs(age) > 3600.0) {
-          continue;
-        }
-      }
-      return irc;
-    }
-  }
-  return failure;
-}
-
-//
-/////////////////////////////////////////////////////////////////////////////
-int t_pppEphPool::t_satEphPool::getChannel() const {
-  if (_ephs.size() > 0) {
-    return _ephs[0]->slotNum();
-  }
-  return 0;
-}
Index: trunk/BNC/src/PPP/pppEphPool.h
===================================================================
--- trunk/BNC/src/PPP/pppEphPool.h	(revision 7203)
+++ 	(revision )
@@ -1,56 +1,0 @@
-#ifndef EPHPOOL_H
-#define EPHPOOL_H
-
-#include <deque>
-#include "pppInclude.h"
-#include "bnctime.h"
-#include "ephemeris.h"
-
-namespace BNC_PPP {
-
-class t_pppEphPool {
- public:
-  t_pppEphPool(unsigned maxQueueSize = 3) {
-    _maxQueueSize = maxQueueSize;
-  }
-  ~t_pppEphPool() {}; 
-
-  void putEphemeris(t_eph* eph);
-  void putOrbCorrection(t_orbCorr* corr);
-  void putClkCorrection(t_clkCorr* corr);
-
-  t_irc getCrd(const t_prn& prn, const bncTime& tt, 
-                    ColumnVector& xc, ColumnVector& vv) const;
-
-  int getChannel(const t_prn& prn) const;
-
-  std::deque<t_eph*>& ephs(t_prn prn) {
-    return _satEphPool[prn]._ephs;
-  }
-
- private:
-
-  class t_satEphPool {
-   public:
-    t_satEphPool() {};
-    ~t_satEphPool() {
-      for (unsigned ii = 0; ii < _ephs.size(); ii++) {
-        delete _ephs[ii];
-      }
-    }
-    void putEphemeris(unsigned maxQueueSize, t_eph* eph);
-    void putOrbCorrection(t_orbCorr* corr);
-    void putClkCorrection(t_clkCorr* corr);
-    t_irc getCrd(const bncTime& tt, 
-                      ColumnVector& xc, ColumnVector& vv) const;
-    int getChannel() const;
-    std::deque<t_eph*> _ephs;
-  };
-
-  t_satEphPool _satEphPool[t_prn::MAXPRN+1];
-  unsigned     _maxQueueSize;
-};
-
-}
-
-#endif
Index: trunk/BNC/src/PPP/pppObsPool.cpp
===================================================================
--- trunk/BNC/src/PPP/pppObsPool.cpp	(revision 7203)
+++ 	(revision )
@@ -1,77 +1,0 @@
-/* -------------------------------------------------------------------------
- * BKG NTRIP Client
- * -------------------------------------------------------------------------
- *
- * Class:      t_pppObsPool
- *
- * Purpose:    Buffer with observations
- *
- * Author:     L. Mervart
- *
- * Created:    29-Jul-2014
- *
- * Changes:    
- *
- * -----------------------------------------------------------------------*/
-
-#include "pppObsPool.h"
-
-using namespace BNC_PPP;
-using namespace std;
-
-// Constructor
-/////////////////////////////////////////////////////////////////////////////
-t_pppObsPool::t_epoch::t_epoch(const bncTime& epoTime, vector<t_pppSatObs*>& obsVector) {
-  _epoTime   = epoTime;
-  for (unsigned ii = 0; ii < obsVector.size(); ii++) {
-    _obsVector.push_back(obsVector[ii]);
-  }
-  obsVector.clear();
-}
-
-// Destructor
-/////////////////////////////////////////////////////////////////////////////
-t_pppObsPool::t_epoch::~t_epoch() {
-  for (unsigned ii = 0; ii < _obsVector.size(); ii++) {
-    delete _obsVector[ii];
-  }
-}
-
-// Constructor
-/////////////////////////////////////////////////////////////////////////////
-t_pppObsPool::t_pppObsPool() {
-  for (unsigned ii = 0; ii <= t_prn::MAXPRN; ii++) {
-    _satCodeBiases[ii] = 0;
-  }
-}
-
-// Destructor
-/////////////////////////////////////////////////////////////////////////////
-t_pppObsPool::~t_pppObsPool() {
-  for (unsigned ii = 0; ii <= t_prn::MAXPRN; ii++) {
-    delete _satCodeBiases[ii];
-  }
-  while (_epochs.size() > 0) {
-    delete _epochs.front();
-    _epochs.pop_front();
-  }
-}
-
-//
-/////////////////////////////////////////////////////////////////////////////
-void t_pppObsPool::putCodeBias(t_satCodeBias* satCodeBias) {
-  int iPrn = satCodeBias->_prn.toInt();
-  delete _satCodeBiases[iPrn];
-  _satCodeBiases[iPrn] = satCodeBias;
-}
-
-//
-/////////////////////////////////////////////////////////////////////////////
-void t_pppObsPool::putEpoch(const bncTime& epoTime, vector<t_pppSatObs*>& obsVector) {
-  const unsigned MAXSIZE = 2;
-  _epochs.push_back(new t_epoch(epoTime, obsVector));
-  if (_epochs.size() > MAXSIZE) {
-    delete _epochs.front();
-    _epochs.pop_front();
-  }
-}
Index: trunk/BNC/src/PPP/pppObsPool.h
===================================================================
--- trunk/BNC/src/PPP/pppObsPool.h	(revision 7203)
+++ 	(revision )
@@ -1,52 +1,0 @@
-#ifndef OBSPOOL_H
-#define OBSPOOL_H
-
-#include <vector>
-#include <deque>
-#include "pppSatObs.h"
-#include "bnctime.h"
-
-namespace BNC_PPP {
-
-class t_pppObsPool {
- public: 
-
-  class t_epoch {
-   public:
-    t_epoch(const bncTime& epoTime, std::vector<t_pppSatObs*>& obsVector);
-    ~t_epoch();
-    std::vector<t_pppSatObs*>& obsVector() {return _obsVector;}
-    const std::vector<t_pppSatObs*>& obsVector() const {return _obsVector;}
-    const bncTime& epoTime() const {return _epoTime;}
-   private:
-    bncTime                _epoTime;
-    std::vector<t_pppSatObs*> _obsVector;
-  };
-
-  t_pppObsPool();
-  ~t_pppObsPool();
-  void putCodeBias(t_satCodeBias* satCodeBias);
-
-  void putEpoch(const bncTime& epoTime, std::vector<t_pppSatObs*>& obsVector);
-
-  const t_satCodeBias* satCodeBias(const t_prn& prn) const {  
-    return _satCodeBiases[prn.toInt()];
-  }
-
-  t_epoch* lastEpoch() {
-    if (_epochs.size()) {
-      return _epochs.back();
-    }
-    else {
-      return 0;
-    }
-  }
-
- private:
-  t_satCodeBias*       _satCodeBiases[t_prn::MAXPRN+1];
-  std::deque<t_epoch*> _epochs;
-};
-
-}
-
-#endif
Index: trunk/BNC/src/PPP/pppParlist.cpp
===================================================================
--- trunk/BNC/src/PPP/pppParlist.cpp	(revision 7203)
+++ 	(revision )
@@ -1,415 +1,0 @@
-/* -------------------------------------------------------------------------
- * BKG NTRIP Client
- * -------------------------------------------------------------------------
- *
- * Class:      t_pppParlist
- *
- * Purpose:    List of estimated parameters
- *
- * Author:     L. Mervart
- *
- * Created:    29-Jul-2014
- *
- * Changes:
- *
- * -----------------------------------------------------------------------*/
-
-#include <cmath>
-#include <iostream>
-#include <sstream>
-#include <iomanip>
-#include <algorithm>
-#include <newmatio.h>
-
-#include "pppParlist.h"
-#include "pppSatObs.h"
-#include "pppStation.h"
-#include "bncutils.h"
-#include "bncconst.h"
-#include "pppClient.h"
-
-using namespace BNC_PPP;
-using namespace std;
-
-// Constructor
-////////////////////////////////////////////////////////////////////////////
-t_pppParam::t_pppParam(e_type type, const t_prn& prn, t_lc::type tLC,
-                 const vector<t_pppSatObs*>* obsVector) {
-
-  _type     = type;
-  _prn      = prn;
-  _tLC      = tLC;
-  _x0       = 0.0;
-  _indexOld = -1;
-  _indexNew = -1;
-  _noise    = 0.0;
-  _ambInfo  = 0;
-
-  switch (_type) {
-   case crdX:
-     _epoSpec = false;
-     _sigma0  = OPT->_aprSigCrd[0];
-     _noise   = OPT->_noiseCrd[0];
-     break;
-   case crdY:
-     _epoSpec = false;
-     _sigma0  = OPT->_aprSigCrd[1];
-     _noise   = OPT->_noiseCrd[1];
-     break;
-   case crdZ:
-     _epoSpec = false;
-     _sigma0  = OPT->_aprSigCrd[2];
-     _noise   = OPT->_noiseCrd[2];
-     break;
-   case clkR:
-     _epoSpec = true;
-     _sigma0  = OPT->_noiseClk;
-     break;
-   case amb:
-     _epoSpec = false;
-     _sigma0  = OPT->_aprSigAmb;
-     _ambInfo = new t_ambInfo();
-     if (obsVector) {
-       for (unsigned ii = 0; ii < obsVector->size(); ii++) {
-         const t_pppSatObs* obs = obsVector->at(ii);
-         if (obs->prn() == _prn) {
-           double offGG = 0;
-           if (_prn.system() == 'R' && tLC != t_lc::MW) {
-             offGG = PPP_CLIENT->offGG();
-           }
-           _x0 = floor((obs->obsValue(tLC) - offGG - obs->cmpValue(tLC)) / obs->lambda(tLC) + 0.5);
-           break;
-         }
-       }
-     }
-     break;
-   case offGG:
-     _epoSpec = true;
-     _sigma0  = 1000.0;
-     _x0      = PPP_CLIENT->offGG();
-     break;
-   case trp:
-     _epoSpec = false;
-     _sigma0  = OPT->_aprSigTrp;
-     _noise   = OPT->_noiseTrp;
-     break;
-  }
-}
-
-// Destructor
-////////////////////////////////////////////////////////////////////////////
-t_pppParam::~t_pppParam() {
-  delete _ambInfo;
-}
-
-//
-////////////////////////////////////////////////////////////////////////////
-double t_pppParam::partial(const bncTime& /* epoTime */, const t_pppSatObs* obs,
-                        const t_lc::type& tLC) const {
-
-  // Special Case - Melbourne-Wuebbena
-  // ---------------------------------
-  if (tLC == t_lc::MW && _type != amb) {
-    return 0.0;
-  }
-
-  const t_pppStation* sta  = PPP_CLIENT->staRover();
-  ColumnVector     rhoV = sta->xyzApr() - obs->xc().Rows(1,3);
-
-  switch (_type) {
-  case crdX:
-    return (sta->xyzApr()[0] - obs->xc()[0]) / rhoV.norm_Frobenius();
-  case crdY:
-    return (sta->xyzApr()[1] - obs->xc()[1]) / rhoV.norm_Frobenius();
-  case crdZ:
-    return (sta->xyzApr()[2] - obs->xc()[2]) / rhoV.norm_Frobenius();
-  case clkR:
-    return 1.0;
-  case offGG:
-    return (obs->prn().system() == 'R') ? 1.0 : 0.0;
-  case amb:
-    if (obs->prn() == _prn) {
-      if      (tLC == _tLC) {
-        return (obs->lambda(tLC));
-      }
-      else if (tLC == t_lc::lIF && _tLC == t_lc::MW) {
-        return obs->lambda(t_lc::lIF) * obs->lambda(t_lc::MW) / obs->lambda(t_lc::l2);
-      }
-      else {
-        map<t_frequency::type, double> codeCoeff;
-        map<t_frequency::type, double> phaseCoeff;
-        obs->lcCoeff(tLC, codeCoeff, phaseCoeff);
-        if      (_tLC == t_lc::l1) {
-          return obs->lambda(t_lc::l1) * phaseCoeff[t_lc::toFreq(obs->prn().system(),t_lc::l1)];
-        }
-        else if (_tLC == t_lc::l2) {
-          return obs->lambda(t_lc::l2) * phaseCoeff[t_lc::toFreq(obs->prn().system(),t_lc::l2)];
-        }
-      }
-    }
-    return 0.0;
-  case trp:
-    return 1.0 / sin(obs->eleSat());
-  }
-
-  return 0.0;
-}
-
-//
-////////////////////////////////////////////////////////////////////////////
-string t_pppParam::toString() const {
-  stringstream ss;
-  switch (_type) {
-  case crdX:
-    ss << "CRD_X";
-    break;
-  case crdY:
-    ss << "CRD_Y";
-    break;
-  case crdZ:
-    ss << "CRD_Z";
-    break;
-  case clkR:
-    ss << "CLK        ";
-    break;
-  case amb:
-    ss << "AMB " << left << setw(3) << t_lc::toString(_tLC) << right << ' ' << _prn.toString();
-    break;
-  case offGG:
-    ss << "OGG        ";
-    break;
-  case trp:
-    ss << "TRP        ";
-    break;
-  }
-  return ss.str();
-}
-
-// Constructor
-////////////////////////////////////////////////////////////////////////////
-t_pppParlist::t_pppParlist() {
-}
-
-// Destructor
-////////////////////////////////////////////////////////////////////////////
-t_pppParlist::~t_pppParlist() {
-  for (unsigned ii = 0; ii < _params.size(); ii++) {
-    delete _params[ii];
-  }
-}
-
-//
-////////////////////////////////////////////////////////////////////////////
-t_irc t_pppParlist::set(const bncTime& epoTime, const std::vector<t_pppSatObs*>& obsVector) {
-
-  // Remove some Parameters
-  // ----------------------
-  vector<t_pppParam*>::iterator it = _params.begin();
-  while (it != _params.end()) {
-    t_pppParam* par = *it;
-
-    bool remove = false;
-
-    if      (par->epoSpec()) {
-      remove = true;
-    }
-
-    else if (par->type() == t_pppParam::amb) {
-      if (par->lastObsTime().valid() && (epoTime - par->lastObsTime() > 120.0)) {
-        remove = true;
-      }
-    }
-
-    else if (par->type() == t_pppParam::amb) {
-      if (par->lastObsTime().valid() && (epoTime - par->lastObsTime() > 3600.0)) {
-        remove = true;
-      }
-    }
-
-    if (remove) {
-      delete par;
-      it = _params.erase(it);
-    }
-    else {
-      ++it;
-    }
-  }
-
-  // Check whether parameters have observations
-  // ------------------------------------------
-  for (unsigned ii = 0; ii < _params.size(); ii++) {
-    t_pppParam* par = _params[ii];
-    if (par->prn() == 0) {
-      par->setLastObsTime(epoTime);
-      if (par->firstObsTime().undef()) {
-        par->setFirstObsTime(epoTime);
-      }
-    }
-    else {
-      for (unsigned jj = 0; jj < obsVector.size(); jj++) {
-        const t_pppSatObs* satObs = obsVector[jj];
-        if (satObs->prn() == par->prn()) {
-          par->setLastObsTime(epoTime);
-          if (par->firstObsTime().undef()) {
-            par->setFirstObsTime(epoTime);
-          }
-          break;
-        }
-      }
-    }
-  }
-
-  // Required Set of Parameters
-  // --------------------------
-  vector<t_pppParam*> required;
-
-  // Coordinates
-  // -----------
-  required.push_back(new t_pppParam(t_pppParam::crdX, t_prn(), t_lc::dummy));
-  required.push_back(new t_pppParam(t_pppParam::crdY, t_prn(), t_lc::dummy));
-  required.push_back(new t_pppParam(t_pppParam::crdZ, t_prn(), t_lc::dummy));
-
-  // Receiver Clock
-  // --------------
-  required.push_back(new t_pppParam(t_pppParam::clkR, t_prn(), t_lc::dummy));
-
-  // GPS-Glonass Clock Offset
-  // ------------------------
-  if (OPT->useSystem('R')) {
-    required.push_back(new t_pppParam(t_pppParam::offGG, t_prn(), t_lc::dummy));
-  }
-
-  // Troposphere
-  // -----------
-  if (OPT->estTrp()) {
-    required.push_back(new t_pppParam(t_pppParam::trp, t_prn(), t_lc::dummy));
-  }
-
-  // Ambiguities
-  // -----------
-  for (unsigned jj = 0; jj < obsVector.size(); jj++) {
-    const t_pppSatObs*        satObs = obsVector[jj];
-    const vector<t_lc::type>& ambLCs = OPT->ambLCs(satObs->prn().system());
-    for (unsigned ii = 0; ii < ambLCs.size(); ii++) {
-      required.push_back(new t_pppParam(t_pppParam::amb, satObs->prn(), ambLCs[ii], &obsVector));
-    }
-  }
-
-  // Check if all required parameters are present
-  // --------------------------------------------
-  for (unsigned ii = 0; ii < required.size(); ii++) {
-    t_pppParam* parReq = required[ii];
-
-    bool found = false;
-    for (unsigned jj = 0; jj < _params.size(); jj++) {
-      t_pppParam* parOld = _params[jj];
-      if (parOld->isEqual(parReq)) {
-        found = true;
-        break;
-      }
-    }
-    if (found) {
-      delete parReq;
-    }
-    else {
-      _params.push_back(parReq);
-    }
-  }
-
-  // Set Parameter Indices
-  // ---------------------
-  sort(_params.begin(), _params.end(), t_pppParam::sortFunction);
-
-  for (unsigned ii = 0; ii < _params.size(); ii++) {
-    t_pppParam* par = _params[ii];
-    par->setIndex(ii);
-    for (unsigned jj = 0; jj < obsVector.size(); jj++) {
-      const t_pppSatObs* satObs = obsVector[jj];
-      if (satObs->prn() == par->prn()) {
-        par->setAmbEleSat(satObs->eleSat());
-        par->stepAmbNumEpo();
-      }
-    }
-  }
-
-  return success;
-}
-
-//
-////////////////////////////////////////////////////////////////////////////
-void t_pppParlist::printResult(const bncTime& epoTime, const SymmetricMatrix& QQ,
-                               const ColumnVector& xx) const {
-
-  string epoTimeStr = string(epoTime);
-  const t_pppStation* sta = PPP_CLIENT->staRover();
-
-  LOG << endl;
-
-  t_pppParam* parX = 0;
-  t_pppParam* parY = 0;
-  t_pppParam* parZ = 0;
-  for (unsigned ii = 0; ii < _params.size(); ii++) {
-    t_pppParam* par = _params[ii];
-    if      (par->type() == t_pppParam::crdX) {
-      parX = par;
-    }
-    else if (par->type() == t_pppParam::crdY) {
-      parY = par;
-    }
-    else if (par->type() == t_pppParam::crdZ) {
-      parZ = par;
-    }
-    else {
-      int ind = par->indexNew();
-      double apr = (par->type() == t_pppParam::trp) ?
-        t_tropo::delay_saast(sta->xyzApr(), M_PI/2.0) :  par->x0();
-      LOG << epoTimeStr << ' ' << par->toString() << ' '
-          << setw(10) << setprecision(4) << apr << ' '
-          << showpos << setw(10) << setprecision(4) << xx[ind] << noshowpos << " +- "
-          << setw(8)  << setprecision(4) << sqrt(QQ[ind][ind]);
-      if (par->type() == t_pppParam::amb) {
-        LOG << " el = " << setw(6) << setprecision(2) << par->ambEleSat() * 180.0 / M_PI
-            << " epo = " << setw(4) << par->ambNumEpo();
-      }
-      LOG << endl;
-    }
-  }
-
-  if (parX && parY && parZ) {
-
-	ColumnVector xyz(3);
-    xyz[0] = xx[parX->indexNew()];
-    xyz[1] = xx[parY->indexNew()];
-    xyz[2] = xx[parZ->indexNew()];
-
-    ColumnVector neu(3);
-    xyz2neu(sta->ellApr().data(), xyz.data(), neu.data());
-
-    SymmetricMatrix QQxyz = QQ.SymSubMatrix(1,3);
-
-    SymmetricMatrix QQneu(3);
-    covariXYZ_NEU(QQxyz, sta->ellApr().data(), QQneu);
-
-    LOG << epoTimeStr << ' ' << sta->name()
-        << " X = " << setprecision(4) << sta->xyzApr()[0] + xyz[0] << " +- "
-        << setprecision(4) << sqrt(QQxyz[0][0])
-
-        << " Y = " << setprecision(4) << sta->xyzApr()[1] + xyz[1] << " +- "
-        << setprecision(4) << sqrt(QQxyz[1][1])
-
-        << " Z = " << setprecision(4) << sta->xyzApr()[2] + xyz[2] << " +- "
-        << setprecision(4) << sqrt(QQxyz[2][2])
-
-        << " dN = " << setprecision(4) << neu[0] << " +- "
-        << setprecision(4) << sqrt(QQneu[0][0])
-
-        << " dE = " << setprecision(4) << neu[1] << " +- "
-        << setprecision(4) << sqrt(QQneu[1][1])
-
-        << " dU = " << setprecision(4) << neu[2] << " +- "
-        << setprecision(4) << sqrt(QQneu[2][2])
-
-        << endl;
-  }
-}
-
Index: trunk/BNC/src/PPP/pppParlist.h
===================================================================
--- trunk/BNC/src/PPP/pppParlist.h	(revision 7203)
+++ 	(revision )
@@ -1,111 +1,0 @@
-#ifndef PARLIST_H
-#define PARLIST_H
-
-#include <vector>
-#include <string>
-#include "pppInclude.h"
-#include "t_prn.h"
-#include "bnctime.h"
-
-namespace BNC_PPP {
-
-class t_pppSatObs;
-
-class t_pppParam {
- public:
-  enum e_type {crdX, crdY, crdZ, clkR, amb, offGG, trp};
-
-  t_pppParam(e_type type, const t_prn& prn, t_lc::type tLC,
-          const std::vector<t_pppSatObs*>* obsVector = 0);
-
-  ~t_pppParam();
-  e_type type() const {return _type;}
-  double x0()  const {return _x0;}
-  double partial(const bncTime& epoTime, const t_pppSatObs* obs, 
-                 const t_lc::type& tLC) const;
-  bool   epoSpec() const {return _epoSpec;}
-  bool   isEqual(const t_pppParam* par2) const {
-    return (_type == par2->_type && _prn == par2->_prn && _tLC == par2->_tLC);
-  }
-  void   setIndex(int indexNew) {
-    _indexOld = _indexNew;
-    _indexNew = indexNew;
-  }
-  int indexOld() const {return _indexOld;}
-  int indexNew() const {return _indexNew;}
-  double sigma0() const {return _sigma0;}
-  double noise() const {return _noise;}
-  t_lc::type tLC() const {return _tLC;}
-  t_prn prn() const {return _prn;}
-  std::string toString() const;
-
-  const bncTime& lastObsTime() const {return _lastObsTime;}
-  void setLastObsTime(const bncTime& epoTime) {_lastObsTime = epoTime;}
-  const bncTime& firstObsTime() const {return _firstObsTime;}
-  void setFirstObsTime(const bncTime& epoTime) {_firstObsTime = epoTime;}
-
-  bool     ambResetCandidate() const   {return _ambInfo && _ambInfo->_resetCandidate;}
-  void     setAmbResetCandidate()      {if (_ambInfo) _ambInfo->_resetCandidate = true;}
-  double   ambEleSat() const           {return _ambInfo ? _ambInfo->_eleSat : 0.0;}
-  void     setAmbEleSat(double eleSat) {if (_ambInfo) _ambInfo->_eleSat = eleSat;}
-  unsigned ambNumEpo() const           {return _ambInfo ? _ambInfo->_numEpo : 0;}
-  void     stepAmbNumEpo()             {if (_ambInfo) _ambInfo->_numEpo += 1;}
-
-  static bool sortFunction(const t_pppParam* p1, const t_pppParam* p2) {
-    if      (p1->_type != p2->_type) {
-      return p1->_type < p2->_type;
-    }
-    else if (p1->_tLC != p2->_tLC) {
-      return p1->_tLC < p2->_tLC;
-    }
-    else if (p1->_prn != p2->_prn) {
-      return p1->_prn < p2->_prn;
-    }
-    return false;
-  }
-
- private:
-  class t_ambInfo {
-   public:
-    t_ambInfo() {
-      _resetCandidate = false;
-      _eleSat         = 0.0;
-      _numEpo         = 0;
-    }
-    ~t_ambInfo() {}
-    bool     _resetCandidate;
-    double   _eleSat;
-    unsigned _numEpo;
-  };
-  e_type     _type;
-  t_prn      _prn;
-  t_lc::type _tLC;
-  double     _x0;
-  bool       _epoSpec;
-  int        _indexOld;
-  int        _indexNew;
-  double     _sigma0;
-  double     _noise;
-  t_ambInfo* _ambInfo;
-  bncTime    _lastObsTime;
-  bncTime    _firstObsTime;
-};
-
-class t_pppParlist {
- public:
-  t_pppParlist();
-  ~t_pppParlist();
-
-  t_irc set(const bncTime& epoTime, const std::vector<t_pppSatObs*>& obsVector);
-  unsigned nPar() const {return _params.size();}
-  const std::vector<t_pppParam*>& params() const {return _params;}
-  std::vector<t_pppParam*>& params() {return _params;}
-  void printResult(const bncTime& epoTime, const SymmetricMatrix& QQ, 
-                   const ColumnVector& xx) const;
- private:
-  std::vector<t_pppParam*> _params;
-};
-
-}
-
-#endif
Index: trunk/BNC/src/PPP/pppSatObs.cpp
===================================================================
--- trunk/BNC/src/PPP/pppSatObs.cpp	(revision 7203)
+++ 	(revision )
@@ -1,505 +1,0 @@
-/* -------------------------------------------------------------------------
- * BKG NTRIP Client
- * -------------------------------------------------------------------------
- *
- * Class:      t_pppSatObs
- *
- * Purpose:    Satellite observations
- *
- * Author:     L. Mervart
- *
- * Created:    29-Jul-2014
- *
- * Changes:    
- *
- * -----------------------------------------------------------------------*/
-
-
-#include <iostream>
-#include <cmath>
-#include <newmatio.h>
-
-#include "pppSatObs.h"
-#include "bncconst.h"
-#include "pppEphPool.h"
-#include "pppStation.h"
-#include "bncutils.h"
-#include "bncantex.h"
-#include "pppObsPool.h"
-#include "pppClient.h"
-
-using namespace BNC_PPP;
-using namespace std;
-
-// Constructor
-////////////////////////////////////////////////////////////////////////////
-t_pppSatObs::t_pppSatObs(const t_satObs& pppSatObs) {
-  _prn     = pppSatObs._prn;
-  _time    = pppSatObs._time;
-  _outlier = false;
-  _valid   = true;
-  for (unsigned ii = 0; ii < t_frequency::max; ii++) {
-    _obs[ii] = 0;
-  }
-  prepareObs(pppSatObs);
-}
-
-// Destructor
-////////////////////////////////////////////////////////////////////////////
-t_pppSatObs::~t_pppSatObs() {
-  for (unsigned iFreq = 1; iFreq < t_frequency::max; iFreq++) {
-    delete _obs[iFreq];
-  }
-}
-
-// 
-////////////////////////////////////////////////////////////////////////////
-void t_pppSatObs::prepareObs(const t_satObs& pppSatObs) {
-
-  _model.reset();
-
-  // Select pseudoranges and phase observations
-  // ------------------------------------------
-  const string preferredAttrib = "CWPX_";
-
-  for (unsigned iFreq = 1; iFreq < t_frequency::max; iFreq++) {
-    string frqNum = t_frequency::toString(t_frequency::type(iFreq)).substr(1);
-    for (unsigned iPref = 0; iPref < preferredAttrib.length(); iPref++) {
-      string obsType = (preferredAttrib[iPref] == '_') ? frqNum : frqNum + preferredAttrib[iPref];
-      if (_obs[iFreq] == 0) {
-        for (unsigned ii = 0; ii < pppSatObs._obs.size(); ii++) {
-          const t_frqObs* obs = pppSatObs._obs[ii];
-          if (obs->_rnxType2ch == obsType && obs->_codeValid && obs->_phaseValid) {
-            _obs[iFreq] = new t_frqObs(*obs);
-          }
-        }
-      }
-    }
-  }
-
-  // Used frequency types
-  // --------------------
-  _fType1 = t_lc::toFreq(_prn.system(),t_lc::l1);
-  _fType2 = t_lc::toFreq(_prn.system(),t_lc::l2);
-
-  // Check whether all required frequencies available
-  // ------------------------------------------------
-  for (unsigned ii = 0; ii < OPT->LCs(_prn.system()).size(); ii++) {
-    t_lc::type tLC = OPT->LCs(_prn.system())[ii];
-    if (!isValid(tLC)) {
-      _valid = false;
-      return;
-    }
-  }
-
-  // Find Glonass Channel Number
-  // ---------------------------
-  if (_prn.system() == 'R') {
-    _channel = PPP_CLIENT->ephPool()->getChannel(_prn);
-  }
-  else {
-    _channel = 0;
-  }
-
-  // Compute Satellite Coordinates at Time of Transmission
-  // -----------------------------------------------------
-  _xcSat.ReSize(4); _xcSat = 0.0;
-  _vvSat.ReSize(4); _vvSat = 0.0;
-  bool totOK  = false;
-  ColumnVector satPosOld(4); satPosOld = 0.0;
-  t_lc::type tLC = isValid(t_lc::cIF) ? t_lc::cIF : t_lc::c1;
-  double prange = obsValue(tLC);
-  for (int ii = 1; ii <= 10; ii++) {
-    bncTime ToT = _time - prange / t_CST::c - _xcSat[3];
-    if (PPP_CLIENT->ephPool()->getCrd(_prn, ToT, _xcSat, _vvSat) != success) {
-      _valid = false;
-      return;
-    }
-    ColumnVector dx = _xcSat - satPosOld;
-    dx[3] *= t_CST::c;
-    if (dx.norm_Frobenius() < 1.e-4) {
-      totOK = true;
-      break;
-    }
-    satPosOld = _xcSat; 
-  }
-  if (totOK) {
-    _model._satClkM = _xcSat[3] * t_CST::c; 
-  }
-  else {
-    _valid = false;
-  }
-}
-
-// 
-////////////////////////////////////////////////////////////////////////////
-void t_pppSatObs::lcCoeff(t_lc::type tLC, 
-                          map<t_frequency::type, double>& codeCoeff,
-                          map<t_frequency::type, double>& phaseCoeff) const {
-
-  codeCoeff.clear();
-  phaseCoeff.clear();
-
-  double f1 = t_CST::freq(_fType1, _channel);
-  double f2 = t_CST::freq(_fType2, _channel);
-
-  switch (tLC) {
-  case t_lc::l1:
-    phaseCoeff[_fType1] = 1.0;  
-    return;
-  case t_lc::l2:  
-    phaseCoeff[_fType2] = 1.0;  
-    return;
-  case t_lc::lIF: 
-    phaseCoeff[_fType1] =  f1 * f1 / (f1 * f1 - f2 * f2);
-    phaseCoeff[_fType2] = -f2 * f2 / (f1 * f1 - f2 * f2);
-    return;
-  case t_lc::MW:  
-    phaseCoeff[_fType1] =  f1 / (f1 - f2);
-    phaseCoeff[_fType2] = -f2 / (f1 - f2);
-    codeCoeff[_fType1]  = -f1 / (f1 + f2);
-    codeCoeff[_fType2]  = -f2 / (f1 + f2);
-    return;
-  case t_lc::CL:  
-    phaseCoeff[_fType1] =  0.5;
-    codeCoeff[_fType1]  =  0.5;
-    return;
-  case t_lc::c1:  
-    codeCoeff[_fType1] = 1.0;  
-    return;
-  case t_lc::c2:  
-    codeCoeff[_fType2] = 1.0;  
-    return;
-  case t_lc::cIF: 
-    codeCoeff[_fType1] =  f1 * f1 / (f1 * f1 - f2 * f2);
-    codeCoeff[_fType2] = -f2 * f2 / (f1 * f1 - f2 * f2);
-    return;
-  case t_lc::dummy: 
-  case t_lc::maxLc: 
-    return;
-  }
-}
-
-// 
-////////////////////////////////////////////////////////////////////////////
-bool t_pppSatObs::isValid(t_lc::type tLC) const {
-  bool valid = true;
-  obsValue(tLC, &valid);
-  return valid;
-}
-// 
-////////////////////////////////////////////////////////////////////////////
-double t_pppSatObs::obsValue(t_lc::type tLC, bool* valid) const {
-
-  map<t_frequency::type, double> codeCoeff;
-  map<t_frequency::type, double> phaseCoeff;
-  lcCoeff(tLC, codeCoeff, phaseCoeff);
-
-  double retVal = 0.0;
-  if (valid) *valid = true;
-
-  map<t_frequency::type, double>::const_iterator it;
-  for (it = codeCoeff.begin(); it != codeCoeff.end(); it++) {
-    t_frequency::type tFreq = it->first;
-    if (_obs[tFreq] == 0) {
-      if (valid) *valid = false;
-      return 0.0;
-    }
-    else {
-      retVal += it->second * _obs[tFreq]->_code;
-    }
-  }
-  for (it = phaseCoeff.begin(); it != phaseCoeff.end(); it++) {
-    t_frequency::type tFreq = it->first;
-    if (_obs[tFreq] == 0) {
-      if (valid) *valid = false;
-      return 0.0;
-    }
-    else {
-      retVal += it->second * _obs[tFreq]->_phase * t_CST::lambda(tFreq, _channel);
-    }
-  }
-
-  return retVal;
-}
-
-// 
-////////////////////////////////////////////////////////////////////////////
-double t_pppSatObs::lambda(t_lc::type tLC) const {
-
-  double f1 = t_CST::freq(_fType1, _channel);
-  double f2 = t_CST::freq(_fType2, _channel);
-
-  if      (tLC == t_lc::l1) {
-    return t_CST::c / f1;
-  }
-  else if (tLC == t_lc::l2) {
-    return t_CST::c / f2;
-  }
-  else if (tLC == t_lc::lIF) {
-    return t_CST::c / (f1 + f2);
-  }
-  else if (tLC == t_lc::MW) {
-    return t_CST::c / (f1 - f2);
-  }
-  else if (tLC == t_lc::CL) {
-    return t_CST::c / f1 / 2.0;
-  }
-
-  return 0.0;
-}
-
-// 
-////////////////////////////////////////////////////////////////////////////
-double t_pppSatObs::sigma(t_lc::type tLC) const {
-
-  map<t_frequency::type, double> codeCoeff;
-  map<t_frequency::type, double> phaseCoeff;
-  lcCoeff(tLC, codeCoeff, phaseCoeff);
-
-  double retVal = 0.0;
-
-  map<t_frequency::type, double>::const_iterator it;
-  for (it = codeCoeff.begin(); it != codeCoeff.end(); it++) {
-    retVal += it->second * it->second * OPT->_sigmaC1 * OPT->_sigmaC1;
-  }
-  for (it = phaseCoeff.begin(); it != phaseCoeff.end(); it++) {
-    retVal += it->second * it->second * OPT->_sigmaL1 * OPT->_sigmaL1;
-  }
-  
-  retVal = sqrt(retVal);    
-
-  // De-Weight GLONASS
-  // -----------------
-  if (_prn.system() == 'R') {
-    retVal *= 5.0;
-  }
-
-  // Elevation-Dependent Weighting
-  // -----------------------------
-  double cEle = 1.0;
-  if ( (OPT->_eleWgtCode  && t_lc::includesCode(tLC)) ||
-       (OPT->_eleWgtPhase && t_lc::includesPhase(tLC)) ) {
-    double eleD = eleSat()*180.0/M_PI;
-    double hlp  = fabs(90.0 - eleD);
-    cEle = (1.0 + hlp*hlp*hlp*0.000004);
-  }
-
-  return cEle * retVal;
-}
-
-// 
-////////////////////////////////////////////////////////////////////////////
-double t_pppSatObs::maxRes(t_lc::type tLC) const {
-
-  map<t_frequency::type, double> codeCoeff;
-  map<t_frequency::type, double> phaseCoeff;
-  lcCoeff(tLC, codeCoeff, phaseCoeff);
-
-  double retVal = 0.0;
-
-  map<t_frequency::type, double>::const_iterator it;
-  for (it = codeCoeff.begin(); it != codeCoeff.end(); it++) {
-    retVal += it->second * it->second * OPT->_maxResC1 * OPT->_maxResC1;
-  }
-  for (it = phaseCoeff.begin(); it != phaseCoeff.end(); it++) {
-    retVal += it->second * it->second * OPT->_maxResL1 * OPT->_maxResL1;
-  }
-
-  return sqrt(retVal);
-}
-
-
-// 
-////////////////////////////////////////////////////////////////////////////
-t_irc t_pppSatObs::cmpModel(const t_pppStation* station) {
-
-  // Reset all model values
-  // ----------------------
-  _model.reset();
-
-  // Topocentric Satellite Position
-  // ------------------------------
-  ColumnVector rSat = _xcSat.Rows(1,3);
-  ColumnVector rhoV = rSat - station->xyzApr(); 
-  _model._rho = rhoV.norm_Frobenius();
-
-  ColumnVector neu(3);
-  xyz2neu(station->ellApr().data(), rhoV.data(), neu.data());
-
-  _model._eleSat = acos( sqrt(neu[0]*neu[0] + neu[1]*neu[1]) / _model._rho );
-  if (neu[2] < 0) {
-    _model._eleSat *= -1.0;
-  }
-  _model._azSat  = atan2(neu[1], neu[0]);
-
-  // Satellite Clocks
-  // ----------------
-  _model._satClkM = _xcSat[3] * t_CST::c;
-
-  // Receiver Clocks
-  // ---------------
-  _model._recClkM = station->dClk() * t_CST::c;
-
-  // Sagnac Effect (correction due to Earth rotation)
-  // ------------------------------------------------
-  ColumnVector Omega(3);
-  Omega[0] = 0.0;
-  Omega[1] = 0.0;
-  Omega[2] = t_CST::omega / t_CST::c;
-  _model._sagnac = DotProduct(Omega, crossproduct(rSat, station->xyzApr()));
-
-  // Antenna Eccentricity
-  // --------------------
-  _model._antEcc = -DotProduct(station->xyzEcc(), rhoV) / _model._rho;
-
-  // Antenna Phase Center Offsets and Variations
-  // -------------------------------------------
-  if (PPP_CLIENT->antex()) {
-    for (unsigned ii = 0; ii < t_frequency::max; ii++) {
-      t_frequency::type frqType = static_cast<t_frequency::type>(ii);
-      bool found;
-      _model._antPCO[ii] = PPP_CLIENT->antex()->rcvCorr(station->antName(), frqType, 
-                                                        _model._eleSat, _model._azSat, found);
-    }
-  }
-
-  // Tropospheric Delay
-  // ------------------
-  _model._tropo = t_tropo::delay_saast(station->xyzApr(), _model._eleSat);
-
-  // Phase Wind-Up
-  // -------------
-  _model._windUp = station->windUp(_time, _prn, rSat);
-
-  // Code Biases
-  // -----------
-  const t_satCodeBias* satCodeBias = PPP_CLIENT->obsPool()->satCodeBias(_prn);
-  if (satCodeBias) { 
-    for (unsigned ii = 0; ii < satCodeBias->_bias.size(); ii++) {
-      const t_frqCodeBias& bias = satCodeBias->_bias[ii];
-      for (unsigned iFreq = 1; iFreq < t_frequency::max; iFreq++) {
-        const t_frqObs* obs = _obs[iFreq];
-        if (obs && obs->_rnxType2ch == bias._rnxType2ch) {
-          _model._codeBias[iFreq]  = bias._value;
-        }
-      }
-    }
-  }
-
-  // Tidal Correction
-  // ----------------
-  _model._tide = -DotProduct(station->tideDspl(), rhoV) / _model._rho;
-
-  // Ionospheric Delay
-  // -----------------
-  // TODO
-
-  // Ocean Loading
-  // -------------
-  // TODO
-
-  // Set Model Set Flag
-  // ------------------
-  _model._set = true;
-
-  return success;
-}
-
-// 
-////////////////////////////////////////////////////////////////////////////
-void t_pppSatObs::printModel() const {
-  LOG.setf(ios::fixed);
-  LOG << "MODEL for Satellite " << _prn.toString() << endl
-      << "RHO:        " << setw(12) << setprecision(3) << _model._rho     << endl
-      << "ELE:        " << setw(12) << setprecision(3) << _model._eleSat * 180.0 / M_PI << endl
-      << "AZI:        " << setw(12) << setprecision(3) << _model._azSat  * 180.0 / M_PI << endl
-      << "SATCLK:     " << setw(12) << setprecision(3) << _model._satClkM << endl
-      << "RECCLK:     " << setw(12) << setprecision(3) << _model._recClkM << endl
-      << "SAGNAC:     " << setw(12) << setprecision(3) << _model._sagnac  << endl
-      << "ANTECC:     " << setw(12) << setprecision(3) << _model._antEcc  << endl
-      << "TROPO:      " << setw(12) << setprecision(3) << _model._tropo   << endl
-      << "WINDUP:     " << setw(12) << setprecision(3) << _model._windUp  << endl
-      << "TIDES:      " << setw(12) << setprecision(3) << _model._tide    << endl;
-  for (unsigned iFreq = 1; iFreq < t_frequency::max; iFreq++) {
-    if (_obs[iFreq]) {
-      LOG << "PCO:        " << t_frequency::toString(t_frequency::type(iFreq)) << setw(12) << setprecision(3) << _model._antPCO[iFreq]    << endl
-          << "BIAS CODE:  " << t_frequency::toString(t_frequency::type(iFreq)) << setw(12) << setprecision(3) << _model._codeBias[iFreq]  << endl
-          << "BIAS PHASE: " << t_frequency::toString(t_frequency::type(iFreq)) << setw(12) << setprecision(3) << _model._phaseBias[iFreq] << endl;
-    }
-  }
-  LOG << "OBS-CMP P3: " << _prn.toString() << " " 
-      << setw(12) << setprecision(3) << obsValue(t_lc::cIF) << " "
-      << setw(12) << setprecision(3) << cmpValue(t_lc::cIF) << " "
-      << setw(12) << setprecision(3) << obsValue(t_lc::cIF) - cmpValue(t_lc::cIF) << endl;
-
-  LOG << "OBS-CMP L3: " << _prn.toString() << " " 
-      << setw(12) << setprecision(3) << obsValue(t_lc::lIF) << " "
-      << setw(12) << setprecision(3) << cmpValue(t_lc::lIF) << " "
-      << setw(12) << setprecision(3) << obsValue(t_lc::lIF) - cmpValue(t_lc::lIF) << endl;
-
-  LOG << "OBS-CMP MW: " << _prn.toString() << " " 
-      << setw(12) << setprecision(3) << obsValue(t_lc::MW) << " "
-      << setw(12) << setprecision(3) << cmpValue(t_lc::MW) << " "
-      << setw(12) << setprecision(3) << obsValue(t_lc::MW) - cmpValue(t_lc::MW) << endl;
-}
-
-// 
-////////////////////////////////////////////////////////////////////////////
-double t_pppSatObs::cmpValueForBanc(t_lc::type tLC) const {
-  return cmpValue(tLC) - _model._rho - _model._sagnac - _model._recClkM;
-}
-
-// 
-////////////////////////////////////////////////////////////////////////////
-double t_pppSatObs::cmpValue(t_lc::type tLC) const {
-
-  if (!isValid(tLC)) {
-    return 0.0;
-  }
-
-  // Non-Dispersive Part
-  // -------------------
-  double nonDisp = _model._rho    + _model._recClkM - _model._satClkM 
-                 + _model._sagnac + _model._antEcc  + _model._tropo 
-                 + _model._tide;
-
-  // Add Dispersive Part
-  // -------------------
-  map<t_frequency::type, double> codeCoeff;
-  map<t_frequency::type, double> phaseCoeff;
-  lcCoeff(tLC, codeCoeff, phaseCoeff);
-
-  double dispPart = 0.0;
-
-  map<t_frequency::type, double>::const_iterator it;
-  for (it = codeCoeff.begin(); it != codeCoeff.end(); it++) {
-    t_frequency::type tFreq = it->first;
-    dispPart += it->second * (_model._antPCO[tFreq] + _model._codeBias[tFreq]);
-  }
-  for (it = phaseCoeff.begin(); it != phaseCoeff.end(); it++) {
-    t_frequency::type tFreq = it->first;
-    dispPart += it->second * (_model._antPCO[tFreq] + _model._phaseBias[tFreq] +
-                              _model._windUp * t_CST::lambda(tFreq, _channel));
-  }
-
-    return nonDisp + dispPart;
-}
-
-// 
-////////////////////////////////////////////////////////////////////////////
-void t_pppSatObs::setRes(t_lc::type tLC, double res) {
-  _res[tLC] = res;
-}
-
-// 
-////////////////////////////////////////////////////////////////////////////
-double t_pppSatObs::getRes(t_lc::type tLC) const {
-  map<t_lc::type, double>::const_iterator it = _res.find(tLC);
-  if (it != _res.end()) {
-    return it->second;
-  }
-  else {
-    return 0.0;
-  }
-}
Index: trunk/BNC/src/PPP/pppSatObs.h
===================================================================
--- trunk/BNC/src/PPP/pppSatObs.h	(revision 7203)
+++ 	(revision )
@@ -1,130 +1,0 @@
-#ifndef PPPSATOBS_H
-#define PPPSATOBS_H
-
-#include <string>
-#include <map>
-#include <newmat.h>
-#include "pppInclude.h"
-#include "satObs.h"
-#include "bnctime.h"
-
-namespace BNC_PPP {
-
-class t_pppStation;
-
-class t_pppSatObs {
- public:
-  t_pppSatObs(const t_satObs& satObs);
-  ~t_pppSatObs();
-  bool                isValid() const {return _valid;};
-  bool                isValid(t_lc::type tLC) const;
-  const t_prn&        prn() const {return _prn;}
-  const ColumnVector& xc() const {return _xcSat;}
-  const bncTime&      time() const {return _time;}
-  t_irc               cmpModel(const t_pppStation* station);
-  double              obsValue(t_lc::type tLC, bool* valid = 0) const;
-  double              cmpValue(t_lc::type tLC) const;
-  double              cmpValueForBanc(t_lc::type tLC) const;
-  double              rho() const {return _model._rho;}
-  double              sagnac() const {return _model._sagnac;}
-  double              eleSat() const {return _model._eleSat;}
-  bool                modelSet() const {return _model._set;}
-  void                printModel() const;
-  void                lcCoeff(t_lc::type tLC, 
-                              std::map<t_frequency::type, double>& codeCoeff,
-                              std::map<t_frequency::type, double>& phaseCoeff) const;
-  double              lambda(t_lc::type tLC) const;
-  double              sigma(t_lc::type tLC) const;
-  double              maxRes(t_lc::type tLC) const;
-  bool                outlier() const {return _outlier;}
-  void                setOutlier() {_outlier = true;}
-  void                setRes(t_lc::type tLC, double res);
-  double              getRes(t_lc::type tLC) const;
-
-  bool slip() const {
-    for (unsigned ii = 1; ii < t_frequency::max; ii++) {
-      if (_obs[ii] && _obs[ii]->_slip) {
-        return true;
-      }
-    }
-    return false;
-  }
-
-  int slipCounter() const {
-    int cnt = -1;
-    for (unsigned ii = 1; ii < t_frequency::max; ii++) {
-      if (_obs[ii] && _obs[ii]->_slipCounter > cnt) {
-        cnt = _obs[ii]->_slipCounter;
-      }
-    }
-    return cnt;
-  }
-
-  int biasJumpCounter() const {
-    int jmp = -1;
-    for (unsigned ii = 1; ii < t_frequency::max; ii++) {
-      if (_obs[ii] && _obs[ii]->_biasJumpCounter > jmp) {
-        jmp = _obs[ii]->_biasJumpCounter;
-      }
-    }
-    return jmp;
-  }
-
- private:
-  class t_model {
-   public:
-    t_model() {reset();}
-    ~t_model() {}
-    void reset() {
-      _set     = false;
-      _rho     = 0.0;
-      _eleSat  = 0.0;
-      _azSat   = 0.0;
-      _recClkM = 0.0;
-      _satClkM = 0.0;
-      _sagnac  = 0.0;
-      _antEcc  = 0.0;
-      _tropo   = 0.0;
-      _tide    = 0.0;
-      _windUp  = 0.0;
-      for (unsigned ii = 0; ii < t_frequency::max; ii++) {
-        _antPCO[ii]    = 0.0;
-        _codeBias[ii]  = 0.0;
-        _phaseBias[ii] = 0.0;
-      }
-    }
-    bool   _set;
-    double _rho;
-    double _eleSat;
-    double _azSat;
-    double _recClkM;
-    double _satClkM;
-    double _sagnac;
-    double _antEcc;
-    double _tropo;
-    double _tide;
-    double _windUp;
-    double _antPCO[t_frequency::max];
-    double _codeBias[t_frequency::max];
-    double _phaseBias[t_frequency::max];
-  };
-
-  void prepareObs(const t_satObs& satObs);
-
-  bool                         _valid;
-  t_frequency::type            _fType1;
-  t_frequency::type            _fType2;
-  t_prn                        _prn;
-  bncTime                      _time;
-  int                          _channel;
-  t_frqObs*                    _obs[t_frequency::max];
-  ColumnVector                 _xcSat;
-  ColumnVector                 _vvSat;
-  t_model                      _model;
-  bool                         _outlier;
-  std::map<t_lc::type, double> _res;
-};
-
-}
-
-#endif
Index: trunk/BNC/src/PPP/pppStation.cpp
===================================================================
--- trunk/BNC/src/PPP/pppStation.cpp	(revision 7203)
+++ 	(revision )
@@ -1,58 +1,0 @@
-/* -------------------------------------------------------------------------
- * BKG NTRIP Client
- * -------------------------------------------------------------------------
- *
- * Class:      t_pppStation
- *
- * Purpose:    Processed station
- *
- * Author:     L. Mervart
- *
- * Created:    29-Jul-2014
- *
- * Changes:    
- *
- * -----------------------------------------------------------------------*/
-
-#include "pppStation.h"
-#include "bncutils.h"
-#include "pppModel.h"
-
-using namespace BNC_PPP;
-using namespace std;
-
-// Constructor
-//////////////////////////////////////////////////////////////////////////////
-t_pppStation::t_pppStation() {
-  _windUp    = new t_windUp();
-}
-
-// Destructor
-//////////////////////////////////////////////////////////////////////////////
-t_pppStation::~t_pppStation() {
-  delete _windUp;
-}
-
-// 
-//////////////////////////////////////////////////////////////////////////////
-void t_pppStation::setXyzApr(const ColumnVector& xyzApr) {
-  _xyzApr = xyzApr;
-  _ellApr.ReSize(3);
-  xyz2ell(_xyzApr.data(), _ellApr.data());
-}
-
-// 
-//////////////////////////////////////////////////////////////////////////////
-void t_pppStation::setNeuEcc(const ColumnVector& neuEcc) {
-  _neuEcc = neuEcc;
-  _xyzEcc.ReSize(3);
-  neu2xyz(_ellApr.data(), _neuEcc.data(), _xyzEcc.data());
-}
-
-// 
-//////////////////////////////////////////////////////////////////////////////
-double t_pppStation::windUp(const bncTime& time, t_prn prn, 
-                         const ColumnVector& rSat) const {
-  return _windUp->value(time, _xyzApr, prn, rSat);
-}
-
Index: trunk/BNC/src/PPP/pppStation.h
===================================================================
--- trunk/BNC/src/PPP/pppStation.h	(revision 7203)
+++ 	(revision )
@@ -1,49 +1,0 @@
-#ifndef STATION_H
-#define STATION_H
-
-#include <string>
-#include <newmat.h>
-#include "pppInclude.h"
-#include "bnctime.h"
-
-namespace BNC_PPP {
-
-class t_windUp;
-
-class t_pppStation {
- public:
-  t_pppStation();
-  ~t_pppStation();
-  void setName(std::string name) {_name = name;}
-  void setAntName(std::string antName) {_antName = antName;}
-  void setXyzApr(const ColumnVector& xyzApr);
-  void setNeuEcc(const ColumnVector& neuEcc);
-  void setDClk(double dClk) {_dClk = dClk;}
-  void setTideDspl(const ColumnVector& tideDspl) {_tideDspl = tideDspl;}
-  const std::string&  name()      const {return _name;}
-  const std::string&  antName()   const {return _antName;}
-  const ColumnVector& xyzApr()    const {return _xyzApr;}
-  const ColumnVector& ellApr()    const {return _ellApr;}
-  const ColumnVector& neuEcc()    const {return _neuEcc;}
-  const ColumnVector& xyzEcc()    const {return _xyzEcc;}
-  const ColumnVector& tideDspl()  const {return _tideDspl;}
-  double dClk() const {return _dClk;}
-  double windUp(const bncTime& time, t_prn prn, const ColumnVector& rSat) const;
-
- private:
-  std::string       _name;
-  std::string       _antName;
-  ColumnVector      _xyzApr;
-  ColumnVector      _ellApr;
-  ColumnVector      _neuEcc;
-  ColumnVector      _xyzEcc;
-  ColumnVector      _tideDspl;
-  double            _dClk;
-  mutable t_windUp* _windUp;
-  bncTime           _timeCheck;
-  ColumnVector      _xyzCheck;
-};
-
-}
-
-#endif
