27#ifndef GMODELSPECTRALEXPONENTIAL_HPP
28#define GMODELSPECTRALEXPONENTIAL_HPP
67 virtual void clear(
void);
69 virtual std::string
classname(
void)
const;
70 virtual std::string
type(
void)
const;
73 const bool& gradients =
false)
const;
146 return (
"GModelSpectralExponential");
Energy value class definition.
Single parameter function abstract base class definition.
Spectral nodes model class definition.
Abstract spectral model base class interface definition.
GVector exp(const GVector &vector)
Computes exponential of vector elements.
Class that handles energies in a unit independent way.
Single parameter function abstract base class.
double eval(const double &x)
eflux_kern(const GModelSpectral *spec)
const GModelSpectral * m_exp
double eval(const double &x)
flux_kern(const GModelSpectral *spec)
Exponential spectral model class.
void copy_members(const GModelSpectralExponential &model)
Copy class members.
void init_members(void)
Initialise class members.
void free_members(void)
Delete class members.
std::vector< double > m_mc_values
Parameter values.
const GModelSpectral * exponent(void) const
Return exponent.
virtual void write(GXmlElement &xml) const
Write model into XML element.
virtual GEnergy mc(const GEnergy &emin, const GEnergy &emax, const GTime &time, GRan &ran) const
Returns Monte Carlo energy between [emin, emax].
GModelSpectralNodes m_mc_spectrum
MC spectrum cache.
virtual double eval(const GEnergy &srcEng, const GTime &srcTime=GTime(), const bool &gradients=false) const
Evaluate function.
virtual std::string classname(void) const
Return class name.
GEnergy m_mc_emax
Last maximum energy.
void update_mc_cache(const GEnergy &emin, const GEnergy &emax) const
Update Monte Carlo pre computation cache.
virtual std::string print(const GChatter &chatter=NORMAL) const
Print Exponential spectral model information.
GModelSpectralExponential(void)
Void constructor.
GEnergy m_mc_emin
Last minimum energy.
virtual double eflux(const GEnergy &emin, const GEnergy &emax) const
Returns model energy flux between [emin, emax] (units: erg/cm2/s)
virtual ~GModelSpectralExponential(void)
Destructor.
GModelSpectral * m_exponent
Exponent model component.
virtual std::string type(void) const
Return model type.
virtual double flux(const GEnergy &emin, const GEnergy &emax) const
Returns model photon flux between [emin, emax] (units: ph/cm2/s)
virtual GModelSpectralExponential * clone(void) const
Clone Exponential spectral model model.
std::string m_type
Model type.
virtual GModelSpectralExponential & operator=(const GModelSpectralExponential &model)
Assignment operator.
virtual void read(const GXmlElement &xml)
Read model from XML element.
virtual void clear(void)
Clear Exponential spectral model.
Spectral nodes model class.
Abstract spectral model base class.
virtual double eval(const GEnergy &srcEng, const GTime &srcTime=GTime(), const bool &gradients=false) const =0
Random number generator class.