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

Public Member Functions

subroutine set_f0_f0g_ptr (f0_inode1_new, f0_inode2_new, f0_f0g_cpp)
 
subroutine f0_mem_allocation
 
subroutine f0_initialize (grid, inode1, inode2, imu1, imu2)
 
subroutine f0_redistribute_p1 ()
 
subroutine f0_redistribute_p2 ()
 
subroutine f0_init_rest (grid)
 
subroutine prep_move_f0g_to_ptl (f0_df0g)
 
subroutine zero_out_f0_f0g (isp)
 
subroutine f0_get_f0g (grid, isp, itr, p, phi, mu_n_in, vp_n, f0g, err)
 Interpolates the grid distribution function to real space, velocity space location given by node, mu_n,vp_n. In poloidal plane it uses nearest neighbor and velocity space linear interpolation. More...
 
subroutine f0_get_f_tot (grid, isp, itr, p, phi, mu_n_in, vp_n, f0_f, f, err)
 
subroutine f0_set_ptrs (nnode, f0_delta_n_cpp, f0_delta_u_cpp, f0_delta_T_cpp)
 Sets pointers to cpp arrays for f0 arrays. More...
 
subroutine f0_update_analytic_f0 (sp_type, nrhomax, density, flow, energy)
 Updates the analytic part of the total-f distribution function by filtering the density, flow and temperature moments from the particle set. This is achieved by computing the density, temperature, and flow moments of the particle set, \(\delta n\), \(\delta T\) and \(\delta u\). This defines two Maxwellians \(f_M(n_0,u_0,T_0)\) and \(f_M(n_0+\delta n,u_0+\delta u,T_0+\delta T)\), the difference of which is subtracted from the particle weights and subsequently added to the analytic distribution function. More...
 

Public Attributes

integer f0_nmu
 
integer f0_nvp
 
real(8), dimension(:,:,:,:),
pointer 
f0_f0g
 Stores the slow varying grid part of the distribution function. More...
 
real(8) f0_smu_max
 
real(8) f0_vp_max
 
real(8) f0_dsmu
 
real(8) f0_dvp
 
integer f0_imu1
 
integer f0_imu2
 
real(8), dimension(:,:),
allocatable, target 
f0_inv_grid_vol
 
real(8), dimension(:,:),
allocatable, target 
f0_grid_vol
 
real(8), dimension(:,:),
allocatable, target 
f0_grid_vol_vonly
 
real(8), dimension(:),
allocatable, target 
f0_b_b0
 
real(8), dimension(:,:),
allocatable, target 
f0_n_ta
 
real(8), dimension(:,:),
allocatable, target 
f0_den
 
real(8), dimension(:,:),
allocatable, target 
f0_t_ev
 
real(8), dimension(:,:),
allocatable, target 
f0_flow
 
real(8), dimension(:,:),
allocatable 
f0_den_global
 
real(8), dimension(:,:),
allocatable 
f0_temp_global
 
real(kind=8), dimension(:,:,:,:,:),
allocatable, target 
temp_redistribute
 
logical f0_update_analytic =.false.
 Switch on/off the update of the analytic part of the distribution function. More...
 
logical f0_update_analytic_local =.false.
 If .false. –> flux-surface average update, .true. –> local. More...
 
real(8) f0_update_analytic_alpha =2D-3
 Separate alpha from sml_f0_grid_alpha for Maxwellian contribution. More...
 
real(8) f0_update_analytic_damp_width = 0.5D0
 For width of \(\exp^{-(x/w)^2}\) damping factor for updating density/temperature of the analytical f0. More...
 
real(8), dimension(:,:), pointer f0_delta_n
 Flux-surface averaged change of density. More...
 
real(8), dimension(:,:), pointer f0_delta_u
 Flux-surface averaged change of parallel flow. More...
 
real(8), dimension(:,:), pointer f0_delta_t
 Flux-surface averaged change of temperature. More...
 
real(kind=8), parameter f0_mu0_factor =3D0
 Set value of lowest mu in grid –> 1/f0_mu0_factor. More...
 

Private Member Functions

subroutine, private partition_intersect (l1, r1, l2, r2, nnodes, psize, partition, index, count, counts, ierror)
 
integer function, private ceil2 (n)
 
integer function, private pair (np, p, k)
 

Member Function/Subroutine Documentation

integer function, private f0_module::ceil2 ( integer  n)
private

Here is the caller graph for this function:

subroutine f0_module::f0_get_f0g ( type(grid_type)  grid,
integer, intent(in)  isp,
integer, intent(in)  itr,
real (8), dimension(3), intent(in)  p,
real (8), intent(in)  phi,
real (8), intent(in)  mu_n_in,
real (8), intent(in)  vp_n,
real (8), intent(out)  f0g,
logical, intent(out)  err 
)

Interpolates the grid distribution function to real space, velocity space location given by node, mu_n,vp_n. In poloidal plane it uses nearest neighbor and velocity space linear interpolation.

Here is the call graph for this function:

Here is the caller graph for this function:

subroutine f0_module::f0_get_f_tot ( type(grid_type)  grid,
integer, intent(in)  isp,
integer, intent(in)  itr,
real (8), dimension(3), intent(in)  p,
real (8), intent(in)  phi,
real (8), intent(in)  mu_n_in,
real (8), intent(in)  vp_n,
real (8), dimension(-f0_nvp:f0_nvp, f0_inode1:f0_inode2, f0_imu1:f0_imu2, ptl_isp:ptl_nsp), intent(in)  f0_f,
real (8), intent(out)  f,
logical, intent(out)  err 
)

Here is the call graph for this function:

subroutine f0_module::f0_init_rest ( type(grid_type)  grid)

Here is the call graph for this function:

Here is the caller graph for this function:

subroutine f0_module::f0_initialize ( type(grid_type)  grid,
integer, intent(in)  inode1,
integer, intent(in)  inode2,
integer, intent(in)  imu1,
integer, intent(in)  imu2 
)

Here is the call graph for this function:

Here is the caller graph for this function:

subroutine f0_module::f0_mem_allocation ( )

Here is the caller graph for this function:

subroutine f0_module::f0_redistribute_p1 ( )

Here is the call graph for this function:

subroutine f0_module::f0_redistribute_p2 ( )

Here is the call graph for this function:

subroutine f0_module::f0_set_ptrs ( integer  nnode,
real(8), dimension(nnode, 0:ptl_nsp), target  f0_delta_n_cpp,
real(8), dimension(nnode, 0:ptl_nsp), target  f0_delta_u_cpp,
real(8), dimension(nnode, 0:ptl_nsp), target  f0_delta_T_cpp 
)

Sets pointers to cpp arrays for f0 arrays.

Parameters
[in]nnodeNumber of mesh vertices, integer
subroutine f0_module::f0_update_analytic_f0 ( integer  sp_type,
integer  nrhomax,
real(8), dimension(grid%nnode, 0:nrhomax)  density,
real(8), dimension(grid%nnode, 0:nrhomax)  flow,
real(8), dimension(grid%nnode, 0:nrhomax)  energy 
)

Updates the analytic part of the total-f distribution function by filtering the density, flow and temperature moments from the particle set. This is achieved by computing the density, temperature, and flow moments of the particle set, \(\delta n\), \(\delta T\) and \(\delta u\). This defines two Maxwellians \(f_M(n_0,u_0,T_0)\) and \(f_M(n_0+\delta n,u_0+\delta u,T_0+\delta T)\), the difference of which is subtracted from the particle weights and subsequently added to the analytic distribution function.

Parameters
[in]gridXGC grid data structure, type(grid_type)
[in]spParticle data object, type(species_type)
[in]psnXGC field data object, type(psn_type)

Here is the call graph for this function:

integer function, private f0_module::pair ( integer  np,
integer  p,
integer  k 
)
private

Here is the caller graph for this function:

subroutine, private f0_module::partition_intersect ( integer, intent(in)  l1,
integer, intent(in)  r1,
integer, intent(in)  l2,
integer, intent(in)  r2,
integer, intent(in)  nnodes,
integer, intent(in)  psize,
integer, dimension(psize+1), intent(in)  partition,
integer, dimension(psize), intent(out)  index,
integer, dimension(psize), intent(out)  count,
integer, intent(out)  counts,
integer, intent(out)  ierror 
)
private

Here is the caller graph for this function:

subroutine f0_module::prep_move_f0g_to_ptl ( real (8), dimension(-f0_nvp:f0_nvp, f0_inode1:f0_inode2, f0_imu1:f0_imu2, ptl_isp:ptl_nsp), intent(out)  f0_df0g)
subroutine f0_module::set_f0_f0g_ptr ( integer  f0_inode1_new,
integer  f0_inode2_new,
real(8), dimension(-f0_nvp:f0_nvp, f0_inode1_new:f0_inode2_new, 0:f0_nmu, ptl_isp:ptl_nsp), target  f0_f0g_cpp 
)
subroutine f0_module::zero_out_f0_f0g ( integer  isp)

Member Data Documentation

real (8), dimension(:), allocatable, target f0_module::f0_b_b0
real (8), dimension(:,:), pointer f0_module::f0_delta_n

Flux-surface averaged change of density.

real (8), dimension(:,:), pointer f0_module::f0_delta_t

Flux-surface averaged change of temperature.

real (8), dimension(:,:), pointer f0_module::f0_delta_u

Flux-surface averaged change of parallel flow.

real (8), dimension(:,:), allocatable, target f0_module::f0_den
real (8), dimension(:,:), allocatable f0_module::f0_den_global
real (8) f0_module::f0_dsmu
real (8) f0_module::f0_dvp
real (8), dimension(:,:,:,:), pointer f0_module::f0_f0g

Stores the slow varying grid part of the distribution function.

real (8), dimension(:,:), allocatable, target f0_module::f0_flow
real (8), dimension(:,:), allocatable, target f0_module::f0_grid_vol
real (8), dimension(:,:), allocatable, target f0_module::f0_grid_vol_vonly
integer f0_module::f0_imu1
integer f0_module::f0_imu2
real (8), dimension(:,:), allocatable, target f0_module::f0_inv_grid_vol
real (kind=8), parameter f0_module::f0_mu0_factor =3D0

Set value of lowest mu in grid –> 1/f0_mu0_factor.

real (8), dimension(:,:), allocatable, target f0_module::f0_n_ta
integer f0_module::f0_nmu
integer f0_module::f0_nvp
real (8) f0_module::f0_smu_max
real (8), dimension(:,:), allocatable, target f0_module::f0_t_ev
real (8), dimension(:,:), allocatable f0_module::f0_temp_global
logical f0_module::f0_update_analytic =.false.

Switch on/off the update of the analytic part of the distribution function.

real (8) f0_module::f0_update_analytic_alpha =2D-3

Separate alpha from sml_f0_grid_alpha for Maxwellian contribution.

real (8) f0_module::f0_update_analytic_damp_width = 0.5D0

For width of \(\exp^{-(x/w)^2}\) damping factor for updating density/temperature of the analytical f0.

logical f0_module::f0_update_analytic_local =.false.

If .false. –> flux-surface average update, .true. –> local.

real (8) f0_module::f0_vp_max
real (kind=8), dimension(:,:,:,:,:), allocatable, target f0_module::temp_redistribute

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