ReFRACtor
named_spectrum.h
Go to the documentation of this file.
1 #ifndef NAMED_SPECTRUM_H
2 #define NAMED_SPECTRUM_H
3 
4 #include "spectrum.h"
5 
6 namespace FullPhysics {
7 /****************************************************************/
15 class NamedSpectrum: public Spectrum {
16 public:
17 //-----------------------------------------------------------------------
19 //-----------------------------------------------------------------------
20 
21  NamedSpectrum(const SpectralDomain& Spec_domain,
22  const SpectralRange& Spec_range, const std::string& Name,
23  int Index)
24  : Spectrum(Spec_domain, Spec_range), name_(Name), index_(Index) {}
25 
26  NamedSpectrum(const Spectrum& Spec, const std::string& Name, int Index)
27  : Spectrum(Spec.spectral_domain(), Spec.spectral_range()),
28  name_(Name), index_(Index) {}
29 
30 //-----------------------------------------------------------------------
32 //-----------------------------------------------------------------------
33 
34  virtual const std::string& name() const {return name_;}
35 
36 //-----------------------------------------------------------------------
38 //-----------------------------------------------------------------------
39 
40  virtual int index() const {return index_;}
41 
42  void print(std::ostream& Os)
43  {
44  Os << "NamedSpectrum:" << std::endl
45  << " name: " << name_ << std::endl
46  << " index: " << index_;
47  }
48 
51 
52 private:
53  std::string name_;
54  int index_;
55 };
56 }
57 #endif
virtual int index() const
An reference index for the spectrum, ie a spectrometer index.
For different instruments, it is more natural to either work with wavenumbers (e.g., GOSAT) or wavelength (e.g., OCO).
const SpectralRange & spectral_range() const
Spectral range (e.g, radiance values)
Definition: spectrum.h:39
virtual const std::string & name() const
Name that makes this a named spectrum.
Adds name and spec index fields to a Spectrum.
NamedSpectrum(const Spectrum &Spec, const std::string &Name, int Index)
This is a full spectrum, which contains a SpectralRange and SpectralDomain.
Definition: spectrum.h:18
NamedSpectrum(const SpectralDomain &Spec_domain, const SpectralRange &Spec_range, const std::string &Name, int Index)
Constructor.
We have a number of different spectrums that appear in different parts of the code.
Contains classes to abstract away details in various Spurr Radiative Transfer software.
Definition: doxygen_python.h:1
NamedSpectrum()
Default constructor needed for SWIG.
const SpectralDomain & spectral_domain() const
Spectral domain (i.e., wavenumber or wavelength).
Definition: spectrum.h:32
void print(std::ostream &Os)

Copyright © 2017, California Institute of Technology.
ALL RIGHTS RESERVED.
U.S. Government Sponsorship acknowledged.
Generated Fri Aug 24 2018 15:44:11