OPAL (Object Oriented Parallel Accelerator Library)
2021.1.99
OPAL
|
#include <BeamStrippingPhysics.h>
Public Member Functions | |
BeamStrippingPhysics (const std::string &name, ElementBase *element) | |
~BeamStrippingPhysics () | |
void | setCyclotron (Cyclotron *cycl) |
virtual void | apply (PartBunchBase< double, 3 > *bunch, const std::pair< Vector_t, double > &boundingSphere) |
virtual const std::string | getType () const |
virtual void | print (Inform &msg) |
virtual bool | stillActive () |
virtual double | getTime () |
virtual std::string | getName () |
virtual size_t | getParticlesInMat () |
virtual unsigned | getRediffused () |
virtual unsigned int | getNumEntered () |
void | doPhysics (PartBunchBase< double, 3 > *bunch) |
Public Member Functions inherited from ParticleMatterInteractionHandler | |
ParticleMatterInteractionHandler (std::string name, ElementBase *elref) | |
virtual | ~ParticleMatterInteractionHandler () |
void | setFlagAllParticlesIn (bool p) |
bool | getFlagAllParticlesIn () const |
void | updateElement (ElementBase *newref) |
ElementBase * | getElement () |
Private Member Functions | |
void | computeCrossSection (PartBunchBase< double, 3 > *bunch, size_t &i, double energy) |
double | computeCrossSectionNakai (double energy, double energyThreshold, int &i) |
double | computeCrossSectionTabata (double energy, double energyThreshold, double a1, double a2, double a3, double a4, double a5, double a6) |
double | computeCrossSectionChebyshev (double energy, double energyMin, double energyMax) |
double | computeCrossSectionBohr (double energy, int zTarget, double massInAmu) |
bool | evalGasStripping (double &deltas) |
bool | evalLorentzStripping (double &gamma, double &eField) |
void | getSecondaryParticles (PartBunchBase< double, 3 > *bunch, size_t &i, bool pdead_LS) |
void | transformToProton (PartBunchBase< double, 3 > *bunch, size_t &i) |
void | transformToHydrogen (PartBunchBase< double, 3 > *bunch, size_t &i) |
void | transformToHminus (PartBunchBase< double, 3 > *bunch, size_t &i) |
void | transformToH3plus (PartBunchBase< double, 3 > *bunch, size_t &i) |
bool | computeEnergyLoss (PartBunchBase< double, 3 > *, Vector_t &, const double, bool) const |
Private Attributes | |
Cyclotron * | cycl_m |
Vacuum * | vac_m |
gsl_rng * | r_m |
double | T_m |
double | dT_m |
double | mass_m |
double | charge_m |
double | pressure_m |
std::unique_ptr< LossDataSink > | lossDs_m |
double | nCSA |
macroscopic cross sections More... | |
double | nCSB |
double | nCSC |
double | nCSTotal |
unsigned | bunchToMatStat_m |
unsigned | stoppedPartStat_m |
unsigned | rediffusedStat_m |
size_t | totalPartsInMat_m |
Static Private Attributes | |
static const double | csCoefSingle_Hminus [3][9] |
static const double | csCoefDouble_Hminus [3][9] |
static const double | csCoefSingle_Hplus [3][9] |
static const double | csCoefDouble_Hplus [3][9] |
static const double | csCoefSingleLoss_H [3][9] |
static const double | csCoefSingleCapt_H [3][9] |
static const double | csCoefSingle_Hplus_Tabata [10] |
static const double | csCoefHminusProduction_H_Tabata [13] |
static const double | csCoefProtonProduction_H_Tabata [9] |
static const double | csCoefProtonProduction_H2plus_Tabata [11] |
static const double | csCoefH3plusProduction_H2plus_Tabata [7] |
static const double | csCoefSingle_Hminus_Chebyshev [11] |
static const double | csCoefDouble_Hminus_Chebyshev [11] |
static const double | csCoefSingle_Hplus_Chebyshev [11] |
static const double | csCoefDouble_Hplus_Chebyshev [11] |
static const double | csCoefHydrogenProduction_H2plus_Chebyshev [11] |
static const double | csCoefProtonProduction_H2plus_Chebyshev [11] |
static const double | energyRangeH2plusinH2 [2] = {111.4, 7.8462E+04} |
static double | a_m [9] = {} |
static double | b_m [3][9] = {} |
Additional Inherited Members | |
Protected Attributes inherited from ParticleMatterInteractionHandler | |
ElementBase * | element_ref_m |
bool | allParticleInMat_m |
if all particles are in matter stay inside the particle matter interaction More... | |
const std::string | name_m |
Definition at line 42 of file BeamStrippingPhysics.h.
BeamStrippingPhysics::BeamStrippingPhysics | ( | const std::string & | name, |
ElementBase * | element | ||
) |
Definition at line 65 of file BeamStrippingPhysics.cpp.
References Options::asciidump, ParticleMatterInteractionHandler::getElement(), getName(), lossDs_m, r_m, Attrib::Legacy::Distribution::T, and vac_m.
BeamStrippingPhysics::~BeamStrippingPhysics | ( | ) |
Definition at line 96 of file BeamStrippingPhysics.cpp.
|
virtual |
Implements ParticleMatterInteractionHandler.
Definition at line 102 of file BeamStrippingPhysics.cpp.
References DEUTERON, doPhysics(), dT_m, PartBunchBase< T, Dim >::get_sPos(), PartBunchBase< T, Dim >::getdT(), PartBunchBase< T, Dim >::getPType(), PartBunchBase< T, Dim >::getPTypeString(), H2P, HMINUS, HYDROGEN, and PROTON.
|
private |
Definition at line 190 of file BeamStrippingPhysics.cpp.
References a_m, AIR, Physics::amu, b_m, computeCrossSectionBohr(), computeCrossSectionChebyshev(), computeCrossSectionNakai(), computeCrossSectionTabata(), csCoefDouble_Hminus, csCoefDouble_Hminus_Chebyshev, csCoefDouble_Hplus, csCoefDouble_Hplus_Chebyshev, csCoefH3plusProduction_H2plus_Tabata, csCoefHminusProduction_H_Tabata, csCoefHydrogenProduction_H2plus_Chebyshev, csCoefProtonProduction_H2plus_Chebyshev, csCoefProtonProduction_H2plus_Tabata, csCoefProtonProduction_H_Tabata, csCoefSingle_Hminus, csCoefSingle_Hminus_Chebyshev, csCoefSingle_Hplus, csCoefSingle_Hplus_Chebyshev, csCoefSingle_Hplus_Tabata, csCoefSingleCapt_H, csCoefSingleLoss_H, DEUTERON, energyRangeH2plusinH2, Vacuum::getResidualGas(), Vacuum::getTemperature(), H2, H2P, HMINUS, HYDROGEN, Physics::kB, Physics::m_h2p, Physics::m_hm, Physics::m_p, nCSA, nCSB, nCSC, nCSTotal, pressure_m, PROTON, PartBunchBase< T, Dim >::PType, Physics::q_e, and vac_m.
Referenced by doPhysics().
|
private |
Analytical expressions for electron loss by light and heavy ions passing through gases based on Bohr theory. H.-D.Betz, "Charge states and charge-changing cross sections of fast heavy ions penetrating through gaseous and solid media", Rev. Mod. Phys. 44, 465 (1972).
Definition at line 532 of file BeamStrippingPhysics.cpp.
References Physics::a0, Physics::c, Physics::h_bar, Physics::m_e, mass_m, Physics::pi, pow(), and sqrt().
Referenced by computeCrossSection().
|
private |
Analytical expression for cross section for inelastic collisions between hydrogen atoms, molecules and ions from Chebyshev fitting parameters. C.F.Barnett, "Atomic data for fusion. Volume 1: Collisions of H, H2, He and Li atoms and ions with atoms and molecules", ORNL-6068/V1 (1990).
Definition at line 507 of file BeamStrippingPhysics.cpp.
References a_m, exp(), and log().
Referenced by computeCrossSection().
|
private |
Analytical expression for charge-transfer cross section between hydrogen ions and atoms with gaseous atoms and molecules based on semiempirically functional forms. Y.Nakai et.al, "Cross sections for charge transfer of hydrogen atoms and ions colliding with gaseous atoms and molecules", At. Data Nucl. Data Tables 37, 69 (1987).
Definition at line 456 of file BeamStrippingPhysics.cpp.
References b_m, Physics::E_ryd, Physics::m_e, Physics::m_h, and pow().
Referenced by computeCrossSection().
|
private |
Analytical expression for cross section of collision processes between hydrogen ions, atoms, and molecules with hydrogen molecules based on semiempirically functional forms. T.Tabata and T.Shirai, "Analytic cross sections for collisions of H+, H2+, H3+, H, H2 and H− with hydrogen molecules", At. Data Nucl. Data Tables 76, 1 (2000).
Definition at line 483 of file BeamStrippingPhysics.cpp.
References Physics::E_ryd, and pow().
Referenced by computeCrossSection().
|
inlineprivatevirtual |
Implements ParticleMatterInteractionHandler.
Definition at line 89 of file BeamStrippingPhysics.h.
|
inline |
Definition at line 127 of file BeamStrippingPhysics.cpp.
References Cyclotron::apply(), PartBunchBase< T, Dim >::Bin, Physics::c, charge_m, computeCrossSection(), cycl_m, dot(), dT_m, ParticleMatterInteractionHandler::element_ref_m, endl(), evalGasStripping(), evalLorentzStripping(), PartBunchBase< T, Dim >::getLocalNum(), getName(), getSecondaryParticles(), Vacuum::getStop(), PartBunchBase< T, Dim >::getT(), PartBunchBase< T, Dim >::getTotalNum(), HMINUS, PartBunchBase< T, Dim >::ID, INFORM_ALL_NODES, level4(), lossDs_m, PartBunchBase< T, Dim >::M, mass_m, PartBunchBase< T, Dim >::P, pressure_m, PartBunchBase< T, Dim >::PType, PartBunchBase< T, Dim >::Q, PartBunchBase< T, Dim >::R, sqrt(), stoppedPartStat_m, T_m, and vac_m.
Referenced by apply().
|
private |
Definition at line 552 of file BeamStrippingPhysics.cpp.
References exp(), nCSTotal, and r_m.
Referenced by doPhysics().
|
private |
Expression for H- lifetime based on the calculation of the electric dissociation rate from the formal theory of decay. L.R.Scherk, "A improved value for the electron affinity of the negative hydrogen ion", Can. J. Phys. 57, 558 (1979).
Definition at line 565 of file BeamStrippingPhysics.cpp.
References a, Physics::a0, Physics::c, dT_m, exp(), Physics::h_bar, Physics::m_e, Hypervolume::n, Physics::q_e, r_m, and sqrt().
Referenced by doPhysics().
|
inlinevirtual |
Implements ParticleMatterInteractionHandler.
Definition at line 150 of file BeamStrippingPhysics.h.
References ParticleMatterInteractionHandler::element_ref_m, ElementBase::getName(), and ParticleMatterInteractionHandler::name_m.
Referenced by BeamStrippingPhysics(), doPhysics(), transformToH3plus(), transformToHminus(), transformToHydrogen(), and transformToProton().
|
inlinevirtual |
Implements ParticleMatterInteractionHandler.
Definition at line 165 of file BeamStrippingPhysics.h.
References bunchToMatStat_m.
|
inlinevirtual |
Implements ParticleMatterInteractionHandler.
Definition at line 155 of file BeamStrippingPhysics.h.
References totalPartsInMat_m.
|
inlinevirtual |
Implements ParticleMatterInteractionHandler.
Definition at line 160 of file BeamStrippingPhysics.h.
References rediffusedStat_m.
|
private |
Definition at line 584 of file BeamStrippingPhysics.cpp.
References AIR, PartBunchBase< T, Dim >::Bin, DEUTERON, PartBunchBase< T, Dim >::getLocalNum(), Vacuum::getResidualGas(), H2, H2P, HMINUS, HYDROGEN, nCSA, nCSB, nCSC, nCSTotal, PartBunchBase< T, Dim >::POrigin, PROTON, PartBunchBase< T, Dim >::PType, r_m, SECONDARY, transformToH3plus(), transformToHminus(), transformToHydrogen(), transformToProton(), vac_m, and PartBunchBase< T, Dim >::weHaveBins().
Referenced by doPhysics().
|
inlinevirtual |
Implements ParticleMatterInteractionHandler.
Definition at line 145 of file BeamStrippingPhysics.h.
References T_m.
|
inlinevirtual |
Implements ParticleMatterInteractionHandler.
Definition at line 170 of file BeamStrippingPhysics.h.
|
virtual |
Implements ParticleMatterInteractionHandler.
Definition at line 716 of file BeamStrippingPhysics.cpp.
|
inline |
Definition at line 49 of file BeamStrippingPhysics.h.
References cycl_m.
|
virtual |
Implements ParticleMatterInteractionHandler.
Definition at line 719 of file BeamStrippingPhysics.cpp.
References totalPartsInMat_m.
|
private |
Definition at line 707 of file BeamStrippingPhysics.cpp.
References endl(), getName(), H3P, PartBunchBase< T, Dim >::ID, INFORM_ALL_NODES, level4(), PartBunchBase< T, Dim >::M, Physics::m_h3p, PartBunchBase< T, Dim >::PType, PartBunchBase< T, Dim >::Q, and Physics::q_e.
Referenced by getSecondaryParticles().
|
private |
Definition at line 698 of file BeamStrippingPhysics.cpp.
References endl(), getName(), HMINUS, PartBunchBase< T, Dim >::ID, INFORM_ALL_NODES, level4(), PartBunchBase< T, Dim >::M, Physics::m_hm, PartBunchBase< T, Dim >::PType, PartBunchBase< T, Dim >::Q, and Physics::q_e.
Referenced by getSecondaryParticles().
|
private |
Definition at line 689 of file BeamStrippingPhysics.cpp.
References endl(), getName(), HYDROGEN, PartBunchBase< T, Dim >::ID, INFORM_ALL_NODES, level4(), PartBunchBase< T, Dim >::M, Physics::m_h, PartBunchBase< T, Dim >::PType, and PartBunchBase< T, Dim >::Q.
Referenced by getSecondaryParticles().
|
private |
Definition at line 680 of file BeamStrippingPhysics.cpp.
References endl(), getName(), PartBunchBase< T, Dim >::ID, INFORM_ALL_NODES, level4(), PartBunchBase< T, Dim >::M, Physics::m_p, PROTON, PartBunchBase< T, Dim >::PType, PartBunchBase< T, Dim >::Q, and Physics::q_e.
Referenced by getSecondaryParticles().
|
staticprivate |
Definition at line 140 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection(), and computeCrossSectionChebyshev().
|
staticprivate |
Definition at line 141 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection(), and computeCrossSectionNakai().
|
private |
Definition at line 115 of file BeamStrippingPhysics.h.
Referenced by getNumEntered().
|
private |
Definition at line 104 of file BeamStrippingPhysics.h.
Referenced by doPhysics().
|
staticprivate |
Definition at line 121 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
staticprivate |
Definition at line 134 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
staticprivate |
Definition at line 123 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
staticprivate |
Definition at line 136 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
staticprivate |
Definition at line 131 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
staticprivate |
Definition at line 128 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
staticprivate |
Definition at line 137 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
staticprivate |
Definition at line 138 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
staticprivate |
Definition at line 130 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
staticprivate |
Definition at line 129 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
staticprivate |
Definition at line 120 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
staticprivate |
Definition at line 133 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
staticprivate |
Definition at line 122 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
staticprivate |
Definition at line 135 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
staticprivate |
Definition at line 127 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
staticprivate |
Definition at line 125 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
staticprivate |
Definition at line 124 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
private |
Definition at line 96 of file BeamStrippingPhysics.h.
Referenced by doPhysics(), and setCyclotron().
|
private |
Definition at line 102 of file BeamStrippingPhysics.h.
Referenced by apply(), doPhysics(), and evalLorentzStripping().
|
staticprivate |
Definition at line 139 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection().
|
private |
Definition at line 107 of file BeamStrippingPhysics.h.
Referenced by BeamStrippingPhysics(), doPhysics(), and ~BeamStrippingPhysics().
|
private |
Definition at line 103 of file BeamStrippingPhysics.h.
Referenced by computeCrossSectionBohr(), and doPhysics().
|
private |
macroscopic cross sections
Definition at line 110 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection(), and getSecondaryParticles().
|
private |
Definition at line 111 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection(), and getSecondaryParticles().
|
private |
Definition at line 112 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection(), and getSecondaryParticles().
|
private |
Definition at line 113 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection(), evalGasStripping(), and getSecondaryParticles().
|
private |
Definition at line 105 of file BeamStrippingPhysics.h.
Referenced by computeCrossSection(), and doPhysics().
|
private |
Definition at line 99 of file BeamStrippingPhysics.h.
Referenced by BeamStrippingPhysics(), evalGasStripping(), evalLorentzStripping(), getSecondaryParticles(), and ~BeamStrippingPhysics().
|
private |
Definition at line 117 of file BeamStrippingPhysics.h.
Referenced by getRediffused().
|
private |
Definition at line 116 of file BeamStrippingPhysics.h.
Referenced by doPhysics().
|
private |
Definition at line 101 of file BeamStrippingPhysics.h.
Referenced by doPhysics(), and getTime().
|
private |
Definition at line 118 of file BeamStrippingPhysics.h.
Referenced by getParticlesInMat(), and stillActive().
|
private |
Definition at line 97 of file BeamStrippingPhysics.h.
Referenced by BeamStrippingPhysics(), computeCrossSection(), doPhysics(), and getSecondaryParticles().