Logo ROOT   6.16/01
Reference Guide
TAttParticle.h
Go to the documentation of this file.
1// @(#)root/eg:$Id$
2// Author: Ola Nordmann 29/09/95
3
4/*************************************************************************
5 * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
6 * All rights reserved. *
7 * *
8 * For the licensing terms see $ROOTSYS/LICENSE. *
9 * For the list of contributors see $ROOTSYS/README/CREDITS. *
10 *************************************************************************/
11
12
13//////////////////////////////////////////////////////////////////////////
14// //
15// TAttParticle //
16// //
17// Particle definition, based on GEANT3 particle definition //
18// //
19// //
20//////////////////////////////////////////////////////////////////////////
21
22#ifndef ROOT_TAttParticle
23#define ROOT_TAttParticle
24
25#include "TNamed.h"
26#include "TAttLine.h"
27
28class THashList;
29
30class TAttParticle : public TNamed {
31private:
32 Double_t fPDGMass; //Mass of the particle in GeV/c2
33 Bool_t fPDGStable; //Logical indicator, if TRUE the particle can not decay
34 Double_t fPDGDecayWidth; //Life time of the particle in sec.
35 Double_t fPDGCharge; //Charge of the particle in units of e
36 TString fParticleType; //Text indicator for the particle family
37 Int_t fMCnumberOfPDG; //PDG MC number followed by
38 //http://pdg.lbl.gov/rpp/mcdata/all.mc
39 Double_t fEnergyCut; //Lower energy cut off, the default is 10 keV
40 Double_t fEnergyLimit; //High energy cut off, the default is 10 TeV
41 Double_t fGranularity; //Granularity of the fLogEScale
42
43public:
45 TAttParticle(const char *name, const char *title,
46 Double_t Mass, Bool_t Stable,
47 Double_t DecayWidth, Double_t Charge, const char *Type,
48 Int_t MCnumber, Int_t granularity=90,
49 Double_t LowerCutOff=1.e-5, Double_t HighCutOff=1.e4);
50 virtual ~TAttParticle();
52 static Int_t ConvertISAtoPDG(Int_t isaNumber);
53 static void DefinePDG();
54 virtual Double_t GetCharge() const { return fPDGCharge; }
55 virtual Double_t GetEnergyCut() const { return fEnergyCut; }
56 virtual Double_t GetEnergyLimit() const { return fEnergyLimit; }
57 virtual Double_t GetGranularity() const { return fGranularity; }
58 virtual Double_t GetDecayWidth() const { return fPDGDecayWidth; }
59 virtual Double_t GetMass() const { return fPDGMass; }
60 virtual Int_t GetMCNumber() const { return fMCnumberOfPDG; }
61 static TAttParticle *GetParticle(const char *name);
62 static TAttParticle *GetParticle(Int_t mcnumber);
63 virtual const char *GetParticleType() const { return fParticleType.Data(); }
64 virtual Bool_t GetStable() const { return fPDGStable; }
65 virtual void Print(Option_t *option="") const ;
66 virtual Double_t SampleMass() const ;
67 virtual Double_t SampleMass(Double_t widthcut) const ;
68
69 ClassDef(TAttParticle,1) //Particle definition
70};
71
72#endif
int Int_t
Definition: RtypesCore.h:41
bool Bool_t
Definition: RtypesCore.h:59
double Double_t
Definition: RtypesCore.h:55
const char Option_t
Definition: RtypesCore.h:62
#define ClassDef(name, id)
Definition: Rtypes.h:324
Particle definition, partly based on GEANT3 particle definition.
Definition: TAttParticle.h:30
static TAttParticle * GetParticle(const char *name)
Get a pointer to the particle object according to the name given.
virtual Double_t GetMass() const
Definition: TAttParticle.h:59
virtual Int_t GetMCNumber() const
Definition: TAttParticle.h:60
virtual Bool_t GetStable() const
Definition: TAttParticle.h:64
TAttParticle()
Particle definition default constructor.
Double_t fEnergyCut
Definition: TAttParticle.h:39
virtual Double_t GetEnergyLimit() const
Definition: TAttParticle.h:56
virtual Double_t GetCharge() const
Definition: TAttParticle.h:54
static Int_t ConvertISAtoPDG(Int_t isaNumber)
Converts the ISAJET Particle number into the PDG MC number.
Double_t fPDGMass
Definition: TAttParticle.h:32
virtual Double_t SampleMass() const
Samples a mass according to the Breit-Wigner resonance distribution.
static void DefinePDG()
Defines particles according to the Particle Data Group.
virtual const char * GetParticleType() const
Definition: TAttParticle.h:63
Double_t fPDGDecayWidth
Definition: TAttParticle.h:34
virtual Double_t GetGranularity() const
Definition: TAttParticle.h:57
static THashList * fgList
Definition: TAttParticle.h:51
virtual ~TAttParticle()
Particle destructor.
virtual void Print(Option_t *option="") const
Print the entire information of this kind of particle.
Double_t fPDGCharge
Definition: TAttParticle.h:35
Bool_t fPDGStable
Definition: TAttParticle.h:33
Int_t fMCnumberOfPDG
Definition: TAttParticle.h:37
TString fParticleType
Definition: TAttParticle.h:36
virtual Double_t GetEnergyCut() const
Definition: TAttParticle.h:55
Double_t fEnergyLimit
Definition: TAttParticle.h:40
Double_t fGranularity
Definition: TAttParticle.h:41
virtual Double_t GetDecayWidth() const
Definition: TAttParticle.h:58
THashList implements a hybrid collection class consisting of a hash table and a list to store TObject...
Definition: THashList.h:34
The TNamed class is the base class for all named ROOT classes.
Definition: TNamed.h:29
Basic string class.
Definition: TString.h:131
const char * Data() const
Definition: TString.h:364
Type
enumeration specifying the integration types.