Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Newton's law of cooling says that the temperature of a body changes at a rate proportional to the difference between its temperature and that of

image text in transcribed

Newton's law of cooling says that the temperature of a body changes at a rate proportional to the difference between its temperature and that of the surrrounding medium (the ambient temperature), dT dt(T-Ta) where T is the temperature of the body (C), t is time (minutes), k is the proportionality constant (per minute), and Ta is the ambient temperature (C) (a) Modify the MATLAB function Euler in Question 1 so that it will use Eulers method to solve this differential equation. Use the function header function Euler2(k , Ta, t0 , TO , tn , n) where Ta- Ta, the initial condition TO - T(to), tn is the final value of t in the numerical solution, and n is the number of time steps. DELIVERABLES: A copy of the M-FILE in your pdf. (b) Use Euler2 to compute a numerical approximation to the above differential equation using k = 0.019/min, Ta-20C and initial condition T(0) = 68C on the tine interval 0, 12] using a step size of 0.125 minutes DELIVERABLES: The function call to Euler2 and the resulting output. (c) Use the fact the exact analytic solution of this problem is T(t) = 204-48e-0.019t to compute (either in MATLAB or using your calculator) the relative error in the computed solution at 12

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Programming Languages 12th International Symposium Dbpl 2009 Lyon France August 2009 Proceedings Lncs 5708

Authors: Philippa Gardner ,Floris Geerts

2009th Edition

3642037925, 978-3642037924

More Books

Students also viewed these Databases questions