Eigenfunction Matching for a Finite Change in Depth: Difference between revisions

From WikiWaves
Jump to navigationJump to search
Created page with '{{incomplete pages}} == Introduction == The problem consists of a region to the left with a free water surface with depth <math>d</math> and to the right a region of depth <mat…'
 
No edit summary
 
(25 intermediate revisions by the same user not shown)
Line 1: Line 1:
{{incomplete pages}}
{{complete pages}}


== Introduction ==
== Introduction ==


The problem consists of a region to the left with a free water surface with depth <math>d</math>
The problem consists of a region of free water surface with depth <math>h</math> except between
and to the right a region of depth <math>h</math>. The problem with a semi-infinite change in depth is treated in
<math>-L</math> and <math>L</math> where the depth is <math>d</math>.  
[[Eigenfunction Matching for a Semi-infinite Change in Depth]]
The problem with a semi-infinite change in depth is treated in
[[Eigenfunction Matching for a Semi-Infinite Change in Depth]]
 
== Governing Equations ==
 
We begin with the [[Frequency Domain Problem]] for a  submerged dock which occupies
the region <math>x>0</math> (we assume <math>e^{-\mathrm{i}\omega t}</math> time dependence).
The depth of is constant <math>h</math> for <math>x<0</math> and
constant <math>d</math> for <math>x>0</math>.
The <math>z</math>-direction points vertically
upward with the water surface at <math>z=0</math>.
The boundary value problem can therefore be expressed as
<center><math>
\Delta\phi=0, \,\,  -h<z<0, \,\, x<-L,\,x>L
</math></center>
<center><math>
\Delta\phi=0, \,\,  -d<z<0, \,\, -L<x<L
</math></center>
<center><math>
\partial_z\phi=\alpha\phi, \,\, z=0,
</math></center>
<center><math>
\partial_x\phi=0, \,\, -d<z<-h,\,x=\pm L,
</math></center>
<center><math>
\partial_z\phi=0, \,\, z=-h,\, x<-L,\,x>L
</math></center>
<center><math>
\partial_z\phi=0, \,\, z=-d,\, -L<x<L
</math></center>
 
We must also apply the [[Sommerfeld Radiation Condition]]
as <math>|x|\rightarrow\infty</math>. This essentially implies
that the only wave at infinity is propagating away and at negative infinity there is a unit incident wave
and a wave propagating away.
 
== Solution Method ==
 
We use [http://en.wikipedia.org/wiki/Separation_of_Variables separation of variables] in the two regions, <math>x<0</math>
and <math>x>0</math>.
 
{{separation of variables in two dimensions}}
 
{{separation of variables for a free surface}}
 
=== Inner product between free surface and dock modes ===
 
<center><math>
B_{mn} = \int\nolimits_{-h}^{0}\phi_{m}^{d}(z)\phi_{n}^{h}(z) \mathrm{d} z
</math></center>
where
<center><math>
B_{mn}= \int\nolimits_{-h}^{0} \frac{\cos(k_{m}^{h}(z+h))\cos(k_{n}^{d}(z+d))}{\cos(k_{m}h)\cos(k_{n}d)} \mathrm{d} z
=\frac{k_{m}^{h}\sin(k_{m}^{d} h)\cos(k_{n}^{d}h)-k_{n}^{d}\cos(k_{m}^{h} h)\sin(k_{n}^{d}h)}
{\cos(k_{m}h)\cos(k_{n}d)({k_{m}^{d}}^{2}-{k_{n}^{d}}^{2})}
</math></center>


== Governing Equations ==
== Governing Equations ==
Line 11: Line 66:
We begin with the [[Frequency Domain Problem]] for a  submerged dock which occupies
We begin with the [[Frequency Domain Problem]] for a  submerged dock which occupies
the region <math>x>0</math> (we assume <math>e^{i\omega t}</math> time dependence).
the region <math>x>0</math> (we assume <math>e^{i\omega t}</math> time dependence).
The depth of submergence is <math>d</math>.
The depth of is constant <math>h</math> for <math>x<-L</math> and <math>x>L</math>
The water is assumed to have constant finite depth <math>h</math> and the <math>z</math>-direction points vertically
and constant <math>d</math> for <math>-L<x>L</math>.
upward with the water surface at <math>z=0</math> and the sea floor at <math>z=-h</math>.  
The <math>z</math>-direction points vertically
upward with the water surface at <math>z=0</math>.
The boundary value problem can therefore be expressed as
The boundary value problem can therefore be expressed as
<center><math>
<center><math>
\Delta\phi=0, \,\,  -h<z<0, \,\, x<0
\Delta\phi=0, \,\,  -h<z<0, \,\, x<-L\,\textrm{or}\, x>L,
</math></center>
</math></center>
<center><math>
<center><math>
\Delta\phi=0, \,\,  -d<z<0, \,\, x>0
\Delta\phi=0, \,\,  -d<z<0, \,\, -L<x<L,
</math></center>
</math></center>
<center><math>
<center><math>
Line 25: Line 81:
</math></center>
</math></center>
<center><math>
<center><math>
\partial_x\phi=0, \,\, -d<z<-h,\,x=0,
\partial_x\phi=0, \,\, -d<z<-h,\,x=\pm{L},
</math></center>
</math></center>
<center><math>
<center><math>
\partial_z\phi=0, \,\, z=-h,\, x<0
\partial_z\phi=0, \,\, z=-h,\, x<-L\,\textrm{or}\, x>L,
</math></center>
</math></center>
<center><math>
<center><math>
\partial_z\phi=0, \,\, z=-d,\, x>0
\partial_z\phi=0, \,\, z=-d,\, -L<x<L.
</math></center>
</math></center>


Line 48: Line 104:
{{separation of variables for a free surface}}
{{separation of variables for a free surface}}


=== Expansion of the potential ===  
== Solution using Symmetry ==


We need to apply some boundary conditions at plus and minus infinity,
The finite dock problem is symmetric about the line <math>x=0</math> and this allows us to solve the problem
where are essentially the the solution cannot grow. This means that we
using symmetry. This method is numerically more efficient and requires only slight modification of the  
only have the positive (or negative) roots of the dispersion equation.
code for [[Eigenfunction Matching for a Semi-Infinite Dock]], the developed theory here is very close
However, it does not help us with the purely imaginary root. Here we
to the semi-infinite solution.
must use a different condition, essentially identifying one solution
We decompose the solution into a symmetric and an anti-symmetric part as is described in
as the incoming wave and the other as the outgoing wave.
[[:Category:Symmetry in Two Dimensions|Symmetry in Two Dimensions]]


Therefore the scattered potential (without the incident wave, which will
=== Symmetric solution ===
be added later) can
 
The symmetric potential can
be expanded as
be expanded as
<center>
<center>
<math>
<math>
\phi(x,z)=\sum_{m=0}^{\infty}a_{m}e^{k_{m}^{h} x}\phi_{m}^{h}(z), \;\;x<0
\phi(x,z)=e^{-k_{0}^{h}(x+L)}\phi_{0}\left(
z\right) + \sum_{m=0}^{\infty}a_{m}^{s}e^{k_{m}^{h}(x+L)}\phi_{m}^{h}(z)
, \;\;x<-L
</math>
</center>
and
<center>
<math>
\phi(x,z)=\sum_{m=0}^{\infty}b_{m}^{s}
\frac{\cosh k_{m}^{d} x}{\cosh k_{m}^{d} L}
\phi_{m}^{d}(z), \;\;-L<x<0
</math>
</center>
where <math>a_{m}^{s}</math> and <math>b_{m}^{s}</math>
are the coefficients of the potential in the two regions.
 
For the first equation we multiply both sides by <math>\phi_{n}^{h}(z) \,</math> and
integrate from <math>-h</math>
and for the second equation we multiply both sides by <math>\phi_{n}^{d}(z) \,</math>
and integrate from <math>-d</math>. This gives us
<center>
<math>
A_{0}\delta_{0n}+a_{n}^{s}A_{n}^{h}
=\sum_{m=0}^{\infty}b_{m}^{s}B_{mn}
</math>
</math>
</center>
</center>
Line 68: Line 148:
<center>
<center>
<math>
<math>
\phi(x,z)=\sum_{m=0}^{\infty}b_{m}
-k_{0}^{h}B_{n0} + \sum_{m=0}^{\infty} a_{m}^{s}k_{m}^{h} B_{nm}
e^{-k_{m}^{d}x}\phi_{m}^{d}(z), \;\;x>0
= -b_{n}^{s}k_{n}^{d}\tanh(k_{n}^{d}L) A_{n}^{d}
</math>
</math>
</center>
</center>
where <math>a_{m}</math> and <math>b_{m}</math>
(for full details of this derivation see [[Eigenfunction Matching for a Semi-Infinite Change in Depth]])
are the coefficients of the potential in the left and right respectively
and <math>k_{m}^{h}</math> denotes the solution for depth <math>h</math> etc.


{{incident potential for two dimensions}}
=== Anti-symmetric solution ===


=== An infinite dimensional system of equations ===
The anti-symmetric potential can
be expanded as
<center>
<math>
\phi(x,z)=e^{-k_{m}^{h}(x+L)}\phi_{0}\left(
z\right) + \sum_{m=0}^{\infty}a_{m}^{a}e^{k_{m}^{h}(x+L)}\phi_{m}(z)
, \;\;x<-L
</math>
</center>
and
<center>
<math>
\phi(x,z)=\sum_{m=0}^{\infty}b_{m}^{a}
\frac{\sinh k_{m}^{h} x}{-\sinh k_{m}^{h} L}\phi_{m}(z), \;\;-L<x<0
</math>
</center>
where <math>a_{m}^{a}</math> and <math>b_{m}^{a}</math>
are the coefficients of the potential in the two regions.
Note that the minus sign in the expression for the dock-covered region has been added so that each component is equal to one at <math>x=-L</math>.


For the first equation we multiply both sides by <math>\phi_{n}^{h}(z) \,</math> and
integrate from <math>-h</math>
and for the second equation we multiply both sides by <math>\phi_{n}^{d}(z) \,</math>
and integrate from <math>-d</math>. This gives us
<center>
<math>
A_{0}^{h}\delta_{0n}+a_{n}^{a}A_{n}^{h}
=\sum_{m=0}^{\infty}b_{m}^{a}B_{mn}
</math>
</center>
and
<center>
<math>
-k_{0}^{h}B_{n0} + \sum_{m=0}^{\infty} a_{m}^{a}k_{m}^{h} B_{nm}
= -b_{n}^{a}k_{n}^{d}\coth(k_{n}^{d}L) A_{n}^{d}
</math>
</center>


The potential and its derivative must be continuous across <math>x=0</math>. Therefore, the
(for full details of this derivation see [[Eigenfunction Matching for a Semi-Infinite Change in Depth]])
potentials and their derivatives at <math>x=0</math> have to be equal or equal to zero
as appropriate.
We obtain:
<center><math>
\begin{align}
\phi_{0}^{h}\left( z\right) + \sum_{m=0}^{\infty}a_{m} \phi_{m}^{h}\left(  z\right)
&=\sum_{m=0}^{\infty}b_{m}\phi_{m}^{d}(z), \quad -h<z<0 \\
-\sum_{m=0}^{\infty}b_{m}k_{m}^{d}\phi_{m}^{d}(z)=  &
\begin{cases}
-k_{0}^{h}\phi_{0}^{h}\left(  z\right) +\sum_{m=0}^{\infty} a_{m}k_{m}^{h}\phi_{m}^{h}\left(  z\right),\quad -h<z<0 \\
0,\quad -d<z<-h
\end{cases}
\end{align}
</math></center>


For the first equation we multiply both sides by <math>\phi_{n}^{h}(z) \,</math> and integrating from <math>-h</math> to <math>0</math> to obtain:
=== Solution to the original problem ===
<center><math>
A_{0}^{h}\delta_{0n} + a_{n}A_{n}^{h} = \sum^{\infty}_{m=0}b_{m}B_{mn}, n\in\mathbb{N}\cup\left\{0\right\}
</math></center>
and for the second equation we multiply both sides by <math>\phi_{n}^{d}(z) \,</math> and integrating from <math>-d</math> to <math>0</math> to obtain:
<center><math>
-k_{0}^{h}B_{n0} + \sum^{\infty}_{m=0}a_{m}k_{m}^{h}B_{nm} = -b_{n}^{d}k_{n}^{d}A_{n}^{d}, n\in\mathbb{N}\cup\left\{0\right\}
</math></center>


Solving the equations above will yield the coefficients of the water velocity potential in the dock covered region.
We can now reconstruct the potential for the finite dock from the two previous symmetric and anti-symmetric solution as explained in
[[:Category:Symmetry in Two Dimensions|Symmetry in Two Dimensions]].
The amplitude in the left open-water region is simply obtained by the superposition principle
<center>
<math>
a_{m} = \frac{1}{2}\left(a_{m}^{s}+a_{m}^{a}\right)
</math>
</center>
<center>
<math>
d_{m} = \frac{1}{2}\left(a_{m}^{s}-a_{m}^{a}\right)
</math>
</center>
Note the formulae for <math>b_m</math> and <math>c_m</math>
are more complicated but can be derived with some work.


=== Inner product between free surface and dock modes ===


<center><math>
B_{mn} = \int\nolimits_{-h}^{0}\phi_{m}^{d}(z)\phi_{n}^{h}(z) \mathrm{d} z
</math></center>
where
<center><math>
B_{mn}= \int\nolimits_{-h}^{0} \frac{\cos(k_{m}^{h}(z+h))\cos(k_{n}^{d}(z+d))}{\cos(k_{m}h)\cos(k_{n}d)} \mathrm{d} z
=\frac{k_{m}^{h}\sin(k_{m}^{d} h)\cos(k_{n}^{d}h)-k_{n}^{d}\cos(k_{m}^{h} h)\sin(k_{n}^{d}h)}
{\cos(k_{m}h)\cos(k_{n}d)({k_{m}^{d}}^{2}-{k_{n}^{d}}^{2})}
</math></center>


== Matlab Code ==
== Matlab Code ==


A program to calculate the coefficients for the semi-infinite dock problems can be found here
A program to calculate the coefficients for the semi-infinite dock problems can be found here
{{semiinfinite_change_in_depth code}}
{{finite_change_in_depth code}}


=== Additional code ===
=== Additional code ===

Latest revision as of 08:46, 21 June 2011


Introduction

The problem consists of a region of free water surface with depth [math]\displaystyle{ h }[/math] except between [math]\displaystyle{ -L }[/math] and [math]\displaystyle{ L }[/math] where the depth is [math]\displaystyle{ d }[/math]. The problem with a semi-infinite change in depth is treated in Eigenfunction Matching for a Semi-Infinite Change in Depth

Governing Equations

We begin with the Frequency Domain Problem for a submerged dock which occupies the region [math]\displaystyle{ x\gt 0 }[/math] (we assume [math]\displaystyle{ e^{-\mathrm{i}\omega t} }[/math] time dependence). The depth of is constant [math]\displaystyle{ h }[/math] for [math]\displaystyle{ x\lt 0 }[/math] and constant [math]\displaystyle{ d }[/math] for [math]\displaystyle{ x\gt 0 }[/math]. The [math]\displaystyle{ z }[/math]-direction points vertically upward with the water surface at [math]\displaystyle{ z=0 }[/math]. The boundary value problem can therefore be expressed as

[math]\displaystyle{ \Delta\phi=0, \,\, -h\lt z\lt 0, \,\, x\lt -L,\,x\gt L }[/math]
[math]\displaystyle{ \Delta\phi=0, \,\, -d\lt z\lt 0, \,\, -L\lt x\lt L }[/math]
[math]\displaystyle{ \partial_z\phi=\alpha\phi, \,\, z=0, }[/math]
[math]\displaystyle{ \partial_x\phi=0, \,\, -d\lt z\lt -h,\,x=\pm L, }[/math]
[math]\displaystyle{ \partial_z\phi=0, \,\, z=-h,\, x\lt -L,\,x\gt L }[/math]
[math]\displaystyle{ \partial_z\phi=0, \,\, z=-d,\, -L\lt x\lt L }[/math]

We must also apply the Sommerfeld Radiation Condition as [math]\displaystyle{ |x|\rightarrow\infty }[/math]. This essentially implies that the only wave at infinity is propagating away and at negative infinity there is a unit incident wave and a wave propagating away.

Solution Method

We use separation of variables in the two regions, [math]\displaystyle{ x\lt 0 }[/math] and [math]\displaystyle{ x\gt 0 }[/math].

We express the potential as

[math]\displaystyle{ \phi(x,z) = X(x)Z(z)\, }[/math]

and then Laplace's equation becomes

[math]\displaystyle{ \frac{X^{\prime\prime}}{X} = - \frac{Z^{\prime\prime}}{Z} = k^2 }[/math]

Separation of variables for a free surface

We use separation of variables

We express the potential as

[math]\displaystyle{ \phi(x,z) = X(x)Z(z)\, }[/math]

and then Laplace's equation becomes

[math]\displaystyle{ \frac{X^{\prime\prime}}{X} = - \frac{Z^{\prime\prime}}{Z} = k^2 }[/math]

The separation of variables equation for deriving free surface eigenfunctions is as follows:

[math]\displaystyle{ Z^{\prime\prime} + k^2 Z =0. }[/math]

subject to the boundary conditions

[math]\displaystyle{ Z^{\prime}(-h) = 0 }[/math]

and

[math]\displaystyle{ Z^{\prime}(0) = \alpha Z(0) }[/math]

We can then use the boundary condition at [math]\displaystyle{ z=-h \, }[/math] to write

[math]\displaystyle{ Z = \frac{\cos k(z+h)}{\cos kh} }[/math]

where we have chosen the value of the coefficent so we have unit value at [math]\displaystyle{ z=0 }[/math]. The boundary condition at the free surface ([math]\displaystyle{ z=0 \, }[/math]) gives rise to:

[math]\displaystyle{ k\tan\left( kh\right) =-\alpha \, }[/math]

which is the Dispersion Relation for a Free Surface

The above equation is a transcendental equation. If we solve for all roots in the complex plane we find that the first root is a pair of imaginary roots. We denote the imaginary solutions of this equation by [math]\displaystyle{ k_{0}=\pm ik \, }[/math] and the positive real solutions by [math]\displaystyle{ k_{m} \, }[/math], [math]\displaystyle{ m\geq1 }[/math]. The [math]\displaystyle{ k \, }[/math] of the imaginary solution is the wavenumber. We put the imaginary roots back into the equation above and use the hyperbolic relations

[math]\displaystyle{ \cos ix = \cosh x, \quad \sin ix = i\sinh x, }[/math]

to arrive at the dispersion relation

[math]\displaystyle{ \alpha = k\tanh kh. }[/math]

We note that for a specified frequency [math]\displaystyle{ \omega \, }[/math] the equation determines the wavenumber [math]\displaystyle{ k \, }[/math].

Finally we define the function [math]\displaystyle{ Z(z) \, }[/math] as

[math]\displaystyle{ \chi_{m}\left( z\right) =\frac{\cos k_{m}(z+h)}{\cos k_{m}h},\quad m\geq0 }[/math]

as the vertical eigenfunction of the potential in the open water region. From Sturm-Liouville theory the vertical eigenfunctions are orthogonal. They can be normalised to be orthonormal, but this has no advantages for a numerical implementation. It can be shown that

[math]\displaystyle{ \int\nolimits_{-h}^{0}\chi_{m}(z)\chi_{n}(z) \mathrm{d} z=A_{n}\delta_{mn} }[/math]

where

[math]\displaystyle{ A_{n}=\frac{1}{2}\left( \frac{\cos k_{n}h\sin k_{n}h+k_{n}h}{k_{n}\cos ^{2}k_{n}h}\right). }[/math]

Inner product between free surface and dock modes

[math]\displaystyle{ B_{mn} = \int\nolimits_{-h}^{0}\phi_{m}^{d}(z)\phi_{n}^{h}(z) \mathrm{d} z }[/math]

where

[math]\displaystyle{ B_{mn}= \int\nolimits_{-h}^{0} \frac{\cos(k_{m}^{h}(z+h))\cos(k_{n}^{d}(z+d))}{\cos(k_{m}h)\cos(k_{n}d)} \mathrm{d} z =\frac{k_{m}^{h}\sin(k_{m}^{d} h)\cos(k_{n}^{d}h)-k_{n}^{d}\cos(k_{m}^{h} h)\sin(k_{n}^{d}h)} {\cos(k_{m}h)\cos(k_{n}d)({k_{m}^{d}}^{2}-{k_{n}^{d}}^{2})} }[/math]

Governing Equations

We begin with the Frequency Domain Problem for a submerged dock which occupies the region [math]\displaystyle{ x\gt 0 }[/math] (we assume [math]\displaystyle{ e^{i\omega t} }[/math] time dependence). The depth of is constant [math]\displaystyle{ h }[/math] for [math]\displaystyle{ x\lt -L }[/math] and [math]\displaystyle{ x\gt L }[/math] and constant [math]\displaystyle{ d }[/math] for [math]\displaystyle{ -L\lt x\gt L }[/math]. The [math]\displaystyle{ z }[/math]-direction points vertically upward with the water surface at [math]\displaystyle{ z=0 }[/math]. The boundary value problem can therefore be expressed as

[math]\displaystyle{ \Delta\phi=0, \,\, -h\lt z\lt 0, \,\, x\lt -L\,\textrm{or}\, x\gt L, }[/math]
[math]\displaystyle{ \Delta\phi=0, \,\, -d\lt z\lt 0, \,\, -L\lt x\lt L, }[/math]
[math]\displaystyle{ \partial_z\phi=\alpha\phi, \,\, z=0, }[/math]
[math]\displaystyle{ \partial_x\phi=0, \,\, -d\lt z\lt -h,\,x=\pm{L}, }[/math]
[math]\displaystyle{ \partial_z\phi=0, \,\, z=-h,\, x\lt -L\,\textrm{or}\, x\gt L, }[/math]
[math]\displaystyle{ \partial_z\phi=0, \,\, z=-d,\, -L\lt x\lt L. }[/math]

We must also apply the Sommerfeld Radiation Condition as [math]\displaystyle{ |x|\rightarrow\infty }[/math]. This essentially implies that the only wave at infinity is propagating away and at negative infinity there is a unit incident wave and a wave propagating away.

Solution Method

We use separation of variables in the two regions, [math]\displaystyle{ x\lt 0 }[/math] and [math]\displaystyle{ x\gt 0 }[/math].

We express the potential as

[math]\displaystyle{ \phi(x,z) = X(x)Z(z)\, }[/math]

and then Laplace's equation becomes

[math]\displaystyle{ \frac{X^{\prime\prime}}{X} = - \frac{Z^{\prime\prime}}{Z} = k^2 }[/math]

Separation of variables for a free surface

We use separation of variables

We express the potential as

[math]\displaystyle{ \phi(x,z) = X(x)Z(z)\, }[/math]

and then Laplace's equation becomes

[math]\displaystyle{ \frac{X^{\prime\prime}}{X} = - \frac{Z^{\prime\prime}}{Z} = k^2 }[/math]

The separation of variables equation for deriving free surface eigenfunctions is as follows:

[math]\displaystyle{ Z^{\prime\prime} + k^2 Z =0. }[/math]

subject to the boundary conditions

[math]\displaystyle{ Z^{\prime}(-h) = 0 }[/math]

and

[math]\displaystyle{ Z^{\prime}(0) = \alpha Z(0) }[/math]

We can then use the boundary condition at [math]\displaystyle{ z=-h \, }[/math] to write

[math]\displaystyle{ Z = \frac{\cos k(z+h)}{\cos kh} }[/math]

where we have chosen the value of the coefficent so we have unit value at [math]\displaystyle{ z=0 }[/math]. The boundary condition at the free surface ([math]\displaystyle{ z=0 \, }[/math]) gives rise to:

[math]\displaystyle{ k\tan\left( kh\right) =-\alpha \, }[/math]

which is the Dispersion Relation for a Free Surface

The above equation is a transcendental equation. If we solve for all roots in the complex plane we find that the first root is a pair of imaginary roots. We denote the imaginary solutions of this equation by [math]\displaystyle{ k_{0}=\pm ik \, }[/math] and the positive real solutions by [math]\displaystyle{ k_{m} \, }[/math], [math]\displaystyle{ m\geq1 }[/math]. The [math]\displaystyle{ k \, }[/math] of the imaginary solution is the wavenumber. We put the imaginary roots back into the equation above and use the hyperbolic relations

[math]\displaystyle{ \cos ix = \cosh x, \quad \sin ix = i\sinh x, }[/math]

to arrive at the dispersion relation

[math]\displaystyle{ \alpha = k\tanh kh. }[/math]

We note that for a specified frequency [math]\displaystyle{ \omega \, }[/math] the equation determines the wavenumber [math]\displaystyle{ k \, }[/math].

Finally we define the function [math]\displaystyle{ Z(z) \, }[/math] as

[math]\displaystyle{ \chi_{m}\left( z\right) =\frac{\cos k_{m}(z+h)}{\cos k_{m}h},\quad m\geq0 }[/math]

as the vertical eigenfunction of the potential in the open water region. From Sturm-Liouville theory the vertical eigenfunctions are orthogonal. They can be normalised to be orthonormal, but this has no advantages for a numerical implementation. It can be shown that

[math]\displaystyle{ \int\nolimits_{-h}^{0}\chi_{m}(z)\chi_{n}(z) \mathrm{d} z=A_{n}\delta_{mn} }[/math]

where

[math]\displaystyle{ A_{n}=\frac{1}{2}\left( \frac{\cos k_{n}h\sin k_{n}h+k_{n}h}{k_{n}\cos ^{2}k_{n}h}\right). }[/math]

Solution using Symmetry

The finite dock problem is symmetric about the line [math]\displaystyle{ x=0 }[/math] and this allows us to solve the problem using symmetry. This method is numerically more efficient and requires only slight modification of the code for Eigenfunction Matching for a Semi-Infinite Dock, the developed theory here is very close to the semi-infinite solution. We decompose the solution into a symmetric and an anti-symmetric part as is described in Symmetry in Two Dimensions

Symmetric solution

The symmetric potential can be expanded as

[math]\displaystyle{ \phi(x,z)=e^{-k_{0}^{h}(x+L)}\phi_{0}\left( z\right) + \sum_{m=0}^{\infty}a_{m}^{s}e^{k_{m}^{h}(x+L)}\phi_{m}^{h}(z) , \;\;x\lt -L }[/math]

and

[math]\displaystyle{ \phi(x,z)=\sum_{m=0}^{\infty}b_{m}^{s} \frac{\cosh k_{m}^{d} x}{\cosh k_{m}^{d} L} \phi_{m}^{d}(z), \;\;-L\lt x\lt 0 }[/math]

where [math]\displaystyle{ a_{m}^{s} }[/math] and [math]\displaystyle{ b_{m}^{s} }[/math] are the coefficients of the potential in the two regions.

For the first equation we multiply both sides by [math]\displaystyle{ \phi_{n}^{h}(z) \, }[/math] and integrate from [math]\displaystyle{ -h }[/math] and for the second equation we multiply both sides by [math]\displaystyle{ \phi_{n}^{d}(z) \, }[/math] and integrate from [math]\displaystyle{ -d }[/math]. This gives us

[math]\displaystyle{ A_{0}\delta_{0n}+a_{n}^{s}A_{n}^{h} =\sum_{m=0}^{\infty}b_{m}^{s}B_{mn} }[/math]

and

[math]\displaystyle{ -k_{0}^{h}B_{n0} + \sum_{m=0}^{\infty} a_{m}^{s}k_{m}^{h} B_{nm} = -b_{n}^{s}k_{n}^{d}\tanh(k_{n}^{d}L) A_{n}^{d} }[/math]

(for full details of this derivation see Eigenfunction Matching for a Semi-Infinite Change in Depth)

Anti-symmetric solution

The anti-symmetric potential can be expanded as

[math]\displaystyle{ \phi(x,z)=e^{-k_{m}^{h}(x+L)}\phi_{0}\left( z\right) + \sum_{m=0}^{\infty}a_{m}^{a}e^{k_{m}^{h}(x+L)}\phi_{m}(z) , \;\;x\lt -L }[/math]

and

[math]\displaystyle{ \phi(x,z)=\sum_{m=0}^{\infty}b_{m}^{a} \frac{\sinh k_{m}^{h} x}{-\sinh k_{m}^{h} L}\phi_{m}(z), \;\;-L\lt x\lt 0 }[/math]

where [math]\displaystyle{ a_{m}^{a} }[/math] and [math]\displaystyle{ b_{m}^{a} }[/math] are the coefficients of the potential in the two regions. Note that the minus sign in the expression for the dock-covered region has been added so that each component is equal to one at [math]\displaystyle{ x=-L }[/math].

For the first equation we multiply both sides by [math]\displaystyle{ \phi_{n}^{h}(z) \, }[/math] and integrate from [math]\displaystyle{ -h }[/math] and for the second equation we multiply both sides by [math]\displaystyle{ \phi_{n}^{d}(z) \, }[/math] and integrate from [math]\displaystyle{ -d }[/math]. This gives us

[math]\displaystyle{ A_{0}^{h}\delta_{0n}+a_{n}^{a}A_{n}^{h} =\sum_{m=0}^{\infty}b_{m}^{a}B_{mn} }[/math]

and

[math]\displaystyle{ -k_{0}^{h}B_{n0} + \sum_{m=0}^{\infty} a_{m}^{a}k_{m}^{h} B_{nm} = -b_{n}^{a}k_{n}^{d}\coth(k_{n}^{d}L) A_{n}^{d} }[/math]

(for full details of this derivation see Eigenfunction Matching for a Semi-Infinite Change in Depth)

Solution to the original problem

We can now reconstruct the potential for the finite dock from the two previous symmetric and anti-symmetric solution as explained in Symmetry in Two Dimensions. The amplitude in the left open-water region is simply obtained by the superposition principle

[math]\displaystyle{ a_{m} = \frac{1}{2}\left(a_{m}^{s}+a_{m}^{a}\right) }[/math]

[math]\displaystyle{ d_{m} = \frac{1}{2}\left(a_{m}^{s}-a_{m}^{a}\right) }[/math]

Note the formulae for [math]\displaystyle{ b_m }[/math] and [math]\displaystyle{ c_m }[/math] are more complicated but can be derived with some work.


Matlab Code

A program to calculate the coefficients for the semi-infinite dock problems can be found here finite_change_in_depth.m

Additional code

This program requires