LCOV - code coverage report
Current view: top level - EVGEN - AliGenEMlib.h (source / functions) Hit Total Coverage
Test: coverage.info Lines: 1 11 9.1 %
Date: 2016-06-14 17:26:59 Functions: 1 14 7.1 %

          Line data    Source code
       1             : #ifndef ALIGENEMLIB_H
       2             : #define ALIGENEMLIB_H
       3             : /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
       4             :  * See cxx source for full Copyright notice                               */
       5             : 
       6             : /* $Id: AliGenEMlib.h 30052 2008-11-25 14:54:18Z morsch $ */
       7             : 
       8             : /////////////////////////////////////////////////////////////////////////////
       9             : //                                                                         //
      10             : // Implementation of AliGenEMlib for electron, di-electron, and photon     //
      11             : // cocktail calculations.                                                  //
      12             : // It is based on AliGenGSIlib.                                            //
      13             : //                                                                         //
      14             : // Responsible: R.Averbeck@gsi.de                                          //
      15             : //                                                                         //
      16             : /////////////////////////////////////////////////////////////////////////////
      17             : 
      18             : #include "AliGenLib.h"
      19             : class TRandom;
      20             : 
      21           0 : class AliGenEMlib :public AliGenLib {
      22             : public:
      23             : 
      24             :   enum Particle_t{ kPizero=0, kEta=1, kRho0=2, kOmega=3, kEtaprime=4, kPhi=5, kJpsi=6,
      25             :        kSigma0=7, kK0s=8, kDeltaPlPl=9, kDeltaPl=10, kDeltaMi=11, kDeltaZero=12,
      26             :        kRhoPl=13, kRhoMi=14, kK0star=15, kDirectRealGamma=16, kDirectVirtGamma=17 };
      27             :   
      28             :   enum CollisionSystem_t {kpp900GeV=0x000, kpp2760GeV=0x64, kpp7TeV=0xC8, kpPb=0x12C, kPbPb=0x190};
      29             : 
      30             : 
      31             :   
      32             :   enum Centrality_t{ kpp = 0x0, k0005=0x1, k0510=0x2, k1020=0x3, k2030=0x4, k3040=0x5, k4050=0x6, k5060=0x7,
      33             :          k0010=0x8, k2040=0x9, k4060=0xA, k6080=0xB, k0020=0xC, k0040=0xD, k2080=0xE, k4080=0xF, kCentralities=0x10};
      34             :   
      35             :   enum PtParamSetPi0_t{ kPizeroParam, kPizeroParamlow, kPizeroParamhigh, kPichargedParam,
      36             :       kPichargedParamlow, kPichargedParamhigh, kPizeroParamAlter,
      37             :       kPizeroParamAlterlow, kPizeroParamAlterhigh, kNPi0Param,
      38             :       kPichargedParamNew, kPichargedParamOld };
      39             :   
      40             :   enum PtParamSetEta_t{ kEtaMtScal=0, kEtaParampp, kEtaParampplow, kEtaParampphigh,
      41             :             kEtaParamRatiopp, kEtaParamRatiopplow, kEtaParamRatiopphigh,
      42             :             kEtaParamPbPb, kEtaParamPPb };
      43             :   
      44             :   enum PtParamSetOmega_t{ kOmegaMtScal=0, kOmegaParampp, kOmegaParampplow, kOmegaParampphigh,
      45             :         kOmegaParamRatiopp, kOmegaParamRatiopplow, kOmegaParamRatiopphigh,
      46             :         kOmegaParamPbPb, kOmegaParamPPb };
      47             :   
      48             :   enum PtParamSetPhi_t{ kPhiMtScal=0, kPhiParampp, kPhiParampplow, kPhiParampphigh,
      49             :             kPhiParamPbPb, kPhiParamPPb, kPhiParamPPblow, kPhiParamPPbhigh };
      50             :   
      51             :   enum v2Sys_t{kLoV2Sys=-1, kNoV2Sys=0, kUpV2Sys=+1};
      52             :  
      53           0 :   AliGenEMlib() { } ;
      54             : 
      55             :   static void SelectParams( Int_t collisionSystem,
      56             :                             Int_t ptSelectPi0, 
      57             :                             Int_t ptSelectEta     = kEtaMtScal, 
      58             :                             Int_t ptSelectOmega   = kOmegaMtScal,
      59             :                             Int_t ptSelectPhi     = kPhiMtScal, 
      60             :                             Int_t centSelect      = kpp, 
      61             :                             Int_t v2sys           = kNoV2Sys) {  
      62           0 :     fgSelectedCollisionsSystem  = collisionSystem;
      63           0 :     fgSelectedPtParamPi0        = ptSelectPi0; 
      64           0 :     fgSelectedPtParamEta        = ptSelectEta; 
      65           0 :     fgSelectedPtParamOmega      = ptSelectOmega; 
      66           0 :     fgSelectedPtParamPhi        = ptSelectPhi; 
      67           0 :     fgSelectedCentrality        = centSelect; 
      68           0 :     fgSelectedV2Systematic      = v2sys; 
      69           0 :   }
      70             : 
      71             :   GenFunc   GetPt(Int_t param, const char * tname=0) const;
      72             :   GenFunc   GetY(Int_t param, const char * tname=0) const;
      73             :   GenFuncIp GetIp(Int_t param, const char * tname=0) const;    
      74             :   GenFunc   GetV2(Int_t param, const char * tname=0) const;
      75             : 
      76             :   //private:
      77             : 
      78             :   // General functions
      79             : 
      80             :   // General functions
      81             :   static Int_t fgSelectedCollisionsSystem; // selected pT parameter
      82             :   static Int_t fgSelectedPtParamPi0; // selected pT parameter
      83             :   static Int_t fgSelectedPtParamEta; // selected pT parameter
      84             :   static Int_t fgSelectedPtParamOmega; // selected pT parameter
      85             :   static Int_t fgSelectedPtParamPhi; // selected pT parameter
      86             :   static Int_t fgSelectedCentrality; // selected Centrality
      87             :   static Int_t fgSelectedV2Systematic; // selected v2 systematics, usefully values: -1,0,1
      88             : 
      89             : 
      90             :   static Double_t PtModifiedHagedornThermal(Double_t pt, 
      91             :                                             Double_t c, 
      92             :                                             Double_t p0, 
      93             :                                             Double_t p1, 
      94             :                                             Double_t n,
      95             :                                             Double_t cT,
      96             :                                             Double_t T);
      97             : 
      98             : 
      99             :   
     100             :   static Double_t PtModifiedHagedornExp(Double_t pt,
     101             :                                         Double_t c,
     102             :                                         Double_t p0,
     103             :                                         Double_t p1,
     104             :                                         Double_t p2,
     105             :                                         Double_t n); 
     106             : 
     107             : 
     108             :   static Double_t PtModifiedHagedornExp2( Double_t pt,
     109             :                                           Double_t c,
     110             :                                           Double_t a,
     111             :                                           Double_t b,
     112             :                                           Double_t p0,
     113             :                                           Double_t p1,
     114             :                                           Double_t d,
     115             :                                           Double_t n);
     116             : 
     117             : 
     118             :   static Double_t PtTsallis(Double_t pt,
     119             :                             Double_t m,
     120             :                             Double_t c,
     121             :                             Double_t T,
     122             :                             Double_t n);
     123             : 
     124             :   static Double_t PtParticleRatiopp(Double_t pt,
     125             :                                     Double_t m1,
     126             :                                     Double_t m2,
     127             :                                     Double_t c1,
     128             :                                     Double_t c2,
     129             :                                     Double_t T1,
     130             :                                     Double_t T2,
     131             :                                     Double_t n);
     132             :   
     133             :   static Double_t PtXQCD( Double_t pt,
     134             :                           Double_t a,
     135             :                           Double_t b,
     136             :                           Double_t c,
     137             :                           Double_t d,
     138             :                           Double_t e,
     139             :                           Double_t f);
     140             :   
     141             :   static Double_t PtModTsallis( Double_t pt,
     142             :                                 Double_t a,
     143             :                                 Double_t b,
     144             :                                 Double_t c,
     145             :                                 Double_t d,
     146             :                                 Double_t e,
     147             :                                 Double_t f,
     148             :                                 Double_t g,
     149             :                                 Double_t mass);
     150             :   
     151             :   static Double_t PtQCD(  Double_t pt,
     152             :                           Double_t a,
     153             :                           Double_t b,
     154             :                           Double_t c,
     155             :                           Double_t d,
     156             :                           Double_t e);
     157             : 
     158             :   static Double_t PtExponential(const Double_t *pt, const Double_t *param);
     159             :   static Double_t PtModifiedHagedornPowerlaw(const Double_t *pt, const Double_t *param);
     160             :   static Double_t PtDoublePowerlaw(const Double_t *pt, const Double_t *param);
     161             :   static Double_t IntegratedKrollWada(const Double_t *mh, const Double_t *);
     162             : 
     163             :   // direct gamma
     164             :   static Double_t PtPromptRealGamma(const Double_t *px, const Double_t *dummy);
     165             :   static Double_t PtPromptVirtGamma(const Double_t *px, const Double_t *dummy);
     166             :   static Double_t PtThermalRealGamma(const Double_t *px, const Double_t *dummy);
     167             :   static Double_t PtThermalVirtGamma(const Double_t *px, const Double_t *dummy);
     168             : 
     169             :   static Int_t    IpDirectRealGamma(TRandom *ran);
     170             :   static Double_t PtDirectRealGamma(const Double_t *px, const Double_t *dummy);
     171             :   static Double_t YDirectRealGamma(const Double_t *py, const Double_t *dummy);
     172             :   static Double_t V2DirectRealGamma(const Double_t *px, const Double_t *dummy);
     173             : 
     174             :   static Int_t    IpDirectVirtGamma(TRandom *ran);
     175             :   static Double_t PtDirectVirtGamma(const Double_t *px, const Double_t *dummy);
     176             :   static Double_t YDirectVirtGamma(const Double_t *py, const Double_t *dummy);
     177             :   static Double_t V2DirectVirtGamma(const Double_t *px, const Double_t *dummy);
     178             : 
     179             :   // Pizero
     180             :   static Int_t    IpPizero(TRandom *ran);
     181             :   static Double_t PtPizero(const Double_t *px, const Double_t *dummy);
     182             :   static Double_t YPizero(const Double_t *py, const Double_t *dummy);
     183             :   static Double_t V2Pizero(const Double_t *px, const Double_t *dummy);
     184             : 
     185             :   // Eta
     186             :   static Int_t    IpEta(TRandom *ran);
     187             :   static Double_t PtEta(const Double_t *px, const Double_t *dummy);
     188             :   static Double_t YEta(const Double_t *py, const Double_t *dummy);
     189             :   static Double_t V2Eta(const Double_t *px, const Double_t *dummy);
     190             : 
     191             :   // Rho
     192             :   static Int_t    IpRho0(TRandom *ran);
     193             :   static Double_t PtRho0(const Double_t *px, const Double_t *dummy);
     194             :   static Double_t YRho0(const Double_t *py, const Double_t *dummy);
     195             :   static Double_t V2Rho0(const Double_t *py, const Double_t *dummy);
     196             : 
     197             : 
     198             :   // Omega
     199             :   static Int_t    IpOmega(TRandom *ran);
     200             :   static Double_t PtOmega(const Double_t *px, const Double_t *dummy);
     201             :   static Double_t YOmega(const Double_t *py, const Double_t *dummy);
     202             :   static Double_t V2Omega(const Double_t *py, const Double_t *dummy);
     203             : 
     204             :   // Etaprime
     205             :   static Int_t    IpEtaprime(TRandom *ran);
     206             :   static Double_t PtEtaprime(const Double_t *px, const Double_t *dummy);
     207             :   static Double_t YEtaprime(const Double_t *py, const Double_t *dummy);
     208             :   static Double_t V2Etaprime(const Double_t *py, const Double_t *dummy);
     209             : 
     210             :   // Phi
     211             :   static Int_t    IpPhi(TRandom *ran);
     212             :   static Double_t PtPhi(const Double_t *px, const Double_t *dummy);
     213             :   static Double_t YPhi(const Double_t *py, const Double_t *dummy);
     214             :   static Double_t V2Phi(const Double_t *py, const Double_t *dummy);
     215             : 
     216             :   // Jpsi
     217             :   static Int_t    IpJpsi(TRandom *ran);
     218             :   static Double_t PtJpsi(const Double_t *px, const Double_t *dummy);
     219             :   static Double_t YJpsi(const Double_t *py, const Double_t *dummy);
     220             :   static Double_t V2Jpsi(const Double_t *py, const Double_t *dummy);
     221             : 
     222             :   // Sigma
     223             :   static Int_t    IpSigma(TRandom *ran);
     224             :   static Double_t PtSigma( const Double_t *px, const Double_t *dummy );
     225             :   static Double_t YSigma(const Double_t *py, const Double_t *dummy);
     226             :   static Double_t V2Sigma0( const Double_t *px, const Double_t *dummy );
     227             :   
     228             :   // K0short
     229             :   static Int_t    IpK0short(TRandom *ran);
     230             :   static Double_t PtK0short( const Double_t *px, const Double_t *dummy );
     231             :   static Double_t YK0short(const Double_t *py, const Double_t *dummy);
     232             :   static Double_t V2K0sshort( const Double_t *px, const Double_t *dummy );
     233             : 
     234             :   // Delta++
     235             :   static Int_t    IpDeltaPlPl(TRandom *ran);
     236             :   static Double_t PtDeltaPlPl( const Double_t *px, const Double_t *dummy );
     237             :   static Double_t YDeltaPlPl(const Double_t *py, const Double_t *dummy);
     238             :   static Double_t V2DeltaPlPl( const Double_t *px, const Double_t *dummy );
     239             :   
     240             :   // Delta+
     241             :   static Int_t    IpDeltaPl(TRandom *ran);
     242             :   static Double_t PtDeltaPl( const Double_t *px, const Double_t *dummy );
     243             :   static Double_t YDeltaPl(const Double_t *py, const Double_t *dummy);
     244             :   static Double_t V2DeltaPl( const Double_t *px, const Double_t *dummy );
     245             :   
     246             :   // Delta-
     247             :   static Int_t    IpDeltaMi(TRandom *ran);
     248             :   static Double_t PtDeltaMi( const Double_t *px, const Double_t *dummy );
     249             :   static Double_t YDeltaMi(const Double_t *py, const Double_t *dummy);
     250             :   static Double_t V2DeltaMi( const Double_t *px, const Double_t *dummy );
     251             :   
     252             :   // Delta0
     253             :   static Int_t    IpDeltaZero(TRandom *ran);
     254             :   static Double_t PtDeltaZero( const Double_t *px, const Double_t *dummy );
     255             :   static Double_t YDeltaZero(const Double_t *py, const Double_t *dummy);
     256             :   static Double_t V2DeltaZero( const Double_t *px, const Double_t *dummy );
     257             : 
     258             :   // Rho+
     259             :   static Int_t    IpRhoPl(TRandom *ran);
     260             :   static Double_t PtRhoPl( const Double_t *px, const Double_t *dummy );
     261             :   static Double_t YRhoPl(const Double_t *py, const Double_t *dummy);
     262             :   static Double_t V2RhoPl( const Double_t *px, const Double_t *dummy );
     263             : 
     264             :   // Rho-
     265             :   static Int_t    IpRhoMi(TRandom *ran);
     266             :   static Double_t PtRhoMi( const Double_t *px, const Double_t *dummy );
     267             :   static Double_t YRhoMi(const Double_t *py, const Double_t *dummy);
     268             :   static Double_t V2RhoMi( const Double_t *px, const Double_t *dummy );
     269             : 
     270             :   // K0*
     271             :   static Int_t    IpK0star(TRandom *ran);
     272             :   static Double_t PtK0star( const Double_t *px, const Double_t *dummy );
     273             :   static Double_t YK0star(const Double_t *py, const Double_t *dummy);
     274             :   static Double_t V2K0star( const Double_t *px, const Double_t *dummy );
     275             :   
     276             : 
     277             :   // General
     278             :   //static Double_t PtFlat(const Double_t *px, const Double_t *dummy);
     279             :   static Double_t YFlat(Double_t y);
     280             :   static Double_t MtScal(Double_t pt, Int_t np);
     281             :   static Double_t V2Param(const Double_t *px, const Double_t *param);
     282             :   static Double_t V2Flat(const Double_t *px, const Double_t *param);
     283             :   static Double_t KEtScal(Double_t pt, Int_t np, Int_t nq=2);
     284             :   static Double_t GetTAA(Int_t cent);
     285             : 
     286             :   static Double_t CrossOverLc(double a, double b, double x);
     287             :   static Double_t CrossOverRc(double a, double b, double x);
     288             : 
     289             :   static const Double_t fgkPtParam[kCentralities][10];                     // parameters of pi pt spectrum
     290             :   static const Double_t fgkModTsallisParamPi0PbPb[kCentralities][7];       // parameters for ModTsallis function for pi0 in PbPb 
     291             :   static const Double_t fgkModTsallisParamPiChargedPbPb[kCentralities][7]; // parameters for ModTsallis function for pi+- in PbPb 
     292             :   static const Double_t fgkV2param[kCentralities][16];                     // parameters of pi v2
     293             :   static const Double_t fgkRawPtOfV2Param[kCentralities][10];              // parameters of the raw pt spectrum of v2 analysys
     294             :   static const Double_t fgkThermPtParam[kCentralities][2];                 // parameters of thermal gamma pt
     295             :   static const Double_t fgkHM[16];                                         // particle masses
     296             :   static const Double_t fgkMtFactor[3][16];                                // mt scaling factor
     297             :   static const Double_t fgkParamSetPi07TeV[kNPi0Param][7];                 // parameters for pi0 in 7 TeV
     298             :   static const Double_t fgkParamSetPi02760GeV[kNPi0Param][7];              // parameters for pi0 in 2.76 TeV
     299             :   static const Double_t fgkParamSetPi0900GeV[kNPi0Param][7];               // parameters for pi0 in 0.9 TeV
     300             : 
     301           6 :   ClassDef(AliGenEMlib,2)
     302             : 
     303             : };
     304             : 
     305             : 
     306             : #endif

Generated by: LCOV version 1.11