polaris.tasks.ocean.seamount.init_utils.compute_tracers
- polaris.tasks.ocean.seamount.init_utils.compute_tracers(config: PolarisConfigParser, z_mid: DataArray) tuple[DataArray, DataArray][source]
Compute the temperature and salinity that reproduce the Beckmann and Haidvogel stratification under the configured equation of state.
Salinity is constant, so all of the stratification is carried by temperature. For
eos_type = linearthe linear equation of state is inverted algebraically; foreos_type = teos-10the tracers are conservative temperature and absolute salinity, and the inversion is throughpolaris.ocean.eos.ct_from_potential_density().Both branches reproduce the same potential density, so the two equations of state give the same buoyancy stratification and differ only in how density depends on pressure.
- Parameters:
config (polaris.config.PolarisConfigParser) – Configuration with the
[seamount]and[ocean]equation of state options.z_mid (xarray.DataArray) – The geometric height (m, negative down) of the layer midpoints.
- Returns:
temperature (xarray.DataArray) – Potential temperature for a linear equation of state, conservative temperature for TEOS-10 (degC).
salinity (xarray.DataArray) – Practical salinity for a linear equation of state, absolute salinity for TEOS-10.