Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
ba88041
Add higher-order horizontal pressure gradient design doc
xylar Jun 28, 2026
5907fb7
Promote convergence rate to a verification requirement
xylar Jul 21, 2026
a6b45e9
Verify the centered limit of the new scheme, not the legacy functor
xylar Jul 21, 2026
1109a31
Restate the hydrostatic consistency claim with its real conditions
xylar Jul 28, 2026
b721519
Split the implementation into two phases
xylar Jul 28, 2026
6a23d5e
Say what each test covers and close three gaps
xylar Jul 28, 2026
bfe454d
Drop the vorticity discussion
xylar Jul 28, 2026
08ef74a
Update design to reflect EOS derivative implementation
xylar Jul 29, 2026
394f6d6
Update the finite-volume HPG design with phase 1 findings
xylar Jul 29, 2026
cd6618b
Reduce the finite-volume HPG target to the fixed-pressure geopotential
xylar Jul 30, 2026
6b5ee5a
Difference the fixed-pressure integrand before integrating it
xylar Jul 30, 2026
fd9c663
Correct the design against the reference implementation's measurements
xylar Jul 31, 2026
d71926b
Settle the design's open items against the implementation
xylar Aug 2, 2026
334ff78
Correct what the exact layer increment claims
xylar Aug 2, 2026
fe52f3e
Record what the sea-floor anchor costs where bathymetry steps
xylar Aug 2, 2026
530040a
Move the column scan to the sea-floor anchor and state the gate's con…
xylar Aug 2, 2026
b9fb0c7
Measure assumption A2 directly instead of by a contrast sweep
xylar Aug 2, 2026
ec759b8
Record the Phase 1 results and retire the tilt exponent as a comparison
xylar Aug 2, 2026
abe247f
Record the global resting-state measurement that bears on A4
xylar Aug 2, 2026
2a12174
Connect Requirement 2.1's bar to the measured advantage
xylar Aug 2, 2026
4118ee8
Move the A4 diagnostic after Phase 1, where it can actually run
xylar Aug 2, 2026
8270867
Record the seamount result: z-star passes, sigma is unstable
xylar Aug 3, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 14 additions & 25 deletions components/omega/doc/design/PGrad.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,23 +89,12 @@ $$
T^p_{e,k} = \frac{1}{2d_e}\left(\sum_{i\in CE(e)} -n_{e,i} M_{i,k+1/2} + \sum_{i\in CE(e)} -n_{e,i} M_{i,k-1/2}\right) + \frac{1}{2}\left(\sum_{i\in CE(e)} p_{i,k}\right) \frac{1}{d_e} \sum_{i\in CE(e)} -n_{e,i}\alpha_{i,k} + \frac{1}{d_e} \sum_{i\in CE(e)} -n_{e,i} (\phi_{TP,i} + \phi_{SAL,i}).
$$

### 3.2 High-order Pressure Gradient
The high order pressure gradient will be based on the {ref}`full volume integral form <omega-v1-vh-momentum-reynolds2>` of the geopotential and pressure terms:
$$
T^p &= - \int_A \int_{\tilde{z}_k^{\text{bot}}}^{\tilde{z}_k^{\text{top}}} \rho_0 \, \left( \nabla \left<\Phi\right> \right) \, d\tilde{z} \, dA \\
& - \int_{\partial A} \left( \int_{\tilde{z}_k^{\text{bot}}}^{\tilde{z}_k^{\text{top}}} \rho_0 \left(\left< \alpha \right> \left<p \right> + \left<\alpha^\prime p^\prime\right> \right) \, d\tilde{z} \right) dl \\
& - \int_A \rho_0 \left[ \left< \alpha \right> \left<p \nabla \tilde{z}_k^{\text{top}} \right> + \left<\alpha^\prime \left(p \nabla \tilde{z}_k^{\text{top}}\right)^\prime\right> \right]_{\tilde{z} = \tilde{z}_k^{\text{top}}} \, dA \\
& + \int_A \rho_0 \left[ \left< \alpha \right> \left<p \nabla \tilde{z}_k^{\text{bot}} \right> + \left<\alpha^\prime \left(p \nabla \tilde{z}_k^{\text{bot}}\right)^\prime\right> \right]_{\tilde{z} = \tilde{z}_k^{\text{bot}}} \, dA.
$$
To obtain the expression that will be used, we neglect the turbulent correlations and drop the Reynold's average notation for single variables:
$$
T^p &= - \int_A \int_{\tilde{z}_k^{\text{bot}}}^{\tilde{z}_k^{\text{top}}} \rho_0 \, \left( \nabla \Phi \right) \, d\tilde{z} \, dA \\
& - \int_{\partial A} \left( \int_{\tilde{z}_k^{\text{bot}}}^{\tilde{z}_k^{\text{top}}} \rho_0 \left(\alpha p \right) \, d\tilde{z} \right) dl \\
& - \int_A \rho_0 \left[ \alpha \left<p \nabla \tilde{z}_k^{\text{top}} \right> \right]_{\tilde{z} = \tilde{z}_k^{\text{top}}} \, dA \\
& + \int_A \rho_0 \left[ \alpha \left<p \nabla \tilde{z}_k^{\text{bot}} \right> \right]_{\tilde{z} = \tilde{z}_k^{\text{bot}}} \, dA.
$$
These volume and area integrals will be computed using quadrature to account for the variability of $\alpha$ with the reconstructed values of temperature, salinity, and pressure at the quadrature points.
The complete details for the high-order pressure gradient will be the subject of a future design document.
### 3.2 Finite-volume Pressure Gradient
The `FiniteVolume` pressure gradient starts from the {ref}`full volume integral form <omega-v1-vh-momentum-reynolds2>` of the geopotential and pressure terms.
Because Omega's pseudo-height coordinate is defined as $\tilde{z} = -p/(\rho_0 g)$ with no offset, surfaces of constant $\tilde{z}$ are surfaces of constant pressure, so $\nabla_{\tilde{z}} p \equiv 0$ and that form's pressure terms — the side-wall integral of $\alpha p$ and the two sloping-interface metric terms — sum identically to zero.
The scheme therefore reduces to the geopotential compared at constant pressure, with the variability of $\alpha$ entering through reconstructed temperature, salinity, and pressure.
Note that this holds for any ALE layering of pseudo-height: the layer interfaces themselves are tilted and move in time, and it is precisely their differing pressures in neighbouring columns that the scheme has to resolve.
The complete design — including the reference-state equation-of-state expansion that bounds TEOS-10 cost, the mean-preserving reconstructions, and the discrete hydrostatic consistency property that keeps thin, steeply sloped layers robust — is given in the {ref}`Higher-Order Horizontal Pressure Gradient <omega-design-pressure-grad-high-order>` design document.

%### 3.3 Barotropic Pressure Gradient
%
Expand Down Expand Up @@ -162,8 +151,8 @@ class PressureGrad{

// Instances of functors
PressureGradCentered CenteredPGrad;
PressureGradHighOrder HighOrderPGrad1; // To be implemented later
PressureGradHighOrder HighOrderPGrad2; // Multiple high order options are likely in the future
PressureGradFiniteVolume FiniteVolumePGrad; // see PGradHighOrder.md
// Additional variants may be added in the future

// Pressure gradient choice from config
PressureGradType PressureGradChoice;
Expand All @@ -187,9 +176,9 @@ The user will select a pressure gradient option at runtime in the input yaml fil
An `enum class` will be used to specify options for the pressure gradient used for an Omega simulation:
```c++
enum class PressureGradType{
Centered,
HighOrder1,
HighOrder2
Centered, // 2nd-order Montgomery scheme (this document)
FiniteVolume // layer-integrated finite-volume scheme (see PGradHighOrder.md)
// , <FutureVariant> // additional option, added when implemented
}
```
### 4.2 Methods
Expand Down Expand Up @@ -260,7 +249,7 @@ void PressureGrad::computePressureGrad(const Array2DReal &Tend,
const I4 TimeLevel) {

OMEGA_SCOPE(LocCenteredPGrad, CenteredPGrad);
OMEGA_SCOPE(LocHighOrderPGrad, HighOrderPGrad);
OMEGA_SCOPE(LocFiniteVolumePGrad, FiniteVolumePGrad);
OMEGA_SCOPE(LocMinLayerEdgeBot, MinLayerEdgeBot);
OMEGA_SCOPE(LocMaxLayerEdgeTop, MaxLayerEdgeTop);

Expand Down Expand Up @@ -305,8 +294,8 @@ void PressureGrad::computePressureGrad(const Array2DReal &Tend,
parallelForInner(
Team, KRange,
INNER_LAMBDA(int KChunk) {
LocHighOrderPGrad(Tend, IEdge, KChunk, PressureMid,
Geopotential, SpecVol);
LocFiniteVolumePGrad(Tend, IEdge, KChunk, PressureMid,
Geopotential, SpecVol);
});
});

Expand Down
Loading
Loading