EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Acts::Material Class Reference

#include <acts/blob/sPHENIX/Core/include/Acts/Material/Material.hpp>

Public Types

using ParametersVector = Acts::ActsVectorF< 5 >
 

Public Member Functions

 Material ()=default
 Construct a vacuum representation.
 
 Material (const ParametersVector &parameters)
 Construct from an encoded parameters vector.
 
 Material (Material &&mat)=default
 
 Material (const Material &mat)=default
 
 ~Material ()=default
 
Materialoperator= (Material &&mat)=default
 
Materialoperator= (const Material &mat)=default
 
constexpr operator bool () const
 Check if the material is valid, i.e. it is not vacuum.
 
constexpr float X0 () const
 Return the radition length. Infinity in case of vacuum.
 
constexpr float L0 () const
 Return the nuclear interaction length. Infinity in case of vacuum.
 
constexpr float Ar () const
 Return the relative atomic mass.
 
constexpr float Z () const
 Return the nuclear charge number.
 
constexpr float molarDensity () const
 Return the molar density.
 
constexpr float molarElectronDensity () const
 Return the molar electron density.
 
float massDensity () const
 Return the mass density.
 
float meanExcitationEnergy () const
 Return the mean electron excitation energy.
 
ParametersVector parameters () const
 Encode the properties into an opaque parameters vector.
 

Static Public Member Functions

static Material fromMolarDensity (float x0, float l0, float ar, float z, float molarRho)
 
static Material fromMassDensity (float x0, float l0, float ar, float z, float massRho)
 

Private Attributes

float m_x0 = std::numeric_limits<float>::infinity()
 
float m_l0 = std::numeric_limits<float>::infinity()
 
float m_ar = 0.0f
 
float m_z = 0.0f
 
float m_molarRho = 0.0f
 

Friends

constexpr bool operator== (const Material &lhs, const Material &rhs)
 
constexpr bool operator!= (const Material &lhs, const Material &rhs)
 

Detailed Description

Material description for interactions with matter.

The following parameters are used to specify the material and its interactions with traversing particles:

  • radiation length X0 (native length units)
  • nuclear interaction length L0 (native length units)
  • relative atomic mass Ar (unitless number)
  • nuclear charge number Z (elementary charge e)
  • molar density (native amount-of-substance unit / (native length unit)³)

The parameters can be effective or average parameters e.g. when a mixture of materials is described.

Note
Always use the opaque parameters vector to serialize/deserialize the material information. Since the internal storage might be different from the external accessors, this ensures that always the numerically optimal parameters are stored. Use the ParametersVector type and do not assume any particular size since we might consider to store more parameters in the future.

Definition at line 38 of file Material.hpp.

View newest version in sPHENIX GitHub at line 38 of file Material.hpp

Member Typedef Documentation

Definition at line 40 of file Material.hpp.

View newest version in sPHENIX GitHub at line 40 of file Material.hpp

Constructor & Destructor Documentation

Acts::Material::Material ( )
default

Construct a vacuum representation.

Acts::Material::Material ( const ParametersVector parameters)

Construct from an encoded parameters vector.

Definition at line 65 of file Material.cpp.

View newest version in sPHENIX GitHub at line 65 of file Material.cpp

Acts::Material::Material ( Material &&  mat)
default
Acts::Material::Material ( const Material mat)
default
Acts::Material::~Material ( )
default

Member Function Documentation

constexpr float Acts::Material::Ar ( ) const
inline

Return the relative atomic mass.

Definition at line 91 of file Material.hpp.

View newest version in sPHENIX GitHub at line 91 of file Material.hpp

References m_ar.

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), and Acts::operator<<().

+ Here is the caller graph for this function:

Acts::Material Acts::Material::fromMassDensity ( float  x0,
float  l0,
float  ar,
float  z,
float  massRho 
)
static

Construct from material parameters using the mass density.

Parameters
X0is the radiation length
L0is the nuclear interaction length
Aris the relative atomic mass
Zis the nuclear charge number
massRhois the mass density
Warning
Due to the choice of native mass units, using the mass density can lead to numerical problems. Typical mass densities lead to computations with values differing by 20+ orders of magnitude.

Definition at line 29 of file Material.cpp.

View newest version in sPHENIX GitHub at line 29 of file Material.cpp

References m_x0, and z.

Referenced by BOOST_AUTO_TEST_CASE(), ActsExamples::Generic::buildDetector(), main(), ActsExamples::RootMaterialTrackReader::read(), ActsExamples::RootMaterialDecorator::RootMaterialDecorator(), and ActsExamples::SteppingAction::UserSteppingAction().

+ Here is the caller graph for this function:

Acts::Material Acts::Material::fromMolarDensity ( float  x0,
float  l0,
float  ar,
float  z,
float  molarRho 
)
static

Construct from material parameters using the molar density.

Parameters
X0is the radiation length
L0is the nuclear interaction length
Aris the relative atomic mass
Zis the nuclear charge number
molarRhois the molar density

Definition at line 54 of file Material.cpp.

View newest version in sPHENIX GitHub at line 54 of file Material.cpp

References m_ar, m_l0, m_molarRho, m_x0, m_z, and z.

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), BOOST_DATA_TEST_CASE(), Acts::Test::makeBeryllium(), Acts::Test::makeSilicon(), and Acts::Test::makeUnitSlab().

+ Here is the caller graph for this function:

constexpr float Acts::Material::L0 ( ) const
inline

Return the nuclear interaction length. Infinity in case of vacuum.

Definition at line 89 of file Material.hpp.

View newest version in sPHENIX GitHub at line 89 of file Material.hpp

References m_l0.

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), and Acts::operator<<().

+ Here is the caller graph for this function:

float Acts::Material::massDensity ( ) const

Return the mass density.

Definition at line 72 of file Material.cpp.

View newest version in sPHENIX GitHub at line 72 of file Material.cpp

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE(), and BOOST_AUTO_TEST_CASE().

+ Here is the caller graph for this function:

float Acts::Material::meanExcitationEnergy ( ) const

Return the mean electron excitation energy.

Definition at line 81 of file Material.cpp.

View newest version in sPHENIX GitHub at line 81 of file Material.cpp

Referenced by BOOST_AUTO_TEST_CASE().

+ Here is the caller graph for this function:

constexpr float Acts::Material::molarDensity ( ) const
inline

Return the molar density.

Definition at line 95 of file Material.hpp.

View newest version in sPHENIX GitHub at line 95 of file Material.hpp

References m_molarRho.

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), and Acts::operator<<().

+ Here is the caller graph for this function:

constexpr float Acts::Material::molarElectronDensity ( ) const
inline

Return the molar electron density.

Definition at line 97 of file Material.hpp.

View newest version in sPHENIX GitHub at line 97 of file Material.hpp

References m_molarRho, and m_z.

Referenced by BOOST_AUTO_TEST_CASE().

+ Here is the caller graph for this function:

constexpr Acts::Material::operator bool ( ) const
inline

Check if the material is valid, i.e. it is not vacuum.

Definition at line 84 of file Material.hpp.

View newest version in sPHENIX GitHub at line 84 of file Material.hpp

References m_ar.

Material& Acts::Material::operator= ( Material &&  mat)
default
Material& Acts::Material::operator= ( const Material mat)
default
Acts::Material::ParametersVector Acts::Material::parameters ( ) const

Encode the properties into an opaque parameters vector.

Definition at line 88 of file Material.cpp.

View newest version in sPHENIX GitHub at line 88 of file Material.cpp

References Dataset::parameters.

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE().

+ Here is the caller graph for this function:

constexpr float Acts::Material::X0 ( ) const
inline

Return the radition length. Infinity in case of vacuum.

Definition at line 87 of file Material.hpp.

View newest version in sPHENIX GitHub at line 87 of file Material.hpp

References m_x0.

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), and Acts::operator<<().

+ Here is the caller graph for this function:

constexpr float Acts::Material::Z ( ) const
inline

Return the nuclear charge number.

Definition at line 93 of file Material.hpp.

View newest version in sPHENIX GitHub at line 93 of file Material.hpp

References m_z.

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE(), BOOST_AUTO_TEST_CASE(), ActsFatras::detail::GaussianMixture::operator()(), ActsFatras::detail::GeneralMixture::operator()(), and Acts::operator<<().

+ Here is the caller graph for this function:

Friends And Related Function Documentation

constexpr bool operator!= ( const Material lhs,
const Material rhs 
)
friend

Definition at line 118 of file Material.hpp.

View newest version in sPHENIX GitHub at line 118 of file Material.hpp

constexpr bool operator== ( const Material lhs,
const Material rhs 
)
friend

Definition at line 113 of file Material.hpp.

View newest version in sPHENIX GitHub at line 113 of file Material.hpp

Member Data Documentation

float Acts::Material::m_ar = 0.0f
private

Definition at line 109 of file Material.hpp.

View newest version in sPHENIX GitHub at line 109 of file Material.hpp

Referenced by Ar(), fromMolarDensity(), and operator bool().

float Acts::Material::m_l0 = std::numeric_limits<float>::infinity()
private

Definition at line 108 of file Material.hpp.

View newest version in sPHENIX GitHub at line 108 of file Material.hpp

Referenced by fromMolarDensity(), and L0().

float Acts::Material::m_molarRho = 0.0f
private

Definition at line 111 of file Material.hpp.

View newest version in sPHENIX GitHub at line 111 of file Material.hpp

Referenced by fromMolarDensity(), molarDensity(), and molarElectronDensity().

float Acts::Material::m_x0 = std::numeric_limits<float>::infinity()
private

Definition at line 107 of file Material.hpp.

View newest version in sPHENIX GitHub at line 107 of file Material.hpp

Referenced by fromMassDensity(), fromMolarDensity(), and X0().

float Acts::Material::m_z = 0.0f
private

Definition at line 110 of file Material.hpp.

View newest version in sPHENIX GitHub at line 110 of file Material.hpp

Referenced by fromMolarDensity(), molarElectronDensity(), and Z().


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