Skip to content

Commit

Permalink
fix unitialized logical var in MOM_MEKE
Browse files Browse the repository at this point in the history
  • Loading branch information
alperaltuntas committed Feb 10, 2020
1 parent 63cf741 commit 3540446
Showing 1 changed file with 9 additions and 11 deletions.
20 changes: 9 additions & 11 deletions src/parameterizations/lateral/MOM_MEKE.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1058,18 +1058,16 @@ logical function MEKE_init(Time, G, US, param_file, diag, CS, MEKE, restart_CS)
call get_param(param_file, mdl, "MEKE_EQUILIBRIUM_ALT", CS%MEKE_equilibrium_alt, &
"If true, use an alternative formula for computing the (equilibrium)"//&
"initial value of MEKE.", default=.false.)
if (CS%MEKE_equilibrium_alt) then
call get_param(param_file, mdl, "MEKE_EQUILIBRIUM_RESTORING", CS%MEKE_equilibrium_restoring, &
"If true, restore MEKE back to its equilibrium value, which is calculated at"//&
"each time step.", default=.false.)
if (CS%MEKE_equilibrium_restoring) then
call get_param(param_file, mdl, "MEKE_RESTORING_TIMESCALE", MEKE_restoring_timescale, &
"The timescale used to nudge MEKE toward its equilibrium value.", units="s", &
default=1e6, scale=US%T_to_s)
CS%MEKE_restoring_rate = 1.0 / MEKE_restoring_timescale
endif

call get_param(param_file, mdl, "MEKE_EQUILIBRIUM_RESTORING", CS%MEKE_equilibrium_restoring, &
"If true, restore MEKE back to its equilibrium value, which is calculated at"//&
"each time step.", default=CS%MEKE_equilibrium_alt)
if (CS%MEKE_equilibrium_restoring) then
call get_param(param_file, mdl, "MEKE_RESTORING_TIMESCALE", MEKE_restoring_timescale, &
"The timescale used to nudge MEKE toward its equilibrium value.", units="s", &
default=1e6, scale=US%T_to_s)
CS%MEKE_restoring_rate = 1.0 / MEKE_restoring_timescale
endif

call get_param(param_file, mdl, "MEKE_FRCOEFF", CS%MEKE_FrCoeff, &
"The efficiency of the conversion of mean energy into "//&
"MEKE. If MEKE_FRCOEFF is negative, this conversion "//&
Expand Down

0 comments on commit 3540446

Please sign in to comment.