Classes | List of all members
gnsstk::IonexData Class Reference

Detailed Description

This class models a IONEX Data Record.

See also
gnsstk::IonexStream and gnsstk::IonexHeader
main ionex test.cpp for example

Definition at line 70 of file IonexData.hpp.

#include <IonexData.hpp>

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

Classes

struct  IonexValType
 A structure used to store IONEX Value Types. More...
 

Static Public Attributes

IonexDataFormatStrings

IONEX Data Formatting Strings

static const GNSSTK_EXPORT std::string startTecMapString = "START OF TEC MAP"
 "START OF TEC MAP" More...
 
static const GNSSTK_EXPORT std::string startRmsMapString = "START OF RMS MAP"
 "START OF RMS MAP" More...
 
static const GNSSTK_EXPORT std::string startHgtMapString = "START OF HEIGHT MAP"
 "START OF HEIGHT MAP" More...
 
static const GNSSTK_EXPORT std::string currentEpochString = "EPOCH OF CURRENT MAP"
 "EPOCH OF CURRENT MAP" More...
 
static const GNSSTK_EXPORT std::string dataBlockString = "LAT/LON1/LON2/DLON/H"
 "LAT/LON1/LON2/DLON/H" More...
 
static const GNSSTK_EXPORT std::string endTecMapString = "END OF TEC MAP"
 "END OF TEC MAP" More...
 
static const GNSSTK_EXPORT std::string endRmsMapString = "END OF RMS MAP"
 "END OF RMS MAP" More...
 
static const GNSSTK_EXPORT std::string endHgtMapString = "END OF HEIGHT MAP"
 "END OF HEIGHT MAP" More...
 
static const GNSSTK_EXPORT std::string endOfFile = "END OF FILE"
 "END OF FILE" More...
 
Standard IONEX value types
static const GNSSTK_EXPORT IonexValType UN
 
static const GNSSTK_EXPORT IonexValType TEC
 
static const GNSSTK_EXPORT IonexValType RMS
 

IonexDataValues

int mapID
 denote the internal number of the current map More...
 
int dim [3]
 How many values are along latitude, longitude, height. More...
 
CommonTime time
 the time corresponding to the current data records More...
 
IonexValType type
 Type of data either TEC or RMS. More...
 
Vector< double > data
 TEC or RMS data. More...
 
int exponent
 Exponent defining the unit of the values. More...
 
double lat [3]
 Definition of a grid in latitude. More...
 
double lon [3]
 Definition of a grid in longitude. More...
 
double hgt [3]
 Definition of a grid in height. More...
 
bool valid
 Validity flag. More...
 
 IonexData ()
 Default constructor. More...
 
virtual ~IonexData ()
 Destructor. More...
 
virtual bool isData () const
 IonexData is a "data", so this function always returns true. More...
 
virtual bool isValid () const
 Am I an valid object? More...
 
virtual void dump (std::ostream &s=std::cout) const
 A debug output function. More...
 
int getIndex (const Triple &in, int igp, Triple &out) const
 
double getValue (const Position &pos) const
 
void reallyPutRecord (FFStream &s) const override
 
void reallyGetRecord (FFStream &s) override
 
std::string writeTime (const CommonTime &dt) const
 
CommonTime parseTime (const std::string &line) const
 

Additional Inherited Members

- Public Member Functions inherited from gnsstk::IonexBase
virtual ~IonexBase ()
 Destructor per the coding standards. More...
 
- Public Member Functions inherited from gnsstk::FFData
void getRecord (FFStream &s)
 
virtual bool isHeader () const
 
void putRecord (FFStream &s) const
 
virtual ~FFData (void)
 virtual desctuctor More...
 

Constructor & Destructor Documentation

◆ IonexData()

gnsstk::IonexData::IonexData ( )

Default constructor.

Definition at line 98 of file IonexData.cpp.

◆ ~IonexData()

gnsstk::IonexData::~IonexData ( )
virtual

Destructor.

Definition at line 105 of file IonexData.cpp.

Member Function Documentation

◆ dump()

void gnsstk::IonexData::dump ( std::ostream &  s = std::cout) const
virtual

A debug output function.

Reimplemented from gnsstk::FFData.

Definition at line 409 of file IonexData.cpp.

◆ getIndex()

int gnsstk::IonexData::getIndex ( const Triple in,
int  igp,
Triple out 
) const

Get the position of a grid point based on input position

Parameters
[in]ininput lat, lon and height
[in]igpgrid point to be returned (1) neareast grid point (2) lower left hand grid point
[out]outlat, lon and height
Returns
the index within the data
Warning
Keep in mind the assumptions of IONEX grid (i.e., latitude between [87.5, -87.5], longitude between [-180, 180]) when you construct a Triple object.

Definition at line 427 of file IonexData.cpp.

◆ getValue()

double gnsstk::IonexData::getValue ( const Position pos) const

Get IONEX TEC or RMS value as a function of the position and nominal height.

A simple 4-point formula is applied to interpolate between grid points.

For more information see page 3 of IONEX manual:

http://igscb.jpl.nasa.gov/igscb/data/format/ionex1.pdf

Parameters
[in]posinput position (Position object).
Returns
Computed TEC or RMS value.
Exceptions
InvalidRequest
FFStreamError

Definition at line 519 of file IonexData.cpp.

◆ isData()

virtual bool gnsstk::IonexData::isData ( ) const
inlinevirtual

IonexData is a "data", so this function always returns true.

Reimplemented from gnsstk::FFData.

Definition at line 155 of file IonexData.hpp.

◆ isValid()

virtual bool gnsstk::IonexData::isValid ( ) const
inlinevirtual

Am I an valid object?

Definition at line 160 of file IonexData.hpp.

◆ parseTime()

CommonTime gnsstk::IonexData::parseTime ( const std::string &  line) const
private

This function constructs a CommonTime object from the given parameters.

Parameters
lineEncoded time string found in the IONEX record.

Definition at line 608 of file IonexData.cpp.

◆ reallyGetRecord()

void gnsstk::IonexData::reallyGetRecord ( FFStream s)
overrideprotectedvirtual

This function obtains a IONEX Data record from the given FFStream.

If there is an error reading the stream, it is reset to its original position and its fail-bit is set.

Exceptions
std::exception
StringExceptionwhen a StringUtils function fails
FFStreamErrorwhen exceptions(failbit) is set and a read or formatting error occurs. This also resets the stream to its pre-read position.

Implements gnsstk::FFData.

Definition at line 227 of file IonexData.cpp.

◆ reallyPutRecord()

void gnsstk::IonexData::reallyPutRecord ( FFStream s) const
overrideprotectedvirtual

Writes a correctly formatted record from this data to stream s.

Exceptions
std::exception
FFStreamError
StringExceptionwhen a StringUtils function fails

Implements gnsstk::FFData.

Definition at line 112 of file IonexData.cpp.

◆ writeTime()

string gnsstk::IonexData::writeTime ( const CommonTime dt) const
private

Writes the CommonTime object into IONEX format. If it's a bad time, it will return blanks.

Parameters
dttime to be written into a IONEX data record.
Exceptions
StringUtils::StringException

Definition at line 623 of file IonexData.cpp.

Member Data Documentation

◆ currentEpochString

const string gnsstk::IonexData::currentEpochString = "EPOCH OF CURRENT MAP"
static

"EPOCH OF CURRENT MAP"

Definition at line 86 of file IonexData.hpp.

◆ data

Vector<double> gnsstk::IonexData::data

TEC or RMS data.

Definition at line 136 of file IonexData.hpp.

◆ dataBlockString

const string gnsstk::IonexData::dataBlockString = "LAT/LON1/LON2/DLON/H"
static

"LAT/LON1/LON2/DLON/H"

Definition at line 88 of file IonexData.hpp.

◆ dim

int gnsstk::IonexData::dim[3]

How many values are along latitude, longitude, height.

Definition at line 132 of file IonexData.hpp.

◆ endHgtMapString

const string gnsstk::IonexData::endHgtMapString = "END OF HEIGHT MAP"
static

"END OF HEIGHT MAP"

Definition at line 94 of file IonexData.hpp.

◆ endOfFile

const string gnsstk::IonexData::endOfFile = "END OF FILE"
static

"END OF FILE"

Definition at line 96 of file IonexData.hpp.

◆ endRmsMapString

const string gnsstk::IonexData::endRmsMapString = "END OF RMS MAP"
static

"END OF RMS MAP"

Definition at line 92 of file IonexData.hpp.

◆ endTecMapString

const string gnsstk::IonexData::endTecMapString = "END OF TEC MAP"
static

"END OF TEC MAP"

Definition at line 90 of file IonexData.hpp.

◆ exponent

int gnsstk::IonexData::exponent

Exponent defining the unit of the values.

Definition at line 139 of file IonexData.hpp.

◆ hgt

double gnsstk::IonexData::hgt[3]

Definition of a grid in height.

Definition at line 143 of file IonexData.hpp.

◆ lat

double gnsstk::IonexData::lat[3]

Definition of a grid in latitude.

Definition at line 141 of file IonexData.hpp.

◆ lon

double gnsstk::IonexData::lon[3]

Definition of a grid in longitude.

Definition at line 142 of file IonexData.hpp.

◆ mapID

int gnsstk::IonexData::mapID

denote the internal number of the current map

Definition at line 131 of file IonexData.hpp.

◆ RMS

const IonexData::IonexValType gnsstk::IonexData::RMS
static

Definition at line 123 of file IonexData.hpp.

◆ startHgtMapString

const string gnsstk::IonexData::startHgtMapString = "START OF HEIGHT MAP"
static

"START OF HEIGHT MAP"

Definition at line 84 of file IonexData.hpp.

◆ startRmsMapString

const string gnsstk::IonexData::startRmsMapString = "START OF RMS MAP"
static

"START OF RMS MAP"

Definition at line 82 of file IonexData.hpp.

◆ startTecMapString

const string gnsstk::IonexData::startTecMapString = "START OF TEC MAP"
static

"START OF TEC MAP"

Definition at line 80 of file IonexData.hpp.

◆ TEC

const IonexData::IonexValType gnsstk::IonexData::TEC
static

Definition at line 121 of file IonexData.hpp.

◆ time

CommonTime gnsstk::IonexData::time

the time corresponding to the current data records

Definition at line 133 of file IonexData.hpp.

◆ type

IonexValType gnsstk::IonexData::type

Type of data either TEC or RMS.

Definition at line 135 of file IonexData.hpp.

◆ UN

const IonexData::IonexValType gnsstk::IonexData::UN
static

Definition at line 119 of file IonexData.hpp.

◆ valid

bool gnsstk::IonexData::valid

Validity flag.

Definition at line 145 of file IonexData.hpp.


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


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