Hypsography

ClimaCore.Hypsography.LinearAdaptionType
LinearAdaption(surface)

Locate the levels by linear interpolation between the surface and the top of the domain, using the method of [12]: $z = z_{ref} + (1 - z_{ref} / z_{top})\, z_{surface}$.

Fields

  • surface: surface elevation [m], a ZPoint or a Field of ZPoints.
source
ClimaCore.Hypsography.SLEVEAdaptionType
SLEVEAdaption(surface, ηₕ, s)

Locate the vertical levels with a hyperbolic-sine decay of the terrain influence between the surface and the top of the domain, using the method of [13], modified so that no warping is applied above the generalized coordinate ηₕ.

Fields

  • surface: surface elevation [m], a ZPoint or a Field of ZPoints.
  • ηₕ: normalized height z_ref / z_top above which the levels are flat [-], with 0 ≤ ηₕ ≤ 1.
  • s: decay scale of the terrain influence as a fraction of z_top [-].

ref_z_to_physical_z throws an error when the decay scale s * z_top does not exceed the surface elevation.

source
ClimaCore.Hypsography.diffuse_surface_elevation!Function
diffuse_surface_elevation!(f::Field; κ = 1e8, maxiter = 100, dt = 1e-1)

Smooth the surface elevation field f in place with second-order diffusion, before passing it to a HypsographyAdaption. Returns f.

A weak-form spectral Laplacian is applied to f with maxiter forward-Euler steps of size dt and diffusivity κ; a weighted DSS is applied to the Laplacian after each step. f is a Field of Reals or of ZPoints.

Keyword Arguments

  • κ = 1e8: diffusivity [m²/s].
  • maxiter = 100: number of forward-Euler steps.
  • dt = 1e-1: time step [s].

The default parameters suit spherical domains with zmax - zsfc of order 10⁴ m.

Examples

diffuse_surface_elevation!(z_surface)
adaption = Hypsography.LinearAdaption(z_surface)
source
ClimaCore.Hypsography.ref_z_to_physical_zFunction
ref_z_to_physical_z(adaption::HypsographyAdaption, z_ref::ZPoint, z_top::ZPoint) -> ZPoint

Convert the reference coordinate z_ref to the physical coordinate as prescribed by adaption, for a domain whose top is at z_top.

Each HypsographyAdaption subtype implements this method; it is the inverse of physical_z_to_ref_z.

source
ClimaCore.Hypsography.physical_z_to_ref_zFunction
physical_z_to_ref_z(adaption::HypsographyAdaption, z_phys::ZPoint, z_top::ZPoint) -> ZPoint

Convert the physical coordinate z_phys to the reference coordinate as prescribed by adaption, for a domain whose top is at z_top.

This is the inverse of ref_z_to_physical_z. It is used for remapping and is not implemented for SLEVEAdaption.

source