1 #ifndef ABSORBER_VMR_LEVEL_H 2 #define ABSORBER_VMR_LEVEL_H 5 #include <boost/lexical_cast.hpp> 18 const blitz::Array<double, 1>& Vmr,
19 const blitz::Array<bool, 1>& Vmr_flag,
20 const std::string& Gas_name);
22 virtual void print(std::ostream& Os)
const;
25 {
return gas_name() +
" VMR for Press Lvl " +
26 boost::lexical_cast<std::string>(i + 1); }
45 using namespace blitz;
46 firstIndex i1; secondIndex i2; thirdIndex i3; fourthIndex i4;
48 Array<double, 2> res(vmrv.
rows(), vmrv.
rows());
55 Array<double, 2> dvmr_dstate(vmrv.
jacobian());
56 Array<double, 2> t(dvmr_dstate.rows(),
sv_cov_full.cols()) ;
57 t = sum(dvmr_dstate(i1, i3) *
sv_cov_full(i3, i2), i3);
58 res = sum(t(i1, i3) * dvmr_dstate(i2, i3), i3);
70 blitz::Array<double, 1> res(vmrcov.rows());
71 for(
int i = 0; i < res.rows(); ++i)
72 res(i) = (vmrcov(i, i) > 0 ? sqrt(vmrcov(i, i)) : 0.0);
virtual std::string state_vector_name_i(int i) const
Return state vector name for ith entry in coeff.
AbsorberVmrLevel(const boost::shared_ptr< Pressure > &Press, const blitz::Array< double, 1 > &Vmr, const blitz::Array< bool, 1 > &Vmr_flag, const std::string &Gas_name)
Constructor.
const blitz::Array< T, D+1 > jacobian() const
As a design principle, we have each base class with the absolutely minimum interface needed for use f...
virtual boost::shared_ptr< AbsorberVmr > clone() const
Clone a AbsorberVmr object.
Apply value function to a blitz array.
const blitz::Array< T, D > & value() const
This class maps the state vector to the absorber VMR on each level.
blitz::Array< double, 1 > vmr_uncertainty() const
Uncertainty of VMR.
virtual void calc_vmr() const
Derived classes should provide a function to fill in vmr when this is called.
blitz::Array< double, 2 > vmr_covariance() const
Covariance of vmr profile.
blitz::Array< double, 1 > vmr_profile() const
VMR on the pressure grid.
virtual std::string sub_state_identifier() const
Return a string to identify this part of the state, this name should be all lower case and seperate p...
Contains classes to abstract away details in various Spurr Radiative Transfer software.
ArrayAd< double, 1 > coeff
Coefficients.
blitz::Array< double, 2 > sv_cov_full
The last full covariance matrix we have been with, saved for reference by derived class...
virtual void print(std::ostream &Os) const
Print to stream.
virtual std::string gas_name() const
This indicates the name of this particular Absorber.
virtual ~AbsorberVmrLevel()