Problem

Execute batch4.m of Example to regenerate the data sets and the plot shown in Figure. Now...

Execute batch4.m of Example to regenerate the data sets and the plot shown in Figure. Now plot log10(rk4_vect) versus log10(h_vect) with the command plot(log10(h_vect),log10(rk4_vect),'ro'). The points produced by this plot command should appear to maintain a linear relationship. Use the following code to determine and plot the “line of best fit” through the these data points (type help polyfit and help polyval to get a full explanation of these commands).

Write the equation of the line of best fit in the form log10(rk4_vect) = C log10(h_vect) + B, where C and B are the slope and intercept captured from the polyfit command. Solve this last equation for rk4_vect. How closely does this last equation compare with the inequality (5.7)?

a) Perform a similar analysis on eul_vect and h_vect and compare with the inequality (5.5).

b) Perform a similar analysis on rk2_vect and h_vect and compare with the inequality (5.6).

Figure Error comparison for Euler RK2, and RK4

Step-by-Step Solution

Request Professional Solution

Request Solution!

We need at least 10 more requests to produce the solution.

0 / 10 have requested this problem solution

The more requests, the faster the answer.

Request! (Login Required)


All students who have requested the solution will be notified once they are available.
Add your Solution
Textbook Solutions and Answers Search
Solutions For Problems in Chapter 5
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT