Changeset 7251 in ntrip
- Timestamp:
- Aug 24, 2015, 5:56:41 PM (9 years ago)
- Location:
- trunk/BNC/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/BNC/src/bncutils.cpp
r7244 r7251 411 411 // Rectangular Coordinates -> Geocentric Coordinates 412 412 //////////////////////////////////////////////////////////////////////////// 413 voidxyz2geoc(const double* XYZ, double* Geoc) {413 t_irc xyz2geoc(const double* XYZ, double* Geoc) { 414 414 415 415 const double bell = t_CST::aell*(1.0-1.0/t_CST::fInv) ; 416 416 const double e2 = (t_CST::aell*t_CST::aell-bell*bell)/(t_CST::aell*t_CST::aell) ; 417 418 417 double Ell[3]; 419 xyz2ell(XYZ, Ell); 420 418 if (xyz2ell(XYZ, Ell) != success) { 419 return failure; 420 } 421 421 double rho = sqrt(XYZ[0]*XYZ[0]+XYZ[1]*XYZ[1]+XYZ[2]*XYZ[2]); 422 422 double Rn = t_CST::aell/sqrt(1-(e2)*pow(sin(Ell[0]),2)); … … 425 425 Geoc[1] = Ell[1]; 426 426 Geoc[2] = rho-t_CST::rgeoc; 427 428 return success; 427 429 } 428 430 -
trunk/BNC/src/bncutils.h
r7245 r7251 74 74 t_irc xyz2ell(const double* XYZ, double* Ell); 75 75 76 voidxyz2geoc(const double* XYZ, double* Geoc);76 t_irc xyz2geoc(const double* XYZ, double* Geoc); 77 77 78 78 void xyz2neu(const double* Ell, const double* xyz, double* neu); -
trunk/BNC/src/pppModel.cpp
r7246 r7251 397 397 // Latitude, longitude, height are defined with respect to a spherical earth model 398 398 // ------------------------------------------------------------------------------- 399 ColumnVector geocSta; 400 xyz2geoc(xyzSta.data(), geocSta.data()); 399 ColumnVector geocSta(3); 400 if (xyz2geoc(xyzSta.data(), geocSta.data()) != success) { 401 return 0.0; 402 } 401 403 402 404 // satellite position rotated to the epoch of signal reception 403 405 // ----------------------------------------------------------- 404 ColumnVector xyzSat ;406 ColumnVector xyzSat(3); 405 407 double omegaZ = t_CST::omega * signalPropagationTime; 406 408 xyzSat[0] = rSat[0] * cos(omegaZ) + rSat[1] * sin(omegaZ);
Note:
See TracChangeset
for help on using the changeset viewer.