cookanna_752563_53803528_HW10 2850-1

pdf

School

Arizona State University *

*We aren’t endorsed by this school

Course

CALCULUS

Subject

Mathematics

Date

Nov 24, 2024

Type

pdf

Pages

11

Uploaded by BailiffPelican2900

Report
10.1 3 pts 10.2 2 pts 10.3 7 pts Numerical Methods HOMEWORK 10 Due April 17, before 11:59 pm Application: Finite Difference Rules 30 Go back to problem 9.4 (from your last HW) which had data for the > . . . . = 20 | height y; (m) of a pumpkin as a function of time t; (sec). S 1] . . T 10 a) Use the 3-point centered difference rule to calculate the acceleration (d?y/dt?) of the pumpkin at t = 1.5 seconds. (Compare 0 : : O this value to what you already know the acceleration due to gravity should be in m/s?.) b) Use the 4-point backward difference rule to calculate the acceleration (d%y/dt?) of the pumpkin at t = 3.0 seconds. Hint: you can find this rule in Table 8-1 (pg 318) of the textbook, or the back of your “Class 30/31” handout. c) IF you obtained and used measurements every 0.1 seconds (instead of 0.3 seconds, like in the table of data), quantify how much you’d expect the error in your acceleration calculation from part (a) to change. Time, t,' Fundamentals: Taylor Series This is the equation for the Taylor Series expansion of f(x+0), as a function of f(x) and all its derivatives at x, that will be given to you on your midterm and exam cheat-sheets: Fx0) = F() 4O () + S () + S f (04 S f ) 4 Start with that equation and use it to derive the expression for f(x; 5Ax) (i.e. f(x) evaluated five nodes to the left of x;) as a function of f(x;) and all the derivatives at x; (up to the FIFTH derivative). Application: Error Order and Precision The following is a 5-point difference scheme, over equally-spaced x;, for d3f/dx3 at x = x;: 1 f(x,) = v (/5 =6F,+12f,,=10£,+3f,,) + Error Write out Taylor Series expressions for each of the four f.3, fio, fi1, fis1 to the FIFTH derivative, like you did in 8.4, and then combine them using the given difference scheme above to ... a) Calculate the discretization error order (i.e. write the error = O(Ax?) for some integer p). b) Calculate the precision of the scheme.
10.1 Application: Finite Difference Rules 304 3 pts Go back to problem 9.4 (from your last HW) which had data for the = . . . f = 20 height y; (m) of a pumpkin as a function of time t; (sec). ) " 0 9 ! T 1 a) Use the 3-point centered difference rule to calculate the 0 03 acceleration (d?y/dt?) of the pumpkin at t = 1.5 seconds. (Compare 0 » t2 ' this value to what you already know the acceleration due to gravity 0 T2 8 ts 06 . 2 Time, t; should be in m/s?.) b) Use the 4-point backward difference rule to calculate the acceleration (d?y/dt?) of the pumpkin by 0.9 at t = 3.0 seconds. Hint: you can find this rule in Table 8-1 (pg 318) of the textbook, or the back t 12 of your “Class 30/31” handout. S c) IF you obtained and used measurements every 0.1 seconds (instead of 0.3 seconds, like in the to 1.5 table of data), quantify how much you’d expect the error in your acceleration calculation from part (a) to change. t, 18 AT Y _ te 21 a) 2 P’(,- center 7 eC t=1% © dt ta 2.4 d2Y . Ni-t -2yi tYi+l 2 to 27 T At + o (s6%) tn 3 . I Eo‘f.;):-u- RIS (At") 29.9-2(21.1) + 23.4 0.09 by | O b) 4 pt backwarols @ t=3 d¥y _ -Ni-3+Hi-2 -5Yi- +2vi dtr Atz -Na+4yq -5V + 2y o3)* s H ) -5(7.0) + 2(0) - 0.09 a2y o= - C1-18 c.) I | used Ol Instead of 03 | ‘3490 would tx‘occi- ‘e ewvor fo dnange loxs o factor & 3 The envor wood be o(3) = 1 —_— 9% Smaller
10.2 Fundamentals: Taylor Series 2pts This is the equation for the Taylor Series expansion of f(x+9), as a function of f(x) and all its derivatives at x, that will be given to you on your midterm and exam cheat-sheets: 8’ 8’ 8 f(x+6)=f(0)+f"(x)+ 7f"(x)+ ;f'"(x)+ Zf""(x)+ o Start with that equation and use it to derive the expression for f(x; 5Ax) (i.e. f(x) evaluated five nodes to the left of x;) as a function of f(x;) and all the derivatives at x; (up to the FIFTH derivative). X=Xi b=-5a% Fi-5 5 2 > Y 'F(‘(i“é} = F(\(i)— Saxf '(Xi} + QAZXL-F “(K.iS - (i;%l .F“‘(X"‘B + Q52<'>_ ‘Fm\(\(.\s _(;DA).CT)‘F.llx (X,B £ (Xi-s) - §(6) - BAXF'(Xi>+ 22 a5 )(i) - -'%5-&(5? (i) + %255' at £ (%) - ?7'_—2: axof ““‘(\(t)
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
10.3 Application: Error Order and Precision 7pts The following is a 5- point difference scheme, over equally-spaced x;, for d3f/dx3 at x = x;: f(x) = (f_3 6/, +12f,,~10f,+3f,,) + Error Write out Taylor Series expressions for each of the four f.3, fi.,, fi1, fi1 to the FIFTH derivative, like you did in 8.4, and then combine them using the given difference scheme above to ... a) Calculate the discretization error order (i.e. write the error = O(AxP) for some integer p). b) Calculate the precision of the scheme. a) Stp V0 Taylor opansion for each term (Fi-a R e |‘D‘+‘> Fia= H{-3axf l(’(.) . (5&(_)'-‘: “(x) (5AK) PR + (’.': Ax) F““Q() (5,»() po ()() - sax () ¢ EOCRUDE 90 x) ¢ B acren(e) - B aPe) 3 4 5 ‘Fl"l = 'F\ - lAX'F '(Xi) + (ZAK) .F“(x) CZA_K) F m( 3 . (ZAX) F.\\\Q(.B (’-Nf) ‘F“‘“ (xi) = [ -2.aXE ‘(Xi) —AX"F“LKu) - —Ax5F (i) « AX" P - 2= axd £ (ki) 'p‘_‘ - ‘F( _ |AXF|(}(’\5 + (IAx) F“(X) _ AK)F"‘( 3 . (l Ax) -F““(X) _ (IAX) F“‘“(X) =i - axP (X)) + zAX (i) - T AR + o AX"#‘"" (<) - n_—; Ax‘5 £ () fitl 2 3 'F\ + lAX'P(.XiB + (l%’(_) F“(Xi) + (_L‘;_EK)FN(K.‘» + (' Ax) 'F““(X) + ('Ax) 'F“‘“CX) B+ AXE (XY # 2 AU + T a®Ee(xi) + Ax"{-‘“"(x N OXF (i) 51-(,,‘0 2 : Add femS Fiy - 6Fi-2 + 12F -1 -i0F +3Fin 1Y =) +C Y1) +3( ) AKX = i(_—%) —(9(—1)+|2<~(> +3 |> -0 AxE(xi)= 1(2)- @(_—3 +|7{,_§ + 5(_,_ =0 AL (K) = | -1—1)—(0(——5 +(-¢ = 2 oo e Ax“#‘“‘(m)- (35 - b(fi Y+n(zE) ¢3 axp ()= 1 () () e ) <o) - S+or> 3: Combna D 23';;(;:@ ~GRi-a 12011 ~ 10F; +3fie ) ferror = Tacs [F(-:»,’QF}—z +[2Fi- - 106 + 3{:11-(__\"'--- 2 - 27-3 [ W‘F \\\(K.\B _ —?!_— Axg_F mu (X‘B] F - 'F“\()(]B - _‘_-tI__MZ__an(Ki> + Cor order O(AX")
b) Preusio n - a\vcn when cevor =0 pr eciSron = a®+rpxT+ex®+dxt +ex P = ot py® text+dX £ = ad +px* +ex +d P = o+ K +o F" = axX +b P = a FMt =0
HW10 (10.1 - 10.6) due Monday April 17 10.4 DERIVING difference formula for ANY order derivative to ANY error order 7 pts Use Taylor series expansions to derive a forward difference scheme, over equally-spaced points, using any or all of f;, fi.1, fi2, fi-3 and fi., that approximates d?f/dx? (2" derivative at x;) to order (Ax3) discretization error. Hint: DON’T write a Taylor Series for f.. f;is just itself (or just written as f(x;)). There’s nothing else you can do with it! Only ever create Taylor Series expansions for points other than f;. Show all your work! Write all appropriate Taylor Series out, and describe your goals what terms do you need to keep, what terms do you need to eliminate? If you follow the methodology from class, you should end up with 4 equations for 4 unknowns (i.e. coefficients g, b, ¢, d that you’re using to weight each Taylor Series). It’s fine if you then use MATLAB to solve for them you should get nice “round” fractions in your final scheme. 10.5 Fundamentals: Characterizing ODEs (Chapter 10) 6 pts For each of the following three ODEs ... i. characterize its order (e.g. 15*-order, 2"9-order, etc.), ii. characterize it as an IVP (Initial Value Problem) or BVP (Boundary Value Problem), iii. write the ODE in standard form. 2 3 (A) qer—r—q+\/%, q(2)=0, q'(0)=1 (B) y(—)=sm(x)+ S;), (—4)=1 (C) pdx(dx _ 4% x(3)=3, x'(3)=2. x"(3) =1
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
10.4 DERIVING difference formula for ANY order derivative to ANY error order 7 pts Use Taylor series expansions to derive a forward difference scheme, over equally-spaced points, using any or all of f;, fi.1, fir2, firz and fi,s that approximates d?f/dx? (2" derivative at x;) to order (Ax3) discretization error. Hint: DON’T write a Taylor Series for f,.. f;is just itself (or just written as f(x;)). There’s nothing else you can do with it! Only ever create Taylor Series expansions for points other than f;. Show all your work! Write all appropriate Taylor Series out, and describe your goals what terms do you need to keep, what terms do you need to eliminate? If you follow the methodology from class, you should end up with 4 equations for 4 unknowns (i.e. coefficients a, b, ¢, d that you're using to weight each Taylor Series). It’s fine if you then use MATLAB to solve for them you should get nice “round” fractions in your final scheme. Fri = |+ af(x) + 2O () + G adFi(a) « a5 axih(x) Bitrs | +2E(G) + 28 (i) + (5 aF (X + F A (%) Pies = 1 +3axF' (%) * T AN + 3 ORF(x) + B adp () Pird= L +YAXF()+ B A F (X)) + 5 axPE (ki) + 5 axt P () oFi+ +bfirngtCFiunrdFivy + o(A)(5} N~/ <nor P = la+2b+y o +4d =0 FU(Xi) = 20+t Fo+8d = | £ (Xi) Catab+ wC+EA =0 () = mart3orFerZd =0 Matvi 0 gt ab 2 3 4 | [a] o 7 2 5 8 b = 1 4 y a = G 3 7 3 c 0] 5 % % | [d]| |ol a= -8.661 b= 15 §i = atptetd ¢ =-4.661 Fi= -1 An? A= 04l AKL{“ (x.‘s = -846] Fiy + A6F i1~ 4061 Ry + 0.916TR+y + 2.90N3H gu(\(o = '5'5('3,%1 Firt + 16Fi2~ 4001 Fing + 0916 R+ + 2.°n'|b1=\'> +0 (AK?’)
10.5 Fundamentals: Characterizing ODEs (Chapter 10) 6 pts For each of the following three ODEs ... i. characterize its order (e.g. 1%*-order, 2"-order, etc.), ii. characterize it as an IVP (Initial Value Problem) or BVP (Boundary Value Problem), iii. write the ODE in standard form. d(x?) 2 (A) qer=r%+\/j—z, q(2)=0, q'(0)=1 (B) y(j—;)=sin(x)+ o x(—4)=1 (C) 1+d—2x(?+x)=—4%, x(3)=3, x'(3)=2, x"(3)=1 A ad =riartiar A@=0 al(e)=t 429 i) order: highest derwvatve @ g Znd ovrdevr i) 2 B0 BVP i) standard form e de _ |4 4 ~ " adr T | cir2 o*q «*) B> \I(%B =sm(x)+ % x(-4) =| i ) order: h\%hes’r denvathve, - -:r,g First ool i) 1 B.o —s VP i) standard form : a‘i\, ) = Z{\—g ¥ (3%\ = S\V\<><) + ox* §§ 2 9K oK _ g\\(\(x>+6;( o J J
o?2X [ d?X C) | + o\tl(o\t +x> = - i) order: hghest denvative : i) 3 8.0 |VP i) stondard form : X(3)=> x'@=2 x"(3)=I ot 2" Ovrden ¥ A3 -H ¢ ! -X = gt AEX
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help
HW10 (10.1 - 10.6) due Monday April 17 10.6 Application: (Single-Step, Explicit) Euler Method to Solve an IVP . . dT T 43 t 5 pts You want to solve the following 1%*-order Initial Value Problem: —+———— with the initial condition T{t = 0) = T, = 30. dt 18 45 300 Why?? Because your manufacturing floor is at an excruciating T, = 30°C (about 86 F), when you turn on the air-conditioning. What you want to determine is how long it will take to get the room temperature down to 18°C. The room has a volume V = (10m) x (20m) x (6m) = 1800 m?3, so knowing the density of air = 1.2 kg/m?3 there’s m = 2160 kg of air you need to cool. Your air-conditioner can only Q = 14400 120t provide 120 kg/min of cold air Watts of solar heat \'\ (at Ty = 10°C, about 50F). That m = 2160 kg of air, initially at T, = 30°C will mix around with the air in I___j‘> Room temp the room, so an equal amount : . e m = 120 kg/min of = T(t) of air will leave the room at . cold air at T, = 10°C - whatever the temperature of m = 120 kg/min of the room is. Let’s call that T{(t). room air leaving at T(t) That all wouldn’t be too bad, except the sun is still coming in the windows, putting in a lot of heat! It’s near the end of the day, so the amount of solar heat is dropping off with time, according to the formula Q = 14400 120t, where t is in minutes, and Q in Watts (so it will be at 0 after 2 hours). So what does all this mean? You’ll learn in a Thermodynamics class that the temperature of the room T(t) will go up and down as the thermal energy in the room goes up and down. The solar heat raises the thermal energy. The difference between the cold air in and room-temp air out lowers the thermal energy. The “energy balance” is given by the 15t order ODE mcd—T =mcT . —mcT +Q , which can be rewritten as ar = fl(TAC —T)+£ dt a m mc The “c” in the equation represents the “thermal capacity” of the air (how much heat it takes to raise the temperature of 1 kg of air by 1°C). That’s known to be 1000 J/kg°C. When I plug all the values for the problem in the equation, and convert units so I’'m working with time (t) in minutes, | get the equation | started with at the top of the page! So let’s get back to that (since, as you probably figured out by now, you didn’t really have to understand anything in this “Why??” box to solve the problem). dT T 43 ¢ (a) Use the (single-step, explicit) Euler method to solve the 15t-order IVP —— - "~ __— where T is the temperature of the room (in °C), and t is time (in dt 18 45 300 minutes). Solve the problem over the range t = [0, 40] minutes, T(0)=30 using step size At = 10 min (i.e. calculate T; att, =0, t; = 10, t, = 20, t; = 30, and t, = 40 minutes). Show all your work in table form, like we did in class, showing how you start from each (t;, T;) to get the next t;,;, “slope/”, and T,;. (b) Make a sketch of T;(t;) (i.e. draw and connect the 5 dots), and comment about what time you think (if ever!) the temperature of the room will get down to 18°C.
10.6 Application: (Single-Step, Explicit) Euler Method to Solve an IVP 5pts You want to solve the following 1%-order Initial Value Problem: d—T = —i + E L with the initial condition T(t = 0) = T, = 30. de 18 45 300 (a) Use the (single-step, explicit) Euler method to solve the 1%t-order IVP d_T = _14. fi __t , where T is the temperature of the room (in °C), and tis time (in dt 18 45 300 minutes). Solve the problem over the range t = [0, 40] minutes, T(0)=30 using step size At = 10 min (i.e. calculate T; at t, =0, t; = 10, t, = 20, t3 = 30, and t, = 40 minutes). ——— Show all your work in table form, like we did in class, showing how you start from each (t; T;) to get the next t;,;, “slope;”, and T;,;. (b) Make a sketch of T;(t;) (i.e. draw and connect the 5 dots), and comment about what time you think (if ever!) the temperature of the room will get down to 18°C. @) Euler Metnod Vit = Vit kot weene k= RN H) At=lo e L= £(rit) tiet Tin=Titkat . To > +o o £a=0 | To=30 L= "jg*us 00 [for =10 | Tor = 203 (10) B Ti= 20001 32 = s Ty 43 €. | t,= 10 |T=2@8% | K= "7g *us Taco |bih =20 | Tin = 22.99+(-0.24q4)( (0) -ng 42 _ 1o = T8 Y45 200 Ta= 19.395 = -0-394 B i |t |Ti | kR | b | Tin-Titees 9 t2=20 |20 | K= 2 +i5 g |tan=20 | 14325 +(-0.ro2e)(lo) = -0.12036 Te=8.914 3 £2=30 [Beiad |L= -y F-3% [t =HO | B2 +(-0a081) (10) = -0.205 T4 = 61404 . 3 [ Y t4=490 (T4 =l.lq04 [ = 'fils—"" t 4g - :";,, s = [b. 404 +(—o.l‘-|\l}()0) = —0-Mil To=MN.1294 - 20 1 D, 2 T temperalure i\ oey dovon o 180 T avound £ =720 Min 15 bR q b 3