Skip to content

Commit

Permalink
add zeroing of velocity to init_mode
Browse files Browse the repository at this point in the history
  • Loading branch information
mark-petersen committed Oct 12, 2022
1 parent 47f4c4e commit 66ac386
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions components/mpas-ocean/src/mode_init/mpas_ocn_init_mode.F
Original file line number Diff line number Diff line change
Expand Up @@ -267,9 +267,15 @@ function ocn_init_mode_run(domain) result(iErr)!{{{
type (mpas_pool_type), pointer :: forcingPool

type (MPAS_timeInterval_type) :: timeStep
real (kind=RKIND), dimension(:,:), pointer :: normalVelocity

ierr = 0

! Initialize normalVelocity to zero for cases that do not specify it.
call mpas_pool_get_subpool(domain % blocklist % structs, 'state', statePool)
call mpas_pool_get_array(statePool, 'normalVelocity', normalVelocity, 1)
normalVelocity(:,:) = 0.0_RKIND

! Eventually, dt should be domain specific
timeStep = mpas_get_clock_timestep(domain % clock, ierr=ierr)
call mpas_get_timeInterval(timeStep, dt=dt)
Expand Down

0 comments on commit 66ac386

Please sign in to comment.