| 1 | Compute Δx and the n + 1 points. Δx=nb−a; the points run from a to b inclusive, so there is one more point than strips. | Δx=0.25; x=0, 0.25, 0.5, 0.75, 1 |
| 2 | Evaluate f at every point. Keep four decimals; round only at the end. | 1, 0.9394, 0.7788, 0.5698, 0.3679 |
| 3 | Apply the weights. Trapezoid: 1,2,2,…,2,1. Simpson: 1,4,2,4,…,4,1 (ends 1, then alternating 4,2, finishing with 4 before the last 1). | T4=20.25[1+2(0.9394+0.7788+0.5698)+0.3679] |
| 4 | Multiply by the factor and round sensibly. 2Δx for the trapezoidal rule, 3Δx for Simpson. | T4≈0.7430; S4=30.25[1+4(0.9394)+2(0.7788)+4(0.5698)+0.3679]≈0.7469 |