BasicModel Class Reference
[GPS solution algorithms and Tropospheric]

#include <BasicModel.hpp>

Inheritance diagram for BasicModel:

Inheritance graph
[legend]
Collaboration diagram for BasicModel:

Collaboration graph
[legend]
List of all members.

Detailed Description

This is a class to compute the basic parts of a GNSS model, like geometric distance, relativity correction, satellite position and velocity at transmission time, satellite elevation and azimuth, etc.

This class is intended to be used with GNSS Data Structures (GDS). It is a more modular alternative to classes such as ModelObs and ModelObsFixedStation.

A typical way to use this class follows:

      // Input observation file stream
   RinexObsStream rin("ebre0300.02o");

      // Load the precise ephemeris file
   SP3EphemerisStore sp3Eph;
   sp3Eph.loadFile("igs11513.sp3");

      // Reference position of receiver station
   Position nominalPos(4833520.2269, 41537.00768, 4147461.489);

      // Some more code and definitions here...

   gnssRinex gRin;  // GNSS data structure for fixed station data

      // Set defaults of models. A typical C1-based modeling is used
   BasicModel model( nominalPos, sp3Eph );

   while(rin >> gRin)
   {

         // Apply the model on the GDS
      gRin >> model;
   }

The "BasicModel" object will visit every satellite in the GNSS data structure that is "gRin" and will try to compute its model: Geometric distance, relativity delay, satellite position at transmission time, satellite elevation and azimuth, etc.

When used with the ">>" operator, this class returns the same incoming data structure with the extra data inserted along their corresponding satellites. Be warned that if a given satellite does not have ephemeris information, it will be summarily deleted from the data structure.

See also:
ModelObs.hpp and ModelObsFixedStation.hpp for classes carrying out a more complete model.

Definition at line 101 of file BasicModel.hpp.

Public Member Functions

 BasicModel ()
 Default constructor.
 BasicModel (const double &aRx, const double &bRx, const double &cRx, Position::CoordinateSystem s=Position::Cartesian, GeoidModel *geoid=NULL)
 Explicit constructor taking as input reference station coordinates.
 BasicModel (const Position &RxCoordinates)
 Explicit constructor, taking as input a Position object containing reference station coordinates.
 BasicModel (const Position &RxCoordinates, XvtStore< SatID > &dEphemeris, const TypeID &dObservable=TypeID::C1, const bool &applyTGD=false)
 Explicit constructor, taking as input reference station coordinates, ephemeris to be used and whether TGD will be computed or not.
virtual satTypeValueMapProcess (const DayTime &time, satTypeValueMap &gData) throw (ProcessingException)
 Returns a satTypeValueMap object, adding the new data generated when calling a modeling object.
virtual gnssSatTypeValueProcess (gnssSatTypeValue &gData) throw (ProcessingException)
 Returns a gnnsSatTypeValue object, adding the new data generated when calling a modeling object.
virtual gnssRinexProcess (gnssRinex &gData) throw (ProcessingException)
 Returns a gnnsRinex object, adding the new data generated when calling a modeling object.
virtual double getMinElev () const
 Method to get satellite elevation cut-off angle.
virtual BasicModelsetMinElev (double newElevation)
 Method to set satellite elevation cut-off angle.
virtual TypeID getDefaultObservable () const
 Method to get the default observable for computations.
virtual BasicModelsetDefaultObservable (const TypeID &type)
 Method to set the default observable for computations.
virtual XvtStore< SatID > * getDefaultEphemeris () const
 Method to get a pointer to the default XvtStore<SatID> to be used with GNSS data structures.
virtual BasicModelsetDefaultEphemeris (XvtStore< SatID > &ephem)
 Method to set the default XvtStore<SatID> to be used with GNSS data structures.
virtual int getIndex (void) const
 Returns an index identifying this object.
virtual std::string getClassName (void) const
 Returns a string identifying this object.
virtual ~BasicModel ()
 Destructor.

Public Attributes

Position rxPos
 Either estimated or "a priori" position of receiver.

Protected Member Functions

virtual int setInitialRxPosition (const double &aRx, const double &bRx, const double &cRx, Position::CoordinateSystem s=Position::Cartesian, GeoidModel *geoid=NULL)
 Method to set the initial (a priori) position of receiver.
virtual int setInitialRxPosition (const Position &RxCoordinates)
 Method to set the initial (a priori) position of receiver.
virtual int setInitialRxPosition ()
 Method to set the initial (a priori) position of receiver.
virtual double getTGDCorrections (DayTime Tr, const XvtStore< SatID > &Eph, SatID sat) throw ()
 Method to get TGD corrections.

Protected Attributes

double minElev
 The elevation cut-off angle for accepted satellites.
XvtStore< SatID > * pDefaultEphemeris
 Pointer to default XvtStore<SatID> object when working with GNSS data structures.
TypeID defaultObservable
 Default observable to be used when fed with GNSS data structures.
bool useTGD
 Whether the TGD effect will be applied to C1 observable or not.


Constructor & Destructor Documentation

BasicModel  )  [inline]
 

Default constructor.

Observable C1 will be used for computations and satellites with elevation less than 10 degrees will be deleted.

Definition at line 108 of file BasicModel.hpp.

BasicModel const double &  aRx,
const double &  bRx,
const double &  cRx,
Position::CoordinateSystem  s = Position::Cartesian,
GeoidModel geoid = NULL
 

Explicit constructor taking as input reference station coordinates.

Those coordinates may be Cartesian (X, Y, Z in meters) or Geodetic (Latitude, Longitude, Altitude), but defaults to Cartesian.

Also, a pointer to GeoidModel may be specified, but default is NULL (in which case WGS84 values will be used).

Parameters:
aRx first coordinate [ X(m), or latitude (degrees N) ]
bRx second coordinate [ Y(m), or longitude (degrees E) ]
cRx third coordinate [ Z, height above ellipsoid or radius, in meters ]
s coordinate system (default is Cartesian, may be set to Geodetic).
geoid pointer to GeoidModel (default is null, implies WGS84)

Definition at line 72 of file BasicModel.cpp.

References BasicModel::defaultObservable, BasicModel::minElev, BasicModel::pDefaultEphemeris, BasicModel::setInitialRxPosition(), and BasicModel::useTGD.

BasicModel const Position RxCoordinates  ) 
 

Explicit constructor, taking as input a Position object containing reference station coordinates.

Definition at line 91 of file BasicModel.cpp.

References BasicModel::defaultObservable, BasicModel::minElev, BasicModel::pDefaultEphemeris, BasicModel::setInitialRxPosition(), and BasicModel::useTGD.

BasicModel const Position RxCoordinates,
XvtStore< SatID > &  dEphemeris,
const TypeID dObservable = TypeID::C1,
const bool &  applyTGD = false
 

Explicit constructor, taking as input reference station coordinates, ephemeris to be used and whether TGD will be computed or not.

Parameters:
RxCoordinates Reference station coordinates.
dEphemeris EphemerisStore object to be used by default.
dObservable Observable type to be used by default.
applyTGD Whether or not C1 observable will be corrected from TGD effect.

Definition at line 116 of file BasicModel.cpp.

References BasicModel::defaultObservable, BasicModel::minElev, BasicModel::setDefaultEphemeris(), BasicModel::setInitialRxPosition(), and BasicModel::useTGD.

virtual ~BasicModel  )  [inline, virtual]
 

Destructor.

Definition at line 244 of file BasicModel.hpp.


Member Function Documentation

std::string getClassName void   )  const [virtual]
 

Returns a string identifying this object.

Implements ProcessingClass.

Definition at line 50 of file BasicModel.cpp.

virtual XvtStore<SatID>* getDefaultEphemeris  )  const [inline, virtual]
 

Method to get a pointer to the default XvtStore<SatID> to be used with GNSS data structures.

Definition at line 218 of file BasicModel.hpp.

virtual TypeID getDefaultObservable  )  const [inline, virtual]
 

Method to get the default observable for computations.

Definition at line 204 of file BasicModel.hpp.

int getIndex void   )  const [virtual]
 

Returns an index identifying this object.

Implements ProcessingClass.

Definition at line 45 of file BasicModel.cpp.

virtual double getMinElev  )  const [inline, virtual]
 

Method to get satellite elevation cut-off angle.

By default, it is set to 10 degrees.

Definition at line 193 of file BasicModel.hpp.

double getTGDCorrections DayTime  Tr,
const XvtStore< SatID > &  Eph,
SatID  sat
throw () [protected, virtual]
 

Method to get TGD corrections.

Definition at line 323 of file BasicModel.cpp.

References GPSEphemerisStore::findEphemeris(), and EngEphemeris::getTgd().

virtual gnssRinex& Process gnssRinex gData  )  throw (ProcessingException) [inline, virtual]
 

Returns a gnnsRinex object, adding the new data generated when calling a modeling object.

Parameters:
gData Data object holding the data.

Implements ProcessingClass.

Definition at line 186 of file BasicModel.hpp.

virtual gnssSatTypeValue& Process gnssSatTypeValue gData  )  throw (ProcessingException) [inline, virtual]
 

Returns a gnnsSatTypeValue object, adding the new data generated when calling a modeling object.

Parameters:
gData Data object holding the data.

Implements ProcessingClass.

Definition at line 176 of file BasicModel.hpp.

satTypeValueMap & Process const DayTime time,
satTypeValueMap gData
throw (ProcessingException) [virtual]
 

Returns a satTypeValueMap object, adding the new data generated when calling a modeling object.

Parameters:
time Epoch.
gData Data object holding the data.

Definition at line 139 of file BasicModel.cpp.

References CorrectedEphemerisRange::azimuthGeodetic, CorrectedEphemerisRange::ComputeAtTransmitTime(), CorrectedEphemerisRange::cosines, CorrectedEphemerisRange::elevationGeodetic, GPSTK_THROW, CorrectedEphemerisRange::rawrange, CorrectedEphemerisRange::relativity, gpstk::SatIDSet, CorrectedEphemerisRange::svclkbias, CorrectedEphemerisRange::svPosVel, Xvt::v, and Xvt::x.

virtual BasicModel& setDefaultEphemeris XvtStore< SatID > &  ephem  )  [inline, virtual]
 

Method to set the default XvtStore<SatID> to be used with GNSS data structures.

Parameters:
ephem XvtStore<SatID> object to be used by default

Definition at line 227 of file BasicModel.hpp.

Referenced by BasicModel::BasicModel().

virtual BasicModel& setDefaultObservable const TypeID type  )  [inline, virtual]
 

Method to set the default observable for computations.

Parameters:
type TypeID object to be used by default

Definition at line 212 of file BasicModel.hpp.

int setInitialRxPosition  )  [protected, virtual]
 

Method to set the initial (a priori) position of receiver.

Definition at line 305 of file BasicModel.cpp.

Referenced by BasicModel::BasicModel(), and BasicModel::setInitialRxPosition().

int setInitialRxPosition const Position RxCoordinates  )  [protected, virtual]
 

Method to set the initial (a priori) position of receiver.

Definition at line 287 of file BasicModel.cpp.

References BasicModel::rxPos.

int setInitialRxPosition const double &  aRx,
const double &  bRx,
const double &  cRx,
Position::CoordinateSystem  s = Position::Cartesian,
GeoidModel geoid = NULL
[protected, virtual]
 

Method to set the initial (a priori) position of receiver.

Returns:
0 if OK -1 if problems arose

Definition at line 264 of file BasicModel.cpp.

References BasicModel::setInitialRxPosition().

virtual BasicModel& setMinElev double  newElevation  )  [inline, virtual]
 

Method to set satellite elevation cut-off angle.

By default, it is set to 10 degrees.

Definition at line 199 of file BasicModel.hpp.


Member Data Documentation

TypeID defaultObservable [protected]
 

Default observable to be used when fed with GNSS data structures.

Definition at line 261 of file BasicModel.hpp.

Referenced by BasicModel::BasicModel().

double minElev [protected]
 

The elevation cut-off angle for accepted satellites.

By default it is set to 10 degrees.

Definition at line 252 of file BasicModel.hpp.

Referenced by BasicModel::BasicModel().

XvtStore<SatID>* pDefaultEphemeris [protected]
 

Pointer to default XvtStore<SatID> object when working with GNSS data structures.

Definition at line 257 of file BasicModel.hpp.

Referenced by BasicModel::BasicModel().

Position rxPos
 

Either estimated or "a priori" position of receiver.

Definition at line 232 of file BasicModel.hpp.

Referenced by BasicModel::setInitialRxPosition().

bool useTGD [protected]
 

Whether the TGD effect will be applied to C1 observable or not.

Definition at line 265 of file BasicModel.hpp.

Referenced by BasicModel::BasicModel().


The documentation for this class was generated from the following files:
Generated on Thu Jul 29 03:31:56 2010 for GPS ToolKit Software Library by  doxygen 1.3.9.1