27#ifndef GMODELSPECTRAL_HPP
28#define GMODELSPECTRAL_HPP
87 virtual std::string
type(
void)
const = 0;
90 const bool& gradients =
false)
const = 0;
104 bool has_par(
const std::string& name)
const;
105 int size(
void)
const;
159 return (
int)
m_pars.size();
Definition of interface for all GammaLib classes.
Time class interface definition.
Interface class for all GammaLib classes.
Class that handles energies in a unit independent way.
Abstract spectral model base class.
bool has_par(const std::string &name) const
Checks if parameter name exists.
virtual double eval(const GEnergy &srcEng, const GTime &srcTime=GTime(), const bool &gradients=false) const =0
void free_members(void)
Delete class members.
virtual void read(const GXmlElement &xml)=0
GModelPar & at(const int &index)
Returns model parameter.
virtual GModelSpectral & operator=(const GModelSpectral &model)
Assignment operator.
void copy_members(const GModelSpectral &model)
Copy class members.
virtual GEnergy mc(const GEnergy &emin, const GEnergy &emax, const GTime &time, GRan &ran) const =0
virtual ~GModelSpectral(void)
Destructor.
virtual GModelPar & operator[](const int &index)
Returns model parameter.
std::vector< GModelPar * > m_pars
Parameter pointers.
virtual double flux(const GEnergy &emin, const GEnergy &emax) const =0
void autoscale(void)
Autoscale parameters.
virtual void clear(void)=0
Clear object.
virtual GModelSpectral * clone(void) const =0
Clones object.
virtual void write(GXmlElement &xml) const =0
virtual std::string print(const GChatter &chatter=NORMAL) const =0
Print content of object.
virtual double eflux(const GEnergy &emin, const GEnergy &emax) const =0
virtual std::string classname(void) const =0
Return class name.
virtual std::string type(void) const =0
int size(void) const
Return number of parameters.
GModelSpectral(void)
Void constructor.
void init_members(void)
Initialise class members.
Random number generator class.