Skip to content

Commit

Permalink
Minor get_param call reformatting
Browse files Browse the repository at this point in the history
  Revised get_param calls to put the units and scale arguments on the same line,
to help detect inconsistent settings.  All answers and output are bitwise
identical.
  • Loading branch information
Hallberg-NOAA authored and marshallward committed Apr 2, 2022
1 parent 6bfd073 commit 063ef75
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 8 deletions.
4 changes: 2 additions & 2 deletions src/user/Phillips_initialization.F90
Original file line number Diff line number Diff line change
Expand Up @@ -265,8 +265,8 @@ subroutine Phillips_initialize_sponges(G, GV, US, tv, param_file, CSp, h)
"The fractional depth where the stratificaiton is centered.", &
units="nondim", default = 0.5)
call get_param(param_file, mdl, "SPONGE_RATE", damp_rate, &
"The rate at which the zonal-mean sponges damp.", units="s-1", &
default = 1.0/(10.0*86400.0), scale=US%T_to_s)
"The rate at which the zonal-mean sponges damp.", &
units="s-1", default = 1.0/(10.0*86400.0), scale=US%T_to_s)

call get_param(param_file, mdl, "JET_WIDTH", jet_width, &
"The width of the zonal-mean jet.", units="km", &
Expand Down
4 changes: 2 additions & 2 deletions src/user/external_gwave_initialization.F90
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ subroutine external_gwave_initialize_thickness(h, G, GV, US, param_file, just_re

if (.not.just_read) call log_version(param_file, mdl, version, "")
call get_param(param_file, mdl, "SSH_ANOMALY_HEIGHT", ssh_anomaly_height, &
"The vertical displacement of the SSH anomaly. ", units="m", &
fail_if_missing=.not.just_read, do_not_log=just_read, scale=US%m_to_Z)
"The vertical displacement of the SSH anomaly. ", units="m", scale=US%m_to_Z, &
fail_if_missing=.not.just_read, do_not_log=just_read)
call get_param(param_file, mdl, "SSH_ANOMALY_WIDTH", ssh_anomaly_width, &
"The lateral width of the SSH anomaly. ", units="coordinate", &
fail_if_missing=.not.just_read, do_not_log=just_read)
Expand Down
7 changes: 3 additions & 4 deletions src/user/user_change_diffusivity.F90
Original file line number Diff line number Diff line change
Expand Up @@ -205,8 +205,8 @@ subroutine user_change_diff_init(Time, G, GV, US, param_file, diag, CS)
!! point to the control
!! structure for this module.

! This include declares and sets the variable "version".
#include "version_variable.h"
! This include declares and sets the variable "version".
# include "version_variable.h"
character(len=40) :: mdl = "user_set_diffusivity" ! This module's name.
character(len=200) :: mesg
integer :: i, j, is, ie, js, je
Expand All @@ -228,8 +228,7 @@ subroutine user_change_diff_init(Time, G, GV, US, param_file, diag, CS)
call log_version(param_file, mdl, version, "")
call get_param(param_file, mdl, "USER_KD_ADD", CS%Kd_add, &
"A user-specified additional diffusivity over a range of "//&
"latitude and density.", default=0.0, units="m2 s-1", &
scale=US%m2_s_to_Z2_T)
"latitude and density.", default=0.0, units="m2 s-1", scale=US%m2_s_to_Z2_T)
if (CS%Kd_add /= 0.0) then
call get_param(param_file, mdl, "USER_KD_ADD_LAT_RANGE", CS%lat_range(:), &
"Four successive values that define a range of latitudes "//&
Expand Down

0 comments on commit 063ef75

Please sign in to comment.