]>
Commit | Line | Data |
---|---|---|
d92ed900 | 1 | /////////////////////////////////////////////////////////////////////////// |
2 | // // | |
3 | // AliFemtoCoulomb: This is a Coulomb correction class which // | |
4 | // 1. Reads in the dat from a file // | |
5 | // 2. Performs a linear interpolation in R and creates any array of // | |
6 | // interpolations // | |
7 | // 3. Interpolates in eta and returns the Coulomb correction to user // | |
8 | // // | |
9 | /////////////////////////////////////////////////////////////////////////// | |
67427ff7 | 10 | |
d92ed900 | 11 | #ifndef ALIFEMTOCOULOMB_H |
12 | #define ALIFEMTOCOULOMB_H | |
67427ff7 | 13 | |
14 | #include <stdio.h> | |
d0e92d9a | 15 | #include "AliFemtoTypes.h" |
16 | #include "AliFemtoPair.h" | |
17 | #include "AliFemtoParticle.h" | |
67427ff7 | 18 | #include "TH1D.h" |
19 | #include "TH3D.h" | |
20 | ||
21 | class AliFemtoCoulomb { | |
22 | ||
23 | public: | |
24 | AliFemtoCoulomb(); | |
25 | AliFemtoCoulomb(const char *readFile, const double& radius, const double& charge); | |
0215f606 | 26 | AliFemtoCoulomb(const AliFemtoCoulomb& aCoul); |
67427ff7 | 27 | virtual ~AliFemtoCoulomb(); |
28 | ||
0215f606 | 29 | AliFemtoCoulomb& operator=(const AliFemtoCoulomb& aCoul); |
30 | ||
67427ff7 | 31 | void SetRadius(const double& radius); |
d92ed900 | 32 | double GetRadius() const; |
67427ff7 | 33 | void SetFile(const char *readFile); |
34 | void SetChargeProduct(const double& charge); | |
35 | ||
36 | // These have different names so eta/Qinv don't confuse the compiler | |
37 | double CoulombCorrect(const double& eta); | |
38 | double CoulombCorrect(const double& eta, const double& radius); | |
39 | double CoulombCorrect(const AliFemtoPair* pair); | |
40 | double CoulombCorrect(const AliFemtoPair* pair, const double& radius); | |
41 | double CoulombCorrect(const double& mass, const double& charge, | |
42 | const double& radius, const double& qInv); | |
43 | TH1D* CorrectionHistogram(const double& mass1, const double& mass2, const int& nBins, | |
44 | const double& low, const double& high); | |
45 | #ifdef __ROOT__ | |
46 | TH1D* CorrectionHistogram(const TH1D*, const double); | |
47 | TH3D* CorrectionHistogram(const TH3D*, const double); | |
48 | #endif | |
49 | private: | |
d92ed900 | 50 | double Eta(const AliFemtoPair* pair); // Calculates eta |
67427ff7 | 51 | void CreateLookupTable(const double& radius); // Creates look-up table |
52 | const char* fFile; // File to interpolate corrections from | |
53 | double fRadius; // Radius from previous iteration | |
54 | double fZ1Z2; // Charge product of particles | |
55 | double fEta[1000]; // interpolated Coulomb correction table | |
56 | double fCoulomb[1000]; // interpolated Coulomb correction table | |
57 | int fNLines; // Number of Eta's in lookup-table | |
58 | ||
59 | #ifdef __ROOT__ | |
60 | ClassDef(AliFemtoCoulomb, 0) | |
61 | #endif | |
62 | }; | |
63 | ||
64 | ||
65 | #endif |