Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pass the namelist variables from the dycore to the physics during the initialization #22

Merged
merged 3 commits into from
Jun 6, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion SHiELD/atmos_model.F90
Original file line number Diff line number Diff line change
Expand Up @@ -370,6 +370,7 @@ subroutine atmos_model_init (Atmos, Time_init, Time, Time_step, iau_offset)
character(len=64) :: filename, filename2, pelist_name
character(len=132) :: text
logical :: p_hydro, hydro, fexist
logical :: do_inline_mp, do_cosp
logical, save :: block_message = .true.
integer :: bdat(8), cdat(8)
integer :: ntracers
Expand Down Expand Up @@ -422,7 +423,8 @@ subroutine atmos_model_init (Atmos, Time_init, Time, Time_step, iau_offset)
!-----------------------------------------------------------------------
!--- before going any further check definitions for 'blocks'
!-----------------------------------------------------------------------
call atmosphere_control_data (isc, iec, jsc, jec, nlev, p_hydro, hydro, tile_num)
call atmosphere_control_data (isc, iec, jsc, jec, nlev, p_hydro, hydro, tile_num, &
do_inline_mp, do_cosp)
call define_blocks_packed ('atmos_model', Atm_block, isc, iec, jsc, jec, nlev, &
blocksize, block_message)

Expand Down Expand Up @@ -473,6 +475,10 @@ subroutine atmos_model_init (Atmos, Time_init, Time, Time_step, iau_offset)
Init_parm%xlat => Atmos%lat
Init_parm%area => Atmos%area
Init_parm%tracer_names => tracer_names
!--- setup IPD_Control
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is indeed very clean.

IPD_Control%dycore_hydrostatic = hydro
IPD_Control%do_inline_mp = do_inline_mp
IPD_Control%do_cosp = do_cosp

allocate(Init_parm%input_nml_file, mold=input_nml_file)
Init_parm%input_nml_file => input_nml_file
Expand Down