]>
Commit | Line | Data |
---|---|---|
06351446 | 1 | // |
e2bafbbc | 2 | // Class AliRsnPairDef |
3 | // | |
4 | // Defines a decay channel for a resonance, | |
5 | // resulting in a specified PDG code for the mother, | |
6 | // and the particle type for the daughters, defined | |
7 | // according to the internal PID format of the package | |
8 | // | |
9 | // author: A. Pulvirenti (alberto.pulvirenti@ct.infn.it) | |
10 | // | |
06351446 | 11 | |
12 | #ifndef ALIRSNPAIRDEF_H | |
13 | #define ALIRSNPAIRDEF_H | |
14 | ||
5eb970a4 | 15 | #include "AliPID.h" |
2dab9030 | 16 | #include "AliRsnDaughter.h" |
06351446 | 17 | |
e2bafbbc | 18 | class AliRsnDaughter; |
19 | ||
06351446 | 20 | class AliRsnPairDef : public TObject |
21 | { | |
aec0ec32 | 22 | public: |
06351446 | 23 | |
24 | AliRsnPairDef(); | |
2dab9030 | 25 | AliRsnPairDef(AliPID::EParticleType type1, Char_t sign1, AliPID::EParticleType type2, Char_t sign2, Int_t motherPDG = 0, Double_t motherMass = 0.0); |
06351446 | 26 | AliRsnPairDef(const AliRsnPairDef ©); |
aec0ec32 | 27 | const AliRsnPairDef& operator= (const AliRsnPairDef ©); |
06351446 | 28 | virtual ~AliRsnPairDef() { } |
29 | ||
30 | // getters | |
2dab9030 | 31 | Int_t GetMotherPDG() const {return fMotherPDG;} |
32 | Double_t GetMotherMass() const {return fMotherMass;} | |
33 | Double_t GetMass(Int_t i) const {if (i>=0&&i<2) return fMass[i]; else return 0.0;} | |
34 | Char_t GetCharge(Int_t i) const {if (i>=0&&i<2) return fCharge[i]; else return 0;} | |
35 | Short_t GetChargeShort(Int_t i) const {if (GetCharge(i) == '+') return 1; else if (GetCharge(i) == '-') return -1; else return 0;} | |
36 | AliPID::EParticleType GetPID(Int_t i) const {if (i>=0&&i<2) return fPID[i]; else return AliPID::kUnknown;} | |
37 | AliRsnDaughter::ERefType GetDaughterType(Int_t i) {if (i>=0&&i<2) return fDaughterType[i]; else return AliRsnDaughter::kNoType;} | |
38 | const char* GetPairName() const; | |
06351446 | 39 | |
40 | // setters | |
06351446 | 41 | void SetMotherPDG(Int_t pdg) {fMotherPDG = pdg;} |
2dab9030 | 42 | void SetMotherMass(Double_t mass) {fMotherMass = mass;} |
43 | Bool_t SetDaughter(Int_t i, AliPID::EParticleType pid, Char_t charge = 0); | |
44 | Bool_t SetDaughters(AliPID::EParticleType type1, Char_t sign1, AliPID::EParticleType type2, Char_t sign2); | |
06351446 | 45 | |
46 | // pair information methods | |
4fbb2459 | 47 | Bool_t IsLikeSign() const {return (fCharge[0] == fCharge[1]);} |
2dab9030 | 48 | Bool_t HasEqualPID() const {return (fPID[0] == fPID[1]);} |
06351446 | 49 | |
aec0ec32 | 50 | private: |
06351446 | 51 | |
52 | // pair parameters | |
2dab9030 | 53 | Double_t fMotherMass; // nominal mass of true mother |
54 | Int_t fMotherPDG; // PDG code of true mother (if known) | |
55 | ||
56 | Double_t fMass[2]; // mass of particles | |
57 | Char_t fCharge[2]; // charge of particles | |
58 | AliPID::EParticleType fPID[2]; // PID of particles | |
59 | AliRsnDaughter::ERefType fDaughterType[2]; // object type (track/V0) | |
06351446 | 60 | |
06351446 | 61 | // ROOT dictionary |
62 | ClassDef(AliRsnPairDef, 1) | |
63 | }; | |
64 | ||
65 | #endif |