1 of 17

Mata Kuliah : Metode Numerik�Minggu ke 14

2 of 17

Mahasiswa dapat melakukan komputasi integrasi numerik dengan metode Trapezoidal, Simpson 1/3

Tujuan perkuliahan

3 of 17

  •  

Defferentiation and Integration

4 of 17

Type of Function

  • Discrete�Forward Difference, Direct Fit Polynomial, Lagrange Method
  • Continues�Forward Difference, Backward Difference, Central Difference, and Higher order from Taylor series.�

5 of 17

Example

  • Discrete

The upward velocity of a rocket is given as a function of time in Table 1.

Using forward divided difference, find the acceleration of the rocket at .

t

v(t)

s

m/s

0

0

10

227.04

15

362.78

20

517.35

22.5

602.97

30

901.67

Table 1 Velocity as a function of time

6 of 17

Example

t

v(t)

s

m/s

0

0

10

227.04

15

362.78

20

517.35

22.5

602.97

30

901.67

 

7 of 17

Example

  • Continuous

The velocity of a rocket is given by

where

is given in m/s and

is given in seconds.

  1. Use forward difference approximation of the first derivative of to calculate the acceleration at . Use a step size of .

8 of 17

Example

 

Hence

9 of 17

Integration

10 of 17

Trapezoidal Rule

11 of 17

Example

The vertical distance covered by a rocket from t=8 to t=30 seconds is given by:

  1. Use single segment Trapezoidal rule to find the distance covered.
  2. Find the true error, for part (a).
  3. Find the absolute relative true error, for part (a).

12 of 17

Example

a)

13 of 17

Example

b)

The exact value of the above integral is

c)

The absolute relative true error,

, would be

14 of 17

Example�(How about Double Segment?)

15 of 17

Multiple Segment (visualization)

Divide into equal segments as shown in Figure 4. Then the width of each segment is:

The integral I is:

16 of 17

Comparation

Table 1 gives the values obtained using multiple segment Trapezoidal rule for

n

Value

Et

1

11868

-807

7.296

---

2

11266

-205

1.853

5.343

3

11153

-91.4

0.8265

1.019

4

11113

-51.5

0.4655

0.3594

5

11094

-33.0

0.2981

0.1669

6

11084

-22.9

0.2070

0.09082

7

11078

-16.8

0.1521

0.05482

8

11074

-12.9

0.1165

0.03560

Table 1: Multiple Segment Trapezoidal Rule Values

Exact Value=11061 m

17 of 17

THANK YOU

FOR YOUR ATTENTION