Public Member Functions | Private Types | Private Attributes | List of all members
gnsstk::IonexStore Class Reference

Detailed Description

This class reads and stores Ionosphere maps.

It computes TEC and RMS values with respect to time and receiver position. Based on extracted TEC values, it calculates the ionospheric delay.

See also
test ionex store.cpp for an example
Warning
The first IONEX map refers to 00:00 UT, the last map to 24:00 UT. The time spacing of the maps (snapshots) is 2 hours. When two consecutive files are loaded the previuous map for 24:00 UT is overwritten by the new 00:00 UT. This might affect the interpolation strategy.

Definition at line 80 of file IonexStore.hpp.

#include <IonexStore.hpp>

Inheritance diagram for gnsstk::IonexStore:
Inheritance graph
[legend]

Public Member Functions

void addMap (const IonexData &iod)
 Insert a new IonexData object into the store. More...
 
void clear ()
 Remove all data. More...
 
void dump (std::ostream &s=std::cout, short detail=0) const
 
double findDCB (const SatID &sat, const CommonTime &time) const
 
CommonTime getFinalTime () const
 
CommonTime getInitialTime () const
 
Triple getIonexValue (const CommonTime &t, const Position &RX, IonexStoreStrategy strategy=IonexStoreStrategy::ConsRot) const
 
double getIono (double elevation, double tecval, double freq, const std::string &ionoMapType) const
 
double getIonoL1 (double elevation, double tecval, const std::string &ionoMapType) const
 
double getIonoL2 (double elevation, double tecval, const std::string &ionoMapType) const
 
double getIonoL5 (double elevation, double tecval, const std::string &ionoMapType) const
 
double getIonoL6 (double elevation, double tecval, const std::string &ionoMapType) const
 
double getIonoL7 (double elevation, double tecval, const std::string &ionoMapType) const
 
double getIonoL8 (double elevation, double tecval, const std::string &ionoMapType) const
 
double getSTEC (double elevation, double tecval, const std::string &ionoMapType) const
 
 IonexStore ()
 Default constructor. More...
 
double ionoMappingFunction (double elevation, const std::string &ionoMapType) const
 
virtual void loadFile (const std::string &filename)
 
virtual ~IonexStore ()
 destructor More...
 
- Public Member Functions inherited from gnsstk::FileStore< IonexHeader >
void addFile (const std::string &fn, IonexHeader &header)
 
void clear () noexcept
 Clear the contents of the (filename, header) map. More...
 
void dump (std::ostream &os=std::cout, short detail=0) const noexcept
 dump a list of file names More...
 
 FileStore () noexcept
 Constructor. More...
 
std::vector< std::string > getFileNames () const
 Get a list of all the file names in the store, as a vector<string> More...
 
const IonexHeadergetHeader (const std::string &fn) const
 
unsigned nfiles () const noexcept
 
unsigned size () const noexcept
 Return the size of the (filename,header) map. More...
 
 ~FileStore ()
 destructor More...
 

Private Types

typedef std::map< CommonTime, IonexHeader::SatDCBMapIonexDCBMap
 The key of this map is the time (first epoch as in IonexHeader) More...
 
typedef std::map< CommonTime, IonexValTypeMapIonexMap
 The key to this map is the time. More...
 
typedef std::map< IonexData::IonexValType, IonexDataIonexValTypeMap
 The key to this map is IonexValType. More...
 

Private Attributes

CommonTime finalTime
 
CommonTime initialTime
 
IonexDCBMap inxDCBMap
 Map of DCB values (IonexHeader.firstEpoch, IonexHeader.svsmap) More...
 
IonexMap inxMaps
 Map of IONEX maps. More...
 

Member Typedef Documentation

◆ IonexDCBMap

The key of this map is the time (first epoch as in IonexHeader)

Definition at line 321 of file IonexStore.hpp.

◆ IonexMap

The key to this map is the time.

Definition at line 315 of file IonexStore.hpp.

◆ IonexValTypeMap

The key to this map is IonexValType.

Definition at line 312 of file IonexStore.hpp.

Constructor & Destructor Documentation

◆ IonexStore()

gnsstk::IonexStore::IonexStore ( )

Default constructor.

Definition at line 60 of file IonexStore.cpp.

◆ ~IonexStore()

gnsstk::IonexStore::~IonexStore ( )
virtual

destructor

Definition at line 68 of file IonexStore.cpp.

Member Function Documentation

◆ addMap()

void gnsstk::IonexStore::addMap ( const IonexData iod)

Insert a new IonexData object into the store.

Definition at line 124 of file IonexStore.cpp.

◆ clear()

void gnsstk::IonexStore::clear ( )

Remove all data.

Definition at line 225 of file IonexStore.cpp.

◆ dump()

void gnsstk::IonexStore::dump ( std::ostream &  s = std::cout,
short  detail = 0 
) const

Dump the store to the provided std::ostream (std::cout by default).

Parameters
[in,out]sstd::ostream object to dump the data to.
[in]detailDetermines how much detail to include in the output: 0 list of filenames with their start and stop times. 1 list of filenames with their start, stop times, type of data and for how many epochs.

Definition at line 146 of file IonexStore.cpp.

◆ findDCB()

double gnsstk::IonexStore::findDCB ( const SatID sat,
const CommonTime time 
) const

Find a DCB value

Parameters
[in]satSatID of satellite of interest
[in]timeTime to search for DCB
Returns
DCB value found (nanoseconds).
Exceptions
InvalidRequestobject thrown when no DCB value is found

Definition at line 499 of file IonexStore.cpp.

◆ getFinalTime()

CommonTime gnsstk::IonexStore::getFinalTime ( ) const
inline

Determine the latest time for which this object can successfully determine the TEC values, and implicitly, the ionospheric delay for any object.

Returns
Final time.
Exceptions
InvalidRequestThis is thrown if the object has no data.

Definition at line 287 of file IonexStore.hpp.

◆ getInitialTime()

CommonTime gnsstk::IonexStore::getInitialTime ( ) const
inline

Determine the earliest time for which this object can successfully determine the TEC values, and implicitly, the ionospheric delay for any object.

Returns
Initial time.
Exceptions
InvalidRequestThis is thrown if the object has no data.

Definition at line 276 of file IonexStore.hpp.

◆ getIonexValue()

Triple gnsstk::IonexStore::getIonexValue ( const CommonTime t,
const Position RX,
IonexStoreStrategy  strategy = IonexStoreStrategy::ConsRot 
) const

Get IONEX TEC, RMS and ionosphere height values as a function of epoch and receiver's position.

Four interpolation strategies are suported (see also Ionex manual: http://igscb.jpl.nasa.gov/igscb/data/format/ionex1.pdf )

A simple 4-point formula is applied to interpolate between the grid points. See more at IonexData::getValue()

Parameters
[in]tTime tag of signal (CommonTime object)
[in]RXReceiver position in ECEF cartesian coordinates (meters).
[in]strategyInterpolation strategy.
Returns
values TEC, RMS and ionosphere height values (Triple object with: TEC and RMS in TECU and the ionosphere height in meters)
Exceptions
InvalidRequest

Definition at line 236 of file IonexStore.cpp.

◆ getIono()

double gnsstk::IonexStore::getIono ( double  elevation,
double  tecval,
double  freq,
const std::string &  ionoMapType 
) const

Get ionospheric slant delay for a given frequency

Parameters
[in]elevationTime tag of signal (CommonTime object)
[in]tecvalTEC value as derived from IONEX file (TECU)
[in]freqFrequency value, in Hz
[in]ionoMapTypeType of ionosphere mapping function (string)
See also
IonexStore::ionoMappingFunction
Returns
Ionosphere slant delay (meters)
Exceptions
InvalidParameter

Definition at line 415 of file IonexStore.cpp.

◆ getIonoL1()

double gnsstk::IonexStore::getIonoL1 ( double  elevation,
double  tecval,
const std::string &  ionoMapType 
) const
inline

Get ionospheric slant delay for L1 frequency

Parameters
[in]elevationTime tag of signal (CommonTime object)
[in]tecvalTEC value as derived from IONEX file (TECU)
[in]ionoMapTypeType of ionosphere mapping function (string)
See also
IonexStore::ionoMappingFunction
Returns
Ionosphere slant delay (meters)
Exceptions
InvalidParameter

Definition at line 176 of file IonexStore.hpp.

◆ getIonoL2()

double gnsstk::IonexStore::getIonoL2 ( double  elevation,
double  tecval,
const std::string &  ionoMapType 
) const
inline

Get ionospheric slant delay for L2 frequency

Parameters
[in]elevationTime tag of signal (CommonTime object)
[in]tecvalTEC value as derived from IONEX file (TECU)
[in]ionoMapTypeType of ionosphere mapping function (string)
See also
IonexStore::ionoMappingFunction
Returns
Ionosphere slant delay (meters)
Exceptions
InvalidParameter

Definition at line 190 of file IonexStore.hpp.

◆ getIonoL5()

double gnsstk::IonexStore::getIonoL5 ( double  elevation,
double  tecval,
const std::string &  ionoMapType 
) const
inline

Get ionospheric slant delay for L5 frequency

Parameters
[in]elevationTime tag of signal (CommonTime object)
[in]tecvalTEC value as derived from IONEX file (TECU)
[in]ionoMapTypeType of ionosphere mapping function (string)
See also
IonexStore::ionoMappingFunction
Returns
Ionosphere slant delay (meters)
Exceptions
InvalidParameter

Definition at line 204 of file IonexStore.hpp.

◆ getIonoL6()

double gnsstk::IonexStore::getIonoL6 ( double  elevation,
double  tecval,
const std::string &  ionoMapType 
) const
inline

Get ionospheric slant delay for L6 frequency

Parameters
[in]elevationTime tag of signal (CommonTime object)
[in]tecvalTEC value as derived from IONEX file (TECU)
[in]ionoMapTypeType of ionosphere mapping function (string)
See also
IonexStore::ionoMappingFunction
Returns
Ionosphere slant delay (meters)
Exceptions
InvalidParameter

Definition at line 218 of file IonexStore.hpp.

◆ getIonoL7()

double gnsstk::IonexStore::getIonoL7 ( double  elevation,
double  tecval,
const std::string &  ionoMapType 
) const
inline

Get ionospheric slant delay for L7 frequency

Parameters
[in]elevationTime tag of signal (CommonTime object)
[in]tecvalTEC value as derived from IONEX file (TECU)
[in]ionoMapTypeType of ionosphere mapping function (string)
See also
IonexStore::ionoMappingFunction
Returns
Ionosphere slant delay (meters)
Exceptions
InvalidParameter

Definition at line 232 of file IonexStore.hpp.

◆ getIonoL8()

double gnsstk::IonexStore::getIonoL8 ( double  elevation,
double  tecval,
const std::string &  ionoMapType 
) const
inline

Get ionospheric slant delay for L8 frequency

Parameters
[in]elevationTime tag of signal (CommonTime object)
[in]tecvalTEC value as derived from IONEX file (TECU)
[in]ionoMapTypeType of ionosphere mapping function (string)
See also
IonexStore::ionoMappingFunction
Returns
Ionosphere slant delay (meters)
Exceptions
InvalidParameter

Definition at line 246 of file IonexStore.hpp.

◆ getSTEC()

double gnsstk::IonexStore::getSTEC ( double  elevation,
double  tecval,
const std::string &  ionoMapType 
) const

Get slant total electron content (STEC) in TECU

Parameters
[in]elevationTime tag of signal (CommonTime object)
[in]tecvalTEC value as derived from IONEX file (TECU)
[in]ionoMapTypeType of ionosphere mapping function (string)
See also
IonexStore::ionoMappingFunction
Returns
slant total electron content (TECU)
Exceptions
InvalidParameter

Definition at line 386 of file IonexStore.cpp.

◆ ionoMappingFunction()

double gnsstk::IonexStore::ionoMappingFunction ( double  elevation,
const std::string &  ionoMapType 
) const

Ionosphere mapping function

Parameters
[in]elevationElevation of satellite as seen at receiver (degrees).
[in]ionoMapTypeType of ionosphere mapping function (string) (0) NONE no mapping function is applied (1) SLM Single Layer Model (IGS) (2) MSLM Modified Single Layer Model (CODE) (3) ESM Extended Slab Model (JLP)

Details at: http://aiuws.unibe.ch/ionosphere/mslm.pdf

Warning
No implementation for JPL's mapping function.
Todo:
Implement ESM support in IonexStore
Todo:
Implement something for the ionoMapType "NONE" case

Definition at line 446 of file IonexStore.cpp.

◆ loadFile()

void gnsstk::IonexStore::loadFile ( const std::string &  filename)
virtual

Load the given IONEX file

Exceptions
FileMissingException

Definition at line 75 of file IonexStore.cpp.

Member Data Documentation

◆ finalTime

CommonTime gnsstk::IonexStore::finalTime
private

Definition at line 309 of file IonexStore.hpp.

◆ initialTime

CommonTime gnsstk::IonexStore::initialTime
private

These fields set the overall span of time for which this object contains data.

Warning
There may be gaps in the data, i.e. the data may not be continuous.

Definition at line 309 of file IonexStore.hpp.

◆ inxDCBMap

IonexDCBMap gnsstk::IonexStore::inxDCBMap
private

Map of DCB values (IonexHeader.firstEpoch, IonexHeader.svsmap)

Definition at line 324 of file IonexStore.hpp.

◆ inxMaps

IonexMap gnsstk::IonexStore::inxMaps
private

Map of IONEX maps.

Definition at line 318 of file IonexStore.hpp.


The documentation for this class was generated from the following files:


gnsstk
Author(s):
autogenerated on Wed Oct 25 2023 02:40:45