ATTPCROOT  0.3.0-alpha
A ROOT-based framework for analyzing data from active target detectors
AtTPC20MgDecay.h
Go to the documentation of this file.
1 
2 #ifndef AtTPC20MGDECAY_H
3 #define AtTPC20MGDECAY_H
4 
5 #include <Rtypes.h> // for Double32_t, Bool_t, THashConsistencyHolder
6 
7 #include "FairGenerator.h"
8 
9 class TBuffer;
10 class TClass;
11 class TMemberInspector;
12 class FairPrimaryGenerator;
13 
14 class AtTPC20MgDecay : public FairGenerator {
15 private:
16  Bool_t fOnlyAPBranch{false}; // True if only the beta-alpha-proton branch is visible
17  Bool_t fBoxVtxIsSet{false}; // True if box vertex is set
18 
19  Double32_t fX{0}, fY{0}, fZ{0}; // Point vertex coordinates [cm]
20  Double32_t fX1{0}, fY1{0}, fZ1{0}, fX2{0}, fY2{0}, fZ2{0}; // Box vertex coords (x1,y1,z1)->(x2,y2,z2)
21  Bool_t fNuclearDecayChainIsSet{false};
22  Int_t fParticlesDefinedInNuclearDecay{0};
23  Double32_t fParticleEnergies[50];
24  Double32_t fParticleBranchingRatios[50];
25 
26 public:
28  AtTPC20MgDecay() = default;
29 
31  virtual ~AtTPC20MgDecay() = default;
32 
34  virtual Bool_t Init();
35 
36  void SetXYZ(Double32_t x = 0, Double32_t y = 0, Double32_t z = 0)
37  {
38  fX = x;
39  fY = y;
40  fZ = z;
41  }
42 
43  void SetBoxXYZ(Double32_t x1 = 0, Double32_t y1 = 0, Double32_t z1 = 0, Double32_t x2 = 0, Double32_t y2 = 0,
44  Double32_t z2 = 0)
45  {
46  fX1 = x1;
47  fY1 = y1;
48  fZ1 = z1;
49  fX2 = x2;
50  fY2 = y2;
51  fZ2 = z2;
52  fBoxVtxIsSet = kTRUE;
53  }
54 
55  virtual Bool_t ReadEvent(FairPrimaryGenerator *primGen);
56 
57  void ShowOnlyAlphaProtonBranch() { fOnlyAPBranch = kTRUE; };
58  void SetNuclearDecayChain() { fNuclearDecayChainIsSet = kTRUE; };
59  void SetDecayChainPoint(Double32_t ParticleEnergy = 0, Double32_t ParticleBranchingRatio = 0);
60 
61  ClassDef(AtTPC20MgDecay, 1)
62 };
63 
64 #endif
AtTPC20MgDecay::ReadEvent
virtual Bool_t ReadEvent(FairPrimaryGenerator *primGen)
Definition: AtTPC20MgDecay-Rnalpha.cxx:35
AtTPC20MgDecay::SetBoxXYZ
void SetBoxXYZ(Double32_t x1=0, Double32_t y1=0, Double32_t z1=0, Double32_t x2=0, Double32_t y2=0, Double32_t z2=0)
Definition: AtTPC20MgDecay.h:43
AtTPC20MgDecay::SetNuclearDecayChain
void SetNuclearDecayChain()
Definition: AtTPC20MgDecay.h:58
AtTPC20MgDecay::AtTPC20MgDecay
AtTPC20MgDecay()=default
Definition: AtTPC20MgDecay-Rnalpha.cxx:20
AtTPC20MgDecay::Init
virtual Bool_t Init()
Definition: AtTPC20MgDecay-Rnalpha.cxx:29
y
const double * y
Definition: lmcurve.cxx:20
AtTPC20MgDecay::SetXYZ
void SetXYZ(Double32_t x=0, Double32_t y=0, Double32_t z=0)
Definition: AtTPC20MgDecay.h:36
AtTPC20MgDecay::SetDecayChainPoint
void SetDecayChainPoint(Double32_t ParticleEnergy=0, Double32_t ParticleBranchingRatio=0)
Definition: AtTPC20MgDecay-Rnalpha.cxx:152
AtTPC20MgDecay::~AtTPC20MgDecay
virtual ~AtTPC20MgDecay()=default
Definition: AtTPC20MgDecay-Rnalpha.cxx:27
AtTPC20MgDecay
Definition: AtTPC20MgDecay.h:14
AtTPC20MgDecay::ShowOnlyAlphaProtonBranch
void ShowOnlyAlphaProtonBranch()
Definition: AtTPC20MgDecay.h:57