assign12 - ASE 211 - Homework 12 Due: in class, Wednesday,...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: ASE 211 - Homework 12 Due: in class, Wednesday, May 4th. 1. Write a matlab m-file which implements the Simpson's rule. Test your code by showing that it computes the following integral exactly: 2 0 (x3 + 3x2 - 2x + 3) dx = 14. 2. Next, generalize your m-file to the composite Simpson's rule and test it on the integral 1 0 6x5 dx = 1, and show that as you double n = 2, 4, 8, the error goes to zero at a rate 4 as h is decreased (i.e., error ch4 , where c is a constant). 3. Apply the code written above to problem A11.14 in the book. Note: Hand in all scripts and results. ...
View Full Document

Ask a homework question - tutors are online