]>
Commit | Line | Data |
---|---|---|
1 | #ifndef ALIHBTFUNCTION_H | |
2 | #define ALIHBTFUNCTION_H | |
3 | ||
4 | /* Id: $ */ | |
5 | ||
6 | /////////////////////////////////////////////////////// | |
7 | // // | |
8 | // AliHBTFunction // | |
9 | // // | |
10 | // Abstract Base Calss for all the function classes // | |
11 | // // | |
12 | // Piotr.Skowronski@cern.ch // | |
13 | // http://alisoft.cern.ch/people/skowron/analyzer // | |
14 | // // | |
15 | /////////////////////////////////////////////////////// | |
16 | ||
17 | #include <TH1.h> | |
18 | #include <TH2D.h> | |
19 | #include <TH3D.h> | |
20 | ||
21 | #include "AliHBTPairCut.h" | |
22 | #include "AliHBTPair.h" | |
23 | ||
24 | ||
25 | class AliHBTAnalysis; | |
26 | class AliHBTParticleCut; | |
27 | ||
28 | class AliHBTFunction: public TNamed | |
29 | { | |
30 | public: | |
31 | AliHBTFunction(); | |
32 | AliHBTFunction(const char* name, const char* title); | |
33 | AliHBTFunction(const AliHBTFunction & source); | |
34 | ||
35 | virtual ~AliHBTFunction(); | |
36 | ||
37 | AliHBTFunction & operator= (const AliHBTFunction & source); | |
38 | ||
39 | virtual TH1* GetNumerator() const = 0; | |
40 | virtual TH1* GetDenominator() const = 0; | |
41 | virtual TH1* GetResult() = 0; | |
42 | ||
43 | virtual void WriteFunction(); | |
44 | virtual void InitFunction(); | |
45 | ||
46 | TH1* GetRatio(Double_t normfactor = 1.0); | |
47 | void Rename(const Char_t * name); //renames the function and histograms ==title is the same that name | |
48 | void Rename(const Char_t * name, const Char_t * title); //renames and retitle the function and histograms | |
49 | ||
50 | void SetPairCut(AliHBTPairCut* cut); | |
51 | ||
52 | virtual AliHBTPair* CheckPair(AliHBTPair* pair); | |
53 | void SetWriteNumAndDen(Bool_t flag = kFALSE){fWriteNumAndDen = flag;} | |
54 | protected: | |
55 | virtual void BuildHistos() = 0;//builds default histograms | |
56 | AliHBTPairCut* fPairCut; //pair cut | |
57 | Bool_t fWriteNumAndDen; //flag indicating whether numerator and denominator should be writted together with a result | |
58 | ClassDef(AliHBTFunction,3) | |
59 | }; | |
60 | /******************************************************************/ | |
61 | inline AliHBTPair* AliHBTFunction::CheckPair(AliHBTPair* pair) | |
62 | { | |
63 | //check if pair and both particles meets the cut criteria | |
64 | if(fPairCut->Pass(pair)) //if the pair is BAD | |
65 | {//it is BAD | |
66 | pair = pair->GetSwapedPair(); | |
67 | if(pair) | |
68 | if(fPairCut->Pass(pair)) //so try reverse combination | |
69 | { | |
70 | return 0x0;//it is BAD as well - so return | |
71 | } | |
72 | } | |
73 | return pair; | |
74 | } | |
75 | ||
76 | /******************************************************************/ | |
77 | /******************************************************************/ | |
78 | /******************************************************************/ | |
79 | class AliHBTCorrelFunction | |
80 | { | |
81 | public: | |
82 | AliHBTCorrelFunction():fRatio(0x0){} | |
83 | AliHBTCorrelFunction(const AliHBTCorrelFunction& in):fRatio((in.fRatio)?(TH1*)in.fRatio->Clone():0x0){} | |
84 | virtual ~AliHBTCorrelFunction(){delete fRatio;} | |
85 | ||
86 | AliHBTCorrelFunction& operator=(const AliHBTCorrelFunction& in); | |
87 | ||
88 | protected: | |
89 | TH1* fRatio;//!pointer to the ratio(result) | |
90 | ||
91 | ClassDef(AliHBTCorrelFunction,1) | |
92 | }; | |
93 | ||
94 | /******************************************************************/ | |
95 | /******************************************************************/ | |
96 | /******************************************************************/ | |
97 | ||
98 | //____________________ | |
99 | /////////////////////////////////////////////////////// | |
100 | // // | |
101 | // AliHBTOnePairFctn // | |
102 | // // | |
103 | // Abstract Base Calss for Functions that need // | |
104 | // one pair to fill function // | |
105 | // // | |
106 | // Piotr.Skowronski@cern.ch // | |
107 | // http://alisoft.cern.ch/people/skowron/analyzer // | |
108 | // // | |
109 | /////////////////////////////////////////////////////// | |
110 | ||
111 | class AliHBTOnePairFctn | |
112 | { | |
113 | public: | |
114 | AliHBTOnePairFctn(){} | |
115 | virtual ~AliHBTOnePairFctn(){} | |
116 | ||
117 | virtual void ProcessSameEventParticles(AliHBTPair* pair) = 0; | |
118 | virtual void ProcessDiffEventParticles(AliHBTPair* pair) = 0; | |
119 | ||
120 | virtual void Init() = 0; | |
121 | virtual void Write() = 0; | |
122 | virtual const char* Name() = 0; | |
123 | ||
124 | ClassDef(AliHBTOnePairFctn,2) | |
125 | }; | |
126 | /******************************************************************/ | |
127 | /******************************************************************/ | |
128 | /******************************************************************/ | |
129 | ||
130 | //____________________ | |
131 | /////////////////////////////////////////////////////// | |
132 | // // | |
133 | // AliHBTTwoPairFctn // | |
134 | // // | |
135 | // Abstract Base Calss for Functions that need // | |
136 | // two pairs to fill function, // | |
137 | // one reconstructed track and corresponding // | |
138 | // simulated pair // | |
139 | // Basically resolution functions // | |
140 | // Lednicky's algorithm uses that as well // | |
141 | // // | |
142 | // Piotr.Skowronski@cern.ch // | |
143 | // http://alisoft.cern.ch/people/skowron/analyzer // | |
144 | // // | |
145 | /////////////////////////////////////////////////////// | |
146 | ||
147 | class AliHBTTwoPairFctn | |
148 | { | |
149 | public: | |
150 | AliHBTTwoPairFctn(){}; | |
151 | virtual ~AliHBTTwoPairFctn(){}; | |
152 | ||
153 | virtual void | |
154 | ProcessSameEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair) = 0; | |
155 | virtual void | |
156 | ProcessDiffEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair) = 0; | |
157 | ||
158 | virtual void Init() = 0; | |
159 | virtual void Write() = 0; | |
160 | virtual const char* Name() = 0; | |
161 | ||
162 | ClassDef(AliHBTTwoPairFctn,2) | |
163 | ||
164 | }; | |
165 | /******************************************************************/ | |
166 | /******************************************************************/ | |
167 | /******************************************************************/ | |
168 | ||
169 | //____________________ | |
170 | /////////////////////////////////////////////////////// | |
171 | // // | |
172 | // AliHBTFunction1D // | |
173 | // // | |
174 | // Base Calss for 1-dimensinal Functions // | |
175 | // // | |
176 | // Piotr.Skowronski@cern.ch // | |
177 | // http://alisoft.cern.ch/people/skowron/analyzer // | |
178 | // // | |
179 | /////////////////////////////////////////////////////// | |
180 | ||
181 | ||
182 | class AliHBTFunction1D: public AliHBTFunction | |
183 | { | |
184 | public: | |
185 | AliHBTFunction1D();//default conmstructor | |
186 | AliHBTFunction1D(Int_t nbins, Float_t maxXval, Float_t minXval); | |
187 | AliHBTFunction1D(const Char_t *name, const Char_t *title); | |
188 | AliHBTFunction1D(const Char_t *name, const Char_t *title, | |
189 | Int_t nbins, Float_t maxXval, Float_t minXval); | |
190 | ||
191 | AliHBTFunction1D(const AliHBTFunction1D & source); | |
192 | AliHBTFunction1D & operator= (const AliHBTFunction1D& /*source*/); | |
193 | ||
194 | virtual ~AliHBTFunction1D(); | |
195 | ||
196 | TH1* GetNumerator() const {return fNumerator;}//returns numerator histogram | |
197 | TH1* GetDenominator() const {return fDenominator;}//returns denominator histogram | |
198 | ||
199 | Double_t Scale(); | |
200 | void SetNumberOfBinsToScale(Int_t n = fgkDefaultNBinsToScale){fNBinsToScale = n;} | |
201 | ||
202 | protected: | |
203 | //returns value to be histogrammed | |
204 | virtual void BuildHistos(Int_t nbins, Float_t max, Float_t min); | |
205 | virtual void BuildHistos(); | |
206 | Double_t Scale(TH1D* num,TH1D* den); | |
207 | ||
208 | TH1D* fNumerator; // Numerator histogram | |
209 | TH1D* fDenominator; // Denumerator histogram | |
210 | UInt_t fNBinsToScale; // Number of bins to scale | |
211 | ||
212 | private: | |
213 | //this must be declared before constructors because they are used as a default arguments | |
214 | static const Int_t fgkDefaultNBins;//default number of Bins in histograms | |
215 | static const Float_t fgkDefaultMin;//Default min value of histograms | |
216 | static const Float_t fgkDefaultMax;//Default max value of histograms | |
217 | static const UInt_t fgkDefaultNBinsToScale;//Default number of bins used for scaling to tale | |
218 | ||
219 | ClassDef(AliHBTFunction1D,2) | |
220 | }; | |
221 | ||
222 | /******************************************************************/ | |
223 | /******************************************************************/ | |
224 | /******************************************************************/ | |
225 | ||
226 | //____________________ | |
227 | /////////////////////////////////////////////////////// | |
228 | // // | |
229 | // AliHBTFunction2D // | |
230 | // // | |
231 | // Base Calss for 2-dimensinal Functions // | |
232 | // // | |
233 | // Piotr.Skowronski@cern.ch // | |
234 | // http://alisoft.cern.ch/people/skowron/analyzer // | |
235 | // // | |
236 | /////////////////////////////////////////////////////// | |
237 | ||
238 | class AliHBTFunction2D: public AliHBTFunction | |
239 | { | |
240 | public: | |
241 | AliHBTFunction2D(); | |
242 | ||
243 | AliHBTFunction2D(const Char_t *name, const Char_t *title); | |
244 | ||
245 | AliHBTFunction2D(Int_t nXbins, Double_t maxXval, Double_t minXval, | |
246 | Int_t nYbins, Double_t maxYval, Double_t minYval); | |
247 | ||
248 | AliHBTFunction2D(const Char_t *name, const Char_t *title, | |
249 | Int_t nXbins, Double_t maxXval, Double_t minXval, | |
250 | Int_t nYbins, Double_t maxYval, Double_t minYval); | |
251 | ||
252 | AliHBTFunction2D(const AliHBTFunction2D & source); | |
253 | ||
254 | AliHBTFunction2D & operator= (const AliHBTFunction2D & /*source*/); | |
255 | ||
256 | virtual ~AliHBTFunction2D(); | |
257 | ||
258 | TH1* GetNumerator() const {return fNumerator;} | |
259 | TH1* GetDenominator() const {return fDenominator;} | |
260 | ||
261 | void SetNumberOfBinsToScale(UInt_t xn = fgkDefaultNBinsToScaleX, | |
262 | UInt_t yn = fgkDefaultNBinsToScaleY); | |
263 | ||
264 | Double_t Scale(); | |
265 | protected: | |
266 | virtual void BuildHistos(Int_t nxbins, Float_t xmax, Float_t xmin, | |
267 | Int_t nybins, Float_t ymax, Float_t ymin); | |
268 | virtual void BuildHistos(); | |
269 | ||
270 | TH2D* fNumerator; // Numerator histogram | |
271 | TH2D* fDenominator; // Denominator histogram | |
272 | ||
273 | //definition of area used for scaling -> Scale is calculated this | |
274 | //way that after division tale is on 1 | |
275 | UInt_t fNBinsToScaleX;//number of bins on X axis | |
276 | UInt_t fNBinsToScaleY;//number of bins on Y axis | |
277 | ||
278 | private: | |
279 | //this must be declared before constructors because they are used as a default arguments | |
280 | static const Int_t fgkDefaultNBinsX;//default number of Bins in X axis in histograms | |
281 | static const Float_t fgkDefaultMinX;//Default min value of X axis in histograms | |
282 | static const Float_t fgkDefaultMaxX;//Default max value of X axis inhistograms | |
283 | static const Int_t fgkDefaultNBinsY;//default number of Bins in histograms | |
284 | static const Float_t fgkDefaultMinY;//Default min value of histograms | |
285 | static const Float_t fgkDefaultMaxY;//Default max value of histograms | |
286 | ||
287 | static const UInt_t fgkDefaultNBinsToScaleX;//Default number of X bins used for scaling to tale | |
288 | static const UInt_t fgkDefaultNBinsToScaleY;//Default number of bins used for scaling to tale | |
289 | ||
290 | ClassDef(AliHBTFunction2D,2) | |
291 | }; | |
292 | /******************************************************************/ | |
293 | /******************************************************************/ | |
294 | /******************************************************************/ | |
295 | ||
296 | //____________________ | |
297 | /////////////////////////////////////////////////////// | |
298 | // // | |
299 | // AliHBTFunction3D // | |
300 | // // | |
301 | // Base Calss for 3-dimensinal Functions that need // | |
302 | // one pair to fill function // | |
303 | // // | |
304 | // Piotr.Skowronski@cern.ch // | |
305 | // http://alisoft.cern.ch/people/skowron/analyzer // | |
306 | // // | |
307 | /////////////////////////////////////////////////////// | |
308 | ||
309 | class AliHBTFunction3D: public AliHBTFunction | |
310 | { | |
311 | public: | |
312 | AliHBTFunction3D(); | |
313 | ||
314 | AliHBTFunction3D(const Char_t *name, const Char_t *title); | |
315 | ||
316 | AliHBTFunction3D(Int_t nXbins, Double_t maxXval, Double_t minXval, | |
317 | Int_t nYbins, Double_t maxYval, Double_t minYval, | |
318 | Int_t nZbins, Double_t maxZval, Double_t minZval); | |
319 | ||
320 | AliHBTFunction3D(const Char_t *name, const Char_t *title, | |
321 | Int_t nXbins, Double_t maxXval, Double_t minXval, | |
322 | Int_t nYbins, Double_t maxYval, Double_t minYval, | |
323 | Int_t nZbins, Double_t maxZval, Double_t minZval); | |
324 | ||
325 | AliHBTFunction3D(const AliHBTFunction3D & source); | |
326 | AliHBTFunction3D & operator= (const AliHBTFunction3D & /*source*/); | |
327 | ||
328 | virtual ~AliHBTFunction3D();//destructor | |
329 | ||
330 | TH1* GetNumerator() const {return fNumerator;} | |
331 | TH1* GetDenominator() const {return fDenominator;} | |
332 | ||
333 | ||
334 | void SetNumberOfBinsToScale(UInt_t xn = fgkDefaultNBinsToScaleX, | |
335 | UInt_t yn = fgkDefaultNBinsToScaleY, | |
336 | UInt_t zn = fgkDefaultNBinsToScaleZ); | |
337 | ||
338 | Double_t Scale(); | |
339 | ||
340 | protected: | |
341 | virtual void BuildHistos(Int_t nxbins, Float_t xmax, Float_t xmin, | |
342 | Int_t nybins, Float_t ymax, Float_t ymin, | |
343 | Int_t nzbins, Float_t zmax, Float_t zmin); | |
344 | virtual void BuildHistos(); | |
345 | ||
346 | TH3F* fNumerator; // Numerator histogram | |
347 | TH3F* fDenominator; // Denominator histogram | |
348 | ||
349 | //definition of area used for scaling -> Scale is calculated this | |
350 | //way that after division tale is on 1 | |
351 | UInt_t fNBinsToScaleX;//number of bins on X axis | |
352 | UInt_t fNBinsToScaleY;//number of bins on Y axis | |
353 | UInt_t fNBinsToScaleZ;//number of bins on Z axis | |
354 | ||
355 | private: | |
356 | //this must be declared before constructors because they are used as a default arguments | |
357 | static const Int_t fgkDefaultNBinsX;//default number of Bins in X axis in histograms | |
358 | static const Float_t fgkDefaultMinX;//Default min value of X axis in histograms | |
359 | static const Float_t fgkDefaultMaxX;//Default max value of X axis inhistograms | |
360 | static const Int_t fgkDefaultNBinsY;//default number of Bins in Y axis in histograms | |
361 | static const Float_t fgkDefaultMinY;//Default min value of Y axis in histograms | |
362 | static const Float_t fgkDefaultMaxY;//Default max value of Y axis inhistograms | |
363 | static const Int_t fgkDefaultNBinsZ;//default number of Bins in Z axis in histograms | |
364 | static const Float_t fgkDefaultMinZ;//Default min value of Z axis in histograms | |
365 | static const Float_t fgkDefaultMaxZ;//Default max value of Z axis inhistograms | |
366 | ||
367 | static const UInt_t fgkDefaultNBinsToScaleX;//Default number of X bins used for scaling to tale | |
368 | static const UInt_t fgkDefaultNBinsToScaleY;//Default number of Y bins used for scaling to tale | |
369 | static const UInt_t fgkDefaultNBinsToScaleZ;//Default number of Z bins used for scaling to tale | |
370 | ||
371 | ClassDef(AliHBTFunction3D,2) | |
372 | }; | |
373 | /******************************************************************/ | |
374 | /******************************************************************/ | |
375 | /******************************************************************/ | |
376 | ||
377 | //____________________ | |
378 | /////////////////////////////////////////////////////// | |
379 | // // | |
380 | // AliHBTOnePairFctn1D // | |
381 | // // | |
382 | // Base Calss for 1-dimensinal Functions that need // | |
383 | // one pair to fill function // | |
384 | // // | |
385 | // Piotr.Skowronski@cern.ch // | |
386 | // http://alisoft.cern.ch/people/skowron/analyzer // | |
387 | // // | |
388 | /////////////////////////////////////////////////////// | |
389 | ||
390 | class AliHBTOnePairFctn1D: public AliHBTOnePairFctn, public AliHBTFunction1D | |
391 | { | |
392 | public: | |
393 | AliHBTOnePairFctn1D(){}//default conmstructor | |
394 | AliHBTOnePairFctn1D(Int_t nbins, Float_t maxXval, Float_t minXval); | |
395 | AliHBTOnePairFctn1D(const Char_t *name, const Char_t *title); | |
396 | AliHBTOnePairFctn1D(const Char_t *name, const Char_t *title, | |
397 | Int_t nbins, Float_t maxXval, Float_t minXval); | |
398 | virtual ~AliHBTOnePairFctn1D(){} | |
399 | ||
400 | void ProcessSameEventParticles(AliHBTPair* pair); | |
401 | void ProcessDiffEventParticles(AliHBTPair* pair); | |
402 | void Write(){WriteFunction();} | |
403 | void Init(){InitFunction();} | |
404 | const char* Name(){return GetName();} | |
405 | ||
406 | protected: | |
407 | //retruns velue to be histogrammed | |
408 | virtual Double_t GetValue(AliHBTPair* pair) = 0; | |
409 | ClassDef(AliHBTOnePairFctn1D,2) | |
410 | }; | |
411 | /******************************************************************/ | |
412 | /******************************************************************/ | |
413 | /******************************************************************/ | |
414 | ||
415 | //____________________ | |
416 | /////////////////////////////////////////////////////// | |
417 | // // | |
418 | // AliHBTOnePairFctn2D // | |
419 | // // | |
420 | // Base Calss for 2-dimensinal Functions that need // | |
421 | // one pair to fill function // | |
422 | // // | |
423 | // Piotr.Skowronski@cern.ch // | |
424 | // http://alisoft.cern.ch/people/skowron/analyzer // | |
425 | // // | |
426 | /////////////////////////////////////////////////////// | |
427 | ||
428 | class AliHBTOnePairFctn2D: public AliHBTOnePairFctn, public AliHBTFunction2D | |
429 | { | |
430 | public: | |
431 | AliHBTOnePairFctn2D(){} | |
432 | ||
433 | AliHBTOnePairFctn2D(const Char_t *name, const Char_t *title); | |
434 | ||
435 | AliHBTOnePairFctn2D(Int_t nXbins, Double_t maxXval, Double_t minXval, | |
436 | Int_t nYbins, Double_t maxYval, Double_t minYval); | |
437 | ||
438 | AliHBTOnePairFctn2D(const Char_t *name, const Char_t *title, | |
439 | Int_t nXbins, Double_t maxXval, Double_t minXval, | |
440 | Int_t nYbins, Double_t maxYval, Double_t minYval); | |
441 | ||
442 | virtual ~AliHBTOnePairFctn2D(){} | |
443 | ||
444 | void ProcessSameEventParticles(AliHBTPair* pair); | |
445 | void ProcessDiffEventParticles(AliHBTPair* pair); | |
446 | void Write(){WriteFunction();} | |
447 | void Init(){InitFunction();} | |
448 | const char* Name(){return GetName();} | |
449 | protected: | |
450 | virtual void GetValues(AliHBTPair* pair, Double_t& x, Double_t& y) = 0; | |
451 | ClassDef(AliHBTOnePairFctn2D,2) | |
452 | }; | |
453 | /******************************************************************/ | |
454 | /******************************************************************/ | |
455 | /******************************************************************/ | |
456 | ||
457 | //____________________ | |
458 | /////////////////////////////////////////////////////// | |
459 | // // | |
460 | // AliHBTOnePairFctn3D // | |
461 | // // | |
462 | // Base Calss for 3-dimensinal Functions that need // | |
463 | // one pair to fill function // | |
464 | // // | |
465 | // Piotr.Skowronski@cern.ch // | |
466 | // http://alisoft.cern.ch/people/skowron/analyzer // | |
467 | // // | |
468 | /////////////////////////////////////////////////////// | |
469 | ||
470 | class AliHBTOnePairFctn3D: public AliHBTOnePairFctn, public AliHBTFunction3D | |
471 | { | |
472 | public: | |
473 | AliHBTOnePairFctn3D(){} | |
474 | ||
475 | AliHBTOnePairFctn3D(const Char_t *name, const Char_t *title); | |
476 | ||
477 | AliHBTOnePairFctn3D(Int_t nXbins, Double_t maxXval, Double_t minXval, | |
478 | Int_t nYbins, Double_t maxYval, Double_t minYval, | |
479 | Int_t nZbins, Double_t maxZval, Double_t minZval); | |
480 | ||
481 | AliHBTOnePairFctn3D(const Char_t *name, const Char_t *title, | |
482 | Int_t nXbins, Double_t maxXval, Double_t minXval, | |
483 | Int_t nYbins, Double_t maxYval, Double_t minYval, | |
484 | Int_t nZbins, Double_t maxZval, Double_t minZval); | |
485 | ||
486 | virtual ~AliHBTOnePairFctn3D(){}//destructor | |
487 | ||
488 | void ProcessSameEventParticles(AliHBTPair* pair); | |
489 | void ProcessDiffEventParticles(AliHBTPair* pair); | |
490 | void Write(){WriteFunction();} | |
491 | void Init(){InitFunction();} | |
492 | const char* Name(){return GetName();} | |
493 | protected: | |
494 | virtual void GetValues(AliHBTPair* pair, Double_t& x, Double_t& y, Double_t& z) = 0; | |
495 | ClassDef(AliHBTOnePairFctn3D,2) | |
496 | }; | |
497 | /******************************************************************/ | |
498 | /******************************************************************/ | |
499 | /******************************************************************/ | |
500 | ||
501 | //____________________ | |
502 | /////////////////////////////////////////////////////// | |
503 | // // | |
504 | // AliHBTTwoPairFctn1D // | |
505 | // // | |
506 | // Base Calss for 1-dimensinal Functions that need // | |
507 | // two pair (simulated and reconstructed) // | |
508 | // to fill function // | |
509 | // // | |
510 | // Piotr.Skowronski@cern.ch // | |
511 | // http://alisoft.cern.ch/people/skowron/analyzer // | |
512 | // // | |
513 | /////////////////////////////////////////////////////// | |
514 | ||
515 | class AliHBTTwoPairFctn1D: public AliHBTTwoPairFctn, public AliHBTFunction1D | |
516 | { | |
517 | public: | |
518 | AliHBTTwoPairFctn1D(){}//default conmstructor | |
519 | AliHBTTwoPairFctn1D(Int_t nbins, Float_t maxXval, Float_t minXval); | |
520 | AliHBTTwoPairFctn1D(const Char_t *name, const Char_t *title); | |
521 | AliHBTTwoPairFctn1D(const Char_t *name, const Char_t *title, | |
522 | Int_t nbins, Float_t maxXval, Float_t minXval); | |
523 | virtual ~AliHBTTwoPairFctn1D(){} | |
524 | ||
525 | void ProcessSameEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair); | |
526 | void ProcessDiffEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair); | |
527 | void Write(){WriteFunction();} | |
528 | void Init(){InitFunction();} | |
529 | const char* Name(){return GetName();} | |
530 | ||
531 | protected: | |
532 | virtual Double_t GetValue(AliHBTPair* trackpair, AliHBTPair* partpair) = 0; | |
533 | ||
534 | ClassDef(AliHBTTwoPairFctn1D,2) | |
535 | }; | |
536 | /******************************************************************/ | |
537 | /******************************************************************/ | |
538 | /******************************************************************/ | |
539 | ||
540 | //____________________ | |
541 | /////////////////////////////////////////////////////// | |
542 | // // | |
543 | // AliHBTTwoPairFctn2D // | |
544 | // // | |
545 | // Base Calss for 2-dimensinal Functions that need // | |
546 | // two pair (simulated and reconstructed) // | |
547 | // to fill function // | |
548 | // // | |
549 | // Piotr.Skowronski@cern.ch // | |
550 | // http://alisoft.cern.ch/people/skowron/analyzer // | |
551 | // // | |
552 | /////////////////////////////////////////////////////// | |
553 | ||
554 | class AliHBTTwoPairFctn2D: public AliHBTTwoPairFctn, public AliHBTFunction2D | |
555 | { | |
556 | public: | |
557 | AliHBTTwoPairFctn2D(){} | |
558 | ||
559 | AliHBTTwoPairFctn2D(const Char_t *name, const Char_t *title); | |
560 | ||
561 | AliHBTTwoPairFctn2D(Int_t nXbins, Double_t maxXval, Double_t minXval, | |
562 | Int_t nYbins, Double_t maxYval, Double_t minYval); | |
563 | ||
564 | AliHBTTwoPairFctn2D(const Char_t *name, const Char_t *title, | |
565 | Int_t nXbins, Double_t maxXval, Double_t minXval, | |
566 | Int_t nYbins, Double_t maxYval, Double_t minYval); | |
567 | ||
568 | virtual ~AliHBTTwoPairFctn2D(){} | |
569 | ||
570 | void ProcessSameEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair); | |
571 | void ProcessDiffEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair); | |
572 | void Write(){WriteFunction();} | |
573 | void Init(){InitFunction();} | |
574 | const char* Name(){return GetName();} | |
575 | ||
576 | protected: | |
577 | virtual void GetValues(AliHBTPair* trackpair, AliHBTPair* partpair, Double_t& x, Double_t& y) = 0; | |
578 | ||
579 | ClassDef(AliHBTTwoPairFctn2D,2) | |
580 | }; | |
581 | /******************************************************************/ | |
582 | /******************************************************************/ | |
583 | /******************************************************************/ | |
584 | ||
585 | //____________________ | |
586 | /////////////////////////////////////////////////////// | |
587 | // // | |
588 | // AliHBTTwoPairFctn3D // | |
589 | // // | |
590 | // Base Calss for 3-dimensinal Functions that need // | |
591 | // two pair (simulated and reconstructed) // | |
592 | // to fill function // | |
593 | // // | |
594 | // Piotr.Skowronski@cern.ch // | |
595 | // http://alisoft.cern.ch/people/skowron/analyzer // | |
596 | // // | |
597 | /////////////////////////////////////////////////////// | |
598 | ||
599 | class AliHBTTwoPairFctn3D: public AliHBTTwoPairFctn, public AliHBTFunction3D | |
600 | { | |
601 | public: | |
602 | AliHBTTwoPairFctn3D(){} | |
603 | ||
604 | AliHBTTwoPairFctn3D(const Char_t *name, const Char_t *title); | |
605 | ||
606 | AliHBTTwoPairFctn3D(Int_t nXbins, Double_t maxXval, Double_t minXval, | |
607 | Int_t nYbins, Double_t maxYval, Double_t minYval, | |
608 | Int_t nZbins, Double_t maxZval, Double_t minZval); | |
609 | ||
610 | AliHBTTwoPairFctn3D(const Char_t *name, const Char_t *title, | |
611 | Int_t nXbins, Double_t maxXval, Double_t minXval, | |
612 | Int_t nYbins, Double_t maxYval, Double_t minYval, | |
613 | Int_t nZbins, Double_t maxZval, Double_t minZval); | |
614 | ||
615 | virtual ~AliHBTTwoPairFctn3D(){}//destructor | |
616 | ||
617 | void ProcessSameEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair); | |
618 | void ProcessDiffEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair); | |
619 | void Write(){WriteFunction();} | |
620 | void Init(){InitFunction();} | |
621 | const char* Name(){return GetName();} | |
622 | ||
623 | protected: | |
624 | virtual void GetValues(AliHBTPair* trackpair, AliHBTPair* partpair, Double_t& x, Double_t& y, Double_t& z) = 0; | |
625 | ||
626 | ClassDef(AliHBTTwoPairFctn3D,2) | |
627 | }; | |
628 | ||
629 | #endif |