In this example we would like to compute PI using the following integration:
Consider the figure below. To do the integration, we'll divide the domain [0,1] into intervals, compute the integral at the mid point of each interval, then multiply those values by the width of each rectangle and finally add up the areas of the all the rectangles to get an approximate value of PI.
| Previous: Data Decomposition | Up: Table of Contents | Next: Computing PI - Serial Code |
|---|