Doubts on application of continuity definition and Dominated Convergence theorem I quote Øksendal (2003).

Let $\mathcal{V}=\mathcal{V}(S,T)$ be the class of functions $f(t,\omega):[0,\infty)\times\Omega\to\mathbb{R}$ such that $(t,\omega)\to f(t,\omega)$ is $\mathcal{B}\times\mathcal{F}$-measurable (where $\mathcal{B}$ denotes the Borel $\sigma$-algebra on $[0,\infty)$), $f(t,\omega)$ is $\mathcal{F}_t$-adapted and $\mathbb{E}\bigg[\int_{S}^T f(t,\omega)^2 dt\bigg]<\infty$. [...]
Recall that a function $\phi\in\mathcal{V}$ is called elementary if it has the form $$\phi(t,\omega)=\sum_j e_j(\omega)\cdot\chi_{[t_j, t_{j+1}]}(t)\tag{1}$$ [...]

Statement Let $g\in\mathcal{V}$ be bounded and $g(\cdot,\omega)$ continuous for each $\omega$. Then there exists elementary functions $\phi_n\in\mathcal{V}$ such that
$$\mathbb{E}\left[\int_S^T\left(g-\phi_n\right)^2dt\right]\to 0\hspace{1.5cm}\text{as }n\to\infty\tag{2}$$
Proof Define $\phi_n(t,\omega)=\sum_j g(t_j,\omega)\cdot\chi_{[t_j,t_{j+1})}(t)$. Then, $\phi_n$ is elementary since $g\in\mathcal{V}$, and $$\int_S^T(g-\phi_n)^2dt\to0\hspace{1.5cm}\text{as }n\to\infty\text{ for each }\omega$$
since $g(\cdot,\omega)$ is continuous for each $\omega$. Hence $\mathbb{E}\left[\int_S^T(g-\phi_n)^2dt\right]\to0$ as $n\to\infty$ by bounded convergence.



My questions:

*

*Why does definition of continuity of $g(\cdot,\omega)$ imply that $$\displaystyle{\int_S^T(g-\phi_n)^2dt}\to0\hspace{1.5cm}\text{as }n\to\infty\text{ for each }\omega\hspace{3.5cm}\text{?}$$


My interpretation: I think I am allowed to conceive $\phi_n$ as a kind of step-function, whose value at time $t_n$ corresponds to the value of the continous and bounded function $g$ at time $t_n$. Does that mean that if I shrink the differential of time $[t_j,t_{j+1})$, continuity of $g$ implies that $|g-\phi_n|<\varepsilon\text{ for }|t_j-t_{j-1}|<\delta$ (which implies that $\displaystyle{\int_S^T(g-\phi_n)^2dt}\to0\hspace{0.5cm}\text{as }n\to\infty\text{ for each }\omega$)?



*In the end, is Lebesgue's dominated convergence theorem applied? If so, why does it lead from $$\displaystyle{\int_S^T(g-\phi_n)^2dt}\to0\hspace{1cm}\text{as }n\to\infty\text{ for each }\omega$$ to $$\mathbb{E}\left[\displaystyle{\int_S^T(g-\phi_n)^2dt}\right]\to0\hspace{2.3cm}\text{as }n\to\infty\text{ for each }\omega\hspace{1.8cm}\text{ ?}$$


My interpretation: What I think is that one could set $X_n=(t_{j+1}-t_j)$ and $Y_n=\displaystyle{\int_S^T(g-\phi_n(t,\omega))^2}$, which - as seen in my interpretation in point $1.$ - since $g$ is continuous, by definition of continuity, is such that for every $t$, $|Y_n|<\epsilon$ whenever $|X_n|<\delta$. In other words, $$g=\lim_{n\to\infty}\phi_n(t,\omega)\hspace{0.5cm}\text{ pointwise}\tag{3}$$ implies that $$0=\lim_{n\to\infty}\int_S^T(g-\phi_n(t,\omega))^2dt\hspace{0.5cm}\text{ pointwise}\tag{4}$$
Hence, given the immediately above explained conditions:

*

*$|Y_n|<\epsilon\text{ for every }t$ (namely, "boundedness"), whenever $|X_n|<\delta$;

*$0=\lim\limits_{n\to\infty}\displaystyle{\int_S^T(g-\phi_n(t,\omega))^2dt}\hspace{0.5cm}\text{ pointwise}$ (namely, "pointwise convergence")
one could apply Lebesgue's dominated convergence theorem:
$$\lim_{n\to\infty}\mathbb{E}\left(Y_n\right)=\mathbb{E}\left(\lim_{n\to\infty}Y_n\right)=\mathbb{E}\left(0\right)=0$$



Are my interpretations of points $1.$ and $2.$ correct? If not, why?
 A: *

*Yes, your reasoning is correct.
For a fixed $\omega$, $g(t,\omega)$ is a continuous function of $t$. This means it is uniformly continuous (in $t$) on the compact interval $[S,T]$. Hence, for any given $\epsilon > 0$, we can find $\delta >0$ such that
$$
 |g(s, \omega) - g(t,\omega)| < \epsilon \quad \forall s, t \in [S,T]: |s-t| < \delta. 
$$
Now choose a $\epsilon > 0$ as above, and a time spacing
$$
S = t_0 < t_1 \ldots < t_n = T,
$$
where max $|t_i - t_{i+1}| < \delta$.
On the every interval $[t_i, t_{i+1})$ we have
$$
|g(t, \omega) - \phi_n(t,\omega)| = |g(t, \omega) - \phi_n(t_i,\omega)| =
|g(t, \omega) - g(t_i,\omega)|< \epsilon.
$$
So
$$
 \int_S^T |g(t, \omega) - \phi_n(t,\omega)|^2 \,dt < \epsilon^2 \cdot (T-S).
$$
Since epsilon was arbitrary, the integral can be made arbitrarily small by making the maximum grid spacing, max $|t_i - t_{i+1}|$, small enough.
You don't write what the $n$ in your functions $\phi_n$ stands for, but I assume it means the grid spacing goes to zero when $n \to \infty$.


*Yes, here the Lebesgue dominated convergence theorem can be applied.
First you have to check that the integrand is uniformly bounded by an integrable function for all $n$. This follows from the previous point (EDIT: This is wrong, as forgottenarow below points out. You als need to use the boundedness of $g$ here. The subtle point here is that the n typically depends on $\omega$).
The integrand can be made smaller than $\epsilon^2$ if the grid is fine enough. This is of course an integrable function, since we consider a finite interval.
Also, for each $\omega$, you have pointwise convergence of $\phi_n(t, \omega)$ to $g(t, \omega)$ when $n\to\infty$ according to (1) (you even have uniform convergence).
So the conditions for the LDK theorem is fulfilled and you are allowed to put the limit inside the integral.  So
$$
 \lim_{n \to \infty}\int_S^T |g(t, \omega) - \phi_n(t,\omega)|^2 \,dt 
= \int_S^T  \lim_{n \to \infty} |g(t, \omega) - \phi_n(t,\omega)|^2 \,dt = 
\int_S^T 0 dt = 0.
$$
Regarding the expectation, you can put the limit inside by the same type of reasoning:
Let $\mathbb{P}$ be the probability measure in which we take the expectation.
$$
\begin{eqnarray*}
\mathbb{E} \left[ \int_S^T |g(t, \omega) - \phi_n(t,\omega)|^2 \,dt \right] =
\int \left( \int_S^T |g(t, \omega) - \phi_n(t,\omega)|^2 \,dt \right) d \mathbb{P}(\omega)
\end{eqnarray*}
$$
For any $\epsilon$ and $n$ large enough the inner integrand is bounded by $\epsilon^2$ according to 1. And, as I mentioned above, this means it is uniformly bounded for all $n$ by the integrable function $\epsilon^2$.
This function is integrable since
$$
\int \left( \int_S^T \epsilon^2 \,dt \right) d \mathbb{P}(\omega) = (T-S)\epsilon^2 \cdot \int d\mathbb{P(\omega)} = (T-S)\epsilon^2,
$$
since the total mass of a probability measure is $1$.
Hence the conditions for LDK is fulfilled and you can put the limit inside the double integral and get $0$ in the limit as $n \to \infty$ as before.
A: Note that $g$ is assumed to be bounded, so there exists some $M < \infty $ such that $\sup_{t \in [S,T]} |g(t,\omega)| < M$ for almost surely all $\omega$. Furthermore, by definition of $\phi_n$, $\sup_{n \in \mathbb{N}}\sup_{t \in [S,T]} |\phi_n(t,\omega)| < M.$

*

*The almost sure continuity of $g$ ensures that $|g(t,\omega) - \phi_n(t,\omega)|^2 \to 0$ for all $t$ for almost surely all $\omega$. By boundedness, $\sup_t |g(t,\omega) - \phi_n(t,\omega)|^2 \leq 4M^2 < \infty$. So by bounded convergence,

$$\int_S^T|g(t,\omega) - \phi_n(t,\omega)|^2\,dt \to 0 \text{ for almost surely all } \omega\in \Omega. $$


*Since $\sup_t |g(t,\omega) - \phi_n(t,\omega)|^2 \leq 4M^2$ almost surely, it follows that,

$$\int_S^T|g(t,\omega) - \phi_n(t,\omega)|^2\,dt < \int_S^T 4M^2\,dt = 4M^2(T-S)<\infty \text{ for almost surely all } \omega \in \Omega.$$
So we can apply bounded convergence again to get,
$$\lim_{n\to\infty}\mathbb{E}\left[\int_S^T|g(t,\omega) - \phi_n(t,\omega)|^2\,dt\right] = \mathbb{E}\left[\lim_{n\to\infty}\int_S^T|g(t,\omega) - \phi_n(t,\omega)|^2\,dt\right] = 0.$$
