0% found this document useful (0 votes)
69 views29 pages

Runge Phenomenon: Guided By: Dr. Geetanjali Pradhan

The document summarizes Runge phenomenon and cubic spline interpolation. It discusses how Runge phenomenon causes the error in polynomial interpolation to increase with higher degrees despite using infinite precision calculations. This is due to amplification of the mathematical error from the derivatives. Cubic spline interpolation is presented as an alternative that divides the domain into pieces and fits cubic polynomials to each piece, minimizing errors compared to single polynomial interpolation. The document explains how to determine the coefficients of cubic spline functions to achieve continuity of the function, first derivative, and second derivative across pieces.

Uploaded by

Swarupa Sarangi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
69 views29 pages

Runge Phenomenon: Guided By: Dr. Geetanjali Pradhan

The document summarizes Runge phenomenon and cubic spline interpolation. It discusses how Runge phenomenon causes the error in polynomial interpolation to increase with higher degrees despite using infinite precision calculations. This is due to amplification of the mathematical error from the derivatives. Cubic spline interpolation is presented as an alternative that divides the domain into pieces and fits cubic polynomials to each piece, minimizing errors compared to single polynomial interpolation. The document explains how to determine the coefficients of cubic spline functions to achieve continuity of the function, first derivative, and second derivative across pieces.

Uploaded by

Swarupa Sarangi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 29

Nov 26th ,2021

RUNGE PHENOMENON
Guided by:
Dr. Geetanjali Pradhan
Group Members:
SRABANI SAHOO (1812106037)
SWARUPA SARANGI (1812106046)
Overview
 Analysing Runge Phenomenon
 The role of error in Runge Phenomenon
 How to minimize Runge Phenomenon?
 Briefly explaining Chebyshev Nodes
 Effectiveness of Piecewise Interpolation
 Preference of Cubic Spline Interpolation
• Question: If the calculation is done with infinite precision( that is, without any
finite digit floating point arithmetic) and the function f is smooth, then
DO WE ALWAYS HAVE A BETTER APPROXIMATION FOR A LARGER VALUE OF
n?

THIS IS NOT TRUE!

This was first shown by Carl Runge.

(The phenomenon of increasing error in a particular way is later called


as Runge Phenomenon)
RUNGE FUNCTION
• Example: (Runge Function)
Consider the Runge’s Function defined on the interval given by

(blue line), (red line). is plotted with black line


• Example: (Runge Function)
Consider the Runge’s Function defined on the interval [-1,1] given by

n= 18 (blue line). is plotted with black line.


• Question: Is the Runge phenomenon due to the amplification in the
arithmetic error?
Even if the calculation is done with infinite precision (that is, without any finite digit floating
point arithmetic), we may still have the Runge Phenomenon due to the amplification in
Mathematical Error.
This can be observed from the upper bound of the infinity norm of , which is given as

(for a polynomial of degree 18)

The error between the generating function and the interpolating polynomial of order n is bounded by
the derivative of the generating function. For Runge-type functions, the magnitude of the derivative
increases.
Interpolating Runge’s function at evenly spaced points leads to exponential growth of infinity norm
error!
• Example: (Runge Function)
Consider the Runge’s Function defined on the interval given by

(blue line), (red line). is plotted with black line


•Example: (Runge Function)
Consider the Runge’s Function defined on the interval given by

(blue line). is plotted with black line.


CHEBYSHEV NODES
• Observe: Error increases near two boundaries
We can find a sequence of nodes for which the corresponding interpolating polynomial yields a good
approximation even for a large value of n.
For instance, define a sequence of nodes

For each
When , the nodes are,
, , , and
.

The nodes defined above are called Chebyshev Nodes.


𝑛=4 𝑛=18

𝑛=32 𝑛=64
𝑓 ( 𝑥 ) , 𝑝 4 (𝑥)

𝑓 ( 𝑥 ) , 𝑝32 (𝑥)

𝑓 ( 𝑥 ) , 𝑝16 (𝑥)

𝑓 ( 𝑥 ) , 𝑝64 (𝑥 )
SPLINE INTERPOLATION
 Piecewise Function
Function defined by multiple sub-functions, where each sub-function applies to a different
interval in the domain.
Piecewise definition is actually a way of expressing the function, rather than a characteristic of
the function itself.

{
𝒙 +𝟑 𝒊𝒇 𝒙 <− 𝟐
𝒇 ( 𝒙 ) = −|𝒙 |+𝟓 𝒊𝒇 − 𝟐 ≤ 𝒙 ≤ 𝟑
𝒙 − 𝟒 𝒊𝒇 𝒙 ≥ 𝟑
What’s Piecewise Interpolation?
• Instead of fitting a single, polynomial to data points, fits low-degree polynomials to subsets of
the values.
• The most common connecting
polynomials are linear or cubic.
• The points where the polynomials
connect are called knots.
Piecewise linear interpolation
Piecewise linear interpolation is simply a game of connect-the-dots. Let us assume
the nodes are given in order, so that

between each pair of adjacent nodes, we use a straight line segment. The resulting
interpolant is given by
Spline (a special type of piecewise polynomial)
If the subsets of data are just two points each, then we call these connecting polynomials
Splines.

Splines minimize oscillation problems and reduce roundoff error possibility due to their lower-
order nature.

In the mathematical field of numerical analysis, Spline Interpolation is a form of


interpolation where the interpolant is a spline.
Spline interpolation is often preferred over polynomial interpolation because the interpolation error can
be made small even when using low-degree polynomials for the spline.
Spline Formation
• A data set of points have intervals between the points.
3- degree polynomial
• We can define spline function for the intervals.
𝑓 (𝑥)

𝑠 5 ( 𝑥)

0 𝑥 𝑥5 𝑥6
5th interval
Spline Formation(Example)
Determining the Spline Functions
• Linear splines: find equations of the line for each interval that

 Pass through the points at either end

• Quadratic splines: find equations of parabolas for each interval that

 Pass through the points at either end

 Match first derivatives at the interior points

• Cubic splines: find cubic equations for each interval that

 Pass through the points at either end (Continuity at the boundary)

 Match first derivative at the interior points (Slope continuity at the boundary)

 Match the second derivative at the interior points (Curvature continuity at the boundary)
Cubic Splines
• Cubic Splines are generally preferred because
they provide the simplest representation that
exhibits the desired appearance of smoothness.
× Linear splines have discontinuous first derivatives

× Quadratic splines have discontinuous second derivatives and require setting the second

derivative at some point to a pre-determined value in order to determine the coefficients


× Quartic of higher order splines tend to exhibit the instabilities inherent in higher order

polynomials(ill-conditioning and/or oscillations).


Determining Cubic Splines Coefficients
• In general, the ith spline function for a cubic spline can be written as:

For data points, there are intervals and thus unknows are required to evaluate- to solve the spline
function coefficients.

𝑆𝑖 ( 𝑥 )
𝑓 (𝑥)

𝒙 − 𝒙𝒊
𝑥𝑖
0 𝑥𝑖
𝑥
Solving for the Spline Coefficients
• The spline function goes through the first and last point of each interval, yielding equation of the
form:

• The first derivative is continuous at each interior points yielding equation of the form:

• The second derivative is continuous at each interior points yielding equation of the form:
Two Additional Equations
• There are a few good options for the final two equations:
 Natural end conditions- assume the second derivative at the first and last points are zero.

 Clamped end conditions- assume the first derivatives at the first and last points are known and specify

values.

 “Not-a-knot” end conditions- force continuity of the third derivative at the second and next-to-last knots

(results in the first two intervals having the same spline function and the last two intervals having the
same spline function)

The best choice depends on the particular data set and/or application you are dealing with.
CONCLUSION
> Spline interpolation is better than
polynomial interpolation
> Cubic Spline interpolation is a special
case of spline interpolation that is
used very often to avoid the problem
of Runge’s phenomenon.
> This method gives an interpolating
polynomial that is smoother and has
smaller error than other
interpolating polynomials such as
Lagrange polynomial and Newton
polynomial.
References Introductory Methods of Numerical Analysis by S.S.Sastry.

Numerical Methods for Scientific and Engineering Computation; M.K. Jain, S.R.K. Iyengar,
R.K.Jain.

A Introduction to Numerical Analysis by K. Atkinson, Wiley.

https://fncbook.github.io/fnc/localapprox/pwlin.html

https://en.wikiversity.org/wiki/Cubic_Spline_Interpolation

https://en.wikipedia.org/wiki/Piecewise

https://courses.seas.harvard.edu/courses/am205/slides/am205_unit1.pdf

https://youtu.be/5xKKxgMaA1o

https://www.coursera.org/learn/intro-to-numerical-analysis/lecture/nxqg5/chebyshev-nodes
ANY QUESTIONS?
THANK YOU

You might also like