Show that $lim_{n \rightarrow \infty}m(O_n)=m(E)$ when $E$ is compact. Below is an attempt at a proof of the following problem. Any feedback would be greatly appreciated. Thx!

Let $E$ be a set and $O_n = \{x: d(x, E) < \frac{1}{n}\}$.
Show

*

*If $E$ is compact then $m(E) = lim_{n \rightarrow \infty} m(O_n)$.


*This is false for $E$ closed and unbounded or $E$ open and bounded.
Note that all sets are real and measurable refers to Lebesgue measurable.

Suppose $E$ is compact. Then $m(E) < \infty$. Also, since each $O_n$ is an open set of $\mathbb{R}^d$, $m(O_n) < \infty$. If either of the following is true, we have that $lim_{n \rightarrow \infty}m(O_n)=m(E)$:
$O_n \nearrow E$
$O_n \searrow E$
Now  $\bigcap_{n=1}^{\infty} O_n = \{ x:d(x,E) = 0\}$.
That is, $x \in \bigcap_{n=1}^{\infty}O_n \iff \exists n> \frac{1}{\epsilon},\ n \in \mathbb{N} \iff x\in \{x \mid d(x,E) =0\}$.
Then we have that $\bigcap_{n=1}^{\infty}O_n = E$ and $O_n \searrow E$. Thus $ \ m(E) = lim_{n \rightarrow \infty} m(O_n)$.
Suppose $E$ is closed and unbounded. Let $E = \{(x,y): y = 2 \}$ and $O_n = \{(x,y): d(x,E) < \frac{1}{n}\}$.
Since $E$ is a line in $\mathbb{R}^2$, $m(E) = 0$.
Also, since the measure of a rectangle in $\mathbb{R}^d$ is its volume, $m(O_n) = \left| O_n \right| = \infty$, since the rectangle $O_n$ is unbounded.
It is therefore apparent that $m(E) \not = lim_{n \rightarrow \infty} m(O_n)$.
Suppose $E$ is open and bounded.
Let $E=(0,1)$ and $O_n = \{x \mid d(x,E) < \frac{1}{n}\}$.
$\mathbb{R}-E$ is closed and $O_n \in \mathbb{R}-E$.
Since $\mathbb{R}-E$ contains all its limit points $lim_{n \rightarrow \infty}O_n = O \in \mathbb{R}-E$.
Thus $lim_{n \rightarrow \infty} m(O_n) \neq m(E)$.

I refer to your three settings as (1), (2), and (3).
(1) What you write here is confusing. You only have to prove that $\bigcap_nO_n = E$. Clearly, $E\subset\bigcap_nO_n$. Now show that $\bigcap_n O_n\subset E$.
(2) This is a correct counterexample.
(3) The counterexample is false. You have $\bigcap_n O_n = [0,1]$ and thus $\lim m(O_n) = m([0,1]) = m(E) + m(\{0,1\}) = m(E)$. I think that the claim is false anyway. We should have $\lim m(O_n) = m(E)$ for bounded and open $E$.
