]> git.uio.no Git - u/mrichter/AliRoot.git/blame_incremental - EVGEN/AliGenParam.h
Corrected (w.r.t. r59504) DPs for MCH: current values, will get added to MUON/Calib/HV
[u/mrichter/AliRoot.git] / EVGEN / AliGenParam.h
... / ...
CommitLineData
1#ifndef ALIGENPARAM_H
2#define ALIGENPARAM_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//
9// Class to generate particles from using parametrized pT and y distributions.
10// Distributions are obtained from pointer to object of type AliGenLib.
11// (For example AliGenMUONlib)
12//
13// andreas.morsch@cern.ch
14//
15
16#include "AliGenMC.h"
17
18class AliPythia;
19class TParticle;
20class AliGenLib;
21class TF1;
22
23typedef enum { kAnalog, kNonAnalog} Weighting_t;
24//-------------------------------------------------------------
25class AliGenParam : public AliGenMC
26{
27public:
28 AliGenParam();
29 AliGenParam(Int_t npart, const AliGenLib * Library, Int_t param, const char* tname = 0);
30 AliGenParam(Int_t npart, Int_t param, const char* tname = 0, const char* name = 0);
31 AliGenParam(Int_t npart, Int_t param,
32 Double_t (*PtPara)(const Double_t*, const Double_t*),
33 Double_t (*YPara )(const Double_t*, const Double_t*),
34 Double_t (*V2Para)(const Double_t*, const Double_t*),
35 Int_t (*IpPara)(TRandom*) );
36
37 virtual ~AliGenParam();
38 virtual void Generate();
39 virtual void Init();
40 // select particle type
41 virtual void SetParam(Int_t param) {fParam = param;}
42 //Setting the flag for Background transportation while using SetForceDecay()
43 void SetSelectAll(Bool_t selectall) {fSelectAll = selectall;}
44 // force decay type
45 virtual void SetWeighting(Weighting_t flag = kAnalog) {fAnalog = flag;}
46 virtual void SetDeltaPt(Float_t delta=0.01) {fDeltaPt = delta;}
47 virtual void SetDecayer(AliDecayer* decayer) {fDecayer = decayer;}
48 virtual void Draw(const char * opt);
49 TF1 * GetPt() { return fPtPara;}
50 TF1 * GetY() {return fYPara;}
51 Float_t GetRelativeArea(Float_t ptMin, Float_t ptMax, Float_t yMin, Float_t yMax, Float_t phiMin, Float_t phiMax);
52
53protected:
54 Double_t (*fPtParaFunc)(const Double_t*, const Double_t*); //! Pointer to Pt parametrisation function
55 Double_t (*fYParaFunc )(const Double_t*, const Double_t*); //! Pointer to Y parametrisation function
56 Int_t (*fIpParaFunc )(TRandom*); //! Pointer to particle type parametrisation function
57 Double_t (*fV2ParaFunc )(const Double_t*, const Double_t*);//! Pointer to V2 parametrisation function
58 TF1* fPtPara; // Transverse momentum parameterisation
59 TF1* fYPara; // Rapidity parameterisation
60 TF1* fV2Para; // v2 parametrization
61 TF1* fdNdPhi; // Phi distribution depending on v2
62 Int_t fParam; // Parameterisation type
63 Float_t fdNdy0; // central multiplicity per event
64 Float_t fYWgt; // Y-weight
65 Float_t fPtWgt; // Pt-weight
66 Float_t fBias; // Biasing factor
67 Int_t fTrials; // Number of trials
68 Float_t fDeltaPt; // pT sampling in steps of fDeltaPt
69 Bool_t fSelectAll; // Flag for transportation of Background while using SetForceDecay()
70 AliDecayer *fDecayer; // ! Pointer to pythia object for decays
71
72private:
73 AliGenParam(const AliGenParam &Param);
74 AliGenParam & operator=(const AliGenParam & rhs);
75
76 ClassDef(AliGenParam, 2) // Generator using parameterised pt- and y-distribution
77};
78#endif
79
80
81
82
83
84
85
86
87
88