Professional Documents
Culture Documents
Lecture 2 28 Short
Lecture 2 28 Short
Lecture 2 28 Short
The one dimensional heat equation: Neumann and Robin boundary conditions
Ryan C. Daileda
Trinity University
Daileda
Our goal is to solve: ut = c 2 uxx , ux (0, t) = ux (L, t) = 0, u(x, 0) = f (x), 0 < x < L , 0 < t, 0 < t, 0 < x < L. (1) (2) (3)
As before, we will use separation of variables to nd a family of simple solutions to (1) and (2), and then the principle of superposition to construct a solution satisfying (3).
Daileda
Separation of variables
Assuming that u(x, t) = X (x)T (t), the heat equation (1) becomes XT = c 2 X T . This implies T X = 2 = k, X c T which we write as X kX = 0, T c kT = 0.
2
(4) (5)
The initial conditions (2) become X (0)T (t) = X (L)T (t) = 0, or X (0) = X (L) = 0.
Daileda The heat equation
(6)
Case 1: k = 2 > 0
The ODE (4) becomes X 2 X = 0 with general solution X = c1 e x + c2 e x . The boundary conditions (6) are 0 = X (0) = c1 c2 = (c1 c2 ), 0 = X (L) = c1 e L c2 e L = (c1 e L c2 e L ). The rst gives c1 = c2 . When we substitute this into the second we get 2c1 sinh L = 0. Since , L > 0, we must have c1 = c2 = 0. Hence X = 0, i.e. there are only trivial solutions in the case k > 0.
Daileda The heat equation
Case 2: k = 0
The ODE (4) is simply X = 0 so that X = Ax + B. The boundary conditions (6) yield 0 = X (0) = X (L) = A. Taking B = 1 we get the solution X0 = 1. The corresponding equation (5) for T is T = 0, which yields T = C . We set T0 = 1. These give the zeroth normal mode: u0 (x, t) = X0 (x)T0 (t) = 1.
Daileda The heat equation
Case 3: k = 2 < 0
The ODE (4) is now X + 2 X = 0 with solutions X = c1 cos x + c2 sin x. The boundary conditions (6) yield 0 = X (0) = c1 sin 0 + c2 cos 0 = c2 , 0 = X (L) = c1 sin L + c2 cos L. The rst of these gives c2 = 0. In order for X to be nontrivial, the second shows that we also need sin L = 0.
Daileda
Case 3: k = 2 < 0
This can occur if and only if L = n, that is = n = n , n = 1, 2, 3, . . . L
Choosing c1 = 1 yields the solutions Xn = cos n x, n = 1, 2, 3, . . . For each n the corresponding equation (5) for T becomes T = 2 T , with n = cn . Up to a constant multiple, the n solution is 2 Tn = e n t .
Daileda
u(x, t) = a0 u0 +
n=1
an un = a0 +
n=1
an e n t cos n x
(7)
is a solution of the heat equation (1) with the Neumann boundary conditions (2).
Daileda
Initial conditions
If we now require that the solution (7) satisfy the initial condition (3) we nd that we need
f (x) = u(x, 0) = a0 +
n=1
an cos
nx , 0 < x < L. L
This is simply the cosine series expansion of f (x). Using our previous results, we nally nd that if f (x) is piecewise smooth then a0 = 1 L
L
f (x) dx, an =
0
2 L
f (x) cos
0
nx dx, n 1. L
Daileda
Conclusion
Theorem If f (x) is piecewise smooth, the solution to the heat equation (1) with Neumann boundary conditions (2) and initial conditions (3) is given by
u(x, t) = a0 +
n=1
an e n t cos n x,
where
n , n = cn , L and the coecients a0 , a1 , a2 , . . . are those occurring in the cosine series expansion of f (x). They are given explicitly by n = a0 = 1 L
L
f (x) dx, an =
0
Daileda
2 L
f (x) cos
0
nx dx, n 1. L
Example 1
Example Solve the following heat conduction problem: 1 ut = uxx , 4 ux (0, t) = ux (1, t) = 0, u(x, 0) = 100x(1 x), 0 < x < 1 , 0 < t, 0 < t, 0 < x < 1.
a0 =
0 1
100x(1 x) dx =
50 3
an = 2
0
100x(1 x) cos nx dx =
Daileda
200(1 + (1)n ) , n 1. n2 2
Example 1
Since c = 1/2, n = n/2. Plugging everything into our general solution we get u(x, t) = 50 200 2 3
n=1
As in the case of Dirichlet boundary conditions, the exponential terms decay rapidly with t. We have
t
lim u(x, t) =
50 . 3
Daileda
Remarks
At any given time, the average temperature in the bar is u(t) = 1 L
L
u(x, t) dx.
0
In the case of Neumann boundary conditions, one has u(t) = a0 = f . That is, the average temperature is constant and is equal to the initial average temperature. Also in this case lim u(x, t) = a0
t
for all x. That is, at any point in the bar the temperature tends to the initial average temperature.
Daileda The heat equation
In (9) we take > 0. This states that the bar radiates heat to its surroundings at a rate proportional to its current temperature. Recall that conditions such as (9) are called Robin conditions.
Daileda The heat equation
Separation of variables
As before, the assumption that u(x, t) = X (x)T (t) leads to the ODEs X kX = 0, T c 2 kT = 0, and the boundary conditions (8) and (9) imply X (0) = 0, X (L) = X (L). Also as before, the possibilities for X depend on the sign of the separation constant k.
Daileda
Case 1: k = 0
We have X = 0 and so X = Ax + B with 0 = X (0) = B, A = X (L) = X (L) = (AL + B). Together these give A(1 + L) = 0. Since , L > 0, we have A = 0 and hence X = 0. Thus, there are only trivial solutions in this case.
Daileda
Case 2: k = 2 > 0
Once again we have X 2 X = 0 and X = c1 e x + c2 e x . The boundary conditions become 0 = c1 + c2 , (c1 e
L
c2 e
) = (c1 e L + c2 e L ).
The rst gives c2 = c1 , which when substituted in the second yields 2c1 cosh L = 2c1 sinh L.
Daileda
Case 2: k = 2 > 0
We may rewrite this as c1 ( cosh L + sinh L) = 0. The quantity in parentheses is positive (since , and L are), so this means we must have c1 = c2 = 0. Hence X = 0 and there are only trivial solutions in this case.
Daileda
Case 3: k = 2 < 0
From X + 2 X = 0 we nd X = c1 cos x + c2 sin x and from the boundary conditions we have 0 = c1 , (c1 sin L + c2 cos L) = (c1 cos L + c2 sin L). Together these imply that c2 ( cos L + sin L) = 0.
Daileda
Case 3: k = 2 < 0
Since we want nontrivial solutions (i.e. c2 = 0), we must have cos L + sin L = 0 which can be rewritten as tan L = . This equation has an innite sequence of positive solutions 0 < 1 < 2 < 3 <
Daileda
Case 3: k = 2 < 0
The gure below shows the curves y = tan L (in red) and y = / (in blue).
Remarks
From the diagram we see that: For each n (2n 1)/2L < n < n/L.
As n n (2n 1)/2L.
Daileda
Normal modes
As in the earlier situations, for each n 1 we have the solution Xn = sin n x and the corresponding Tn = e n t , n = cn which give the normal modes of the heat equation with boundary conditions (8) and (9) un (x, t) = Xn (x)Tn (t) = e n t sin n x.
2 2
Daileda
Superposition
Superposition of normal modes gives the general solution
u(x, t) =
n=1
cn un (x, t) =
n=1
cn e n t sin n x.
f (x) =
n=1
cn sin n x.
This is a generalized Fourier series for f (x). It is dierent from the ordinary sine series for f (x) since n is not a multiple of a common value.
Daileda
f , Xn
=
m=1
= cn sin n x, sin n x = cn Xn , Xn since the inner products with m = n all equal zero.
Daileda
f , Xn cn = = Xn , Xn
f (x) sin n x dx
0 L
. sin n x dx
2
For any given f (x) these integrals can typically be computed explicitly in terms of n . The values of n , however, must typically be found via numerical methods.
Daileda
Conclusion
Theorem The solution to the heat equation (1) with Robin boundary conditions (8) and (9) and initial condition (3) is given by
u(x, t) =
n=1
cn e n t sin n x,
Example 2
Example Solve the following heat conduction problem: ut = 1 uxx , 25 u(0, t) = 0, 0 < x < 3 , 0 < t, 0 < t, 0 < t, 0 < x < 3.
Daileda
Example 2
100
0
and
0
sin2 n x dx = Hence cn =
Daileda
Example 2
u(x, t) =
n=1
Daileda
Example 2
Remarks: In order to use this solution for numerical approximation or visualization, we must compute the values n . This can be done numerically in Maple, using the fsolve command. Specically, n can be computed via the command fsolve(tan(mL)=-m/k,m=(2n-1)Pi/(2L)..nPi/L); where L and k have been assigned the values of L and , respectively. These values can be computed and stored in an Array structure, or one can dene n as a function using the -> operator.
Daileda
Example 2
Here are approximate values for the rst 5 values of n and cn . n 1 2 3 4 5 Therefore u(x, t) = 47.0449e 0.0210t sin(0.7249x) + 45.1413e 0.1113t sin(1.6679x) + 21.3586e 0.2872t sin(2.6795x) + 19.3403e 0.5505t sin(3.7098x) + 12.9674e 0.9015t sin(4.7474x) +
Daileda The heat equation