Numerical Methods – Detailed Notes
with Examples
1. Methods for Non-Linear Equations
Bisection Method
Used to find the root of a function in a given interval [a, b] where f(a)f(b)<0. Example:
Find root of f(x)=x^3−x−2 between x=1 and x=2.
Newton-Raphson Method
Uses tangents to find roots. Formula: xₙ₊₁ = xₙ - f(xₙ)/f'(xₙ). Example:
Find root of f(x)=x^2−2 using x₀=1.
Fixed Point Method
Converts equation to x=g(x) and iterates. Example:
For x = cos(x), iterate xₙ₊₁ = cos(xₙ).
Regula Falsi Method
Similar to bisection but uses a secant line. Example:
Find root of f(x)=x^3−x−2 between 1 and 2.
Secant Method
Like Newton-Raphson but without derivative. Uses two initial guesses. Formula: xₙ₊₁ = xₙ -
f(xₙ)*(xₙ - xₙ₋₁)/(f(xₙ) - f(xₙ₋₁)).
2. Numerical Integration
Trapezoidal Rule
Approximates area using trapezoids. Formula: (h/2)[f(a)+2f(x₁)+...+2f(xₙ₋₁)+f(b)].
Example:
Integrate f(x)=x^2 from 0 to 2.
Simpson's 1/3 Rule
Uses parabolic segments. Formula: (h/3)[f(a)+4f(x₁)+2f(x₂)+...+f(b)]. Requires even number
of intervals.
Simpson's 3/8 Rule
Uses cubic interpolation. Formula: (3h/8)[f(x₀)+3f(x₁)+3f(x₂)+f(x₃)] etc. Works well for
multiples of 3 intervals.
3. Numerical Methods for ODEs
Euler Method
Simple approximation method for dy/dx = f(x, y). Formula: yₙ₊₁ = yₙ + h*f(xₙ, yₙ). Example:
Solve dy/dx = x + y, y(0) = 1 using h=0.1.
Runge-Kutta Method (RK4)
More accurate than Euler. Formula involves intermediate slopes (k1, k2, k3, k4). Example:
Solve dy/dx = x + y with y(0) = 1 using h = 0.1.