Trapezoidal Rule for Integration

07.02
Trapezoidal Rule for Integration-More Examples
Chemical Engineering
Example 1
In an attempt to understand the mechanism of the depolarization process in a fuel cell, an
electro-kinetic model for mixed oxygen-methanol current on platinum was developed in the
laboratory at FAMU. A very simplified model of the reaction developed suggests a
functional relation in an integral form. To find the time required for 50% of the oxygen to be
consumed, the time, T s  is given by
 6.73x  4.3025  10 7

1.2210 6 
2.316  10 11 x

T  
0.6110 6

dx

a) Use single segment Trapezoidal rule to find the time required for 50% of the oxygen
to be consumed.
b) Find the true error, E t , for part (a).
c) Find the absolute relative true error, t , for part (a).
Solution
a)
 f a   f b 
I  b  a 
 , where
2

a  1.22  10 6
b  0.61  10 6
 6.73x  4.3025  10 7 
f ( x)   

2.316  10 11 x



f 1.22  10
6







 6.73 1.22  10 6  4.3025  10 7 
11
 
  3.0581  10
11
6
2.316  10 1.22  10



 6.73 0.61  10 6  4.3025  10 7 
11
f 0.61  10  
  3.2104  10
11
6
2.316  10 0.61  10


11
  3.0582  10   3.2104  1011 
I  0.61  10 6  1.22  10 6 

2



6


 1.9119  10 5 s
07.02.1




07.02.2
Chapter 07.02
b) The exact value of the above integral is,
7
0.6110 6 6.73x  4.3025  10

T  
1.2210 6 
2.316  10 11 x


dx

 1.9014  10 5 s
so the true error is
Et  True Value  Approximate Value
 1.9014  10 5  1.9119  10 5
 1056.2
c) The absolute relative true error, t , would then be
True Error
 100
True Value
 1056.2

 100
1.9014  10 5
 0.55549 %
t 
Example 2
In an attempt to understand the mechanism of the depolarization process in a fuel cell, an
electro-kinetic model for mixed oxygen-methanol current on platinum was developed in the
laboratory at FAMU. A very simplified model of the reaction developed suggests a
functional relation in an integral form. To find the time required for 50% of the oxygen to be
consumed, the time, T s  is given by
 6.73x  4.3025  10 7

1.2210 6 
2.316  10 11 x

T  
0.6110 6

dx

a) Use two- segment Trapezoidal rule to find the time required for 50% of the oxygen to
be consumed.
b) Find the true error, E t , for part (a).
c) Find the absolute relative true error, t , for part (a).
Solution
a)

ba
 n1

f
(
a
)

2
 f (a  ih )  f (b)

2n 
 i 1


n2
a  1.22  10 6
b  0.61  10 6
 6.73x  4.3025  10 7 
f ( x)   

2.316  10 11 x


I
Trapezoidal Rule-More Examples: Chemical Engineering
ba
n
0.61  10 6  1.22  10 6

2
 0.30500  10 6
f x0   f 1.22  10 6 
07.02.3
h



 6.73 1.22  10 6  4.3025  10 7 
11
f 1.22  10  
  3.0581  10
11
6
2.316  10 1.22  10


6
6
f x1   f 1.22  10  0.30500  10 
 f 0.91500  10 6 

6





 6.73 0.915  10 6  4.3025  10 7 
11
f 0.91500  
  3.1089  10
11
6
2.316  10 0.915  10


6
f x 2   f x n   f 0.61  10 




 6.73 0.61  10 6  4.3025  10 7 
11
f 0.61  10 6  
  3.2104  10
11
6
2.316  10 0.61  10


0.61  10 6  1.22  10 6 
 21

6
6 
I
f
1
.
22

10

2
 f a  ih   f 0.61  10 

22
 i 1



6
 0.61  10

f 1.22  10 6   2 f 0.915  10 6   f 0.61  10 6 
4
 0.61  10 6

 3.0581  1011  2 3.1089  1011   3.2104  1011
4
 1.9042  10 5 s
b) The exact value of the above integral is,
7
0.6110 6 6.73x  4.3025  10


dx
T  
6 

11
1.2210
2.316  10 x









 1.90140  10 5 s
so the true error is
Et  True Value  Approximate Value
 1.90140  10 5  1.9042  10 5
 282.12
c) The absolute relative true error, t , would then be
True Error
 100
True Value
 282.12

 100
1.9014  10 5
 0.14838 %
t 




07.02.4
Chapter 07.02
Table 1 Values obtained using multiple-segment Trapezoidal rule for
7
0.6110 6 6.73x  4.3025  10


dx
T  
6 
11
1.2210
2
.
316

10
x


n
Value
Et
1
2
3
4
5
6
7
8
191190
190420
190260
190210
190180
190170
190160
190150
1056.2
282.12
127.31
72.017
46.216
32.142
23.636
18.107
t %
0.55549
0.14838
0.066956
0.037877
0.024307
0.016905
0.012431
0.0095231
a %
--0.40711
0.081424
0.029079
0.013570
0.0074020
0.0044740
0.0029079