|
ImpactX
|
#include <Aperture.H>
Public Types | |
| enum | Shape { rectangular , elliptical } |
| enum | Action { transmit , absorb } |
| using | PType = ImpactXParticleContainer::ParticleType |
Public Member Functions | |
| Aperture (amrex::ParticleReal aperture_x, amrex::ParticleReal aperture_y, amrex::ParticleReal repeat_x, amrex::ParticleReal repeat_y, bool shift_odd_x, Shape shape, Action action, amrex::ParticleReal dx=0, amrex::ParticleReal dy=0, amrex::ParticleReal rotation_degree=0, std::optional< std::string > name=std::nullopt) | |
| void | compute_constants (RefPart const &refpart) |
| template<typename T_Real = amrex::ParticleReal, typename T_IdCpu = uint64_t> | |
| AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void | operator() (T_Real &AMREX_RESTRICT x, T_Real &AMREX_RESTRICT y, T_Real &AMREX_RESTRICT t, T_Real &AMREX_RESTRICT px, T_Real &AMREX_RESTRICT py, T_Real &AMREX_RESTRICT pt, T_IdCpu &AMREX_RESTRICT idcpu, RefPart const &AMREX_RESTRICT refpart) const |
| AMREX_GPU_HOST AMREX_FORCE_INLINE Map6x6 | transport_map (RefPart const &AMREX_RESTRICT refpart) const |
Public Member Functions inherited from impactx::elements::mixin::Named | |
| AMREX_GPU_HOST void | set_name (std::string const &new_name) |
| AMREX_GPU_HOST | Named (std::optional< std::string > name) |
| AMREX_GPU_HOST_DEVICE | ~Named () |
| AMREX_GPU_HOST | Named (Named const &other) |
| AMREX_GPU_HOST Named & | operator= (Named const &other) |
| AMREX_GPU_HOST_DEVICE | Named (Named &&other) noexcept |
| AMREX_GPU_HOST_DEVICE Named & | operator= (Named &&other) noexcept |
| AMREX_FORCE_INLINE std::string | name () const |
| AMREX_FORCE_INLINE bool | has_name () const |
Public Member Functions inherited from impactx::elements::mixin::BeamOptic< Aperture > | |
| void | operator() (ImpactXParticleContainer &pc, int step, int period) |
| void | operator() (ImpactXParticleContainer::iterator &pti, RefPart &AMREX_RESTRICT ref_part) |
Public Member Functions inherited from impactx::elements::mixin::LinearTransport< Aperture > | |
| LinearTransport ()=default | |
| LinearTransport (LinearTransport const &)=default | |
| LinearTransport (LinearTransport &&)=default | |
| LinearTransport & | operator= (LinearTransport const &)=default |
| LinearTransport & | operator= (LinearTransport &&rhs)=default |
| ~LinearTransport ()=default | |
| AMREX_GPU_HOST AMREX_FORCE_INLINE void | operator() (Map6x6 &AMREX_RESTRICT cm, RefPart const &AMREX_RESTRICT ref) const |
Public Member Functions inherited from impactx::elements::mixin::Thin | |
| AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void | operator() (RefPart &AMREX_RESTRICT refpart) const |
| AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE int | nslice () const |
| AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::ParticleReal | ds () const |
Public Member Functions inherited from impactx::elements::mixin::Alignment | |
| Alignment (amrex::ParticleReal dx, amrex::ParticleReal dy, amrex::ParticleReal rotation_degree) | |
| Alignment ()=default | |
| Alignment (Alignment const &)=default | |
| Alignment & | operator= (Alignment const &)=default |
| Alignment (Alignment &&)=default | |
| Alignment & | operator= (Alignment &&rhs)=default |
| ~Alignment ()=default | |
| void | compute_constants (RefPart const &refpart) |
| template<typename T_Real> | |
| AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void | shift_in (T_Real &AMREX_RESTRICT x, T_Real &AMREX_RESTRICT y, T_Real &AMREX_RESTRICT px, T_Real &AMREX_RESTRICT py) const |
| template<typename T_Real> | |
| AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void | shift_out (T_Real &AMREX_RESTRICT x, T_Real &AMREX_RESTRICT y, T_Real &AMREX_RESTRICT px, T_Real &AMREX_RESTRICT py) const |
| AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::ParticleReal | dx () const |
| AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::ParticleReal | dy () const |
| AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::ParticleReal | rotation () const |
Public Member Functions inherited from impactx::elements::mixin::NoFinalize | |
| void | finalize () |
Static Public Member Functions | |
| static std::string | shape_name (Shape const &shape) |
| static std::string | action_name (Action const &action) |
Public Attributes | |
| Shape | m_shape |
| Action | m_action |
| aperture type (rectangular, elliptical) | |
| amrex::ParticleReal | m_inv_aperture_x |
| action type (transmit, absorb) | |
| amrex::ParticleReal | m_inv_aperture_y |
| maximum horizontal coordinate | |
| amrex::ParticleReal | m_repeat_x |
| maximum vertical coordinate | |
| amrex::ParticleReal | m_repeat_y |
| horizontal period for repeated masking | |
| bool | m_shift_odd_x |
| vertical period for repeated masking | |
Public Attributes inherited from impactx::elements::mixin::Alignment | |
| amrex::ParticleReal | m_dx = 0 |
| amrex::ParticleReal | m_dy = 0 |
| horizontal translation error [m] | |
| amrex::ParticleReal | m_rotation = 0 |
| vertical translation error [m] | |
Static Public Attributes | |
| static constexpr auto | type = "Aperture" |
Static Public Attributes inherited from impactx::elements::mixin::Alignment | |
| static constexpr amrex::ParticleReal | degree2rad = ablastr::constant::math::pi / 180.0 |
Static Public Attributes inherited from amrex::simd::Vectorized< amrex::simd::native_simd_size_particlereal > | |
| static constexpr int | simd_width |
|
inline |
A thin collimator element that applies a transverse aperture boundary. Particles outside the boundary are considered lost.
| shape | aperture shape |
| action | specify action of domain (transmit/absorb) |
| aperture_x | horizontal half-aperture (m) |
| aperture_y | vertical half-aperture (m) |
| repeat_x | horizontal period for repeated masking, optional (m) |
| repeat_y | vertical period for repeated masking, optional (m) |
| shift_odd_x | for hexagonal/triangular mask patterns: horizontal shift of every 2nd (odd) vertical period by repeat_x / 2. Use alignment offsets dx,dy to move whole mask as needed. |
| dx | horizontal translation error in m |
| dy | vertical translation error in m |
| rotation_degree | rotation error in the transverse plane [degrees] |
| name | a user defined and not necessarily unique name of the element |
|
static |
|
inline |
Compute and cache the constants for the push.
In particular, used to pre-compute and cache variables that are independent of the individually tracked particle.
| refpart | reference particle (unused) |
|
inline |
This is an aperture functor, so that a variable of this type can be used like an aperture function.
| x | particle position in x |
| y | particle position in y |
| t | particle position in t (unused) |
| px | particle momentum in x |
| py | particle momentum in y |
| pt | particle momentum in t (unused) |
| idcpu | particle global index |
| refpart | reference particle (unused) |
|
static |
|
inline |
This function returns the linear transport map.
| [in] | refpart | reference particle |
| Action impactx::elements::Aperture::m_action |
aperture type (rectangular, elliptical)
| amrex::ParticleReal impactx::elements::Aperture::m_inv_aperture_x |
action type (transmit, absorb)
| amrex::ParticleReal impactx::elements::Aperture::m_inv_aperture_y |
maximum horizontal coordinate
| amrex::ParticleReal impactx::elements::Aperture::m_repeat_x |
maximum vertical coordinate
| amrex::ParticleReal impactx::elements::Aperture::m_repeat_y |
horizontal period for repeated masking
| Shape impactx::elements::Aperture::m_shape |
| bool impactx::elements::Aperture::m_shift_odd_x |
vertical period for repeated masking
|
staticconstexpr |