#include #include // the function we want to integrate float f (float x) { return (1.0/x); } // Numerical integration using Simpson's rule float simpson (int n, float min, float max) { int i; float interval, sum, x; interval = ((max -min) /n); sum=0; for (i=1; i