Math 21 Assignment #11 Problem 1 (1.5 2) Find a formal solution to the given initial-boundary value problem. = 2 u x, < x < π, t > 2 u(, t) = u(π, t) =, t > u(x, ) = x 2, < x < π Problem 2 (1.5 5) Find a formal solution to the given initial-boundary value problem. = 2 u x 2, < x < π, t > (, t) = (π, t) =, t > x x u(x, ) = e x, < x < 1 Problem 3 (1.5 8) Find a formal solution to the given initial-boundary value problem. = 2 u x, < x < π, t > 2 u(, t) =, u(π, t) = 3π, t > u(x, ) =, < x < π Problem 4 (1.5 1) Find a formal solution to the given initial-boundary value problem. = 3 2 u + x, < x < π, t > x2 u(, t) = u(π, t) =, t > u(x, ) = sin(x), < x < π Problem 5 (1.5 14) Find a formal solution to the given initial-boundary value problem. = 3 2 u + 5, < x < π, t > x2 u(, t) = u(π, t) = 1, t > u(x, ) = 1, < x < π 1
Problem 6 (1.6 2) Find a formal solution. (Ans. P [an cos (4nt) + bn sin (4nt)] sin (nx), 2 u = 16 2 u 2 x, < x < π, t > 2 u (, t) = u (π, t) =, t > u (x, ) = sin 2 x, < x < 1 (x, ) = 1 cos x, < x < π. a n = ( 8 π 1 n(n 2 4) n odd n even, bn = ( 1 πn 2 1 π(n 2 1) n odd n even. Problem 7 (1.6 8) Find a formal solution. 2 u = 2 u + xsin t, < x < π, t >. 2 x2 u (, t) = u (π, t) =, t > u (x, ) =, < x < π, (x, ) =, < x < π. (Ans. [sin t t cos t] sin x + P 2( 1) n n=2 [sin (nt) n sin t]sin (nx).) n 2 (n 2 1) Problem 8 (1.6 1) Derive a formal formula for the solution. where U 1, U 2 are constants. (Ans. u (x, t) = U 1 + 2 u = α 2 2 u 2 x, < x <, t > 2 u (, t) = U 1 u (, t) = U 2, t > a n = 2 u (x, ) = f (x), < x <, (x, ) = g (x), < x <, U2 U1 Z x + X j f (x) b n = 2 nπα» a n cos» U 1 + Z nπαt U2 U1 g (x) sin «+ b n sin nπαt ff nπx x sin dx, nπx dx. «nπx sin 2
Problem 9 (1.6 14) Consider with f (x) = x 2, g (x) =. (Ans. x 2 + α 2 t 2 ) 2 u 2 = α 2 2 u, x2 < x <, t > u (x, ) = f (x), < x < (x, ) = g (x), < x < Problem 1 (1.6 16) Same as above, but with f (x) = sin 3x, g (x) = 1. (Ans. sin (3x) cos (3αt) + t.) 3
Solution 1. (1.5 2) Using separation of variables, assume then Substituting back into the PDE we have then Consider the boundary conditions so either T(t) =, the trivial solution, or Solving the boundary value problem u(x,t) = X(x)T(t) = X(x)T (t) 2 u x 2 = X (x)t(t) X(x)T (t) = X (x)t(t) T (t) T(t) = X (x) = K, K constant X(x) { X (x) KX(x) = T (t) KT(t) = u(,t) = u(π,t) = X()T(t) = X(π)T(t) = X() = X(π) = X (x) KX(x) =, X() = X(π) = this is second order linear homogeneous equation with auxiliary equation r 2 K = We investigate three possible cases for K. Case 1: K > r = ± K, real and distinct roots. This has the general solution X(x) = c 1 e Kx + c 2 e Kx Using the boundary conditions: X() = c 1 + c 2 = c 2 = c 1 X(π) = c Kπ 1 e ( ) c 1 e Kπ = c 1 e Kπ e 2 Kπ 1 = Since K >, we must have c 1 =, which is the trivial solution. 4
Case 2: K = r =, double root. This has the general solution X(x) = c 1 + c 2 x Using the boundary conditions: This case also gives us the trivial solution. X() = c 1 = X(π) = c 2 π = c 2 = Case 3: K < r = ± Ki, complex roots. This has the general solution Using the boundary conditions: Either c 2 = (the trivial solution) or X(x) = c 1 cos( Kx) + c 2 sin( Kx) X() = c 1 = X(π) = c 2 sin( Kπ) = sin( Kπ) = Kπ = nπ K = n 2,n = 1,2,... These eigenvalues have the corresponding eigenfunctions X n (x) = c n sin(nx) Using the eigenvalues in the equation for T(t): T (t) KT(t) = T (t) + n 2 T(t) = T n (t) = a n e n2 t Putting the equations for X(x) and T(t) together and combining the constants, we have u n (x,t) = X n (x)t n (t) = b n sin(nx)e n2 t Since u n (x,t) is a solution to the PDE for any value of n, we take the infinite series u(x,t) = b n sin(nx)e n2 t From the general solution and initial condition, we have u(x, ) = b n sin(nx) = x 2 5
which means we can choose the b n s as the coefficients in the Fourier sine series for f(x) = x 2 : b n = 2 x 2 sin(nx)dx π = 2 [ n 2 x 2 cos(nx) + 2cos(nx) + 2nxsin(nx) π n 3 2 ( = (2 n 2 πn 3 π 2 )( 1) n 2 ) Thus the formal solution to the given initial-boundary value problem is u(x,t) = 2 π ] π 1 ( (2 n 2 n 3 π 2 )( 1) n 2 ) sin(nx)e n 2 t 6
Solution 2. (1.5 5) Following a similar argument as for 1.5 2, we use separation of variables and the boundary conditions to arrive at the system of ODEs: { X (x) KX(x) =, X () = X (π) = T (t) KT(t) = Consider the boundary value problem: X (x) KX(x) =, X () = X (π) = This has the auxiliary equation Again we consider three cases as above. r 2 K = Case 1: K > Using a similar argument as in 1.5 2, the only solution in this case is the trivial solution. Case 2: K = Here Using the boundary conditions: X(x) = c + c 1 x X (x) = c 1 X () = c 1 = and c is arbitrary. So here we have the nontrivial solution Case 3: K < In this case the general solution is Using the boundary conditions: Either c 1 = (trivial solution) or X(x) = c X(x) = c 1 cos( Kx) + c 2 sin( Kx) X (x) = c 1 K sin( Kx) + c2 K cos( Kx) X () = c 2 = X (π) = c 1 K sin( Kπ) = sin( Kπ) = K = n 2 These eigenvalues have the corresponding eigenfunctions X n (x) = c n cos(nx) Combining cases 2 and 3, we have the eigenvalues and eigenfunctions K = n 2 X n (x) = c n cos(nx) 7
for n =,1,2,... Returning to the equation for T(t): T (t) KT(t) = T (t) + n 2 T(t) = T n (t) = a n e n2 t Putting the equations for X(x) and T(t) together and merging the constants, we have u n (x,t) = a n cos(nx)e n2t,n =,1,2,... Taking the infinite series of these solutions, we have u(x,t) = a 2 + a n cos(nx)e n2 t From the general solution and the initial condition, we have u(x,) = a 2 + a n cos(nx) = e x which means we can choose the a n s as the coefficients in the Fourier cosine series for f(x) = e x : a = 2 π e x dx = 2 π (eπ 1) a n = 2 e x cos(nx)dx π ( e π ( 1) n ) 1 = 2 π n 2 + 1 Thus the formal solution to the given initial-boundary value problem is u(x,t) = 1 π (eπ 1) + 2 π e π ( 1) n 1 n 2 + 1 cos(nx)e n2 t 8
Solution 3. (1.5 8) We assume the solution consists of a steady-state solution v(x) and a transient solution w(x,t) so that u(x,t) = v(x) + w(x,t) where w(x,t) and its derivatives tend to zero as t. Then = w 2 u x 2 = v (x) + 2 w x 2 Substituting these back into the original PDE, we obtain the problem w = v (x) + 2 w, < x < π,t > x2 (1) v() + w(,t) =, v(π) + w(π,t) = 3π, t > (2) v(x) + w(x,) =, < x < π (3) etting t we obtain the steady-state boundary value problem v (x) =, < x < π v() =, v(π) = 3π Integrating twice, we find Using the boundary conditions, we find v(x) = c 1 x + c 2 Thus v() = c 2 = v(π) = c 1 π = 3π c 1 = 3 v(x) = 3x Substituting this back into equations (1)-(3) we have w = 2 w x 2, < x < π,t > w(,t) = w(π,t) =, t > w(x,) = 3x, < x < π Following a similar argument as in 1.5 2, we have the general solution w(x,t) = b n sin(nx)e n2 t From the general solution and the initial condition w(x,) we have w(x, ) = b n sin(nx) = 3x 9
which means we can choose the b n s as the coefficients in the Fourier sine series for g(x) = 3x: b n = 2 π = 6 n ( 1)n 3x sin(nx)dx Thus, ( 1) n w(x,t) = 6 sin(nx)e n2 t n and the solution to the initial-boundary value problem is u(x,t) = v(x) + w(x,t) = ( 1) n 3x + 6 sin(nx)e n2 t n 1
Solution 4. (1.5 1) As in question 1.5 8, assume the solution consists of a steady-state solution and a transient solution: u(x,t) = v(x) + w(x,t) where w(x,t) and its derivatives tend to zero as t. Substituting into the original PDE we have ( ) w = 3 v (x) + 2 w x 2 + x, < x < π,t > v() + w(,t) = v(π) + w(π,t) =, t > v(x) + w(x,) = sin(x), < x < π etting t, we obtain the steady-state boundary value problem Integrating twice to find v(x): v (x) = x 3 v() = v(π) = Thus v(x) = 1 18 x3 + c 1 x + c 2 Using the boundary conditions to find the constants: v() = c 2 = v(π) = 1 18 π3 + c 1 π = c 1 = π2 18 v(x) = 1 18 x3 + π2 18 x We then have the following problem for w(x,t): w = 3 2 w x 2, < x < π,t > w(,t) = w(π,t) =, t > w(x,) = sin(x) + 1 18 x3 π2 18 x, < x < π Following a similar argument as in question 1.5 2, we have the general solution w(x,t) = b n sin(nx)e 3n2 t From the general solution and the initial condition for w(x,), we have w(x, ) = b n sin(nx) = sin(x) + 1 18 x3 π2 18 x 11
which means we can choose the b n s as the coefficients in the Fourier sine series for g(x) = sin(x) + 1 18 x3 π2 18 x: b n = 2 (sin(x) + 118 ) π x3 π2 18 x sin(nx)dx = 2 ( 3π cos(nπ) + 3n 2 ) π cos(nπ) π 9n 3 (n 2 Note: this is not valid for n = 1 1) 2 = 3n 3 ( 1)n b 1 = 2 (sin(x) + 118 ) π x3 π2 18 x sin(x)dx Thus, = 1 3 w(x,t) = 1 3 sin(x)e 3t + n=2 2 3n 3 ( 1)n sin(nx)e 3n 2 t and the formal solution to the initial-boundary value problem is u(x,t) = v(x) + w(x,t) = π2 18 x 1 18 x3 + 1 3 sin(x)e 3t + 2 3 ( 1) n n=2 n 3 sin(nx)e 3n 2 t 12
Solution 5. (1.5 14) As in question 1.5 8, assume the solution consists of a steady state solution and a transient solution: u(x,t) = v(x) + w(x,t) where w(x,t) and its derivatives tend to zero as t. Substituting into the original PDE we have ( ) w = 3 v (x) + 2 w x 2 + 5, < x < π,t > (4) v() + w(,t) = v(π) + w(π,t) = 1, t > (5) v(x) + w(x,) = 1, < x < π (6) etting t we obtain the steady-state boundary value problem Integrating twice, we find v (x) = 5 3 v() = v(π) = 1 v(x) = 5 6 x2 + c 1 x + c 2 Using the boundary conditions: v() = c 2 = 1 v(π) = 5 6 π2 + c 1 π + 1 = 1 c 1 = 5 6 π Thus v(x) = 1 + 5π 6 x 5 6 x2 Substituting this back into equations (4)-(6), we have w = 3 2 w x 2, < x < π,t > w(,t) = w(/pi,t) =, t > w(x,) = 5π 6 x + 5 6 x2, < x < π Following a similar argument as in question 1.5 2, we have the general solution w(x,t) = b n sin(nx)e 3n2 t From the general solution and the initial condition for w(x,), we have w(x, ) = b n sin(nx) = 5π 6 x + 5 6 x2 13
which means we can choose the b n s as the coefficients in the Fourier since series for g(x) = 5π 6 x+ 5 6 x2 : b n = 2 π = Here, c n = when n is even, and for n odd Thus, ( 5π6 x + 56 x2 ) sin(nx)dx 1 3n 3 π (( 1)n 1) 2 c 2k+1 = 3(2k + 1) 3 π, k =,1,2,... w(x,t) = 2 3π k= 1 2 (2k + 1) 3 sin(nx)e 3n t and the formal solution to the initial-boundary value problem is u(x,t) = v(x) + w(x,t) = 1 + 5π 6 x 5 6 x2 2 3π k= 1 sin((2k + 1)x) 2 t e 3(2k+1) (2k + 1) 3 14
Solution 6. (1.6 2) We give a complete solution here, with every step included. Some steps will be omitted in the following problems. 1. Separate variables Plug in u = X (x)t (t) gives T X = 16X T = T T = 16X X. As the left is a function of t alone and the right is a function of x alone, that they are equal for all x,t means both are constants. Call it λ. We get 2. Solve the eigenvalue problem. T 16λT =, X λx =. The X equation combined with boundary conditions gives the eigenvalue problem u (,t) = = X () T (t) = = X () = ; u (π,t) = = X (π)t (t) = = X (π) =. X λx =, X () = X (π) =. Recall that an eigenvalue is a specific value of λ such that the above problem has nonzero solutions, and these nonzero solutions (clearly dependent on λ!) are the corresponding eigenfunctions. i. Write down the general solutions to the equation: The formulas for the general solutions depend on the sign of λ. λ >, λ =, λ <, X = C 1 e λx + C 2 e λx ; X = C 1 + C 2 x; X = C 1 cos λx + C 2 sin λx. ii. Check whether there are any λ s such that the corresponding solutions can satisfy the boundary conditions while being nonzero (that is at least one of C 1,C 2 is nonzero. Any λ >? X () = = C 1 + C 2 = ; X (π) = = C 1 e π λ + C 2 e π λ =. These two requirements combined = C 1 = C 2 =. So there is no positive eigenvalue. 15
Is λ = an eigenvalue? X () = = C 1 = X (π) = = C 1 + C 2 π = Combined we have C 1 = C 2 =. So is not an eigenvalue. Any λ <? Combine these two we have X () = = C 1 = ; X (π) = = C 1 cos λπ + C 2 sin λπ =. C 1 = ; C 2 sin λπ =. Now at least one of C 1,C 2 is nonzero is equivalent to for some integer n. This then becomes sin λπ = λπ = nπ λ = n 2 for integer n. Notice that 1. n and n give the same λ; 2. we are discussing the case λ <. We finally conclude that λ n = n 2, n = 1,2,3,... The corresponding X n are C 1 cos λx + C 2 sin λx with C 1 = and λ = λ n : X n = A n sinnx, n = 1,2,3,... Summary: The eigenvalues are λ n = n 2, eigenfunctions are X n = A n sinnx, and the range of n is 1,2,3,... 3. Solve for T n. Recall that T 16λT =. With the particular λ n s, we have which gives T n + 16n 2 T n = T n = D n cos (4nt) + E n sin (4nt) with D n,e n arbitrary constants and n ranging 1 to. 4. Write down u = c n X n T n : which simplifies to u (x,t) = c n A n sin(nx) [D n cos (4nt) + E n sin (4nt)] u (x,t) = [a n cos (4nt) + b n sin(4nt)] sin (nx). 16
5. Determine a n,b n through initial conditions. The above formula gives u (x,) = a n sin(nx) and (x,) = 4nb n sin (nx). Comparing with initial conditions we have u (x,) = sin 2 x, sin 2 x = 1 cos x = (x,) = 1 cos x, a n sin(nx) 4nb n sin (nx). In other words a n and 4nb n are coefficients for the Fourier Sine expansion of sin 2 x and 1 cos x, respectively. Fourier Sine expansion of sin 2 x. We have = π. So We evaluate the two integrals. a n = 2 sin 2 xsin (nx) dx π = 2 1 cos 2x sin (nx) dx π 2 = 1 [ ] sin nxdx cos 2xsin (nx) dx. π sin nxdx = 1 n cos nx π = 1 [cos (nπ) 1] n = 1 ( 1)n n { n even = 2 n n odd. 17
sin[(n + 2)x] + sin [(n 2) x] cos 2xsin (nx) dx = dx 2 = 1 [ ] cos (n + 2)x cos (n 2) x π + 2 n + 2 n 2 [ ] = 1 ( 1) n+2 1 + ( 1)n 2 1 2 n + 2 n 2 = 1 [ ( 1) n ] 1 + ( 1)n 1 2 n + 2 n 2 = 1 ( 1)n 2n 2 n 2 4 = [1 ( 1)n ]n n 2 4 { n even = 2n n 2 4 n odd. Note that, the above calculation is only correct when n 2, as when n = 2 dividing by n 2 becomes meaningless. However checking the n = 2 case separately, we see that the result is so the above is in fact true for all n. Thus we have a n = { 8 π 1 n(n 2 4) Fourier Sine expansion of 1 cos x. We have n odd n even. We have 4nb n = 2 π = 2 π (1 cos x) sin(nx) dx sin(nx) dx 2 π { n even sinnxdx = 2 n n odd. cos xsin (nx) dx. 18
and cos xsin (nx) dx = 1 [sin (n + 1)x + sin(n 1) x]dx 2 = 1 [ ] cos (n + 1)x cos (n 1) x π + 2 n + 1 n 1 [ ] = 1 ( 1) n+1 1 + ( 1)n 1 1 2 n + 1 n 1 (1 ( 1) n 1) 2n = 2 n 2 1 ( = 1 ( 1) n 1) n n 2 1 { n odd = 2n n 2 1 n even. Again we need to discuss the n = 1 case separately. In the case so the general formula still holds. Thus we have cos xsin(nx) dx = b n = { 1 πn 2 1 cos xsin x = n odd π(n 2 1) n even. 19
Solution 7. (1.6 8) 1. Separate variables. Writing u = X (x)t (t) and plug into equation, neglecting xsint for now: T λt = ; X λx =. 2. Solve eigenvalue problem. The eigenvalue problem is X λx =, X () = X (π) = which leads to λ n = n 2 ; X n = A n sin(nx) ; n = 1,2,3,... 3. Write down u: u (x,t) = c n T n sin (nx) = T n (t)sin (nx). Note that we have integrated c n into T n. 4. Apply the initial conditions and integrate the forcing: 2 u 2 = 2 u Thus we must have u (x,) = = T n () sin (nx) = = T n () = ; (x,) = = T n () sin (nx) = = T n () = ; x 2 + xsin t = T n sin (nx) = n 2 T n sin(nx) [ T n + n 2 T n ] sin(nx) = xsin t. To determine T n, we need to expand x into sin(nx) s. 5. Expand x. x = a n sin(nx) with a n = 2 π = 2 nπ = 2 nπ xsin (nx) dx = 2 nπ [π ( 1)n ] = 2( 1)n+1. n xd[cos (nx)] [cos (nx) x π +xsint. ] cos (nx) dx 2
6. Solve T n. We have [ T n + n 2 ] ( ) 2( 1) n+1 T n sin(nx) = sin t sin (nx) n which gives T n + n 2 T n = 2( 1)n+1 sint. n Together with initial conditions T n () = T n () =. First solve the homogeneous equation: T n + n 2 T n = = T n = C 1 cos (nt) + C 2 sin (nt). Next we try to find a particular solution. We use undetermined coefficients. The form of the particular solution is T p = t s [Asin t + B cos t]. Where s is the number of times sint appears in the general solution of the homogeneous problem. There are two cases: n = 1. In this case s = 1. Substitute T p = t [Asin t + B cos t] into the equation we find out A =, B = 1. So the particular solution is T p = t cos t. The general solution to the non-homogeneous problem is then Applying T () = T () = we reach So T 1 = sint t cos t. n 1. In this case s = and Substituting into equation, we have T n = C 1 cos t + C 2 sint t cos t. C 1 =, C 2 = 1. T p = Asin t + B cos t. A = 2( 1)n+1 n(n 2 1), B =. So T n = C 1 cos (nt) + C 2 sin(nt) + 2( 1)n+1 n(n 2 1) sint. 21
Applying T () = T () = we reach Thus T n = 7. Write down solution. Finally we have u (x,t) = C 1 =, C 2 = 2( 1)n n 2 (n 2 1). T n X n = T 1 X 1 + 2( 1)n n 2 (n 2 [sin (nt) nsin t]. 1) T n X n n=2 = [sint t cos t] sinx 2( 1) n + n 2 (n 2 [sin (nt) nsin t] sin(nx). 1) n=2 22
Solution 8. (1.6 1) 1. Take care of the boundary conditions. We need to find an appropriate function w such that it satisfies both the equation and the boundary conditions, and then set v = u w. The boundary conditions for v would be v (,t) = v (,t) = and separation of variables can then be applied. The first try is usually w = w (x) independent of t. Then w must satisfy Such w exists. We have = α 2 w, w () = U 1,w () = U 2. w (x) = U 1 + U 2 U 1 x. 2. Now set v = u w. This gives u = v + w and the equation becomes the boundary conditions are 2 (v + w) 2 = α 2 2 (v + w) x 2 2 v 2 = α2 2 v x 2, v (,t) = v (,t) =, and the initial condition becomes [ v (x,) = f (x) w = f (x) U 1 + U ] 2 U 1 x, So we need to solve v w (x,) = g (x) (x,) = g (x). 2 v 2 = α 2 2 v x 2 v (,t) = v (,t) =, [ v (x,) = f (x) U 1 + U ] 2 U 1 x v (x,) = g (x). 3. Solve v. The solution is given by [ ( ) nπαt v (x,t) = a n cos + b n sin with a n = 2 { [ f (x) b n = 2 nπα U 1 + U 2 U 1 g (x) sin ( nπαt ]} x sin ( nπx ) dx. )] ( nπx ) sin ( nπx ) dx, 23
4. Write down u. Recalling u = v + w we have u (x,t) = U 1 + U 2 U 1 x + [ a n cos ( nπαt ) + b n sin ( nπαt )] ( nπx ) sin with a n = 2 { [ f (x) b n = 2 nπα U 1 + U 2 U 1 g (x) sin ]} x sin ( nπx ) dx. ( nπx ) dx, 24
Solution 9. (1.6 14) As < x < we need to apply d Alembert formula: u (x,t) = Substituting f = x 2,g = we have f (x αt) + f (x + αt) 2 + 1 2α x+αt x αt u (x,t) = (x αt)2 + (x + αt) 2 2 = x 2 + α 2 t 2. g (y)dy. 25
Solution 1. (1.6 16) As f = sin 3x, g = 1 we have u (x,t) = sin[3(x αt)] + sin[3(x + αt)] 2 = sin(3x) cos (3αt) + t. + 1 2α x+αt x αt 1dx 26