Numerical Methods Lab

Some necessary programs in C programming Language

[Reader can use these programs in any types of C or C++ compiler. These may not be applicable in every situation but reader use it by adopting need based modification. Some compiler may give errors which may arise in the form of void main(), getch(), clrscr(), library <conio.h> etc.]

General Programs (PDF)

  1. Prime numbers between two natural numbers

  2. Sorting some given numbers are in ascending order

  3. Sorting some given numbers are in descending order

  4. Solutions of Quadratic equations

  5. Find the area of a triangle when sides are given

  6. Calculate the value of log(1+x), base e & -1 < x < =1

  7. Find the value of Cos(x) when x is given in RAD (For Beginner-Type-I , Advanced-Type-II)

  8. Find the value of Sin(x) when x is given in RAD (For Beginner-Type-I , Advanced-Type-II)

Real Root Findings (Equation) (PDF)

  1. Newton-Raphson method ( For Beginner-Type-I , Advanced-Type-II )

  2. Bisection Method

  3. Fixed-point Iteration Method

  4. Regula-falsi Method

  5. Secant Method

Numerical Integration (PDF)

  1. Integration of given function with limit by Trapezoidal rule

  2. Integration of given function with limit by Simpson's 1/3 rule

  3. Gauss Quadrature Integration (Four points)

  4. Integration by Weddle's rule

Interpolation (PDF)

  1. Newton Forward Interpolation

  2. Newton Backward Interpolation

  3. Lagrange Interpolation

Numerical Solutions of Ordinary Differential Equations

  1. Euler's method

  2. Modified Euler's method

  3. Runge-Kutta method

Matrix Related (PDF)

  1. Addition of two matrices

  2. Multiplication of two matrices

  3. Gauss's elimination method

  4. Gauss-Jacobi Method

  5. Gauss-Seidel Method

  6. Gauss-Jordan Method

  7. LU factorization method

  8. Inverse of a square matrix

Numerical Method for Finding Largest Eigen value & Eigen Vector

  1. Power method for finding largest eigen value & corresponding vector