intercalibration coefficient More...
#include <CalibCoeff.h>
Public Member Functions | |
CalibCoeff (const double &value=1., const bool &isGood=0) | |
ctor | |
double | difference () const |
the abs difference wrt prev value | |
double | operator*= (const double &var) |
update the value and turn into good the coefficient | |
void | setStatus (const bool &stat) |
set its value and turn into good the coefficient | |
void | setValue (const double &val) |
set its value and turn into good the coefficient | |
bool | status () const |
its status | |
double | value () const |
its value | |
~CalibCoeff () | |
dtor | |
Private Attributes | |
double | m_difference |
the difference with the previous value | |
bool | m_isGood |
if it is good | |
double | m_value |
the actual value |
intercalibration coefficient
Definition at line 14 of file CalibCoeff.h.
CalibCoeff::CalibCoeff | ( | const double & | value = 1. , |
const bool & | isGood = 0 |
||
) |
ctor
Definition at line 11 of file CalibCoeff.cc.
: m_value (value), m_isGood (isGood), m_difference (m_value) {}
CalibCoeff::~CalibCoeff | ( | ) |
double CalibCoeff::difference | ( | ) | const |
the abs difference wrt prev value
Definition at line 39 of file CalibCoeff.cc.
References m_difference, and m_isGood.
{ return m_isGood * m_difference - !m_isGood ; }
double CalibCoeff::operator*= | ( | const double & | var | ) |
update the value and turn into good the coefficient
Definition at line 83 of file CalibCoeff.cc.
References m_difference, m_isGood, m_value, and funct::true.
void CalibCoeff::setStatus | ( | const bool & | stat | ) |
set its value and turn into good the coefficient
Definition at line 72 of file CalibCoeff.cc.
References m_isGood, and testRegression::stat.
void CalibCoeff::setValue | ( | const double & | val | ) |
set its value and turn into good the coefficient
Definition at line 59 of file CalibCoeff.cc.
References m_difference, m_isGood, m_value, and funct::true.
{ m_value = val ; m_difference = m_value ; m_isGood = true ; return ; }
bool CalibCoeff::status | ( | ) | const |
double CalibCoeff::value | ( | ) | const |
double CalibCoeff::m_difference [private] |
the difference with the previous value
Definition at line 43 of file CalibCoeff.h.
Referenced by difference(), operator*=(), and setValue().
bool CalibCoeff::m_isGood [private] |
if it is good
Definition at line 41 of file CalibCoeff.h.
Referenced by difference(), operator*=(), setStatus(), setValue(), status(), and value().
double CalibCoeff::m_value [private] |
the actual value
Definition at line 39 of file CalibCoeff.h.
Referenced by operator*=(), setValue(), and value().