Numerical Methods
Adrita Alam
Lecturer,Dept of CSE
Varendra University, Rajshahi
Email: [Link]@[Link]
1
Outline
■ Introduction
■ Approximations and Errors
■ Roots of Equations
■ Systems of linear algebraic equations
■ Curve Fitting
■ Numerical Differentiation and Integration
2
Roots of Equations
3
4
5
6
Bracketing Methods
• Figure 1 illustrates the basic
idea of bracketing method–
that is guessing an interval
containing the root(s) of a
function.
• Starting point of the interval is
a lower bound, 𝑥𝑙. End point of
the interval is an upper bound,
𝑥𝑢.
• By using bracketing methods,
the interval will split into two
subintervals and the size of
the interval is successively
reduced to a smaller interval.
• The subintervals will reduce
the range of intervals until its
distance is less than the
desired accuracy of the
solution
7
Bracketing Methods
8
9
10
11
12
13
Advantages:
• Simple and easy to implement
• One function evaluation per iteration
• The size of the interval containing the zero is reduced by 50% after each
iteration
• The number of iterations can be determined a priori
• No knowledge of the derivative is needed
• The function does not have to be differentiable
Disadvantages:
• Slow to converge
• Good intermediate approximations may be discarded
• We need two initial guesses a and b which bracket the root.
• It is among the slowest methods to find the root.
• When an interval contains more than one root, the bisection method can
find only one of them.
14
Bisection Methods: Class work
• Find the real root of the equation f(x)=x3 – x – 1= 0 correct to 2 decimal places.(ε=0.01).
Answer: 1.328125
• Find the positive root, between 0 and 1, of the equation x = 𝑒 −𝑥 to a tolerance of 0.05%.
Hints:
f(x) = x𝑒 −𝑥 - 1
initial guesses: 0,1
Answer: 0.567 (up to three decimal places)
15
False Position Method or Regular Falsi Method
16
False Position Method or Regular Falsi Method
The equation of the chord joining the two points [a, 𝑓(a)] and [b, 𝑓(b)] if given by –
Let y = 0 be the point of intersection of the chord equation (given above) with the
x-axis.
© 2020, M.T. Özsu & P. Valduriez 17
False Position Method or Regular Falsi Method
© 2020, M.T. Özsu & P. Valduriez 18
19
False Position Method or Regular Falsi Method
Advantages:
• Simple and easy to implement
• Brackets the root
Disadvantages:
• Can be very slow to converge
• Like Bisection, need an initial interval around the root
20