ReFRACtor
temperature.h
Go to the documentation of this file.
1 #ifndef TEMPERATURE_H
2 #define TEMPERATURE_H
4 #include "observer.h"
5 #include "auto_derivative.h"
6 #include "array_with_unit.h"
7 #include "pressure.h"
8 
9 namespace FullPhysics {
10 /****************************************************************/
22 class Temperature : virtual public StateVectorObserver,
23  public Observable<Temperature> {
24 public:
25  virtual ~Temperature() {}
26  virtual void add_observer(Observer<Temperature>& Obs)
27  { add_observer_do(Obs, *this);}
29  { remove_observer_do(Obs, *this);}
30 
31 //-----------------------------------------------------------------------
44 //-----------------------------------------------------------------------
45 
47  {
48  blitz::Array<double, 1> empty;
49  return ArrayWithUnit<double, 1>(empty, units::Pa);
50  }
51 
52 //-----------------------------------------------------------------------
56 //-----------------------------------------------------------------------
57 
59  temperature(const AutoDerivativeWithUnit<double>& Press) const = 0;
60 
62 
63 //-----------------------------------------------------------------------
70 //-----------------------------------------------------------------------
71 
72  virtual boost::shared_ptr<Temperature> clone() const = 0;
73 
74 //-----------------------------------------------------------------------
79 //-----------------------------------------------------------------------
80 
82  clone(const boost::shared_ptr<Pressure>& Press) const = 0;
83 };
84 }
85 #endif
virtual ArrayAdWithUnit< double, 1 > temperature_grid(const Pressure &P) const
Return temperature at the pressure grid.
Definition: temperature.cc:15
virtual void add_observer(Observer< Temperature > &Obs)
Add an observer.
Definition: temperature.h:26
This is a AutoDerivative that also has units associated with it.
virtual AutoDerivativeWithUnit< double > temperature(const AutoDerivativeWithUnit< double > &Press) const =0
Return the temperature at the given pressure (in Pascals)
void add_observer_do(Observer< Temperature > &Obs, Temperature &t)
Add an observer.
Definition: observer.h:148
const Unit Pa("Pa", N/(m *m))
This is an observer of a StateVector.
void remove_observer_do(Observer< Temperature > &Obs, Temperature &t)
Remove an observer.
Definition: observer.h:173
Mixin for a class that allows other classes to observe it state.
Definition: observer.h:12
virtual boost::shared_ptr< Temperature > clone() const =0
Clone a Temperature object.
This class maintains the pressure portion of the state.
Definition: pressure.h:32
Contains classes to abstract away details in various Spurr Radiative Transfer software.
Definition: doxygen_python.h:1
virtual ArrayWithUnit< double, 1 > important_pressure_level() const
The temperature can vary quickly over a small pressure range, e.g.
Definition: temperature.h:46
This class maintains the temperature portion of the state.
Definition: temperature.h:22
virtual void remove_observer(Observer< Temperature > &Obs)
Remove an observer.
Definition: temperature.h:28

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