|
BDSIM
BDSIM is a Geant4 extension toolkit for simulation of particle transport in accelerator beamlines.
|
A class that holds the current integrated quantities along a beam line. More...
#include <BDSBeamlineIntegral.hh>

Public Member Functions | |
| BDSBeamlineIntegral (const BDSParticleDefinition &incomingParticle, G4double T0In=0, G4double integratedArcLength=0, G4bool integrateKineticEnergyIn=true) | |
| void | Integrate (const GMAD::Element &componentAsDefined) |
| G4double | ProvideSynchronousTAtCentreOfNextElement (const GMAD::Element *el) const |
| G4double | ProvideSynchronousTAtEndOfNextElement (const GMAD::Element *el) const |
| G4double | MomentumAtStartOfLastElement () const |
| G4double | KineticEnergyAtStartOfLastElement () const |
Data Fields | |
| G4bool | integrateKineticEnergy |
| On by default, but allow control to not integrate it for old behaviour. | |
| G4double | synchronousTAtEnd |
| G4double | synchronousTAtMiddleOfLastElement |
| G4double | arcLength |
| BDSParticleDefinition | designParticle |
| G4bool | changeOfEnergyEncountered |
| G4int | rigidityCount |
| Which change in rigidity we're at. Starts at 0, +1 after each change. Used for naming. | |
A class that holds the current integrated quantities along a beam line.
Used to hold accumulated quantities like the current total arc length, synchronous global time and current particle rigidity / momentum along the beam line.
Definition at line 40 of file BDSBeamlineIntegral.hh.
|
explicit |
Definition at line 39 of file BDSBeamlineIntegral.cc.
| BDSBeamlineIntegral::~BDSBeamlineIntegral | ( | ) |
Definition at line 52 of file BDSBeamlineIntegral.cc.
| void BDSBeamlineIntegral::Integrate | ( | const GMAD::Element & | componentAsDefined | ) |
Increment all quantities in this class by adding this element onto the beam line.
Definition at line 55 of file BDSBeamlineIntegral.cc.
References BDSParticleDefinition::ApplyChangeInKineticEnergy(), BDSParticleDefinition::Beta(), BDSParticleDefinition::BRho(), BDSComponentFactory::CalculateAngleAndFieldRBend(), GMAD::Element::cavityFieldType, BDSParticleDefinition::Charge(), BDS::DetermineCavityFieldType(), BDSComponentFactory::EFieldFromElement(), GMAD::Element::frequency, BDSGlobalConstants::Instance(), integrateKineticEnergy, BDS::IsFinite(), GMAD::Element::l, GMAD::Element::phase, rigidityCount, BDSFieldEMRFCavity::TransitTimeFactor(), GMAD::Element::type, BDSTypeSafeEnum< def, inner >::underlying(), and BDSParticleDefinition::Velocity().
Referenced by BDSComponentFactory::CreateComponent(), ProvideSynchronousTAtCentreOfNextElement(), and ProvideSynchronousTAtEndOfNextElement().


|
inline |
Definition at line 65 of file BDSBeamlineIntegral.hh.
|
inline |
Definition at line 64 of file BDSBeamlineIntegral.hh.
| G4double BDSBeamlineIntegral::ProvideSynchronousTAtCentreOfNextElement | ( | const GMAD::Element * | el | ) | const |
Provide the next synchronous T at the centre if we were to add on this new element to the beam line (i.e. integrate it). Doesn't change the current contents though. Constructs a copy of this instance, does the calculation, then does away with the copy.
Definition at line 136 of file BDSBeamlineIntegral.cc.
References Integrate().
Referenced by BDSComponentFactory::CreateComponent().


| G4double BDSBeamlineIntegral::ProvideSynchronousTAtEndOfNextElement | ( | const GMAD::Element * | el | ) | const |
Provide the next synchronous T at the middle if we were to add on this new element. Similar to above function.
Definition at line 144 of file BDSBeamlineIntegral.cc.
References Integrate().

| G4double BDSBeamlineIntegral::arcLength |
Definition at line 70 of file BDSBeamlineIntegral.hh.
| G4bool BDSBeamlineIntegral::changeOfEnergyEncountered |
Definition at line 72 of file BDSBeamlineIntegral.hh.
| BDSParticleDefinition BDSBeamlineIntegral::designParticle |
Definition at line 71 of file BDSBeamlineIntegral.hh.
| G4bool BDSBeamlineIntegral::integrateKineticEnergy |
On by default, but allow control to not integrate it for old behaviour.
Definition at line 67 of file BDSBeamlineIntegral.hh.
Referenced by BDSDetectorConstruction::BuildBeamline(), and Integrate().
| G4int BDSBeamlineIntegral::rigidityCount |
Which change in rigidity we're at. Starts at 0, +1 after each change. Used for naming.
Definition at line 73 of file BDSBeamlineIntegral.hh.
Referenced by BDSComponentFactory::CreateComponent(), and Integrate().
| G4double BDSBeamlineIntegral::synchronousTAtEnd |
Definition at line 68 of file BDSBeamlineIntegral.hh.
| G4double BDSBeamlineIntegral::synchronousTAtMiddleOfLastElement |
Definition at line 69 of file BDSBeamlineIntegral.hh.