Private types and functions
Documentation for Imaginocean.jl's internal interface.
Imaginocean
Imaginocean.get_cartesian_nodes_and_vertices — Methodget_cartesian_nodes_and_vertices(grid::Union{LatitudeLongitudeGrid, OrthogonalSphericalShellGrid}, ℓx, ℓy, ℓz)Return the cartesian coordinates of the horizontal nodes of the grid at locations ℓx, ℓy, and ℓz on the unit sphere and also the corresponding coordinates of the four vertices that determine the cell surrounding each node.
Imaginocean.get_lat_lon_nodes_and_vertices — Methodget_lat_lon_nodes_and_vertices(grid, ℓx, ℓy, ℓzs; lower_limit=-180)Return the latitude-longitude coordinates of the horizontal nodes of the grid at locations ℓx, ℓy, and ℓz and also the coordinates of the four vertices that determine the cell surrounding each node.
Imaginocean.get_latitude_vertices — Methodget_latitude_vertices(i, j, k, grid::Union{LatitudeLongitudeGrid, OrthogonalSphericalShellGrid}, ℓx, ℓy, ℓz)Return the latitudes that correspond to the four vertices of cell i, j, k at location (ℓx, ℓy, ℓz). The first vertex is the cell's Southern-Western oneλand the rest follow in counter-clockwise order.
Imaginocean.get_longitude_vertices — Methodget_longitude_vertices(i, j, k, grid::Union{LatitudeLongitudeGrid, OrthogonalSphericalShellGrid}, ℓx, ℓy, ℓz)Return the longitudes that correspond to the four vertices of cell i, j, k at location (ℓx, ℓy, ℓz). The first vertex is the cell's Southern-Western one and the rest follow in counter-clockwise order.
Imaginocean.lat_lon_to_cartesian — Methodlat_lon_to_cartesian(longitude, latitude; radius=1)Convert $(λ, φ) = ($longitude$,$latitude$)$ coordinates (in degrees) to cartesian coordinates $(x, y, z)$ on a sphere with radius, $R$, i.e.,
\[\begin{aligned} x &= R \cos(λ) \cos(φ), \\ y &= R \sin(λ) \cos(φ), \\ z &= R \sin(φ). \end{aligned}\]
Imaginocean.lat_lon_to_x — Methodlat_lon_to_x(longitude, latitude)Convert (longitude, latitude) coordinates (in degrees) to cartesian x on the unit sphere.
Imaginocean.lat_lon_to_y — Methodlat_lon_to_y(longitude, latitude)Convert (longitude, latitude) coordinates (in degrees) to cartesian y on the unit sphere.
Imaginocean.lat_lon_to_z — Methodlat_lon_to_z(longitude, latitude)Convert (longitude, latitude) coordinates (in degrees) to cartesian z on the unit sphere.
Imaginocean.longitude_domain — Methodlongitude_domain(longitude; lower_limit = -180)Bring longitude to domain [lower_limit, lower_limit + 360] (in degrees). By default, lower_limit = -180 implying longitude domain $[-180, 180]$.
Examples
julia> using Imaginocean: longitude_domain
julia> longitude_domain(400)
40
julia> longitude_domain(-50)
-50
julia> longitude_domain(-50; lower_limit=0)
310MakieCore.convert_arguments — MethodMakie.convert_arguments(P::Type{<:AbstractPlot}, field::Field, k_index::Int)Convert an Oceananigans.jl Field with non-flat horizontal dimensions at vertical index k_index to arguments that can be plotted as a surface in Makie.jl.