59 UInt_t altrocfg1, UInt_t altrocfg2 )
63 int index =
SelectBunch( bunchvector, &maxampindex, &maxamp );
68 Float_t maxf = TMath::MaxElement( bunchvector.at(index).GetLength(),
fReversed );
69 short maxrev = maxampindex - bunchvector.at(index).GetStartBin();
71 short timebinOffset = maxampindex - (bunchvector.at(index).GetLength()-1);
83 int nsamples = last - first + 1;
87 Float_t tmax = (maxrev - first);
92 fTf1->SetParLimits(0, 0.5*maxf*fkEulerSquared, 2*maxf*fkEulerSquared );
101 fTf1->ReleaseParameter(2);
105 Short_t tmpStatus = 0;
108 tmpStatus = graph->Fit(
fTf1,
"Q0RW");
110 catch (
const std::exception & e)
112 AliError( Form(
"TGraph Fit exception %s, fit status %d", e.what(),tmpStatus) );
124 tmax =
fTf1->GetParameter(1) + timebinOffset - (maxrev - first)
125 +
fTf1->GetParameter(2);
134 fTf1->GetChisquare(),
144 Int_t ndf = last - first - 1;
int fFitArrayCut
Cut on ADC value (after ped. subtraction) for signals used for fit.
void PrintFitResult(const TF1 *f) const
Print fit results.
Float_t fAmpCut
Max ADC - pedestal must be higher than this befor attemting to extract the amplitude.
const double fkEulerSquared
e^2 = 7.389056098930650227
virtual ~AliCaloRawAnalyzerFakeALTRO()
Destructor.
int fOverflowCut
Value when ADC starts to saturate.
int fNsampleCut
Minimum number of sample require before attemting to extract signal parameters.
Container class to hold info from bunches/samples.
int SelectBunch(const std::vector< AliCaloBunchInfo > &bunchvector, short *maxampbin, short *maxamplitude)
We select the bunch with the highest amplitude unless any time constraints is set.
const double TIMEBINWITH
each sample is 100 ns
Container class to hold results from fitting.
Float_t fTau
Rise time of the signal (peak position = t0 +tau), by defauly it is 235 ns.
Raw data fitters base class.
double fXaxis[ALTROMAXSAMPLES]
Axis if time bins, ( used by TGraph )
AliCaloRawAnalyzerFakeALTRO()
Constructor.
Algo::fitAlgorithm fAlgo
Which algorithm to use.
void SelectSubarray(const Double_t *date, int length, short maxindex, int *first, int *last, int cut) const
Float_t ReverseAndSubtractPed(const AliCaloBunchInfo *bunch, UInt_t altrocfg1, UInt_t altrocfg2, double *outarray) const
static void PrintBunch(const AliCaloBunchInfo &bunch)
Print bunch information.
TF1 * fTf1
Analytical formula of the Semi Gaussian to be fitted.
Double_t fReversed[ALTROMAXSAMPLES]
Reversed sequence of samples (pedestalsubtracted)
Double_t CalculateChi2(const Double_t amp, const Double_t time, const Int_t first, const Int_t last, const Double_t adcErr=1, const Double_t tau=2.35) const
bool fVerbose
Print debug information to std out if set to true.
Double_t fL1Phase
Phase of the ADC sampling clock relative to the LHC clock.
virtual AliCaloFitResults Evaluate(const std::vector< AliCaloBunchInfo > &bunchvector, UInt_t altrocfg1, UInt_t altrocfg2)
Extract signal parameters using fitting.
#define AliError(message)
Bool_t fFixTau
Fixed fit parameter or not, used in AliCaloRawAnalyzerFitter.
Raw data fitting: FALTRO.