Skip to content

Commit

Permalink
Fixed bug in GFS_time_vary_step calling GFS_rad_time_vary_run with lo…
Browse files Browse the repository at this point in the history
…cal/uninitialized variables ictmflg, isolar instead of the correct parameters defined in physparam
  • Loading branch information
DomHeinzeller committed Dec 26, 2017
1 parent bc2c524 commit 9941ede
Showing 1 changed file with 4 additions and 13 deletions.
17 changes: 4 additions & 13 deletions GFS_layer/GFS_driver.F90
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@ module GFS_driver
use module_radsw_parameters, only: topfsw_type, sfcfsw_type
use module_radlw_parameters, only: topflw_type, sfcflw_type
use funcphys, only: gfuncphys
use GFS_suite_setup_1, only: GFS_suite_setup_1_run
use GFS_suite_setup_2, only: GFS_suite_setup_2_run

implicit none

Expand Down Expand Up @@ -238,6 +236,9 @@ end subroutine GFS_initialize
subroutine GFS_time_vary_step (Model, Statein, Stateout, Sfcprop, Coupling, &
Grid, Tbd, Cldprop, Radtend, Diag)

use physparam, only: ictmflg, isolar
use GFS_suite_setup_1, only: GFS_suite_setup_1_run
use GFS_suite_setup_2, only: GFS_suite_setup_2_run
use GFS_rad_time_vary, only: GFS_rad_time_vary_run
implicit none

Expand All @@ -253,21 +254,11 @@ subroutine GFS_time_vary_step (Model, Statein, Stateout, Sfcprop, Coupling, &
type(GFS_radtend_type), intent(inout) :: Radtend(:)
type(GFS_diag_type), intent(inout) :: Diag(:)
!--- local variables
! DH* - where are those coming from?
!integer :: nblks, ictmflg, isolar
integer :: ictmflg, isolar
!real(kind=kind_phys) :: rinc(5)
real(kind=kind_phys) :: sec

call GFS_suite_setup_1_run (Model, sec)

!--- radiation time varying routine
! CCPP
call GFS_rad_time_vary_run(Model,Statein, Tbd, blksz, sec, &
ictmflg, isolar)

!--- repopulate specific time-varying sfc properties for AMIP/forecast runs
call Gcycle_driver (nblks, Model, Grid, Sfcprop, Cldprop)
call GFS_rad_time_vary_run(Model, Statein, Tbd, blksz, sec, ictmflg, isolar)

call GFS_suite_setup_2_run (blksz, Grid, Model, Tbd, Sfcprop, Cldprop, Diag)

Expand Down

0 comments on commit 9941ede

Please sign in to comment.