0% found this document useful (0 votes)
21 views

GreensFunctionPrimer

Green's functions provide a method for solving boundary value problems with sources in differential equations, often simplifying the process compared to traditional methods. The document discusses the derivation of a Green's function for a one-dimensional heat equation and illustrates the solution process using integrals. Ultimately, once the Green's function is established, it allows for the computation of solutions to the original problem by integrating the product of the Green's function with the source function.

Uploaded by

Anurag Agarwal
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
21 views

GreensFunctionPrimer

Green's functions provide a method for solving boundary value problems with sources in differential equations, often simplifying the process compared to traditional methods. The document discusses the derivation of a Green's function for a one-dimensional heat equation and illustrates the solution process using integrals. Ultimately, once the Green's function is established, it allows for the computation of solutions to the original problem by integrating the product of the Green's function with the source function.

Uploaded by

Anurag Agarwal
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

An Introduction to Green’s Functions

Separation of variables is a great tool for working partial differential equation problems without
sources. When there are sources, the related method of eigenfunction expansion can be used, but
often it is easier to employ the method of Green’s functions. The general idea of a Green’s function
solution is to use integrals rather than series; in practice, the two methods often yield the same
solution form.
Students find the concept of a Green’s function solution to be hard to understand both because
the concept is abstract and because the required notation can be very confusing at first. One way
to work through these difficulties is to start by using Green’s functions to solve boundary value
problems for ordinary differential equations. Note that we are talking here about problems with
sources, not Sturm-Liouville problems.

A Simple Model Problem


Consider heat flow in one dimension with time-independent sources:

ρcut = K0 uxx + Q(x),

u(0, t) = 0, u(L, t) = 0,
u(x, 0) = f (x).
As time goes to infinity, the effect of the initial condition should disappear and the temperature
achieve an equilibrium distribution. This equilibrium temperature will satisfy the problem obtained
from the original by dropping the time derivative term from the differential equation and dropping
the initial condition. If we fold K0 into Q by defining
Q(x)
q(x) =
K0
and use the prime symbol for x derivatives of the equilibrium temperature u(x), we get the problem

−u00 = q(x), u(0) = 0, u(L) = 0. (1)

Solving the Model Problem with Ordinary Calculus


Problem (1) is a very simple problem, as differential equations go. Since u00 is given explicitly
as a function of x, we need only integrate twice. This problem could be used as a project in a
multivariable calculus course, but most students would find it difficult. Let’s work through it and
see why it is not quite so simple as it appears.1

Step 1: Integrate the differential equation once.


Since we don’t knowR an antiderivative for q, we need to construct one. It is not acceptable to
simply write −u0 = q(x) dx. The right side of this formula is not a function because it does not
have unique values. Instead, we need to use a definite integral. Using the fundamental theorem of
calculus, we can write Z x
d
q(x0 ) dx0 = q(x), (2)
dx 0
1
Of course it would be easy if we had a known simple function for q. But we want to write down a solution that
works for arbitrary q. That way we will have solved a general problem rather than a mere example.

1
which gives us a well-defined antiderivative function. Note that we could have started the integral
somewhere other than 0, but we’ll see later that 0 was the most convenient place. Also, we could
have used any symbol other than x for the integration variable, as x has already been assigned to
be the independent variable for the problem (1).
We’ve found one antiderivative of q, but with no useful boundary condition we will still need
an integration constant so that our formula includes all antiderivatives. Thus, we have
Z x
0
−u = q(x0 ) dx0 − C. (3)
0

Here we have chosen to call the constant −C rather than C for convenience. As it stands, C
represents the unknown value of u0 at x = 0.

Step 2: Integrate again using u(0) = 0.


For our next integration, we do have a useful boundary condition, so it is best to integrate (3)
from the known point u(0) = 0 to the arbitrary unknown point (x, u(x)). First rewrite (3) using a
dummy variable (s) in place of x:
Z s
du
=C− q(x0 ) dx0 .
ds 0

Now integrate both sides from s = 0 to s = x:


Z x Z x Z s 
du
ds = C− q(x0 ) dx0 ds.
0 ds 0 0

The left side and the first term on the right side are easy, giving us
Z xZ s
u(x) = Cx − q(x0 ) dx0 ds. (4)
0 0

Step 3: Reverse the order of integration to reduce the double integral.


The formula (4) does not yet satisfy the boundary condition at x = L. Before we do that, it would
be good to get rid of the double integral. We could easily integrate q(x0 ) with respect to s, but
that requires that we carefully reverse the order of integration.2
Figure 1 shows the domain of the integral. The picture on the left shows the nested inequalities
0 < s < x, 0 < x0 < s, which correspond to the original integral (4). Note that the outer variable
marks slices in the (s, x0 ) plane, while the inner variable indicates the extent of each slice, with
the upper bound dependent on the specific value of s for that slice. The picture on the right is the
same region, but with slices marked by the variable x0 rather than s. The slices now run over the
interval 0 < x0 < x, and the range of s along a slice is given by x0 < s < x; note that this time it
is the lower bound that is different for each slice. Thus, the solution formula can be rewritten as
Z xZ x Z x
u(x) = Cx − q(x0 ) ds dx0 = Cx − (x − x0 )q(x0 ) dx0 . (5)
0 x0 0

2
Multivariable calculus books teach this topic, but they do so with artificial problems. We don’t have to reverse
the order of integration for real calculus problems if we set them up correctly the first time. Very strong students
can see this for themselves, so they get the idea that reversing the order of integration is busywork of no practical
importance. However, differential equations solutions with double integrals necessarily obtain the integrals with the
wrong integration order, as has happened here. We should use this example in multivariable calculus so that students
know the real importance of the technique of reversing the order of integration.

2
x0 x0
6 x0 = s 6 s = x0
x x

- -
x s x s

Figure 1: Integration domains for (4) and (5).

Step 4: Use the boundary condition u(L) = 0 to evaluate C.


Substituting x = L into the solution (5) yields
Z L
0 = CL − (L − x0 )q(x0 ) dx0 ,
0

or Z L
1
C= (L − x0 )q(x0 ) dx0 .
L 0
Substituting this result into (5) yields
Z L  Z x
x
u(x) = (L − x0 )q(x0 ) dx0 − (x − x0 )q(x0 ) dx0 , (6)
0 L 0

which is the solution for the equilbrium temperature problem. If we want to evaluate the solution
for a particular q, the simplest procedure is to first calculate the functions
Z x Z x
q0 (x) = q(x0 ) dx0 , q1 (x) = x0 q(x0 ) dx0 . (7)
0 0

Once these functions are known, the solution can be calculated as


 
1
u(x) = q0 (L) − q1 (L) x − xq0 (x) + q1 (x). (8)
L

For general understanding, we can also rewrite the formula (6) in a way that shows an interesting
symmetry, first moving factors x and L around to get
Z L Z x
1 1
u(x) = x(L − x0 ) q(x0 ) dx0 − L(x − x0 ) q(x0 ) dx0 ,
L 0 L 0

and then splitting up the first integral into a portion from 0 to x and a portion from x to L, and
then combining the two integrals on 0 to x. The resulting formula is
Z x Z L
1 1
u(x) = x0 (L − x) q(x0 ) dx0 + x(L − x0 ) q(x0 ) dx0 . (9)
L 0 L x

3
Solving the Model Problem with Superposition
Did you enjoy the first method of solving the problem? Integrating by brute force is unnecessarily
complicated. There is a more conceptual method based on the idea of superposition. If we break
q up into components on different intervals in x, we can find the resulting u for each component
separately and then add the results. This is only beneficial if we have an easier time obtaining the
solution for a component than for the full interval, and that only happens if we have infinitely-many
intervals of width 0.
It is natural to think of q as a function distributed over an interval in x. However, we can
instead think of it as an infinite sum of point sources using the Dirac delta function:
Z L
q(x) = δ(x − x0 ) q(x0 ) dx0 . (10)
0
Before we proceed, it is important to confirm that this equation is correct and to understand what it
says conceptually. To check its accuracy, note that the integrand is 0 everywhere except at x0 = x;
hence, we can replace the function q(x0 ) with the constant q(x).3 Thus,
Z L Z L Z L
δ(x − x0 ) q(x0 ) dx0 = δ(x − x0 ) q(x) dx0 = q(x) δ(x − x0 ) dx0 = q(x),
0 0 0
where we have used the basic property of the delta function to evaluate the last integral. To
interpret (10), think of δ(x − x0 ) as a unit point source at x = x0 and q(x0 ) dx0 as the strength of
this source. Thus, δ(x − x0 )q(x0 ) dx0 is a point source of appropriate strength located at x0 and
the distributed function q(x) is the infinite sum of all such point sources.
Now define the Green’s function G(x; x0 ) to be the response of the boundary value problem to
a unit point source located at x = x0 ;4 that is, G is the solution of
−u00 (x) = δ(x − x0 ), u(0) = 0, u(L) = 0. (11)
Once we have found the Green’s function, we will have the response to a unit point source at an
arbitrary location. Just as we can build q(x) by adding up products of the unit source δ(x−x0 ) and
the source strength q(x0 ) dx0 , we can build u(x) by adding up products of the unit-source response
G(x; x0 ) and the source strength q(x0 ) dx0 :
Z L
u(x) = G(x; x0 ) q(x0 ) dx0 . (12)
0

Calculating the Green’s Function


Given that we have already got the solution (9) for (1), we can identify the Green’s function as

1 x(L − x0 ), x < x0
G(x; x0 ) = . (13)
L x0 (L − x), x > x0
Note how simple it is: it is piecewise linear, 0 at both endpoints, continuous at x = x0 , and has
the symmetry property G(x; x0 ) = G(x0 ; x).
Now suppose we want to use the Green’s function method to solve (1). This only requires us
to solve the problem (11) to find the Green’s function (13); then formula (12) gives us the solution
of (1). This is bound to be an improvement over the direct method because we need only solve the
simplest possible special case of (1).
3
In the context of the integral, x0 is the integration variable and x is merely a parameter.
4
Some authors use a comma rather than a semicolon. The semicolon is helpful in that it identifies x as an
independent variable and x0 as a parameter. The function G is the response at all points x to a source located at
the specific arbitrary point x0 .

4
Step 1: Integrate the differential equation on the separate domains 0 < x < x0 and
x0 < x < L.
Equation (11) reduces to the trivial equation u00 = 0 on any interval that does not include x = x0 ;
hence, we can immediately write down the general solution on each of the intervals 0 < x < x0 and
x0 < x < L: 
A + Bx, x < x0
u= . (14)
C + Dx, x > x0
In one extremely quick step, we have reduced the problem from a differential equation with bound-
ary conditions to an algebra problem for four unknown constants.

Step 2: Use the boundary conditions at 0 and L.


The boundary conditions u(0) = 0 and u(L) = 0, respectively, give us A = 0 and C = −DL. Thus,
we have 
Bx, x < x0
u= . (15)
D(x − L), x > x0

Step 3: Integrate the differential equation from x0 −  to x0 +  for arbitrarily small .


Integrating the differential equation (11) yields
Z x0 + Z x0 +
δ(x − x0 ) dx0 = − u00 dx,
x0 − x0 −
or
1 = −u0 (x0 + ) + u0 (x0 − ) = −D + B.
Thus, B = 1 + D and
 
(1 + D)x, x < x0 1 (L + DL)x, x < x0
u= = . (16)
D(x − L), x > x0 L DL(x − L), x > x0

Step 4: Enforce continuity at x0 .


At x = x0 , we must have
(1 + D)x0 = D(x0 − L);
hence, DL = −x0 . This yields the final result

1 x(L − x0 ), x < x0
G(x; x0 ) = . (17)
L x0 (L − x), x > x0

Summary
The Green’s function for any problem with a distributed source is the solution of the corresponding
problem with an arbitrary unit point source. Once the Green’s function is known, the solution of
the original problem can be computed by integrating the product of the Green’s function with the
source function. We’ve seen that this reduces the workload when applied to an ordinary differential
equation. In the context of partial differential equations, there will generally be no simple method
for finding the solution with a distributed source, but if the geometry is simple we will have little
difficulty in finding the Green’s function. In particular, the Green’s function method will always
work for the 1D heat equation. It is not generally used for the wave equation because the method
of characteristics is much more powerful.

You might also like