XGCa
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Classes | Public Types | Public Member Functions | Public Attributes | Private Member Functions | Private Attributes | List of all members
Plasma Class Reference

#include <plasma.hpp>

Collaboration diagram for Plasma:
Collaboration graph
[legend]

Classes

struct  DecomposedRecalculableF0Arrays
 

Public Types

enum  DevicePtlOpt { UseDevicePtl =0, NoDevicePtl }
 
enum  ParticleType { Electrons =0, Ions }
 

Public Member Functions

 Plasma ()
 
 Plasma (NLReader::NamelistReader &nlr, const Simulation< DeviceType > &sml, const DomainDecomposition< DeviceType > &pol_decomp, const VelocityGrid &vgrid)
 
template<typename F >
void for_all_species (F func, DevicePtlOpt device_ptl_opt=UseDevicePtl)
 
template<typename F >
void for_all_nonadiabatic_species (F func, DevicePtlOpt device_ptl_opt=UseDevicePtl)
 
template<typename F >
void for_electrons (F func, DevicePtlOpt device_ptl_opt=UseDevicePtl)
 
template<typename F >
void for_all_ions (F func, DevicePtlOpt device_ptl_opt=UseDevicePtl)
 
template<typename F >
void for_all (ParticleType particle_type, F func, DevicePtlOpt device_ptl_opt=UseDevicePtl)
 
template<typename F >
void for_one_species (int isp, F func, DevicePtlOpt device_ptl_opt=UseDevicePtl)
 
int largest_n_ptl (bool check_backup)
 
void deallocate_device_ptl ()
 
void update_decomposed_f0_calculations (const DomainDecomposition< DeviceType > &pol_decomp)
 
void resize_f0_f0g (const DomainDecomposition< DeviceType > &pol_decomp, const VelocityGrid &vgrid)
 

Public Attributes

std::vector< Species
< DeviceType > > 
all_species
 Every particle species in the simulation. More...
 
VGridDistribution< HostTypef0_f0g
 
DecomposedRecalculableF0Arrays decomposed_recalculable_f0_arrays
 Contains f0 values that are poloidally decomposed but don't need to be transferred between ranks during load rebalancing. More...
 
Kokkos::View< double
**, Kokkos::LayoutRight,
HostType
f0_delta_n
 Flux-surface averaged change of density. More...
 
Kokkos::View< double
**, Kokkos::LayoutRight,
HostType
f0_delta_u
 Flux-surface averaged change of parallel flow. More...
 
Kokkos::View< double
**, Kokkos::LayoutRight,
HostType
f0_delta_T
 Flux-surface averaged change of temperature. More...
 
View< double **, CLayout,
HostType
f0_den_global
 Equilibrium density at vertices. More...
 
View< double **, CLayout,
HostType
f0_temp_global
 Equilibrium temperature at vertices. More...
 
int nspecies
 Number of species including electrons. More...
 
int n_nonadiabatic_species
 Number of nonadiabatic species. More...
 

Private Member Functions

void init_global_f0_arrays (int grid_nnode, bool is_XGCa)
 
template<typename T_in , typename T_out >
void set_unmanaged_f0_species_view (const T_in &view_in, int isp, T_out &view_out)
 
void transfer_particles_d_ownership (int isp)
 
void manage_particle_ownership (int isp, DevicePtlOpt device_ptl_opt)
 

Private Attributes

bool species_share_particles_d_ownership
 Whether to use the device particles sharing scheme. More...
 
bool particles_d_has_owner
 Whether a species owns the device particles allocation. More...
 
int particles_d_owner
 Which species, if any, owns the device particles allocation. More...
 

Member Enumeration Documentation

Enumerator
UseDevicePtl 
NoDevicePtl 
Enumerator
Electrons 
Ions 

Constructor & Destructor Documentation

Plasma::Plasma ( )
inline
Plasma::Plasma ( NLReader::NamelistReader nlr,
const Simulation< DeviceType > &  sml,
const DomainDecomposition< DeviceType > &  pol_decomp,
const VelocityGrid vgrid 
)
inline

Here is the call graph for this function:

Member Function Documentation

void Plasma::deallocate_device_ptl ( )
inline

Here is the caller graph for this function:

template<typename F >
void Plasma::for_all ( ParticleType  particle_type,
func,
DevicePtlOpt  device_ptl_opt = UseDevicePtl 
)
inline

Here is the call graph for this function:

Here is the caller graph for this function:

template<typename F >
void Plasma::for_all_ions ( func,
DevicePtlOpt  device_ptl_opt = UseDevicePtl 
)
inline

Here is the call graph for this function:

template<typename F >
void Plasma::for_all_nonadiabatic_species ( func,
DevicePtlOpt  device_ptl_opt = UseDevicePtl 
)
inline

Here is the call graph for this function:

Here is the caller graph for this function:

template<typename F >
void Plasma::for_all_species ( func,
DevicePtlOpt  device_ptl_opt = UseDevicePtl 
)
inline

Here is the call graph for this function:

Here is the caller graph for this function:

template<typename F >
void Plasma::for_electrons ( func,
DevicePtlOpt  device_ptl_opt = UseDevicePtl 
)
inline

Here is the call graph for this function:

Here is the caller graph for this function:

template<typename F >
void Plasma::for_one_species ( int  isp,
func,
DevicePtlOpt  device_ptl_opt = UseDevicePtl 
)
inline

Here is the call graph for this function:

Here is the caller graph for this function:

void Plasma::init_global_f0_arrays ( int  grid_nnode,
bool  is_XGCa 
)
inlineprivate

Here is the call graph for this function:

Here is the caller graph for this function:

int Plasma::largest_n_ptl ( bool  check_backup)
inline

Here is the call graph for this function:

Here is the caller graph for this function:

void Plasma::manage_particle_ownership ( int  isp,
DevicePtlOpt  device_ptl_opt 
)
inlineprivate

Here is the caller graph for this function:

void Plasma::resize_f0_f0g ( const DomainDecomposition< DeviceType > &  pol_decomp,
const VelocityGrid vgrid 
)
inline

Here is the call graph for this function:

Here is the caller graph for this function:

template<typename T_in , typename T_out >
void Plasma::set_unmanaged_f0_species_view ( const T_in &  view_in,
int  isp,
T_out &  view_out 
)
inlineprivate

Here is the call graph for this function:

void Plasma::transfer_particles_d_ownership ( int  isp)
inlineprivate
void Plasma::update_decomposed_f0_calculations ( const DomainDecomposition< DeviceType > &  pol_decomp)
inline

Here is the caller graph for this function:

Member Data Documentation

std::vector<Species<DeviceType> > Plasma::all_species

Every particle species in the simulation.

DecomposedRecalculableF0Arrays Plasma::decomposed_recalculable_f0_arrays

Contains f0 values that are poloidally decomposed but don't need to be transferred between ranks during load rebalancing.

Kokkos::View<double**,Kokkos::LayoutRight, HostType> Plasma::f0_delta_n

Flux-surface averaged change of density.

Kokkos::View<double**,Kokkos::LayoutRight, HostType> Plasma::f0_delta_T

Flux-surface averaged change of temperature.

Kokkos::View<double**,Kokkos::LayoutRight, HostType> Plasma::f0_delta_u

Flux-surface averaged change of parallel flow.

View<double**,CLayout, HostType> Plasma::f0_den_global

Equilibrium density at vertices.

VGridDistribution<HostType> Plasma::f0_f0g
View<double**,CLayout, HostType> Plasma::f0_temp_global

Equilibrium temperature at vertices.

int Plasma::n_nonadiabatic_species

Number of nonadiabatic species.

int Plasma::nspecies

Number of species including electrons.

bool Plasma::particles_d_has_owner
private

Whether a species owns the device particles allocation.

int Plasma::particles_d_owner
private

Which species, if any, owns the device particles allocation.

bool Plasma::species_share_particles_d_ownership
private

Whether to use the device particles sharing scheme.


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