MFC
Exascale flow solver
Loading...
Searching...
No Matches
p_main.f90
Go to the documentation of this file.
1!>
2!! @file
3!! @brief Contains program p_main
4
5!> @brief This program takes care of setting up the initial condition and
6!! grid data for the multicomponent flow code.
7program p_main
8
9 use m_global_parameters !< global parameters for the code
10
11 use m_start_up
12
13 implicit none
14
15 logical :: file_exists
16 real(wp) :: start, finish, time_avg, time_final
17 real(wp), allocatable, dimension(:) :: proc_time
18
19 call random_seed()
20
22
23 ! Initialization of the MPI environment
24
26
27 call s_read_grid()
28
29 allocate (proc_time(0:num_procs - 1))
30
31 call s_apply_initial_condition(start, finish)
32
33 time_avg = abs(finish - start)
34
35 call s_save_data(proc_time, time_avg, time_final, file_exists)
36
37 deallocate (proc_time)
38
40
41end program p_main
Defines global parameters for the computational domain, simulation algorithm, and initial conditions.
integer num_procs
Number of processors.
Reads and validates user inputs, loads existing grid/IC data, and initializes pre-process modules.
impure subroutine, public s_initialize_modules
Initializes all pre-process modules, allocates data structures, and sets I/O procedure pointers.
impure subroutine, public s_save_data(proc_time, time_avg, time_final, file_exists)
Gathers processor timing data and writes elapsed wall-clock time to a summary file.
impure subroutine, public s_apply_initial_condition(start, finish)
Generates or reads the initial condition, applies relaxation if needed, and writes output data files.
impure subroutine, public s_read_grid()
Reads an existing grid from data files or generates a new grid from user inputs.
impure subroutine, public s_initialize_mpi_domain
Initializes MPI, reads and validates user inputs on rank 0, and decomposes the computational domain.
impure subroutine, public s_finalize_modules
Finalizes all pre-process modules, deallocates resources, and shuts down MPI.
program p_main
This program takes care of setting up the initial condition and grid data for the multicomponent flow...
Definition p_main.f90:7