← Vector field tour
LESSON D · RUNNABLE BASELINEToward shallow water

One conservative pressure step + one passive transport audit

Make the variables
earn their place.

This first model keeps height and tangent velocity on vertices, derives an oriented edge 1-form for audits, and advances the linear gravity-wave equations. A passive dye visualizes velocity without entering pressure or energy. The physical wave state remains intentionally simple so the operator pair is tested before curvature, nonlinear transport, or wet/dry fronts.

BASELINE EQUATIONS uⁿ⁺¹ = uⁿ − Δt g G hⁿ hⁿ⁺¹ = hⁿ − Δt H D uⁿ⁺¹ qⁿ⁺¹(x) = qⁿ(x − Δt u) diagnostic only

D = −Gᵀ under the uniform vertex mass. The adjointness defect below tests the implementation rather than asking you to trust the notation.

RUNNING NOWh at vertices + u in vertex tangent framesphysical = { h, u } · diagnostic = { q }

Directly visual and continuous with the integrability lessons. Pressure adds a gradient, so initially irrotational velocity stays curl-free.

DERIVED, NEVER HIDDENα on oriented edgesαᵢⱼ = ½(uᵢ + uⱼ) · eᵢⱼ

Use this transfer for flux and circulation audits. It is a representation map, not a claim that vertex vectors are already 1-forms.

RESEARCH BRANCHvorticity ζ + divergence δ (or streamfunction ψ)ζ = curl u · n

A vorticity-based formulation exposes rotational modes and global harmonic content differently. The “seed vortex” button makes the missing mode visible before students replace the state.

LIVE STATEheight perturbation + vertex velocity
CFL —
time0
mass drift
energy
curl RMS
G/D adjoint defect
DIAGNOSTIC HISTORYcyan = energy · pink = |mass drift|
NEXT RESEARCH QUESTION

Choose new variables without losing the audits.

A vorticity/divergence or vorticity/streamfunction state should reconstruct velocity, preserve global harmonic modes, and still provide the edge flux used by continuity. Keep the same manufactured tests while swapping only that middle representation.

  1. A
    Replace the state.

    Store ζ and δ (or ψ), plus the two harmonic periods on a torus.

  2. B
    Reconstruct u.

    Use the Hodge split and report the residual and gauge conditions.

  3. C
    Reuse the contracts.

    Mass drift, energy, curl, adjointness, and edge flux must still be visible.