Go to the documentation of this file.
43 #ifndef PRS_POSITION_SOLUTION_HPP
44 #define PRS_POSITION_SOLUTION_HPP
48 #include "gnsstk_export.h"
84 lab[0]=
"ECEF_X";
lab[1]=
"ECEF_Y";
lab[2]=
"ECEF_Z";
90 void setLabels(std::string lab1, std::string lab2, std::string lab3)
91 {
lab[0]=lab1;
lab[1]=lab2;
lab[2]=lab3; }
120 for(
unsigned int i=0; i<3; i++) {
121 if(
N==0)
Sbias(i) = Sol(i);
147 void dump(std::ostream& os, std::string
msg=
"")
const
150 os <<
"Simple statistics on " <<
msg << std::endl
151 << std::fixed << std::setprecision(3);
153 os <<
" " <<
lab[0] <<
" N: " <<
S[0].
N()
154 << std::fixed << std::setprecision(4)
160 os <<
" " <<
lab[1] <<
" N: " <<
S[1].
N()
161 << std::fixed << std::setprecision(4)
167 os <<
" " <<
lab[2] <<
" N: " <<
S[2].
N()
168 << std::fixed << std::setprecision(4)
175 os <<
"Weighted average " <<
msg << std::endl;
178 os << std::setw(14) << std::setprecision(4) << Sol <<
" " <<
N;
180 else os <<
" No data!";
387 std::vector<SatID>& Sats,
388 const std::vector<double>& Pseudorange,
431 const std::vector<SatID>& Sats,
435 const int& niterLimit,
436 const double& convLimit,
443 std::vector<SatID>& Satellites,
444 const std::vector<double>& Pseudorange,
475 std::vector<SatID>& Satellites,
476 const std::vector<double>& Pseudorange,
531 for(
unsigned int i=0; i<3; i++)
548 os <<
was << std::endl;
554 for(
size_t i=0; i<Cov.
rows(); i++)
556 for(
size_t j=i; j<Cov.
cols(); j++)
557 Cov(i,j) = Cov(j,i) = Cov(i,j)*sig;
562 NL +=
"ECEF_X"; NL +=
"ECEF_Y"; NL +=
"ECEF_Z";
566 os <<
"Covariance: " << msg << std::endl << LM << std::endl;
567 os <<
"APV: " << msg << std::fixed << std::setprecision(3)
568 <<
" sigma = " << sig <<
" meters with "
569 <<
ndof <<
" degrees of freedom.\n";
594 S(3+i) = (k == -1 ?
APSolution[3+i] : Sol[3+k]);
619 if(invMC.
rows() == 0) {
627 APV +=
dot(PreFitResid,Gpfr);
628 ndata += PreFitResid.size();
bool isValid() const
Return the status of solution.
std::string outputString(std::string tag, int iret=-99, const Vector< double > &Vec=PRSNullVector)
return string of NAV and RMS strings
std::vector< SatelliteSystem > allowedGNSS
BaseClass & ident(RefMatrixBase< T, BaseClass > &m)
std::vector< SatID > SatelliteIDs
LabeledMatrix & scientific()
Set the format to scientific.
WtdAveStats was
The "memory" of this object, used only when hasMemory is true.
int RAIMCompute(const CommonTime &Tr, std::vector< SatID > &Satellites, const std::vector< double > &Pseudorange, const Matrix< double > &invMC, NavLibrary &eph, TropModel *pTropModel, NavSearchOrder order=NavSearchOrder::User)
void dumpSolution(std::ostream &os, std::string msg="PRS")
friend std::ostream & operator<<(std::ostream &s, const WtdAveStats &as)
double TDOP
DOPs computed in a call to DOPCompute() or outputString()
T Minimum(void) const
return minimum value
std::string outputStringHeader(std::string tag)
return string of the form "#tag label etc" which is header for data strings
T dot(const SparseVector< T > &SL, const SparseVector< T > &SR)
dot (SparseVector, SparseVector)
T StdDev(void) const
return computed standard deviation
@ Y
Encrypted legacy GPS precise code.
void add(const Vector< double > &Sol, const Matrix< double > &Cov)
void Reset(void)
reset, i.e. ignore earlier data and restart sampling
size_t cols() const
The number of columns in the matrix.
std::string outputCLKString(std::string tag, int iret=-99)
return string of {SYS clock} for all systems, error code and V/NV
CommonTime currTime
time tag of the current solution
Vector< double > PreFitResidual
std::vector< SatelliteSystem > dataGNSS
size_t rows() const
The number of rows in the matrix.
Matrix< T > inverseSVD(const ConstMatrixBase< T, BaseClass > &m, const T tol=T(1.e-8))
Vector< double > Solution
NavSearchOrder
Specify the behavior of nav data searches in NavLibrary/NavDataFactory.
int Nsvs
the number of good satellites used in the final computation
void addToMemory(const Vector< double > &Sol, const Matrix< double > &Cov, const Vector< double > &PreFitResid, const Matrix< double > &Partials, const Matrix< double > &invMeasCov)
Vector & resize(const size_t index)
void dump(std::ostream &os, std::string msg="") const
LabeledMatrix & setprecision(int p)
Set the precision to p digits.
int RAIMComputeUnweighted(const CommonTime &Tr, std::vector< SatID > &Satellites, const std::vector< double > &Pseudorange, NavLibrary &eph, TropModel *pTropModel, NavSearchOrder order=NavSearchOrder::User)
std::string outputRMSString(std::string tag, int iret=-99)
Matrix< double > getCov(void) const
std::string outputPOSString(std::string tag, int iret=-99, const Vector< double > &Vec=PRSNullVector)
std::string errorCodeString(int iret)
A convenience for printing the error code (return value)
SparseMatrix< T > transpose(const SparseMatrix< T > &M)
transpose
int SimplePRSolution(const CommonTime &Tr, const std::vector< SatID > &Sats, const Matrix< double > &SVP, const Matrix< double > &invMC, TropModel *pTropModel, const int &niterLimit, const double &convLimit, Vector< double > &Resids, Vector< double > &Slopes)
Vector< double > APSolution
int PreparePRSolution(const CommonTime &Tr, std::vector< SatID > &Sats, const std::vector< double > &Pseudorange, NavLibrary &eph, Matrix< double > &SVP, NavSearchOrder order=NavSearchOrder::User) const
void setMessage(std::string m)
T Maximum(void) const
return maximum value
void fixAPSolution(const double &X, const double &Y, const double &Z)
static const std::string gpsfmt
static const GNSSTK_EXPORT Vector< double > PRSNullVector
empty vector used to detect default
#define GNSSTK_RETHROW(exc)
Matrix< double > invMeasCov
static const std::string calfmt
time formats used in prints
std::string getMessage(void) const
Vector< double > getSol(void) const
int NIterations
the actual number of iterations used
double SlopeLimit
Slope limit (dimensionless).
bool Valid
flag: output content is valid.
size_t size() const
STL size.
Matrix< double > Partials
Matrix<double> containing the partials matrix used in the final solution.
double Convergence
the RSS change in solution at the end of iterations.
T Average(void) const
return the average
LabeledMatrix & symmetric(bool s=true)
If true, the matrix is symmetrical, so print only the lower triangle.
std::string outputValidString(int iret=-99)
Exception & addText(const std::string &errorText)
@ User
Return the latest message before the search time.
std::string outputNAVString(std::string tag, int iret=-99, const Vector< double > &Vec=PRSNullVector)
return string of info in POS and CLK
double RMSLimit
RMS limit (m) on residual of fit.
Matrix< double > Covariance
void updateAPSolution(const Vector< double > &Sol)
static const std::string timfmt
std::string configString(std::string tag)
A convenience for printing the current configuarion.
int vectorindex(const std::vector< T > &vec, const T &value)
Vector< double > sumInfoState
unsigned int N(void) const
return the sample size
void setLabels(std::string lab1, std::string lab2, std::string lab3)
LabeledMatrix & setw(int w)
Set the width to w characters.
Matrix< double > getInfo(void) const
gnsstk
Author(s):
autogenerated on Wed Oct 25 2023 02:40:40