Ir al contenido

underwater.sound_speed

Esta página aún no está disponible en tu idioma.

Speed of sound in sea water (empirical equations).

Three coexisting equations for the sound speed c as a function of temperature, salinity and depth/pressure, selectable through model:

  • "unesco" — the UNESCO / Chen & Millero (1977) algorithm, the international standard, in the Wong & Zhu (1995) ITS-90 recalculation. Default.
  • "del_grosso" — the Del Grosso (1974) equation (Wong & Zhu 1995 form), a high-accuracy alternative over a narrower domain.
  • "mackenzie" — the Mackenzie (1981) nine-term depth-based equation.

The UNESCO and Del Grosso equations use pressure, not depth, so a depth is first converted with the Leroy & Parthiot (1998) standard-ocean formula (depth_to_pressure). SoundSpeedProfile evaluates c over a depth profile and exposes the sound-speed gradient.

Sources (clean-room, implemented from the equations, validated by cross-model agreement and the canonical Mackenzie check value 1550.744 m/s at 25 °C, 35 ppt, 1000 m): NPL Technical Guide “Speed of Sound in Sea-Water” (Wong & Zhu 1995 coefficient tables), Mackenzie (1981) JASA 70, Del Grosso (1974) JASA 56, Leroy & Parthiot (1998) JASA 103.

Auto-generated from the source docstrings by scripts/generate_api_docs.py (make api-docs). Do not edit by hand.

depth_to_pressure(depth: float, latitude: float = 45.0) -> float

Gauge pressure at a given ocean depth (Leroy & Parthiot 1998), in MPa.

Standard-ocean formula (an ideal medium of 0 °C and 35 ppt); no local corrections are applied.

Parameters

NameDescription
depthDepth below the surface Z, in metres (>= 0).
latitudeLatitude φ, in degrees (default 45°).

Returns: Gauge pressure, in megapascals.

Raises

ExceptionWhen
ValueErrorIf the depth is negative or non-finite.
sea_water_sound_speed(
temperature: float,
salinity: float,
depth: float,
*,
model: str = 'unesco',
latitude: float = 45.0,
) -> float

Speed of sound in sea water, in metres per second.

Parameters

NameDescription
temperatureTemperature T, in degrees Celsius.
salinitySalinity S, in parts per thousand (PSU).
depthDepth below the surface, in metres (>= 0).
model"unesco" (default), "del_grosso" or "mackenzie".
latitudeLatitude for the depth→pressure conversion, in degrees (used by "unesco" and "del_grosso"; default 45°).

Returns: The sound speed c, in m/s.

Raises

ExceptionWhen
ValueErrorIf model is unknown or an input is non-finite.
sound_speed_profile(
depths: NDArray[np.float64] | list[float],
temperatures: NDArray[np.float64] | list[float] | float,
salinities: NDArray[np.float64] | list[float] | float,
*,
model: str = 'unesco',
latitude: float = 45.0,
) -> SoundSpeedProfile

Evaluate a sound-speed profile over a depth column.

Parameters

NameDescription
depthsDepths, in metres (1-D, non-negative, increasing).
temperaturesTemperature per depth, in °C (array or a scalar broadcast to every depth).
salinitiesSalinity per depth, in PSU (array or scalar).
modelSound-speed equation (see sea_water_sound_speed).
latitudeLatitude for the depth→pressure conversion, in degrees.

Returns: A SoundSpeedProfile.

Raises

ExceptionWhen
ValueErrorIf the inputs are invalid.
SoundSpeedProfile(
depth: NDArray[np.float64],
sound_speed: NDArray[np.float64],
gradient: NDArray[np.float64],
model: str,
)

Sound-speed profile c(z) over a column of water.

Attributes

NameDescription
depthDepths, in metres (increasing downward).
sound_speedSound speed at each depth, in m/s.
gradientVertical sound-speed gradient dc/dz, in (m/s)/m.
modelThe equation used.
SoundSpeedProfile.plot(
ax: Axes | None = None,
*,
language: str = 'en',
**kwargs: Any,
) -> Axes

Plot the sound-speed profile (speed vs depth, depth increasing down).