MFC
Exascale flow solver
Loading...
Searching...
No Matches
m_global_parameters.fpp.f90
Go to the documentation of this file.
1# 1 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
2!>
3!! @file
4!! @brief Contains module m_global_parameters
5
6# 1 "/home/runner/work/MFC/MFC/src/common/include/case.fpp" 1
7! This file exists so that Fypp can be run without generating case.fpp files for
8! each target. This is useful when generating documentation, for example. This
9! should also let MFC be built with CMake directly, without invoking mfc.sh.
10
11! For pre-process.
12# 8 "/home/runner/work/MFC/MFC/src/common/include/case.fpp"
13
14! For moving immersed boundaries in simulation
15# 12 "/home/runner/work/MFC/MFC/src/common/include/case.fpp"
16# 6 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp" 2
17
18!> @brief Global parameters for the post-process: domain geometry, equation of state, and output database settings
20
21#ifdef MFC_MPI
22 use mpi !< message passing interface (mpi) module
23#endif
24
27 use m_thermochem, only: species_names
29 ! Shared state: generated_decls, num_dims, num_vels, sys_size, eqn_idx, chemistry, shear_*
31
32 implicit none
33
34 !> @name Logistics
35 !> @{
36 integer :: num_procs !< Number of processors
37 !> @}
38
39 ! Computational Domain Parameters
40
41 integer :: proc_rank !< Rank of the local processor
42 !> @name Number of cells in the x-, y- and z-coordinate directions
43 !> @{
44 integer :: m_root
45 !> @}
46
47 !> @name Max and min number of cells in a direction of each combination of x-,y-, and z-
49 integer(kind=8) :: nglobal !< Total number of cells in global domain
50
51 !> @name Cylindrical coordinates (either axisymmetric or full 3D)
52 !> @{
53 integer :: grid_geometry
54 !> @}
55
56 !> @name Global number of cells in each direction
57 !> @{
58 integer :: m_glb, n_glb, p_glb
59 !> @}
60
61 ! num_dims, num_vels: in m_global_parameters_common
62 !> @name Cell-boundary locations in the x-, y- and z-coordinate directions
63 !> @{
64 real(wp), allocatable, dimension(:) :: x_cb, x_root_cb, y_cb, z_cb
65 !> @}
66
67 !> @name Cell-center locations in the x-, y- and z-coordinate directions
68 !> @{
69 real(wp), allocatable, dimension(:) :: x_cc, x_root_cc, y_cc, z_cc
70 real(sp), allocatable, dimension(:) :: x_root_cc_s, x_cc_s
71 !> @}
72
73 !> Cell-width distributions in the x-, y- and z-coordinate directions
74 !> @{
75 real(wp), allocatable, dimension(:) :: dx, dy, dz
76 !> @}
77
78 integer :: buff_size !< Number of ghost cells for boundary condition storage
79 !> @name IO options for adaptive time-stepping
80 !> @{
81 logical :: cfl_dt
82 integer :: n_save
83 !> @}
84
85 ! NOTE: m_root, x_root_cb, x_root_cc = defragmented grid (1D only; equals m, x_cb, x_cc in serial)
86
87 !> @name Simulation Algorithm Parameters
88 !> @{
89 ! sys_size, chemistry, eqn_idx: in m_global_parameters_common
90 !> @}
91
92 !> @name Annotations of the structure, i.e. the organization, of the state vectors
93 !> @{
94 type(qbmm_idx_info) :: qbmm_idx !< QBMM moment index mappings.
95 integer :: beta_idx !< Index of lagrange bubbles beta
96 !> @}
97
98 ! Cell Indices for the (local) interior points (O-m, O-n, 0-p). Stands for "InDices With BUFFer".
99 type(int_bounds_info) :: idwint(1:3)
100
101 ! Cell indices (InDices With BUFFer): includes buffer in simulation only
103 logical :: bc_io
104 !> @name Boundary conditions in the x-, y- and z-coordinate directions
105 !> @{
108 !> @}
109
110 ! shear_num, shear_indices, shear_BC_flip_num, shear_BC_flip_indices: in m_global_parameters_common
111 ! proc_coords, start_idx, mpiiofs, mpi_info_int: in m_global_parameters_common
112 type(int_bounds_info), dimension(3) :: nidx !< Neighbor index offsets per direction (#1290 decomposition)
113 integer, allocatable, dimension(:,:,:) :: neighbor_ranks !< MPI ranks of neighbors (#1290 decomposition)
114 type(ib_airfoil_parameters), allocatable, dimension(:) :: ib_airfoil !< Per-airfoil NACA parameters (unused in post_process)
115 !> Per-airfoil computed surface grids (unused in post_process)
116 type(ib_airfoil_grid), allocatable, dimension(:) :: ib_airfoil_grids
117
118#ifdef MFC_MPI
119 type(mpi_io_var), public :: mpi_io_data
123 real(wp), allocatable, dimension(:,:), public :: mpi_io_data_lg_bubbles
124#endif
125
126 ! fluid_pp, bub_pp: auto-generated in generated_decls.fpp
127 real(wp), allocatable, dimension(:) :: adv !< Advection variables
128 ! Formatted Database File(s) Structure Parameters
129
130 type(bounds_info) :: x_output, y_output, z_output !< Portion of domain to output for post-processing
131 type(int_bounds_info) :: x_output_idx, y_output_idx, z_output_idx !< Indices of domain to output for post-processing
132 !> @name Size of the ghost zone layer in the x-, y- and z-coordinate directions. The definition of the ghost zone layers is only
133 !! necessary when using the Silo database file format in multidimensions. These zones provide VisIt with the subdomain
134 !! connectivity information that it requires in order to produce smooth plots.
135 !> @{
137 !> @}
138
139 ! alpha_rho_wrt, mom_wrt, vel_wrt, flux_wrt, alpha_rho_e_wrt, alpha_wrt,
140 ! omega_wrt, chem_wrt_Y, schlieren_alpha: auto-generated in generated_decls.fpp
141 integer :: fd_number !< Finite-difference half-stencil size: MAX(1, fd_order/2)
143 !> @name Bubble modeling variables and parameters
144 !> @{
145 real(wp) :: eu
146 real(wp), dimension(:), allocatable :: weight, r0
147 real(wp) :: phi_vg, phi_gv, pe_c, tw, k_vl, k_gl
148 real(wp) :: gam_m
149 real(wp), dimension(:), allocatable :: pb0, mass_g0, mass_v0, pe_t, k_v, k_g
150 real(wp), dimension(:), allocatable :: re_trans_t, re_trans_c, im_trans_t, im_trans_c, omegan
152 real(wp) :: g
153 integer :: nmom
154 !> @}
155
156 real(wp) :: wall_time, wall_time_avg !< Wall time measurements
157
158contains
159
160 !> Assigns default values to user inputs prior to reading them in. This allows for an easier consistency check of these
161 !! parameters once they are read from the input file.
163
164 integer :: i !< Generic loop iterator
165
166 ! Shared defaults (case_dir, m/n/p, cyl_coord, cfl flags, model_eqns, BC blocks,
167 ! recon/weno/muscl/num_fluids/igr/mhd/relativity under case-opt guard, Tait EOS, bubble flags,
168 ! IB flags, parallel I/O flags, fft_wrt)
169
171
172 ! Boundary conditions (bc_x/y/z are per-target declarations, not visible in common)
173 bc_x%beg = dflt_int; bc_x%end = dflt_int
174 bc_y%beg = dflt_int; bc_y%end = dflt_int
175 bc_z%beg = dflt_int; bc_z%end = dflt_int
176
177# 167 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
178# 168 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
179 bc_x%vb1 = 0._wp
180 bc_x%ve1 = 0._wp
181# 168 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
182 bc_x%vb2 = 0._wp
183 bc_x%ve2 = 0._wp
184# 168 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
185 bc_x%vb3 = 0._wp
186 bc_x%ve3 = 0._wp
187# 171 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
188# 167 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
189# 168 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
190 bc_y%vb1 = 0._wp
191 bc_y%ve1 = 0._wp
192# 168 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
193 bc_y%vb2 = 0._wp
194 bc_y%ve2 = 0._wp
195# 168 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
196 bc_y%vb3 = 0._wp
197 bc_y%ve3 = 0._wp
198# 171 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
199# 167 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
200# 168 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
201 bc_z%vb1 = 0._wp
202 bc_z%ve1 = 0._wp
203# 168 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
204 bc_z%vb2 = 0._wp
205 bc_z%ve2 = 0._wp
206# 168 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
207 bc_z%vb3 = 0._wp
208 bc_z%ve3 = 0._wp
209# 171 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
210# 172 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
211
212# 174 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
213 bc_x%isothermal_in = .false.
214 bc_x%isothermal_out = .false.
215 bc_x%Twall_in = dflt_real
216 bc_x%Twall_out = dflt_real
217# 174 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
218 bc_y%isothermal_in = .false.
219 bc_y%isothermal_out = .false.
220 bc_y%Twall_in = dflt_real
221 bc_y%Twall_out = dflt_real
222# 174 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
223 bc_z%isothermal_in = .false.
224 bc_z%isothermal_out = .false.
225 bc_z%Twall_in = dflt_real
226 bc_z%Twall_out = dflt_real
227# 179 "/home/runner/work/MFC/MFC/src/post_process/m_global_parameters.fpp"
228
230
231 ! Computational domain parameters (post-specific)
233
236
237 cfl_dt = .false.
241
242 bc_io = .false.
244
245 chem_params%gamma_method = 1
246 chem_params%transport_model = 1
247
248 chem_params%reaction_substeps = 0
249 chem_params%adap_substeps = .false.
250 chem_params%reaction_substeps_max = 0
251
252 ! Fluids physical parameters (post-specific; G = dflt_real differs from pre/sim)
253 do i = 1, num_fluids_max
254 fluid_pp(i)%gamma = dflt_real
255 fluid_pp(i)%pi_inf = dflt_real
256 fluid_pp(i)%cv = 0._wp
257 fluid_pp(i)%qv = 0._wp
258 fluid_pp(i)%qvp = 0._wp
259 fluid_pp(i)%G = dflt_real
260 fluid_pp(i)%non_newtonian = .false.
261 fluid_pp(i)%K = dflt_real
262 fluid_pp(i)%nn = dflt_real
263 fluid_pp(i)%tau0 = 0._wp
264 fluid_pp(i)%hb_m = dflt_real
265 fluid_pp(i)%mu_min = dflt_real
266 fluid_pp(i)%mu_max = dflt_real
267 fluid_pp(i)%mu_bulk = dflt_real
268 end do
269
270 ! Subgrid bubble parameters (bub_pp struct + scalar companions; bub_pp%R0ref is set in common
271 ! via R0ref; the scalar companions are per-target manual declarations)
274 bub_pp%rho0ref = dflt_real; rho0ref = dflt_real
286 bub_pp%k_v = dflt_real
287 bub_pp%k_g = dflt_real
292
293 ! Formatted database file(s) structure parameters (post-specific)
294 format = dflt_int
295
297
298 alpha_rho_wrt = .false.
299 alpha_rho_e_wrt = .false.
300 rho_wrt = .false.
301 mom_wrt = .false.
302 vel_wrt = .false.
303 chem_wrt_y = .false.
304 chem_wrt_t = .false.
306 flux_wrt = .false.
307 e_wrt = .false.
308 pres_wrt = .false.
309 alpha_wrt = .false.
310 gamma_wrt = .false.
311 heat_ratio_wrt = .false.
312 pi_inf_wrt = .false.
313 pres_inf_wrt = .false.
314 prim_vars_wrt = .false.
315 cons_vars_wrt = .false.
316 c_wrt = .false.
317 omega_wrt = .false.
318 qm_wrt = .false.
319 liutex_wrt = .false.
320 schlieren_wrt = .false.
321 sim_data = .false.
322 cf_wrt = .false.
323 ib_state_wrt = .false.
324 lag_txt_wrt = .false.
325 lag_header = .true.
326 lag_db_wrt = .false.
327 lag_id_wrt = .true.
328 lag_pos_wrt = .true.
329 lag_pos_prev_wrt = .false.
330 lag_vel_wrt = .true.
331 lag_rad_wrt = .true.
332 lag_rvel_wrt = .false.
333 lag_r0_wrt = .false.
334 lag_rmax_wrt = .false.
335 lag_rmin_wrt = .false.
336 lag_dphidt_wrt = .false.
337 lag_pres_wrt = .false.
338 lag_mv_wrt = .false.
339 lag_mg_wrt = .false.
340 lag_betat_wrt = .false.
341 lag_betac_wrt = .false.
342
344
346
347 ! Bubble modeling (post-specific)
348 nb = dflt_int
349
350 ! Output partial domain (post-specific)
351 output_partial_domain = .false.
352 x_output%beg = dflt_real
353 x_output%end = dflt_real
354 y_output%beg = dflt_real
355 y_output%end = dflt_real
356 z_output%beg = dflt_real
357 z_output%end = dflt_real
358
360
361 !> Computation of parameters, allocation procedures, and/or any other tasks needed to properly setup the module
363
364 integer :: i, j, fac
365
366 ! Setting m_root equal to m in the case of a 1D serial simulation
367
368 if (n == 0) m_root = m_glb
369
370 ! Declared for the common conversion kernel but not a post_process input, so it is neither
371 ! defaulted on non-root ranks nor broadcast. Post-process never carries viscous stresses.
372 viscous = .false.
373
374 ! Gamma/Pi_inf: force num_fluids=1 (post_process-specific side effect of the gamma-law model)
376
377 ! post_process sets nmom to 6 for qbmm before the shared eqn_idx setup
378 ! (guard matches the original site: inside the 5-equation branch)
379 if (model_eqns == model_eqns_5eq .and. qbmm) nmom = 6
380
381 ! Populate eqn_idx, sys_size, shear_* (shared logic)
382 call s_initialize_eqn_idx(nmom, nb, six_eqn_alf_is_advected=.false.)
383
384 ! post-only: 6eq alf is a dummy (no void fraction in 6eq)
385 if (model_eqns == model_eqns_6eq) eqn_idx%alf = 1
386
387 ! post-only: set default indices for disabled fields (used by post-processing consumers)
389 if (.not. cont_damage) eqn_idx%damage = dflt_int
390 if (.not. hyper_cleaning) eqn_idx%psi = dflt_int
391 end if
392
393 ! post-only: species defaults when chemistry is off
394 if (.not. chemistry) then
395 eqn_idx%species%beg = 1
396 eqn_idx%species%end = 1
397 end if
398
399 ! Per-target (post_process): beta_idx for bubbles_lagrange (5eq only, after main eqn_idx setup)
401 beta_idx = sys_size + 1
403 end if
404
405 ! Per-target (post_process): qbmm_idx allocations and fills
406 if (model_eqns == model_eqns_5eq .and. bubbles_euler) then
407 allocate (qbmm_idx%rs(nb), qbmm_idx%vs(nb))
408 allocate (qbmm_idx%ps(nb), qbmm_idx%ms(nb))
409
410 if (qbmm) then
411 allocate (qbmm_idx%moms(nb, nmom))
412 do i = 1, nb
413 do j = 1, nmom
414 qbmm_idx%moms(i, j) = eqn_idx%bub%beg + (j - 1) + (i - 1)*nmom
415 end do
416 qbmm_idx%rs(i) = qbmm_idx%moms(i, 2)
417 qbmm_idx%vs(i) = qbmm_idx%moms(i, 3)
418 end do
419 else
420 do i = 1, nb
421 if (polytropic .neqv. .true.) then
422 fac = 4
423 else
424 fac = 2
425 end if
426
427 qbmm_idx%rs(i) = eqn_idx%bub%beg + (i - 1)*fac
428 qbmm_idx%vs(i) = qbmm_idx%rs(i) + 1
429
430 if (polytropic .neqv. .true.) then
431 qbmm_idx%ps(i) = qbmm_idx%vs(i) + 1
432 qbmm_idx%ms(i) = qbmm_idx%ps(i) + 1
433 end if
434 end do
435 end if
436 end if
437
438 if (output_partial_domain) then
439 x_output_idx%beg = 0
440 x_output_idx%end = 0
441 y_output_idx%beg = 0
442 y_output_idx%end = 0
443 z_output_idx%beg = 0
444 z_output_idx%end = 0
445 end if
446
447#ifdef MFC_MPI
448 if (qbmm .and. .not. polytropic) then
449 allocate (mpi_io_data%view(1:sys_size + 2*nb*nnode))
450 allocate (mpi_io_data%var(1:sys_size + 2*nb*nnode))
451 else
452 allocate (mpi_io_data%view(1:sys_size))
453 allocate (mpi_io_data%var(1:sys_size))
454 end if
455
456 do i = 1, sys_size
457 if (down_sample) then
458 allocate (mpi_io_data%var(i)%sf(-1:m + 1,-1:n + 1,-1:p + 1))
459 else
460 allocate (mpi_io_data%var(i)%sf(0:m,0:n,0:p))
461 end if
462 mpi_io_data%var(i)%sf => null()
463 end do
464 if (qbmm .and. .not. polytropic) then
465 do i = sys_size + 1, sys_size + 2*nb*nnode
466 allocate (mpi_io_data%var(i)%sf(0:m,0:n,0:p))
467 mpi_io_data%var(i)%sf => null()
468 end do
469 end if
470
471 if (ib) allocate (mpi_io_ib_data%var%sf(0:m,0:n,0:p))
472#endif
473
474 ! Size of the ghost zone layer is non-zero only when post-processing the raw simulation data of a parallel multidimensional
475 ! computation in the Silo-HDF5 format. If this is the case, one must also verify whether the raw simulation data is 2D or
476 ! 3D. In the 2D case, size of the z-coordinate direction ghost zone layer must be zeroed out.
477 if (num_procs == 1 .or. format /= format_silo) then
478 offset_x%beg = 0
479 offset_x%end = 0
480 offset_y%beg = 0
481 offset_y%end = 0
482 offset_z%beg = 0
483 offset_z%end = 0
484 else if (n == 0) then
485 offset_y%beg = 0
486 offset_y%end = 0
487 offset_z%beg = 0
488 offset_z%end = 0
489 else if (p == 0) then
490 offset_z%beg = 0
491 offset_z%end = 0
492 end if
493
494 ! Determining the finite-difference number and the buffer size. Note that the size of the buffer is unrelated to the order
495 ! of the WENO scheme. Rather, it is directly dependent on maximum size of ghost zone layers and possibly the order of the
496 ! finite difference scheme used for the computation of vorticity and/or numerical Schlieren function.
497 buff_size = max(offset_x%beg, offset_x%end, offset_y%beg, offset_y%end, offset_z%beg, offset_z%end)
498
499 if (any(omega_wrt) .or. schlieren_wrt .or. qm_wrt .or. liutex_wrt) then
500 fd_number = max(1, fd_order/2)
502 end if
503
504 ! Configuring Coordinate Direction Indexes
505 idwint(1)%beg = 0; idwint(2)%beg = 0; idwint(3)%beg = 0
506 idwint(1)%end = m; idwint(2)%end = n; idwint(3)%end = p
507
508 idwbuff(1)%beg = -buff_size
509 if (num_dims > 1) then; idwbuff(2)%beg = -buff_size; else; idwbuff(2)%beg = 0; end if
510 if (num_dims > 2) then; idwbuff(3)%beg = -buff_size; else; idwbuff(3)%beg = 0; end if
511
512 idwbuff(1)%end = idwint(1)%end - idwbuff(1)%beg
513 idwbuff(2)%end = idwint(2)%end - idwbuff(2)%beg
514 idwbuff(3)%end = idwint(3)%end - idwbuff(3)%beg
515
516 ! Allocating single precision grid variables if needed
517 allocate (x_cc_s(-buff_size:m + buff_size))
518
519 ! Allocating the grid variables in the x-coordinate direction
520 allocate (x_cb(-1 - offset_x%beg:m + offset_x%end))
521 allocate (x_cc(-buff_size:m + buff_size))
522 allocate (dx(-buff_size:m + buff_size))
523
524 ! Allocating grid variables in the y- and z-coordinate directions
525 if (n > 0) then
526 allocate (y_cb(-1 - offset_y%beg:n + offset_y%end))
527 allocate (y_cc(-buff_size:n + buff_size))
528 allocate (dy(-buff_size:n + buff_size))
529
530 if (p > 0) then
531 allocate (z_cb(-1 - offset_z%beg:p + offset_z%end))
532 allocate (z_cc(-buff_size:p + buff_size))
533 allocate (dz(-buff_size:p + buff_size))
534 end if
535
536 ! Allocating the grid variables, only used for the 1D simulations, and containing the defragmented computational domain
537 ! grid data
538 else
539 allocate (x_root_cb(-1:m_root))
540 allocate (x_root_cc(0:m_root))
541
542 if (precision == precision_single) then
543 allocate (x_root_cc_s(0:m_root))
544 end if
545 end if
546
547 allocate (adv(num_fluids))
548
549 if (cyl_coord .neqv. .true.) then ! Cartesian grid
550 grid_geometry = 1
551 else if (cyl_coord .and. p == 0) then ! Axisymmetric cylindrical grid
552 grid_geometry = 2
553 else ! Fully 3D cylindrical grid
554 grid_geometry = 3
555 end if
556
558
559 !> Subroutine to initialize parallel infrastructure
564 end subroutine s_initialize_parallel_io
565
566 !> Deallocation procedures for the module
568
569 integer :: i
570
571 if (bubbles_euler) then
572 deallocate (qbmm_idx%rs, qbmm_idx%vs, qbmm_idx%ps, qbmm_idx%ms)
573 if (qbmm) deallocate (qbmm_idx%moms)
574 end if
575
576 ! Deallocating the grid variables for the x-coordinate direction
577 deallocate (x_cc, x_cb, dx)
578
579 ! Deallocating grid variables for the y- and z-coordinate directions
580 if (n > 0) then
581 deallocate (y_cc, y_cb, dy)
582 if (p > 0) then
583 deallocate (z_cc, z_cb, dz)
584 end if
585 else
586 ! Deallocating the grid variables, only used for the 1D simulations, and containing the defragmented computational
587 ! domain grid data
588 deallocate (x_root_cb, x_root_cc)
589 end if
590
591 ! Shared: deallocate proc_coords and start_idx
593
594 deallocate (adv)
595
596#ifdef MFC_MPI
597 if (parallel_io) then
598 do i = 1, sys_size
599 mpi_io_data%var(i)%sf => null()
600 end do
601
602 deallocate (mpi_io_data%var)
603 deallocate (mpi_io_data%view)
604 end if
605
606 if (ib) mpi_io_ib_data%var%sf => null()
607#endif
608
609 if (allocated(neighbor_ranks)) deallocate (neighbor_ranks)
610
612
613end module m_global_parameters
integer, intent(in) j
Compile-time constant parameters: default values, tolerances, and physical constants.
integer, parameter model_eqns_5eq
integer, parameter format_silo
integer, parameter dflt_int
Default integer value.
real(wp), parameter dflt_real
Default real value.
integer, parameter num_fluids_max
Maximum number of fluids in the simulation.
integer, parameter nnode
Number of QBMM nodes.
integer, parameter precision_single
integer, parameter model_eqns_6eq
integer, parameter model_eqns_gamma_law
Shared derived types for field data, patch geometry, bubble dynamics, and MPI I/O structures.
Shared global parameters and equation-index setup for all three executables. Each per-target m_global...
impure subroutine s_finalize_global_parameters_common
Shared finalize core: deallocate proc_coords and start_idx. Per-target finalize routines call this fi...
type(subgrid_bubble_physical_parameters) bub_pp
Subgrid bubble physical parameters.
integer sys_size
Number of unknowns in system of equations.
logical, dimension(num_fluids_max) alpha_rho_e_wrt
logical, dimension(num_species) chem_wrt_y
real(wp), dimension(num_fluids_max) schlieren_alpha
logical, dimension(num_fluids_max) alpha_wrt
type(physical_parameters), dimension(num_fluids_max) fluid_pp
Per-fluid stiffened-gas EOS parameters, Reynolds numbers, and shear modulus.
logical, dimension(num_fluids_max) alpha_rho_wrt
type(eqn_idx_info) eqn_idx
All conserved-variable equation index ranges and scalars.
impure subroutine s_initialize_parallel_io_common
Configure MPI parallel I/O settings and allocate processor coordinate arrays. Shared across all three...
impure subroutine s_assign_common_defaults
Assign default values to the user-input parameters that are shared across all three executables (pre_...
impure subroutine s_initialize_eqn_idx(nmom_in, nb_in, six_eqn_alf_is_advected)
Initialize equation-index state (eqn_idx and sys_size) from the namelist parameters....
Global parameters for the post-process: domain geometry, equation of state, and output database setti...
real(sp), dimension(:), allocatable x_cc_s
type(mpi_io_levelset_norm_var), public mpi_io_levelsetnorm_data
impure subroutine s_assign_default_values_to_user_inputs
Assigns default values to user inputs prior to reading them in. This allows for an easier consistency...
impure subroutine s_finalize_global_parameters_module
Deallocation procedures for the module.
real(wp), dimension(:), allocatable im_trans_c
type(int_bounds_info), dimension(1:3) idwint
integer beta_idx
Index of lagrange bubbles beta.
type(int_bounds_info) offset_y
type(int_bounds_info), dimension(3) nidx
Neighbor index offsets per direction (#1290 decomposition).
real(wp), dimension(:), allocatable pb0
real(wp), dimension(:), allocatable im_trans_t
type(qbmm_idx_info) qbmm_idx
QBMM moment index mappings.
real(wp), dimension(:,:), allocatable, public mpi_io_data_lg_bubbles
real(wp), dimension(:), allocatable y_cc
integer proc_rank
Rank of the local processor.
real(wp), dimension(:), allocatable re_trans_t
real(wp), dimension(:), allocatable adv
Advection variables.
real(wp), dimension(:), allocatable x_root_cc
type(int_bounds_info) z_output_idx
Indices of domain to output for post-processing.
type(mpi_io_ib_var), public mpi_io_ib_data
real(wp), dimension(:), allocatable y_cb
real(wp), dimension(:), allocatable dz
real(wp), dimension(:), allocatable weight
real(wp), dimension(:), allocatable k_v
real(wp), dimension(:), allocatable x_root_cb
integer fd_number
Finite-difference half-stencil size: MAX(1, fd_order/2).
type(mpi_io_levelset_var), public mpi_io_levelset_data
type(int_bounds_info), dimension(1:3) idwbuff
integer buff_size
Number of ghost cells for boundary condition storage.
real(wp), dimension(:), allocatable z_cb
type(bounds_info) z_output
Portion of domain to output for post-processing.
type(ib_airfoil_parameters), dimension(:), allocatable ib_airfoil
Per-airfoil NACA parameters (unused in post_process).
integer, dimension(:,:,:), allocatable neighbor_ranks
MPI ranks of neighbors (#1290 decomposition).
real(wp), dimension(:), allocatable r0
type(int_bounds_info) x_output_idx
impure subroutine s_initialize_global_parameters_module
Computation of parameters, allocation procedures, and/or any other tasks needed to properly setup the...
real(wp), dimension(:), allocatable x_cc
real(wp), dimension(:), allocatable k_g
type(ib_airfoil_grid), dimension(:), allocatable ib_airfoil_grids
Per-airfoil computed surface grids (unused in post_process).
type(chemistry_parameters) chem_params
real(wp), dimension(:), allocatable x_cb
real(wp), dimension(:), allocatable dy
type(int_bounds_info) offset_x
real(wp), dimension(:), allocatable z_cc
integer num_procs
Number of processors.
type(int_bounds_info) y_output_idx
type(int_bounds_info) offset_z
type(cell_num_bounds) cells_bounds
real(wp), dimension(:), allocatable mass_g0
real(wp) wall_time_avg
Wall time measurements.
type(mpi_io_var), public mpi_io_data
impure subroutine s_initialize_parallel_io
Subroutine to initialize parallel infrastructure.
real(wp), dimension(:), allocatable omegan
real(wp), dimension(:), allocatable re_trans_c
real(sp), dimension(:), allocatable x_root_cc_s
real(wp), dimension(:), allocatable dx
Cell-width distributions in the x-, y- and z-coordinate directions.
real(wp), dimension(:), allocatable pe_t
real(wp), dimension(:), allocatable mass_v0
integer(kind=8) nglobal
Total number of cells in global domain.
Basic floating-point utilities: approximate equality, default detection, and coordinate bounds.
elemental subroutine, public s_update_cell_bounds(bounds, m, n, p)
Update the min and max number of cells in each set of axes.
Groups the x, y, z boundary condition begin/end codes for passing as a single argument.
Derived type adding beginning (beg) and end bounds info as attributes.
Max and min number of cells in a direction of each combination of x-,y-, and z-.
Computed surface grid for a NACA airfoil (simulation-only, not in namelist).
User-input parameters for a NACA 4-digit airfoil (namelist-safe: scalars only).
Integer bounds for variables.
QBMM moment index mappings - separate from bub beg/end so eqn_idx contains no allocatables.