energyCalibrationFunctions Class Reference

Energy calibration functions. More...

#include <energyCalibration.h>

List of all members.

Public Member Functions

 energyCalibrationFunctions (int s=-1)
int setScanSign (int s=0)
Double_t gaussChargeSharing (Double_t *x, Double_t *par)
Double_t erfFunction (Double_t *x, Double_t *par)
Double_t erfFunctionChargeSharing (Double_t *x, Double_t *par)
Double_t erfFuncFluo (Double_t *x, Double_t *par)
Double_t spectrum (Double_t *x, Double_t *par)
Double_t scurve (Double_t *x, Double_t *par)
Double_t scurveFluo (Double_t *x, Double_t *par)

Static Public Member Functions

static float median (float *x, int n)
static int quick_select (int arr[], int n)
static int kth_smallest (int *a, int n, int k)

Private Attributes

int sign


Detailed Description

Energy calibration functions.

class containing all the possible energy calibration functions (scurves with and without charge sharing, gaussian spectrum with and without charge sharing, possibility of chosing the sign of the X-axis)


Constructor & Destructor Documentation

energyCalibrationFunctions::energyCalibrationFunctions ( int  s = -1  )  [inline]


Member Function Documentation

Double_t energyCalibrationFunctions::erfFuncFluo ( Double_t *  x,
Double_t *  par 
)

Double Erf function with charge sharing slope par[0] is the pedestal par[1] is the slope of the pedestal par[2] is the inflection point of the first energy par[3] is the RMS of the first energy par[4] is the amplitude of the first energy par[5] is the angual coefficient of the charge sharing slope of the first energy (scales with par[3]) par[6] is the inflection point of the second energy par[7] is the RMS of the second energy par[8] is the amplitude of the second energy par[9] is the angual coefficient of the charge sharing slope of the second energy (scales with par[8])

Double_t energyCalibrationFunctions::erfFunction ( Double_t *  x,
Double_t *  par 
)

Basic erf function par[0] is the inflection point par[1] is the RMS par[2] is the amplitude

Double_t energyCalibrationFunctions::erfFunctionChargeSharing ( Double_t *  x,
Double_t *  par 
)

Erf function with charge sharing slope par[0] is the pedestal par[1] is the slope of the pedestal par[2] is the inflection point par[3] is the RMS par[4] is the amplitude par[5] is the angual coefficient of the charge sharing slope (scales with par[3])

Double_t energyCalibrationFunctions::gaussChargeSharing ( Double_t *  x,
Double_t *  par 
)

Gaussian Function with charge sharing pedestal par[0] is the absolute height of the background pedestal par[1] is the slope of the background pedestal par[2] is the gaussian peak position par[3] is the RMS of the gaussian (and of the pedestal) par[4] is the height of the function par[5] is the fractional height of the charge sharing pedestal (scales with par[3])

static int energyCalibrationFunctions::kth_smallest ( int *  a,
int  n,
int  k 
) [static]

Calculates the median of an array of n elements (swaps the arrays!)

static float energyCalibrationFunctions::median ( float *  x,
int  n 
) [static]

Calculates the median of an array of n elements

static int energyCalibrationFunctions::quick_select ( int  arr[],
int  n 
) [static]

Calculates the median of an array of n elements (swaps the arrays!)

Double_t energyCalibrationFunctions::scurve ( Double_t *  x,
Double_t *  par 
)

Erf function with charge sharing slope with the correct scan sign par[0] is the pedestal par[1] is the slope of the pedestal par[2] is the inflection point par[3] is the RMS par[4] is the amplitude par[5] is the angual coefficient of the charge sharing slope (scales with par[3])

Double_t energyCalibrationFunctions::scurveFluo ( Double_t *  x,
Double_t *  par 
)

Double Erf function with charge sharing slope par[0] is the pedestal par[1] is the slope of the pedestal par[2] is the inflection point of the first energy par[3] is the RMS of the first energy par[4] is the amplitude of the first energy par[5] is the angual coefficient of the charge sharing slope of the first energy (scales with par[3]) par[6] is the inflection point of the second energy par[7] is the RMS of the second energy par[8] is the amplitude of the second energy par[9] is the angual coefficient of the charge sharing slope of the second energy (scales with par[8])

int energyCalibrationFunctions::setScanSign ( int  s = 0  )  [inline]

sets scan sign

Parameters:
s can be 1 (energy and x-axis have the same direction) or -1 (energy and x-axis have opposite directions) otherwise gets
Returns:
current scan sign can be 1 (energy and x-axis have the same direction) or -1 (energy and x-axis have opposite directions)

Double_t energyCalibrationFunctions::spectrum ( Double_t *  x,
Double_t *  par 
)

static function Gaussian with charge sharing pedestal with the correct scan sign par[0] is the absolute height of the background pedestal par[1] is the fractional height of the charge sharing pedestal (scales with par[3] par[2] is the gaussian peak position par[3] is the RMS of the gaussian (and of the pedestal) par[4] is the height of the function


Member Data Documentation

int energyCalibrationFunctions::sign [private]


The documentation for this class was generated from the following file:
Generated on Tue Mar 27 16:32:29 2012 by  doxygen 1.4.7