Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Main 20231025 #509

Merged
merged 66 commits into from
Oct 25, 2023
Merged

Main 20231025 #509

merged 66 commits into from
Oct 25, 2023

Conversation

marshallward
Copy link
Member

@marshallward marshallward commented Oct 25, 2023

Merged branch from main, includes updates from NCAR.

Gaea regression: https://gitlab.gfdl.noaa.gov/ogrp/MOM6/-/pipelines/21103 ✔️ 🟡

Do not use GitHub to merge this PR, it will be merged remotely.

gustavo-marques and others added 30 commits April 27, 2022 14:25
Replaces LU_pred to L_diag, since now this logical only controls
if diagnostics should be posted.
This commit adds the latest updates to the vertFPmix subroutine
after Bill Large did some cleaning. We have highlight places in
the code where work must be done.
omega_w2x is the counter-clockwise angle of the wind stress with
respect to the horizontal abscissa (x-coordinate) at tracer
points [rad]. This variable is needed in the vertPFmix subroutine.
This line of code was lost during the last merge.
* Rename MOM_lateral_boundary_diffusion.F90 to
  MOM_hor_bnd_diffusion.F90.
* Following the suggestion from a reviewer, MOM_lateral_boundary_diffusion
  has been renamed to MOM_hor_bnd_diffusion. Many submodules related to the
  'old; lateral diffusion have been renamed throughout the code.
  LBD has been replaced to HBD.
* Tested that answers for GMOM do not change.
Build and store the HBD grid outside the tracer loop since the
same grid is used in all tracers. This makes this module
more computationaly efficient. A GMOM case run for 10 days and with
3 tracer is ~ 7.5 % faster.
add desc argument to log_param calls in MOM_CFC_cap
CFC_BC_FILE must be specified if USE_CFC_CAP=.true.

use hemispheric averages poleward of 10 degrees latitude
linearly interpolate between 10S and 10N

correct bug that atm cfc12 was used in cfc11 flux computation
* Add subroutine hbd_grid_test, which mimics subroutine hbd_grid
  but it is only used in the unit tests;

* Add unit tests for hbd_grid_test and fix existing tests for
  fluxes_layer_method;

* Delete unused code and fix the format of doxygen throughout
  the module.
…OM_CFC_cap

refs moved out of nuopc cap code, MOM_forcing_type, MOM_variables

call CFC_cap_set_forcing in call_tracer_set_forcing

add call to call_tracer_set_forcing in nuopc cap

add arguments to call_tracer_set_forcing

increase width in MOM_CFC_cap unit test output

correct typo in oil_tracer
migrate nearly all refs to CFC_cap into MOM_tracer_flow_control and MOM_CFC_cap
Improvements in the MOM_lateral_boundary_diffusion module
* changes in nuopc cap, infra, and MOM.F90 to receive ensembe id from the coupler (alternative to FMS ensemble mngr)

* multi-instance logfile name correction in nuopc cap

* append ensemble suffix to _doc files

* changes in rpointer and restart file name handling to accommodate multi-instance CESM runs

* remove fms2_io_mod usage in FMS1/MOM_ensemble_manager_infra.F90

* rm whitespace in mom_cap
This commit adds the option to apply a linear decay in the
neutral diffusion fluxes within a transition zone defined
by the boundary layer depths of adjacent columns. This option
is controlled by a new parameter NDIFF_TAPERING, which is only
available when NDIFF_INTERIOR_ONLY=True. By default
NDIFF_TAPERING=False and answers are bitwise identical.
Merge changes from GFDL to main (2023-04-06)
Writes useful fields when the diffusivity of viscosity is less than zero.
The should help understanding the root cause of such cases and facilitate
the necessary adjustments.
Output relevant fields when diff or visc < 0
gustavo-marques and others added 26 commits August 22, 2023 11:43
Follow Marshall Ward suggestion and rearrange the code
to be closer to what the compilers will do (or we hope
they would do).
This commit aims to potentially enhance performance.
Answers are bit-wise identical.
Changes needed for introducing 3D tracer diffusivities
* Add Leith+E

This commit adds the 2D Leith+E closure, which uses a modified 2D Leith biharmonic viscosity paired with a harmonic backscatter. ('Modified' here is not used in the same sense as 'modified 2D Leith'; it just means that the biharmonic coefficient is modified to account for enstrophy backscatter.) Variables are often named 'leithy' to refer to Leith+E.

The parameterization is controlled by three main entries in user_nl_mom:
1. USE_LEITHY = True
2. LEITH_CK = 1.0
3. LEITH_BI_CONST = 8.0

To use Leith+E you should have LAPLACIAN=True and BIHARMONIC=True. (It doesn't hurt to be explicit and also set LEITH_AH=False, along with any other viscous closures, but this is not required. If USE_LEITHY=True it will not use any of the other schemes. It does use the background value of the biharmonic coefficient as a minimum, but ignores the
background harmonic value.) LEITH_CK is the fraction of energy dissipated by the biharmonic term that gets backscattered by the harmonic term (it's a target; the backscatter rate is not exact.) Recommended values between 0 and 1. LEITH_BI_CONST is Upsilon^6 where Upsilon is the ratio between the grid scale and the dissipation scale for enstrophy.
Values should be greater than or equal to 1; 8 is a good place to start.

The code is sensitive to the background value of Ah; specifically, if Ah is too large, the code is unstable. This is because the backscatter coefficient is proportional to Ah, and if Ah is large then you get large backscatter. If your code is unstable, consider reducing, e.g., `AH_VEL_SCALE`.

* Background Ah

This commit updates the code so that it uses the background Ah as
a minimum. Previously, if `SMAGORINSKY_AH = True`, Leith+E would
use the Smag value of Ah as the minimum, which is incorrect.

* Improve logging

Removed `do_not_log` condition on `USE_LEITHY`

* Fix Leithy Logic

Added one line to fix the fact that the code would only work as
intended if either (i) writing out Ah_h, or (ii) in debug mode.
Also swapped .le. and .lt. for <= and <.
* add optional run time info in nuopc cap. Author: Jun Wang
Add option to apply non-local momentum flux
* Makes set_u_at_v and set_v_at_u public

* First draft for fpmix

* Change name of logical

Replaces LU_pred to L_diag, since now this logical only controls
if diagnostics should be posted.

* Updates to vertFPmix

This commit adds the latest updates to the vertFPmix subroutine
after Bill Large did some cleaning. We have highlight places in
the code where work must be done.

* Add missing use for vertFPmix

* Add omega_w2x to fluxes and forces

omega_w2x is the counter-clockwise angle of the wind stress with
respect to the horizontal abscissa (x-coordinate) at tracer
points [rad]. This variable is needed in the vertPFmix subroutine.

* Add mssing call to get_param for FPMIX

This line of code was lost during the last merge.

* Pass wavebands from coupler to wave_parameters_CS

This commit passes the waveband information recieved
from the coupler to wave_parameters_CS. This information
is set to public so that it can be used elsewhere. To
exercise this code the following must be set:

SURFBAND = COUPLER
WAVE_METHOD = SURFACE_BANDS

No answer changes.

* Describe local variables and make code consistent

* Removed L_diag and moved variables in vertFPmix

* Revert order of variables in vertFPmix
* Move mct_cap/ to STALE_mct_cap/. mct cap is no longer supported and will soon be removed for good.

* remove mct from CI testing

* Remove mct test from github workflows
…20230908-candidate

add run time information in NUOPC cap
…candidate-2023-09-13

NCAR to main (2023-09-14)
@marshallward marshallward merged commit e5b64f9 into dev/gfdl Oct 25, 2023
17 checks passed
@marshallward marshallward deleted the main_20231025 branch February 28, 2024 16:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants