Mwarusz/omega/submesoscale eddies#8
Conversation
|
@copilot Please add user and developer documentation for the submesoscale eddy parametrization added in this PR in the same style as the documentation of other components in doc/userGuide and doc/devGuide. |
Implemented in commit 409f413. I added new pages for both guides ( |
|
@copilot In the developer docs please add more detail about inputs to the core methods of the |
Implemented in commit 7cc031e. I expanded the developer guide with a new |
7cc031e to
409f413
Compare
|
@copilot Improve the wording of the developer docs without making substantial changes. |
b003252 to
b257c69
Compare
There was a problem hiding this comment.
Pull request overview
This PR introduces an optional submesoscale mixed-layer instability (MLI) parameterization (“SubmesoEddies”) to Omega, wiring it into the auxiliary-state transport velocity used by pseudo-thickness and tracer advection, and adds accompanying documentation, tests, and machine/build support updates.
Changes:
- Add
SubmesoEddiessingleton (mixed-layer depth, buoyancy gradient, eddy velocity) and initialize/finalize it in the ocean driver lifecycle. - Introduce
TransportAuxVars::NormalTransportVelocityand refactor tendencies to use transport velocity (base flow + optional submeso eddy-induced component). - Update test utilities (
setScalar/setVectorEdge) and add a new unit test forSubmesoEddies, plus documentation and config defaults.
Reviewed changes
Copilot reviewed 73 out of 73 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| components/omega/test/ocn/TendencyTermsTest.cpp | Update test lambdas to match new setScalar/setVectorEdge functor signatures. |
| components/omega/test/ocn/TendenciesTest.cpp | Update test setup calls to pass nullptr ZCoord and updated functor signatures. |
| components/omega/test/ocn/SubmesoEddiesTest.cpp | New unit test exercising mixed-layer depth, buoyancy gradient, and eddy velocity. |
| components/omega/test/ocn/OceanTestCommon.h | Extend setScalar/setVectorEdge to pass element indices and optional Z-coordinates. |
| components/omega/test/ocn/HorzOperatorsTest.cpp | Update operator tests for new setScalar/setVectorEdge signatures. |
| components/omega/test/ocn/ForcingTest.cpp | Update forcing tests for new setScalar/setVectorEdge signatures. |
| components/omega/test/ocn/AuxiliaryVarsTest.cpp | Update aux-var tests for new setScalar/setVectorEdge signatures. |
| components/omega/test/ocn/AuxiliaryStateTest.cpp | Update aux-state test init to pass nullptr ZCoord and updated signatures. |
| components/omega/test/CMakeLists.txt | Adjust test command and add SubmesoEddies test; MPI arg formatting changes. |
| components/omega/src/timeStepping/ForwardBackwardStepper.cpp | Pass tracer array into pseudo-thickness tendency computation. |
| components/omega/src/ocn/Tendencies.h | Extend pseudo-thickness tendency API to accept tracer array. |
| components/omega/src/ocn/Tendencies.cpp | Use AuxState helpers for pseudo-thickness/tracer aux, and switch to transport velocity for advection operators. |
| components/omega/src/ocn/SubmesoEddies.h | New submesoscale eddy parameterization interface (+ linearInterp). |
| components/omega/src/ocn/SubmesoEddies.cpp | New implementation and IO field definitions for submeso diagnostics. |
| components/omega/src/ocn/OceanInit.cpp | Initialize SubmesoEddies during module init. |
| components/omega/src/ocn/OceanFinal.cpp | Destroy SubmesoEddies during finalization. |
| components/omega/src/ocn/auxiliaryVars/TransportAuxVars.h | New aux-var container for normal transport velocity. |
| components/omega/src/ocn/auxiliaryVars/TransportAuxVars.cpp | Register/unregister NormalTransportVelocity field with IO metadata. |
| components/omega/src/ocn/AuxiliaryState.h | Add TransportAux member and new compute methods for transport/pseudo-thickness/tracer aux. |
| components/omega/src/ocn/AuxiliaryState.cpp | Compute and apply submeso eddy-induced velocity into NormalTransportVelocity; refactor aux computations. |
| components/omega/src/CMakeLists.txt | Remove stdc++fs linkage (commented out). |
| components/omega/OmegaBuild.cmake | Allow skipping CIME config in standalone build via OMEGA_SKIP_CIME. |
| components/omega/machines/nocime/workmac-clang.cmake | New “nocime” machine preset for a mac clang/mpich-style build. |
| components/omega/machines/nocime/pm-gpu-gcc.env | New nocime env module file. |
| components/omega/machines/nocime/pm-gpu-gcc.cmake | New nocime cmake preset. |
| components/omega/machines/nocime/pm-cpu-intel.env | New nocime env module file. |
| components/omega/machines/nocime/pm-cpu-intel.cmake | New nocime cmake preset. |
| components/omega/machines/nocime/pm-cpu-gcc.env | New nocime env module file. |
| components/omega/machines/nocime/pm-cpu-gcc.cmake | New nocime cmake preset. |
| components/omega/machines/nocime/liczydlo-gpu-amdclang.cmake | New nocime cmake preset. |
| components/omega/machines/nocime/liczydlo-cpu-gcc.cmake | New nocime cmake preset. |
| components/omega/machines/nocime/liczydlo-cpu-amdclang.cmake | New nocime cmake preset. |
| components/omega/machines/nocime/frontier-gpu-amdclang.env | New nocime env module file. |
| components/omega/machines/nocime/frontier-gpu-amdclang.cmake | New nocime cmake preset. |
| components/omega/machines/nocime/frontier-cpu-gcc.env | New nocime env module file. |
| components/omega/machines/nocime/frontier-cpu-gcc.cmake | New nocime cmake preset. |
| components/omega/machines/nocime/frontier-cpu-amdclang.env | New nocime env module file. |
| components/omega/machines/nocime/frontier-cpu-amdclang.cmake | New nocime cmake preset. |
| components/omega/machines/nocime/chrysalis-intel.env | New nocime env module file. |
| components/omega/machines/nocime/chrysalis-intel.cmake | New nocime cmake preset. |
| components/omega/machines/nocime/blake-pvc-intel.env | New nocime env module file. |
| components/omega/machines/nocime/blake-pvc-intel.cmake | New nocime cmake preset. |
| components/omega/machines/nocime/blake-h100-gcc.env | New nocime env module file. |
| components/omega/machines/nocime/blake-h100-gcc.cmake | New nocime cmake preset. |
| components/omega/machines/nocime/blake-cpu-polaris.env | New nocime env module file. |
| components/omega/machines/nocime/blake-cpu-polaris.cmake | New nocime cmake preset. |
| components/omega/machines/nocime/blake-cpu-intel.env | New nocime env module file. |
| components/omega/machines/nocime/blake-cpu-intel.cmake | New nocime cmake preset. |
| components/omega/machines/nocime/blake-cpu-gcc.env | New nocime env module file. |
| components/omega/machines/nocime/blake-cpu-gcc.cmake | New nocime cmake preset. |
| components/omega/machines/nocime/aurora-gpu-intel.env | New nocime env module file. |
| components/omega/machines/nocime/aurora-gpu-intel.cmake | New nocime cmake preset. |
| components/omega/machines/cime/pm-gpu-nvidiagpu.cmake | New CIME-backed machine preset. |
| components/omega/machines/cime/pm-gpu-gnugpu.cmake | New CIME-backed machine preset. |
| components/omega/machines/cime/pm-cpu-nvidia.cmake | New CIME-backed machine preset. |
| components/omega/machines/cime/pm-cpu-intel.cmake | New CIME-backed machine preset. |
| components/omega/machines/cime/pm-cpu-gnu.cmake | New CIME-backed machine preset. |
| components/omega/machines/cime/frontier-gnu.cmake | New CIME-backed machine preset. |
| components/omega/machines/cime/frontier-craygnu.cmake | New CIME-backed machine preset. |
| components/omega/machines/cime/frontier-craygnu-mphipcc.cmake | New CIME-backed machine preset. |
| components/omega/machines/cime/frontier-craycray.cmake | New CIME-backed machine preset. |
| components/omega/machines/cime/frontier-craycray-mphipcc.cmake | New CIME-backed machine preset. |
| components/omega/machines/cime/chrysalis-intel.cmake | New CIME-backed machine preset. |
| components/omega/machines/cime/chrysalis-gnu.cmake | New CIME-backed machine preset. |
| components/omega/machines/cime/aurora-ifxgpu.cmake | New CIME-backed machine preset. |
| components/omega/machines/cime/aurora-ifx.cmake | New CIME-backed machine preset. |
| components/omega/external/CMakeLists.txt | Adjust GSW-C build flags, adding a Darwin-specific shared-library link mode. |
| components/omega/doc/userGuide/SubmesoEddies.md | New user documentation for configuration and diagnostics. |
| components/omega/doc/devGuide/SubmesoEddies.md | New developer documentation describing algorithms and APIs. |
| components/omega/doc/index.md | Add SubmesoEddies docs to Sphinx toctrees. |
| components/omega/configs/Default.yml | Add default Omega:Submeso configuration block. |
| KOKKOS_INLINE_FUNCTION Real linearInterp(Real x, Real y1, Real x1, Real y2, | ||
| Real x2) { | ||
| const Real A = (y1 - y2) / (x1 - x2); | ||
| const Real B = y1 - A * x1; | ||
| return (x1 == x2) ? y1 : A * x + B; | ||
| } |
| // Replace with global constant when added | ||
| const Real Tiny = 1e-12_Real; | ||
|
|
||
| parallelForOuter( |
| std::numeric_limits<Real>::min(), // min valid value | ||
| std::numeric_limits<Real>::max(), // max valid value |
| else() | ||
| add_test( | ||
| NAME ${test_name} | ||
| COMMAND ../omega_env.sh ./${exe_name} | ||
| COMMAND ./${exe_name} | ||
| ) |
| set(OMEGA_GKLIB_ROOT "/Users/mwarusz/installs/gklib" CACHE STRING "") | ||
| set(OMEGA_METIS_ROOT "/Users/mwarusz/installs/metis" CACHE STRING "") | ||
| set(OMEGA_PARMETIS_ROOT "/Users/mwarusz/installs/parmetis" CACHE STRING "") |
b257c69 to
433bbe5
Compare
433bbe5 to
a3ea9d4
Compare
5a970d3 to
339140a
Compare
No description provided.