6 wave dispersion relations with derivatives

21 Sep 2025

Tessendorf’s 2005 paper “Simulating Ocean Water” describes three basic dispersion relations:

  1. The deep water dispersion relation:

    ω2=gk \omega^2 = gk

    where ω\omega is the wave’s temporal frequency in rad/s\text{rad}/s, gg is gravity in m/s2m/s^2, and kk is the spatial frequency in m/sm/s.

  2. The shallow water dispersion relation:

    ω2=gktanhkh \omega^2 = gk \tanh kh

    where hh is the water mean depth in mm.

  3. The deep water relation with viscosity correction:

    ω2=gk(1+k2L2) \omega^2 = gk (1 + k^2 L^2)

    where LL is the scale in mm at which the viscosity term operates. At 0, it has no effect.

Horvath’s 2015 paper “Empirical directional wave spectra for computer graphics” formulates the viscosity term in terms of different physical units, and applies it to the shallow water dispersion relation:

ω2=(gk+σρk3)tanhkh \omega^2 = (gk + \frac{\sigma}{\rho} k^3) \tanh kh

where σ\sigma is the surface tension in N/mN/m, and ρ\rho is the water density in kg/m3kg/m^3.

It is useful to have derivatives of the dispersion relation. Horvath’s paper describes how we can calculate the spectrum term S(kx,ky)S(k_x, k_y) from S(ω,θ)S(\omega, \theta) and the derivative of the dispersion relation ωk\frac{\partial \omega}{\partial k}:

S(kx,ky)=S(ω,θ)ωk/k S(k_x, k_y) = S(\omega, \theta) \frac{\partial \omega}{\partial k} / k

So, with that motivation, we would like the derivatives of our dispersion relations. You should autodifferentiate if that’s an option. If not, here are derivations of each derivative:

  1. Deep water:

    ω2=gkω=(gk)12ωk=12(gk)12g=g2gk=12gk \begin{align*} \omega^2 &= gk \\ \omega &= (gk)^\frac{1}{2} \\ \frac{\partial \omega}{\partial k} &= \frac{1}{2} (gk)^{-\frac{1}{2}} g \\ &= \frac{g}{2\sqrt{gk}} \\ &= \frac{1}{2} \sqrt{\frac{g}{k}} \end{align*}

    Wolfram here.

  2. Shallow water:

    First we will need ktanhkh\frac{\partial}{\partial k} \tanh kh:

    ktanhkh=k[ekhekhekh+ekh]=k[(ekhekh)(ekh+ekh)1]=(hekhhekh)(ekh+ekh)1+(ekhekh)[(ekh+ekh)2(hekhhekh)]=h(1[ekhekhekh+ekh]2=h(1tanh2kh) \begin{align*} \frac{\partial}{\partial k} \tanh kh &= \frac{\partial}{\partial k} [\frac{e^{kh} - e^{-kh}}{e^{kh}+e^{-kh}}] \\ &= \frac{\partial}{\partial k} [(e^{kh} - e^{-kh})(e^{kh}+e^{-kh})^{-1}] \\ &= (he^{kh}-he^{-kh})(e^{kh}+e^{-kh})^{-1} + (e^{kh}-e^{-kh})[-(e^{kh}+e^{-kh})^{-2}(he^{kh}-he^{-kh})] \\ &= h(1-[\frac{e^{kh}-e^{-kh}}{e^{kh}+e^{-kh}}]^2 \\ &= h(1-\tanh^2 kh) \end{align*}

    With that identity, let’s proceed:

    ω2=gktanhkhω=(gktanhkh)12ωk=12[gktanhkh]12[gtanh(kh)+gkh(1tanh2kh]=g(tanhkh+kh(1tanh2kh))2gktanhkh=gtanhkh+gkh(1tanh2kh)2gktanhkh=12[gtanhkh+gkh(1tanh2kh)gktanhkh]=gtanhkh+gkh(1tanh2kh)2gktanhkh=g(tanhkh+khsech2kh)2gktanhkh \begin{align*} \omega^2 &= gk \tanh kh \\ \omega &= (gk \tanh kh)^{\frac{1}{2}} \\ \frac{\partial \omega}{\partial k} &= \frac{1}{2} [gk \tanh kh]^{-\frac{1}{2}} [g \tanh (kh) + gkh(1 - \tanh ^2 kh] \\ &= \frac{g(\tanh kh + kh(1 - \tanh ^2 kh))}{2 \sqrt{gk \tanh kh}} \\ &= \frac{g \tanh kh + gkh (1 - \tanh^2 kh)}{2 \sqrt{gk \tanh kh}} \\ &= \frac{1}{2} [\sqrt{g \tanh kh} + \frac {gkh(1 - \tanh^2 kh)}{\sqrt{gk \tanh kh}}] \\ &= \frac {g \tanh kh + gkh(1 - \tanh^2 kh)}{2\sqrt{gk \tanh kh}} \\ &= \frac {g (\tanh kh + kh \operatorname{sech}^2 kh)}{2\sqrt{gk \tanh kh}} \end{align*}

    Wolfram here. (Recall that sech2x=1tanh2x\operatorname{sech}^2 x = 1 - \tanh^2 x.)

  3. Viscous deep water (Tessendorf version):

    ω2=gk[1+k2L2]ω=(gk[1+k2L2])12ωk=12(gk[1+k2L2])12[g+3gk2L2]=g+3gk2L22gk[1+k2L2] \begin{align*} \omega^2 &= gk [1 + k^2 L^2] \\ \omega &= (gk [1 + k^2 L^2])^{\frac{1}{2}} \\ \frac{\partial \omega}{\partial k} &= \frac{1}{2}(gk [1 + k^2 L^2])^{-\frac{1}{2}} [g+3gk^2 L^2] \\ &= \frac{g+3gk^2L^2}{2\sqrt{gk[1+k^2L^2]}} \end{align*}

    Wolfram here.

  4. Viscous deep water (Horvath version):

    ω2=gk+σρk3ω=(gk+σρk3)12ωk=12(gk+σρk3)12[g+3σρk2]=g+3σρk22gk+σρk3 \begin{align*} \omega^2 &= gk + \frac{\sigma}{\rho}k^3 \\ \omega &= (gk + \frac{\sigma}{\rho}k^3)^{\frac{1}{2}} \\ \frac{\partial \omega}{\partial k} &= \frac{1}{2}(gk + \frac{\sigma}{\rho}k^3)^{-\frac{1}{2}} [g+3\frac{\sigma}{\rho}k^2] \\ &= \frac{g + 3 \frac{\sigma}{\rho}k^2}{2 \sqrt{gk+\frac{\sigma}{\rho}k^3}} \end{align*}

    Wolfram here.

  5. Viscous shallow water (Tessendorf version):

    FYI - use the Horvath version instead. This relation sucks.

    We’ll want ktanhkh\frac{\partial}{\partial k} \sqrt{\tanh kh}:

    ktanhkh=k(tanhkh)12=12(tanhkh)12ktanhkh=12(tanhkh)12h(1tanh2kh)=h1tanh2kh2tanhkh=hsech2kh2tanhkh \begin{align*} \frac{\partial}{\partial k} \sqrt{\tanh kh} &= \frac{\partial}{\partial k} (\tanh kh)^{\frac{1}{2}} \\ &= \frac{1}{2} (\tanh kh)^{-\frac{1}{2}} \frac{\partial}{\partial k} \tanh kh \\ &= \frac{1}{2} (\tanh kh)^{-\frac{1}{2}} h(1 - \tanh^2 kh) \\ &= h \frac{1 - \tanh^2 kh}{2 \sqrt{\tanh kh}} \\ &= h \frac{\operatorname{sech}^2 kh}{2 \sqrt{\tanh kh}} \end{align*}

    Now we can proceed:

    ω2=gk(1+k2L2)tanhkhω=(gk(1+k2L2)tanhkh)12ωk=(k[gk(1+k2L2)])tanhkh+[gk(1+k2L2)]ktanhkh=g(3+k2L2)2kg(1+k2L2)=12g(3+k2L2)ktanhkh+gk(1+k2L2)[h(1tanh2kh)2tanhkh] \begin{align*} \omega^2 &= gk (1 + k^2 L^2) \tanh kh \\ \omega &= (gk (1 + k^2 L^2) \tanh kh)^{\frac{1}{2}} \\ \frac{\partial \omega}{\partial k} &= (\frac{\partial}{\partial k} [gk (1 + k^2 L^2)]) \tanh kh + [gk (1 + k^2 L^2)] \frac{\partial}{\partial k} \tanh kh \\ &= \frac{g (3 + k^2 L^2)}{2 \sqrt{k} \sqrt{g (1 + k^2 L^2)}} \dots \\ &= \frac{1}{2} \sqrt{\frac{g(3+k^2 L^2)}{k}} \sqrt{\tanh kh} + \sqrt{gk (1+k^2 L^2)} [\frac{h (1 - \tanh^2 kh)}{2 \sqrt{\tanh kh}}] \end{align*}

    We can apply some transformations to get a common denominator and agree with Wolfram:

    ωk=g(3+k2L2)2gk(1+k2L2)tanhkh+=g(3+k2L2)tanhkh2gk(1+k2L2)tanhkh+=+gk(1+k2L2)[h(1tanh2kh)2tanhkh]=+gk(1+k2L2)gk(1+k2L2)[h(1tanh2kh)2tanhkh]=+gk(1+k2L2)h(1tanh2kh)2gk(1+k2L2)tanhkh=+ghk(1+k2L2)(1tanh2kh)2gk(1+k2L2)tanhkh=g(3+k2L2)tanhkh+ghk(1+k2L2)(1tanh2kh)2gk(1+k2L2)tanhkh=g(3+k2L2)tanhkh+ghk(1+k2L2)(sech2kh)2gk(1+k2L2)tanhkh \begin{align*} \frac{\partial \omega}{\partial k} &= \frac{g (3 + k^2 L^2)}{2 \sqrt{gk(1+k^2 L^2)}} \sqrt{\tanh kh} + \dots \\ &= \frac{g (3 + k^2 L^2) \tanh kh}{2 \sqrt{gk(1+k^2 L^2) \tanh kh}} + \dots \\ &= \dots + \sqrt{gk (1+k^2 L^2)} [\frac{h (1 - \tanh^2 kh)}{2 \sqrt{\tanh kh}}] \\ &= \dots + \frac{gk(1+k^2 L^2)}{\sqrt{gk(1+k^2 L^2)}} [\frac{h (1 - \tanh^2 kh)}{2 \sqrt{\tanh kh}}] \\ &= \dots + \frac{gk(1+k^2 L^2) h (1 - \tanh^2 kh)}{2 \sqrt{gk(1+k^2 L^2) \tanh kh}} \\ &= \dots + \frac{ghk(1+k^2 L^2)(1-\tanh^2 kh)}{2 \sqrt{gk(1+k^2 L^2) \tanh kh}} \\ &= \frac{g(3+k^2L^2) \tanh kh + ghk(1+k^2 L^2)(1-\tanh^2 kh)}{2 \sqrt{gk(1+k^2 L^2) \tanh kh}} \\ &= \frac{g(3+k^2L^2) \tanh kh + ghk(1+k^2 L^2)(\operatorname{sech}^2 kh)}{2 \sqrt{gk(1+k^2 L^2) \tanh kh}} \end{align*}

    Wolfram here.

  6. Viscous shallow water (Horvath version):

    ω2=(gk+σρk3)tanhkhω=((gk+σρk3)tanhkh)12ωk=[k(gk+σρk3)]tanh12kh+(gk+σρk3)12ktanh12kh=[12(gk+σρk3)12(g+3σρk2)]tanh12kh+(gk+σρk3)12h1tanh2kh2tanhkh \begin{align*} \omega^2 &= (gk + \frac{\sigma}{\rho}k^3) \tanh kh \\ \omega &= ((gk + \frac{\sigma}{\rho}k^3) \tanh kh)^{\frac{1}{2}} \\ \frac{\partial \omega}{\partial k} &= [\frac{\partial}{\partial k}(gk + \frac{\sigma}{\rho}k^3)] \tanh^{\frac{1}{2}} kh + (gk + \frac{\sigma}{\rho}k^3)^{\frac{1}{2}} \frac{\partial}{\partial k} \tanh^{\frac{1}{2}} kh \\ &= [\frac{1}{2}(gk+\frac{\sigma}{\rho}k^3)^{-\frac{1}{2}}(g+3\frac{\sigma}{\rho}k^2)] \tanh^{\frac{1}{2}} kh + (gk + \frac{\sigma}{\rho}k^3)^{\frac{1}{2}}h\frac{1-\tanh^2 kh}{2 \sqrt{\tanh kh}} \end{align*}

    Let’s try to corral this into a form closer to what Wolfram gives us:

    ωk=[12(gk+σρk3)12(g+3σρk2)]tanhkh+(gk+σρk3)12h1tanh2kh2tanhkh=g+3σρk22gk+σρk3tanhkh+=(g+3σρk2)tanhkh2(gk+σρk3)tanhkh+=+(gk+σρk3)12h1tanh2kh2tanhkh=+(gk+σρk3)h1tanh2kh2(gk+σρk3)tanhkh=+h(gk+σρk3)(1tanh2kh)2(gk+σρk3)tanhkh=(g+3σρk2)tanhkh+h(gk+σρk3)(1tanh2kh)2(gk+σρk3)tanhkh=(g+3σρk2)tanhkh+h(gk+σρk3)sech2kh2(gk+σρk3)tanhkh \begin{align*} \frac{\partial \omega}{\partial k} &= [\frac{1}{2}(gk+\frac{\sigma}{\rho}k^3)^{-\frac{1}{2}}(g+3\frac{\sigma}{\rho}k^2)] \sqrt{\tanh{kh}} + (gk + \frac{\sigma}{\rho}k^3)^{\frac{1}{2}}h\frac{1-\tanh^2 kh}{2 \sqrt{\tanh kh}} \\ &= \frac{g+3\frac{\sigma}{\rho}k^2}{2\sqrt{gk+\frac{\sigma}{\rho}k^3}} \sqrt{\tanh{kh}} + \dots \\ &= \frac{(g+3\frac{\sigma}{\rho}k^2) \tanh{kh}}{2\sqrt{(gk+\frac{\sigma}{\rho}k^3)\tanh{kh}}} + \dots \\ &= \dots + (gk + \frac{\sigma}{\rho}k^3)^{\frac{1}{2}}h\frac{1-\tanh^2 kh}{2 \sqrt{\tanh kh}} \\ &= \dots + (gk + \frac{\sigma}{\rho}k^3)h\frac{1-\tanh^2 kh}{2 \sqrt{(gk + \frac{\sigma}{\rho}k^3) \tanh kh}} \\ &= \dots + \frac{h (gk+\frac{\sigma}{\rho}k^3) (1 - \tanh^2 kh)}{2 \sqrt{(gk+\frac{\sigma}{\rho}k^3)\tanh kh}} \\ &= \frac{(g+3\frac{\sigma}{\rho}k^2) \tanh{kh} + h (gk+\frac{\sigma}{\rho}k^3) (1 - \tanh^2 kh)}{2 \sqrt{(gk+\frac{\sigma}{\rho}k^3)\tanh kh}} \\ &= \frac{(g+3\frac{\sigma}{\rho}k^2) \tanh{kh} + h (gk+\frac{\sigma}{\rho}k^3) \operatorname{sech}^2{kh}}{2 \sqrt{(gk+\frac{\sigma}{\rho}k^3)\tanh kh}} \end{align*}

    Wolfram here. Divide numerator and denominator by ρ\rho (or p in wolfram) to make them match.

back to main page