• Tidak ada hasil yang ditemukan

To convey some idea of how the Runge-Kutta is developed, let’s look at the derivation of the 2

N/A
N/A
Protected

Academic year: 2019

Membagikan "To convey some idea of how the Runge-Kutta is developed, let’s look at the derivation of the 2"

Copied!
27
0
0

Teks penuh

(1)
(2)

Runge-Kutta Methods

2

Runge-Kutta methods are very popular

because of their good efficiency; and are used in most computer programs for

(3)

Runge-Kutta Methods

3

To convey some idea of how the Runge-Kutta

is developed, let’s look at the derivation of

the 2nd order. Two estimates

n n 1

2

n n

1

2 1

n 1

n

,

,

k

y

h

x

hf

k

y

x

hf

k

bk

ak

y

y

(4)

Runge-Kutta Methods

4

The initial conditions are:

The Taylor series expansion

   

n2 n

2 2

n n

n 1

n

,

!

2

,

dx

y

x

y

d

h

dx

y

x

dy

h

x

y

x

y

 

x

y

f

dx

dy

,

(5)

Runge-Kutta Methods

5

From the Runge-Kutta

The definition of the function

Expand the next step

(6)

Runge-Kutta

Methods

6

From the Runge-Kutta

Compare with the Taylor series

2 2 y

n 1

n

y

a

b

hf

b

h

f

b

h

f

f

y

2

1

2

1

1

b

b

b

a

(7)

Runge-Kutta Methods

7

The Taylor series coefficients (3 equations/4 unknowns)

If you select “a” as

If you select “a” as

Note: These coefficient would result in a modified Euler or Midpoint Method

2

1

,

2

1

,

1

b

b

b

a

2

3

,

2

3

,

3

1

,

3

2

b

a

1

,

2

1

2

1

b

(8)

Runge-Kutta Method

(2

nd

Order) Example

8

Consider Exact Solution

The initial condition is: The step size is:

Use the coefficients

1

.

0

h

 

0

1

y

2

y

dx

dy

1

,

2

1

2

1

b

a

x

y

(9)

Runge-Kutta Method (2

nd

Order) Example

9

The values are

1 2

i 1

i

1 i

i 2

i i

1

2

1

,

,

k

k

y

y

k

y

h

x

hf

k

y

x

hf

k

(10)

Runge-Kutta Method

(2

nd

Order) Example

10

The values are equivalent of Modified Euler

k1 Estimate Solution k2 Exact Error

xn yn y'n hy'n y*n+1 y*' n+1 h(y*'n+1 )

(11)

Runge-Kutta Method

(2

nd

Order) Example [b]

11

The values are

(12)

Runge-Kutta Method

(2

nd

Order) Example [b]

12

The values are

k1 Estimate Solution k2 Exact Error

xn yn y'n hy'n y*n+1 y*' n+1 h(y*'n+1 ) Exact

(13)

Runge-Kutta Methods

13

The Runge-Kutta methods are higher

order approximation of the basic forward integration. These methods provide

solutions which are comparable in

accuracy to Taylor series solution in which higher order derivatives are retained.

(14)

Runge-Kutta Methods

14

Method Equations

Euler

(Error of the order h2)   

Modified Euler

(Error of the order h3)  

Heun

(Error of the order h4)  

4th order Runge Kutta

(15)

The 4th Order Runge-Kutta

15

The general form of the equations:

(16)

The 4th Order Runge-Kutta

16

This is a fourth order function that solves an initial value problems using a four step program to get an estimate of the Taylor series through the fourth

order.

This will result in a local error of O(Dh5)

(17)

4

th

-order

Runge-Kutta Method

17

xi xi + h/2 xi + h

f1

f2

f3

f4

1 2 2 2 3 4 6

1

f f

f f

f    

(18)

Runge-Kutta Method

(4

th

Order) Example

18

Consider Exact Solution

The initial condition is: The step size is:

2

x

y

dx

dy

y

2

2

x

x

2

e

x

 

0

1

y

1

.

0

(19)

The 4th Order Runge-Kutta

19

The example of a single step:

 

109499 .

0 104988

.

104988 .

(20)

Runge-Kutta Method (4th Order)

Example

20

The values for the 4th order Runge-Kutta method

x y f(x,y) k 1 f 2 k 2 f 3 k 3 f 4 k 4 Change Exact

(21)

Runge-Kutta Method (4th Order)

Example

21

The values are

equivalent to those of the exact solution. If we were to go out to x=5.

y(5) = -111.4129 (-111.4132)

The error is small

relative to the exact solution.

4th Order Runge-Kutta Method

-10 -8 -6 -4 -2 0 2 4

0 1 2 3 4

X Value

Y

V

a

lu

e

(22)

Runge-Kutta Method (4th Order)

Example

22

A comparison between the 2nd order and

the 4th order Runge-Kutta methods show a

slight difference.

Runge Kutta Comparison

-10 -8 -6 -4 -2 0 2 4

0 1 2 3 4

X Value

Y

V

a

lu

e

Exact 2nd order 4th order

Error of the Methods

0.00 2.00 4.00 6.00 8.00 10.00

0 1 2 3 4 5

X Value

A

b

s

o

lu

te

|

E

rr

o

r|

Error 2nd order method

(23)

The 4th Order Runge-Kutta

23

Higher order differential equations can be treated as if they were a set of

first-order equations. Runge-Kutta type forward integration solutions can be

(24)

The 4th Order Runge-Kutta

24

The general form of the 2nd order

equations:

(25)

25

The step sizes are:

(26)
(27)

Referensi

Dokumen terkait

Meanings of several Sanskrit words which are loaned into Thai language are shifted, but in Javanese language, the meanings are extended if compared to the Sanskrit.. For

Pokja II Unit Layanan Pengadaan Kabupaten Kaur akan mengadakan klarifikasi, negosiasi teknis dan biaya. Kolonel Syamsul Bahrun Padang Kempas – Bintuhan Acara :

Karakteristik pohon inang anggrek pada lokasi penelitian memiliki ciri fisik yang sama, yaitu memiliki kulit luar yang tebal, kasar, dan retak-retak, meskipun

Setelah proses estimasi yang dilakukan secara standar selesai, maka selanjutnya data di analisis dengan tujuan untuk menghasilkan estimasi sebaran suseptibilitas magnetik

Infeksi bakteri pada saluran kemih menyebabkan pelepasan sitokin proinflamasi seperti Interleukin-6 dan Interleukin-8 ke aliran darah sehingga menyebabkan respon pejamu pada

Fungsi audit intern ditetapkan dalanr suatu satuan usaha untuk. memerik*a dan mengeveluaai keeukupan dan

The results of logistic regression showed that there was a relationship between cigarette advertising illustrated the dangers of smoking and smoking behavior

Salah satu hak asasi anak adalah hak sipil anak yang diperlukan oleh seorang anak untuk bisa mengembangkan kemampuan dan kepribadiannya sebagai seorang individu