XGC1
Data Types | Modules | Functions/Subroutines | Variables
search.F90 File Reference
#include "adios_macro.h"
#include "t_coeff_mod_macro.h"
#include "fftw3.f"
Include dependency graph for search.F90:

Data Types

type  grid_class::grid_type
 

Modules

module  grid_class
 

Functions/Subroutines

subroutine grid_class::init_fortran_grid (grid_nnode_in, grid_ntriangle_in, grid_x_in, grid_rgn_in, grid_nd_in, grid_mapping_in, basis_in)
 
subroutine grid_class::init_fortran_grid_surf (n_xpt, i_x1, i_x2, nsurf1, nsurf2, nsurf3a, nsurf3b, isurf_sep1, isurf_sep2, npsi_surf, surf_maxlen, surf_len, surf_idx)
 
subroutine grid_class::init_fortran_grid_filter_arrays (npsi_surf, surf_maxlen, theta_sort_idx, m_max_surf)
 
subroutine grid_class::init_fortran_grid_theta_qsafety (nnode, npsi_surf, theta, qsafety)
 
subroutine grid_class::init_secondary_grid_arrays (grid_psi_in, grid_grad_psi_in, grid_bfield_in)
 
subroutine grid_class::init_guess_table_from_cpp (guess_n1, guess_list_len, guess_n_in, guess_min_in, guess_max_in, inv_guess_d_in, guess_list_in, guess_xtable_in, guess_count_in)
 
subroutine grid_class::init_fortran_vols_and_areas (tr_area_h, tr_vol_h, node_vol_ff_h, node_vol_nearest_h, node_vol_h, node_area_h)
 
subroutine grid_class::init_fortran_psi_grid_props (npsi_surf, psi_surf, npsi_surf2, psi_surf2, psi_surf_map)
 
subroutine grid_class::alloc_fortran_gradient_mat_unit_vec (m, n, width)
 
subroutine grid_class::init_grid (grid)
 Initializes the grid data structure from input files containing i) The (R,Z) coordinates of all vertices including whether they are wall vertices (.node file), ii) the connectivity of the vertices defining the triangles of the unstructured mesh (.ele file), iii) the flux-surface connectivity, i.e. which vertices are on the same flux-surface, and for vertices not aligned on flux-surfaces between which flux-surfaces those vertices lie. More...
 
subroutine grid_class::init_triangle (grid)
 
subroutine grid_class::t_coeff (grid, itr, x, p)
 
subroutine grid_class::t_coeff_mod (grid, xy, psiin, itr, p)
 
subroutine grid_class::calc_gen_theta_psi (grid)
 Calculates the average psi on the complete flux-surfaces and the generalized poloidal angle (=normalized poloidal arc length) More...
 
subroutine order_nodes (grid, isurf, isize, idx_start, theta, idx)
 Sorts input SOL flux-surface according to the poloidal arclength l_theta where l_theta=0 at the outer midplane. More...
 
subroutine gen_pol_angle_single (i)
 
integer function grid_class::get_nsurfs_for_avg ()
 
subroutine get_b_and_derivs_cyl (r, z, B_mag, br, bphi, bz, dbrdr, dbpdr, dbzdr, dbrdp, dbpdp, dbzdp, dbrdz, dbpdz, dbzdz)
 
subroutine get_pe_info (mype, totalpe)
 
subroutine search_tr2 (grid, xy, itr, p)
 
subroutine search_tr_check_guess (grid, x, init, itr, p)
 
subroutine write_gradient_mat (grid)
 
real(kind=8) function fourier_filter_damp_fac (psi, inpsi, outpsi, bd_width)
 Evaluate a damping factor for the boundary condition of the Fourier filter functions. More...
 

Variables

integer, parameter grid_class::grid_rgn_wall = 100
 
real(8), parameter grid_class::grid_search_tr2_psi_null = -1D10
 
integer, parameter grid_class::grid_min_surf_size = 5
 
type(grid_type), target grid_class::grid_global
 

Function/Subroutine Documentation

◆ fourier_filter_damp_fac()

real (kind=8) function fourier_filter_damp_fac ( real (kind=8), intent(in)  psi,
real (kind=8), intent(in)  inpsi,
real (kind=8), intent(in)  outpsi,
real (kind=8), intent(in)  bd_width 
)

Evaluate a damping factor for the boundary condition of the Fourier filter functions.

Parameters
[in]psiInput poloidal flux, real(8)
[in]inpsiInner filter boundary, real(8)
[in]outpsiOuter filter boundary, real(8)
[in]bd_widthBoundary width, real(8)
Here is the caller graph for this function:

◆ gen_pol_angle_single()

subroutine calc_gen_theta_psi::gen_pol_angle_single ( integer, intent(in)  i)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_b_and_derivs_cyl()

subroutine get_b_and_derivs_cyl ( real(kind=8), intent(in)  r,
real(kind=8), intent(in)  z,
real(kind=8), intent(out)  B_mag,
real(kind=8), intent(out)  br,
real(kind=8), intent(out)  bphi,
real(kind=8), intent(out)  bz,
real(kind=8), intent(out)  dbrdr,
real(kind=8), intent(out)  dbpdr,
real(kind=8), intent(out)  dbzdr,
real(kind=8), intent(out)  dbrdp,
real(kind=8), intent(out)  dbpdp,
real(kind=8), intent(out)  dbzdp,
real(kind=8), intent(out)  dbrdz,
real(kind=8), intent(out)  dbpdz,
real(kind=8), intent(out)  dbzdz 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_pe_info()

subroutine get_pe_info ( integer  mype,
integer  totalpe 
)

◆ order_nodes()

subroutine calc_gen_theta_psi::order_nodes ( type(grid_type), intent(in)  grid,
integer, intent(in)  isurf,
integer, intent(in)  isize,
integer, intent(in)  idx_start,
real (kind=8), dimension(isize), intent(out)  theta,
integer, dimension(isize), intent(out)  idx 
)

Sorts input SOL flux-surface according to the poloidal arclength l_theta where l_theta=0 at the outer midplane.

Parameters
[in]gridgrid data; type(grid_type)
[in]isurfflux-surface index; integer
[in]isizelength of the flux-surface; integer @apram[out] theta output arclength; real(8)
[out]idxoutput sort index; integer
Here is the caller graph for this function:

◆ search_tr2()

subroutine search_tr2 ( type(grid_type grid,
real(kind=8), dimension(2)  xy,
integer  itr,
real(kind=8), dimension(3)  p 
)
Here is the caller graph for this function:

◆ search_tr_check_guess()

subroutine search_tr_check_guess ( type(grid_type), intent(in)  grid,
real (kind=8), dimension(2), intent(in)  x,
integer, intent(in)  init,
integer, intent(out)  itr,
real (kind=8), dimension(3), intent(out)  p 
)
Here is the call graph for this function:

◆ write_gradient_mat()

subroutine write_gradient_mat ( type (grid_type), intent(inout)  grid)
Here is the call graph for this function:
Here is the caller graph for this function: