Find the upper derivative and lower derivatives $\overline{D}\mu$ and $\underline{D}\mu$. Here is an exercise from Cohn's Measure Theory that I don't believe I've done correctly:

Let $I$ be the line segment in $\mathbb{R}^2$ that connects the points $(0,0)$ and $(1,1)$. Define a finite Borel measure $\mu$ on $\mathbb{R}^2$ by letting $\mu(A)$ be the one-dimensional Lebesgue measure of $A \cap I$. (More precisely, let $T$ be the map of the interval $[0, \sqrt{2}]$ onto $I$ given by $T(t) = (t/\sqrt{2})(1,1)$, and define $\mu$ by $\mu(A) = \lambda(T^{-1}(A)).)$ Find the upper derivative and lower derivatives $\overline{D}\mu$ and $\underline{D}\mu$.


Well, let's write down these definitions first:
$$(\overline{D}\mu)(x) = \limsup_{\epsilon \to 0+}\left\{ \frac{\mu(C)}{\lambda(C)}: C \in \mathscr{C}, x \in C, \text{ and } e(C) < \epsilon \right\}$$
and
$$(\underline{D}\mu)(x) = \liminf_{\epsilon \to 0+}\left\{ \frac{\mu(C)}{\lambda(C)}: C \in \mathscr{C}, x \in C, \text{ and } e(C) < \epsilon \right\},$$
where $\mathscr{C}$ is the family of nondegenerate closed squares in $\mathbb{R}^2$ (with sides parallel to the coordinate axes) and $e(C)$ is the edge length of $C \in \mathscr{C}$ (and I am assuming that, here, $\lambda$ is Lebesgue measure on $\mathbb{R}^2$, despite the use of the same notation for the Lebesgue measure on $\mathbb{R}$).
Clearly, if $x \notin I$ then $(\overline{D}\mu)(x) = 0 = (\underline{D}\mu)(x)$.
If $x \in I$ then, for each $C \in \mathscr{C}$ such that $x \in C$, we have that
$$\frac{\mu(C)}{\lambda(C)} = \frac{\lambda(T^{-1}(C))}{\lambda(C)} = \frac{\sqrt{2}e(C)}{(e(C))^2} = \frac{\sqrt{2}}{e(C)}. $$
So, for a fixed $x \in I$ and for each $\epsilon >0$, we'll define the set $E_\epsilon$ as follows:
$$ E_\epsilon = \left\{ \frac{\mu(C)}{\lambda(C)}: C \in \mathscr{C}, x \in C, e(C) < \epsilon \right\} = \left\{ \frac{\sqrt{2}}{e(C)}: C \in \mathscr{C}, x \in C, e(C) < \epsilon \right\}. $$
Since $e(C) < \epsilon$, for each $\sqrt{2}/e(C) \in E_\epsilon$, it follows that
$$\frac{1}{\epsilon} < \frac{\sqrt{2}}{e(C)}, $$
for each $\sqrt{2}/e(C) \in E_\epsilon$; and since $e(C)$ can be made arbitrary small, it follows that
$$ \sup\{E_\epsilon: \epsilon > 0\} = \infty. $$
Thus, the function $f(\epsilon) = \sup\{E_\epsilon: \epsilon > 0\}$ clearly tends to $\infty$ as $\epsilon \to 0$. So (I guess?) $(\overline{D}\mu)(x) = \infty$ if $x \in I$ and $(\overline{D}\mu)(x) = 0$ if $x \notin I$... which doesn't seem right.
Similarly, the function $g(\epsilon) = \inf\{E_\epsilon : \epsilon > 0\}$ is bounded from below by $1/\epsilon$, and $1/\epsilon$ increases without bound as $\epsilon \to 0$. Thus, $g(\epsilon) \to \infty$ as $\epsilon \to 0$, as well. So $\overline{D}\mu = \underline{D}\mu$. Again, this doesn't seem right...
 A: I think your approach is correct. Here is my way of doing this. I'll skip some steps for some details.
First, I extend the definitions:
$$(\overline{D}\mu)(x,y)=\overline{\lim_{r\to 0}}\frac{\mu\left(\overline{B_r(x,y)}\right)}{\lambda\left(\overline{B_r(x,y)}\right)}$$
Similarly,
$$(\underline{D}\mu)(x,y)=\underline{\lim_{r\to 0}}\frac{\mu\left(\overline{B_r(x,y)}\right)}{\lambda\left(\overline{B_r(x,y)}\right)}$$
Case 1: If $(x,y)\notin I$, we can choose $r>0$ sufficiently small such that $\overline{B_r(x,y)}\cap I=\emptyset$. The reason is because $I$ is closed, so its complement is open in $\mathbb{R}^2$. So for sufficiently small $r>0$,
$$\lim_{r\to 0}\frac{\mu\left(\overline{B_r(x,y)}\right)}{\lambda\left(\overline{B_r(x,y)}\right)}=\lim_{r\to 0}\frac{0}{\pi r^2}=0$$
which implies $(\overline{D}\mu)(x,y)=(\underline{D}\mu)(x,y)=0$.
Case 2: If $(x,y)\in I$, then $x=y$. Assume that $(x,x)\neq(0,0)\neq(1,1)$. For sufficiently small $r>0$, $\overline{B_r(x,y)}\cap I$ is part of line segment $I$, of length  $2r$. Therefore,
$$\lim_{r\to 0}\frac{\mu\left(\overline{B_r(x,y)}\right)}{\lambda\left(\overline{B_r(x,y)}\right)}=\lim_{r\to 0}\frac{2r}{\pi r^2}=+\infty$$
which implies $(\overline{D}\mu)(x,y)=(\underline{D}\mu)(x,y)=+\infty$.
Case 3: When $(x,x)=(0,0)$ or $(1,1)$, for sufficiently small $r>0$, $\overline{B_r(x,y)}\cap I$ is part of line segment $I$, of length  $r$. Therefore,
$$\lim_{r\to 0}\frac{\mu\left(\overline{B_r(x,y)}\right)}{\lambda\left(\overline{B_r(x,y)}\right)}=\lim_{r\to 0}\frac{r}{\pi r^2}=+\infty$$
The result is: $(\overline{D}\mu)(x)=(\underline{D}\mu)(x)=0$ if $(x,y)\notin I$ and $(\overline{D}\mu)(x)=(\underline{D}\mu)(x)=+\infty$ if $(x,y)\in I$.
