SlideShare a Scribd company logo
Interpolasi
Interpolasi
• Interpolasi : menaksir harga-harga diantara titik-titik data yang telah tepat
(diketahui)
• Metode yang paling sering digunakan adalah interpolasi polinomial
• Formula umum polinomial orde ke-n :
n
n x
a
x
a
x
a
a
x
f 



 
2
2
1
0
)
(
Untuk n+1 titik-titik data, terdapat satu dan hanya satu polinomial orde ke-n
atau kurang yang melewati semua titik
a) Orde pertama (linear yang menghubungkan dua titik , b) orde kedua
(kuadratik atau parabola) yang menghubungkan tiga titik c) orde ketiga
(kubik) yang menghubungkan empat titik
Interpolasi
• Meskipun terdapat satu dan hanya satu
polinomial orde ke-n yang mencocokkan n+1
titik, ada berbagai format matematika di mana
polinomial itu dinyatakan:
1. Polinomial Newton
2. Polinomial Lagrange
4
Polinomial Interpolasi
Diferensi Terbagi Newton
Interpolasi Linear
• Menghubungkan dua titik data dengan sebuah
garis lurus
f1(x) menandakan sebuah polinomial interpolasi
orde pertama.
)
(
)
(
)
(
)
(
0
1
0
1
0
0
1
x
x
x
f
x
f
x
x
x
f
x
f





Formula interpolasi
linear
kemiringan
)
(
)
(
)
(
)
(
)
( 0
0
1
0
1
0
1 x
x
x
x
x
f
x
f
x
f
x
f 




Contoh Interpolasi Linear
• Contoh:
Taksirlah ln 2 dengan menggunakan interpolasi linear. Lakukan interpolasi
antara ln 1=0 dan ln 6= 1.7917595 . Harga ln2 sebenarnya adalah 0,69314718
Solusi :
)
(
)
(
)
(
)
(
)
( 0
0
1
0
1
0
1 x
x
x
x
x
f
x
f
x
f
x
f 




35835190
.
0
)
1
2
(
1
6
0
7917595
.
1
0
)
2
(
1 





f Persen kesalahan εt=48.3%
Jika digunakan interval yang lebih kecil antara x0=1 sampai x1=4, maka :
46209813
.
0
)
1
2
(
1
4
0
3862944
.
1
0
)
2
(
1 





f Persen kesalahan εt=33.3%
Contoh Interpolasi Linear
Interval yang semakin kecil memberikan suatu taksiran yang lebih baik
7
• Jika tiga titik data tersedia, taksiran diperbaiki dengan memperkenalkan beberapa
lengkungan ke dalam garis yang menghubungkan titik-titik
Ini dapat dilakukan dengan sebuah polinomial orde kedua (polinomial kuadratik)
)
)(
(
)
(
)
( 1
0
2
0
1
0
2 x
x
x
x
b
x
x
b
b
x
f 





)
( 0
0
0 x
f
b
x
x 

Orde kedua
Interpolasi Kuadratik
)
(
)
(
0
1
0
1
1
1
x
x
x
f
x
f
b
x
x




0
2
0
1
0
1
1
2
1
2
2
2
x
x
x
x
x
f
x
f
x
x
x
f
x
f
b
x
x








)
(
)
(
)
(
)
(
)
)(
(
)
(
)
( 1
0
2
0
1
0 x
x
x
x
b
x
x
b
b
x
f 





)
)(
(
)
(
)
(
)
(
)
(
)
(
)
)(
(
)
(
)
(
)
(
)
(
)
(
)
(
1
2
0
2
0
2
0
1
0
1
0
2
2
1
2
0
2
0
2
1
0
2
2
2
0
1
0
1
1
0
0
x
x
x
x
x
x
x
x
x
f
x
f
x
f
x
f
b
x
x
x
x
x
x
b
x
f
x
f
b
x
x
x
x
x
f
x
f
b
x
f
b



















)
)(
(
)
(
)
))(
(
)
(
(
)
(
)
))(
(
)
(
(
1
2
0
2
0
1
1
2
0
1
1
2
1
2
1
2
2
x
x
x
x
x
x
x
x
x
f
x
f
x
x
x
x
x
f
x
f
b










)
(
)
(
)
(
)
(
)
(
)
(
)
(
0
2
0
1
0
1
1
2
1
2
2
x
x
x
x
x
f
x
f
x
x
x
f
x
f
b







)
)(
(
)
(
)
))(
(
)
(
(
)
))(
(
)
(
(
))
(
)
(
(
)
(
)
))(
(
)
(
(
1
2
0
2
0
1
0
1
0
1
1
2
0
1
0
1
1
2
1
2
1
2
2
x
x
x
x
x
x
x
x
x
f
x
f
x
x
x
f
x
f
x
f
x
f
x
x
x
x
x
f
x
f
b















)
)(
(
)
(
)
))(
(
)
(
(
)
(
)
))(
(
)
(
)
(
)
(
(
1
2
0
2
0
1
0
1
1
2
0
1
1
2
1
2
0
1
1
2
2
2
x
x
x
x
x
x
x
x
x
x
x
f
x
f
x
x
x
x
x
f
x
f
x
f
x
f
b
x
x















Contoh Interpolasi Kuadratik
• Taksirlah ln 2 dengan menggunakan interpolasi kuadratik.
x0=1 f(x0)= 0
x1= 4 f(x1)=1.3862944
x2= 6 f(x2)= 1.7917595
Harga ln2 sebenarnya adalah 0,69314718
Solusi:
)
( 0
0
0 x
f
b
x
x 

b0=0
)
(
)
(
0
1
0
1
1
1
x
x
x
f
x
f
b
x
x




.
b
x
x 46209813
0
1
4
0
3862944
.
1
1
1 




Contoh Interpolasi Kuadratik
0
2
0
1
0
1
1
2
1
2
2
2
x
x
x
x
x
f
x
f
x
x
x
f
x
f
b
x
x








)
(
)
(
)
(
)
(
051873116
.
0
1
6
46209813
.
0
4
6
3862944
.
1
7917595
.
1
2
2 






 b
x
x
)
)(
(
)
(
)
( 1
0
2
0
1
0
2 x
x
x
x
b
x
x
b
b
x
f 





)
4
)(
1
(
051873116
.
0
)
1
(
46209813
.
0
0
)
(
2 




 x
x
x
x
f
56584436
.
0
)
(
2 
x
f Kesalahan : εt= 18.4%
Bentuk Umum Polinomial Interpolasi Newton
)
(
)
(
]
,
[
j
i
j
i
j
i
x
x
x
f
x
f
x
x
f



Diferensi terbagi hingga
pertama
]
,
,
,
,
[
]
,
,
[
]
,
[
)
(
)
(
)
)(
(
)
)(
(
)
(
)
(
0
1
1
0
1
2
2
0
1
1
0
0
1
1
0
1
0
2
0
1
0
x
x
x
x
f
b
x
x
x
f
b
x
x
f
b
x
f
b
x
x
x
x
x
x
b
x
x
x
x
b
x
x
b
b
x
f
n
n
n
n
n
n




















]
,
[
]
,
[
]
,
,
[
k
i
k
j
j
i
k
j
i
x
x
x
x
f
x
x
f
x
x
x
f



0
0
2
1
1
1
0
1
1
x
x
x
x
x
f
x
x
x
f
x
x
x
x
f
n
n
n
n
n
n
n


 



]
,
,
,
[
]
,
,
,
[
]
,
,
,
,
[




Contoh Interpolasi Kuadratik
Contoh Polinomial Interpolasi
Diferensi Terbagi Newton
Taksirlah ln 2 menggunakan polinomial interpolasi terbagi hingga Newton orde ketiga
x0=1 f(x0)= 0
x1= 4 f(x1)=1.3862944
x2= 6 f(x2)= 1.7917595
x3= 5 f(x3)= 1.6094379
Harga ln2 sebenarnya adalah 0,69314718
Solusi:
)
2
)(
1
)(
0
(
3
)
1
)(
0
(
2
)
0
(
1
0
)
(
2 x
x
x
x
x
x
b
x
x
x
x
b
x
x
b
b
x
f 









Polinomial orde ketiga:
j
x
i
x
j
x
f
i
x
f
j
x
i
x
f



)
(
)
(
]
,
[
Diferensi terbagi pertama:
46209813
0
1
4
0
3862944
.
1
]
0
,
1
[ .
x
x
f 



20273255
0
4
6
3862944
.
1
7917595
.
1
]
1
,
2
[ .
x
x
f 



18232160
.
0
6
5
7917595
.
1
6094379
.
1
]
2
,
3
[ 




x
x
f
Contoh Polinomial Interpolasi
Diferensi Terbagi Newton
Diferensi terbagi kedua:
051873116
.
0
1
6
46209813
.
0
20273255
.
0
]
0
,
1
,
2
[ 




x
x
x
f
020410950
.
0
4
5
20273255
.
0
18232160
.
0
]
1
,
2
,
3
[ 




x
x
x
f
Diferensi terbagi ketiga:
0
]
0
,
,
2
,
1
[
]
1
,
,
1
,
[
]
0
,
1
,
,
1
,
[
x
n
x
x
n
x
n
x
f
x
n
x
n
x
f
x
x
n
x
n
x
f










0078655415
.
0
1
5
)
051873116
.
0
(
020410950
.
0
]
0
,
1
,
2
,
3
[ 





x
x
x
x
f
Untuk n=3 :
Contoh Polinomial Interpolasi
Diferensi Terbagi Newton
Hasil-hasil untuk f[x1,x0] , f[x2,x1,x0] dan f[x3,x2,x1,x0] menunjukkan koefisien b1,b2,b3.
Bersama dengan b0=f(x0) = 0, persamaan adalah :
n
x
x
x
x
x
x
n
b
x
x
x
x
b
x
x
b
b
x
n
f )
1
(
)
1
)(
0
(
)
1
)(
0
(
2
)
0
(
1
0
)
( 









 

3
f
x
x
x
x
x
x
x
f
62876869
.
0
)
2
(
)
6
)(
4
)(
1
(
0078655415
.
0
)
4
)(
1
(
051873116
.
0
)
1
(
46209813
.
0
0
)
(
3











Kesalahan relatif : εt= 9.3%
Polinomial Interpolasi Lagrange
Polinomial interpolasi Lagrange adalah formulasi kembali dari polinomial Newton
yang mencegah komputasi diferensi terbagi.
Persamaan dinyatakan sebagai:









n
i
j
j j
x
i
x
j
x
x
x
i
L
:
dimana
n
i
i
x
f
x
i
L
x
n
f
0
)
(
0
)
(
)
(
)
(
Versi linear (n-1) adalah:
)
(
)
(
)
( 1
0
1
0
0
1
0
1
1 x
f
x
x
x
x
x
f
x
x
x
x
x
f






Versi orde kedua adalah:
  
  
  
  
  
  
x
f
x
x
x
x
x
x
x
x
x
f
x
x
x
x
x
x
x
x
x
f
x
x
x
x
x
x
x
x
x
f )
2
(
1
2
0
2
1
0
)
1
(
2
1
0
1
2
0
)
0
(
2
0
1
0
2
1
)
(
2















Polinomial Interpolasi Lagrange
Taksirlah ln 2 menggunakan polinomial interpolasi Lagrange orde pertama dan kedua
x0=1 f(x0)= 0
x1= 4 f(x1)=1.3862944
x2= 6 f(x2)= 1.7917595
Solusi:
)
(
)
(
)
( 1
0
1
0
0
1
0
1
1 x
f
x
x
x
x
x
f
x
x
x
x
x
f





 4620981
.
0
3862944
.
1
1
4
1
2
0
4
1
4
2
)
(
1 






x
f
Taksiran pada x=2 adalah:
Polinomial orde kedua adalah:
  
  
  
  
  
  
x
f
x
x
x
x
x
x
x
x
x
f
x
x
x
x
x
x
x
x
x
f
x
x
x
x
x
x
x
x
x
f )
2
(
1
2
0
2
1
0
)
1
(
2
1
0
1
2
0
)
0
(
2
0
1
0
2
1
)
(
2















  
  
  
  
  
  
.
f 56584437
.
0
7917595
1
4
6
1
6
4
2
1
2
3862944
.
1
6
4
1
4
6
2
1
2
0
6
1
4
1
6
2
4
2
)
2
(
2 















18
Interpolasi Spline
• Terdapat kasus dimana fungsi
polinomial membawa hasil yang
keliru karena pembulatan dan
overshoot
• Suatu pendekatan alternatif
adalah menerapkan polinomial
orde lebih rendah terhadap
sekumpulan titik data yang
disebut fungsi spline
Gambar (a) sampai (c)
menunjukkan perubahan
mendadak mempengaruhi
osilasi dalam polinomial
interpolasi. (d) spline kubik
memberikan aproksimasi yang
lebih dapat diterima

More Related Content

Featured

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
Marius Sescu
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
Expeed Software
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
Pixeldarts
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
marketingartwork
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
Skeleton Technologies
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
Neil Kimberley
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
SpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Lily Ray
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
Rajiv Jayarajah, MAppComm, ACC
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
Christy Abraham Joy
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
Vit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
MindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
RachelPearson36
 

Featured (20)

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 

Pertemuan 12 (2).ppt

  • 2. Interpolasi • Interpolasi : menaksir harga-harga diantara titik-titik data yang telah tepat (diketahui) • Metode yang paling sering digunakan adalah interpolasi polinomial • Formula umum polinomial orde ke-n : n n x a x a x a a x f       2 2 1 0 ) ( Untuk n+1 titik-titik data, terdapat satu dan hanya satu polinomial orde ke-n atau kurang yang melewati semua titik a) Orde pertama (linear yang menghubungkan dua titik , b) orde kedua (kuadratik atau parabola) yang menghubungkan tiga titik c) orde ketiga (kubik) yang menghubungkan empat titik
  • 3. Interpolasi • Meskipun terdapat satu dan hanya satu polinomial orde ke-n yang mencocokkan n+1 titik, ada berbagai format matematika di mana polinomial itu dinyatakan: 1. Polinomial Newton 2. Polinomial Lagrange
  • 4. 4 Polinomial Interpolasi Diferensi Terbagi Newton Interpolasi Linear • Menghubungkan dua titik data dengan sebuah garis lurus f1(x) menandakan sebuah polinomial interpolasi orde pertama. ) ( ) ( ) ( ) ( 0 1 0 1 0 0 1 x x x f x f x x x f x f      Formula interpolasi linear kemiringan ) ( ) ( ) ( ) ( ) ( 0 0 1 0 1 0 1 x x x x x f x f x f x f     
  • 5. Contoh Interpolasi Linear • Contoh: Taksirlah ln 2 dengan menggunakan interpolasi linear. Lakukan interpolasi antara ln 1=0 dan ln 6= 1.7917595 . Harga ln2 sebenarnya adalah 0,69314718 Solusi : ) ( ) ( ) ( ) ( ) ( 0 0 1 0 1 0 1 x x x x x f x f x f x f      35835190 . 0 ) 1 2 ( 1 6 0 7917595 . 1 0 ) 2 ( 1       f Persen kesalahan εt=48.3% Jika digunakan interval yang lebih kecil antara x0=1 sampai x1=4, maka : 46209813 . 0 ) 1 2 ( 1 4 0 3862944 . 1 0 ) 2 ( 1       f Persen kesalahan εt=33.3%
  • 6. Contoh Interpolasi Linear Interval yang semakin kecil memberikan suatu taksiran yang lebih baik
  • 7. 7 • Jika tiga titik data tersedia, taksiran diperbaiki dengan memperkenalkan beberapa lengkungan ke dalam garis yang menghubungkan titik-titik Ini dapat dilakukan dengan sebuah polinomial orde kedua (polinomial kuadratik) ) )( ( ) ( ) ( 1 0 2 0 1 0 2 x x x x b x x b b x f       ) ( 0 0 0 x f b x x   Orde kedua Interpolasi Kuadratik ) ( ) ( 0 1 0 1 1 1 x x x f x f b x x     0 2 0 1 0 1 1 2 1 2 2 2 x x x x x f x f x x x f x f b x x         ) ( ) ( ) ( ) (
  • 8. ) )( ( ) ( ) ( 1 0 2 0 1 0 x x x x b x x b b x f       ) )( ( ) ( ) ( ) ( ) ( ) ( ) )( ( ) ( ) ( ) ( ) ( ) ( ) ( 1 2 0 2 0 2 0 1 0 1 0 2 2 1 2 0 2 0 2 1 0 2 2 2 0 1 0 1 1 0 0 x x x x x x x x x f x f x f x f b x x x x x x b x f x f b x x x x x f x f b x f b                    ) )( ( ) ( ) ))( ( ) ( ( ) ( ) ))( ( ) ( ( 1 2 0 2 0 1 1 2 0 1 1 2 1 2 1 2 2 x x x x x x x x x f x f x x x x x f x f b           ) ( ) ( ) ( ) ( ) ( ) ( ) ( 0 2 0 1 0 1 1 2 1 2 2 x x x x x f x f x x x f x f b        ) )( ( ) ( ) ))( ( ) ( ( ) ))( ( ) ( ( )) ( ) ( ( ) ( ) ))( ( ) ( ( 1 2 0 2 0 1 0 1 0 1 1 2 0 1 0 1 1 2 1 2 1 2 2 x x x x x x x x x f x f x x x f x f x f x f x x x x x f x f b                ) )( ( ) ( ) ))( ( ) ( ( ) ( ) ))( ( ) ( ) ( ) ( ( 1 2 0 2 0 1 0 1 1 2 0 1 1 2 1 2 0 1 1 2 2 2 x x x x x x x x x x x f x f x x x x x f x f x f x f b x x               
  • 9. Contoh Interpolasi Kuadratik • Taksirlah ln 2 dengan menggunakan interpolasi kuadratik. x0=1 f(x0)= 0 x1= 4 f(x1)=1.3862944 x2= 6 f(x2)= 1.7917595 Harga ln2 sebenarnya adalah 0,69314718 Solusi: ) ( 0 0 0 x f b x x   b0=0 ) ( ) ( 0 1 0 1 1 1 x x x f x f b x x     . b x x 46209813 0 1 4 0 3862944 . 1 1 1     
  • 10. Contoh Interpolasi Kuadratik 0 2 0 1 0 1 1 2 1 2 2 2 x x x x x f x f x x x f x f b x x         ) ( ) ( ) ( ) ( 051873116 . 0 1 6 46209813 . 0 4 6 3862944 . 1 7917595 . 1 2 2         b x x ) )( ( ) ( ) ( 1 0 2 0 1 0 2 x x x x b x x b b x f       ) 4 )( 1 ( 051873116 . 0 ) 1 ( 46209813 . 0 0 ) ( 2       x x x x f 56584436 . 0 ) ( 2  x f Kesalahan : εt= 18.4%
  • 11. Bentuk Umum Polinomial Interpolasi Newton ) ( ) ( ] , [ j i j i j i x x x f x f x x f    Diferensi terbagi hingga pertama ] , , , , [ ] , , [ ] , [ ) ( ) ( ) )( ( ) )( ( ) ( ) ( 0 1 1 0 1 2 2 0 1 1 0 0 1 1 0 1 0 2 0 1 0 x x x x f b x x x f b x x f b x f b x x x x x x b x x x x b x x b b x f n n n n n n                     ] , [ ] , [ ] , , [ k i k j j i k j i x x x x f x x f x x x f    0 0 2 1 1 1 0 1 1 x x x x x f x x x f x x x x f n n n n n n n        ] , , , [ ] , , , [ ] , , , , [    
  • 13. Contoh Polinomial Interpolasi Diferensi Terbagi Newton Taksirlah ln 2 menggunakan polinomial interpolasi terbagi hingga Newton orde ketiga x0=1 f(x0)= 0 x1= 4 f(x1)=1.3862944 x2= 6 f(x2)= 1.7917595 x3= 5 f(x3)= 1.6094379 Harga ln2 sebenarnya adalah 0,69314718 Solusi: ) 2 )( 1 )( 0 ( 3 ) 1 )( 0 ( 2 ) 0 ( 1 0 ) ( 2 x x x x x x b x x x x b x x b b x f           Polinomial orde ketiga: j x i x j x f i x f j x i x f    ) ( ) ( ] , [ Diferensi terbagi pertama: 46209813 0 1 4 0 3862944 . 1 ] 0 , 1 [ . x x f     20273255 0 4 6 3862944 . 1 7917595 . 1 ] 1 , 2 [ . x x f     18232160 . 0 6 5 7917595 . 1 6094379 . 1 ] 2 , 3 [      x x f
  • 14. Contoh Polinomial Interpolasi Diferensi Terbagi Newton Diferensi terbagi kedua: 051873116 . 0 1 6 46209813 . 0 20273255 . 0 ] 0 , 1 , 2 [      x x x f 020410950 . 0 4 5 20273255 . 0 18232160 . 0 ] 1 , 2 , 3 [      x x x f Diferensi terbagi ketiga: 0 ] 0 , , 2 , 1 [ ] 1 , , 1 , [ ] 0 , 1 , , 1 , [ x n x x n x n x f x n x n x f x x n x n x f           0078655415 . 0 1 5 ) 051873116 . 0 ( 020410950 . 0 ] 0 , 1 , 2 , 3 [       x x x x f Untuk n=3 :
  • 15. Contoh Polinomial Interpolasi Diferensi Terbagi Newton Hasil-hasil untuk f[x1,x0] , f[x2,x1,x0] dan f[x3,x2,x1,x0] menunjukkan koefisien b1,b2,b3. Bersama dengan b0=f(x0) = 0, persamaan adalah : n x x x x x x n b x x x x b x x b b x n f ) 1 ( ) 1 )( 0 ( ) 1 )( 0 ( 2 ) 0 ( 1 0 ) (              3 f x x x x x x x f 62876869 . 0 ) 2 ( ) 6 )( 4 )( 1 ( 0078655415 . 0 ) 4 )( 1 ( 051873116 . 0 ) 1 ( 46209813 . 0 0 ) ( 3            Kesalahan relatif : εt= 9.3%
  • 16. Polinomial Interpolasi Lagrange Polinomial interpolasi Lagrange adalah formulasi kembali dari polinomial Newton yang mencegah komputasi diferensi terbagi. Persamaan dinyatakan sebagai:          n i j j j x i x j x x x i L : dimana n i i x f x i L x n f 0 ) ( 0 ) ( ) ( ) ( Versi linear (n-1) adalah: ) ( ) ( ) ( 1 0 1 0 0 1 0 1 1 x f x x x x x f x x x x x f       Versi orde kedua adalah:                   x f x x x x x x x x x f x x x x x x x x x f x x x x x x x x x f ) 2 ( 1 2 0 2 1 0 ) 1 ( 2 1 0 1 2 0 ) 0 ( 2 0 1 0 2 1 ) ( 2               
  • 17. Polinomial Interpolasi Lagrange Taksirlah ln 2 menggunakan polinomial interpolasi Lagrange orde pertama dan kedua x0=1 f(x0)= 0 x1= 4 f(x1)=1.3862944 x2= 6 f(x2)= 1.7917595 Solusi: ) ( ) ( ) ( 1 0 1 0 0 1 0 1 1 x f x x x x x f x x x x x f       4620981 . 0 3862944 . 1 1 4 1 2 0 4 1 4 2 ) ( 1        x f Taksiran pada x=2 adalah: Polinomial orde kedua adalah:                   x f x x x x x x x x x f x x x x x x x x x f x x x x x x x x x f ) 2 ( 1 2 0 2 1 0 ) 1 ( 2 1 0 1 2 0 ) 0 ( 2 0 1 0 2 1 ) ( 2                                  . f 56584437 . 0 7917595 1 4 6 1 6 4 2 1 2 3862944 . 1 6 4 1 4 6 2 1 2 0 6 1 4 1 6 2 4 2 ) 2 ( 2                
  • 18. 18 Interpolasi Spline • Terdapat kasus dimana fungsi polinomial membawa hasil yang keliru karena pembulatan dan overshoot • Suatu pendekatan alternatif adalah menerapkan polinomial orde lebih rendah terhadap sekumpulan titik data yang disebut fungsi spline Gambar (a) sampai (c) menunjukkan perubahan mendadak mempengaruhi osilasi dalam polinomial interpolasi. (d) spline kubik memberikan aproksimasi yang lebih dapat diterima