Maths Compiled NRS

You might also like

Download as doc, pdf, or txt
Download as doc, pdf, or txt
You are on page 1of 64

Notes by: Prof . N.R.

Srinath, RNIST, Bangalore

ALCULUS OF VARIATIONS
Calculus of variations deals with finding maximum or minimum value of a definite integral
involving a certain function.

FUNCTIONALS

We wish to find the curve y = f(x) where y(x1) = y1 and y(x2) = y2 such that for a given
function f(x, y, y’)

Ex: Consider the problem of finding the curve y = f(x) through (x1, y1) and (x2, y2) such
that the length is minimum.

Euler’s Equation
A necessary condition for

Proof:
Let y = y(x) be the Curve joining A(x1, y1) and B(x2, y2) which makes I an extremum.
be a neighbouring curve joining joining A and B.

The value of I along (1) is

1
This being a function of , is maximum or minimum for = 0.

which is the Euler’s equation

Other forms of Eulers Equations

Proof:
Since f is a function of x, y, y’

We have

2
which is another form of Eulers Equation

Say (x, y, y’)

Particular Cases
1. f is a function of y’ alone

then Eulers equation reduces to

This may be integrated to obtain y = y(x)

3
2. f is independent of y

Again Euler’s equation reduces to

Since f is independent of y this can be solved by integration.

3. f is independent of y’

This can be solved by integration.


4. f is independent of x and y.

Euler’s equation becomes

This yields a solution of the form y = ax + b

1. Find the extremals of the functional

We have which is independent of y.

 Eulers equation reduces to

4
2. Prove that the shortest distance between two points in a plane is a straight line.

 We get a straight line

5
3. Find the curves on which the function with y(0) = 0 and y(1) =1

can be extremised.

By Euler’s equation

12x – 2y’’ = 0

 y = x3 is the only Curve on which extremum can be attained.

4. On which Curve the functional

Let f = (y’)2 – y2 + 2xy

Eulers equation

A.E D2 + 1 = 0

6
D=i
CF = C1 sinx + C2 cos x

= (1 + D2)-1 x
= (1 – D2) x
=x
 y = C1 sinx + C2 cos x + x
y(0) = 0  C2 = 0

5. Find the extremal of the functional

We have f = y2 – (y1)2 – 2ysinx

2y – 2 sinx + 2y’’ = 0  y’’ + y = sinx


A,E is D2 + 1 = 0  D = i
CF = C1 cos x + C2 sinx

7
Given y(0) = 0  0 = C1

C2 = 0

GEODESIC
A geodesic on a surface is a curve along which the distance between any two points of
the surface is a minimum.

1. Show that the geodesics on a sphere of radius a are its great circles.
We have

By Eulers equation

8
I w.r.t 

is a plane thro origin which cuts the sphere along a greater circle.

MINIMAL SURFACE OF REVOLUTION


1. Find the curve passing through the points (x1, y1) and (x2, y2) which when rotated
about the x-axis gives a minimum surface area.

9
Let S be the surface area

 Eulers equation reduces to

We get

Separating the variables and integrating

BRACHISTOCHRONE PROBLEM
“Brachistos” means shortest and “Chronos” means time. We wish to find the path of a
particle in the absence of friction, which will slide from one point to another in the
shortest time under the action of gravity.

10
Let the particle start sliding along OP1 from O with initial velocity zero.

At time ‘t’ the particle be at P(x, y) and OP = s

By principle of work and energy


K.E at P – K.E at O = Work done in moving the particle from O to P.

i.e.,

Now time taken by particle to move from O to P1 is

Euler’s equation reduces to

11
Solving for y1

Solving for y1

Separating the variables

Hanging chain
Consider a heavy chain suspended under gravity between two points A and B,

12
Let ds be the are elements at P(x, y) of the chain.
If  is the density of chain, then
Potential energy of the element is  ds gy, where g is the acceleration due to gravity.
 The total potential energy of the chain is given by

 Euler's equation reduces to

Isoperimetric problems

suppose we wish to find the external of I subject to

the conclusion.

13
Problems of this kind are referred as isoperimetric problems.
Example:
Finding a closed curve of given perimeter and maximum area.

These problems are generally solved by method of Lagrange's multipliers.

To extremise (1) we multiply (2) by  and add to (1)


 is called the Lagrange Multiplier

Where H = f + g

The general solution of (4) contains two orbitrary constants and the multiplier , which
can be evaluated by using y(x1) = y1, y(x2) = x2 and (2).

1. Find the plane curve of fixed perimeter and maximum area.


Let l be the fixed perimeter of a plane curve, between x = x1 and x = x2 then

H satisfies Eulers equation

14
or (x - a)2 + (y - b)2 = 2 which is a circle

2. Prove that the sphere is the solid figure of revolution which for a given surface area,
has maximum volume.

Consider are OPA of the curve which rotates about the x-axis.

Volume of solid of revolution

We have to maximize V subject to S =Constant

15
H satisfies Eulers equation (independent of x)

as the curve passes through (0, 0) and (a, 0) → c=0

When x = 0, y = 0, k = 2
or (x - 2)2 + y2 = 42 which is a circle with centre (2, 0) and radius 2
Hence figure formed by the revolution of area is a sphere.

16
Numerical Analysis
Limitations of analytical methods led to the evolution of Numerical methods. Numerical
Methods often are repetitive in nature i.e., these consist of the repeated execution of the
same procedure where at each step the result of the proceeding step is used. This process
known as iterative process is continued until a desired degree of accuracy of the result is
obtained.

Solution of Algebraic and Transcendental Equations


The equation f(x) = 0 said to be purely algebraic if f(x) is purely a polynomial in x.

If f(x) contains some other functions like Trigonometric, Logarithmic, exponential etc.
then f(x) = 0 is called a Transcendental equation.

Ex: (1) x4 - 7x3 + 3x + 5 = 0 is algebraic


(2) ex - x tan x = 0 is transcendental

Bisection Method:
This method is used in locating a root of the equation f(x) = 0 between a and b.

If f(x) is continuous between a and b, f(a) and f(b) are opposite in sign then exists a root between
a and b.

For simplicity, let f(a) < 0 and f(b) > 0

The first approximation to the root is

If f(x1) = 0 then x1 is the root of f(x)=0


If f(x1) is + ve then root lies between a and x1 and the second approximation to the root is

Now if f(x2) is - ve then the root lies between x2 and x1 and the third approximation to the root is

17
This process is continued until the root is found with desired accuracy

Fig.
1. Solve x3 - 9x + 1 = 0 for the root lying between 2 and 3 using bisection method in six stages.
Answer:
f(x) = x3 - 9x + 1 = 0
f(2) =-9 -ve
f(3) = 55 +ve

 Root lies between 2.5 and 3

f(x2) = f(2.75) = -2.9 -ve


 Root lies between 2.75 and 3

18
f(x3) = 2.875 = -1.111 -ve
 Root lies between 2.875 and 3

f(x4) = -0.09 -ve


 Root lies between 2.9375 and 3

f(x5) = 0.451 +ve


 Root lies between 2.9375 and 2.969

f(x5) = 0.17 +ve

 Root lies between 2.9375 and 2.953

19
Method of false position or Regula-Falsi Method:
This is a method of finding a real root of an equation f(x) = 0 and is slightly an
improvisation of the bisection method.

Let x0 and x1 be two points such that f(x0) and f(x1) are opposite in sign.

Let f(x0) > 0 and f(x1) < 0


 The graph of y = f(x) crosses the x-axis between x0 and x1
 Root of f(x) = 0 lies between x0 and x1
Now equation of the Chord AB is

When y =0 we get x = x2

20
Which is the first approximation
If f(x0) and f(x2) are opposite in sign then second approximation

This procedure is continued till the root is found with desired accuracy.

1. Find a real root of x3 - 2x -5 = 0 by method of false position correct to three decimal


places between 2 and 3.
Answer:
Let f(x) = x3 - 2x - 5 = 0
f(2) = -1
f(3) = 16
 a root lies between 2 and 3
Take x0 = 2, x1 = 3
 x0 = 2, x1 = 3

= 2.0588
f(x2) = f(2.0588) = -0.3908

 Root lies between 2.0588 and 3


Taking x0 = 2.0588 and x1 = 3
f(x0) = -0.3908, f(x1) = 16

= 2.0813
f(x3) = f(2.0813) = -0.14680
 Root lies between 2.0813 and 3

21
Taking x0 = 2.0813 and x1 = 3
f(x0) = 0.14680, f(x1) =16

Repeating the process the successive approximations are


x5 = 2.0915, x6 = 2.0934, x7 = 2.0941, x8 = 2.0943
Hence the root is 2.094 correct to 3 decimal places.

22
2. Find the root of the equation xex = cos x using Regula falsi method correct to three
decimal places.
Answer:
Let f(x) = cosx - xex
Observe
f(0) = 1
f(1) =cos1 - e = -2.17798
 root lies between 0 and 1
Taking x0 = 0, x1 = 1
f(x0) = 1, f(x1) = -2.17798

f(x2) = f(0.31467) = 0.51987 +ve


 Root lies between 0.31467 and 1
x0 = 0.31467, x1 = 1
f(x0) = 0.51987, f(x1) = -2.17798

f(x3) = f(0.44673) = 0.20356 +ve


 Root lies between 0.44673 and 1

Repeating this process


x5 = 0.50995, x6 = 0.51520, x7 = 0.51692, x8 = 0.51748
x9 = 0.51767, etc
Hence the root is 0.518 correct to 4 decimal places

Newton Raphson Method

23
This method is used to find the isolated roots of an equation f(x) = 0, when the derivative
of f(x) is a simple expression.

Let m be a root of f(x) = 0 near a.


 f(m) = 0
We have by Taylor's series

Ignoring higher order terms


f(m) = f(a) + (m - a) f' (a) = 0

Let a = x0, m = x1

1. Using Newton's Raphson Method find the real root of x log10 x = 1.2 correct to four
decimal places.
Answer:
Let f(x) = x log10 x - 1.2
f(1) = -1.2, f(2) = -0.59794, f(3) = 0.23136

24
Let x0 = 2.5 (you may choose 2 or 3 also)

Repeating the procedure

2.Using Newton's Method, find the real root of xex = 2. Correct to 3 decimal places.
Answer:
Let f(x) = xex - 2
f(0) = -2
f(1) = e - 2 = 0.7182
Let x0 = 1
f' (x) = (x + 1) ex
We have

25
3. Find by Newton's Method the real root of 3x = cosx + 1 near 0.6, x is in radians.
Correct for four decimal places.
Answer:
Let f(x) = 3x - cosx - 1
f'(x) = 3 + sinx

Since x1 = x2
The desired root is 0.6071

4. Obtain the iterative formula for finding the square root of N and find
Answer:

or x2 - N = 0
 f(x) = x2 - N
f'(x) = 2x
Now

26
Since x2 = x3 = 6.4031

5. Obtain an iterative formula for finding the p-th root of N and hence find (10)1/3 correct
to 3 decimal places.
Answer:
Let xp = N
or xp - N = 0
Let f(x) = xp - N
f ' ( x )  px p1

Observe that 8 < 10

 Use x0 = 2, p = 3, N=10

27
6. Obtain an iterative formula for finding the reciprocal of p-th root of N. Find (30) -1/5
correct to 3 decimal places.
Answer:
Let x -p = N
or x -p - N = 0
 f(x) = x -p - N
f'(x) = -px -p - 1
Now

We use x0 = 0.5, p = 5, N = 30

28
proof not read
Finite Differences
Let y = f(x) be represented by a table
x: x0 x1 x2 x3 …. xn
y: y0 y1 y2 y3 … yn
where x0, x1,x2….xn are equidistant. (x1 - x0 = x2 - x1 = x3 - x2 =….=xn - xn-1 = h)
We now define the following operators called the difference operators.

Forward difference operator ()

Difference Table
x y y 2y 3y 4y 5y
x0 y0
y0
x1 y1 2y0

29
y1 3y0
x2 y2 2y1 4y0
y2 3y0
x3 y3 2y2
y3
x4 y4

Ex: The following table gives a set of values of x and the corresponding values of y = f(x)
x: 10 15 20 25 30 35
y: 19.97 21.51 22.47 23.52 24.65 25.89

Form the difference table and find


x y  2 3 4 5

10 19.97
1.54
15 21.51 -0.58
0.96 0.67
20 22.47 0.09 -0.68
1.05 -0.01 0.72
25 23.52 0.08 0.04
1.13 0.03
30 24.65 0.11
1.24
35 25.89

Note: The nth differences of a polynomial of n the degree are constant.


If f(x) = a0 xn + a1 xn-1 + a2 xn-2 +… + an, a0  0 then

30
1. Construct a difference table for y = f(x) = x3 +2x + 1 for x = 1, 2, 3, 4, 5

x y y y y y


1 4
9
2 13 12
21 6
3 34 18 0
39 6
4 73 24
63
5 136

2. If y0 = 1, y1 = 11, y2 = 21, y3 = 28, y4 = 29. Construct the difference table.

31
x y y y y y
x0 1
10
x1 11 0
10 -3
x2 21 -3 0
7 -3
x3 28 -6
1
x4 29

Backward difference operator ()


Let y = f(x)
We define f(x) = f(x) - f(x - h)
i.e. y1 = y1 - y0 =  y0
y2 = y2 - y1 =  y1
y3 = y3 - y2 =  y2
'
'
yn = yn - yn-1 =  yn - 1

Note:
1.  f(x + h) = f(x + h) - f(x) =  f(x)
2. 2 f(x + 2h) = (f(x + 2h))
=  {f(x + 2h) - f(x + h)}

32
= f(x + 2h) -  f(x + h)
= f(x + 2h) - f(x + h) - f(x + h) + f(x)
= f(x + 2h) -2f(x + h) + f(x)
= 2 f(x)
|||ly n f(x + nh) = n f(x)

Backward difference table


x y y 2y 3y 4y 5y
X0 y0
y1
X1 y1 2y2
y2 3y3
X2 y2 2y3 4y4
y3 3y4 4y5
X3 y3 2y4 4y5
y4 3y5
X4 y4 2y5
y5
X5 y5

1. Form the difference table for


x 40 50 60 70 80 90
y 184 204 226 250 276 304

and find y (30), 2y (70), 5y (90)

33
x y y 2y 3y 4y 5y
40 184
20
50 204 2
22 0
60 226 2 0
24 0 0
70 250 2 0
26 0
80 276 2
28
90 304

y (80) = 26, 2y (70) = 2, 5y (90) = 0

2. Given
x 0 1 2 3 4
f(x) 4 12 32 76 156

Construct the difference table and write the values of f (4), 2f (4), 3f (3)

34
x y y 2y 3y
0 4
8
1 12 12
20 12
2 32 24
44 12
3 76 36
80
4 156

Central Differences Operator ()


Let y = f(x) be represented by a table
x: x0 x1 x2 x3 …. xn
y: y0 y1 y2 y3 … yn

Note 1:

Note 2:

Note 3: We have

35
Note 4: Central difference table

x y y 2y 3y 4y


x0 y0
y1/2
x1 y1 2y1
y3/2 3y3/2
x2 y2 2y2 4y4
y5/2 3y5/2
x3 y3 2y3
y7/2
x4 y4

1. Show that:
i)

ii) prove that

36
2. Given f(-2) = 12, f(-1) = 16, f(0) = 15, f(1) = 18, f(2) = 20
form the central difference table and write down the values of y-3/2, 2y0, 3y1/2 by taking
x0 = 0
x y y 2y 3y 4y
-2 y-2 12

y-3/2 4
-1 y-1 16 2y1 -5
y-1/2 -1 3y-1/2 9
0 y0 15 2y0 4 4y0 -14

y1/2 3 3y1/2 -5
1 y1 18 2y1 -1
y3/2 2
2 y2 20

Shift operator (E)


E f(x) = f(x +h)
E2 f(x) = f(x + 2h)
En f(x) = f(x + nh)

Note: 1

f ( x )  Ef ( x )  f ( x )

37
Note 2:

1. Show that
i) 6 y 0  y 6  6 y 5  16 y 4  20 y 3  15 y 2  6 y1  y 0

ii)

2. If f(x) = x3 + 6x2 + 11x + 6. Prove that the second difference is 6x + 18 using h = 1.

= 6x + 18

3. If f(x) = eax show that f(0) and its leading differences form a G.P
f(x) = eax
f(0) = e0 = 1

38
which is in GP where first term = ea(0) = 1
Common ratio eah - 1

4. Find i) sinx ii) tan-1x iii) log x


i) sinx = sin (x + h) - sinx

ii)

iii)

5. Evaluate i) ii) choose h = 1

Answer:

i)

ii)

39
6. Find the missing term from the table:
x 0 1 2 3 4
y 1 3 9 - 81

Explain why the value obtained is different by putting x = 3 in 3x.


Note:
The above problem can be worked in two methods
Method I denoting the missing value as a, b, c ..etc. Construct a difference table and
solve.
Method II Given a set of n values, assume n y = 0 or (E - 1)n y = 0 expand using
binomial theorem.
x y y 2y 3y 4y
0 1 2
1 3 6 4
2 9 a-9 a - 15 a - 19 -4a + 124
3 a 81 - a 81 - a -3a +105
4 81

Put 4y = 0 (assuming f(x) its be a polynomial of degree 3)


i.e., -4a + 124 = 0
a = 31

Since we have assumed f(x) to be a polynomial of degree 3 which is not 3 x we obtained a


different value.

40
Method 2:
(E - 1)4 y0 = 0
y4 - 4E3y0 + 6E2y0- 4Ey0 + y0 = 0
y4 - 4y3 + 6y2 - 4y1 + y0 = 0  y3 = 31

7. Given u1 = 8, u3 = 64, u5 = 216 find u2 and u4


x u u 2u 3u
x1 8
x2 a a-8 -2a + 72 b + 3a - 200
x3 64 64 - a b + a - 128 -3b - a + 408
x4 b b - 64 -2b + 280
x5 216 216 -b

We carryout upto the stage where we get two entries ( 2 unknowns) and equate each
of those entries to zero. (Assuming) to be a polynomial of degree 2.
b + 3a - 200 = 0
-3b - a + 408 = 0
We get a = 24 b = 128

Method 2:
Given 3 set of values
Assume 3u0 = 0

i.e.,

41
Solving we get a = 24, b = 128

8. Given u0 = 0, u1 = 12, u2 = 81, u3 = 200, u4 = 100, u5 = 8 find 5 u0 without using


difference table.
Ans: 5 u0 = 755
Try these
9. Find the missing value in the table
x 0 1 2 3 4
y 1 2 4 - 16

Answer: a = 8.25

10. Assuming that the following values of y belong to a polynomial of degree 4.


Complete the next 3 values.
x 0 1 2 3 4
y 1 -1 1 -1 1

Answer: a = 31, b = 129, c = 351

Interpolation
The word interpolation denotes the method of computing the value of the function y =
f(x) for any given value of x when a set (x0, y0), (x1, y1),…(xn, yn) are given.
Note:
Since in most of the cases the exact form of the function is not known. In such cases the
function f(x) is replaced by a simpler function (x) which has the same values as f(x) for
x0, x1, x2….,xn.

42
is called the Newton Gregory forward difference formula

Note :
1. Newton forward interpolation is used to interpolate the values of y near the beginning
of a set of tabular values.
2. y0 may be taken as any point of the table but the formula contains those values of y
which come after the value chosen as y0.

The table gives the distances in nautical miles of the visible horizon for the given heights
in feet above the earths surface.
x = height 100 150 200 250 300 350 400
y = distance 10.63 13.03 15.04 16.81 18.42 19.90 21.27

Find the values of y when i) x = 120, ii) y =218

43
x y  2 3 4 5 6
100 10.63
2.40
150 13.03 -0.39
2.01 0.15
200 15.04 -0.24 -0.07
1.77 0.08 0.02
250 16.81 -0.16 -0.05 0.02
1.61 0.03 0.04
300 18.42 -0.13 -0.01
1.48 0.02
350 19.90 -0.11
1.37
400 21.27

Choose x0 = 100

i)

ii) Let x = 218, x0 = 200,

= 15.7

2. Find the value of f(1.85)

44
x y y 2y 3y 4y 5y 6y
1.7 5.474
0.575
1.8 6.049 0.062
0.637 0.004
1.9 6.686 0.066 0.004
0.703 0.008 -0.004
2.0 7.389 0.074 0 0.004
0.777 0.008 0
2.1 8.166 0.082 0
0.859 0.008
2.2 9.025 0.090
0.949
23 9.974

= 6.359

4. Given sin 45o = 0.7071, sin 50o = 0.7660, sin 55o =0.8192, sin 60o = 0.8660. Find sin
48o.

x y  2 3
45 0.7071
0.589
50 0.7660 -0.0057
0.0532 0.0007
55 0.8192 -0.0064
0.0468

45
60 0.8660

From the following data find the number of students who have obtained  45 marks.
Also find the number of students who have scored between 41 and 45 marks.
Marks 0 - 40 41 - 50 51 - 60 61 -70 71 - 80
No. of students 31 42 51 35 31

46
x y  2 3 4
40 31
42
50 73 9
51 -25
60 124 -16 37
35 12
70 159 -4
31
80 190

f(45) - f(40) = 70 = Number of students who have scored between 41 and 45.

Find the interpolating polynomial for the following data:


f(0) = 1, f(1) = 0, f(2) = 1, f(3) = 10. Hence evaluate f(0.5)

47
y  2 3
x
0 1
-1
1 0 2
1 6
2 1 8
9
3 10

6. Find the interpolating polynomial for the following data:


x: 0 1 2 3 4
f(x) : 3 6 11 18 27

48
x y  2 3 4
0 3
3
1 6 2
5 0
2 11 2 0
7 0
3 18 2
9
4 27

Newton Gregory Backward Interpolation formula

2. The values of tan x are given for values of x in the following table. Estimate tan (0.26)

x 0.10 0.15 0.20 0.25 0.30


y 0.1003 0.1511 0.2027 0.2553 0.3093

49
x y  2 3 4
0.10 0.1003
0.0508
0.15 0.1511 0.0008
0.0516 0.0002
0.20 0.2027 0.0010 0.0002
0.0526 0.0004
0.25 0.2553 0.0014
0.0540
0.30 0.3093

3. The deflection d measured at various distances x from one end of a cantilever is given
by the following table. Find d when x = 0.95

50
x d  2 3 4 5
0 0
0.0347
0.2 0.0347 0.0479
0.0826 -0.0318
0.4 0.1173 0.0161 0.0003
0.0987 -0.0321 -0.0003
0.6 0.2160 -0.016 0
0.0827 -0.032
0.8 0.2987 -0.0481
0.0346
1.0 0.3333

0.95  1
u  0.25 d  0.3308 when x  0.95
0.2
4. The area y of circles for different diameters x are given below:
x: 80 85 90 95 100
y: 5026 5674 6362 7088 7854

Calculate area when x = 98


x y y 2y 3y 4y
80 5026
648
85 5674 40
688 -2
90 6362 38 4
726 2
95 7088 40
766
100 7854

Answer:

y = 7542

51
Find the interpolating polynomial which approximates the following data.

x 0 1 2 3 4
y -5 -10 -9 4 35

52
x y  2 3 4
0 -5
-5
1 -10 6
1 6
2 -9 12 0
13 6
3 4 18
31
4 35

53
54
Central difference interpolation formula
X y  2 3 4 5 6
x-3 y-3
y-3
x-2 y-2 2y-3
y-2 3y-3
x-1 y-1 2y-2 4y-3
y-1 3y-2 5y-3
x0 y0 2y-1 4y-2 6y-3
y-0 3y-1 5y-2
x1 y1 2y0 4y-1
y1 3y0
x2 y2 2y1
y2
x3 y3
a) Stirlings formula

b) Bessel's formula

55
1. Apply sterling's formula to find f(14.2) from the following table:
x y  2 3 4
10 0.24
0.041
12 0.281 -0.004
0.037 0.001
14 0.318 -0.003 0
0.034 0.001
16 0.352 -0.002
0.032
18 0.384
x  x 0 14.2  14
u   0.1
h 2

= 0.3215

56
2.Apply stirling's formula to find a polynomial f(x) of degree 4 that approximates the
following data and hence find f(2.5)
x f(x)  2 3 4
1 1
-2
2 -1 4
2 -8
3 1 -4 18
-2 8
4 -1 4
2
5 1

3. Using Bessels formula find f(12.5) for the data:

57
x f(x)  2 3
5 12
1
10 13 0
1 1
15 14 1
2
20 16

=13.4375

4. Using Bessel's formula find 3rd degree polynomial that approximates the following
data:
f(0) = 2, f(1) = 3, f(2) = 8, f(3)=23
x y  2 3
0 2
1
1 3 4
5 6
2 8 10
15
3 23

58
Interpolation with unequal intervals
Newton backward and forward interpolation is applicable only when x 0, x1,…,xn-1 are
equally spaced.

Now we use two interpolation formulae for unequally spaced values of x.

i) Lagranges formula for unequal intervals:


If y = f(x) takes the values y0, y1, y2,….,yn corresponding to x = x0, x1, x2,…,xn then

is known as the lagrange's interpolation formula

ii) Divided differences ()

second divided difference

59
similarly
Newton's divided difference interpolation formula

is called the Newton's divided difference formula.

Note:
Lagrange's formula has the drawback that if another interpolation value were inserted,
then the interpolation coefficients need to be recalculated.

Inverse interpolation: Finding the value of y given the value of x is called interpolation
where as finding the value of x for a given y is called inverse interpolation.

Since Lagrange's formula is only a relation between x and y we can obtain the inverse
interpolation formula just by interchanging x and y.

is the Lagranges formula for inverse interpolation

5. The following table gives the values of x and y


x: 1.2 2.1 2.8 4.1 4.9 6.2
y: 4.2 6.8 9.8 13.4 15.5 19.6

60
Find x when y = 12 using Lagranges inverse interpolation formula.
Using Langrages formula

= 3.55

1. Given the values


x: 5 7 11 13 17
f(x) : 150 392 1452 2366 5202

Evaluate f(9) using (i) Lagrange's formula (ii) Newton's divided difference formula.

i) Lagranges formula

f(9) = 810

ii)
5 150
121
7 392 24
265 1

61
11 1452 32 0
457 1
13 2366 42
709
17 5202

f(9) = 150 + 121 (9 - 5) + 24 (9 - 5) (9 - 7) + 1(9 - 5) (9 - 7) (9 - 11) = 810

2. Using I) Langranges interpolation and ii) divided difference formula. Find the value of
y when x = 10.
x: 5 6 9 11
y: 12 13 14 16

Lagranges formula

62
Divided difference
x y  2 3
5 12
1
6 13

9 14

11 16

3. If y(1) = -3, y(3) = 9, y(4) =30, y(6) = 132 find the lagranges interpolating polynomial
that takes the same values as y at the given points.
Given:
x 1 3 4 6
y -3 9 30 132

= x3 - 3x2 + 5x - 6

63
4. Find the interpolating polynomial using Newton divided difference formula for the
following data:
x 0 1 2 5
y 2 3 12 147

x y  2 3
0 2
1

1 3 4
9 1
2 12 9
45
5 147

F(x) = 2 + (x - 0)(1) + (x - 0) (x - 1) (4) + (x - 0) (x - 1) (x - 2) 1


= x 3 + x2 - x + 2

Try this
5. Using Lagranges interpolation formula find a polynomial which passes through the
points (0, -12), (1, 0) (3, 6). (4, 12)
Answer: x3 - 7x2 +18x - 12

64

You might also like