mxlib
c++ tools for analyzing astronomical data and other tasks by Jared R. Males. [git repo]
|
A basic spectrum.
Definition at line 24 of file astroSpectra.hpp.
#include <astro/astroSpectra.hpp>
Public Types | |
typedef std::string | paramsT |
The parameter is a string name. More... | |
Static Public Member Functions | |
static std::string | fileName (const paramsT &name) |
This function should calculate the file name (without the path) for the spectrum parameters. More... | |
static int | readSpectrum (std::vector< realT > &rawLambda, std::vector< realT > &rawSpectrum, const std::string &path, const paramsT ¶ms) |
This function reads the spectrum, returning its raw wavelength and spectrum points. More... | |
Static Public Attributes | |
static constexpr realT | wavelengthUnits = static_cast<realT>(1) |
Specify how to convert to SI wavelength units. No conversions are performed in the basic spectrum. More... | |
static constexpr realT | fluxUnits = static_cast<realT>(1) |
Specify how to convert to SI flux units. No conversions are performed in the basic spectrum. More... | |
static constexpr const char * | dataDirEnvVar = 0 |
The data directory environment variable name. More... | |
typedef std::string mx::astro::basicSpectrum< _units >::paramsT |
The parameter is a string name.
Definition at line 31 of file astroSpectra.hpp.
|
inlinestatic |
This function should calculate the file name (without the path) for the spectrum parameters.
[in] | name | The parameters of the spectrum, in this case just its file name. |
Definition at line 43 of file astroSpectra.hpp.
|
inlinestatic |
This function reads the spectrum, returning its raw wavelength and spectrum points.
No unit conversions or interpolations should take place.
[out] | rawLambda | the raw wavelength vector. This should be an empty vector on input. |
[out] | rawSpectrum | the raw spectrum. This should be an empty vector on input. |
[in] | path | the full path to the file. |
[in] | params | the parameters are passed in case needed to construct the spectrum |
Definition at line 51 of file astroSpectra.hpp.
References mx::ioutils::readColumns().
|
staticconstexpr |
The data directory environment variable name.
Definition at line 40 of file astroSpectra.hpp.
|
staticconstexpr |
Specify how to convert to SI flux units. No conversions are performed in the basic spectrum.
Definition at line 37 of file astroSpectra.hpp.
|
staticconstexpr |
Specify how to convert to SI wavelength units. No conversions are performed in the basic spectrum.
Definition at line 34 of file astroSpectra.hpp.