Skip to content

Commit

Permalink
Merge pull request #16 from MatthewMasarik-NOAA/comments/sync-dev/uni…
Browse files Browse the repository at this point in the history
…fied

Langmuir updates:  PR to address comments made on NOAA-EMC/WW3 NOAA-EMC#1034
  • Loading branch information
alperaltuntas authored Dec 14, 2023
2 parents 1effbd7 + 308d7a7 commit fe15c2a
Show file tree
Hide file tree
Showing 7 changed files with 42 additions and 45 deletions.
28 changes: 11 additions & 17 deletions model/inp/ww3_grid.inp
Original file line number Diff line number Diff line change
Expand Up @@ -305,25 +305,25 @@ $ limitation and the GSE alleviation.
$
$ Unstructured grids ------------------------------------------------ $
$ UNST parameters : Namelist UNST
$ UGBCCFL : Turns on/off (TRUE/FALSE) the computation of the CFL number on the physical domain boundary.
$ UGBCCFL : Turns on/off (TRUE/FALSE) the computation of the CFL number on the physical domain boundary.
$ If FALSE the explicit scheme can be much faster though stability is not guaranteed
$ (default TRUE)
$ UGOBCAUTO : TRUE: OBC points are taken from type 15 elements (default)
$ FALSE: OBC points must be listed in ww3_grid.inp
$ UGOBCDEPTH : Threshold ( < 0) depth (default -10) for OBC points if UGOBCAUTO is TRUE
$ UGOBCFILE : File name of file for reading boudary (default 'unset')
$ UGOBCFILE : File name of file for reading boudary (default 'unset')
$
$ The following are TRUE/FALSE variables and only one can be TRUE.
$ By default, EXPFSN is TRUE and must be set to false to activate another option
$ The following are TRUE/FALSE variables and only one can be TRUE.
$ By default, EXPFSN is TRUE and must be set to false to activate another option
$ EXPFSN : Activation of N scheme (default option)
$ EXPFSPSI : Activation of PSI scheme
$ EXPFSFCT : Activation of FCT scheme
$ IMPFSN : Activation of N implicit scheme
$ EXPTOTAL : Activation of Block explicit N scheme solver
$ IMPTOTAL : Activation of fully implicit scheme, non splitting
$
$
$ The following TRUE/FALSE variables are only for IMPTOTAL=TRUE
$ IMPREFRACTION : Turn on implicit freq. shift (default FALSE)
$ IMPREFRACTION : Turn on implicit freq. shift (default FALSE)
$ IMPFREQSHIFT : Turn on implicit freq. shift terms (default FALSE)
$ IMPSOURCE : Turn on implicit source terms (default FALSE)
$
Expand All @@ -332,17 +332,17 @@ $ JGS_TERMINATE_DIFFERENCE : Terminate based on the t
$ JGS_TERMINATE_NORM : Terminate based on the norm of the solution (TRUE/FALSE, default FALSE)
$ JGS_USE_JACOBI : Use Jacobi solver family (TRUE/FALSE, default TRUE)
$ JGS_BLOCK_GAUSS_SEIDEL : Use Block Gauss Seidel method for imptotal instead of the conservative jacobi iterator. (TRUE/FALSE, default TRUE)
$ JGS_MAXITER : Max. Number of solver iterations for JGS_TERMINATE_MAXITER (integer, default 100)
$ JGS_PMIN : % of grid points that do not need to converge during solver iteration (real, default 1)
$ JGS_MAXITER : Max. Number of solver iterations for JGS_TERMINATE_MAXITER (integer, default 100)
$ JGS_PMIN : % of grid points that do not need to converge during solver iteration (real, default 1)
$ JGS_DIFF_THR : Implicit solver threshold for JGS_TERMINATE_DIFFERENCE (real, default 1.0e-10)
$ JGS_NORM_THR : Norm of the solution for JGS_TERMINATE_NORM (real, default 1.0e-20)
$ JGS_LIMITER : TRUE: Use total (quasi-steady: limits whole equation) instead of local limiter (un-steady: limits only source terms)
$ FALSE: default
$ FALSE: default
$ JGS_LIMITER_FUNC : 1 - old limiter (default)
$ 2 - alternatnive limiter
$ SETUP_APPLY_WLV : Compute wave setup (TRUE/FALSE, default TRUE)
$ SETUP_APPLY_WLV : Compute wave setup (TRUE/FALSE, default TRUE)
$ SOLVERTHR_SETUP : Solver threshold for setup computations (default 1E-6)
$ CRIT_DEP_SETUP : Critical depth for setup computations (default 0.1)
$ CRIT_DEP_SETUP : Critical depth for setup computations (default 0.1)

$
$ SMC grid propagation : Namelist PSMC and default values
Expand Down Expand Up @@ -457,12 +457,6 @@ $ depth (HSL) type.
$ 0 : Uniform HSL=10m (default)
$ 1 : HSL from coupler
$
$ Output parameters :
$ USS : surface Stokes drift
$ USSX/Y (netCDF: uuss/vuss)
$ USSH : surface layer averaged Stokes drift
$ USSHX/Y (netCDF: uussh/vussh)
$
$ For more info on the Langmuir parameterization, see:
$ Li, Qing, et al. "Langmuir mixing effects on global climate:
$ WAVEWATCH III in CESM." Ocean Modelling 103 (2016): 145-160.
Expand Down
13 changes: 7 additions & 6 deletions regtests/bin/matrix_cmake_datarmor
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ usage ()
{
cat 2>&1 << EOF
Usage: $myname model_dir
Usage: $myname model_dir
Required:
model_dir : path to model dir of WW3 source
EOF
Expand All @@ -51,7 +51,7 @@ main_dir="`cd $main_dir 1>/dev/null 2>&1 && pwd`"


# 1. Set up

export np='28' #number of mpi tasks
export npl='28' #number of mpi tasks for ufs applications and large setups
export npl1='20' #number of mpi tasks for ufs/large setups (b4b check)
Expand Down Expand Up @@ -151,9 +151,10 @@ main_dir="`cd $main_dir 1>/dev/null 2>&1 && pwd`"
export shwtr='y' # shallow water tests
export unstr='y' # unstructured grid tests
export pdlib='y' # unstr with pdlib for domain decomposition and implicit solver
export lmp='y' # Langmuir mixing parameterization
export smcgr='y' # SMC grid test
export rtd='y' # Rotated pole test
export mudice='y' # Mud/Ice and wave interaction tests
export mudice='y' # Mud/Ice and wave interaction tests
export infgrv='y' # Second harmonic generation tests
export uost='y' # ww3_ts4 Unresolved Obstacles Source Term (UOST)
export assim='y' # Restart spectra update
Expand All @@ -178,17 +179,17 @@ main_dir="`cd $main_dir 1>/dev/null 2>&1 && pwd`"
export nth_b4b='y' # Thread Reproducibility
export esmf='n' # ESMF coupling
# export filter='PR3 ST2 UQ'
# The filter does a set of consecutive greps on the
# The filter does a set of consecutive greps on the
# command lines generated by filter.base with the above
# selected options.

# --------------------------------------------------------------------------- #
# 2. Execute matrix.base ... #
# --------------------------------------------------------------------------- #

$main_dir/../regtests/bin/matrix.base

$main_dir/../regtests/bin/matrix_divider_cmake.sh
$main_dir/../regtests/bin/matrix_divider_cmake.sh

# --------------------------------------------------------------------------- #
# End to the matrix #
Expand Down
17 changes: 9 additions & 8 deletions regtests/bin/matrix_cmake_milhydro
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@
# #
# --------------------------------------------------------------------------- #
usage ()
{
{
cat 2>&1 << EOF
Usage: $myname model_dir
Usage: $myname model_dir
Required:
model_dir : path to model dir of WW3 source
EOF
Expand All @@ -41,7 +41,7 @@ EOF
# Convert main_dir to absolute path
main_dir="`cd $main_dir 1>/dev/null 2>&1 && pwd`"

# Set batchq queue, choose modules and other custom variables to fit system and
# Set batchq queue, choose modules and other custom variables to fit system and
# to define headers etc (default to original version if empty)
# 1. Set up
# 1.a Computer/ user dependent set up
Expand All @@ -58,7 +58,7 @@ EOF
echo " export path_build_root=$(dirname $main_dir)/regtests/buildmatrix" >> matrix.head
echo ' [[ -d ${path_build_root} ]] && rm -rf ${path_build_root}' >> matrix.head

echo ' '
echo ' '

if [ "$batchq" = 'slurm' ]
then
Expand Down Expand Up @@ -97,9 +97,10 @@ echo " export path_build_root=$(dirname $main_dir)/regtests/buildmatrix" >> mat
export shwtr='y' # shallow water tests
export unstr='y' # unstructured grid tests
export pdlib='y' # unstr with pdlib for domain decomposition and implicit solver
export lmp='y' # Langmuir mixing parameterization
export smcgr='y' # SMC grid test
export rtd='y' # Rotated pole test
export mudice='y' # Mud/Ice and wave interaction tests
export mudice='y' # Mud/Ice and wave interaction tests
export infgrv='y' # Second harmonic generation tests
export uost='y' # ww3_ts4 Unresolved Obstacles Source Term (UOST)
export assim='y' # Restart spectra update
Expand All @@ -124,14 +125,14 @@ echo " export path_build_root=$(dirname $main_dir)/regtests/buildmatrix" >> mat
export npl_b4b='n' # MPI task Reproducibility
export nth_b4b='n' # Thread Reproducibility
export esmf='n' # ESMF coupling
# The filter does a set of consecutinve greps on the
# The filter does a set of consecutinve greps on the
# command lines generated by filter.base with the above
# selected options.

# --------------------------------------------------------------------------- #
# 2. Execute matrix.base ... #
# --------------------------------------------------------------------------- #


$main_dir/../regtests/bin/matrix.base

Expand All @@ -146,7 +147,7 @@ echo " export path_build_root=$(dirname $main_dir)/regtests/buildmatrix" >> mat
do
echo "sbatch < $file" >> msuball.sh
done
fi
fi

# --------------------------------------------------------------------------- #
# End to the matrix #
Expand Down
11 changes: 6 additions & 5 deletions regtests/bin/matrix_cmake_ukmo_cray
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ usage ()
{
cat 2>&1 << EOF
Usage: $myname model_dir
Usage: $myname model_dir
Required:
model_dir : path to model dir of WW3 source
EOF
Expand Down Expand Up @@ -139,14 +139,15 @@ fi
export shwtr='y' # shallow water tests
export unstr='y' # unstructured grid tests
export pdlib='y' # unstr with pdlib for domain decomposition and implicit solver
export lmp='y' # Langmuir mixing parameterization
export smcgr='y' # SMC grid test
export rtd='y' # Rotated pole test
export mudice='y' # Mud/Ice and wave interaction tests
export mudice='y' # Mud/Ice and wave interaction tests
export infgrv='y' # Second harmonic generation tests
export uost='y' # ww3_ts4 Unresolved Obstacles Source Term (UOST)
export assim='y' # Restart spectra update
export oasis='y' # Atmosphere, ocean, and ice coupling using oasis
export calendar='y' # Calendar type
export calendar='y' # Calendar type
export confignc='y' # Configurable netCDF meta data (ww3_ounf)

export multi01='y' # mww3_test_01 (wetting and drying)
Expand All @@ -166,14 +167,14 @@ fi
export nth_b4b='y' # Thread Reproducibility
export esmf='n' # ESMF coupling
# export filter='PR3 ST2 UQ'
# The filter does a set of consecutinve greps on the
# The filter does a set of consecutinve greps on the
# command lines generated by filter.base with the above
# selected options.

# --------------------------------------------------------------------------- #
# 2. Execute matrix.base ... #
# --------------------------------------------------------------------------- #

$main_dir/../regtests/bin/matrix.base

$main_dir/../regtests/bin/matrix_divider_cmake.sh
Expand Down
4 changes: 2 additions & 2 deletions regtests/ww3_tp2.22/input/ww3_ounf.inp
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,15 @@ $ file for a full documentation of field output options. Namelist type
$ selection is used here (for alternative F/T flags, see ww3_shel.inp).
$
N
HS T01 DIR SPR USS USSH
HS EF T01 DIR SPR USS USSH
$
$--------------------------------------------------------------------- $
$ netCDF version [3,4]
$ and variable type 4 [2 = SHORT, 3 = it depends , 4 = REAL]
$ swell partitions [0 1 2 3 4 5]
$ variables in same file [T] or not [F]
$
3 4
4 4
0 1 2
T
$
Expand Down
12 changes: 6 additions & 6 deletions regtests/ww3_tp2.22/input/ww3_ounp.inp
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
$ -------------------------------------------------------------------- $
$ WAVEWATCH III NETCDF Point output post-processing $
$--------------------------------------------------------------------- $
$ First output time (yyyymmdd hhmmss), increment of output (s),
$ First output time (yyyymmdd hhmmss), increment of output (s),
$ and number of output times.
$
19680606 000000 21600. 1000
$
$ Points requested --------------------------------------------------- $
$
$ Define points index for which output is to be generated.
$ Define points index for which output is to be generated.
$ If no one defined, all points are selected
$ One index number per line, negative number identifies end of list.
1
Expand All @@ -21,16 +21,16 @@ $--------------------------------------------------------------------- $
$ file prefix
$ number of characters in date [4(yearly),6(monthly),8(daily),10(hourly)]
$ netCDF version [3,4]
$ points in same file [T] or not [F]
$ points in same file [T] or not [F]
$ and max number of points to be processed in one pass
$ output type ITYPE [0,1,2,3]
$ flag for global attributes WW3 [0] or variable version [1-2-3-4]
$ flag for dimensions order time,station [T] or station,time [F]
$
ww3.
6
3
T 150
4
T 150
1
0
T
Expand Down Expand Up @@ -72,7 +72,7 @@ $ 2 : Mean wave pars.
$ 3 : Nondimensional pars. (U*)
$ 4 : Nondimensional pars. (U10)
$ 5 : 'Validation table'
$ 6 : WMO standard output
$ 6 : WMO standard output
$ 4
$
$ -------------------------------------------------------------------- $
Expand Down
2 changes: 1 addition & 1 deletion regtests/ww3_tp2.22/input/ww3_outf.inp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ $ -----------------------------------------
19680606 000000 3600. 12
$
N
HS T01 DIR SPR USS USSH
HS EF T01 DIR SPR USS USSH
$
1 0
$
Expand Down

0 comments on commit fe15c2a

Please sign in to comment.