# How to find a sequence of step functions that converges to $\frac{1}{\sqrt{x}}$?

Definition:Let $v:(a,b)\to\mathbb{R}$. If there exists a partition $P$ of the interval $(a,b)$ such that $v$ is constant in each subinterval of $P$, we say that $v$ is a step function.

Let $u:(0,1)\to\mathbb{R}$ be the function given by $u(x)=1/\sqrt{x}$. I'm trying to find a sequence $u_n:(0,1)\to\mathbb{R}$ of step functions that converges to $u$ almost everywhere.

I think I got a solution for some simplest cases, like $u(x)=x$, $u(x)=2x$, $u(x)=x^2$, by taking $$u_n(x)=\left\{\begin{matrix} u\left(\frac{1}{n}\right) & \text{if }0<x\leq\frac{1}{n}\\ u\left(\frac{2}{n}\right) & \text{if }\frac{1}{n}<x\leq\frac{2}{n}\\ \vdots& \\ u(1) & \text{if }\frac{n-1}{n}<x<1 \end{matrix}\right.$$ But I don't know how to solve the case $u(x)=1/\sqrt{x}$.

Thanks.

Consider the usual step function approach for $\left[\dfrac 1 n,1\right)$, let the step function be $0$ on $(0,n^{-1})$. That is, partition $[n^{-1},1)$ into small segments and take say the $\inf$ of your function to be the constant of the step in the interval. As $n$ grows larger, you will be able to approach $0$ nicely. Rememeber all we want is a pointwise limit. If you want to save some work, you can argue like this. For each $k$, there is a sequence of step functions $s_{k,n}$ that converge to $x^{-1/2}$ on $[k^{-1},1)$. Consider the sequence $t_n=s_{n,n}$ where we define the step to be $0$ where we didn't define it before.

• What's "usual step function"? – Pedro Sep 1 '13 at 21:56
• @Pedro For continuous functions, you can partition your interval regualrly and take the $\inf$ of your function in each interval to define the step function. – Pedro Tamaroff Sep 1 '13 at 21:57
• Let $I_1=(0, n^{-1})$ and $I_k=[(k-1)n^{-1},kn^{-1})$, $k=2,...,n$. You said we can define $$u_n(x)=\left\{\begin{matrix} 0 & \text{if }x\in I_1\\ \inf_{x\in I_2} u(x) & \text{if }x\in I_2\\ \vdots& \\ \inf_{x\in I_n} u(x) & \text{if }x\in I_n \end{matrix}\right.$$ Right? So, if $x\in I_k$ $(k>2)$, then $u_n(x)=u(kn^{-1})=1/\sqrt{kn^{-1}}$ because $u$ is strictly decreasing. Right? Now, how to prove that $|1/\sqrt{kn^{-1}}-1/\sqrt{x}|=|u_n(x)-u(x)|<\varepsilon$? – Pedro Sep 2 '13 at 9:35
• I think a possible answer for my last question is the continuity of $u$ (like you suggested in above comment when said "For continuous functions..."). If possible, let me know if this approach is right. – Pedro Sep 2 '13 at 10:15
• Uniform continuity should be more helpful. – Pedro Tamaroff Sep 2 '13 at 12:42

IMHO, the easiest way is to do something like

$$u_n(x) = \min\left( n, 2^{-n} \Big\lfloor 2^n \frac{1}{\sqrt{x}} \Big\rfloor \right)$$

The use of the factor $2^n$ instead of $n$ make you easier to justify for fixed $x$, your $u_n(x)$ is a monotonic increasing sequence in $n$. The use of $2^{-n} \lfloor 2^{n} \cdots \rfloor$ allow you to conclude for large enough $n$, the difference between $u_n(x)$ and $\frac{1}{\sqrt{x}}$ is bounded by $2^{-n}$ and hence $u_n(x)$ converges pointwise to $\frac{1}{\sqrt{x}}$ for any $x > 0$.