27 #ifndef GMODELTEMPORALPHASECURVE_HPP
28 #define GMODELTEMPORALPHASECURVE_HPP
88 const double&
norm = 1.0,
97 virtual void clear(
void);
99 virtual std::string
classname(
void)
const;
100 virtual std::string
type(
void)
const;
101 virtual double eval(
const GTime& srcTime,
102 const bool& gradients =
false)
const;
112 double norm(
void)
const;
113 void norm(
const double& norm);
116 double phase(
void)
const;
118 void phase(
const double& phase);
119 double value(
const double& phase)
const;
120 double f0(
void)
const;
121 void f0(
const double& f0);
122 double f1(
void)
const;
123 void f1(
const double& f1);
124 double f2(
void)
const;
125 void f2(
const double& f2);
162 return (
"GModelTemporalPhaseCurve");
176 return (
"PhaseCurve");
bool m_has_normalize
XML has normalize attribute.
double norm(const GVector &vector)
Computes vector norm.
bool normalize(void) const
Return normalization flag.
GNodeArray m_nodes
Phase values of nodes.
Abstract temporal model base class.
GTime mjd(void) const
Return reference Modified Julian Day.
void init_members(void)
Initialise class members.
GModelPar m_f0
Frequency at reference MJD.
bool m_normalize
Normalize phase curve (default: true)
double m_scale
Scale factor due to normalization.
Random number generator class.
std::vector< double > m_values
Function values at nodes.
double f2(void) const
Return second frequency derivative at reference Modified Julian Day.
virtual GModelTemporalPhaseCurve & operator=(const GModelTemporalPhaseCurve &model)
Assignment operator.
virtual GTimes mc(const double &rate, const GTime &tmin, const GTime &tmax, GRan &ran) const
Return vector of random event times.
Model parameter class interface definition.
virtual std::string type(void) const
Return model type.
Node array class interface definition.
Abstract temporal model base class interface definition.
void load_nodes(const GFilename &filename)
Load nodes from file.
double f0(void) const
Return frequency at reference Modified Julian Day.
void copy_members(const GModelTemporalPhaseCurve &model)
Copy class members.
void free_members(void)
Delete class members.
virtual void read(const GXmlElement &xml)
Read model from XML element.
virtual ~GModelTemporalPhaseCurve(void)
Destructor.
GModelPar m_f1
First freq. derivative at reference MJD.
GModelPar m_norm
Normalization factor.
double phase(void) const
Return phase at reference Modified Julian Day.
double value(const double &phase) const
Evaluate phase curve value for a given phase.
const GFilename & filename(void) const
Return file name.
double norm(void) const
Return normalization factor.
virtual std::string print(const GChatter &chatter=NORMAL) const
Print phase curve information.
GModelPar m_f2
Second freq. derivative at reference MJD.
GModelTemporalPhaseCurve(void)
Void constructor.
double value(void) const
Return parameter value.
double f1(void) const
Return first frequency derivative at reference Modified Julian Day.
virtual double eval(const GTime &srcTime, const bool &gradients=false) const
Evaluate function.
double mjd(void) const
Return time in Modified Julian Days (TT)
virtual GModelTemporalPhaseCurve * clone(void) const
Clone phase curve.
GModelPar m_phase
Phase at reference MJD.
GModelPar m_mjd
Reference MJD.
void normalize_nodes(void)
Normalise nodes.
GFilename m_filename
Name of phase file function.
Temporal phase curve model class.
Time class interface definition.
virtual void write(GXmlElement &xml) const
Write model into XML element.
Filename class interface definition.
virtual std::string classname(void) const
Return class name.
virtual void clear(void)
Clear phase curve.