Boundary-value Problems in Rectangular Coordinates 2009
Outline Separation of Variables: Heat Equation on a Slab Separation of Variables: Vibrating String Separation of Variables: Laplace Equation Review on Boundary Conditions Dirichlet s Problems Neumann s Problems Robin s Problems(Optional) 2D Heat Equation 2D Wave Equation
Separation of Variables Separation of Variables
One Dimensional Heat Equation (Heat Conduction on a Slab) Problem: Consider a unifrom slab (or rod or bar) of length L with insulated lateral surface. Let the internal temperature distribution on the slab be u(x, t) at point x and time t. Given that at time t = the temperature distribution of the slab is f(x), and given that both ends on the slab are held at zero constant temperature. Find the subsequent temperature distribution u(x, t) for 0 < x < L and t > 0 on the slab. (Of course, from our experience we know that u 0 as t, and our solution for u(x, t) should also capture this observation.)
Boundary-value Problem 1D Heat Equation: u t = 2 u c2, x2 0 < x < L, t > 0; (1) Boundary Conditions (Zero temperature at both ends): u(0, t) = 0 and u(l, t) = 0, t > 0; (2) Initial condition (Initial temperature distribution f(x)): u(x, 0) = f(x), 0 < x < L. (3)
Separation of variables Let u(x, t) = X(x)T (t), differentiate & subsitute into Eq.(1): T c 2 T = X X = k, Which gives a set of two ODEs: Now, the boundary condition becomes X kx = 0, (4) T kc 2 T = 0. (5) u(0, t) = X(0)T (t) = 0 = X(0) = 0 t > 0, (6) u(l, t) = X(L)T (t) = 0 = X(L) = 0 t > 0. (7)
There are three possible cases for the eigenvalue k: k = b 2 > 0 X(x) = c1 cosh bx + c 2 sinh bx, X(0) = X(L) = 0 = c1 = c 2 = 0 trivial solution k = 0 X(x) = c1 x + c 2 X(0) = X(L) = 0 = c1 = c 2 = 0 trivial solution k = β 2 < 0 X(x) = c1 cos βx + c 2 sin βx X(0) = 0 = c1 = 0 X(L) = 0 = β = βn = nπ L, n = 1, 2,... c2 is arbitrary, and set c 2 to 1.
Thus, a non-trivial solution for Eq.(4) is X(x) = X n (x) = sin nπ x, n = 1, 2,.... L By using k = β 2, solve Eq.(5) T (t), T (t) = T n (t) = b n e λ2 nt, n = 1, 2,..., where λ n = cnπ L. Combining X n (x) and T n (t), we get a solution for Eq.(1) and the solution satisfies the Boundary Conditions Eq.(2) u n (x, t) = X n (x)t n (t) = b n e λ2 n t sin nπ L x, n = 1, 2,..., (8)
Principle of Superposition Theorem If φ and ψ are solutions to a linear differential equation and satisfy a linear boundary condition, then the linear combination u = c 1 φ + c 2 ψ is also a solution and satisfies the same boundary condition. Here c 1 and c 2 are constants. Since u 1 (x, t), u 2 (x, t),... are satisfying the 1D Heat equation and the zero temperature boundary conditions. Thus, a general solution is the superposition of all these u n (x, t): u(x, t) = n=1 b n e λ2 nt sin nπ L x. (9)
Half-range Fourier Series Applying initial condition u(x, 0) = b n sin nπ x = f(x), 0 < x < L, L = b n = 2 L k=1 L 0 f(x) sin nπ x dx, n = 1, 2,... L
Summary Boundary-value problems General solution u = c 2 2 u, 0 < x < L, t > 0; t t2 u(0, t) = 0 and u(l, t) = 0, t > 0; u(x, 0) = f(x), 0 < x < L. u(x, t) = b n = 2 L n=1 L 0 b n e λ2 n t sin nπ L x, f(x) sin nπx L dx. λ n = cnπ L ;
Sumarry for Method of Separation of Variables 1. Decompose u into products of functions of one variable. 2. Decompose the PDE into a set of ODEs. 3. Identify boundary conditions and the corresponding Sturm-Liouville problems. 4. Solve the Sturm-Liouville problems and obtain the corresponding eigenvalues. 5. Apply principle of superposition to obtain the eigenfucntion expansion of a general solution. 6. Use the initial conditions to obtain generalized Fourier coefficients of the eigenfunction expansion.
Example Given that a homogeneous rod of lenght L = π is properly insulated except at both ends. Suppose that both ends of the rod are kept at a constant temperature of zero degree Celsius. Find the temperature distribution in the rod u(x, t) for t > 0 if given that the entire rod is initially at a temperature of 100 degree Celsius.
One Dimensional Wave Equation (Vibrating String) Problem: Consider a stretched string of length L with both ends fastened on the x-axis. Suppose that the string is plucked from its equilibrium position and release at time t = 0. Assuming that the amplitude of the vibration at time t 0 and position x is u(x, t). Suppose that the initial shape of the string is u(x, 0) = f(x) and the initial velocity at each point on the string is du (x, 0) = g(x). dx Find the subsequent motion of the string u(x, t) for 0 < x < L and t > 0.
Boundary-value problems 1D Wave Equation: 2 u t 2 = 2 u c2, 0 < x < L, t > 0; (10) t2 Boundary Conditions (fixed end points): u(0, t) = 0 and u(l, t) = 0, t > 0; (11) Initial Conditions (initial displacement and initial velocity): u(x, 0) = f(x) and u (x, 0) = g(x), 0 < x < L. (12) t
Separation of variables Let u(x, t) = X(x)T (t), differentiate and subsitute into Eq. 10: T c 2 T = X X = k, Which gives a set of two ODEs: Now, the boundary condition becomes X kx = 0, (13) T kc 2 T = 0. (14) u(0, t) = X(0)T (t) = 0 = X(0) = 0 t > 0, (15) u(l, t) = X(L)T (t) = 0 = X(L) = 0 t > 0.(16)
There are three possible cases for the constant k: k = b 2 > 0 (trivial solution) X(x) = c 1 cosh bx + c 2 sinh bx, X(0) = X(L) = 0 = c 1 = c 2 = 0. k = 0 (trivial solution) X(x) = c 1 x + c 2, X(0) = X(L) = 0 = c 1 = c 2 = 0. k = β 2 < 0 (non-trivial solution) X(x) = c 1 cos βx + c 2 sin βx, X(0) = 0 = c 1 = 0 X(L) = 0 = β = β n = nπ L, n = 1, 2,...
A non-trivial solution for Eq. (13) is X(x) = X n (x) = c 2 sin nπ L x, n = 1, 2,..., with c 2 is arbitrary, and let say set c 2 = 1. By using k = β 2, solve Eq. (14) and get T (t) = T n (t) = b n cos λ n t + b n sin λ n t, n = 1, 2,..., Here λ n = cnπ L. Combining X n (x) and T n (t), we get a solution for Eq. (10) and also satisfies the Boundary Conditions Eqs. (11) u n (x, t) = X n (x)t n (t) = sin nπ L (b n cos λ n t+b n sin λ n t), n = 1, 2,... (17)
Principle of Superposition Theorem If φ and ψ are solutions to a linear differential equation and satisfy a linear boundary condition, then the linear combination u = c 1 φ + c 2 ψ is also a solution and satisfies the same boundary condition. Here c 1 and c 2 are constants. Since u 1 (x, t), u 2 (x, t),... are satisfying the 1D wave equation and the fixed ends boundary conditions. Thus, a general solution is the superposition of all these u n (x, t): u(x, t) = sin nπ L (b n cos λ n t + b n sin λ n t). (18) n=1
Half-range Fourier Series Applying initial condition u(x, 0) = b n sin nπ x = f(x), 0 < x < L, L k=1 L = b n = 2 f(x) sin nπ x dx, n = 1, 2,... L 0 L Applying initial condition u t (x, 0) = λ n b n sin nπ x = g(x), 0 < x < L, L = λ n b n = 2 L k=1 L 0 g(x) sin nπ x dx, n = 1, 2,... L
Summary Boundary-value problems 2 u t 2 = c 2 2 u, 0 < x < L, t > 0; t2 u(0, t) = 0 and u(l, t) = 0, t > 0; u(x, 0) = f(x) and u (x, 0) = g(x), 0 < x < L. t General solution u(x, t) = sin nπ L (b n cos λ n t + b n sin λ n t), b n = 2 L n=1 L 0 f(x) sin nπx L dx, b n = 2 λ n L L 0 λ n = cnπ L ; g(x) sin nπx L dx.
Sumarry for Method of Separation of Variables 1. Decompose u into products of functions of one variable. 2. Decompose the PDE into a set of ODEs. 3. Identify boundary conditions and the corresponding Sturm-Liouville problems. 4. Solve the Sturm-Liouville problems and obtain the corresponding eigenvalues. 5. Apply principle of superposition to obtain the eigenfucntion expansion of a general solution. 6. Use the initial conditions to obtain generalized Fourier coefficients of the eigenfunction expansion.
Examples 1. Let say a string with length L = 1 is fixed at two ends. The initial displacement of the string is f(x) = sin mπ L x and with zero initial velocity. Find u(x, t). 2. Same as the previous example, but { 3 10 f(x) = x, 0 x 1; 3 3(1 x) 1, x 1. 10 3 3. Now, assume that the initial displacement is 0, but the the initial velocity is g(x) = x cos x, given that L = 1 and c = 1. Find u(x, t).
D Alembert s Method (Optional) Boundary-value problems 2 u t 2 = c 2 2 u, 0 < x < L, t > 0; t2 u(0, t) = 0 and u(l, t) = 0, t; u(x, 0) = f(x) and u (x, 0) = g(x), 0 < x < L. t D Alembert solution u(x, t) = 1 2 [f (x ct)+f (x+ct)]+ 1 2c x+ct x ct where f and g are odd extension of f and g. g (s) ds, (19)
Examples (Optional) 1. Let say f(x) = sin mπ x and g(x) = 0, find the solution L for the 1D wave equation. 2. Same as the previous example, but L = 1, c = 1, π g(x) = 0, and { 3 10 f(x) = x, 0 x 1; 3 3(1 x) 1, x 1. 10 3 3. Now, let say L = 1, c = 1, f(x) = 0, g(x) = x, 0 < x < 1. Find the solution.
Two Dimensional Laplace Equation Problem: Consider a rectangle slab of length a and width b, assuming that it is properly insulated from top and bottom of the surfaces. The internal temperature distribution u(x, y, t), 0 < x < a, 0 < y < b, t > 0 in the slab in now given by 2D heat equation u = t c2 2 u. The four boundaries of the slab are kept at a constant temperature of zero for x = 0, x = a and y = 0, except at y = b where the temperature is kept at u(x, b, t) = f(x). Suppose the slab are left for a very long time, and the temperature distribution no longer changing with time, i.e. u = 0. t Now, find the steady state temperature distribution u(x, y) of the slab.
Boundary-value problems 2D Laplace Equation: 2 u x + 2 u = 0, 2 y2 0 < x < a, 0 < y < b; (20) Boundary Conditions: u(0, y) = u(a, y) = 0, 0 < y < a; (21) u(x, 0) = 0 and u(x, b) = f(x), 0 < x < a; (22)
Solving Laplace Equation 1. Decompose u into products of functions of one variable. u(x, y) = X(x)Y (y). 2. Decompose the PDE into a set of ODEs. X + kx = 0; (23) Y ky = 0. (24) 3. Identify boundary conditions and the corresponding Sturm-Liouville problems. X(0) = X(a) = 0, and Y (0) = 0. The Sturm-Liouville problem is X + kx = 0, X(0) = X(a) = 0.
4 Solve the Sturm-Liouville problems and obtain the corresponding eigenvalues. Non-trivial solution is Xn (x) = sin nπ a x, n = 1, 2,.... Corresponding solution for Y is Y n (y) = A n cosh nπ a y + B n sinh nπ a y. Apply BC Y (0) = 0, thus Yn (y) = B n sinh nπ a y. 5 Apply principle of superposition to obtain the eigenfucntion expansion of a general solution. u(x, y) = X n Y n = B n sinh nπ a y sin nπ a x. n=1 n=1 6 Use the initial conditions to obtain generalized Fourier coefficients of the eigenfunction expansion. nπb sinh a B n = 2 f(x) sin nπ x dx, n = 1, 2,.... a a a
Example Find the steady-state temperature distribution u(x, y) of a 1 2 slab, with y represent distance along the direction of the longer side of the slab. Given that one longer side of the slab is kept at 50 C and the other sides are kept at zero temperature.
Review on Boundary Conditions Review on Boundary Conditions
One Dimensional Heat Equation Again Recall the heat equation in our first example With the initial condition, u t = 2 u c2, 0 < x < L, t > 0. (25) x2 And the boundary condition, u(x, 0) = f(x), 0 < x < L. (26) u(0, t) = u(l, t) = 0, t > 0. (27) Here the boundary conditions are called Homogeneous Dirichlet s Boundary Conditions.
Homogeneous (Zero Temperature) Dirichlet s Boundary Condition We already showed that the solution for the zero temperature heat equation is u(x, t) = n=1 b n e λ2 n t sin nπ L x, n = 1, 2,..., (28) where b n = 2 L L 0 f(x) sin nπ L x dx. Now, let s take a closer look at the B.C.
Boundary conditions for 1D Heat Equation Three commonly used boundary conditions are Dirichlet s B.C. (the values of u are given on boundaries) (Homogeneous B.C.) u(0, t) = u(l, t) = 0, t > 0. (Non-homogeneous B.C.) u(0, t) = T 0, u(l, t) = T 1, t > 0 and T 0, T 1 0. Neumann s B.C. (normal derivatives are given on boundaries) u u x (0, t) = x (L, t) = 0, t > 0. Robin s B.C. (αu + u n are given on boundaries) This B.C. correspond to one end insulated and one end radiating heat. u(0, t) = 0, u x (L, t) = κu(l, t), t > 0. κ is called the convection coefficient.
Homogeneous (Non-Zero Temperature) Dirichlet s Boundary Condition u t = c 2 2 u, x2 0 < x < L, t > 0; I.C. : u(x, 0) = f(x), 0 < x < L; B.C. : u(0, t) = u(l, t) = T 0, t > 0. By changing the variable w(x, t) = u(x, t) T 0, we could recovered the zero temperature boundary-value problem w = c 2 2 w, 0 < x < L, t > 0; t x2 I.C. : w(x, 0) = f(x) T 0, 0 < x < L; B.C. : w(0, t) = w(l, t) = 0, t > 0.
Steady-State Solutions The steady-state solution, or time-independent solution, is when the change of temperature distribution u s (x, t) no longer depends on time t. This usually happens when t. In the steady-state situation, u = 0, and thus the heat t equation now becomes a second order ODE d2 u = 0. dx 2 If the boundary conditions are homogeneous u(0, t) = u(l, t) = T 0, then the steady-state solution is u s (x, t) = u s (x) = T 0. If the boundary conditions are non-homogeneous u(0, t) = T 0, u(l, t) = T 1, then the steady-state solution is u s (x, t) = u s (x) = T 1 T 0 x + T L 0.
Dirichlet s (Non-homogeneous) B.C. The corresponding boundary-value problem is u = c 2 2 u, 0 < x < L, t > 0; (29) t x2 B.C.: u(0, t) = T 0, u(l, t) = T 1, t > 0; (30) I.C.: u(x, 0) = f(x), 0 < x < L. (31) The strategy to solve PDE with non-homogeneous B.C. is Find the steady-state solution u s (x) that satisfies the B.C. Convert the non-homogeneous problem to a homogeneous problem by changing the variable w(x, t) = u(x, t) u s (x).
By substituting w(x, t) = u(x, t) u s (x) into the non-homogeneous B.C. problem, we get w = c 2 2 w, 0 < x < L, t > 0; t x2 I.C.: w(x, 0) = f(x) u s (x), 0 < x < L; B.C.: w(0, t) = w(l, t) = 0, t > 0. The solution to the homogeneous BVP is w(x, t) = b n e λ2nt sin β n x, where n=1 L b n = 2 (f(x) u s (x)) sin β n x dx. L 0 Finally, the solution to the non-homogeneous problem is u(x, t) = w(x, t) + u s (x).
Example Solve the following non-homogeneous boundary-value problem: u = 4 2 u, 0 < x < π, t > 0; t x2 I.C.: u(x, 0) = 50, 0 < x < π; B.C.: u(0, t) = 0, and u(π, t) = 100, t > 0.
Neumann s Boundary Conditions The corresponding boundary-value problem is u t = 2 u c2, 0 < x < L, t > 0; (32) x2 u u B.C.: (0, t) = (L, t) = 0, t > 0; (33) x x I.C.: u(x, 0) = f(x), 0 < x < L. (34) After separated the variables: X kx = 0, X (0) = X (L) = 0; T kc 2 T = 0.
Consider the three cases for the eigenvalue k: k = b 2 > 0 = X(x) = c 1 cosh bx + c 2 sinh bx, X (0) = X (L) = 0 = c 1 = c 2 = 0 trivial solution k = 0, = X(x) = c 1 x + c 2 X (0) = X (L) = 0 = c 1 = 0, c 2 arbitrary Let choose c2 = a 0 /2 where a 0 is a constant. k = β 2 < 0, = X(x) = c 1 cos βx + c 2 sin βx X (0) = 0 = c 2 = 0 X (L) = 0 = β = β n = nπ L, n = 1, 2,... βc1 is arbitrary, and set βc 1 to 1. The corresponding solution for T is T (t) = T n (t) = a n e λ2 n t.
Combining X n (x) and T n (t), and applying the principle of superposition, we get the general solution u(x, t) = a 0 2 + a n e λ2 n t cos nπ L n=1 x, n = 1, 2,..., (35) where a 0 = 2 L a n = 2 L L 0 L 0 f(x) dx, f(x) cos nπ L x dx.
Robin s Boundary Conditions The corresponding boundary-value problem is u t = 2 u c2, 0 < x < L, t > 0; (36) x2 u B.C.: u(0, t) = 0, (L, t) = κu(l, t), t > 0;(37) x I.C.: u(x, 0) = f(x), 0 < x < L. (38) After separated the variables: X kx = 0, T kc 2 T = 0. X(0) = 0, X (L) = κx(l);
Consider the three cases for the eigenvalue k: k = b 2 > 0 = X(x) = c 1 cosh bx + c 2 sinh bx, X(0) = 0, X (L) = κx(l) = c 1 = c 2 = 0 because κ, cosh bl and sinh bl are strictly positive. k = 0, = X(x) = c 1 x + c 2 X(0) = 0, X (L) = κx(l) = c 1 = c 2 = 0 trivial solution. k = β 2 < 0, = X(x) = c 1 cos βx + c 2 sin βx X(0) = 0 = c1 = 0 X (L) = κx(l) implies β must satisfies the non-linear equation β cos βl + κ sin βl = 0, which has infinite many roots, β = β n, n = 1, 2,.... Thus, X(x) = Xn (x) sin β n x.
The corresponding solution for T is T (t) = T n (t) = c n e λ2 nt, where λ n = cβ n. Combining X n (x) and T n (t), and applying the principle of superposition, we get the general solution u(x, t) = c n e λ2nt sin β n x, n = 1, 2,..., (39) n=1 where c n = 1 L 0 sin2 β n x dx L 0 f(x) sin β n x dx.
Example Solve the following Robin s problem: u = 2 u, 0 < x < 1, t > 0; t x2 I.C.: u(x, 0) = x(1 x), 0 < x < 1; B.C.: u u (0, t) = 0, and (1, t) = u(1, t), t > 0. x x
Two Dimensional Wave Equation Boundary-value problem ( ) 2 u 2 t = u 2 c2 x + 2 u, 0 < x < L, t > 0; 2 y 2 B.C.: u(0, y, t) = u(a, y, t) = 0, for 0 y b and t > 0; B.C.: u(x, 0, t) = u(x, b, t) = 0, for 0 x a and t > 0; I.C.: u(x, y, 0) = f(x, y) and u (x, y, 0) = g(x, y). t Separation of variables: u(x, y, t) = X(x)Y (y)t (t); u(0, y, t) = u(a, y, t) = 0 = X(0) = X(a) = 0; u(x, 0, t) = u(x, b, t) = 0 = Y (0) = Y (b) = 0.
T c 2 T = X X + Y Y = k2, gives T + c 2 k 2 T = 0; X = Y X Y k2 = µ 2 ; X + µ 2 X = 0 and Y + ν 2 Y = 0, where ν = k 2 µ 2. In summary X + µ 2 X = 0, X(0) = 0, X(a) = 0, Y + ν 2 Y = 0, Y (0) = 0, Y (b) = 0, Ẍ + c 2 k 2 T = 0, k 2 = µ 2 + ν 2.
Solution of the separated equations X(x) = c1 sin µx + c 2 cos µx; Y (y) = d1 sin νy + d 2 cos νy; T (t) = e1 sin ckt + e 2 cos ckt. where ν = k 2 µ 2. From the boundary condition for X and Y we get c2 = 0, µ = µ m = mπ a, and c 1 arbitrary (set to 1). d2 = 0, ν = ν n = nπ b, and d 1 arbitrary (set to 1). Thus, X(x) = Xm (x) = sin µ m x, m = 1, 2,... ; Y (y) = Yn (x) = sin ν n y, n = 1, 2,... ; T (t) = Tmn (t) = B mn cos λ mn t + B sin λ mn t, where λ mn = c µ 2 m + νn. 2
By using the principle of superposition, the solution to the 2D wave equation is u(x, y, t) = n=1 m=1 The coefficients are given by (B mn cos λt + Bmn sin λt) sin µ m x sin ν n y. b a Bmn = 4 f(x, y) sin µ m x sin ν n y dx dy; ab 0 0 B mn = 4 b a g(x, y) sin µ m x sin ν n y dx dy; abλ mn 0 0 µm = mπ a, ν n = nπ, m, n = 1, 2,.... b (40)
Two Dimensional Heat Equation Boundary-value problem u ( ) 2 t = u c2 x + 2 u, 0 < x < L, t > 0; 2 y 2 B.C.: u(0, y, t) = u(a, y, t) = 0, for 0 y b and t > 0; B.C.: u(x, 0, t) = u(x, b, t) = 0, for 0 x a and t > 0; I.C.: u(x, y, 0) = f(x, y), for 0 < x < a, 0 < y < b. General solution: u(x, y, t) = n=1 m=1 A mn sin µ m x sin ν n ye λmnt ; µ m = mπ, ν a n = nπ, λ b mn = c µ 2 m + νn; 2 A mn = 4 ab b a 0 0 f(x, y) sin µ m x sin ν n y dx dy.