A, which involves summing the function values at various x values, xi = a + iAx, for i=0, 1, 2, . . ., so that nAx = b-a, x 0 = a, and x n-1 = b-Ax. Using this formula, which is known as the rectangular rule, compute the integral x x 2 0 2 =d for Ax =2, 1, 0.5, 0.1, 0.05, and 0.01.Compare the results obtained with the exact value of 8/3. Plot the numerical error versus the step size Ax. What value of Ax will you choose for such computations, on the basis of the results obtained?
Fig: 1