8 #include <TParameter.h>
35 Set(method, cut1, cut2, cut3, cut4, cut5);
49 if (&o ==
this)
return *
this;
77 fCuts[1] = fmd2i >= 0 ? fmd2i : fmd1i;
78 fCuts[2] = fmd2o >= 0 ? fmd2o : fmd1i * oFac;
79 fCuts[3] = fmd3i >= 0 ? fmd3i : fmd1i;
80 fCuts[4] = fmd3o >= 0 ? fmd3o : fmd1i * oFac;
92 Warning(what,
"*** DEPRECATED - use AliFMDMultCuts::Set instead ***");
93 Set(method, fmd1i, fmd2i, fmd2o, fmd3i, fmd3o);
100 Warning(
"SetIncludeSigma",
101 "*** DEPRECATED - use AliFMDMultCuts::Set instead ***");
117 case 1: idx = 0;
break;
118 case 2: idx = 1 + ((r ==
'I' || r ==
'i') ? 0 : 1);
break;
119 case 3: idx = 3 + ((r ==
'I' || r ==
'i') ? 0 : 1);
break;
121 if (idx < 0)
return -
kBad;
138 DGUARD(fDebug, 5,
"Get mult cut for FMD%d%c (method %d) @ etabin=%d",
142 Warning(
"GetMultCut",
"Got bad cut parameter for FMD%d%c ieta=%d",
149 DMSG(fDebug, 5,
"-> %8.4f", param);
165 rcut = fits->
GetMpvCut(d,r,ieta,param);
break;
169 rcut = fits->
GetXiCut(d, r, ieta, param);
189 Warning(
"GetMultCut",
"No energy loss fits obtained from manager");
191 DMSG(fDebug, 5,
"-> %8.4f", rcut);
209 DGUARD(fDebug, 5,
"Get mult cut for FMD%d%c @ eta=%8.4f",
214 DMSG(fDebug, 5,
"bin=%4d", iEta);
230 return latex ?
"c=X" :
"fixed value";
232 return latex ?
"c=X#times#Delta_{p}":
"fraction of MPV";
234 return latex ?
"range" :
"c: lower fit bound";
236 return latex ?
"c=#Delta_{p}-X#times#xi" :
"landau width";
238 return latex ?
"c=#Delta_{p}-X#times(#xi+#sigma)" :
"landau+sigma width";
240 return latex ?
"c:P(#Delta<c)<X" :
"probability";
242 return latex ?
"x=#Delta_{p}-X#times#bar{#xi+#sigma}" :
245 return latex ?
"c:?" :
"unknown";
252 if (m.EqualTo(
"fixed value") || m.Contains(
"fix"))
254 else if (m.EqualTo(
"fraction of mpv") || m.Contains(
"mpv"))
256 else if (m.EqualTo(
"fit range") || m.Contains(
"fit"))
258 else if (m.EqualTo(
"landau width") || m.Contains(
"xi") ||
260 else if (m.EqualTo(
"landau+sigma avg") || m.Contains(
"avg"))
262 else if (m.EqualTo(
"landau+sigma width") || m.Contains(
"sig"))
264 else if (m.EqualTo(
"probability") || m.Contains(
"prob"))
273 DGUARD(fDebug, 5,
"Fill Histogram %s with cuts", h->GetName());
275 TAxis* yAxis = h->GetYaxis();
276 for (
Int_t iy = 1; iy <= yAxis->GetNbins(); iy++) {
277 TString lab(yAxis->GetBinLabel(iy));
282 DMSG(fDebug, 5,
"FMD%d%c", det, rng);
284 for (
Int_t ix = 1; ix <= h->GetNbinsX(); ix++) {
285 Double_t eta = h->GetXaxis()->GetBinCenter(ix);
287 DMSG(fDebug, 10,
"FMD%s bin=%4d -> eta=%8.4f -> %8.4f",
288 lab.Data(), ix, eta,
c);
290 if (c > 0) h->SetBinContent(ix, iy, c);
300 if (name && name[0] !=
'\0') {
319 if (!l)
return false;
321 if (name && name[0] !=
'\0') {
322 ll =
static_cast<TList*
>(l->FindObject(name));
324 if (!ll)
return false;
326 TObject* meth = ll->FindObject(
"method");
327 TObject* fmd1i = ll->FindObject(
"fmd1i");
328 TObject* fmd2i = ll->FindObject(
"fmd2i");
329 TObject* fmd2o = ll->FindObject(
"fmd2o");
330 TObject* fmd3i = ll->FindObject(
"fmd3i");
331 TObject* fmd3o = ll->FindObject(
"fmd3o");
353 #define PF(N,V,...) \
354 AliForwardUtil::PrintField(N,V, ## __VA_ARGS__)
355 #define PFB(N,FLAG) \
357 AliForwardUtil::PrintName(N); \
358 std::cout << std::boolalpha << (FLAG) << std::noboolalpha << std::endl; \
360 #define PFV(N,VALUE) \
362 AliForwardUtil::PrintName(N); \
363 std::cout << (VALUE) << std::endl; } while(false)
369 gROOT->IncreaseDirLevel();
371 gROOT->IncreaseDirLevel();
377 gROOT->DecreaseDirLevel();
378 gROOT->DecreaseDirLevel();
void Print(Option_t *option="") const
static EMethod String2Method(const char *str)
Double_t GetXiCut(UShort_t d, Char_t r, Int_t etaBin, Double_t f) const
Double_t GetCutParam(UShort_t d, Char_t r) const
#define DMSG(L, N, F,...)
void SetIncludeSigma(Bool_t in)
void DepSet(const char *what, EMethod method, Double_t fmd1i, Double_t fmd2i=-1, Double_t fmd2o=-1, Double_t fmd3i=-1, Double_t fmd3o=-1)
Double_t GetMultCut(UShort_t d, Char_t r, Double_t eta, Bool_t errors) const
AliFMDMultCuts & operator=(const AliFMDMultCuts &o)
static const char * Method2String(EMethod method, Bool_t latex)
const char * GetMethodString(Bool_t latex=false) const
void Output(TList *l, const char *name=0) const
Int_t FindEtaBin(Double_t eta) const
Various utilities used in PWGLF/FORWARD.
Double_t GetAvgXiSigmaCut(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
void Set(EMethod method, Double_t fmd1i, Double_t fmd2i=-1, Double_t fmd2o=-1, Double_t fmd3i=-1, Double_t fmd3o=-1)
static void GetParameter(TObject *o, UShort_t &value)
Double_t GetProbabilityCut(UShort_t d, Char_t r, Int_t etaBin, Double_t f) const
Bool_t Input(TList *l, const char *name)
const AliFMDCorrELossFit * GetELossFit() const
#define DGUARD(L, N, F,...)
static TObject * MakeParameter(const char *name, UShort_t value)
void FillHistogram(TH2 *h) const
Double_t GetMpvCut(UShort_t d, Char_t r, Int_t etaBin, Double_t f) const
static AliForwardCorrectionManager & Instance()
Double_t GetLowCut() const