7.6 9 19 #9a > f:=exp(x); f := exp(x) > exactf:=evalf(int(f,x=0..4)); exactf := 53.59815003 > left2:=evalf(value(leftsum(f,x=0..4,2))); left2 := 16.77811220 > right2:=evalf(value(rightsum(f,x=0..4,2))); right2 := 123.9744123 > trap2:=evalf(value(trapezoid(f,x=0..4,2))); trap2 := 70.37626223 > mid2:=evalf(value(middlesum(f,x=0..4,2))); mid2 := 45.60763750 > simp2:=evalf(value(simpson(f,x=0..4,4))); simp2 := 53.86384573 #9b > left4:=evalf(value(leftsum(f,x=0..4,4))); left4 := 31.19287485 > right4:=evalf(value(rightsum(f,x=0..4,4))); right4 := 84.79102488 > trap4:=evalf(value(trapezoid(f,x=0..4,4))); trap4 := 57.99194987 > mid4:=evalf(value(middlesum(f,x=0..4,4))); mid4 := 51.42835626 > simp4:=evalf(value(simpson(f,x=0..4,8))); simp4 := 53.61622078 #9c > leftImprove:=(left2-exactf)/(left4-exactf); leftImprove := 1.643364678 > rightImprove:=(right2-exactf)/(right4-exactf); rightImprove := 2.256164672 > trapImprove:=(trap2-exactf)/(trap4-exactf); trapImprove := 3.818588195 > midImprove:=(mid2-exactf)/(mid4-exactf); midImprove := 3.682613823 > simpImprove:=(simp2-exactf)/(simp4-exactf); simpImprove := 14.70308095 Left/Right should be 2, Trap/Mid should be 4, Simpson should be 16 The answers are a little off because of the rapid growth of e^x. #19a Increasing have left < mid,trap,true < right Smiling have mid < true < trap Looks like increasing and frowning. err n=3 err n=30 Left 2.205271 0.2205271 Right 1.686549 0.1686549 Trap 0.259361 0.00259361 Mid 0.121030 0.0012103 Simp 0.005767l 0.0000005767l 7.7 3 #3 int(x/(4+x^2),x=1..Large) => u = x^2+4; du = 2x dx; x=0=>u=4; x=Large=>u=Large. So 0.5 * int(1/u,u=4..Large) = limit( ln Large - ln 4 ) -> infinity as Large -> infinity so the int diverges. #10 int(1/(1+x^2),x=1..Large) = arctan(Large) - arctan(1) => pi/2-pi/4= pi/4 7.8 5 #5 x^3+1 > x^3 so 1/(x^3+1) < 1/(x^3) and since int(x^(-3),x=1..infinity) converges so does int(1/(x^3+1),x=1..infinity)