Geant4 11.1.1
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4Ions Class Reference

#include <G4Ions.hh>

+ Inheritance diagram for G4Ions:

Public Types

enum class  G4FloatLevelBase {
  no_Float =0 , plus_X , plus_Y , plus_Z ,
  plus_U , plus_V , plus_W , plus_R ,
  plus_S , plus_T , plus_A , plus_B ,
  plus_C , plus_D , plus_E
}
 

Public Member Functions

 G4Ions (const G4String &aName, G4double mass, G4double width, G4double charge, G4int iSpin, G4int iParity, G4int iConjugation, G4int iIsospin, G4int iIsospin3, G4int gParity, const G4String &pType, G4int lepton, G4int baryon, G4int encoding, G4bool stable, G4double lifetime, G4DecayTable *decaytable, G4bool shortlived, const G4String &subType="", G4int anti_encoding=0, G4double excitation=0.0, G4int isomer=0)
 
virtual ~G4Ions ()
 
G4IonsIonsDefinition ()
 
G4IonsIons ()
 
G4double GetExcitationEnergy () const
 
G4int GetIsomerLevel () const
 
G4Ions::G4FloatLevelBase GetFloatLevelBase () const
 
G4int GetFloatLevelBaseIndex () const
 
void SetFloatLevelBase (G4Ions::G4FloatLevelBase flb)
 
void SetFloatLevelBase (char flbChar)
 
void SetFloatLevelBase (G4int flbIdx)
 
- Public Member Functions inherited from G4ParticleDefinition
 G4ParticleDefinition (const G4String &aName, G4double mass, G4double width, G4double charge, G4int iSpin, G4int iParity, G4int iConjugation, G4int iIsospin, G4int iIsospinZ, G4int gParity, const G4String &pType, G4int lepton, G4int baryon, G4int encoding, G4bool stable, G4double lifetime, G4DecayTable *decaytable, G4bool shortlived=false, const G4String &subType="", G4int anti_encoding=0, G4double magneticMoment=0.0)
 
virtual ~G4ParticleDefinition ()
 
 G4ParticleDefinition (const G4ParticleDefinition &)=delete
 
G4ParticleDefinitionoperator= (const G4ParticleDefinition &)=delete
 
G4bool operator== (const G4ParticleDefinition &right) const
 
G4bool operator!= (const G4ParticleDefinition &right) const
 
const G4StringGetParticleName () const
 
G4double GetPDGMass () const
 
G4double GetPDGWidth () const
 
G4double GetPDGCharge () const
 
G4double GetPDGSpin () const
 
G4int GetPDGiSpin () const
 
G4int GetPDGiParity () const
 
G4int GetPDGiConjugation () const
 
G4double GetPDGIsospin () const
 
G4double GetPDGIsospin3 () const
 
G4int GetPDGiIsospin () const
 
G4int GetPDGiIsospin3 () const
 
G4int GetPDGiGParity () const
 
G4double GetPDGMagneticMoment () const
 
void SetPDGMagneticMoment (G4double mageticMoment)
 
G4double CalculateAnomaly () const
 
const G4StringGetParticleType () const
 
const G4StringGetParticleSubType () const
 
G4int GetLeptonNumber () const
 
G4int GetBaryonNumber () const
 
G4int GetPDGEncoding () const
 
G4int GetAntiPDGEncoding () const
 
void SetAntiPDGEncoding (G4int aEncoding)
 
G4int GetQuarkContent (G4int flavor) const
 
G4int GetAntiQuarkContent (G4int flavor) const
 
G4bool IsShortLived () const
 
G4bool GetPDGStable () const
 
void SetPDGStable (const G4bool aFlag)
 
G4double GetPDGLifeTime () const
 
void SetPDGLifeTime (G4double aLifeTime)
 
G4double GetIonLifeTime () const
 
G4DecayTableGetDecayTable () const
 
void SetDecayTable (G4DecayTable *aDecayTable)
 
G4ProcessManagerGetProcessManager () const
 
void SetProcessManager (G4ProcessManager *aProcessManager)
 
G4VTrackingManagerGetTrackingManager () const
 
void SetTrackingManager (G4VTrackingManager *aTrackingManager)
 
G4ParticleTableGetParticleTable () const
 
G4int GetAtomicNumber () const
 
G4int GetAtomicMass () const
 
void DumpTable () const
 
void SetVerboseLevel (G4int value)
 
G4int GetVerboseLevel () const
 
void SetApplyCutsFlag (G4bool)
 
G4bool GetApplyCutsFlag () const
 
G4bool IsGeneralIon () const
 
G4bool IsMuonicAtom () const
 
G4ProcessManagerGetMasterProcessManager () const
 
void SetMasterProcessManager (G4ProcessManager *aNewPM)
 
G4int GetInstanceID () const
 
void SetParticleDefinitionID (G4int id=-1)
 
G4int GetParticleDefinitionID () const
 
G4bool IsHypernucleus () const
 
G4int GetNumberOfLambdasInHypernucleus () const
 
G4bool IsAntiHypernucleus () const
 
G4int GetNumberOfAntiLambdasInAntiHypernucleus () const
 

Static Public Member Functions

static G4Ions::G4FloatLevelBase FloatLevelBase (char flbChar)
 
static G4Ions::G4FloatLevelBase FloatLevelBase (G4int flbIdx)
 
static char FloatLevelBaseChar (G4Ions::G4FloatLevelBase flb)
 
- Static Public Member Functions inherited from G4ParticleDefinition
static const G4PDefManagerGetSubInstanceManager ()
 
static void Clean ()
 

Protected Member Functions

 G4Ions ()
 
- Protected Member Functions inherited from G4ParticleDefinition
 G4ParticleDefinition ()
 
G4int FillQuarkContents ()
 
void SetParticleSubType (const G4String &subtype)
 
void SetAtomicNumber (G4int)
 
void SetAtomicMass (G4int)
 

Additional Inherited Members

- Protected Types inherited from G4ParticleDefinition
enum  { NumberOfQuarkFlavor = 6 }
 
- Protected Attributes inherited from G4ParticleDefinition
G4int theQuarkContent [NumberOfQuarkFlavor]
 
G4int theAntiQuarkContent [NumberOfQuarkFlavor]
 
G4bool isGeneralIon = false
 
G4bool isMuonicAtom = false
 

Detailed Description

Definition at line 51 of file G4Ions.hh.

Member Enumeration Documentation

◆ G4FloatLevelBase

Constructor & Destructor Documentation

◆ G4Ions() [1/2]

G4Ions::G4Ions ( const G4String aName,
G4double  mass,
G4double  width,
G4double  charge,
G4int  iSpin,
G4int  iParity,
G4int  iConjugation,
G4int  iIsospin,
G4int  iIsospin3,
G4int  gParity,
const G4String pType,
G4int  lepton,
G4int  baryon,
G4int  encoding,
G4bool  stable,
G4double  lifetime,
G4DecayTable decaytable,
G4bool  shortlived,
const G4String subType = "",
G4int  anti_encoding = 0,
G4double  excitation = 0.0,
G4int  isomer = 0 
)

Definition at line 43 of file G4Ions.cc.

58 : G4ParticleDefinition( aName,mass,width,charge,iSpin,iParity,
59 iConjugation,iIsospin,iIsospin3,gParity,pType,
60 lepton,baryon,encoding,stable,lifetime,decaytable,
61 shortlived, subType, anti_encoding),
62 theExcitationEnergy(excitation),
63 theIsomerLevel(isomer),
64 floatLevelBase(G4FloatLevelBase::no_Float)
65{
66 if ((aName == "proton") || (aName == "neutron")) {
67 isGeneralIon = false ;
68 } else if ( (aName == "GenericIon") || (aName == "alpha")
69 || (aName == "He3") || (aName == "deuteron")|| (aName == "triton")) {
70 isGeneralIon = false ;
71 } else if ( (aName == "anti_He3") || (aName == "anti_deuteron")
72 || (aName == "anti_triton") || (aName == "anti_alpha") ) {
73 isGeneralIon = false ;
74 } else if ( (aName == "iron") || (aName == "oxygen") || (aName == "nitrogen")
75 || (aName == "carbon") || (aName == "helium") || (aName == "alpha+")
76 || (aName == "hydrogen") || (aName == "Ps-1s") || (aName == "Ps-2s")) {
77 isGeneralIon = false ;
78 } else if ( aName == "hypertriton" || aName == "anti_hypertriton" ||
79 aName == "hyperalpha" || aName == "anti_hyperalpha" ||
80 aName == "hyperH4" || aName == "anti_hyperH4" ||
81 aName == "doublehyperH4" || aName == "anti_doublehyperH4" ||
82 aName == "doublehyperdoubleneutron" || aName == "anti_doublehyperdoubleneutron" ||
83 aName == "hyperHe5" || aName == "anti_hyperHe5" ) {
84 isGeneralIon = false;
85 } else {
86 isGeneralIon = true;
87 }
88
89 // isomer level isset to 9
90 // if isomer level is set to 0 for excited state
91 //
92 if ((theExcitationEnergy > 0.0) && (isomer==0)) isomer =9;
93
94 if (GetAtomicNumber() == 0 )
95 {
96 // AtomicNumber/Mass is positive even for anti_nulceus
97 SetAtomicNumber( std::abs(G4int(GetPDGCharge()/eplus)) );
98 SetAtomicMass( std::abs(GetBaryonNumber()) );
99 }
100}
int G4int
Definition: G4Types.hh:85
G4int GetAtomicNumber() const
G4double GetPDGCharge() const
void SetAtomicMass(G4int)
void SetAtomicNumber(G4int)

◆ ~G4Ions()

G4Ions::~G4Ions ( )
virtual

Definition at line 106 of file G4Ions.cc.

107{
108}

◆ G4Ions() [2/2]

Member Function Documentation

◆ FloatLevelBase() [1/2]

G4Ions::G4FloatLevelBase G4Ions::FloatLevelBase ( char  flbChar)
static

Definition at line 110 of file G4Ions.cc.

111{
113 switch(flbChar)
114 {
115 case 'x': case 'X':
116 flb = plusX;
117 break;
118 case 'y': case 'Y':
119 flb = plusY;
120 break;
121 case 'z': case 'Z':
122 flb = plusZ;
123 break;
124 case 'u': case 'U':
125 flb = plusU;
126 break;
127 case 'v': case 'V':
128 flb = plusV;
129 break;
130 case 'w': case 'W':
131 flb = plusW;
132 break;
133 case 'r': case 'R':
134 flb = plusR;
135 break;
136 case 's': case 'S':
137 flb = plusS;
138 break;
139 case 't': case 'T':
140 flb = plusT;
141 break;
142 case 'a': case 'A':
143 flb = plusA;
144 break;
145 case 'b': case 'B':
146 flb = plusB;
147 break;
148 case 'c': case 'C':
149 flb = plusC;
150 break;
151 case 'd': case 'D':
152 flb = plusD;
153 break;
154 case 'e': case 'E':
155 flb = plusE;
156 break;
157 case '\0': default:
158 break;
159 }
160 return flb;
161}
#define plusA
Definition: G4Ions.hh:122
#define plusT
Definition: G4Ions.hh:121
#define plusR
Definition: G4Ions.hh:119
#define plusV
Definition: G4Ions.hh:114
#define plusW
Definition: G4Ions.hh:115
#define plusD
Definition: G4Ions.hh:125
#define plusU
Definition: G4Ions.hh:113
#define plusS
Definition: G4Ions.hh:120
#define plusY
Definition: G4Ions.hh:117
#define plusX
Definition: G4Ions.hh:116
#define plusZ
Definition: G4Ions.hh:118
#define plusB
Definition: G4Ions.hh:123
#define plusC
Definition: G4Ions.hh:124
#define plusE
Definition: G4Ions.hh:126
#define noFloat
Definition: G4Ions.hh:112
G4FloatLevelBase
Definition: G4Ions.hh:83

Referenced by G4ExcitationHandler::BreakItUp(), G4ITDecay::DecayIt(), G4IonTable::FindIon(), G4IonTable::GetIon(), G4IonTable::GetLifeTime(), G4RadioactiveDecay::LoadDecayTable(), SetFloatLevelBase(), and G4IsotopeProperty::SetFloatLevelBase().

◆ FloatLevelBase() [2/2]

G4Ions::G4FloatLevelBase G4Ions::FloatLevelBase ( G4int  flbIdx)
static

Definition at line 163 of file G4Ions.cc.

164{
165 static G4Ions::G4FloatLevelBase flb[] =
166 { noFloat,
169 return flb[flbIdx];
170}

◆ FloatLevelBaseChar()

char G4Ions::FloatLevelBaseChar ( G4Ions::G4FloatLevelBase  flb)
static

Definition at line 172 of file G4Ions.cc.

173{
174 static char flbChar[] = {'\0','X','Y','Z','U','V','W',
175 'R','S','T','A','B','C','D','E'};
176 return flbChar[static_cast<G4int>(flb)];
177}

Referenced by G4IonTable::CreateIon(), G4IsotopeProperty::DumpInfo(), and G4IonTable::GetIonName().

◆ GetExcitationEnergy()

G4double G4Ions::GetExcitationEnergy ( ) const
inline

Definition at line 145 of file G4Ions.hh.

146{
147 return theExcitationEnergy;
148}

◆ GetFloatLevelBase()

G4Ions::G4FloatLevelBase G4Ions::GetFloatLevelBase ( ) const
inline

Definition at line 157 of file G4Ions.hh.

158{
159 return floatLevelBase;
160}

◆ GetFloatLevelBaseIndex()

G4int G4Ions::GetFloatLevelBaseIndex ( ) const
inline

Definition at line 163 of file G4Ions.hh.

164{
165 return static_cast<G4int>(floatLevelBase);
166}

◆ GetIsomerLevel()

G4int G4Ions::GetIsomerLevel ( ) const
inline

Definition at line 151 of file G4Ions.hh.

152{
153 return theIsomerLevel;
154}

◆ Ions()

G4Ions * G4Ions::Ions ( )
inline

Definition at line 139 of file G4Ions.hh.

140{
141 return this;
142}

◆ IonsDefinition()

G4Ions * G4Ions::IonsDefinition ( )
inline

Definition at line 133 of file G4Ions.hh.

134{
135 return this;
136}

◆ SetFloatLevelBase() [1/3]

void G4Ions::SetFloatLevelBase ( char  flbChar)
inline

Definition at line 175 of file G4Ions.hh.

176{
177 floatLevelBase = FloatLevelBase(flbChar);
178}
static G4Ions::G4FloatLevelBase FloatLevelBase(char flbChar)
Definition: G4Ions.cc:110

◆ SetFloatLevelBase() [2/3]

void G4Ions::SetFloatLevelBase ( G4int  flbIdx)
inline

Definition at line 181 of file G4Ions.hh.

182{
183 floatLevelBase = FloatLevelBase(flbIdx);
184}

◆ SetFloatLevelBase() [3/3]

void G4Ions::SetFloatLevelBase ( G4Ions::G4FloatLevelBase  flb)
inline

Definition at line 169 of file G4Ions.hh.

170{
171 floatLevelBase = flb;
172}

Referenced by G4MuonicAtom::G4MuonicAtom().


The documentation for this class was generated from the following files: