AliPhysics  d497547 (d497547)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
AliFMDCorrELossFit Class Reference

#include <AliFMDCorrELossFit.h>

Inheritance diagram for AliFMDCorrELossFit:

Classes

struct  ELossFit
 

Public Types

enum  { kHasShift = (1<<14), kIsGoodAsserted = (1<<15), kIsGood = (1<<16) }
 
enum  { kDefaultQuality = 8 }
 

Public Member Functions

 AliFMDCorrELossFit ()
 
 AliFMDCorrELossFit (const AliFMDCorrELossFit &o)
 
virtual ~AliFMDCorrELossFit ()
 
AliFMDCorrELossFitoperator= (const AliFMDCorrELossFit &o)
 
Set fits
Bool_t SetFit (UShort_t d, Char_t r, Double_t eta, Int_t quality, const TF1 &f)
 
Bool_t SetFit (UShort_t d, Char_t r, Double_t eta, ELossFit *f)
 
Bool_t SetFit (UShort_t d, Char_t r, Int_t etaBin, ELossFit *f)
 
Bool_t SetFit (UShort_t d, Char_t r, Double_t eta, Int_t quality, UShort_t n, Double_t chi2, UShort_t nu, Double_t c, Double_t ec, Double_t delta, Double_t edelta, Double_t xi, Double_t exi, Double_t sigma, Double_t esigma, Double_t sigman, Double_t esigman, Double_t *a, Double_t *ea)
 
Set and get eta axis
void SetEtaAxis (const TAxis &axis)
 
void SetEtaAxis (Int_t nBins, Double_t min, Double_t max)
 
const TAxisGetEtaAxis () const
 
void SetLowCut (Double_t cut)
 
Double_t GetLowCut () const
 
Int_t FindEtaBin (Double_t eta) const
 
Find fits
ELossFitFindFit (UShort_t d, Char_t r, Double_t eta, UShort_t minQ) const
 
ELossFitFindFit (UShort_t d, Char_t r, Int_t etabin, UShort_t minQ) const
 
ELossFitGetFit (UShort_t d, Char_t r, Double_t eta) const
 
ELossFitGetFit (UShort_t d, Char_t r, Int_t etabin) const
 
Finding cuts
Double_t GetMpvCut (UShort_t d, Char_t r, Int_t etaBin, Double_t f) const
 
Double_t GetXiCut (UShort_t d, Char_t r, Int_t etaBin, Double_t f) const
 
Double_t GetXiSigmaCut (UShort_t d, Char_t r, Int_t etaBin, Double_t f) const
 
Double_t GetAvgXiSigmaCut (UShort_t d, Char_t r, Int_t etaBin, Double_t f) const
 
Double_t GetProbabilityCut (UShort_t d, Char_t r, Int_t etaBin, Double_t f) const
 
Bool_t IsGood (Bool_t verbose=true, Double_t minRate=.7, Int_t maxGap=3, Int_t minInner=25, Int_t minOuter=15, Int_t minQuality=kDefaultQuality)
 
Miscellaneous
void CacheBins (UShort_t minQuality=kDefaultQuality) const
 
TObjArrayGetRingArray (UShort_t d, Char_t r) const
 
Bool_t IsFolder () const
 
void Browse (TBrowser *b)
 
void Draw (Option_t *option="")
 
void Print (Option_t *option="R") const
 
TListGetStacks (Bool_t err, Bool_t rel, Bool_t good, UShort_t maxN=5) const
 

Protected Member Functions

Int_t GetRingIndex (UShort_t d, Char_t r) const
 
TObjArrayGetOrMakeRingArray (UShort_t d, Char_t r)
 
void UpdateStackHist (ELossFit *f, Bool_t rel, Int_t used, TH1 *hChi, TH1 *hN, TH1 *hC, TH1 *hDelta, TH1 *hXi, TH1 *hSigma, Int_t maxN, TH1 **hA) const
 

Protected Attributes

TObjArray fRings
 
TAxis fEtaAxis
 
Double_t fLowCut
 
TArrayI fCache
 

Detailed Description

Object holding the Energy loss fit 'correction'

These are generated from Monte-Carlo or real ESDs.

Definition at line 38 of file AliFMDCorrELossFit.h.

Member Enumeration Documentation

anonymous enum

Flags set on the correction object

Enumerator
kHasShift 

Bit set if we use the delta shift

kIsGoodAsserted 

Bit set if badness was asserted

kIsGood 

Bit set if the correction object is bad

Definition at line 44 of file AliFMDCorrELossFit.h.

anonymous enum

Default least quality to use

Enumerator
kDefaultQuality 

Definition at line 61 of file AliFMDCorrELossFit.h.

Constructor & Destructor Documentation

AliFMDCorrELossFit::AliFMDCorrELossFit ( )

Default constructor

Definition at line 745 of file AliFMDCorrELossFit.cxx.

AliFMDCorrELossFit::AliFMDCorrELossFit ( const AliFMDCorrELossFit o)

Copy constructor

Parameters
oObject to copy from

Definition at line 763 of file AliFMDCorrELossFit.cxx.

AliFMDCorrELossFit::~AliFMDCorrELossFit ( )
virtual

Destructor

Definition at line 782 of file AliFMDCorrELossFit.cxx.

Member Function Documentation

void AliFMDCorrELossFit::Browse ( TBrowser *  b)

Browse this object

Parameters
b

Definition at line 1666 of file AliFMDCorrELossFit.cxx.

void AliFMDCorrELossFit::CacheBins ( UShort_t  minQuality = kDefaultQuality) const
void AliFMDCorrELossFit::Draw ( Option_t option = "")

Draw this object

Parameters
optionOptions. Possible values are
  • error Plot error bars
  • relative Plot relative errors

Definition at line 1489 of file AliFMDCorrELossFit.cxx.

Referenced by AliFMDCorrELossFit::ELossFit::Browse(), and CorrDrawer::DrawIt().

Int_t AliFMDCorrELossFit::FindEtaBin ( Double_t  eta) const

Find the eta bin corresponding to the given eta

Parameters
etaEta value
Returns
Bin (in \([1,N_{bins}]\)) corresponding to the given eta, or 0 if out of range.

Definition at line 889 of file AliFMDCorrELossFit.cxx.

Referenced by FindFit(), GetFit(), AliFMDDensityCalculator::GetMaxWeight(), AliFMDMultCuts::GetMultCut(), and SetFit().

AliFMDCorrELossFit::ELossFit * AliFMDCorrELossFit::FindFit ( UShort_t  d,
Char_t  r,
Double_t  eta,
UShort_t  minQ 
) const

Find the fit corresponding to the specified parameters. This uses the cache map of good fits for the look-up. For un-cached look-up see GetFit.

Parameters
dDetector
rRing
etaEta value
minQMinimum quality
Returns
Fit parameters or null in case of problems

Definition at line 1119 of file AliFMDCorrELossFit.cxx.

Referenced by AliFMDDensityCalculator::FindMaxWeight(), GetAvgXiSigmaCut(), GetMpvCut(), GetProbabilityCut(), GetStacks(), GetXiCut(), GetXiSigmaCut(), and AliFMDDensityCalculator::NParticles().

AliFMDCorrELossFit::ELossFit * AliFMDCorrELossFit::FindFit ( UShort_t  d,
Char_t  r,
Int_t  etabin,
UShort_t  minQ 
) const

Find the fit corresponding to the specified parameters. This uses the cache map of good fits for the look-up. For un-cached look-up see GetFit.

Parameters
dDetector
rRing
etabinEta bin (1 based)
minQMinimum quality
Returns
Fit parameters or null in case of problems

Definition at line 1080 of file AliFMDCorrELossFit.cxx.

Double_t AliFMDCorrELossFit::GetAvgXiSigmaCut ( UShort_t  d,
Char_t  r,
Int_t  etaBin,
Double_t  f 
) const

Get average Xi and sigma width cut, like \( \Delta - f\left(\frac{\xi/\delta^2_{\xi}+\sigma/\delta^2_{\sigma}}{1/\delta^2_{\xi}+1/\delta^2_{\sigma}})\)

  • that is, the average of \(\xi\) and \(\sigma\) weighted by the uncertainties.
Parameters
dDetector
rRing
etaBinEta bin (1-based)
fscalar

Definition at line 1228 of file AliFMDCorrELossFit.cxx.

Referenced by AliFMDMultCuts::GetMultCut().

const TAxis& AliFMDCorrELossFit::GetEtaAxis ( ) const
inline

Get the eta axis used

Returns

Definition at line 570 of file AliFMDCorrELossFit.h.

Referenced by AliFMDDensityCalculator::CacheMaxWeights(), AliFMDSharingFilter::SetupForData(), and Trending2ELoss().

AliFMDCorrELossFit::ELossFit * AliFMDCorrELossFit::GetFit ( UShort_t  d,
Char_t  r,
Double_t  eta 
) const

Find the fit corresponding to the specified parameters. Note, the a cache-map of good fits isn't used for this look-up. To use the cache, use FindFit.

Parameters
dDetector
rRing
etaEta value
Returns
Fit parameters or null in case of problems

Definition at line 1061 of file AliFMDCorrELossFit.cxx.

AliFMDCorrELossFit::ELossFit * AliFMDCorrELossFit::GetFit ( UShort_t  d,
Char_t  r,
Int_t  etabin 
) const

Find the fit corresponding to the specified parameters. Note, the a cache-map of good fits isn't used for this look-up. To use the cache, use FindFit.

Parameters
dDetector
rRing
etabinEta bin (1 based)
Returns
Fit parameters or null in case of problems

Definition at line 1038 of file AliFMDCorrELossFit.cxx.

Double_t AliFMDCorrELossFit::GetLowCut ( ) const
inline

Get the low cut used when fitting

Returns
Low cut used for fitting

Definition at line 582 of file AliFMDCorrELossFit.h.

Referenced by AliFMDMultCuts::GetMultCut().

Double_t AliFMDCorrELossFit::GetMpvCut ( UShort_t  d,
Char_t  r,
Int_t  etaBin,
Double_t  f 
) const

Get MPV fraction cut, like \( f \Delta\)

Parameters
fFraction

Definition at line 1194 of file AliFMDCorrELossFit.cxx.

Referenced by AliFMDMultCuts::GetMultCut().

TObjArray * AliFMDCorrELossFit::GetOrMakeRingArray ( UShort_t  d,
Char_t  r 
)
protected

Get the ring array corresponding to the specified ring

Parameters
dDetector
rRing
Returns
Pointer to ring array, or newly created container

Definition at line 1168 of file AliFMDCorrELossFit.cxx.

Referenced by SetFit().

Double_t AliFMDCorrELossFit::GetProbabilityCut ( UShort_t  d,
Char_t  r,
Int_t  etaBin,
Double_t  f 
) const

Find the x value that corresponds to a (normalized) probability of low or less. That is, we can use this to say: "Give me the x value under which it is unlikely that a particle gave a signal".

Parameters
dDetector
rRing
etaBinEta bin (1-based)
fscalar
Returns
Cut value, or 1000 in case of problems

Definition at line 1239 of file AliFMDCorrELossFit.cxx.

Referenced by AliFMDMultCuts::GetMultCut().

TObjArray * AliFMDCorrELossFit::GetRingArray ( UShort_t  d,
Char_t  r 
) const

Get the ring array corresponding to the specified ring

Parameters
dDetector
rRing
Returns
Pointer to ring array, or null in case of problems

Definition at line 1150 of file AliFMDCorrELossFit.cxx.

Referenced by CorrDrawer::DrawIt(), FindFit(), and GetFit().

Int_t AliFMDCorrELossFit::GetRingIndex ( UShort_t  d,
Char_t  r 
) const
protected

Calculate the index of a ring.

Parameters
dDetector
rRing
Returns
Index of the ring

Definition at line 1138 of file AliFMDCorrELossFit.cxx.

Referenced by GetOrMakeRingArray(), and GetRingArray().

TList * AliFMDCorrELossFit::GetStacks ( Bool_t  err,
Bool_t  rel,
Bool_t  good,
UShort_t  maxN = 5 
) const

Get a list of THStack - one for each parameter.

If err is true, then error bars are set too. If rel is true, then the relative error (rather than the absolute value) is filled into the histograms. If good is true, then we use the cache-map of good fits rather than all fits.

Parameters
errShow errors
relShow relative errors
goodOnly show good fits
maxNMaximum weight to use
Returns
List of THStack

Definition at line 1345 of file AliFMDCorrELossFit.cxx.

Referenced by CompELossFits(), and Draw().

Double_t AliFMDCorrELossFit::GetXiCut ( UShort_t  d,
Char_t  r,
Int_t  etaBin,
Double_t  f 
) const

Get Xi width cut, like \( \Delta - f\xi\)

Parameters
dDetector
rRing
etaBinEta bin (1-based)
fscalar

Definition at line 1206 of file AliFMDCorrELossFit.cxx.

Referenced by AliFMDMultCuts::GetMultCut().

Double_t AliFMDCorrELossFit::GetXiSigmaCut ( UShort_t  d,
Char_t  r,
Int_t  etaBin,
Double_t  f 
) const

Get Xi and sigma width cut, like \( \Delta - f(\xi+\sigma)\)

Parameters
dDetector
rRing
etaBinEta bin (1-based)
fscalar

Definition at line 1217 of file AliFMDCorrELossFit.cxx.

Referenced by AliFMDMultCuts::GetMultCut().

Bool_t AliFMDCorrELossFit::IsFolder ( ) const
inline

Signal that this is a folder

Returns
Always true

Definition at line 776 of file AliFMDCorrELossFit.h.

Bool_t AliFMDCorrELossFit::IsGood ( Bool_t  verbose = true,
Double_t  minRate = .7,
Int_t  maxGap = 3,
Int_t  minInner = 25,
Int_t  minOuter = 15,
Int_t  minQuality = kDefaultQuality 
)

Calculate and return the overall quality of this correction object. The quality is either good or bad. The quality of the object is determined as, for each ring

  • The ratio of successful to attempted fits (success rate) is larger than minRate. A successful fit is one with a least quality of minQuality
  • The maximum distance between successful fits is no larger than maxGap (default 3).
  • For inners, that at least minInner (default 25) fits were attempted
  • For outers, that at least minOuter (default 15) fits were attempted
Parameters
verboseWether to print information
minRateLeast success rate
maxGapMaximum gap to allow
minInnerLeast number of attempted fits in inners
minOuterLeast number of attempted fits in outers
minQualityLeast quality for good fits
Returns
true if the correction object is good.

Definition at line 1251 of file AliFMDCorrELossFit.cxx.

Referenced by AliFMDEnergyFitter::MakeCorrectionsObject(), and Trending2ELoss().

AliFMDCorrELossFit & AliFMDCorrELossFit::operator= ( const AliFMDCorrELossFit o)

Assignment operator

Parameters
oObject to assign from
Returns
Reference to this object

Definition at line 792 of file AliFMDCorrELossFit.cxx.

void AliFMDCorrELossFit::Print ( Option_t option = "R") const

Print this object.

Parameters
optionOptions
  • R Print recursive

Definition at line 1591 of file AliFMDCorrELossFit.cxx.

Referenced by AliFMDDensityCalculator::CacheMaxWeights(), and CorrDrawer::DrawIt().

void AliFMDCorrELossFit::SetEtaAxis ( const TAxis axis)
inline

Set the eta axis to use

Parameters
axisEta axis

Definition at line 873 of file AliFMDCorrELossFit.h.

Referenced by AliFMDEnergyFitter::MakeCorrectionsObject(), operator=(), MakeELossFit::Run(), and Trending2ELoss().

void AliFMDCorrELossFit::SetEtaAxis ( Int_t  nBins,
Double_t  min,
Double_t  max 
)
inline

Set the eta axis to use

Parameters
nBinsNumber of bins
minMinimum \( \eta\)
maxmaximum \( \eta\)

Definition at line 867 of file AliFMDCorrELossFit.h.

Bool_t AliFMDCorrELossFit::SetFit ( UShort_t  d,
Char_t  r,
Double_t  eta,
Int_t  quality,
const TF1 &  f 
)

Set the fit parameters from a function

Parameters
dDetector
rRing
etaEta
qualityQuality flag
fFunction from fit
Returns
true on success

Definition at line 1016 of file AliFMDCorrELossFit.cxx.

Referenced by AliFMDEnergyFitter::RingHistos::FindBestFits(), MakeELossFit::Run(), SetFit(), and Trending2ELoss().

Bool_t AliFMDCorrELossFit::SetFit ( UShort_t  d,
Char_t  r,
Double_t  eta,
ELossFit f 
)

Set the fit parameters from a function

Parameters
dDetector
rRing
etaEta
fELoss fit result - note, the object will take ownership
Returns
true on success

Definition at line 941 of file AliFMDCorrELossFit.cxx.

Bool_t AliFMDCorrELossFit::SetFit ( UShort_t  d,
Char_t  r,
Int_t  etaBin,
ELossFit f 
)

Set the fit parameters from a function

Parameters
dDetector
rRing
etaBinEta (bin number, 1->nBins)
fELoss fit result - note, the object will take ownership
Returns
true on success

Definition at line 913 of file AliFMDCorrELossFit.cxx.

Bool_t AliFMDCorrELossFit::SetFit ( UShort_t  d,
Char_t  r,
Double_t  eta,
Int_t  quality,
UShort_t  n,
Double_t  chi2,
UShort_t  nu,
Double_t  c,
Double_t  ec,
Double_t  delta,
Double_t  edelta,
Double_t  xi,
Double_t  exi,
Double_t  sigma,
Double_t  esigma,
Double_t  sigman,
Double_t  esigman,
Double_t a,
Double_t ea 
)

Set the fit parameters from a function

Parameters
dDetector number
rRing identifier
etaEta value
qualityQuality flag
n\( N\) - Number of fitted peaks
chi2\( \chi^2 \)
nu\( \nu \) - number degrees of freedom
c\( C\) - scale constant
ec\( \delta C\) - error on \( C\)
delta\( \Delta\) - most probable value
edelta\( \delta\Delta\) - error on \(\Delta\)
xi\( \xi\) - Landau width
exi\( \delta\xi\) - error on \(\xi\)
sigma\( \sigma\) - Gaussian width
esigma\( \delta\sigma\) - error on \(\sigma\)
sigman\( \sigma_n\) - Noise width
esigman\( \delta\sigma_n\) - error on \(\sigma_n\)
aArray of \( N-1\) weights \( a_i\) for \( i=2,\ldots\)
eaArray of \( N-1\) errors on weights \( a_i\) for \( i=2,\ldots\)
Returns
true on success

Definition at line 963 of file AliFMDCorrELossFit.cxx.

void AliFMDCorrELossFit::SetLowCut ( Double_t  cut)
inline

Set the low cut used when fitting

Parameters
cutCut value

Definition at line 576 of file AliFMDCorrELossFit.h.

Referenced by AliFMDEnergyFitter::MakeCorrectionsObject(), and Trending2ELoss().

void AliFMDCorrELossFit::UpdateStackHist ( ELossFit f,
Bool_t  rel,
Int_t  used,
TH1 hChi,
TH1 hN,
TH1 hC,
TH1 hDelta,
TH1 hXi,
TH1 hSigma,
Int_t  maxN,
TH1 **  hA 
) const
protected

Fill fit values into stack histograms

Parameters
fFit
relIf true, fill in relative errors
usedThe bin begin used for this fit
hChi\(\chi^2/\nu\) histogram
hN\( N_{a}\) - number of components - histogram
hC\( C\) - prefactor - histogram
hDelta\( \Delta_p\) - most-probably value - histogram
hXi\( \xi\) - Landau 'width' - histogram
hSigma\( \sigma\) - Gaussian smear - histogram
maxN\( N_{a,max}\) Largest possible \( N\)
hA\( a_{i}, i=\{2,..,N_{a,max}\}\) - histogram

Definition at line 1450 of file AliFMDCorrELossFit.cxx.

Referenced by GetStacks().

Member Data Documentation

TArrayI AliFMDCorrELossFit::fCache
mutableprotected

Definition at line 860 of file AliFMDCorrELossFit.h.

Referenced by CacheBins(), FindFit(), operator=(), and Print().

TAxis AliFMDCorrELossFit::fEtaAxis
protected
Double_t AliFMDCorrELossFit::fLowCut
protected

Definition at line 859 of file AliFMDCorrELossFit.h.

Referenced by GetLowCut(), operator=(), Print(), and SetLowCut().


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