Numerical Analysis Solution
Comments
Description
NUMERICALANALYSIS (SOLVED EXERCISES) Olayinka G. Okeola Question: Determine the values of such that the b.v.p u"u 0 ; u (0) 0 ; u (1) 0 has non-trivial solution for n 5 using canomical form of solution. Solution Recall Chebyshev polynomial Tn ( x) cos(arc cos x) ; 1 x 1 n 0 To ( x) cos 0 1 n 1 T1 ( x) cos(arc cos x ) x The recursive relation generated as follows: T2 ( x) 2 x 2 1 T3 ( x ) 4 x 3 3 x T4 ( x) 8 x 4 8 x 2 1 T5 ( x ) 16 x 5 20 x 3 5 x Given condition: u (0) 0 ; u (1) 0, 0 x 1 Transforming Tn (x) , 1 x 1 into 0 x 1 x λ, γ are constants 0 (1) 1 (2) 1 2 Hence 1 1 x 2 2 Page x 2 1 2 2 x 1 To ( x) 1 T1 ( x) 2 x 1 T2 ( x) 2(2 x 1) 2 1 8 x 2 8 x 1 T3 ( x ) 4( 2 x 1) 3 3( 2 x 1) 32 x 3 48 x 2 1 T4 ( x) 8(2 x 1) 4 8(2 x 1) 2 1 128 x 4 256 x 3 160 x 2 32 x 1 T5 ( x ) 16( 2 x 1) 5 20( 2 x 1) 3 5(2 x 1) 512 x 5 1280 x 4 1120 x 3 400 x 2 50 x 1 U " U 0 2 )U 0 x 2 LU 0 ( 2 x 2 LQi ( x) x i L LQi ( x) i (i 1) x i 2 x i LQi ( x) i (i 1) LQi 2 ( x) LQi L{LQi ( x)} i (i 1) LQi 2 ( x) LQi LQi ( x) i (i 1)Qi 2 ( x) Qi Page 3 Qi ( x) LQi ( x) i(i 1)Qi 2 ( x) 1 Qi ( x) LQi ( x) i (i 1)Qi 2 ( x) 1 Qi ( x) x i i (i 1)Qi 2 ( x) 1 x i 1 Q1 ( x) x2 2 i 2 Q2 ( x ) 2 x 3 6x i 3 Q3 ( x) 2 x 4 12 24 i 4 Q4 ( x ) 2 3 x 5 20 x 3 120 x 2 3 i 5 Q5 ( x) i 0 Qo ( x) LU 0 LU n ( x) 1 ( x)Tn ( x) 2 ( x)Tn1 ( x) n 1 ( x)Tn ( x) 1 ( x)ci ( n ) x i i 0 n 1 2 ( x)Tn 1 ( x) 2 ( x)ci ( n 1) x i i 0 n n 1 LU n ( x) 1 ( x)ci x i 2 ( x)ci (n) i 0 ( n 1) xi i 0 (n) ( n 1) LU n ( x) 1 ( x)ci 2 ( x)ci Qi ( x) i0 i 0 n 1 n For U(0) = 0 n 1 n ( n) ( n 1) 0 1 ( x )c i 2 ( x )c i Qi (0) i 0 i 0 (1) For U(1) =0 n 1 n (n) ( n 1) 0 1 ( x )c i 2 ( x ) c i Qi (1) i 0 i 0 Qi (0) i 0 1 0 n 1 0 ( n 1) ci Qi (1) 2 i 0 n 1 ( n 1) i 4 c Page n (n) c i Qi (0) i n0 (n) c i Qi (1) i 0 (2) For n=5 5 5 5 5 5 5 5 5 ci Qi (0) c0 Q0 (0) c1 Q1 (0) c 2 Q2 (0) c3 Q3 (0) c 4 Q4 (0) c5 Q5 (0) i 0 1) (1) 4 1 (2) 24 (50)(0) (400) (1120)(0) (1280) (512)(0) 2 3 1 800 30720 2 3 c Q (0) c Q (0) c Q (0) c Q (0) c Q (0) c Q (0) i 0 4 i i 4 0 4 1 0 4 2 1 4 3 2 4 4 3 4 1 (2) 24 (32)(0) (160) 2 (256)(0) (128) 3 1 320 3072 2 3 2) (1) 5 5 5 5 5 5 5 5 ci Qi (1) c0 Q0 (1) c1 Q1 (1) c 2 Q2 (1) c3 Q3 (1) c 4 Q4 (1) c5 Q5 (1) i 0 3) (1) 1 2 1 6 1 12 24 1 20 120 1 (1120) (1280) (512) (50)( 1 ) (400) 2 2 2 3 2 3 1 800 92160 2 3 4 c Q (1) c Q (1) c Q (1) c Q (1) c Q (1) c Q (1) i 0 4 i i 4 0 0 4 1 1 4 2 2 4 3 3 4 4 4 1 1 1 2 1 6 1 12 24 (32) (160) 2 (256) 2 (128) 2 3 1 320 3072 2 3 4) (1) 5 A 1 320 3072 3 0 2 1 1 320 3072 2 0 3 2 Page 1 800 30720 2 3 1 800 92160 3 2 A 0 1 800 30720 1 320 3072 1 800 92160 1 320 3072 3 2 3 0 2 3 2 3 2 2 2240 456754 14745600 18874360 2 3 0 4 5 6 24 22403 4567042 14745600 188743680 0 f ( ) 24 22403 4567042 14745600 188743680 f ' ( ) 83 67202 913408 14745600 By Newton-Raphson method n 1 n n 2 3 4 5 6 7 8 9 10 f ( ) f ' ( ) 11.51573 11.06039 10.70213 10.42561 10.21848 10.07066 9.97386 9.92118 9.85577 Page 6 9.9 Problem Statement 1) Use the explicit method to solve for the temperature distribution of a long, thin rod with a length lf 10cm and the following value: k ' 0 .49 Cal /( s .cm o C ) , x 2cm . At t = 0, the temperature of the rod is zero and the boundary conditions are fixed for all times at T(0)=1000C and T(10) =500C. Note that the rod is aluminum with c 0.2174Cal /( g .o C ) and 2.7 g / cm 3 . Compute results to t =0.2 and compare those in example 24.1 2) Use the Crank-Nocolson method to solve problem 1 above for x 2.5cm . Solutions 1) Page 7 x 2cm t 0.05s t 0.2 k (0.49) 0.835cm 2 / s (2.7 0.2174) kt 2 0.010437 x Ti j 1 Ti j (Ti j 1 2Ti j Ti j 1 ) At t= 0.05s i 1, j 0 T11 T10 (T20 2T10 T00 ) 0 (0 2(0) 100) 1.0437 i 2, j 0 T21 T20 (T30 2T20 T10 ) 0 (0 2(0) 0) 0 i 3, j 0 T31 T30 (T40 2T30 T20 ) 0 (0 2(0) 0) 0 i 4, j 0 T41 T40 (T50 2T40 T30 ) 0 (50 2(0) 0) 0.52185 At t = 0.1s i 1, j 1 T12 T11 (T21 2T11 T01 ) 1.0437 (0 2( 2.0875) 100) 2.04382 i 2, j 1 T22 T21 (T31 2T21 T11 ) 0 (0 2(0) 1.0437) 0.01089 i 3, j 1 T32 T31 (T41 2T31 T21 ) 0 (0.52185 2(0) 0) 0.00544 i 4, j 1 T42 T41 (T51 2T41 T31 ) 0.52185 (50 2(0.52185) 0) 1.02191 At t = 0.15s i 1, j 2 T13 T12 (T21 2T12 T02 ) 2.04382 (0.01089 2( 2.04382) 100) 3.04497 i 2, j 2 T23 T22 (T32 2T22 T12 ) 0.01089 (0.00544 2(0.01089) 2.04382) 0.03205 i 3, j 2 T33 T32 (T42 2T32 T22 ) 0.00544 (1.02191 2(0.00544) 0.01089) 0.0161 Page T43 T42 (T52 2T42 T32 ) 1.02191 (50 2(1.02191) 0.00544 ) 1.52248 8 i 4, j 2 At t = 0.2s i 1, j 3 T14 T13 (T23 2T13 T03 ) 3.04497 (0.03205 2(3.04497) 100) 4.02544 i 2, j 3 T24 T23 (T33 2T23 T13 ) 0.03205 (0.0161 2(0.03205) 3.04497) 0.06333 i 3, j 3 T34 T33 (T43 2T33 T23 ) 0.0161 (1.52248 2(0.00161) 0.03205) 0.03198 i 4, j 3 T44 T43 (T53 2T43 T33 ) 1.52248 (50 2(1.52248 ) 0.0161) 2.01272 (2) Using Crank-Nicolson to solve the problem 1 with x 2.5cm x 2.5cm t 0.1s t 0.2s k 0.835cm 2 / s kt 2 0.01336 x First interior node 2(1 )T1l 1 T2l 1 f 0 (t l ) 2(1 )T1l T2l f 0 (t l 1 ) Last interior node Tml 11 2(1 )Tml 1 f m 1 (t l ) 2(1 )Tml 1 Tml f m 1 (t l 1 ) Inner nodes Page 9 Ti l 11 2(1 )Ti l 1 Ti l 11 Ti l1 2(1 )Ti l Ti l1 At t = 0.1s 2(1 )T11 T21 f 0 (t 0 ) 2(1 )T10 T20 f 0 (t 1 ) i 1, l 0 2.02672T11 0.01336T21 (100) 0 0 (100) (1) 2.02672T11 0.01336T21 2.672 i 4, l 0 T21 2(1 )T31 T41 T20 2(1 )T30 T40 0.01336T21 2.02672T31 0.01336T41 0 T31 2(1 )T41 f 5 (t ' ) 2(1 )T30 T 0 f 5 (t ' ) 0.01336T31 2.02672T41 1.336 (2) (3) (4) 10 i 3, l 0 0.01336T11 2.02672T21 0.01336T31 0 Page i 2, l 0 T11 2(1 )T21 T31 T10 2(1 )T20 T30 2.02672 0.01336 T11 2.672 0.01336 2.02672 0.01336 1 0 T2 0.01336 2.02672 0.01336 T31 0 0.01336 2.02672 T41 1.336 Using Gauss elimination method[1] [1] See Appendix T11 1.3183 T21 0.0087 T31 0.00428 T41 0.65917 At t = 0.2s 2(1 )T12 T22 f 0 (t 1 ) 2(1 )T11 T21 f 0 (t 2 ) i 1, l 1 2.02672T12 T22 (100) 1.97328(1.3183) (0.0087) (100) (1) 2.02672T12 0.01336T22 1.336 2.6014 0.00012 1.336 5.2733 T12 2(1 )T22 T32 T11 2(1 )T21 T31 i 2, l 1 0.01336T12 2.02672T22 0.01336T32 0.01761 0.01717 0.0006 (2) 0.01336T12 2.02672T22 0.01336T32 0.0005 T22 2(1 )T32 T42 T21 2(1 )T31 T41 i 3, l 1 0.01336T22 2.02672T32 0.01336T42 0.00012 0.0084 0.00881 (3) T32 2(1 )T42 f 5 (t ' ) 2(1 )T31 T41 f 5 (t 2 ) 0.01336T32 2.02672T42 (50) 0.01701 0.00881 (50) 1.36182 (4) Page i 4, l 1 11 0.01336T22 2.02672T32 0.01336T42 0.01713 0 0 2.02672 0.01336 T12 5.2733 0.01336 2.02672 0.01336 2 0.0005 0 T2 0.01336 2.02672 0.01336 T32 0.01713 0 0.01336 2.02672 T42 1.36182 0 0 Using Gauss elimination method[2] [2] See Appendix T11 2.60214 T21 0.02074 T31 0.50645 T41 0.67526 Appendix [1] 0 0 2.02672 0.01336 T11 2.672 0.01336 2.02672 0.01336 1 0 0 T2 0.01336 2.02672 0.01336 T31 0 0 0.01336 2.02672 T41 1.336 0 0 m21 0.01336 2.02672 which gives 0 0 2.02672 0.01336 T11 2.672 0 1 0.01761 2.02672 0.01336 0 T2 0 0.01336 2.02672 0.01336 T31 0 1 0 0.01336 2.02672 T4 1.336 0 6.59222 10 3 which gives 0 0 2.02672 0.01336 T11 2.672 0 1 0.01761 2 . 02663 0 . 01336 0 T2 0 0 2.02672 0.01336 T31 0.000116 0 0.01336 2.02672 T41 1.336 0 12 2.0266 Page m32 0.01336 m43 m32 which gives 0 0 2.02672 0.01336 T11 2.672 0 1 0.01761 2.02663 0.01336 0 T2 0 0 2.02663 0.01336 T31 0.000116 0 0 2.02663 T41 1.3359 0 Solving by back substitution give T41 1.3359 0.05917 2.02663 2.02663T31 0.01336(0.65917) 0.000116 T31 0.004288 2.02663T21 0.01336T31 0.01761 T21 0.008666 2.02663T11 0.01336T21 2.672 T11 1.3183 Appendix [2] 0 0 2.02672 0.01336 T12 5.2733 0.01336 2.02672 0.01336 2 0.0005 0 T2 0 0.01336 2.02672 0.01336 T32 0.01713 0 0 0.01336 2.02672 T42 1.36182 m21 0.01336 2.02672 which gives 2.0266 6.59222 10 3 which gives Page m32 0.01336 13 0 0 2.02672 0.01336 T12 5.2733 0 2 0.03526 2 . 02663 0 . 01336 0 T2 0 0.01336 2.02672 0.01336 T32 0.01713 0 0.01336 2.02672 T42 1.36182 0 0 0 2.02672 0.01336 T12 5.2733 0 2 0.03526 2.02663 0.01336 0 T2 0 0 2.02672 0.01336 T32 1.01736 0.01336 2.02672 T42 1.36182 0 0 m43 m32 which gives 0 0 2.02672 0.01336 T12 5.2733 0 2 0.03526 2 . 02663 0 . 01336 0 T2 0 0 2.02672 0.01336 T32 1.01736 0 0 2.02663 T42 1.36852 0 Solving by back substitution give T42 1.36852 0.67526 2.02663 2.02663T32 0.01336(0.67526) 1.01736 T32 0.50645 2.02663T22 0.01336T32 0.03526 T22 0.02074 Page 14 2.02663T12 0.01336T22 5.2733 T12 2.60214
Copyright © 2024 DOKUMEN.SITE Inc.