Berkeley Nuclear Data Software
Public Member Functions | Protected Attributes | List of all members
LinearCalib Class Reference

#include <CalibrationClasses.h>

Inheritance diagram for LinearCalib:
Inheritance graph
[legend]
Collaboration diagram for LinearCalib:
Collaboration graph
[legend]

Public Member Functions

 LinearCalib ()
 
virtual double applyCalib (double a_value) const
 returns a_value*m_scalar+m_offset More...
 
double invertCalib (double a_value) const
 
void setCalibration (double a_scalar, double a_offset)
 
void setScalar (double a_scalar)
 
void setOffset (double a_offset)
 
virtual std::ostream & print (std::ostream &a_stream=std::cout) const
 prints nothing by default More...
 
virtual LinearCalibclone ()
 
- Public Member Functions inherited from DetectorCalib
 DetectorCalib ()
 
CalibType getCalibType ()
 
void setTime (uint32_t a_t)
 sets the experiment time during the processing in time since epoch More...
 
void setTDiv (int a_timeDiv)
 sets the divisor for which to consider the given time More...
 
virtual ~DetectorCalib ()
 

Protected Attributes

double m_scalar
 scalar for the calibration More...
 
double m_offset
 offset for the calibration More...
 
- Protected Attributes inherited from DetectorCalib
CalibType m_type
 
uint32_t m_t
 
int m_tDiv
 

Detailed Description

class used to apply a LinearCalibration to a measurement value inherits from above abc to provide common interface

Constructor & Destructor Documentation

◆ LinearCalib()

LinearCalib::LinearCalib ( )

default constuctor puts the class into a functional state with a scalar value of one and an offset value of zero (does nothing to the original value)

Here is the caller graph for this function:

Member Function Documentation

◆ applyCalib()

double LinearCalib::applyCalib ( double  a_value) const
inlinevirtual

returns a_value*m_scalar+m_offset

Implements DetectorCalib.

Reimplemented in TDepLinearCalib.

◆ clone()

LinearCalib * LinearCalib::clone ( )
virtual

this is required to implement deep copies of derived classes and needs to be implemented for any inheriting class

Implements DetectorCalib.

Reimplemented in TDepLinearCalib.

Here is the call graph for this function:

◆ invertCalib()

double LinearCalib::invertCalib ( double  a_value) const
inlinevirtual

allows for the inverse mapping of a given calibration if needed for applying cuts. implementation isn't enforced by default so the base class implimentation will return -10000;

Reimplemented from DetectorCalib.

◆ print()

std::ostream & LinearCalib::print ( std::ostream &  a_stream = std::cout) const
virtual

prints nothing by default

Reimplemented from DetectorCalib.

Reimplemented in TDepLinearCalib.

Here is the caller graph for this function:

◆ setCalibration()

void LinearCalib::setCalibration ( double  a_scalar,
double  a_offset 
)

◆ setOffset()

void LinearCalib::setOffset ( double  a_offset)
Here is the caller graph for this function:

◆ setScalar()

void LinearCalib::setScalar ( double  a_scalar)
Here is the caller graph for this function:

Member Data Documentation

◆ m_offset

double LinearCalib::m_offset
protected

offset for the calibration

◆ m_scalar

double LinearCalib::m_scalar
protected

scalar for the calibration


The documentation for this class was generated from the following files: