promotion image of download ymail app
Anonymous asked in Science & MathematicsMathematics · 1 decade ago

composite trapezoidal rule for integration.?

integration tanx from x=0 to pi/4

determine the values of n and h needed to achieve an accuracy of 10^-8.

and if n=4 how can i find the bound of error??

1 Answer

  • 1 decade ago
    Favorite Answer

    The page says the error term is 1/12*h^3*f"(t) where t is somehwere in the interval. The second derivative is 2*tan(x)*(1+tan(x)^2) which is increasing, so its max is at pi/4 where its value is 4 (worse case scenario). So error<= 1/12*h^3*4 so you make sure 1/12*h^3*4 <10^-8. Since h = (b-a)/n = (pi/4-0)/n you have 1/3* (pi/(4n))^3 <10^-8 which you solve for n> [10^8 *pi^3/(3*4^3) ] ^(1/3) = approximately 252.7 so you take 253 subdivisions. OR use a better method, like higher order Newton-Coates method (e.g., Rhomberg integration, etc.)

    Second part, plug in 4 into above error term : 1/12 *{(pi/4 -0)/4]^3 *4 = approximately .0025

    • Commenter avatarLogin to reply the answers
Still have questions? Get your answers by asking now.