| 1 | |
| 2 | #ifndef AliGenParam_H |
| 3 | #define AliGenParam_H |
| 4 | #include "AliGenerator.h" |
| 5 | #include "AliPythia.h" |
| 6 | #include "TNamed.h" |
| 7 | #include "TF1.h" |
| 8 | #include "TArrayF.h" |
| 9 | #include "TArrayI.h" |
| 10 | #include "TTree.h" |
| 11 | #include "TMCParticle.h" |
| 12 | |
| 13 | //------------------------------------------------------------- |
| 14 | class AliGenParam : public AliGenerator |
| 15 | { |
| 16 | protected: |
| 17 | Double_t (*fPtParaFunc)(Double_t*, Double_t*); |
| 18 | Double_t (*fYParaFunc )(Double_t*, Double_t*); |
| 19 | Int_t (*fIpParaFunc )(); |
| 20 | TF1* fPtPara; |
| 21 | TF1* fYPara; |
| 22 | Param_t fParam; |
| 23 | Float_t fdNdy0; |
| 24 | Float_t fYWgt; |
| 25 | Float_t fPtWgt; |
| 26 | Weighting_t fAnalog; //Flaf for anolog or pt-weighted generation |
| 27 | Float_t fBias; |
| 28 | Int_t fTrials; |
| 29 | Decay_t fForceDecay; |
| 30 | TArrayI fChildSelect; |
| 31 | AliPythia *fPythia; |
| 32 | private: |
| 33 | // check if particle is selected as child |
| 34 | Bool_t ChildSelected(Int_t ip); |
| 35 | // all kinematic selection goes here |
| 36 | Bool_t KinematicSelection(TMCParticle *particle); |
| 37 | public: |
| 38 | AliGenParam(); |
| 39 | AliGenParam(Int_t npart, Param_t param); |
| 40 | // Double_t (*PtPara)(Double_t*, Double_t*), |
| 41 | // Double_t (*YPara )(Double_t*, Double_t*)); |
| 42 | virtual ~AliGenParam(); |
| 43 | virtual void Generate(); |
| 44 | virtual void Init(); |
| 45 | // select particle type |
| 46 | virtual void SetParam(Param_t param=jpsi_p) {fParam=param;} |
| 47 | // force decay type |
| 48 | virtual void ForceDecay(Decay_t decay=dimuon) {fForceDecay=decay;} |
| 49 | virtual void SetWeighting(Weighting_t flag=analog) {fAnalog=flag;} |
| 50 | ClassDef(AliGenParam,1) // Generator using parameterised pt- and y-distribution |
| 51 | }; |
| 52 | #endif |
| 53 | |
| 54 | |
| 55 | |
| 56 | |
| 57 | |
| 58 | |
| 59 | |
| 60 | |
| 61 | |
| 62 | |