Mata kuliah : K0624 - Metode Numerik II Tahun : 2010 Pertemuan 3 Differensiasi DIFFERENSIASI NUMERIK f x0 Limit h 0 f x0 h f ( x0 ) h f x0 h f ( x0 ) f x0 h Forward Difference Formula Bina Nusantara University 3 f x h f x f x O h h f x h f x f x O h h f x h f x f x h Forward Difference Formula h 2 h2 3 Oh f x f x 2 3! DIFFERENSIASI NUMERIK f ( x 2h) 4 f ( x h) 3 f ( x ) f ( x) h f ( x ) f ( x h) f ( x) h Backward Difference Formula Bina Nusantara University 5 Backward Difference 11 July 2017 Metode Numerik II 6 DIFFERENSIASI NUMERIK 3 f ( x ) 4 f ( x h ) f ( x 2h ) f ( x) 2h 1 f x0 f x0 h f x0 h 2h Central Difference Formula Bina Nusantara University 7 2h 3 3 2h 6 6 f x h f x h 2hf x f x f x 3! 6! f x h f x h h2 3 h5 6 f x f x f x 2h 3! 6! f x h f x h h2 3 h5 6 f x f x f x 2h 3! 6! f x h f x h f x O h2 2h 2 5 h h O h2 f 3 x f 6 x 3! 6! Misalkan f(x) = ln x dan x0 = 1.8 f 1.8 Hitung 0.1 0.5877867 0.6418539 f (1.8 h) f (1.8) h 0.5406720 0.01 0.5877867 0.5933268 0.5540100 0.001 0.5877867 0.5883421 0.5554000 h f (1.8) f (1.8 h) Nilai eksak adalah Bina Nusantara University f 1.8 0.55 5 9 Example: Bila f x xe x Hitung x f x 1.9 12.703199 2.0 14.778112 2.1 17.148957 2.2 19.855030 f 2 dengan h 0.1 Gunakan Forward Difference formula: 1 f x0 f x0 h f x0 h 1 f 2 f 2.1 f 2 0.1 1 17.148957 14.778112 0.1 23.708450 Gunakan untuk tiga titik: 1 3 f x0 4 f x0 h f x0 2h f x0 2h 1 3 f ( 2) 4 f ( 2.1) f ( 2.2) f 2 2 0 .1 1 3 14.778112 4 17.148957 0.2 19.855030 22.032310 Central difference formula: 1 f x0 h f x0 h f x0 2h 1 f ( 2.1) f (1.9) f 2 2 0 .1 1 17.148957 12.703199 0.2 22.228790 Nilai Exact f’(x) = 22.167168 Perbandingan hasil dengan h = 0.1 Nilai exact dari f 2 adalah 22.167168 Rumus f 2 Error Forward Difference 23.708450 1.541282 Tiga Titik 22.032310 0.134858 Central 22.228790 0.061622 Turunan order dua h2 2 h3 3 f x h f x hf x f x f x 22 3!3 h 2 h 3 f x h f x hf x f x f x 2 3! Dari kedua persamaan di atas diperoleh 2 4 2h 2 2h 4 f x h f x h 2 f x f x f x 2 4! 2 4 2h 2 2h 4 f x h 2 f x f x h f x f x 2 4! 2 f x h 2 f x f x h 2 h 2 4 x f x f 2 h 4! 2 f x h 2 f x f x h 2 h 4 x f 2 x f 2 h 4! f 2 f x h 2 f x f x h x h2 Contoh : Hitung f’(0.5) . h = 0.5 nilai exact forwad difference backward difference central difference 11 July 2017 Metode Numerik II 17 Contoh 11 July 2017 f(x) = e-x sin(x) f '(x) = e-x cos(x) - e-x sin(x) f '(1) = - 0.110794 , h = 0.5 f '(1) = ( f(1+0.5) – f(1-0.5))/1 = - 0.0682151 Metode Numerik II 18 TURUNAN ORDER TINGGI (1) dan (2) dijumlahkan Bina Nusantara University 19 Bina Nusantara University 20 Bina Nusantara University 21 Forward dan Backward dari order O(h2) Bina Nusantara University 22 Forward dan Backward dari order O(h2) Bina Nusantara University 23 Contoh 11 July 2017 f(x) = e-x sin(x) f '' (x) = e-x cos(x) - e-x sin(x) f '(1) = - 0.110794 , h = 0.2 f '(1) = ( f(1+0.2) – f(1-0.2))/(0.04) = - 0.10401 Metode Numerik II 24 Contoh 11 July 2017 f(x) = e-x sin(x) f '' (x) = e-x cos(x) - e-x sin(x) f '(1) = - 0.110794 , h = 0.1 f '(1) = ( f(1+0.1) – f(1-0.1))/(0.01) = - 0.110794 Metode Numerik II 25 Contoh 11 July 2017 f(x) = e-x sin(x) f '' (x) = e-x cos(x) - e-x sin(x) f '(1) = - 0.110794 , h = 0.05 f '(1) = ( f(1+0.05) – f(1-0.05))/(0.1) = - 0.11087 Metode Numerik II 26 TERIMA KASIH 27
© Copyright 2026 Paperzz