next up previous
Next: The Robbins boundary problem Up: A fast method for Previous: Introduction

The Neumann boundary problem

In this section we will briefly review a fast method to solve the Helmholtz equation on a rectangle with Neumann boundary conditions. This problem can easily be solved using a fast transformation. And as it will be shown in the next section, this is an important property in solving the Robbins boundary problem, in which we can twice use the techniques we are about to describe. In this point of view as mentioned in the abstract, the Robbins boundary problem can be split into two cheaper problems of which one can be solved using the Neumann boundary problem. First we will describe the solution to this problem, which is very similar to a method in the book of Pickering [24].

We take the Helmholtz equation,

$\displaystyle \frac{\partial^2 \phi}{\partial x^2} + \frac{\partial^2 \phi}{\partial y^2} + \lambda \phi = f(x,y),$ (1)

on a rectangle $ [0,a_1] \times [0,a_2]$ with Neumann boundary conditions on two parallel sides, e.g. on the sides $ y=0$ and $ y=a_2$.

$\displaystyle \frac{\partial \phi}{\partial y}(x,0) = \beta_0(x), \hspace{0.3 c...
...artial \phi}{\partial y}(x,a_2) = \beta_1(x), \hspace{0.3cm} 0 \leq x \leq a_1.$ (2)

The boundary conditions on the two other sides $ x=0$ and $ x=a_1$ are arbitrary, e.g. of Robbins type (with $ 0\leq y \leq a_2$),

$\displaystyle \Big( \frac{\partial \phi}{\partial x}-p_0 \phi \Big)(0,y) = \alp...
...,\; \Big( \frac{\partial \phi}{\partial x}-p_1 \phi \Big)(a_1,y) = \alpha_1(y).$ (3)

We divide $ [0,a_1]$ (resp. $ [0,a_2]$) into $ n_1$ (resp. $ n_2$) equal parts and when using the classical five points difference scheme for $ i=0,1,\dots ,n_1$ and $ j=0,1,\dots, n_2$, we get

$\displaystyle u_{i,j} - \theta_1 (u_{i+1,j} + u_{i-1,j}) - \theta_2 (u_{i,j+1} + u_{i,j-1}) = -\delta f_{i,j}$ (4)

with

$\displaystyle h_1=\frac{a_1}{n_1}, \,\,\,\,h_2=\frac{a_2}{n_2},\,\,\,\, \delta ...
... \,\, \theta_1 = \frac{\delta}{h_1^2}, \,\,\,\, \theta_2 = \frac{\delta}{h_2^2}$ (5)

and where $ u_{i,j}$ is the approximated value of $ \phi(x,y)$ in the grid point $ (x_i,y_j)$ and in the same way we define $ f_{i,j}$ as the value of $ f(x,y)$ in the grid point $ (x_i,y_j)$. Approximating the boundary conditions with central differences we can substitute $ u_{i,-1}$ and $ u_{i,n_{2}+1}$ by

$\displaystyle u_{i,-1} = u_{i,1} - 2 h_2 \beta_{0,i}, \hspace{0.3cm} u_{i,n_2+1} = u_{i,n_2-1} + 2 h_2 \beta_{1,i},$ (6)

with $ \beta_{k,i} = \beta_k(x_i)$. This gives us a system of equations $ M_{NN}\, \mathbf{u} = \mathbf{b}$ with unknowns $ u_{i,j}$ for $ i=0,1,\ldots,n_1$ and $ j=0,1,\ldots,n_2$ where

$\displaystyle \mathbf{u}=\left[ \begin{array}{c} \mathbf{u}_0\\  \mathbf{u}_1\\...
...begin{array}{c} u_{0,j}\\  u_{1,j}\\  \vdots \\  u_{n_1,j} \end{array} \right].$ (7)

and $ M_{NN}$ is the following block matrix

$\displaystyle M_{NN}= \left[ \begin{array}{ccccc} A & 2 T & & &\\  T & A & T & ...
...ots & \ddots & \ddots &\\  & & T & A & T \\  & & & 2 T & A \end{array} \right],$ (8)

where $ A$ and $ T$ are of the form: $ T=-\theta_2 I$ and

$\displaystyle A=\left[ \begin{array}{cccc} 1 + 2 h_1 p_0 \theta_1 & - 2 \theta_...
...& - \theta_1 \\  & & - 2 \theta_1 & 1 - 2 h_1 p_1 \theta_1 \end{array} \right],$ (9)

with $ \theta_1$ and $ \theta_2$ as in (5).

It is a well-known fact that a matrix like

$\displaystyle B = \left[ \begin{array}{ccccc}
a & 2 \, t & & &\\
t & a & t & ...
... \ddots & \ddots &\\
& & t & a & t \\
& & & 2 \, t & a
\end{array} \right]
$

of size $ n+1$ with $ a$ and $ t$ scalars, can be diagonalized in the following sense

$\displaystyle B = C\Lambda C$

with $ C=\left(c_{i,j}\right)$ and $ \Lambda = \mathrm{diag}
\{\lambda_0,\ldots,\lambda_{n}\}$, where

$\displaystyle c_{i,j}=\left\{ \begin{array}{lll}
\sqrt{2/n} \,1/2, & \mbox{ for...
.../n} \, (-1)^i \, 1/2, & \mbox{ voor } j=n, & i=0,\ldots,n,
\end{array} \right.
$

and

$\displaystyle \lambda_i = a + 2 \, t \cos\frac{i \pi}{n}, \hspace{0.3cm}
i=0,\ldots,n.
$

To prove this, write the matrix $ B$ as $ a I + t X_{00}$ with $ X_{00}$ as in (18), and then use the formula (27). A more compact form for the matrix $ C$ is

$\displaystyle C = \sqrt{\frac{2}{n}} \left[\epsilon_j \cos \frac{i j
\pi}{n}\right]_{i,j=0}^{n},$

with

$\displaystyle \epsilon_k = \left\{ \begin{array}{ll} 1/2 & \mbox{ voor } k = 0,n\\  1 & \mbox{ voor } k = 1,2,\ldots,n-1 \end{array} \right. .$ (10)

(When we explicitely want to denote the size of the matrix $ C$ we denote it as $ C_{n+1}$.) The matrix $ C$ is the matrix of one of the versions of the discrete cosine transform ($ DCT$), [13,1,6,28,36]. This matrix is nor symmetric, nor persymmetric but satisfies $ \left(C\right)^{-1} = C$.

Before we can continu we need some new notations. The symbol $ \otimes$ denotes the Kronecker product of matrices [10]. For a $ (p \times
q)$-matrix $ A= [a_{i,j}]$ and a $ (r \times s)$-matrix $ B= [b_{i,j}]$ the Kroneckerproduct $ C = B\otimes A$ is a $ (p r \times q s)$-matrix defined as

$\displaystyle C = \left[ \begin{array}{ccc} b_{1,1} \, A & \cdots & b_{1,s} \, ...
...ts& &\vdots \\  b_{r,1} \, A & \cdots & b_{r,s} \, A \\
\end{array} \right]. $

It is obvious that the matrix $ C$ has a block structure with $ r$ block rows and $ s$ block columns. We denote the $ (i_2,j_2)$th block submatrix of $ C$ with $ C_{i_2,j_2}$. The $ (i_1,j_1)$th element of $ C_{i_2,j_2}$ is denoted as $ C_{i_1,j_1;i_2,j_2}$ and equals $ a_{i_1,j_1} \,
b_{i_2,j_2}$.

In a similar way as in the scalar case it can be shown that the matrix $ M_{NN}$ can be factorised in the following way,

$\displaystyle M_{NN} = \left( C \otimes I \right) \Lambda \left( C \otimes I \right),$ (11)

with $ \Lambda$ a block diagonal matrix with blocks

$\displaystyle \Lambda_j = A + 2 \, T \cos \frac{j \pi}{n_2}, \hspace{0.3cm} j=0,\ldots,n_2.$ (12)

We now present the algorithm for solving the Helmholtz equation with the Neumann boundary conditions. We use an operator called $ \mathrm{Vec}$ which means that we make a long vector from a matrix by placing all the columns of the matrix one below the other.

algorithm 1   Solving $ M_{NN} \mathbf{u} = \mathbf{b}$ where $ M_{NN}$ is the block tridiagonal matrix of size $ (n_1+1)\times (n_2+1)$, given by (8), with $ A$ and $ T$ of size $ n_1+1$ as in (9). Let $ \mathbf{b} =
\mathrm{vec}\, V$ with $ V \in {\mathbb{R}}^{(n_1+1) \times (n_2+1)}$ (and the same for $ \mathbf{z} = \mathrm{vec}\, Z$, $ \mathbf{y} = \mathrm{vec}\, Y$, $ \mathbf{u} = \mathrm{vec}\, U$).
  1. $ Z = V C_{n_2+1}$
  2. for $ j=0,\ldots,n_2$:
    solve the systems of equations $ \left( A + 2 T \cos
\frac{j \pi}{n_2} \right) \mathbf{y}_j = \mathbf{z}_j$ for $ \mathbf{y}_j$
  3. $ U = Y C_{n_2+1}$

The transformations in the first and the final step are cosine transformations on the rows of the matrix $ V$ (resp. $ Y$). Such a transformation of length $ n$ can be done using the Fast Fourier Transform (FFT) in $ 2.5 \, n \log n$ flops [33,22]), so we get a complexity of $ 5 \, n_1 n_2 \log
n_2 + 8 n_1 n_2$, because $ A$ and $ T$ are tridiagonal (under the assumption that $ n_2$ is a power of 2, or has at least small prime factors).



next up previous
Next: The Robbins boundary problem Up: A fast method for Previous: Introduction
Raf Vandebril 2004-04-19