Changeset 8542 in ntrip for trunk/BNC/src/ephemeris.cpp


Ignore:
Timestamp:
Nov 15, 2018, 11:16:46 AM (5 years ago)
Author:
stuerze
Message:

minor changes to consider a satellite clock drift that is introduced via RTNET format

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/BNC/src/ephemeris.cpp

    r8489 r8542  
    6565                                                 << 900 << 1800 << 3600 << 7200
    6666                                                 << 10800;
    67   xc.ReSize(7);
     67  xc.ReSize(6);
    6868  vv.ReSize(3);
    6969  if (position(tt.gpsw(), tt.gpssec(), xc.data(), vv.data()) != success) {
     
    320320  static const double gmGRS      = 398.6005e12;
    321321
    322   memset(xc, 0, 7*sizeof(double));
     322  memset(xc, 0, 6*sizeof(double));
    323323  memset(vv, 0, 3*sizeof(double));
    324324
     
    368368  double tc = tt - _TOC;
    369369  xc[3] = _clock_bias + _clock_drift*tc + _clock_driftrate*tc*tc;
    370 
    371   xc[4] = _clock_bias;
    372   xc[5] = _clock_drift;
    373   xc[6] = _clock_driftrate;
    374370
    375371  // Velocity
     
    402398  xc[3] -= 2.0 * (xc[0]*vv[0] + xc[1]*vv[1] + xc[2]*vv[2]) / t_CST::c / t_CST::c;
    403399
     400  xc[4] = _clock_drift + _clock_driftrate*tc;
     401  xc[5] = _clock_driftrate;
     402 
    404403  return success;
    405404}
     
    618617  static const double nominalStep = 10.0;
    619618
    620   memset(xc, 0, 7*sizeof(double));
     619  memset(xc, 0, 6*sizeof(double));
    621620  memset(vv, 0, 3*sizeof(double));
    622621
     
    655654  xc[3] = -_tau + _gamma * dtClk;
    656655
    657   xc[4] = -_tau;
    658   xc[5] = _gamma;
    659   xc[6] = 0.0;
     656  xc[4] = _gamma;
     657  xc[5] = 0.0;
    660658
    661659  return success;
     
    923921  static const double gmWGS = 398.6004418e12;
    924922
    925   memset(xc, 0, 7*sizeof(double));
     923  memset(xc, 0, 6*sizeof(double));
    926924  memset(vv, 0, 3*sizeof(double));
    927925
     
    971969  double tc = tt - _TOC;
    972970  xc[3] = _clock_bias + _clock_drift*tc + _clock_driftrate*tc*tc;
    973 
    974   xc[4] = _clock_bias;
    975   xc[5] = _clock_drift;
    976   xc[6] = _clock_driftrate;
    977971
    978972  // Velocity
     
    10071001  //xc[3] -= 2.0 * (xc[0]*vv[0] + xc[1]*vv[1] + xc[2]*vv[2]) / t_CST::c / t_CST::c;
    10081002
     1003  xc[4] = _clock_drift + _clock_driftrate*tc;
     1004  xc[5] = _clock_driftrate;
     1005 
    10091006  return success;
    10101007}
     
    13191316  xc[3] = _agf0 + _agf1 * dt;
    13201317
    1321   xc[4] = _agf0;
    1322   xc[5] = _agf1;
    1323   xc[6] = 0.0;
     1318  xc[4] = _agf1;
     1319  xc[5] = 0.0;
    13241320
    13251321  return success;
     
    16731669  xc[3] = _clock_bias + _clock_drift*tc + _clock_driftrate*tc*tc;
    16741670
    1675   xc[4] = _clock_bias;
    1676   xc[5] = _clock_drift;
    1677   xc[6] = _clock_driftrate;
    1678 
    16791671  // dotC  = _clock_drift + _clock_driftrate*tc
    16801672  //       - 4.442807633e-10*_e*sqrt(a0)*cos(E) * dEdM * n;
     
    16871679  // xc[3] -= 2.0 * (xc[0]*vv[0] + xc[1]*vv[1] + xc[2]*vv[2]) / t_CST::c / t_CST::c;
    16881680
     1681  xc[4] = _clock_drift + _clock_driftrate*tc;
     1682  xc[5] = _clock_driftrate;
    16891683  return success;
    16901684}
Note: See TracChangeset for help on using the changeset viewer.