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_decomposed_arrays (f0_T_ev_cpp, f0_inv_grid_vol_cpp, f0_grid_vol_cpp, f0_grid_vol_vonly_cpp, f0_n_Ta_cpp, f0_den_cpp, f0_flow_cpp, f0_B_B0_cpp) |
subroutine | f0_init_global_arrays (f0_den_global_cpp, f0_temp_global_cpp) |
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 | reset_f0_f |
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... | |
subroutine | get_f0_density (den, isp) |
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(:,:), pointer | f0_inv_grid_vol |
real(8), dimension(:,:), pointer | f0_grid_vol |
real(8), dimension(:,:), pointer | f0_grid_vol_vonly |
real(8), dimension(:), pointer | f0_b_b0 |
real(8), dimension(:,:), pointer | f0_n_ta |
real(8), dimension(:,:), pointer | f0_den |
real(8), dimension(:,:), pointer | f0_t_ev |
real(8), dimension(:,:), pointer | f0_flow |
real(8), dimension(:,:), pointer | f0_den_global |
real(8), dimension(:,:), pointer | 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) |
|
private |
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.
subroutine f0_module::f0_init_decomposed_arrays | ( | real(8), dimension(f0_inode1:f0_inode2, ptl_isp:ptl_nsp), target | f0_T_ev_cpp, |
real(8), dimension(f0_inode1:f0_inode2, ptl_isp:ptl_nsp), target | f0_inv_grid_vol_cpp, | ||
real(8), dimension(f0_inode1:f0_inode2, ptl_isp:ptl_nsp), target | f0_grid_vol_cpp, | ||
real(8), dimension(f0_inode1:f0_inode2, ptl_isp:ptl_nsp), target | f0_grid_vol_vonly_cpp, | ||
real(8), dimension(f0_inode1:f0_inode2, ptl_isp:ptl_nsp), target | f0_n_Ta_cpp, | ||
real(8), dimension(f0_inode1:f0_inode2, ptl_isp:ptl_nsp), target | f0_den_cpp, | ||
real(8), dimension(f0_inode1:f0_inode2, ptl_isp:ptl_nsp), target | f0_flow_cpp, | ||
real(8), dimension(f0_inode1:f0_inode2), target | f0_B_B0_cpp | ||
) |
subroutine f0_module::f0_init_global_arrays | ( | real(8), dimension(grid%nnode, ptl_isp:ptl_nsp), target | f0_den_global_cpp, |
real(8), dimension(grid%nnode, ptl_isp:ptl_nsp), target | f0_temp_global_cpp | ||
) |
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 | ||
) |
subroutine f0_module::f0_mem_allocation | ( | ) |
subroutine f0_module::f0_redistribute_p1 | ( | ) |
subroutine f0_module::f0_redistribute_p2 | ( | ) |
subroutine f0_module::f0_set_ptrs | ( | integer | nnode, |
real(8), dimension(nnode, ptl_isp:ptl_nsp), target | f0_delta_n_cpp, | ||
real(8), dimension(nnode, ptl_isp:ptl_nsp), target | f0_delta_u_cpp, | ||
real(8), dimension(nnode, ptl_isp:ptl_nsp), target | f0_delta_T_cpp | ||
) |
Sets pointers to cpp arrays for f0 arrays.
[in] | nnode | Number 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.
[in] | grid | XGC grid data structure, type(grid_type) |
[in] | sp | Particle data object, type(species_type) |
[in] | psn | XGC field data object, type(psn_type) |
subroutine f0_module::get_f0_density | ( | real(8), dimension(f0_inode1:f0_inode2) | den, |
integer | isp | ||
) |
|
private |
|
private |
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::reset_f0_f | ( | ) |
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 | ) |
real (8), dimension(:), pointer 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(:,:), pointer f0_module::f0_den |
real (8), dimension(:,:), pointer 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(:,:), pointer f0_module::f0_flow |
real (8), dimension(:,:), pointer f0_module::f0_grid_vol |
real (8), dimension(:,:), pointer f0_module::f0_grid_vol_vonly |
integer f0_module::f0_imu1 |
integer f0_module::f0_imu2 |
real (8), dimension(:,:), pointer 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(:,:), pointer 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(:,:), pointer f0_module::f0_t_ev |
real (8), dimension(:,:), pointer 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 |