ImpactX
Public Member Functions | Private Attributes | List of all members
impactx::distribution::Thermal Struct Reference

#include <Thermal.H>

Public Member Functions

 Thermal (amrex::ParticleReal k, amrex::ParticleReal kT, amrex::ParticleReal kT_halo, amrex::ParticleReal normalize, amrex::ParticleReal normalize_halo, amrex::ParticleReal halo)
 
void initialize (amrex::ParticleReal bunch_charge, RefPart const &ref)
 
void finalize ()
 
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void operator() (amrex::ParticleReal &AMREX_RESTRICT x, amrex::ParticleReal &AMREX_RESTRICT y, amrex::ParticleReal &AMREX_RESTRICT t, amrex::ParticleReal &AMREX_RESTRICT px, amrex::ParticleReal &AMREX_RESTRICT py, amrex::ParticleReal &AMREX_RESTRICT pt, amrex::RandomEngine const &engine) const
 

Private Attributes

amrex::ParticleReal m_k
 
amrex::ParticleReal m_T1
 linear focusing strength (1/meters) More...
 
amrex::ParticleReal m_T2
 
amrex::ParticleReal m_normalize
 temperature of each particle population More...
 
amrex::ParticleReal m_normalize_halo
 
amrex::ParticleReal m_halo
 normalization constant of first/second population More...
 
amrex::ParticleReal m_rmin
 relative weight of halo population More...
 
amrex::ParticleReal m_rmax
 maximum r value for tabulated cdf More...
 
int m_nbins
 number of radial bins for tabulated cdf More...
 
amrex::ParticleReal m_bg
 reference value of relativistic beta*gamma More...
 
amrex::ParticleReal m_w
 weight of the secondary (halo) population More...
 
amrex::ParticleReal const * m_cdf1 = nullptr
 
amrex::ParticleReal const * m_cdf2 = nullptr
 non-owning pointer to device core CDF More...
 

Constructor & Destructor Documentation

◆ Thermal()

impactx::distribution::Thermal::Thermal ( amrex::ParticleReal  k,
amrex::ParticleReal  kT,
amrex::ParticleReal  kT_halo,
amrex::ParticleReal  normalize,
amrex::ParticleReal  normalize_halo,
amrex::ParticleReal  halo 
)
inline

A stationary Thermal or Bi-thermal distribution

Return sampling from a 6D bi-thermal distribution, a stationary solution of the Vlasov-Poisson system in an isotropic linear focusing channel.

Parameters
klinear focusing strength (1/meters)
kTtemperature k*T of the primary (core) population
kT_halotemperature k*T of the secondary (halo) population
normalizenormalization constant of first population
normalize_halonormalization constant of second population
haloweight of the secondary (halo) population

Member Function Documentation

◆ finalize()

void impactx::distribution::Thermal::finalize ( )
inline

Close and deallocate all data and handles.

◆ initialize()

void impactx::distribution::Thermal::initialize ( amrex::ParticleReal  bunch_charge,
RefPart const &  ref 
)
inline

Initialize the distribution.

This in particular sets the m_data radial profile of the stationary beam

Parameters
bunch_chargecharge of the beam in C
refthe reference particle

◆ operator()()

AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void impactx::distribution::Thermal::operator() ( amrex::ParticleReal &AMREX_RESTRICT  x,
amrex::ParticleReal &AMREX_RESTRICT  y,
amrex::ParticleReal &AMREX_RESTRICT  t,
amrex::ParticleReal &AMREX_RESTRICT  px,
amrex::ParticleReal &AMREX_RESTRICT  py,
amrex::ParticleReal &AMREX_RESTRICT  pt,
amrex::RandomEngine const &  engine 
) const
inline

Return 1 6D particle coordinate

Parameters
xparticle position in x
yparticle position in y
tparticle position in t
pxparticle momentum in x
pyparticle momentum in y
ptparticle momentum in t
enginea random number engine (with associated state)

Member Data Documentation

◆ m_bg

amrex::ParticleReal impactx::distribution::Thermal::m_bg
private

reference value of relativistic beta*gamma

◆ m_cdf1

amrex::ParticleReal const* impactx::distribution::Thermal::m_cdf1 = nullptr
private

◆ m_cdf2

amrex::ParticleReal const* impactx::distribution::Thermal::m_cdf2 = nullptr
private

non-owning pointer to device core CDF

◆ m_halo

amrex::ParticleReal impactx::distribution::Thermal::m_halo
private

normalization constant of first/second population

◆ m_k

amrex::ParticleReal impactx::distribution::Thermal::m_k
private

◆ m_nbins

int impactx::distribution::Thermal::m_nbins
private

number of radial bins for tabulated cdf

◆ m_normalize

amrex::ParticleReal impactx::distribution::Thermal::m_normalize
private

temperature of each particle population

◆ m_normalize_halo

amrex::ParticleReal impactx::distribution::Thermal::m_normalize_halo
private

◆ m_rmax

amrex::ParticleReal impactx::distribution::Thermal::m_rmax
private

maximum r value for tabulated cdf

◆ m_rmin

amrex::ParticleReal impactx::distribution::Thermal::m_rmin
private

relative weight of halo population

minimum r value for tabulated cdf

◆ m_T1

amrex::ParticleReal impactx::distribution::Thermal::m_T1
private

linear focusing strength (1/meters)

◆ m_T2

amrex::ParticleReal impactx::distribution::Thermal::m_T2
private

◆ m_w

amrex::ParticleReal impactx::distribution::Thermal::m_w
private

weight of the secondary (halo) population


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