5. Calculus

Numerical Integration

Numerical Integration 📘

Imagine you want to know how much water flows into a tank, how far a car travels when its speed keeps changing, or how much money is earned when a company’s sales rate rises and falls during the day. In each case, the total amount depends on a changing rate. That is where numerical integration becomes useful, students. It helps us estimate accumulated change when an exact integral is difficult, impossible, or unnecessary to calculate by hand.

By the end of this lesson, you should be able to:

  • explain the main ideas and terminology behind numerical integration,
  • use common numerical methods to estimate area under a curve,
  • interpret the result in context,
  • connect numerical integration to the broader ideas of calculus,
  • and use technology effectively to support calculations.

Numerical integration is a major part of calculus because it links rate of change to accumulation. In IB Mathematics: Applications and Interpretation SL, the focus is not only on symbolic methods, but also on how mathematics is used in real situations with data, graphs, and technology.

What Numerical Integration Means

In calculus, an integral measures accumulation. If a graph shows a rate, then the area under that graph can represent the total amount collected over time or over distance. For example, if $v(t)$ is velocity, then the integral of $v(t)$ over time gives displacement. If $r(t)$ is the rate of rainfall, then the integral of $r(t)$ over time gives total rainfall. 🌧️

Sometimes we can find an exact integral using formulas and anti-derivatives. But in many real-world situations, the function is known only from a table of values, a graph, or data from a calculator. Then we use numerical integration, which means estimating the value of an integral using geometry and repeated calculations.

A definite integral is written as $\int_a^b f(x)\,dx$. Numerically, this means estimating the area between the curve $y=f(x)$ and the $x$-axis from $x=a$ to $x=b$. When $f(x)$ is positive, that area represents accumulation. If parts of the graph go below the axis, the signed area must be considered.

The key idea is simple: instead of finding one exact curved shape, we approximate it with shapes whose areas are easy to calculate, such as rectangles or trapezia.

Why We Need Approximation Methods

In real life, data are often messy. A weather station might record temperature every hour, a fitness watch might record heart rate every few seconds, and a sensor in a factory might measure flow rate at regular intervals. These values may not fit a simple formula. Even if a formula exists, it may be too complicated for exact integration.

Numerical methods give an estimate that is usually very accurate when the intervals are small. This is why technology is important in this topic. A graphing calculator, spreadsheet, or dynamic mathematics software can process many data points quickly and reduce human error.

The main methods you should know are the trapezoidal rule and, in some contexts, rectangular approximations. The trapezoidal rule is especially important because it is efficient and usually more accurate than using rectangles alone.

The Trapezoidal Rule

The trapezoidal rule estimates the area under a curve by dividing the interval into equal parts and replacing each curved section with a trapezium. If the interval from $a$ to $b$ is divided into $n$ equal subintervals, then the width of each part is $h=\frac{b-a}{n}$.

Suppose the function values are $f(x_0), f(x_1), f(x_2), \dots, f(x_n)$, where $x_0=a$ and $x_n=b$. The trapezoidal rule is:

$$\int_a^b f(x)\,dx \approx \frac{h}{2}\left[f(x_0)+2f(x_1)+2f(x_2)+\cdots+2f(x_{n-1})+f(x_n)\right]$$

This formula works because each interior point is shared by two adjacent trapezia, while the endpoints belong to only one.

Example 1: Using a Table of Values

Suppose the speed of a cyclist, $v(t)$, in metres per second is recorded every second from $t=0$ to $t=4$:

  • $v(0)=2$
  • $v(1)=4$
  • $v(2)=5$
  • $v(3)=6$
  • $v(4)=7$

To estimate the distance travelled from $t=0$ to $t=4$, use the trapezoidal rule with $h=1$:

$$\int_0^4 v(t)\,dt \approx \frac{1}{2}\left[2+2(4)+2(5)+2(6)+7\right]$$

$$=\frac{1}{2}(39)=19.5$$

So the cyclist travels about $19.5$ metres. 🚴

This is a good example of numerical integration in context: the integral gives displacement, and the units must be interpreted carefully. Since speed was measured in $\text{m s}^{-1}$ and time in seconds, the result is in metres.

Interpreting Signed Area and Context

One important idea in calculus is that the integral gives signed area, not just geometric area. If a graph lies above the $x$-axis, the integral is positive. If it lies below the axis, the integral is negative.

This matters in applications. For example, if $v(t)$ is velocity, then a negative value means motion in the opposite direction. The definite integral $\int_a^b v(t)\,dt$ gives net displacement, not total distance.

Example 2: Positive and Negative Values

Imagine a train’s velocity changes so that it is positive for a while and then negative for a short time. If you calculate $\int_0^6 v(t)\,dt$, the result tells you the overall change in position from $t=0$ to $t=6$. The negative part subtracts from the total because it represents movement in the opposite direction.

If you want total distance, you must integrate the speed, which is $|v(t)|$, not the velocity itself. This distinction is very important in IB Mathematics, because interpretation in context is just as important as computation.

Using Technology for Numerical Integration

Technology-supported calculus is a major feature of IB Mathematics: Applications and Interpretation SL. Often, a calculator can estimate integrals directly using built-in commands, but you should still understand the method being used.

For example, a graphing calculator may display a numerical approximation to $\int_a^b f(x)\,dx$ using a trapezoidal algorithm or a similar numerical method. Spreadsheets can also be used by creating columns for $x$ values, $f(x)$ values, and calculating the trapezia one by one.

When using technology, always check:

  • that the interval is correct,
  • that the function is entered accurately,
  • that the units make sense,
  • and that the answer is interpreted in context.

If a calculator gives $12.74$, that number alone is not enough. You must say what it represents. For example, it might be $12.74\,\text{kg}$ of mass accumulated, $12.74\,\text{m}$ of displacement, or $12.74\,\text{cm}^2$ of area, depending on the situation.

Accuracy, Error, and Reasonableness

Numerical integration gives an estimate, not an exact answer. The accuracy depends on how many intervals are used and how smoothly the graph behaves. Smaller subintervals usually give a better approximation. If the graph is curved strongly, a very rough estimate may be far from the true value.

A useful habit is to ask whether the result is reasonable. For instance, if a water tank is filling at around $3\,\text{L min}^{-1}$ for about $10$ minutes, then the total volume should be near $30\,\text{L}$. If the integral estimate gives $300\,\text{L}$, something is probably wrong with the data, units, or method.

This type of checking is important in IB because mathematical modelling is about sensible interpretation, not just pushing buttons on a calculator. ✅

Connection to the Wider Topic of Calculus

Numerical integration connects directly to the central ideas of calculus:

  • differentiation describes instantaneous rate of change,
  • integration describes accumulation,
  • and the two are linked by the Fundamental Theorem of Calculus.

In an ideal situation, if $F'(x)=f(x)$, then $\int_a^b f(x)\,dx=F(b)-F(a)$. But when an exact antiderivative is not practical, numerical integration steps in as a useful alternative.

This connection is powerful in applications and interpretation. For example, if $a(t)$ is acceleration, then integrating gives velocity, and integrating velocity gives displacement. In a data-based situation, each step may need numerical approximation rather than exact symbolic work.

So numerical integration is not separate from calculus. It is one of the main ways calculus is used in the real world, especially when data are discrete rather than continuous.

Conclusion

Numerical integration allows us to estimate accumulation from graphs, tables, and data. The trapezoidal rule is a key method in this topic, and it is especially useful when exact integration is difficult or when values are collected from experiments and technology. students, the most important ideas are area, accumulation, signed area, units, and interpretation in context. Numerical integration is a practical bridge between abstract calculus and real-world problem solving. When used carefully, it turns changing rates into meaningful totals, helping us understand everything from travel and weather to business and science.

Study Notes

  • Numerical integration estimates the value of a definite integral when an exact answer is not available or not needed.
  • The definite integral $\int_a^b f(x)\,dx$ represents accumulated change or signed area.
  • The trapezoidal rule uses trapezia to approximate the area under a curve.
  • If the interval $[a,b]$ is split into $n$ equal parts, then $h=\frac{b-a}{n}$.
  • The trapezoidal rule is $$\int_a^b f(x)\,dx \approx \frac{h}{2}\left[f(x_0)+2f(x_1)+\cdots+2f(x_{n-1})+f(x_n)\right].$$
  • Numerical integration is especially useful with tables, graphs, and real data.
  • The result must be interpreted with units and context.
  • A positive integral means net accumulation above the axis; a negative part subtracts from the total.
  • For velocity $v(t)$, $\int_a^b v(t)\,dt$ gives displacement, while $\int_a^b |v(t)|\,dt$ gives total distance.
  • Technology is important, but the mathematics and interpretation must still be understood clearly.

Practice Quiz

5 questions to test your understanding

Numerical Integration — IB Mathematics Applications And Interpretation SL | A-Warded