{VERSION 5 0 "IBM INTEL NT" "5.0" }
{USTYLETAB {CSTYLE "Maple Input" -1 0 "Courier" 0 1 255 0 0 1 0 1 0 0 
1 0 0 0 0 1 }{CSTYLE "" -1 256 "" 0 10 0 0 0 0 1 0 0 0 0 0 0 0 0 1 }
{CSTYLE "" -1 257 "" 1 20 0 0 0 0 0 0 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 
258 "" 1 16 0 0 0 0 0 0 1 0 0 0 0 0 0 1 }{CSTYLE "" -1 259 "" 0 1 0 0 
0 0 0 2 0 0 0 0 0 0 0 1 }{CSTYLE "" -1 260 "" 0 1 0 0 0 0 1 1 0 0 0 0 
0 0 0 1 }{CSTYLE "" -1 261 "" 0 1 0 0 0 0 0 0 2 0 0 0 0 0 0 0 }
{CSTYLE "" -1 262 "" 1 16 0 0 0 0 0 0 1 0 0 0 0 0 0 0 }{CSTYLE "" -1 
263 "" 1 14 0 0 0 0 0 0 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 264 "" 1 16 0 
0 0 0 0 0 1 0 0 0 0 0 0 0 }{CSTYLE "" -1 265 "" 1 16 0 0 0 0 0 0 1 0 
0 0 0 0 0 0 }{CSTYLE "" -1 266 "" 1 16 0 0 0 0 0 0 1 0 0 0 0 0 0 0 }
{CSTYLE "" -1 267 "" 0 1 0 0 0 0 0 0 1 0 0 0 0 0 0 0 }{CSTYLE "" -1 
268 "" 1 16 0 0 0 0 0 0 1 0 0 0 0 0 0 0 }{CSTYLE "" -1 269 "" 0 1 0 0 
0 0 0 0 1 0 0 0 0 0 0 0 }{CSTYLE "" -1 270 "" 1 16 0 0 0 0 0 0 1 0 0 
0 0 0 0 0 }{CSTYLE "" -1 271 "" 0 1 0 0 0 0 0 0 1 0 0 0 0 0 0 0 }
{CSTYLE "" -1 272 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 0 }{CSTYLE "" -1 
273 "" 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 0 }{PSTYLE "Normal" -1 0 1 
{CSTYLE "" -1 -1 "Times" 1 12 0 0 0 1 2 2 2 2 2 2 1 1 1 1 }1 1 0 0 0 
0 1 0 1 0 2 2 0 1 }{PSTYLE "Heading 1" -1 3 1 {CSTYLE "" -1 -1 "Times
" 1 18 0 0 0 1 2 1 2 2 2 2 1 1 1 1 }1 1 0 0 8 4 1 0 1 0 2 2 0 1 }
{PSTYLE "Heading 2" -1 4 1 {CSTYLE "" -1 -1 "Times" 1 14 0 0 0 1 2 1 
2 2 2 2 1 1 1 1 }1 1 0 0 8 2 1 0 1 0 2 2 0 1 }{PSTYLE "AC - Title" -1 
256 1 {CSTYLE "" -1 -1 "Times" 1 18 0 0 0 1 2 1 2 2 2 2 1 1 1 1 }3 1 
0 0 12 12 1 0 1 0 1 2 258 1 }{PSTYLE "AC - Author" -1 257 1 {CSTYLE "
" -1 -1 "Times" 1 12 0 0 0 1 1 2 2 2 2 2 1 1 1 1 }3 1 0 0 8 8 1 0 1 0 
2 2 259 1 }{PSTYLE "AC - Note" -1 258 1 {CSTYLE "" -1 -1 "Times" 1 12 
0 0 0 1 2 2 2 2 2 2 1 1 1 1 }3 1 0 0 0 0 1 0 1 0 2 2 0 1 }{PSTYLE "AC \+
- Normal Text" -1 259 1 {CSTYLE "" -1 -1 "Times" 1 12 0 0 0 1 2 2 2 2 
2 2 1 1 1 1 }1 1 0 0 0 0 1 0 1 0 2 2 0 1 }{PSTYLE "AC - Section Headin
g" -1 260 1 {CSTYLE "" -1 -1 "Times" 1 16 0 0 0 1 2 1 2 2 2 2 1 1 1 1 
}1 1 0 0 12 0 1 0 1 0 2 2 260 1 }{PSTYLE "AC - Disclaimer" -1 261 1 
{CSTYLE "" -1 -1 "Times" 1 9 0 0 0 1 2 2 2 2 2 2 1 1 1 1 }1 1 0 0 12 
0 1 0 1 0 2 2 0 1 }{PSTYLE "Normal" -1 262 1 {CSTYLE "" -1 -1 "Times" 
1 12 0 0 0 1 2 2 2 2 2 2 1 1 1 1 }3 1 0 0 0 0 1 0 1 0 2 2 0 1 }
{PSTYLE "AC - Author" -1 263 1 {CSTYLE "" -1 -1 "Times" 1 12 0 0 0 1 
1 2 2 2 2 2 1 1 1 1 }3 1 0 0 4 4 1 0 1 0 2 2 259 1 }{PSTYLE "Maple Out
put" -1 264 1 {CSTYLE "" -1 -1 "Times" 1 12 0 0 0 1 2 2 2 2 2 2 1 1 1 
1 }1 3 0 0 0 0 1 0 1 0 2 2 0 1 }{PSTYLE "Maple Plot" -1 265 1 {CSTYLE 
"" -1 -1 "Times" 1 12 0 0 0 1 2 2 2 2 2 2 1 1 1 1 }1 1 0 0 0 0 1 0 1 
0 2 2 0 1 }}
{SECT 0 {PARA 256 "" 0 "" {TEXT 261 40 "Higher Order Interpolation is \+
a Bad Idea" }{TEXT 257 0 "" }}{PARA 263 "" 0 "" {TEXT 256 7 "\251 2003
 " }{TEXT -1 127 "Nathan Collier, Autar Kaw, Jai Paul , University of \+
South Florida , kaw@eng.usf.edu , http://numericalmethods.eng.usf.edu/
mws ." }}{PARA 259 "" 0 "" {TEXT -1 0 "" }}{PARA 258 "" 0 "" {TEXT -1 
202 "NOTE: This worksheet demonstrates the use of Maple to show how hi
gher interpolation can be a bad idea. It illustrates how choosing more
 data points can result in highly oscillatory polynomial functions." }
}{SECT 0 {PARA 260 "" 0 "" {TEXT 258 12 "Introduction" }{TEXT -1 0 "" 
}}{PARA 259 "" 0 "" {TEXT 259 149 "The following example illustrates w
hy higher order polynomial interpolation, that is, interpolating using
 high number of data points, is a bad idea. " }{TEXT -1 127 "In 1901, \+
Carl Runge published his work on dangers of higher order polynomial in
terpolation.  He took a simple looking function " }{OLE 1 4100 1 "[xm]
Br=WfoRrB:::wk;nyyI;G:;:j::>:B>N:F:nyyyyy]::yyyyyy::::::::::::::::::::
:::::::::::::::::::::::::::::::::::::::::::::::::::fyyyyya:nYf::G:jy;:
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
::::::::JcvGYMt>^:fBWMtNHm=;:::::::n<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j:JNP
M>JSng;FaAF:;jR:_KjDJFEj:>:MSGK:_;KT:=J:>?sJ:VY;sy>Z:JBC:<J<D:c<:fg[oG
jIJJ:^Z:jPN:C:[Y:=J>JS>v<VfCF:RGs:qQ:[:JBG:;J<D::::v=>>:<:Uk:^:>X?B:K:
_c<SNJ]j:JvPM>JS>f<^v;F:;Jv:_;?F:=:GUGs:qAB:>L;Z<>Z<>ZJVdscRYEUXQZB:Mc
<OBGgrJKpIJJ:^:f??J<JrG:K:_c<SNtQj:jOPM>JS>f<>h=FZ:jXPM?JMJ?vYxy:J:^=V
Y[j=B:;JXE:<j:NZ\\VdsWhngfg[:N[:F>OV:B:=B:>pbQ<McJKxWCJ:f?=J<<:[Q;<j;B
:;:::Ja@Na`><:::::::::::::::::::::::::::::::::::::::::::::::::::::::::
::::::::3:" }{TEXT -1 268 " on the interval of [-1,1].  He took data p
oints equidistantly spaced in [-1,1], and then interpolated the data p
oints with polynomials.  He found that as he took more points, the pol
ynomials and the original curve differed considerably in their value f
rom each other." }}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 8 "restart;" 
}}}}{PARA 260 "" 0 "" {TEXT -1 0 "" }}{SECT 0 {PARA 3 "" 0 "" {TEXT 
262 17 "Section I : Data." }}{PARA 0 "" 0 "" {TEXT -1 29 "Runge's func
tion is given by:" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{EXCHG {PARA 0 ">
 " 0 "" {MPLTEXT 1 0 24 "fRunge:=x->1/(1+25*x^2);" }}}}{PARA 3 "" 0 "
" {TEXT 263 26 "Plotting Runge's Function:" }}{EXCHG {PARA 0 "> " 0 "
" {MPLTEXT 1 0 62 "plot(fRunge,-1..1,-1..1,thickness=2,title=\"Runge's
 function\");" }}}{PARA 3 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" 
{TEXT -1 0 "" }}{SECT 0 {PARA 3 "" 0 "" {TEXT -1 0 "" }{TEXT 264 55 "S
ection II: Polynomial interpolation for 5 data points." }}{PARA 0 "" 
0 "" {TEXT -1 218 "Let us first interpolate approximate Runge's functi
on using polynomial interpolation.  For interpolation 5 equidistant da
ta points, [-1, -0.5, 0, 0.5, 1] are chosen in [-1,1] . This will give
 us a 4th order polynomial." }}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 
98 "poly5:=interp([-1, -0.5, 0, 0.5, 1],[fRunge(-1), fRunge(-0.5),fRun
ge(0),fRunge(0.5),fRunge(1)],t);" }}}{EXCHG {PARA 0 "> " 0 "" 
{MPLTEXT 1 0 101 "poly5:=t->interp([-1, -0.5, 0, 0.5, 1],[fRunge(-1), \+
fRunge(-0.5),fRunge(0),fRunge(0.5),fRunge(1)],t):" }}}{PARA 0 "" 0 "" 
{TEXT -1 55 "let us now plot it against the actual Runge's function." 
}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 146 "plot([fRunge,poly5],-1..1
,-1..1,thickness=2,title=\"Runge's function and 4th order polynomial\"
,legend=[\"Runge's Function\",\"4th Order Polynomial\"]);" }}}}{PARA 
4 "" 0 "" {TEXT -1 0 "" }}{SECT 0 {PARA 3 "" 0 "" {TEXT -1 0 "" }
{TEXT 265 56 "Section III: Polynomial interpolation for 9 data points.
" }}{PARA 0 "" 0 "" {TEXT -1 205 "Runge' function is now approximated \+
by choosing 9 equidistant data points, [-1, -0.75, -0.5, -0.25, 0, 0.2
5, 0.5, 0.75, 1] in [-1,1].  Interpolating with these values would giv
e us an 8th order polynomial." }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}
{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 169 "poly9:=interp([-1,-0.75,-0.
5,-0.25,0,0.25,0.5,0.75,1],[fRunge(-1),fRunge(-0.75),fRunge(-0.5),fRun
ge(-0.25),fRunge(0),fRunge(0.25),fRunge(0.5),fRunge(0.75),fRunge(1)],t
);" }}}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 172 "poly9:=t->interp([-1
,-0.75,-0.5,-0.25,0,0.25,0.5,0.75,1],[fRunge(-1),fRunge(-0.75),fRunge(
-0.5),fRunge(-0.25),fRunge(0),fRunge(0.25),fRunge(0.5),fRunge(0.75),fR
unge(1)],t):" }}}{PARA 264 "" 1 "" {TEXT -1 59 "Plotting the 8th order
 polynomial against Runge's function," }}{EXCHG {PARA 0 "> " 0 "" 
{MPLTEXT 1 0 163 "plot([fRunge,poly9],-1..1,-1..1,thickness=2,color=[r
ed,blue],title=\"Runge's function and 8th order polynomial\",legend=[
\"Runge's Function\",\"8th Order Polynomial\"]);" }}}}{PARA 4 "" 0 "" 
{TEXT -1 0 "" }}{SECT 0 {PARA 3 "" 0 "" {TEXT -1 0 "" }{TEXT 266 56 "S
ection IV: Polynomial interpolation for 21 data points." }}{EXCHG }
{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 366 "poly21:=interp([-1,-0.9,-0.
8,-0.7,-0.6,-0.5,-0.4,-0.3,-0.2,-0.1,0,0.1,0.2,0.3,0.4,0.5,0.6,0.7,0.8
,0.9,1],[fRunge(-1),fRunge(-0.9),fRunge(-0.8),fRunge(-0.7),fRunge(-0.6
),fRunge(-0.5),fRunge(-0.4),fRunge(-0.3),fRunge(-0.2),fRunge(-0.1),fRu
nge(0),fRunge(0.1),fRunge(0.2),fRunge(0.3),fRunge(0.4),fRunge(0.5),fRu
nge(0.6),fRunge(0.7),fRunge(0.8),fRunge(0.9),fRunge(1)],t);" }}}
{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 369 "poly21:=t->interp([-1,-0.9,
-0.8,-0.7,-0.6,-0.5,-0.4,-0.3,-0.2,-0.1,0,0.1,0.2,0.3,0.4,0.5,0.6,0.7,
0.8,0.9,1],[fRunge(-1),fRunge(-0.9),fRunge(-0.8),fRunge(-0.7),fRunge(-
0.6),fRunge(-0.5),fRunge(-0.4),fRunge(-0.3),fRunge(-0.2),fRunge(-0.1),
fRunge(0),fRunge(0.1),fRunge(0.2),fRunge(0.3),fRunge(0.4),fRunge(0.5),
fRunge(0.6),fRunge(0.7),fRunge(0.8),fRunge(0.9),fRunge(1)],t):" }
{TEXT -1 0 "" }}}{EXCHG {PARA 0 "" 0 "" {TEXT -1 50 "Plotting this pol
ynomial against Runge's function," }}}{EXCHG {PARA 0 "> " 0 "" 
{MPLTEXT 1 0 166 "plot([fRunge,poly21],-1..1,-1..1,thickness=2,color=[
red,gold],title=\"Runge's function and 20th order polynomial\",legend=
[\"Runge's Function\",\"20th Order Polynomial\"]);" }}}}{PARA 4 "" 0 "
" {TEXT -1 0 "" }}{SECT 0 {PARA 3 "" 0 "" {TEXT -1 0 "" }{TEXT 267 0 "
" }{TEXT 268 22 "Section V: Comparison." }}{PARA 0 "" 0 "" {TEXT -1 
144 "Below is a plot to compare the interpolated polynomials obtained \+
using 5, 9 and 21 data points, respectively, with the actual Runge's f
unction :" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 
0 "" }}{EXCHG {PARA 0 "> " 0 "" {MPLTEXT 1 0 256 "plot([fRunge,poly9,p
oly5,poly21],-1..1,-2..2,thickness=[3,2,2,2],color=[RED,BLUE,GREEN,GOL
D],title=\"Runge's function,4th, 8th and 20th order polynomials\",lege
nd=[\"Runge's function\",\"8-th order polynomial\",\"4-th order polyno
mial\",\"20-th order polynomial\"]);" }}}{EXCHG }{EXCHG }{EXCHG {PARA 
0 "> " 0 "" {MPLTEXT 1 0 0 "" }}}{PARA 265 "" 1 "" {TEXT -1 0 "" }}}
{PARA 4 "" 0 "" {TEXT -1 0 "" }}{SECT 0 {PARA 3 "" 0 "" {TEXT -1 0 "" 
}{TEXT 269 0 "" }{TEXT 270 23 "Section VI: Conclusion." }}{PARA 0 "" 
0 "" {TEXT -1 331 "Maple helped us to apply our knowledge of numerical
 methods of interpolation to see that higher order interpolation is a \+
bad idea. As the interpolant order becomes higher, the difference betw
een the values of the original function and the interpolated function \+
are very different, especially close to the end points of -1 and +1.  \+
" }}{PARA 0 "" 0 "" {TEXT -1 0 "" }}{PARA 0 "" 0 "" {TEXT -1 124 "Choo
se even order of  polynomials of your own choice, and see the effect o
f the higher order interpolation at x=0.8 and x=0." }}}{PARA 4 "" 0 "
" {TEXT 271 11 "References:" }}{PARA 0 "" 0 "" {TEXT -1 4 "[1] " }
{TEXT 272 53 "Autar Kaw, Holistic Numerical Methods Institute , See" }
}{PARA 0 "" 0 "" {TEXT 273 81 "http://numericalmethods.eng.usf.edu/mws
/ind/05inp/mws_ind_inp_spe_higherorder.pdf" }}{PARA 261 "" 0 "" {TEXT 
-1 0 "" }{TEXT 260 11 "Disclaimer:" }{TEXT -1 248 " While every effort
 has been made to validate the solutions in this worksheet, University
 of South Florida and the contributors are not responsible for any err
ors contained and are not liable for any damages resulting from the us
e of this material." }}}{MARK "0 0" 0 }{VIEWOPTS 1 1 0 1 1 1803 1 1 1 
1 }{PAGENUMBERS 0 1 2 33 1 1 }
