A Beginner's Course in Boundary Element Methods: Whye-Teong Ang
A Beginner's Course in Boundary Element Methods: Whye-Teong Ang
x
2
+
2
y
2
= 0. (1.1)
The Laplaces equation occurs in the formulation of prob-
lems in many diverse elds of studies in engineering and physi-
cal sciences, such as thermostatics, elastostatics, electrostatics,
magnetostatics, ideal uid ow and ow in porous media.
An interior boundary value problem which is of practical
interest requires solving Eq. (1.1) in the two-dimensional region
R (on the Oxy plane) bounded by a simple closed curve C
subject to the boundary conditions
= f
1
(x, y) for (x, y) C
1
,
n
= f
2
(x, y) for (x, y) C
2
, (1.2)
where f
1
and f
2
are suitably prescribed functions and C
1
and
C
2
are non-intersecting curves such that C
1
C
2
= C. Refer
to Figure 1.1 for a geometrical sketch of the problem.
7
Figure 1.1
The normal derivative /n in Eq. (1.2) is dened by
n
= n
x
x
+ n
y
y
, (1.3)
where n
x
and n
y
are respectively the x and y components of a
unit normal vector to the curve C. Here the unit normal vector
[n
x,
n
y
] on C is taken to be pointing away from the region R.
Note that the normal vector may vary from point to point on
C. Thus, [n
x
, n
y
] is a function of x and y.
The boundary conditions given in Eq. (1.2) are assumed to
be properly posed so that the boundary value problem has a
unique solution, that is, it is assumed that one can always nd
a function (x, y) satisfying Eqs. (1.1)-(1.2) and that there is
only one such function.
For a particular example of practical situations involving
the boundary value problem above, one may mention the clas-
sical heat conduction problem where denotes the steady-state
temperature in an isotropic solid. Eq. (1.1) is then the temper-
ature governing equation derived, under certain assumptions,
from the law of conservation of heat energy together with the
8
Fouriers heat ux model. The heat ux out of the region R
across the boundary C is given by /n, where is the
thermal heat conductivity of the solid. Thus, the boundary
conditions in Eq. (1.2) imply that at each and every given
point on C either the temperature or the heat ux (but not
both) is known. To determine the temperature eld in the
solid, one has to solve Eq. (1.1) in R to nd the solution that
satises the prescribed boundary conditions on C.
In general, it is dicult (if not impossible) to solve exactly
the boundary value problem dened by Eqs. (1.1)-(1.2). The
mathematical complexity involved depends on the geometrical
shape of the region R and the boundary conditions given in Eq.
(1.2). Exact solutions can only be found for relatively simple
geometries of R (such as a square region) together with partic-
ular boundary conditions. For more complicated geometries or
general boundary conditions, one may have to resort to numer-
ical (approximate) techniques for solving Eqs. (1.1)-(1.2).
This chapter introduces a boundary element method for the
numerical solution of the interior boundary value problem de-
ned by Eqs. (1.1)-(1.2). We show how a boundary integral so-
lution can be derived for Eq. (1.1) and applied to obtain a sim-
ple boundary element procedure for approximately solving the
boundary value problem under consideration. The implemen-
tation of the numerical procedure on the computer, achieved
through coding in FORTRAN 77, is discussed in detail.
1.2 Fundamental Solution
If we use polar coordinates r and centered about (0, 0), as
dened by x = r cos and y = r sin, and introduce (r, ) =
(r cos , r sin), we can rewrite Eq. (1.1) as
1
r
r
(r
r
) +
1
r
2
2
= 0. (1.4)
For the case in which is independent of , that is, if
is a function of r alone, Eq. (1.4) reduces to the ordinary
9
dierential equation
d
dr
(r
d
dr
[(r)]) = 0 for r 6= 0. (1.5)
The ordinary dierential equation in Eq. (1.5) can be easily
integrated twice to yield the general solution
(r) = Aln(r) + B, (1.6)
where A and B are arbitrary constants.
From (1.6), it is obvious that the two-dimensional Laplaces
equation in Eq. (1.1) admits a class of particular solutions given
by
(x, y) = Aln
p
x
2
+ y
2
+ B for (x, y) 6= (0, 0). (1.7)
If we choose the constants A and B in (1.7) to be 1/(2)
and 0 respectively and shift the center of the polar coordinates
from (0, 0) to the general point (, ), a particular solution of
Eq. (1.1) is
(x, y) =
1
2
ln
p
(x )
2
+ (y )
2
for (x, y) 6= (, ).
(1.8)
As we shall see, the particular solution in Eq. (1.8) plays an
important role in the development of boundary element meth-
ods for the numerical solution of the interior boundary value
problem dened by Eqs. (1.1)-(1.2). We specially denote this
particular solution using the symbol (x, y; , ), that is, we
write
(x, y; , ) =
1
4
ln[(x )
2
+ (y )
2
]. (1.9)
We refer to (x, y; , ) in Eq. (1.9) as the fundamental
solution of the two-dimensional Laplaces equation. Note that
(x, y; , ) satises Eq. (1.1) everywhere except at (, ) where
it is not well dened.
10
1.3 Reciprocal Relation
If
1
and
2
are any two solutions of Eq. (1.1) in the region
R bounded by the simple closed curve C then it can be shown
that
Z
C
(
2
1
n
1
2
n
)ds(x, y) = 0. (1.10)
Eq. (1.10) provides a reciprocal relation between any two
solutions of the Laplaces equation in the region R bounded by
the curve C. It may be derived from the two-dimensional version
of the Gauss-Ostrogradskii (divergence) theorem as explained
below.
According to the divergence theorem, if F= u(x, y)i+v(x, y)j
is a well dened vector function such that F = u/x+v/y
exists in the region R bounded by the simple closed curve C
then
Z
C
F n ds(x, y) =
ZZ
R
F dxdy,
that is,
Z
C
[un
x
+ vn
y
]ds(x, y) =
ZZ
R
[
u
x
+
v
y
]dxdy,
where n = [n
x
, n
y
] is the unit normal vector to the curve C,
pointing away from the region R.
Since
1
and
2
are solutions of Eq. (1.1), we may write
1
x
2
+
2
1
y
2
= 0,
2
x
2
+
2
2
y
2
= 0.
If we multiply the rst equation by
2
and the second one
by
1
and take the dierence of the resulting equations, we
11
obtain
x
(
2
1
x
1
2
x
) +
y
(
2
1
y
1
2
y
) = 0,
which can be integrated over R to give
ZZ
R
[
x
(
2
1
x
1
2
x
) +
y
(
2
1
y
1
2
y
)]dxdy = 0.
Application of the divergence theorem to convert the double
integral over R into a line integral over C yields
Z
C
[(
2
1
x
1
2
x
)n
x
+ (
2
1
y
1
2
y
)n
y
]ds(x, y) = 0
which is essentially Eq. (1.10).
Together with the fundamental solution given by Eq. (1.9),
the reciprocal relation in Eq. (1.10) can be used to derive
a useful boundary integral solution for the two-dimensional
Laplaces equation.
1.4 Boundary Integral Solution
Let us take
1
= (x, y; , ) (the fundamental solution as de-
ned in Eq. (1.9)) and
2
= , where is the required solution
of the interior boundary value problem dened by Eqs. (1.1)-
(1.2).
Since (x, y; , ) is not well dened at the point (, ), the
reciprocal relation in Eq. (1.10) is valid for
1
= (x, y; , )
and
2
= only if (, ) does not lie in the region RC. Thus,
Z
C
[(x, y)
n
((x, y; , ))
(x, y; , )
n
((x, y))]ds(x, y)
= 0 for (, ) / R C. (1.11)
12
Figure 1.2
A more interesting and useful integral equation than Eq.
(1.11) can be derived from Eq. (1.10) if we take the point (, )
to lie in the region R C.
For the case in which (, ) lies in the interior of R, Eq.
(1.10) is valid if we replace C by C C
, where C
is a circle
of center (, ) and radius as shown in Figure 1.2
1
. This is
because (x, y; , ) and its rst order partial derivatives (with
respect to x or y) are well dened in the region between C and
C
[(x, y)
n
((x, y; , ))
(x, y; , )
n
((x, y))]ds(x, y)
= 0. (1.12)
1
The divergence theorem is not only applicable for simply connected
regions but also for multiply connected ones such as the one shown in
Figure 1.2. For the region in Figure 1.2, the unit normal vector to C
(the
inner boundary) points towards the center of the circle.
13
Eq. (1.12) holds for any radius > 0, so long as the circle
C
[(x, y)
n
((x, y; , ))
(x, y; , )
n
((x, y))]ds(x, y). (1.13)
Using polar coordinates r and centered about (, ) as
dened by x = r cos and y = r sin, we may write
(x, y; , ) =
1
2
ln(r),
n
[(x, y; , )] = n
x
x
[(x, y; , )] + n
y
y
[(x, y; , )]
=
n
x
cos + n
y
sin
2r
. (1.14)
The Taylors series of (x, y) about the point (, ) is given
by
(x, y) =
X
m=0
m
X
k=0
(
m
x
k
y
mk
)
(x,y)=(,)
(x )
k
(y )
mk
k!(mk)!
.
On the circle C
, r = . Thus,
(x, y) =
X
m=0
m
X
k=0
(
m
x
k
y
mk
[(x, y)])
(x,y)=(,)
m
cos
k
sin
mk
k!(mk)!
for (x, y) C
. (1.15)
14
Similarly, we may write
n
[(x, y)] =
X
m=0
m
X
k=0
(
m
x
k
y
mk
{
n
[(x, y)]})
(x,y)=(,)
m
cos
k
sin
mk
k!(mk)!
for (x, y) C
.
(1.16)
Using Eqs. (1.14), (1.15) and (1.16) and writing ds(x, y) =
d with ranging from 0 to 2, we may now attempt to eval-
uate the limit on the right hand side of Eq. (1.13). On C
, the
normal vector [n
x
, n
y
] is given by [cos , sin]. Thus,
Z
C
(x, y)
n
[(x, y; , ]ds(x, y)
=
1
2
(, )
2
Z
0
d
1
2
X
m=1
m
X
k=0
m
k!(mk)!
(
m
x
k
y
mk
)
(x,y)=(,)
2
Z
0
cos
k
sin
mk
d
(, ) as 0
+
, (1.17)
and
Z
C
(x, y; , )
n
[(x, y)]ds(x, y)
=
1
2
X
m=0
m
X
k=0
(
m
x
k
y
mk
(
n
[(x, y)]))
(x,y)=(,)
m+1
ln()
k!(mk)!
2
Z
0
cos
k
sin
mk
d
0 as 0
+
, (1.18)
15
since
m+1
ln() 0 as 0
+
for m = 0, 1, 2, .
Consequently, as 0
+
, Eq. (1.13) yields
(, ) =
Z
C
[(x, y)
n
((x, y; , ))
(x, y; , )
n
((x, y))]ds(x, y)
for (, ) R. (1.19)
Together with Eq. (1.9), Eq. (1.19) provides us with a
boundary integral solution for the two-dimensional Laplaces
equation. If both and /n are known at all points on
C, the line integral in Eq. (1.19) can be evaluated (at least
in theory) to calculate at any point (, ) in the interior of
R. From the boundary conditions (1.2), however, at any given
point on C, either or /n, not both, is known.
To solve the interior boundary value problem, we must nd
the unknown and /n on C
2
and C
1
respectively. As we
shall see later on, this may be done through manipulation of
data on the boundary C only, if we can derive a boundary
integral formula for (, ), similar to the one in Eq. (1.19), for
a general point (, ) that lies on C.
For the case in which the point (, ) lies on C, Eq. (1.10)
holds if we replace the curve C by DD
and D
is the part of C
[(x, y)
n
((x, y; , ))
(x, y; , )
n
((x, y))]ds(x, y). (1.20)
16
Let us examine what happens to Eq. (1.20) when we let
0
+
.
As 0
+
, the curve D tends to C. Thus, we may write
Z
C
[(x, y)
n
((x, y; , ))
(x, y; , )
n
((x, y))]ds(x, y)
= lim
0
+
Z
D
[(x, y)
n
((x, y; , ))
(x, y; , )
n
((x, y))]ds(x, y). (1.21)
Figure 1.3
Note that, unlike in Eq. (1.13), the line integral over C in
Eq. (1.21) is improper as its integrand is not well dened at
(, ) which lies on C. Strictly speaking, the line integration
should be over the curve C without an innitesimal segment
that contains the point (, ), that is, the line integral over C
in Eq. (1.21) has to be interpreted in the Cauchy principal
sense if (, ) lies on C.
To evaluate the limit on the right hand side of Eq. (1.21),
we need to know what happens to D
when we let 0
+
. Now
17
if (, ) lies on a smooth part of C (not at where the gradient
of the curve changes abruptly, that is, not at a corner point, if
there is any), one can intuitively see that the part of C inside C
to tend to a semi-circle as 0
+
, if (, ) lies on a
smooth part of C. It follows that in attempting to evaluate the
limit on the right hand side of Eq. (1.21) we have to integrate
over only half a circle (instead of a full circle as in the case of
Eq. (1.13)).
Modifying Eqs. (1.17) and (1.18), we obtain
lim
0
+
Z
D
(x, y)
n
[(x, y; , )]ds(x, y) =
1
2
(, ),
lim
0
+
Z
D
(x, y; , )
n
[(x, y)]ds(x, y) = 0.
Hence Eq. (1.21) gives
1
2
(, ) =
Z
C
[(x, y)
n
((x, y; , ))
(x, y; , )
n
((x, y))]ds(x, y)
for (, ) lying on a smooth part of C.
(1.22)
Together with the boundary conditions in Eq. (1.2), Eq.
(1.22) may be applied to obtain a numerical procedure for de-
termining the unknown and/or /n on the boundary C.
Once and /n are known at all points on C, the solution
of the interior boundary value problem dened by Eqs. (1.1)-
(1.2) is given by Eq. (1.19) at any point (, ) inside R. More
details are given in Section 1.5 below.
For convenience, we may write Eqs. (1.11), (1.19) and
(1.22) as a single equation given by
18
(, )(, ) =
Z
C
[(x, y)
n
((x, y; , ))
(x, y; , )
n
((x, y))]ds(x, y),
(1.23)
if we dene
(, ) =
0 if (, ) / R C,
1/2 if (, ) lies on a smooth part of C,
1 if (, ) R.
(1.24)
1.5 Boundary Element Solution with Con-
stant Elements
We now show how Eq. (1.23) may be applied to obtain a simple
boundary element procedure for solving numerically the interior
boundary value problem dened by Eqs. (1.1)-(1.2).
The boundary C is approximated as an N-sided polygon
with sides C
(1)
, C
(2)
, , C
(N1)
and C
(N)
, that is,
C ' C
(1)
C
(2)
C
(N1)
C
(N)
. (1.25)
The sides or the boundary elements C
(1)
, C
(2)
, , C
(N1)
and C
(N)
are constructed as follows. We put N well spaced
out points given by (x
(1)
, y
(1)
), (x
(2)
, y
(2)
), , (x
(N1)
, y
(N1)
)
and (x
(N)
, y
(N)
) on C, in the order given, following the counter
clockwise direction. Dening (x
(N+1)
, y
(N+1)
) = (x
(1)
, y
(1)
),
we take C
(k)
to be the boundary element from (x
(k)
, y
(k)
) to
(x
(k+1)
, y
(k+1)
) for k = 1, 2, , N.
As an example, in Figure 1.4, the boundary C = C
1
C
2
in
Figure 1.1 is approximated using 5 boundary elements denoted
by C
(1)
, C
(2)
, C
(3)
, C
(4)
and C
(5)
.
19
Figure 1.4
For a simple approximation of and /n on the bound-
ary C, we assume that these functions are constants over each
of the boundary elements. Specically, we make the approxi-
mation:
'
(k)
and
n
= p
(k)
for (x, y) C
(k)
(k = 1, 2, , N),
(1.26)
where
(k)
and p
(k)
are respectively the values of and /n
at the midpoint of C
(k)
.
With Eqs. (1.25) and (1.26), we nd that Eq. (1.23) can
be approximately written as
(, )(, ) =
N
X
k=1
{
(k)
F
(k)
2
(, ) p
(k)
F
(k)
1
(, )}, (1.27)
where
F
(k)
1
(, ) =
Z
C
(k)
(x, y; , )ds(x, y),
F
(k)
2
(, ) =
Z
C
(k)
n
[(x, y; , )]ds(x, y). (1.28)
20
For a given k, either
(k)
or p
(k)
(not both) is known from
the boundary conditions in Eq. (1.2). Thus, there are N un-
known constants on the right hand side of Eq. (1.27). To deter-
mine their values, we have to generate N equations containing
the unknowns.
If we let (, ) in Eq. (1.27) be given in turn by the mid-
points of C
(1)
, C
(2)
, , C
(N1)
and C
(N)
, we obtain
1
2
(m)
=
N
X
k=1
{
(k)
F
(k)
2
(x
(m)
, y
(m)
) p
(k)
F
(k)
1
(x
(m)
, y
(m)
)}
for m = 1, 2, , N, (1.29)
where (x
(m)
, y
(m)
) is the midpoint of C
(m)
.
In the derivation of Eq. (1.29), we take (x
(m)
, y
(m)
) = 1/2,
since (x
(m)
, y
(m)
) being the midpoint of C
(m)
lies on a smooth
part of the approximate boundary C
(1)
C
(2)
C
(N1)
C
(N)
.
Eq. (1.29) constitutes a system of N linear algebraic equa-
tions containing the N unknowns on the right hand side of Eq.
(1.27). We may rewrite it as
N
X
k=1
a
(mk)
z
(k)
=
N
X
k=1
b
(mk)
for m = 1, 2, , N, (1.30)
where a
(mk)
, b
(mk)
and z
(k)
are dened by
a
(mk)
=
F
(k)
1
(x
(m)
, y
(m)
) if is specied over C
(k)
,
F
(k)
2
(x
(m)
, y
(m)
)
1
2
(mk)
if /n is
specied over C
(k)
,
b
(mk)
=
(k)
(F
(k)
2
(x
(m)
, y
(m)
) +
1
2
(mk)
)
if is specied over C
(k)
,
p
(k)
F
(k)
1
(x
(m)
, y
(m)
) if /n is specied
over C
(k)
,
(mk)
=
0 if m 6= k,
1 if m = k,
z
(k)
=
(
p
(k)
if is specied over C
(k)
,
(k)
if /n is specied over C
(k)
.
(1.31)
21
Note that z
(1)
, z
(2)
, , z
(N1)
and z
(N)
are the N unknown
constants on the right hand side of Eq. (1.27), while a
(mk)
and
b
(mk)
are known coecients.
Once Eq. (1.30) is solved for the unknowns z
(1)
, z
(2)
, ,
z
(N1)
and z
(N)
, the values of and /n over the element
C
(k)
, as given by
(k)
and p
(k)
respectively, are known for k = 1,
2, , N. Eq. (1.27) with (, ) = 1 then provides us with an
explicit formula for computing in the interior of R, that is,
(, ) '
N
X
k=1
{
(k)
F
(k)
2
(, ) p
(k)
F
(k)
1
(, )} for (, ) R.
(1.32)
To summarize, a boundary element solution of the interior
boundary value problem dened by Eqs. (1.1)-(1.2) is given
by Eq. (1.32) together with Eqs. (1.28), (1.30) and (1.31).
Because of the approximation in Eqs. (1.25) and (1.26), the
solution is said to be obtained using constant elements. Ana-
lytical formulae for calculating F
(k)
1
(, ) and F
(k)
2
(, ) in Eq.
(1.28) are given in Eqs. (1.37), (1.38), (1.40) and (1.41) (to-
gether with Eq. (1.35)) in the section below.
1.6 Formulae for Integrals of Constant El-
ements
The boundary element solution above requires the evaluation of
F
(k)
1
(, ) and F
(k)
2
(, ). These functions are dened in terms
of line integrals over C
(k)
as given in Eq. (1.28). The line
integrals can be worked out analytically as follows.
Points on the element C
(k)
may be described using the para-
metric equations
x = x
(k)
t`
(k)
n
(k)
y
y = y
(k)
+ t`
(k)
n
(k)
x
)
from t = 0 to t = 1, (1.33)
where `
(k)
is the length of C
(k)
and [n
(k)
x
, n
(k)
y
] = [y
(k+1)
y
(k)
, x
(k)
x
(k+1)
]/`
(k)
is the unit normal vector to C
(k)
pointing
away from R.
22
For (x, y) C
(k)
, we nd that ds(x, y) =
p
(dx)
2
+ (dy)
2
=
`
(k)
dt and
(x )
2
+ (y )
2
= A
(k)
t
2
+ B
(k)
(, )t + E
(k)
(, ), (1.34)
where
A
(k)
= [`
(k)
]
2
,
B
(k)
(, ) = [n
(k)
y
(x
(k)
) + (y
(k)
)n
(k)
x
](2`
(k)
),
E
(k)
(, ) = (x
(k)
)
2
+ (y
(k)
)
2
. (1.35)
For any point (, ), the parameters in Eq. (1.35) satisfy
4A
(k)
E
(k)
(, ) [B
(k)
(, )]
2
0. To see why this is true,
consider the straight line dened by the parametric equations
x = x
(k)
t`
(k)
n
(k)
y
and y = y
(k)
+ t`
(k)
n
(k)
x
for < t < .
Note that C
(k)
is a subset of this straight line (given by the
parametric equations from t = 0 to t = 1). Eq. (1.34) also
holds for any point (x, y) lying on the extended line. If (, )
does not lie on the line then A
(k)
t
2
+B
(k)
(, )t +E
(k)
(, ) > 0
for all real values of t (that is, for all points (x, y) on the line)
and hence 4A
(k)
E
(k)
(, ) [B
(k)
(, )]
2
> 0. On the other
hand, if (, ) is on the line, we can nd exactly one point
(x, y) such that A
(k)
t
2
+ B
(k)
(, )t + E
(k)
(, ) = 0. As each
point (x, y) on the line is given by a unique value of t, we con-
clude that 4A
(k)
E
(k)
(, ) [B
(k)
(, )]
2
= 0 for (, ) lying on
the line.
From Eqs. (1.28), (1.33) and (1.34), F
(k)
1
(, ) and F
(k)
2
(, )
may be written as
F
(k)
1
(, ) =
`
(k)
4
1
Z
0
ln[A
(k)
t
2
+ B
(k)
(, )t + E
(k)
(, )]dt,
F
(k)
2
(, ) =
`
(k)
2
1
Z
0
n
(k)
x
(x
(k)
) + n
(k)
y
(y
(k)
)
A
(k)
t
2
+ B
(k)
(, )t + E
(k)
(, )
dt.
(1.36)
The second integral in Eq. (1.36) is the easiest one to work
out for the case in which 4A
(k)
E
(k)
(, ) [B
(k)
(, )]
2
= 0. For
23