ATTPCROOT  0.3.0-alpha
A ROOT-based framework for analyzing data from active target detectors
Public Member Functions | Protected Attributes | List of all members
AtTools::AtELossTable Class Reference

#include <AtELossTable.h>

Inheritance diagram for AtTools::AtELossTable:
Inheritance graph
[legend]
Collaboration diagram for AtTools::AtELossTable:
Collaboration graph
[legend]

Public Member Functions

 AtELossTable (double density=0)
 
 AtELossTable (const std::vector< double > &energy, const std::vector< double > &dEdX, double density=0)
 
void SetDistanceError (double val)
 Set error in particle range when calculating energy losses. More...
 
void LoadSrimTable (std::string fileName)
 
void LoadLiseTable (std::string fileName, double mass, double density, int column=2)
 
virtual double GetdEdx (double energy) const override
 
virtual double GetRange (double energyIni, double energyFin=0) const override
 
virtual double GetEnergyLoss (double energyIni, double distance) const override
 
virtual double GetEnergy (double energyIni, double distance) const override
 
double GetEnergyOld (double energyIni, double distance) const
 
- Public Member Functions inherited from AtTools::AtELossModel
 AtELossModel (double density)
 
virtual ~AtELossModel ()=default
 
void SetDensity (double density)
 

Protected Attributes

tk::spline fdXdE
 
double fDistErr {1e-4}
 
- Protected Attributes inherited from AtTools::AtELossModel
double fDensityIni
 
double fDensity
 
double fdEdxScale {1}
 

Additional Inherited Members

- Protected Member Functions inherited from AtTools::AtELossModel
void SetIniDensity (double density)
 

Detailed Description

Definition at line 13 of file AtELossTable.h.

Constructor & Destructor Documentation

◆ AtELossTable() [1/2]

AtTools::AtELossTable::AtELossTable ( double  density = 0)
inline

Definition at line 20 of file AtELossTable.h.

◆ AtELossTable() [2/2]

AtTools::AtELossTable::AtELossTable ( const std::vector< double > &  energy,
const std::vector< double > &  dEdX,
double  density = 0 
)

Definition at line 26 of file AtELossTable.cxx.

Member Function Documentation

◆ GetdEdx()

double AtTools::AtELossTable::GetdEdx ( double  energy) const
overridevirtual

Get the stopping power in MeV/mm

Implements AtTools::AtELossModel.

Definition at line 32 of file AtELossTable.cxx.

◆ GetEnergy()

double AtTools::AtELossTable::GetEnergy ( double  energyIni,
double  distance 
) const
overridevirtual

Get the energy of particle after traveling some distance (in mm). If the distance is negative, then returns the energy the particle had to reach energyIni after distance.

Implements AtTools::AtELossModel.

Definition at line 46 of file AtELossTable.cxx.

◆ GetEnergyLoss()

virtual double AtTools::AtELossTable::GetEnergyLoss ( double  energyIni,
double  distance 
) const
inlineoverridevirtual

Get the energy loss over some distance (in mm).

Implements AtTools::AtELossModel.

Definition at line 38 of file AtELossTable.h.

◆ GetEnergyOld()

double AtTools::AtELossTable::GetEnergyOld ( double  energyIni,
double  distance 
) const

Definition at line 74 of file AtELossTable.cxx.

◆ GetRange()

double AtTools::AtELossTable::GetRange ( double  energyIni,
double  energyFin = 0 
) const
overridevirtual

Get the range of the particle in the material.

Implements AtTools::AtELossModel.

Definition at line 38 of file AtELossTable.cxx.

◆ LoadLiseTable()

void AtTools::AtELossTable::LoadLiseTable ( std::string  fileName,
double  mass,
double  density,
int  column = 2 
)

Load energy loss table from LISE++ (export of stopping power graph to file).

Parameters
[in]fileNameName of text file.
[in]massMass of the fragment in units of u.
[in]densityDensity of target in g/cm^3. If positive, units of table are assumed to be MeV/mg/cm^2. If not positive units of the table are assumed to be MeV/um and the target density is taken to be |density|.
[in]columnThe column in the table to use as the energy model (default LISE is 2).

Definition at line 170 of file AtELossTable.cxx.

◆ LoadSrimTable()

void AtTools::AtELossTable::LoadSrimTable ( std::string  fileName)

Definition at line 113 of file AtELossTable.cxx.

◆ SetDistanceError()

void AtTools::AtELossTable::SetDistanceError ( double  val)
inline

Set error in particle range when calculating energy losses.

Definition at line 24 of file AtELossTable.h.

Member Data Documentation

◆ fDistErr

double AtTools::AtELossTable::fDistErr {1e-4}
protected

Definition at line 17 of file AtELossTable.h.

◆ fdXdE

tk::spline AtTools::AtELossTable::fdXdE
protected

Definition at line 15 of file AtELossTable.h.


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