Using the concept of integration, we can define the mean or the average value of a function defined on a particular domain. Suppose that we have a real-valued function f(x) defined on an interval [a,b] then the mean/average value of the function can be calculated using the formula:

\text{Average Value } = \frac{1}{b-a} \int_{a}^{b} f(x) dxIf f(x) is taken to be a step function with each “step” having the same width then the average value calculated using the above formula coincides with the simple arithmetic mean of the values taken by the function.

**Example 1:**

Consider the following step function defined on the domain [0,3] :

f(x) = \begin{cases} 1 & 0\leq x\leq 1 \\ 2 & 1\leq x\leq 2 \\ 3 & 2\leq x\leq 3 \end{cases}We calculate the mean/average value of the function using the above formula,

\text{Average Value } = \frac{1}{b-a} \int_{a}^{b} f(x) dx = \frac{1}{3-0} \int_{0}^{3} f(x) dx \text{Average Value } = \frac{1}{3} [\int_{0}^{1} 1 dx+ \int_{1}^{2} 2 dx + \int_{2}^{3} 3 dx] \text{Average Value } = \frac{1}{3} \{ [x]_{0}^{1} + [2x]_{1}^{2}+ [3x]_{2}^{3} \} \text{Average Value } = \frac{1 +2 + 3}{3} = 2As remarked earlier, the mean value of a step function with each step having equal width has an average value equal to the arithmetic mean of the value taken by the function.

**Example 2: **

Consider the function f(x) = x^2 defined on the domain [0,3] :

We calculate the mean/average value of the function using the formula,

\text{Average Value } = \frac{1}{b-a} \int_{a}^{b} f(x) dx = \frac{1}{3-0} \int_{0}^{3} x^2 dx \text{Average Value } = \frac{1}{3}[\frac{x^3}{3}]_0^3 = \frac{27}{9} = 3