A Rectangle
Mathematics
Calculus
the Rectangle Method
The Rectangle Method is a fundamental technique in numerical analysis used to approximate the definite integral of a function, which represents the total area bounded by the curve of the function and the x-axis.
The core concept relies on slicing the region under the curve into a series of vertical rectangles and summing their individual areas to estimate the total area.
Subdividing the Interval
The total interval \([a, b]\) along the x-axis is divided into \(n\) equal sub-intervals. The width of each rectangle, denoted as \(\Delta x\), is calculated as:
\[\Delta x = \frac{b - a}{n}\]
Determining the Height
The height of each rectangle is determined by evaluating the function \(f(x)\) at a specific sample point \(x_i^*\) within each sub-interval. The three most common variations are:
- Left Endpoint Method: Height is based on the function's value at the left edge of the sub-interval.
- Right Endpoint Method: Height is based on the function's value at the right edge of the sub-interval.
- Midpoint Method: Height is based on the function's value at the exact center of the sub-interval, which typically yields the most accurate approximation of the three.
Calculating the Total Area
The definite integral is approximated by summing the areas (width multiplied by height) of all \(n\) rectangles:
\[\int_{a}^{b} f(x) dx \approx \sum_{i=1}^{n} f(x_i^*) \Delta x\]
General Symbolic Example
Let us approximate the integral of a general function \(f(x)\) over the interval \([a, b]\) using \(n\) rectangles.
- Define Grid Points and Midpoints:
The boundaries of the sub-intervals are denoted by \(x_0, \dots, x_i, \dots, x_n\) with a constant width \(\Delta x = \frac{b-a}{n}\). For each sub-interval \(i\), the sample point \(m_i\) is located exactly at the center of the boundaries:
\[m_i = \frac{x_{i-1} + x_i}{2}\]
- Calculate Individual Rectangle Areas:
The height of each rectangle is determined by evaluating the function exactly at the midpoint \(m_i\).
- Area of Rectangle 1: \(A_1 = f(m_1) \cdot \Delta x\)
- Area of Rectangle 2: \(A_2 = f(m_2) \cdot \Delta x\)
- Area of Rectangle \(n\): \(A_n = f(m_n) \cdot \Delta x\)
- Sum the Areas:
The total approximate integral \(I\) is the sum of all individual areas factored by the constant width \(\Delta x\):
\[\int_{a}^{b} f(x) dx \approx \sum_{i=1}^{n} f(m_i) \Delta x\]
