MODFLOW 6 version 6.9.0.dev0
USGS Modular Hydrologic Model
Loading...
Searching...
No Matches
runcontrolmodule Module Reference

Data Types

type  runcontroltype

Functions/Subroutines

class(runcontroltype) function, pointer, public create_seq_run_control ()
subroutine ctrl_start (this)
subroutine ctrl_finish (this)
subroutine ctrl_at_stage (this, stage)
 This will call the handler for a particular stage.
subroutine init_handler (this)
subroutine ctrl_after_con_cr (this)
 Actions after connections have been created.
subroutine before_con_df (this)
 Actions before defining the connections.
subroutine after_con_df (this)
 Actions after defining connections.
subroutine rc_solution_sync (num_sol, stage, ctx)
 Synchronizes from within numerical solution (delegate).
subroutine destroy (this)

Function/Subroutine Documentation

◆ after_con_df()

subroutine runcontrolmodule::after_con_df ( class(runcontroltype) this)
private

Definition at line 150 of file RunControl.f90.

151 class(RunControlType) :: this
152
153 ! Reduce the halo
154 call this%virtual_data_mgr%compress_halo()
155
156 ! Add variables in interface models to the mapper
157 call this%mapper%add_interface_vars()
158

◆ before_con_df()

subroutine runcontrolmodule::before_con_df ( class(runcontroltype), target this)
private

Set up the virtual data manager: The models and exchanges in the halo for this interface have been determined. Add them to the virtual data manager for synchronization. (After which the interface model

Definition at line 121 of file RunControl.f90.

122 class(RunControlType), target :: this
123 ! local
124 integer(I4B) :: i
125 class(*), pointer :: obj_ptr
126 class(NumericalSolutionType), pointer :: sol
127
128 ! Add (halo) models and exchanges to the virtual
129 ! solutions. Set the synchronization handler
130 ! in the numerical solution.
131 do i = 1, basesolutionlist%Count()
132 obj_ptr => basesolutionlist%GetItem(i)
133 select type (obj_ptr)
134 class is (numericalsolutiontype)
135 sol => obj_ptr
136 call this%virtual_data_mgr%add_solution(sol)
137 sol%synchronize => rc_solution_sync
138 sol%synchronize_ctx => this
139 end select
140 end do
141
142 ! The remote data fields in exchanges need to
143 ! be copied in from the virtual exchanges
144 call this%mapper%add_exchange_vars()
145
Here is the call graph for this function:

◆ create_seq_run_control()

class(runcontroltype) function, pointer, public runcontrolmodule::create_seq_run_control

Definition at line 33 of file RunControl.f90.

34 class(RunControlType), pointer :: run_controller
35
36 allocate (run_controller)
37
Here is the caller graph for this function:

◆ ctrl_after_con_cr()

subroutine runcontrolmodule::ctrl_after_con_cr ( class(runcontroltype) this)
private

Definition at line 107 of file RunControl.f90.

108 class(RunControlType) :: this
109
110 call this%virtual_data_mgr%activate_halo()
111

◆ ctrl_at_stage()

subroutine runcontrolmodule::ctrl_at_stage ( class(runcontroltype) this,
integer(i4b) stage )
private

Definition at line 76 of file RunControl.f90.

77 class(RunControlType) :: this
78 integer(I4B) :: stage
79
80 if (stage == stg_bfr_mdl_df) then
81 call this%init_handler()
82 else if (stage == stg_aft_con_cr) then
83 call this%after_con_cr()
84 else if (stage == stg_bfr_con_df) then
85 call this%before_con_df()
86 else if (stage == stg_aft_con_df) then
87 call this%after_con_df()
88 end if
89
90 call this%virtual_data_mgr%synchronize(stage)
91 call this%mapper%scatter(0, stage)
92

◆ ctrl_finish()

subroutine runcontrolmodule::ctrl_finish ( class(runcontroltype) this)
private

Definition at line 47 of file RunControl.f90.

48 use simvariablesmodule, only: iout
51 use timermodule, only: elapsed_time
52 use simmodule, only: final_message
53 class(RunControlType) :: this
54
55 ! clean up
56 call this%destroy()
57
58 ! -- Write memory usage, elapsed time and terminate
60 call mem_da()
61 call mem_alias_da()
62
63 ! stop and print timings
64 call g_prof%stop(g_prof%tmr_finalize)
65 call g_prof%stop(g_prof%tmr_run)
66 call g_prof%print(iout)
67 call g_prof%destroy()
68
69 call elapsed_time(iout, 1)
70 call final_message()
71
Previous variable names checked in as deprecated aliases.
subroutine, public mem_alias_da()
Clear the recorded aliases.
subroutine, public mem_write_usage(iout)
Write memory manager memory usage based on the user-specified memory_print_option.
subroutine, public mem_da()
Deallocate memory in the memory manager.
This module contains simulation methods.
Definition Sim.f90:10
subroutine, public final_message()
Create final message.
Definition Sim.f90:477
This module contains simulation variables.
integer(i4b) iout
file unit number for simulation output
subroutine, public elapsed_time(iout, iprtim)
Get end time and calculate elapsed time.
Definition Timer.f90:36
Here is the call graph for this function:

◆ ctrl_start()

subroutine runcontrolmodule::ctrl_start ( class(runcontroltype) this)
private

Definition at line 40 of file RunControl.f90.

41 class(RunControlType) :: this
42
43 allocate (this%virtual_data_mgr)
44

◆ destroy()

subroutine runcontrolmodule::destroy ( class(runcontroltype) this)
private

Definition at line 177 of file RunControl.f90.

178 class(RunControlType) :: this
179
180 call this%virtual_data_mgr%destroy()
181 deallocate (this%virtual_data_mgr)
182

◆ init_handler()

subroutine runcontrolmodule::init_handler ( class(runcontroltype), target this)
private

Definition at line 95 of file RunControl.f90.

97 class(RunControlType), target :: this
98
99 call this%virtual_data_mgr%create(simulation_mode)
100 call this%virtual_data_mgr%init()
101 call this%mapper%init()
102
character(len=linelength) simulation_mode

◆ rc_solution_sync()

subroutine runcontrolmodule::rc_solution_sync ( class(numericalsolutiontype) num_sol,
integer(i4b) stage,
class(*), pointer ctx )
private

Definition at line 163 of file RunControl.f90.

165 class(NumericalSolutionType) :: num_sol
166 integer(I4B) :: stage
167 class(*), pointer :: ctx
168
169 select type (ctx)
170 class is (runcontroltype)
171 call ctx%virtual_data_mgr%synchronize_sln(num_sol%id, stage)
172 call ctx%mapper%scatter(num_sol%id, stage)
173 end select
174
Here is the caller graph for this function: