]> git.uio.no Git - u/mrichter/AliRoot.git/blob - FASTSIM/AliFastGlauber.h
df1e4d46a3cbc8641cf18ef637c14572e8c240e7
[u/mrichter/AliRoot.git] / FASTSIM / AliFastGlauber.h
1 #ifndef ALIFASTGLAUBER_H
2 #define ALIFASTGLAUBER_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4  * See cxx source for full Copyright notice                               */
5
6 /* $Id$ */
7
8 #include <TObject.h>
9 class TF1;
10 class TF2;
11
12 class AliFastGlauber : public TObject {
13  public:
14     AliFastGlauber();
15     virtual ~AliFastGlauber(){;}
16     void SetWoodSaxonParameters(Double_t r0, Double_t d, Double_t w, Double_t n)
17         {fWSr0 = r0; fWSd = d; fWSw = w; fWSn = n;}
18     void SetMaxImpact(Float_t bmax = 20.) {fbMax = bmax;};
19     void SetHardCrossSection(Float_t xs = 6.6) {fSigmaHard = xs;}
20     
21     static Double_t WSb          (Double_t *xx, Double_t *par);
22     static Double_t WSbz         (Double_t *xx, Double_t *par);
23     static Double_t WSz          (Double_t *xx, Double_t *par);
24     static Double_t WSta         (Double_t *xx, Double_t *par);
25     static Double_t WStarfi      (Double_t *xx, Double_t *par);
26     static Double_t WStaa        (Double_t *xx, Double_t *par);
27     static Double_t WSgeo        (Double_t *xx, Double_t *par);
28     static Double_t WSbinary     (Double_t *xx, Double_t *par);
29     static Double_t WSN          (Double_t *xx, Double_t *par);
30     static Double_t WAlmond      (Double_t *xx, Double_t *par);
31     static Double_t WPathLength0 (Double_t *xx, Double_t *par);
32     static Double_t WPathLength  (Double_t *xx, Double_t *par);
33     static Double_t WIntRadius   (Double_t *xx, Double_t *par);
34     
35     void Init(Int_t mode = 0);
36     void DrawWSb();
37     void DrawThickness();
38     void DrawOverlap();
39     void DrawGeo();
40     void DrawBinary();
41     void DrawN();    
42     void DrawKernel(Double_t b);
43     void DrawAlmond(Double_t b);
44     void DrawPathLength0(Double_t b);
45     void DrawPathLength(Double_t b, Int_t ni = 1000);
46     void DrawIntRadius(Double_t b);
47     
48     Double_t CrossSection(Double_t b1, Double_t b2);
49     Double_t FractionOfHardCrossSection(Double_t b1, Double_t b2);
50     Double_t Binaries(Double_t b);
51     TF2* Kernel()  {return fWStarfi;}
52     TF1* Overlap() {return fWStaa;}
53     void SimulateTrigger(Int_t n);
54     void GetRandom(Float_t& b, Float_t& p, Float_t& mult);
55     void GetRandom(Int_t& bin, Bool_t& hard);
56     Float_t GetRandomImpactParameter(Float_t bmin, Float_t bmax);
57  protected:
58     static TF1*    fWSb;         // Wood-Saxon Function (b)
59     static TF2*    fWSbz;        // Wood-Saxon Function (b, z)
60     static TF1*    fWSz;         // Wood-Saxon Function (b = b0, z)
61     static TF1*    fWSta;        // Thickness Function
62     static TF2*    fWStarfi;     // Kernel for Overlap Function
63     static TF1*    fWStaa;       // Overlap Function
64     static TF2*    fWAlmond;     // Interaction Almond
65     static TF1*    fWPathLength0;// Path Length as a function of phi
66     static TF1*    fWPathLength; // Path Length as a function of phi
67     static TF1*    fWIntRadius;  // Interaction Radius
68     static TF1*    fWSgeo;       // dSigma/db geometric
69     static TF1*    fWSbinary;    // dSigma/db binary
70     static TF1*    fWSN;         // dN/db binary
71     
72     Float_t fWSr0;      // Wood-Saxon Parameter r0
73     Float_t fWSd;       // Wood-Saxon Parameter d
74     Float_t fWSw;       // Wood-Saxon Parameter w
75     Float_t fWSn;       // Wood-Saxon Parameter n
76     Float_t fSigmaHard; // Hard Cross Section
77     static Float_t fbMax;    // Maximum Impact Parameter
78     
79     ClassDef(AliFastGlauber,1) // Event geometry simulation in the Glauber Model
80 };
81
82 #endif 
83
84
85