double quad_serial ( double f ( double x ), double a, double b, int n );