First draft of project (See pictures HERE)

Project #1 Numerical approximation of integration

Your script file will compute the numerical approximation of the area under a curve using the rectangular approximation rule (you may use the trapezoidal approximation if you want).

Run your script for 5 different values of the width of the rectangle. For each run, with a given width, your script will compute the approximate area by summing the areas of the rectangles. You can, if you prefer, have your script only run once to compute all five areas (use another for loop! that encompasses the for loop that sums the rectangular areas).

After you have run the script 5 times and obtained 5 areas, plot those resulting values (rectangle width on abscissa, area on ordinate). As width decreases, the computed area should get closer to the true area.

To test your program to make sure it is working correctly, your function should be something simple: y = 2 * x + 1. Once you know your program is correct, use the following higher order polynomial y = 3 * x^3 - 2 * x^2 - 4 * x + 1. Integrate (find area) from 0 to 100.

The plot can be in a separate script, if you wish