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

Bring in Bill Large's Stokes MOST updates #94

Merged
merged 11 commits into from
Aug 14, 2024

Conversation

mnlevy1981
Copy link
Contributor

We are testing these changes in MOM6 - they should be bit-for-bit identical in current configurations, but provide a mechanism for enabling Stokes MOST in the KPP module.

Cleaned up unused variables, also removed trailing white space.
Mostly adding protex comments to new functions and standardizing comments in if
/ else / endif statements
Replaced f90pdf call in make_protex_file with a protex script from the internet
and then call pdflatex several times on resulting tex file. The table of
contents isn't quite complete, but scanning through the rest of the document it
looks okay.
@mnlevy1981 mnlevy1981 marked this pull request as ready for review August 12, 2024 21:28
Found a better protex script to use as a base (courtesy of GEOS-Chem at Harvard
- I believe this is the group that provided the original f90pdf script that we
were previously using). Made a few tweaks to get it working with modern perl
(based on changes from the previous protex script I had found), and also
cleaned up a lot of the protex comments in the source code itself.
Now the link from the table of contents to text is blue text (previously black
text in a blue box), and the link is only the page number (makes the TOC more
readable, since it's mostly black text).
Used tex formatting for some of the equations in KPP descriptions, removed all
the "Only those used by entire module" USES blocks
Auto-generated tex file no longer references NASA contributor to protex project
Replace hard tabs with two spaces (caught by consistency check)
@mnlevy1981 mnlevy1981 merged commit 3ec78ba into CVMix:master Aug 14, 2024
alperaltuntas pushed a commit to NCAR/MOM6 that referenced this pull request Sep 9, 2024
This PR revises the formulation of the legacy K-profile parameterization (KPP) ocean boundary layer scheme. It incorporates:

1.  a non-local momentum flux—the Flux-profile parameterization (`FPMIX`); when the local shear is not aligned with the wind, this scheme adds a non-local momentum flux in the direction of the wind; and 
2.  mixing with and without waves following the Monin-Obukhov Similarity Theory expanded to include Stokes drift (`STOKES_MOST`). This option provides the transition from waveless to ocean surface waves in any stage of growth or decay.

**Summary:**

* Uncomment omega w2x entries;
* Simplify the nonlocal increments in `vertFPMix`;
* In the call to `CVmix_kpp_compute_unresolved_shear`, passes the 2D surface buoyancy flux (`surfBuoyFlux2`) instead of the 1D version (`surfBuoyFlux`), which is preferable. **This is answer changing**;
* Remove `uold` and `vold` diagnostics. These were used in an alternative time-stepping scheme that is now obsolete; 
* Pass boundary layer depths to the RK2 and add consistency check to make sure `FPMix` is always used with `SPLIT`;
* Add the capability to mix down the Eulerian gradient instead of the Lagrangian;
* Make a minimum set of `FPMix` diagnostics available.

This PR relies on CVMix/CVMix-src#94. 

New diagnostics:
```

"StokesXI"  
    ! modules: {ocean_model,ocean_model_d2}
    ! long_name: Stokes Similarity Parameter
    ! units: nondim
    ! cell_methods: xh:mean yh:mean area:mean

"Lam2"  
    ! modules: {ocean_model,ocean_model_d2}
    ! long_name: Ustk0_ustar
    ! units: nondim
    ! cell_methods: xh:mean yh:mean area:mean

"uE_h" 
    ! modules: {ocean_model,ocean_model_z,ocean_model_rho2,ocean_model_d2,ocean_model_z_d2,ocean_model_rho2_d2}
    ! long_name: x-zonal Eulerian
    ! units: m s-1
    ! cell_methods: xh:mean yh:mean zl:mean area:mean
    ! variants: {uE_h,uE_h_xyave}

"vE_h" 
    ! modules: {ocean_model,ocean_model_z,ocean_model_rho2,ocean_model_d2,ocean_model_z_d2,ocean_model_rho2_d2}
    ! long_name: y-merid Eulerian
    ! units: m s-1
    ! cell_methods: xh:mean yh:mean zl:mean area:mean
    ! variants: {vE_h,vE_h_xyave}

"uInc_h"  
    ! modules: {ocean_model,ocean_model_z,ocean_model_rho2,ocean_model_d2,ocean_model_z_d2,ocean_model_rho2_d2}
    ! long_name: x-zonal Eulerian
    ! units: m s-1
    ! cell_methods: xh:mean yh:mean zl:mean area:mean
    ! variants: {uInc_h,uInc_h_xyave}

"vInc_h"  
    ! modules: {ocean_model,ocean_model_z,ocean_model_rho2,ocean_model_d2,ocean_model_z_d2,ocean_model_rho2_d2}
    ! long_name: x-zonal Eulerian
    ! units: m s-1
    ! cell_methods: xh:mean yh:mean zl:mean area:mean
    ! variants: {vInc_h,vInc_h_xyave}

"uStk" 
    ! modules: {ocean_model,ocean_model_z,ocean_model_rho2,ocean_model_d2,ocean_model_z_d2,ocean_model_rho2_d2}
    ! long_name: x-FP du increment
    ! units: m s-1
    ! cell_methods: xh:mean yh:mean zl:mean area:mean
    ! variants: {uStk,uStk_xyave}

"vStk"  
    ! modules: {ocean_model,ocean_model_z,ocean_model_rho2,ocean_model_d2,ocean_model_z_d2,ocean_model_rho2_d2}
    ! long_name: y-FP dv increment
    ! units: m s-1
    ! cell_methods: xh:mean yh:mean zl:mean area:mean
    ! variants: {vStk,vStk_xyave}

"Omega_tau2s" 
    ! modules: {ocean_model,ocean_model_z,ocean_model_rho2,ocean_model_d2,ocean_model_z_d2,ocean_model_rho2_d2}
    ! long_name: Stress direction from shear
    ! units: radians
    ! cell_methods: xh:mean yh:mean zi:point area:mean
    ! variants: {Omega_tau2s,Omega_tau2s_xyave}

"Omega_tau2w"  
    ! modules: {ocean_model,ocean_model_z,ocean_model_rho2,ocean_model_d2,ocean_model_z_d2,ocean_model_rho2_d2}
    ! long_name: Stress direction from wind
    ! units: radians
    ! cell_methods: xh:mean yh:mean zi:point area:mean
    ! variants: {Omega_tau2w,Omega_tau2w_xyave}

"uStk0"  
    ! modules: {ocean_model,ocean_model_d2}
    ! long_name: Zonal Surface Stokes
    ! units: m s-1
    ! cell_methods: xh:mean yh:mean area:mean

"vStk0"  
    ! modules: {ocean_model,ocean_model_d2}
    ! long_name: Merid Surface Stokes
    ! units: m s-1
    ! cell_methods: xh:mean yh:mean area:mean
```
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.

1 participant