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

Fix for invisible first_time_step bug in SHiELD #18

Merged
merged 6 commits into from
Sep 14, 2022
Merged
Show file tree
Hide file tree
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
4 changes: 2 additions & 2 deletions SHiELD/atmos_model.F90
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ module atmos_model_mod
logical :: dycore_only = .false.
logical :: debug = .false.
logical :: sync = .false.
logical :: first_time_step = .true.
logical :: first_time_step = .false.
logical :: fprint = .true.
logical :: ignore_rst_cksum = .false. ! enforce (.false.) or override (.true.) data integrity restart checksums
real, dimension(4096) :: fdiag = 0. ! xic: TODO: this is hard coded, space can run out in some cases. Should make it allocatable.
Expand Down Expand Up @@ -634,7 +634,7 @@ subroutine update_atmos_model_state (Atmos)
if (mpp_pe() == mpp_root_pe()) write(6,*) ' gfs diags time since last bucket empty: ',time_int/3600.,'hrs'
call atmosphere_nggps_diag(Atmos%Time)
endif
if (ANY(nint(fdiag(:)*3600.0) == seconds) .or. (fdiag_fix .and. mod(seconds, nint(fdiag(1)*3600.0)) .eq. 0) .or. first_time_step) then
if (ANY(nint(fdiag(:)*3600.0) == seconds) .or. (fdiag_fix .and. mod(seconds, nint(fdiag(1)*3600.0)) .eq. 0) .or. (IPD_Control%kdt == 1 .and. first_time_step)) then
if(Atmos%iau_offset > zero) then
if( time_int - Atmos%iau_offset*3600. > zero ) then
time_int = time_int - Atmos%iau_offset*3600.
Expand Down
1 change: 1 addition & 0 deletions solo/atmos_model.F90
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ program atmos_model
character(len=17) :: calendar = 'no_calendar ' !< The calendar type used by the current integration. Valid values are
!! consistent with the time_manager module: 'gregorian', 'julian',
!! 'noleap', or 'thirty_day'. All values must be lower case.
!! In solo_core the default is no_calendar
integer, dimension(4) :: current_time = (/ 0, 0, 0, 0/) !< The current time integration starts with (DD,HH,MM,SS)
integer :: years=0 !< Number of years the current integration will be run
integer :: months=0 !< Number of months the current integration will be run
Expand Down