0% found this document useful (0 votes)
42 views5 pages

Math 270 Week 1 Lecture

Numerical Integration and Applications 1) The Trapezoidal Rule and Simpson's Rule are introduced for numerically evaluating definite integrals using interval subdivision. 2) Examples are provided to demonstrate applying these rules to evaluate specific integrals using 4 subintervals. 3) Applications of numerical integration include finding the root-mean-square voltage in a circuit over time and determining the electric charge that passes a point in a circuit as a function of time by evaluating the integral of the current.

Uploaded by

s_castle
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
42 views5 pages

Math 270 Week 1 Lecture

Numerical Integration and Applications 1) The Trapezoidal Rule and Simpson's Rule are introduced for numerically evaluating definite integrals using interval subdivision. 2) Examples are provided to demonstrate applying these rules to evaluate specific integrals using 4 subintervals. 3) Applications of numerical integration include finding the root-mean-square voltage in a circuit over time and determining the electric charge that passes a point in a circuit as a function of time by evaluating the integral of the current.

Uploaded by

s_castle
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 5

Numerical Integration Applications

Week 1: Numerical Integration and Applications

Numerical Integration Rules

Trapezoidal Rule:
b

∫ f ( x ) dx=[ f ( a 0 )+ 2 f ( a1 ) +…+ 2 f ( an−1 ) + f ( an ) ] ∆2x where an equals


a
the endpoints of the subintervals defined by (b-a)/n.

Simpson’s Rule
b

∫ f ( x ) dx=[ y 0+ 4 y 1 +2 y 2+ 4 y 3 +2 y 4 …+2 y n−2+ 4 y n −1 + y n ] h3


a
Where an are endpoints and xn are midpoints of
subintervals defined by (b-a)/n = h

A Evaluating a definite integral using the Trapezoidal Rule


2
Example 1: Approximate the value of ∫ x √ x dx, where n = 4
0

First, find Δx.


∆x = (b-a)/n = (2-0)/4 = .5

Second, use Δx to define the n subintervals


Sub Interval 1 = [0, .5]
Sub Interval 2 = [.5, 1]
Sub Interval 3 = [1, 1.5]
Sub Interval 4 = [1.5, 2]

Third, Now that we have the subintervals, each endpoint becomes an a value.
Endpoint a0 = 0
Endpoint a1= .5
Endpoint a2 = 1
Endpoint a3 = 1.5
Endpoint a4 = 2

Fourth, plug each a value into f(x) to generate the values needed for the trapezoidal rule.
F(0) = 0
F(.5)=.3536
F(1) = 1
F(1.5)= 1.8371
F(2) = 2.8284

Finally, plug into the trapezoidal rule formula.


2

∫ x √ x dx=[0+2 ( .3536 )+ 2 ( 1 ) +2 ( 1.8371 )+ 2.8284] .52 =2.30245


0

Actual value from calculator = 2.2627416

B Evaluating a definite integral using Simpson’s Rule


3
1
Example 2: Approximate the value of ∫ dx where n = 4
1 x

First, Find h.
h= (b-a)/4 = (3-1)/4 = .5

Second, use h to define the n subintervals


Sub Interval 1 = [1, 1.5]
Sub Interval 2 = [1.5, 2]
Sub Interval 3 = [2, 2.5]
Sub Interval 4 = [2.5, 3]

Third, use each endpoint as an x value.


X0 = 1
X1 = 1.5
X2 = 2
X3 = 2.5
X4 = 3

Fourth, plug each x value into f(x) to determine the y values needed in the formula
1
y 0= =1
1
1
y 1= =.6667
1.5
1
y 2= =.5
2
1
y 3= =.4
2.5
1
y 4 = =.3333
3

Finally, plug each y value into Simpson’s rule.


3

∫ 1x dx=[1+ 4 ( .6667 ) +2 ( .5 ) +4 ( .4 ) +.3333] .53 =1.100016667


1

Actual Value from calculator = 1.0986123

C Applications

Example 3: The voltage in a certain circuit is given by V  4 cos(2 t ) . A voltmeter does


not indicate the amplitude. Instead the voltmeter reads the root-mean-square (rms), the
square root of
the average value of the square of the voltage over one cycle. That is
b

  f ( x) 
2
rms  1
ba dx
a
. Find the root – mean – square value of the voltage in volts over
the interval [0.5, 4.5]

a = 0.5 and b = 4.5

4.5
Plugging into the formula we have rms =
√ 1

4.5−5 0.5
[ 4 cos ⁡(2 πt) ]
2

Now, we have to evaluate this out

4.5 4.5 4.5

rms=
4.5
√ 1

4 0.5
16 cos 2 ( 2 πt ) dt =
1
4 √ 2

∗16 ∫ cos 2 ( 2 πt ) dt = 4 ∫ cos ( 2 πt ) dt = 2
0.5 0.5

√∫ 0.5
cos 2 (2 πt ) dt

1+cos (4 πt)
cos 2 ( 2 πt )=
2

4.5

rms=2

-
√ ∫
.5
1+cos ⁡(4 πt)
2
4.5 1 1 1
1+ cos ⁡(4 πt) t+ sin ⁡( 4 πt) 4.5+ sin ⁡(4 π 4.5) .5+ sin ⁡(4 π .5)
∫ = 4π 4.5 = 4π - 4π =
2 ¿.5
.5 2 2 2
1 1 1 1
4.5+ sin ⁡(18 π) .5+ sin ⁡(2 π ) 4.5+ (0) .5+ (0) 4.5 .5 4
4π - 4π = 4π - 4π = - = =2
2 2 2
2 2 2 2

rms=2 √ 2=2.828 Volts

Example 4: The current i (in A) in an electric circuit as a function of time t (in s) is


given by i=4 t 2+7 . Find an expression for the electric charge q (in C) that passes a point
in the circuit as a function of t. If q = 0 C when t = 0 s, determine the total charge that
passes the point in 2.0 s.

q=∫ i dt

2
So, q=∫ 4 t +7 dt

4
q= t 3+7 t +C
3

We know that q(0) = 0

4
0= 03 +7( 0)+C
3
0=C

4
q= t 3+7 t
3

Finally, we can determine the total charge at t= 2 s by plugging 2 into the q function.

4
q ( 2 ) = ( 2 )3 +7 ( 2 ) =24.667
3

Example 5: The Voltage across a 5.0-µF capacitor is zero. What is the Voltage after
20ms if a current of 75mA charges the capacitor?

Since the current is 75mA we know that i = 0.075 A = 7.5 X 10-2 A

Also, 5.0-µF = 5.0 X 10-6 F

1
V c= idt
C∫
1 −2 7.5 X 10−2 4 4
V c= −6 ∫ ( 7.5 X 10 ) dt = −6 ∫
dt =1.5 X 10 ∫ dt =( 1.5 X 10 ) t+ C
5.0 X 10 5.0 X 10

We know that V(0) = 0, which means that C = 0

Note that 20ms = 20 X 10-3 s

V c ( 20 )=( 1.5 X 104 )( 20 X 10−3 )=300 V

You might also like