Analysis Software
Documentation for sPHENIX simulation software
|
#include <acts/blob/sPHENIX/Fatras/include/ActsFatras/Kernel/InteractionList.hpp>
Classes | |
struct | Selection |
Point-like interaction selection. More... | |
Public Member Functions | |
void | disable (size_t process) |
Disable a specific process identified by index. | |
template<typename process_t > | |
void | disable () |
template<size_t kProcess> | |
std::tuple_element_t< kProcess, Processes > & | get () |
Access a specific process identified by index. | |
template<typename process_t > | |
process_t & | get () |
template<typename generator_t > | |
bool | runContinuous (generator_t &rng, const Acts::MaterialSlab &slab, Particle &particle, std::vector< Particle > &generated) const |
template<typename generator_t > | |
Selection | armPointLike (generator_t &rng, const Particle &particle) const |
template<typename generator_t > | |
bool | runPointLike (generator_t &rng, size_t processIndex, Particle &particle, std::vector< Particle > &generated) const |
Private Types | |
using | Mask = std::bitset< sizeof...(processes_t)> |
using | Processes = std::tuple< processes_t...> |
using | ContinuousIndices = detail::ContinuousIndices< Processes > |
using | PointLikeIndices = detail::PointLikeIndices< Processes > |
Private Member Functions | |
template<typename generator_t , std::size_t kI0, std::size_t... kIs> | |
bool | runContinuousImpl (generator_t &rng, const Acts::MaterialSlab &slab, Particle &particle, std::vector< Particle > &generated, std::index_sequence< kI0, kIs...>) const |
template<typename generator_t > | |
bool | runContinuousImpl (generator_t &, const Acts::MaterialSlab &, Particle &, std::vector< Particle > &, std::index_sequence<>) const |
template<typename generator_t , std::size_t kI0, std::size_t... kIs> | |
void | armPointLikeImpl (generator_t &rng, const Particle &particle, Selection &selection, std::index_sequence< kI0, kIs...>) const |
template<typename generator_t > | |
void | armPointLikeImpl (generator_t &, const Particle &, Selection &, std::index_sequence<>) const |
template<typename generator_t , size_t kI0, size_t... kIs> | |
bool | runPointLikeImpl (generator_t &rng, size_t processIndex, Particle &particle, std::vector< Particle > &generated, std::index_sequence< kI0, kIs...>) const |
template<typename generator_t > | |
bool | runPointLikeImpl (generator_t &, size_t, Particle &, std::vector< Particle > &, std::index_sequence<>) const |
Private Attributes | |
Mask | m_mask |
Processes | m_processes |
Compile-time set of interaction processes for the simulation.
Two different type of interaction processes are supported: continuous and point-like interactions.
Continuous processes scale with the passed material. They tpyically describe effective results of a large number of small interactions such as multiple scattering or ionisation. Continous process types must provide a call operator with the following signature:
template <typename generator_t> bool operator()( generator_t& rng, const Acts::MaterialSlab& slab, Particle& particle, std::vector<Particle>& generatedParticles) const
If multiple continuous processes are defined, they are executed serially in the order in which they are given.
For point-like processes, the passed material only affects the probability with which they occur but not the interaction itself, e.g. photon conversion into electron pairs. They are simulated by first drawing a limit on the material paths and then executing the interaction with the shortest limit when the drawn amount of material has been passed. Point-like process types must provide the following two member functions:
// generate X0/L0 limits template <typename generator_t> std::pair<Scalar, Scalar> generatePathLimits( generator& rng, const Particle& particle) const // run the process simulation template <typename generator_t> bool run( generator_t& rng, Particle& particle, std::vector<Particle>& generatedParticles) const
For both continuous and point-like interactions, the output particle is modified in-place (if needed) and the return value indicates a break condition in the simulation, i.e. the particle is dead (true) or alive (false) after the interaction.
The physics processes are extendable by the user to accomodate their specific requirements. While the set of available physics processes must be configured at compile-time, within that set, processes can again be selectively disabled at run-time. By default all processes are applied.
Definition at line 175 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 175 of file InteractionList.hpp
|
private |
Definition at line 178 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 178 of file InteractionList.hpp
|
private |
Definition at line 176 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 176 of file InteractionList.hpp
|
private |
Definition at line 179 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 179 of file InteractionList.hpp
|
private |
Definition at line 177 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 177 of file InteractionList.hpp
|
inline |
Arm the point-like interactions by generating limits and select processes.
generator_t | must be a RandomNumberEngine |
[in] | rng | is the random number generator |
[in] | particle | is the initial particle state |
Definition at line 241 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 241 of file InteractionList.hpp
References ActsFatras::InteractionList< processes_t >::armPointLikeImpl().
Referenced by BOOST_AUTO_TEST_CASE().
|
inlineprivate |
Definition at line 300 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 300 of file InteractionList.hpp
References ActsFatras::InteractionList< processes_t >::Selection::l0Limit, ActsFatras::InteractionList< processes_t >::Selection::l0Process, ActsFatras::InteractionList< processes_t >::m_mask, ActsFatras::InteractionList< processes_t >::m_processes, ActsFatras::InteractionList< processes_t >::Selection::x0Limit, and ActsFatras::InteractionList< processes_t >::Selection::x0Process.
Referenced by ActsFatras::InteractionList< processes_t >::armPointLike().
|
inlineprivate |
Definition at line 320 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 320 of file InteractionList.hpp
|
inline |
Disable a specific process identified by index.
Definition at line 193 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 193 of file InteractionList.hpp
References ActsFatras::InteractionList< processes_t >::m_mask.
Referenced by BOOST_AUTO_TEST_CASE().
|
inline |
Disable a specific process identified by type.
Definition at line 199 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 199 of file InteractionList.hpp
References ActsFatras::InteractionList< processes_t >::m_mask, and value.
|
inline |
Access a specific process identified by index.
Definition at line 205 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 205 of file InteractionList.hpp
References ActsFatras::InteractionList< processes_t >::m_processes.
Referenced by ActsFatras::makeStandardChargedElectroMagneticInteractions().
|
inline |
Access a specific process identified by type.
Definition at line 213 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 213 of file InteractionList.hpp
References ActsFatras::InteractionList< processes_t >::m_processes.
|
inline |
Simulate the combined effects from all continuous interactions.
generator_t | must be a RandomNumberEngine |
[in] | rng | is the random number generator |
[in] | slab | is the passed material |
[in,out] | particle | is the particle being updated |
[out] | generated | is the container of generated particles |
Definition at line 226 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 226 of file InteractionList.hpp
References ActsFatras::InteractionList< processes_t >::runContinuousImpl().
Referenced by BOOST_AUTO_TEST_CASE().
|
inlineprivate |
Definition at line 275 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 275 of file InteractionList.hpp
References ActsFatras::InteractionList< processes_t >::m_mask, ActsFatras::InteractionList< processes_t >::m_processes, and tgeo-response2json::process().
Referenced by ActsFatras::InteractionList< processes_t >::runContinuous().
|
inlineprivate |
Definition at line 288 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 288 of file InteractionList.hpp
|
inline |
Simulate the effects from a single point-like interaction.
generator_t | must be a RandomNumberEngine |
[in] | rng | is the random number generator |
[in] | processIndex | is the index of the process to be executed |
[in,out] | particle | is the particle being updated |
[out] | generated | is the container of generated particles |
The process index is expected to originate from a previous armPointLike(...)
call, but this is not enforced. How to select the correct process requires more information that is not available here.
Definition at line 260 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 260 of file InteractionList.hpp
References ActsFatras::InteractionList< processes_t >::runPointLikeImpl().
Referenced by BOOST_AUTO_TEST_CASE().
|
inlineprivate |
Definition at line 329 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 329 of file InteractionList.hpp
References ActsFatras::InteractionList< processes_t >::m_mask, ActsFatras::InteractionList< processes_t >::m_processes, and utils::run.
Referenced by ActsFatras::InteractionList< processes_t >::runPointLike().
|
inlineprivate |
Definition at line 345 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 345 of file InteractionList.hpp
|
private |
Definition at line 268 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 268 of file InteractionList.hpp
Referenced by ActsFatras::InteractionList< processes_t >::armPointLikeImpl(), ActsFatras::InteractionList< processes_t >::disable(), ActsFatras::InteractionList< processes_t >::runContinuousImpl(), and ActsFatras::InteractionList< processes_t >::runPointLikeImpl().
|
private |
Definition at line 269 of file InteractionList.hpp.
View newest version in sPHENIX GitHub at line 269 of file InteractionList.hpp
Referenced by ActsFatras::InteractionList< processes_t >::armPointLikeImpl(), ActsFatras::InteractionList< processes_t >::get(), ActsFatras::InteractionList< processes_t >::runContinuousImpl(), and ActsFatras::InteractionList< processes_t >::runPointLikeImpl().