Trapezoidal rule 6

Evaluate
Taking 4 equal intervals (I) Trapezoidal rule 
And (ii) Simpsons 1/3 rd rule

Solution:-
h = 0.4 - 0 /4 = 0.1
Y = f(x) = cos x

X            Y 
0            1
0.1         0.99500
0.2         0.98006
0.3         0.95534
0.4         0.92106

(I) using Trapezoidal rule
Integration of y dx = h/2[(y0+ yn) + 2( y1+ y2..... + y(n-1) ]
=> 0.1/2 [ (1+ 0.92106) + 2( 0.99500+ 0.98006 + 0.95534) ]
=> 0.1/2 [ 1.92106 + 2 × 2.9304 ]
=> 0.05 [ 1.92106 + 5.8608]
=> 0.05 × 7.78186 
=> 0.389093

(II)  using Simpsons 1/3rd rule

Integration of y dx = h/3[(y0+ yn) + 4( y1+ y3 ..... + y(n-1) +2 ( y2+ y4 ..... + y(n-2)]

=> 0.1/3 [ (1+ 0.92106) + 4(0.99500+ 0.95534) + 2 × 0.98006 ]
=> 0.1/3 [ 1.92106 + 4× 1.95034 + 2× 0.98006 ]
=> 0.1/3 [ 1.92106 + 7.80136 + 1.96012] 
=> 0.1/3 × 11.68254
=> 0.389418

Comments

Popular posts from this blog

planar and non planar

ammeter and voltmeter

zener diode and working principle