# Question on the Construction of the Integral in Measure Theory

I am self-studying measure theory, and I got some trouble understanding the construction of the integral. Here is the first two stages of the construction:

Stage 1$$\quad$$ We begin with the simple function. Let $$(X,\mathscr{A})$$ be a measurable space. We will denote by $$\mathscr{S}$$ the collection of all simple real-valued $$\mathscr{A}$$-measurable functions on $$X$$ and by $$\mathscr{S}_+$$ the collection of nonnegative functions in $$\mathscr{S}$$.

Let $$\mu$$ be a measure on $$(X,\mathscr{A})$$. If $$f$$ belongs to $$\mathscr{S}_+$$ and is given by $$f = \sum_{i=1}^ma_i\chi_{A_i}$$ where $$a_1,\dots,a_m$$ are nonnegative real numbers and $$A_1,\dots,A_m$$ are disjoint subsets of $$X$$ that belong to $$\mathscr{A}$$, then $$\int f d\mu$$, the integral of $$f$$ with respect to $$\mu$$, is defined to be $$\sum_{i=1}^ma_i\mu(A_i)$$ (note that this sum is either a nonnegative real number or $$+\infty$$).

Stage 2$$\quad$$ As our next step, we define the integral of an arbitrary $$[0,+\infty]$$-valued $$\mathscr{A}$$-measurable function on $$X$$. For such a function $$f$$, let \begin{align*} \int fd\mu = \sup\left\{\int gd\mu:g\in\mathscr{S}_+\ \text{and}\ g\leq f\right\}.\tag1 \end{align*}

(There is a final stage 3, but my problem is with the stage 2.)

My question is this: How is the equation (1) compatible with the summation definition of $$f$$ in Stage 1?

I can see that, if $$f$$ and $$g$$ both belong to $$\mathscr{S}_+$$ and if $$f(x)\leq g(x)$$ holds at each $$x$$ in $$X$$, then $$\int fd\mu \leq \int gd\mu$$. But I am not quite sure how the two definitions agree with each other. Could someone please help me out? Thanks a lot in advance!

Reference: Measure Theory by Donald Cohn page 55.

• Definition in summation notation is defined only for non-negative real valued simple functions. Definition in $(1)$ is general non-negative measurable functions. See that simple functions are measurable and that definition in summation is included in the definition in $(1)$. Apr 15 at 17:35
• Just an informal hint: Please try to draw graphs of simple functions and try to understand and figure what these expressions in summation actually mean in the graphs. That way you will get a clear idea of the machinery behind the symbols. Even my professor encouraged the students to do the same to gain a proper insight into what was happening. Apr 15 at 17:39