$D_f = 0$ on a path connected open set implies $f = const$ Let $U \subseteq \Bbb R^n$ be an open set and let $f:U \to \Bbb R^n$ be a differentiable function. if $U$ is path connected and $D_f=0$ for every point in $U$, show that $f$ is constant ($D_f$ is the differential of $f$). 
I thought about proving that $f$ is locally constant and then showing that if $f$ is locally constant and $U$ is path connected then $f$ is global constant, but it seems like a lot of work. Is there something simpler / shorter? 
 A: Hint: let $\gamma : [0,1] \to U$ be a piecewise linear path between two points $x,y \in U$. Now use the mean value theorem to study the difference
$$f(\gamma(1)) - f(\gamma(0)).$$
A: I just found ashortcut by @Sharkos answer in here : Why does zero derivative imply a function is locally constant?
maybe thats what you looking for. However the standard proof achieved by using mean value theorem.
Let $p,q \in U$. Let $\gamma : [0,1] \rightarrow U$ be a path connecting $p=\gamma(0)$ and $q=\gamma(1)$. We can cover the image $\gamma[0,1]$ by finite number of open balls because $\gamma[0,1]$ compact. I'll leave it to you to show that $f$ is constant on each ball. Because the intersection of these balls is not empty we conclude that $f$ must be the same constant as we move from each ball to the next. After finite steps we conclude that $f(p)=f(q)$. So $f$ is constant on all $U$ $\square$.
$\textbf{EDIT :}$
However, to show that $f$ is constant on each ball use mean value theorem, that is if $\gamma(t) = a + t(b-a)$ is a line segment from $a$ to $b$ on a convex subset $U\subset \mathbb{R}^n$, then there exist $c \in \gamma(t)$ s.t
$$
f(b) -f(a) = Df \cdot (b-a)
$$
By this you must able to show that (by Cauchy-Schwarz ineq.)
$$
\text{if} \quad ||Df|| \leq M \quad \forall x\in U, \text{then} \quad |f(x)-f(y)| \leq M ||x-y|| \quad \forall x,y \in U
$$
and therefore this result you can show that $f$ is constant on the open ball.
