1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
18 Revision 1.7 2000/05/02 08:12:13 morsch
19 Coding rule violations corrected.
21 Revision 1.6 1999/09/29 09:24:14 fca
22 Introduction of the Copyright and cvs Log
26 #include "AliGenGSIlib.h"
30 ClassImp(AliGenGSIlib)
32 Bool_t AliGenGSIlib::fgDebug =kFALSE;
37 //____________________________________________________________
38 Double_t AliGenGSIlib::PtUpsilonRitman( Double_t *px, Double_t *dummy )
41 /* AliGenMUONlib parametrisation
42 const Double_t kpt0 = 5.3;
43 const Double_t kxn = 2.5;
46 Double_t pass1 = 1.+(x/kpt0)*(x/kpt0);
47 return x/TMath::Power(pass1,kxn);
49 if (fgDebug) cout<<"Ritman Pt paramtrisation\n";
50 const Double_t kpt0 = 4.7;
51 const Double_t kxn = 3.5;
54 Double_t pass1 = 1.+((x*x)/(kpt0*kpt0));
55 return x/TMath::Power(pass1,kxn);
61 //____________________________________________________________
62 Double_t AliGenGSIlib::YUpsilonRitman(Double_t *py, Double_t *dummy)
67 /* original from AliGenMUON
68 const Double_t ky0 = 3.;
71 Double_t y=TMath::Abs(*py);
76 yu=kb*TMath::Exp(-(y-ky0)*(y-ky0)/2);
79 if (fgDebug) cout<<"Ritman Y paramtrisation\n";
80 return 0.003; //GSI parametrisation
82 // particle composition
84 Int_t AliGenGSIlib::IpUpsilonRitman()
87 if (fgDebug) cout<<"Ritman Ip paramtrisation\n";
92 Double_t AliGenGSIlib::PtUpsilonKarel( Double_t *px, Double_t *dummy )
96 if (fgDebug) cout<<"Karel Pt paramtrisation\n";
103 //____________________________________________________________
104 Double_t AliGenGSIlib::YUpsilonKarel(Double_t *py, Double_t *dummy)
109 if (fgDebug) cout<<"Karel Y paramtrisation\n";
110 return 0.003; //Karel parametrisation
113 // particle composition
116 Int_t AliGenGSIlib::IpUpsilonKarel()
120 if (fgDebug) cout<<"Karel Ip paramtrisation\n";
126 Double_t AliGenGSIlib::PtUpsilonMUON( Double_t *px, Double_t *dummy )
129 const Double_t kpt0 = 5.3;
130 const Double_t kxn = 2.5;
133 Double_t pass1 = 1.+(x/kpt0)*(x/kpt0);
134 return x/TMath::Power(pass1,kxn);
139 //____________________________________________________________
140 Double_t AliGenGSIlib::YUpsilonMUON(Double_t *py, Double_t *dummy)
143 const Double_t ky0 = 3.;
144 const Double_t kb=1.;
146 Double_t y=TMath::Abs(*py);
151 yu=kb*TMath::Exp(-(y-ky0)*(y-ky0)/2);
154 // particle composition
156 Int_t AliGenGSIlib::IpUpsilonMUON()
163 typedef Double_t (*GenFunc) (Double_t*, Double_t*);
165 typedef Int_t (*GenFuncIp) ();
169 GenFunc AliGenGSIlib::GetPt(Param_t param, const char * tname)
171 // Return pointer to pT parameterisation
173 TString sname(tname);
181 if (sname=="RITMAN"){
182 func=PtUpsilonRitman;
191 printf("<AliGenGSIlib::GetPt> unknown parametrisation\n");
194 printf("<AliGenGSIlib::GetPt> unknown parametrisation\n");
201 GenFunc AliGenGSIlib::GetY(Param_t param, const char * tname)
203 // Return pointer to y- parameterisation
205 TString sname(tname);
213 if (sname=="RITMAN"){
222 printf("<AliGenGSIlib::GetY> unknown parametrisation\n");
226 printf("<AliGenGSIlib::GetY> unknown parametrisation\n");
233 GenFuncIp AliGenGSIlib::GetIp(Param_t param, const char * tname)
235 // Return pointer to particle type parameterisation
237 TString sname(tname);
245 if (sname=="RITMAN"){
246 func=IpUpsilonRitman;
254 printf("<AliGenGSIlib::GetIP> unknown parametrisation\n");
258 printf("<AliGenGSIlib::GetIp> unknown parametrisation\n");