PB3D [2.47]
Ideal linear high-n MHD stability in 3-D
Loading...
Searching...
No Matches
num_vars.f90 File Reference

Go to the source code of this file.

Modules

module  num_vars
 Numerical variables used by most other modules.

Variables

integer, parameter, public num_vars::dp = REAL64
 double precision
integer, parameter, public num_vars::dpi = INT64
 double precision
real(dp), parameter, public num_vars::weight_dp = 0.008
 size of double precision in kB
integer, parameter, public num_vars::max_str_ln = 120
 maximum length of strings
integer, parameter, public num_vars::max_name_ln = 30
 maximum length of filenames
integer, parameter, public num_vars::max_deriv = 2
 highest derivatives for metric factors in Flux coords.
integer, public num_vars::prog_style
 program style (1: PB3D, 2: PB3D_POST)
character(len=4), public num_vars::prog_name
 name of program, used for info
character(len=3), parameter, public num_vars::output_name = 'out'
 name of output file
character(len=14), parameter, public num_vars::shell_commands_name = 'shell_commands'
 name of shell commands file
character(len=9), parameter, public num_vars::mem_usage_name = 'mem_usage'
 name of memory usage file
integer, public num_vars::mem_usage_count
 counter for memory usage output
real(dp), parameter, public num_vars::prog_version = 2.47_dp
 version number
real(dp), parameter, public num_vars::min_pb3d_version = 2.43_dp
 minimum PB3D version for POST
logical, public num_vars::debug_version = .true.
 debug version used
integer, public num_vars::rank
 MPI rank.
integer, public num_vars::n_procs
 nr. of MPI processes
integer, public num_vars::sol_n_procs
 nr. of MPI processes for solution with SLEPC
integer(kind=8), public num_vars::time_start
 start time of simulation
real(dp), public num_vars::max_tot_mem
 maximum total memory for all processes [MB]
real(dp), public num_vars::max_x_mem
 maximum memory for perturbation calculations for all processes [MB]
integer, dimension(:,:), allocatable, public num_vars::x_jobs_lims
 data about X jobs: [ \(\min_k\), \(\max_k\), \(\min_m\), \(\max_m\)] for all jobs
integer, dimension(:,:), allocatable, public num_vars::eq_jobs_lims
 data about eq jobs: [ \(\min_\theta\), \(\max_\theta\)] for all jobs
integer, public num_vars::x_job_nr
 nr. of X job
integer, public num_vars::eq_job_nr
 nr. of eq job
real(dp), parameter, public num_vars::mem_scale_fac = 6.0
 empirical scale factor of memory to calculate eq compared to just storing it
real(dp), parameter, public num_vars::pi =4_dp*datan(1.0_dp)
 \(\pi\)
real(dp), parameter, public num_vars::mu_0_original = 4E-7_dp*pi
 permeability of free space
complex(dp), parameter, public num_vars::iu = (0, 1)
 complex unit
integer, public num_vars::ev_style
 determines the method used for solving an EV problem
integer, public num_vars::eq_style
 either 1 (VMEC) or 2 (HELENA)
integer, public num_vars::rho_style
 style for equilibrium density profile
integer, public num_vars::u_style
 style for calculation of U (1: ord.2, 2: ord.1, 1: ord.0)
integer, public num_vars::norm_style
 style for normalization
integer, public num_vars::k_style
 style for kinetic energy
integer, dimension(2), public num_vars::bc_style
 style for BC left and right
integer, public num_vars::x_style
 style for secondary mode numbers (1: prescribed, 2: fast)
integer, public num_vars::matrix_slepc_style
 style for matrix storage (1: sparse, 2: shell)
integer, public num_vars::solver_slepc_style
 style for solver (1: Krylov-Schur, 2: GD)
integer, public num_vars::post_style
 style for POST (1: extended grid, 2: B-aligned grid)
integer, public num_vars::x_grid_style
 style for normal component of X grid (1: eq, 2: sol, 3: enriched)
integer, public num_vars::alpha_style
 style for alpha (1: one field line, many turns, 2: many field lines, one turn)
integer, public num_vars::max_it_slepc
 maximum nr. of iterations for SLEPC
logical, public num_vars::plot_resonance
 whether to plot the q-profile or iota-profile with resonances
logical, public num_vars::plot_magn_grid
 whether to plot the grid in real coordinates
logical, public num_vars::plot_b
 whether to plot the magnetic field in real coordinates
logical, public num_vars::plot_j
 whether to plot the current in real coordinates
logical, public num_vars::plot_flux_q
 whether to plot flux quantities in real coordinates
logical, public num_vars::plot_kappa
 whether to plot curvature
logical, public num_vars::plot_sol_xi
 whether to plot plasma perturbation of solution in POST
logical, public num_vars::plot_sol_q
 whether to plot magnetic perturbation of solution in POST
logical, public num_vars::plot_vac_pot
 whether to plot vacuum potential in POST
logical, public num_vars::plot_e_rec
 whether to plot energy reconstruction in POST
logical, public num_vars::ltest
 whether or not to call the testing routines
logical, public num_vars::use_pol_flux_e
 whether poloidal flux is used in E coords.
logical, public num_vars::use_pol_flux_f
 whether poloidal flux is used in F coords.
logical, public num_vars::use_normalization
 whether to use normalization or not
real(dp), public num_vars::ev_bc
 value of artificial Eigenvalue for boundary condition
real(dp), public num_vars::ev_guess
 first guess for eigenvalue
real(dp), dimension(:), allocatable, public num_vars::tol_slepc
 tolerance for SLEPC for different Richardson levels
real(dp), public num_vars::max_njq_change
 maximum change of prim. mode number times saf. fac. / rot. transf. when using X_style 2 (fast)
integer, public num_vars::norm_disc_prec_eq
 precision for normal discretization for equilibrium
integer, public num_vars::norm_disc_prec_x
 precision for normal discretization for perturbation
integer, public num_vars::norm_disc_prec_sol
 precision for normal discretization for solution
integer, public num_vars::norm_disc_style_sol
 style for normal discretization for solution (1: central fin. diff., 2: left fin. diff.)
integer, public num_vars::magn_int_style
 style for magnetic integrals (1: trapezoidal, 2: Simpson 3/8)
integer, public num_vars::max_it_rich
 number of levels for Richardson extrapolation
real(dp), public num_vars::tol_rich
 tolerance for Richardson extrapolation
integer, public num_vars::max_it_zero
 maximum number of iterations to find zeros
integer, public num_vars::max_nr_backtracks_hh
 maximum number of backtracks for Householder, relax. factors
real(dp), public num_vars::tol_zero
 tolerance for zeros
real(dp), public num_vars::tol_norm
 tolerance for normal range (normalized to 0..1)
integer, parameter, public num_vars::ex_max_size = 10000
 maximum size of matrices for external plot
character(len=max_str_ln), public num_vars::eq_name
 name of equilibrium file from VMEC or HELENA
character(len=max_str_ln), public num_vars::pb3d_name
 name of PB3D output file
logical, public num_vars::no_plots = .false.
 no plots made
logical, public num_vars::jump_to_sol = .false.
 jump to solution
logical, public num_vars::export_hel = .false.
 export HELENA
logical, public num_vars::plot_vmec_modes = .false.
 plot VMEC modes
logical, public num_vars::invert_top_bottom_h = .false.
 invert top and bottom for HELENA equilibria
logical, public num_vars::no_output = .false.
 no output shown
logical, public num_vars::post_output_full = .false.
 POST has output on full grids.
logical, public num_vars::post_output_sol = .false.
 POST has outputs of solution.
logical, public num_vars::do_execute_command_line = .false.
 call "execute_command_line" inside program
logical, public num_vars::print_mem_usage = .false.
 print memory usage is printed
logical, public num_vars::swap_angles = .false.
 swap angles theta and zeta in plots (only for POST)
logical, public num_vars::compare_tor_pos = .false.
 compare quantities at toroidal positions (only for POST)
logical, public num_vars::retain_all_sol
 retain also faulty solutions
character(len=5), public num_vars::plot_dir = 'Plots'
 directory where to save plots
character(len=7), public num_vars::script_dir = 'Scripts'
 directory where to save scripts for plots
character(len=4), public num_vars::data_dir = 'Data'
 directory where to save data for plots
integer, public num_vars::n_theta_plot
 nr. of poloidal points in plot
integer, public num_vars::n_zeta_plot
 nr. of toroidal points in plot
integer, dimension(2), public num_vars::n_vac_plot
 nr. of points in R and Z in vacuum
real(dp), public num_vars::min_theta_plot
 min. of theta_plot
real(dp), public num_vars::max_theta_plot
 max. of theta_plot
real(dp), public num_vars::min_zeta_plot
 min. of zeta_plot
real(dp), public num_vars::max_zeta_plot
 max. of zeta_plot
real(dp), public num_vars::min_r_plot
 min. of r_plot
real(dp), public num_vars::max_r_plot
 max. of r_plot
real(dp), public num_vars::min_rvac_plot
 min. of R in which to plot vacuum
real(dp), public num_vars::max_rvac_plot
 max. of R in which to plot vacuum
real(dp), public num_vars::min_zvac_plot
 min. of Z in which to plot vacuum
real(dp), public num_vars::max_zvac_plot
 max. of Z in which to plot vacuum
integer, public num_vars::plot_grid_style
 style for POST plot grid (0: 3-D plots, 1: slab plots, 2: slab plots with folding, 3: straight cylinder))
integer, public num_vars::n_sol_requested
 how many solutions requested
integer, dimension(4), public num_vars::n_sol_plotted
 how many solutions to be plot (first unstable, last unstable, first stable, last stable)
integer, dimension(2), public num_vars::plot_size
 size of plot in inches
integer, public num_vars::rich_restart_lvl
 starting Richardson level (0: none [default])
character(len=max_str_ln), public num_vars::input_name
 will hold the full name of the input file
integer, public num_vars::ex_plot_style
 external plot style (1: GNUPlot, 2: Bokeh for 2D, Mayavi for 3D)
real(dp), public num_vars::pert_mult_factor_post
 factor with which to multiply perturbation strength for POST
real(dp), dimension(2), public num_vars::rz_0
 origin of geometrical poloidal coordinate
integer, parameter, public num_vars::input_i = 50
 file number of input file
integer, parameter, public num_vars::eq_i = 51
 file number of equilibrium file from VMEC or HELENA
integer, parameter, public num_vars::pb3d_i = 52
 file number of PB3D output file
integer, parameter, public num_vars::output_i = 53
 file number of output file
integer, parameter, public num_vars::shell_commands_i = 54
 file number of shell commands file
integer, parameter, public num_vars::mem_usage_i = 55
 file number of memory usage file
integer, parameter, public num_vars::output_ev_i = 56
 file number of output of EV
integer, parameter, public num_vars::decomp_i = 57
 file number of output of EV decomposition
integer, parameter, public num_vars::hel_export_i = 59
 file number of output of HELENA equilibrium export file
integer, parameter, public num_vars::hel_pert_i = 58
 file number of HELENA equilibrium perturbation file
integer, parameter, public num_vars::prop_b_tor_i = 60
 file number of \(B_\phi\) proportionality factor file