GPLIB++
|
The class MTStation is used to store the transfer functions and related information for a MT-site. More...
#include <MTStation.h>
Public Types | |
enum | tmtdataformat { unknown, mtt, j, edi, pek, nc, zmm, mtf } |
Public Member Functions | |
void | AssignAll (const int nfreq) |
void | Rotate (const double rotangle) |
void | Rotate (void) |
Rotate to zero rotation angle. More... | |
trealdata | GetFrequencies () const |
return the available frequencies in a single vector More... | |
void | SetFrequencies (const trealdata &freqs) |
Set the frequencies of the tensor elements, invalidates the previously stored impedance data, mainly for creating synthetic data. More... | |
double | GetLatitude () const |
access funtion for Latitude More... | |
void | SetLatitude (double lat) |
double | GetLongitude () const |
void | SetLongitude (double lon) |
double | GetElevation () const |
std::string | GetName () |
double | GetAzimuth () const |
const MTTensor & | at (const unsigned int i) const |
direct acces to a tensor at a given index More... | |
const std::vector< MTTensor > & | GetMTData () const |
Get the full vector of Tensor elements read only. More... | |
std::vector< MTTensor > & | SetMTData () |
Get the full vector of Tensor elements for reading and writing. More... | |
virtual MTStation * | clone () const |
for parallel runs we need to make a copy of the object and its derived classes More... | |
MTStation & | operator= (const MTStation &source) |
MTStation () | |
MTStation (const MTStation &old) | |
MTStation (const int size) | |
MTStation (const std::string filename) | |
virtual | ~MTStation () |
virtual void | GetData (const std::string filename) |
read in data from file, determines format by ending More... | |
virtual void | GetData () |
virtual void | WriteData (const std::string filename) |
void | WriteAsMtt (const std::string filename) |
Write data in goettingen .mtt format. More... | |
void | WriteAsEdi (const std::string filename) |
Write data as edi (no functionality yet) More... | |
void | WriteAsJ (const std::string filename) |
Write data to j-file. More... | |
void | WriteBack () |
Write data back in original format, with filename given by station name. More... | |
Protected Member Functions | |
void | Update () |
Update all derived quantities. More... | |
void | Assign (const int nfreq) |
Assign() assigns zero to all derived quantities, this makes the calculation. More... | |
Friends | |
class | C1DMTSynthData |
The class MTStation is used to store the transfer functions and related information for a MT-site.
Definition at line 17 of file MTStation.h.
Enumerator | |
---|---|
unknown | |
mtt | |
j | |
edi | |
pek | |
nc | |
zmm | |
mtf |
Definition at line 20 of file MTStation.h.
gplib::MTStation::MTStation | ( | ) |
Definition at line 49 of file MTStation.cpp.
Referenced by clone().
gplib::MTStation::MTStation | ( | const MTStation & | old | ) |
Definition at line 824 of file MTStation.cpp.
References Update().
gplib::MTStation::MTStation | ( | const int | size | ) |
Definition at line 64 of file MTStation.cpp.
References Assign().
gplib::MTStation::MTStation | ( | const std::string | filename | ) |
Definition at line 58 of file MTStation.cpp.
|
virtual |
Definition at line 54 of file MTStation.cpp.
|
protected |
Assign() assigns zero to all derived quantities, this makes the calculation.
Definition at line 74 of file MTStation.cpp.
Referenced by AssignAll(), gplib::C1DMTSynthData::CalcSynthetic(), gplib::C1DAnisoMTSynthData::GetData(), and MTStation().
void gplib::MTStation::AssignAll | ( | const int | nfreq | ) |
Definition at line 70 of file MTStation.cpp.
References Assign().
|
inline |
direct acces to a tensor at a given index
Definition at line 114 of file MTStation.h.
Referenced by gplib::PTensorMTStation::operator=(), PrintComponent(), gplib::PTensor1DMTObjective::SafeParallel(), and WriteToFile().
|
inlinevirtual |
for parallel runs we need to make a copy of the object and its derived classes
Reimplemented in gplib::C1DAnisoMTSynthData, and gplib::C1DMTSynthData.
Definition at line 129 of file MTStation.h.
References MTStation().
|
inline |
Definition at line 108 of file MTStation.h.
|
virtual |
read in data from file, determines format by ending
Definition at line 597 of file MTStation.cpp.
References edi, j, mtf, gplib::MTFileTypes, mtt, nc, pek, Rotate(), unknown, and zmm.
Referenced by gplib::MTStationList::GetData(), init(), and main().
|
inlinevirtual |
Reimplemented in gplib::C1DAnisoMTSynthData.
Definition at line 141 of file MTStation.h.
|
inline |
Definition at line 100 of file MTStation.h.
trealdata gplib::MTStation::GetFrequencies | ( | ) | const |
return the available frequencies in a single vector
Return a vector containing the available frequencies; This should be rewritten to be more efficient
Definition at line 136 of file MTStation.cpp.
Referenced by gplib::C1DMTSynthData::CalcSynthetic(), gplib::C1DAnisoMTSynthData::GetData(), main(), gplib::PTensor1DMTObjective::SafeParallel(), and gplib::C1DMTObjective::SafeParallel().
|
inline |
access funtion for Latitude
Definition at line 84 of file MTStation.h.
Referenced by PrintComponent().
|
inline |
Definition at line 92 of file MTStation.h.
Referenced by PrintComponent().
|
inline |
Get the full vector of Tensor elements read only.
Definition at line 119 of file MTStation.h.
Referenced by main(), gplib::PTensorMTStation::operator=(), PrintComponent(), gplib::C1DMTObjective::SafeParallel(), WriteParameterToFile(), and WriteToFile().
|
inline |
Definition at line 104 of file MTStation.h.
Referenced by main(), gplib::HasSameName::operator()(), and PrintComponent().
Definition at line 832 of file MTStation.cpp.
References Update().
void gplib::MTStation::Rotate | ( | const double | rotangle | ) |
Given a rotation angle in radian this method rotates the impedance tensor and updates all derived quantities
Rotate(const double rotangle) rotates the impedance tensor by the angle rotangle in radian and updates all derived quantities
Definition at line 115 of file MTStation.cpp.
References Update().
void gplib::MTStation::Rotate | ( | void | ) |
Rotate to zero rotation angle.
Rotate() rotates the impedance tensor by the negative of the angle given in the rotangles field
Definition at line 126 of file MTStation.cpp.
References Update().
Referenced by GetData().
void gplib::MTStation::SetFrequencies | ( | const trealdata & | freqs | ) |
Set the frequencies of the tensor elements, invalidates the previously stored impedance data, mainly for creating synthetic data.
Definition at line 144 of file MTStation.cpp.
Referenced by main(), gplib::PTensor1DMTObjective::SafeParallel(), and gplib::C1DMTObjective::SafeParallel().
|
inline |
Definition at line 88 of file MTStation.h.
Referenced by gplib::MTStationList::GetData().
|
inline |
Definition at line 96 of file MTStation.h.
Referenced by gplib::MTStationList::GetData().
|
inline |
Get the full vector of Tensor elements for reading and writing.
Definition at line 124 of file MTStation.h.
Referenced by main(), and PrintComponent().
|
protected |
Update all derived quantities.
The Update() method first updates all components individually and then recalculates all derived quantities that depend on more than one component
Definition at line 84 of file MTStation.cpp.
Referenced by gplib::C1DMTSynthData::CalcSynthetic(), gplib::C1DAnisoMTSynthData::GetData(), MTStation(), operator=(), Rotate(), and WriteAsMtt().
void gplib::MTStation::WriteAsEdi | ( | const std::string | filename | ) |
Write data as edi (no functionality yet)
Definition at line 687 of file MTStation.cpp.
Referenced by WriteBack().
void gplib::MTStation::WriteAsJ | ( | const std::string | filename | ) |
Write data to j-file.
Definition at line 714 of file MTStation.cpp.
References gplib::MTTensor::GetdZxx(), gplib::MTTensor::GetdZxy(), gplib::MTTensor::GetdZyx(), gplib::MTTensor::GetdZyy(), gplib::MTTensor::GetZxx(), gplib::MTTensor::GetZxy(), gplib::MTTensor::GetZyx(), and gplib::MTTensor::GetZyy().
Referenced by main(), and WriteBack().
void gplib::MTStation::WriteAsMtt | ( | const std::string | filename | ) |
Write data in goettingen .mtt format.
Definition at line 681 of file MTStation.cpp.
References Update().
Referenced by main(), WriteBack(), gplib::Aniso1DMTObjective::WriteData(), gplib::PTensor1DMTObjective::WriteData(), and gplib::Iso1DMTObjective::WriteData().
void gplib::MTStation::WriteBack | ( | ) |
Write data back in original format, with filename given by station name.
Definition at line 661 of file MTStation.cpp.
References edi, j, mtt, WriteAsEdi(), WriteAsJ(), and WriteAsMtt().
Referenced by WriteData().
|
virtual |
Definition at line 655 of file MTStation.cpp.
References WriteBack().
|
friend |
Definition at line 146 of file MTStation.h.