ReFRACtor
spectral_window_range.h
Go to the documentation of this file.
1 #ifndef SPECTRAL_WINDOW_RANGE_H
2 #define SPECTRAL_WINDOW_RANGE_H
3 
4 #include "spectral_window.h"
5 #include "array_with_unit.h"
6 
7 namespace FullPhysics {
8  class Dispersion;
9 
10 /****************************************************************/
21 public:
22  SpectralWindowRange(const ArrayWithUnit<double, 3>& Microwindow_ranges);
23 
24  template<class T>
25  SpectralWindowRange(const ArrayWithUnit<double, 3>& Microwindow_ranges,
26  const blitz::Array<T, 2>& Bad_sample_mask);
27  virtual ~SpectralWindowRange() {}
28 
29 //-----------------------------------------------------------------------
32 //-----------------------------------------------------------------------
33 
34  const std::vector<boost::shared_ptr<Dispersion> >& dispersion() const
35  {return disp_;}
36  void dispersion(const std::vector<boost::shared_ptr<Dispersion> >& D)
37  { disp_ = D; }
38 
39  virtual int number_spectrometer() const {return range_.value.rows();}
40  virtual SpectralBound spectral_bound() const;
41  virtual std::vector<int> grid_indexes(const SpectralDomain& Grid,
42  int Spec_index) const;
43  void print(std::ostream& Os) const;
44  const ArrayWithUnit<double, 3>& range_array() const {return range_;}
46  { range_ = Ran;}
47  const blitz::Array<bool, 2>& bad_sample_mask() const
48  { return bad_sample_mask_; }
49  void bad_sample_mask(const blitz::Array<bool, 2>& M)
50  { bad_sample_mask_.reference(M.copy()); }
51 private:
53  // Mask of bad samples, True for a bad sample, False for a good one
54  blitz::Array<bool, 2> bad_sample_mask_;
55  std::vector<boost::shared_ptr<Dispersion> > disp_;
56 };
57 }
58 #endif
void print(std::ostream &Os) const
Print to a stream.
SpectralWindowRange(const ArrayWithUnit< double, 3 > &Microwindow_ranges)
Construct a new window from the supplied information.
void bad_sample_mask(const blitz::Array< bool, 2 > &M)
virtual SpectralBound spectral_bound() const
Bounds of spectral window.
const ArrayWithUnit< double, 3 > & range_array() const
For different instruments, it is more natural to either work with wavenumbers (e.g., GOSAT) or wavelength (e.g., OCO).
blitz::Array< T, D > value
virtual std::vector< int > grid_indexes(const SpectralDomain &Grid, int Spec_index) const
Given a list of wavenumbers, this returns the indices that fall within the window.
This is an implementation of a SpectralWindow that covers a fixed window.
This gives the upper and lower bounds of the SpectralWindow.
void dispersion(const std::vector< boost::shared_ptr< Dispersion > > &D)
This class represents a the spectral window.
virtual int number_spectrometer() const
Number of spectrometers.
Contains classes to abstract away details in various Spurr Radiative Transfer software.
Definition: doxygen_python.h:1
const blitz::Array< bool, 2 > & bad_sample_mask() const
void range_array(const ArrayWithUnit< double, 3 > &Ran)
const std::vector< boost::shared_ptr< Dispersion > > & dispersion() const
The Dispersion is optional.

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