Skip to content

Latest commit

 

History

History
44 lines (27 loc) · 1.05 KB

README.md

File metadata and controls

44 lines (27 loc) · 1.05 KB

Riemann Sum

Integral approximation using Riemann sum



Installation

git clone https://github.com/CodePleaseRun/riemann-sum.git
cd riemann-sum

Dependencies:

  • matplotlib
  • numpy
  • sympy

Usage

python main.py

Points to be noted

  • To be specific, the program is calculating Left Riemann sum. If the function f(x) is assumed to be a smooth function, all three Riemann sums (Left, Right, Middle) will converge to the same value as the number of subdivisions goes to infinity.
  • Left Limit & Right Limit are evaluated first. That means input like gamma(3), exp(2) will be evaluated and converted to float before being used.
  • The Points input determines the smoothness of the the function f(x). It is independent from the number of subdivisions used for calculating Riemann sum.

Licence

MIT