Garfield 0.3
Toolkit for the detailed simulation of particle detectors based on ionization measurement in gases and semiconductors
Loading...
Searching...
No Matches
Garfield::TrackPAI Class Reference

#include <TrackPAI.hh>

Inheritance diagram for Garfield::TrackPAI:
Garfield::Track

Classes

struct  Cluster

Public Member Functions

 TrackPAI ()
virtual ~TrackPAI ()
bool NewTrack (const double x0, const double y0, const double z0, const double t0, const double dx0, const double dy0, const double dz0) override
 Calculate a new track starting from (x0, y0, z0) at time t0 in direction (dx0, dy0, dz0).
const std::vector< Cluster > & GetClusters () const
double GetClusterDensity () override
 Get the cluster density (number of ionizing collisions per cm or inverse mean free path for ionization).
double GetStoppingPower () override
 Get the stopping power (mean energy loss [eV] per cm).
Public Member Functions inherited from Garfield::Track
 Track ()=delete
 Default constructor.
 Track (const std::string &name)
 Constructor.
virtual ~Track ()
 Destructor.
virtual void SetParticle (const std::string &part)
 Set the type of charged particle.
void SetEnergy (const double e)
 Set the particle energy.
void SetBetaGamma (const double bg)
 Set the relative momentum of the particle.
void SetBeta (const double beta)
 Set the speed ( $\beta = v/c$) of the particle.
void SetGamma (const double gamma)
 Set the Lorentz factor of the particle.
void SetMomentum (const double p)
 Set the particle momentum.
void SetKineticEnergy (const double ekin)
 Set the kinetic energy of the particle.
double GetEnergy () const
 Return the particle energy.
double GetBetaGamma () const
 Return the $\beta\gamma$ of the projectile.
double GetBeta () const
 Return the speed ( $\beta = v/c$) of the projectile.
double GetGamma () const
 Return the Lorentz factor of the projectile.
double GetMomentum () const
 Return the particle momentum.
double GetKineticEnergy () const
 Return the kinetic energy of the projectile.
double GetCharge () const
 Get the charge of the projectile.
double GetMass () const
 Get the mass [eV / c2] of the projectile.
void SetSensor (Sensor *s)
 Set the sensor through which to transport the particle.
void EnablePlotting (ViewDrift *viewer)
 Switch on plotting.
void DisablePlotting ()
 Switch off plotting.
void EnableDebugging ()
 Switch on debugging messages.
void DisableDebugging ()
 Switch off debugging messages.

Private Member Functions

bool SetupMedium (Medium *medium)
bool SetupCrossSectionTable ()
double ComputeMaxTransfer () const
double ComputeCsTail (const double emin, const double emax)
double ComputeDeDxTail (const double emin, const double emax)
std::pair< double, double > SampleEnergyDeposit (const double u) const
double SampleAsymptoticCs (double u) const
double SampleAsymptoticCsSpinZero (const double emin, double u) const
double SampleAsymptoticCsSpinHalf (const double emin, double u) const
double SampleAsymptoticCsSpinOne (const double emin, double u) const
double SampleAsymptoticCsElectron (const double emin, double u) const
double SampleAsymptoticCsPositron (const double emin, double u) const
double LossFunction (const double eps1, const double eps2) const

Private Attributes

double m_speed = 0.
double m_emax = 0.
double m_imfp = 0.
double m_dedx = 0.
std::array< double, m_nStepsm_eps1
std::array< double, m_nStepsm_eps2
std::array< double, m_nStepsm_epsInt
std::array< double, m_nStepsm_energies
std::array< double, m_nStepsm_cdf
std::array< double, m_nStepsm_rutherford
std::vector< Clusterm_clusters
std::string m_mediumName = ""
double m_mediumDensity = 0.
double m_electronDensity = 0.

Static Private Attributes

static constexpr size_t m_nSteps = 1000

Additional Inherited Members

Protected Member Functions inherited from Garfield::Track
void PlotNewTrack (const double x0, const double y0, const double z0)
void PlotCluster (const double x0, const double y0, const double z0)
Static Protected Member Functions inherited from Garfield::Track
static std::array< double, 3 > StepBfield (const double dt, const double qoverm, const double vmag, double bx, double by, double bz, std::array< double, 3 > &dir)
Protected Attributes inherited from Garfield::Track
std::string m_className = "Track"
double m_q = -1.
int m_spin = 1
double m_mass
double m_energy = 0.
double m_beta2 = 1.
bool m_isElectron = false
std::string m_particleName = "mu-"
Sensor * m_sensor = nullptr
bool m_isChanged = true
ViewDriftm_viewer = nullptr
bool m_debug = false
size_t m_plotId = 0

Detailed Description

Definition at line 14 of file TrackPAI.hh.

Constructor & Destructor Documentation

◆ TrackPAI()

Garfield::TrackPAI::TrackPAI ( )

◆ ~TrackPAI()

virtual Garfield::TrackPAI::~TrackPAI ( )
inlinevirtual

Definition at line 24 of file TrackPAI.hh.

24{}

Member Function Documentation

◆ ComputeCsTail()

double Garfield::TrackPAI::ComputeCsTail ( const double emin,
const double emax )
private

◆ ComputeDeDxTail()

double Garfield::TrackPAI::ComputeDeDxTail ( const double emin,
const double emax )
private

◆ ComputeMaxTransfer()

double Garfield::TrackPAI::ComputeMaxTransfer ( ) const
private

◆ GetClusterDensity()

double Garfield::TrackPAI::GetClusterDensity ( )
overridevirtual

Get the cluster density (number of ionizing collisions per cm or inverse mean free path for ionization).

Reimplemented from Garfield::Track.

◆ GetClusters()

const std::vector< Cluster > & Garfield::TrackPAI::GetClusters ( ) const
inline

Definition at line 30 of file TrackPAI.hh.

30{ return m_clusters; }
std::vector< Cluster > m_clusters
Definition TrackPAI.hh:57

◆ GetStoppingPower()

double Garfield::TrackPAI::GetStoppingPower ( )
overridevirtual

Get the stopping power (mean energy loss [eV] per cm).

Reimplemented from Garfield::Track.

◆ LossFunction()

double Garfield::TrackPAI::LossFunction ( const double eps1,
const double eps2 ) const
inlineprivate

Definition at line 80 of file TrackPAI.hh.

80 {
81 const double eps = eps1 * eps1 + eps2 * eps2;
82 return eps > 0. ? eps2 / eps : 0.;
83 }

◆ NewTrack()

bool Garfield::TrackPAI::NewTrack ( const double x0,
const double y0,
const double z0,
const double t0,
const double dx0,
const double dy0,
const double dz0 )
overridevirtual

Calculate a new track starting from (x0, y0, z0) at time t0 in direction (dx0, dy0, dz0).

Implements Garfield::Track.

◆ SampleAsymptoticCs()

double Garfield::TrackPAI::SampleAsymptoticCs ( double u) const
private

◆ SampleAsymptoticCsElectron()

double Garfield::TrackPAI::SampleAsymptoticCsElectron ( const double emin,
double u ) const
private

◆ SampleAsymptoticCsPositron()

double Garfield::TrackPAI::SampleAsymptoticCsPositron ( const double emin,
double u ) const
private

◆ SampleAsymptoticCsSpinHalf()

double Garfield::TrackPAI::SampleAsymptoticCsSpinHalf ( const double emin,
double u ) const
private

◆ SampleAsymptoticCsSpinOne()

double Garfield::TrackPAI::SampleAsymptoticCsSpinOne ( const double emin,
double u ) const
private

◆ SampleAsymptoticCsSpinZero()

double Garfield::TrackPAI::SampleAsymptoticCsSpinZero ( const double emin,
double u ) const
private

◆ SampleEnergyDeposit()

std::pair< double, double > Garfield::TrackPAI::SampleEnergyDeposit ( const double u) const
private

◆ SetupCrossSectionTable()

bool Garfield::TrackPAI::SetupCrossSectionTable ( )
private

◆ SetupMedium()

bool Garfield::TrackPAI::SetupMedium ( Medium * medium)
private

Member Data Documentation

◆ m_cdf

std::array<double, m_nSteps> Garfield::TrackPAI::m_cdf
private

Definition at line 54 of file TrackPAI.hh.

◆ m_clusters

std::vector<Cluster> Garfield::TrackPAI::m_clusters
private

Definition at line 57 of file TrackPAI.hh.

◆ m_dedx

double Garfield::TrackPAI::m_dedx = 0.
private

Definition at line 44 of file TrackPAI.hh.

◆ m_electronDensity

double Garfield::TrackPAI::m_electronDensity = 0.
private

Definition at line 62 of file TrackPAI.hh.

◆ m_emax

double Garfield::TrackPAI::m_emax = 0.
private

Definition at line 39 of file TrackPAI.hh.

◆ m_energies

std::array<double, m_nSteps> Garfield::TrackPAI::m_energies
private

Definition at line 53 of file TrackPAI.hh.

◆ m_eps1

std::array<double, m_nSteps> Garfield::TrackPAI::m_eps1
private

Definition at line 48 of file TrackPAI.hh.

◆ m_eps2

std::array<double, m_nSteps> Garfield::TrackPAI::m_eps2
private

Definition at line 49 of file TrackPAI.hh.

◆ m_epsInt

std::array<double, m_nSteps> Garfield::TrackPAI::m_epsInt
private

Definition at line 50 of file TrackPAI.hh.

◆ m_imfp

double Garfield::TrackPAI::m_imfp = 0.
private

Definition at line 42 of file TrackPAI.hh.

◆ m_mediumDensity

double Garfield::TrackPAI::m_mediumDensity = 0.
private

Definition at line 61 of file TrackPAI.hh.

◆ m_mediumName

std::string Garfield::TrackPAI::m_mediumName = ""
private

Definition at line 60 of file TrackPAI.hh.

◆ m_nSteps

size_t Garfield::TrackPAI::m_nSteps = 1000
staticconstexprprivate

Definition at line 47 of file TrackPAI.hh.

◆ m_rutherford

std::array<double, m_nSteps> Garfield::TrackPAI::m_rutherford
private

Definition at line 55 of file TrackPAI.hh.

◆ m_speed

double Garfield::TrackPAI::m_speed = 0.
private

Definition at line 37 of file TrackPAI.hh.


The documentation for this class was generated from the following file:
  • /builds/garfield/docs/source/Include/Garfield/TrackPAI.hh