ImpactX
Public Types | Public Member Functions | Static Public Attributes | Private Attributes | List of all members
impactx::ShortRF Struct Reference

#include <ShortRF.H>

Public Types

using PType = ImpactXParticleContainer::ParticleType
 

Public Member Functions

 ShortRF (amrex::ParticleReal const V, amrex::ParticleReal const k)
 
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void operator() (PType &AMREX_RESTRICT p, amrex::ParticleReal &AMREX_RESTRICT px, amrex::ParticleReal &AMREX_RESTRICT py, amrex::ParticleReal &AMREX_RESTRICT pt, RefPart const &refpart) const
 
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void operator() ([[maybe_unused]] 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
 

Static Public Attributes

static constexpr auto name = "ShortRF"
 

Private Attributes

amrex::ParticleReal m_V
 
amrex::ParticleReal m_k
 normalized (max) RF voltage drop. More...
 

Member Typedef Documentation

◆ PType

Constructor & Destructor Documentation

◆ ShortRF()

impactx::ShortRF::ShortRF ( amrex::ParticleReal const  V,
amrex::ParticleReal const  k 
)
inline

A short RF cavity element at zero crossing for bunching

Parameters
VNormalized RF voltage drop V = Emax*L/(c*Brho)
kWavenumber of RF in 1/m

Member Function Documentation

◆ ds()

AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::ParticleReal impactx::ShortRF::ds ( ) const
inline

Return the segment length

Returns
zero, because this is a zero-length element

◆ nslice()

AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE int impactx::ShortRF::nslice ( ) const
inline

Number of slices used for the application of space charge

Returns
one, because this is a zero-length element

◆ operator()() [1/2]

AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void impactx::ShortRF::operator() ( PType &AMREX_RESTRICT  p,
amrex::ParticleReal &AMREX_RESTRICT  px,
amrex::ParticleReal &AMREX_RESTRICT  py,
amrex::ParticleReal &AMREX_RESTRICT  pt,
RefPart const &  refpart 
) const
inline

This is a shortrf functor, so that a variable of this type can be used like a shortrf function.

Parameters
pParticle AoS data for positions and cpu/id
pxparticle momentum in x
pyparticle momentum in y
ptparticle momentum in t
refpartreference particle

◆ operator()() [2/2]

AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void impactx::ShortRF::operator() ( [[maybe_unused] ] RefPart &AMREX_RESTRICT  refpart) const
inline

This pushes the reference particle.

Parameters
[in,out]refpartreference particle

Member Data Documentation

◆ m_k

amrex::ParticleReal impactx::ShortRF::m_k
private

normalized (max) RF voltage drop.

◆ m_V

amrex::ParticleReal impactx::ShortRF::m_V
private

◆ name

constexpr auto impactx::ShortRF::name = "ShortRF"
static

The documentation for this struct was generated from the following file: