.. DO NOT EDIT. .. THIS FILE WAS AUTOMATICALLY GENERATED BY SPHINX-GALLERY. .. TO MAKE CHANGES, EDIT THE SOURCE PYTHON FILE: .. "api/gallery/oceanography/plot_08_ekman_dead_water.py" .. LINE NUMBERS ARE GIVEN BELOW. .. only:: html .. note:: :class: sphx-glr-download-link-note :ref:`Go to the end ` to download the full example code or to run this example in your browser via JupyterLite. .. rst-class:: sphx-glr-example-title .. _sphx_glr_api_gallery_oceanography_plot_08_ekman_dead_water.py: Ekman's dead water (1904) ========================= On Nansen's Fram expedition the ship slowed to a crawl in fjords where a thin layer of meltwater lay over salty sea water. Vagn Walfrid Ekman showed that the ship was making waves on the hidden density jump. Those internal waves travel at about ``sqrt(g' h)`` with the reduced gravity ``g' = g d_rho / rho``, a few tens of centimetres per second, so a slow ship pours its energy into them. .. GENERATED FROM PYTHON SOURCE LINES 12-31 .. image-sg:: /api/gallery/oceanography/images/sphx_glr_plot_08_ekman_dead_water_001.png :alt: Waves on a hidden density jump :srcset: /api/gallery/oceanography/images/sphx_glr_plot_08_ekman_dead_water_001.png :class: sphx-glr-single-img .. code-block:: Python import matplotlib.pyplot as plt import numpy as np from earthsciencekit.constants import GRAVITY from earthsciencekit.oceanography import internal_wave_speed, reduced_gravity, shallow_wave_speed upper = np.linspace(0.5, 10, 200) fig, ax = plt.subplots() for contrast in [5, 10, 20]: gprime = reduced_gravity(contrast, 1025, GRAVITY) deep_limit = internal_wave_speed(gprime, upper, 1e6) np.testing.assert_allclose(deep_limit / shallow_wave_speed(upper, GRAVITY), np.sqrt(contrast / 1025), rtol=1e-5) ax.plot(upper, internal_wave_speed(gprime, upper, 100), label=f"density jump {contrast} kg/m^3") ax.axhspan(0.5, 0.8, color="tab:red", alpha=0.15, label="Fram in dead water") ax.set(xlabel="fresh-layer thickness [m]", ylabel="internal wave speed [m/s]", title="Waves on a hidden density jump") ax.legend() plt.show() .. rst-class:: sphx-glr-timing **Total running time of the script:** (0 minutes 0.091 seconds) .. _sphx_glr_download_api_gallery_oceanography_plot_08_ekman_dead_water.py: .. only:: html .. container:: sphx-glr-footer sphx-glr-footer-example .. container:: lite-badge .. image:: images/jupyterlite_badge_logo.svg :target: ../../../lite/lab/index.html?path=api/gallery/oceanography/plot_08_ekman_dead_water.ipynb :alt: Launch JupyterLite :width: 150 px .. container:: sphx-glr-download sphx-glr-download-jupyter :download:`Download Jupyter notebook: plot_08_ekman_dead_water.ipynb ` .. container:: sphx-glr-download sphx-glr-download-python :download:`Download Python source code: plot_08_ekman_dead_water.py ` .. container:: sphx-glr-download sphx-glr-download-zip :download:`Download zipped: plot_08_ekman_dead_water.zip ` .. only:: html .. rst-class:: sphx-glr-signature `Gallery generated by Sphinx-Gallery `_