# Why is this inequality for supremum true?

Suppose I have a RCLL martingale $M_t$, then Doob says

$$E[\sup_{0\le t\le T}|M_t|^2]\le \text{const.}\, E[|M_T|^2]$$

Suppose the latter is finite. How can I deduce from there, that $E[(\sup_{0\le t \le T}|M_t|)^2]<\infty$. I know the following:

$$E[\sup_{0\le t\le T}|M_t|^2]\le E[\sup_t|M_t|\sup_t|M_t|]=E[(\sup_{0\le t \le T}|M_t|)^2]$$

But I want the reverse inequality, i.e. I want $E[(\sup_{0\le t \le T}|M_t|)^2]$ bound with $E[\sup_{0\le t\le T}|M_t|^2]$.

-
For any set $X$ and any non-negative function $f:X\to\Bbb R$ it holds that $$\sup_X f^2 = (\sup_X f)^2$$ since $f\mapsto f^2$ is strictly monotonic on $[0,\infty)$ –  Ilya Jan 18 '13 at 9:37
@Ilya Can you give me a proof of that statement? One direction I already proved –  user20869 Jan 18 '13 at 9:49

Let $X$ be some set and let $f:X\to\Bbb R_+$ be some function. Let $a = \sup_X f(x)$, then there exists a sequence $(x_n)$ such that $\lim_n f(x_n) = a$. In that case $$\left(\sup_X f(x)\right)^2 = \left(\lim_nf(x_n)\right)^2 = \lim_n f^2(x_n)\leq\sup_Xf^2(x)$$