# The shortest distance between any two distinct points is the line segment joining them.How can I see why this is true?

On a euclidean plane, the shortest distance between any two distinct points is the line segment joining them. How can I see why this is true?

-
– Austin Mohr Aug 10 '12 at 17:51
The definition of the length of a smooth curve segment as a limit of polygonal approximations easily implies the result. But that is not entirely satisfactory as an explanation. – André Nicolas Aug 10 '12 at 17:58
What do you mean by "shortest distance"? – Qiaochu Yuan Aug 10 '12 at 18:34
When you ask "how can I feel", are you looking for an intuitive grokking of the fact, or do you want a formal proof? In order to give the latter, one needs an explicit definition of what the length of something that is not a line segment is, and the only such definition in general use involves calculus in an essential way. It may be doable to prove without calculus that a line segment has minimal length among all piecewise straight curves joining two points, but then which axioms do you want it proved from? (Euclid seems to take something like this as so obvious it's not even stated). – Henning Makholm Aug 10 '12 at 19:03
When I want to feel this is true I imagine taking a small rubber band and stretching it between the two points. – Rahul Aug 11 '12 at 2:09

Every now and then it's nice to nuke a mosquito.

Let's assume that the path connecting two points $(a,y(a))$ and $(b,y(b))$ can be expressed as a function, and the curve $C(x)$ is given by $C(x) = (x,y(x))$. Then we will proceed using the Calculus of Variations.

The derivative of $C$ wrt $x$ is $(1, y')$, and the functional we want to minimize is the length of the curve $L = \int \|C'\|dx = \int_a^b\sqrt{1 + y' ^2} dx$. If we take $f(x,y,y') = \sqrt{1 + y'^2}$, we get that $\frac{df}{dy} = 0, \frac{df}{dy'} = \frac{y'}{\sqrt{1 + y'^2}}$. Then the Euler-Lagrange equation, sometimes referred to as the fundamental equation of the Calculus of Variations, says exactly that $\dfrac{d}{dx} \left( \frac{y'}{\sqrt{1 + y'^2}}\right) = 0$, which is exactly that $y'$ is a constant.

Thus, if the path connecting the two points is expressible as a function, then the shortest such path is given by a straight line.

EDIT I was certain that someone was in the middle of writing an answer when I typed my tongue-in-cheek response (as so often happens), but as I now see that there is more to add, allow me to extend my answer

The problem here is that we must first define "distance." In the standard Euclidean Plane, the distance between two points is defined to be the length of the line segment between them. So we can drop the word 'shortest' and say that "The distance between any two distant points is the length of the line segment joining them."

Presumably, you want to know that going along any other path will be at least as long. One way of 'seeing this' is that you can approximate any curve with a polygonal path, and these satisfy the triangle inequality, which will make the path longer.

-
+1 for "nuke a mosquito". – user22805 Aug 10 '12 at 22:54
When I saw the question, I just knew somebody would post the variational route... :) – J. M. Aug 11 '12 at 1:07
@J.M. I never knew about \| - that's one of those little things. Thanks for that! – mixedmath Aug 11 '12 at 1:12
Yeah, it looks nicer than just abutting two pipe characters, no? :) – J. M. Aug 11 '12 at 1:14

Let $\gamma(s)$ be a continuous curve in the plane with end-points $\gamma(0) = a$ and $\gamma(1) = b$. Using the Euler-Lagrange equations, the only stationary solution is $\gamma(s) = bs + (1 - s)a$, which is a line connecting the two end-points. See also this.

-
I have found explanations. – ReekMaths Jan 25 '13 at 18:43
Thank you for all these helps. – ReekMaths Jan 26 '13 at 20:32

Here's my self-contained solution, which does not make the unnecessary assumption that the path is a function. It also does not assume previous knowledge of the Euler-Lagrange equation.

To do this, I reformulate this as a physics problem:
We know that light always takes the fastest path between two points.
If we assume the speed of light is constant, then the fastest is the same as the shortest path, and the two problems become equivalent.
Therefore, we ask: what would be the trajectory of a beam of light from $\vec{p}_1$ to $\vec{p}_2$?

If we call this trajectory $\vec{r}(t)$, initially, we may intuitively desire to make a statement such as: \begin{align*} \frac{d}{d\vec{r}} \operatorname{Length}(\vec{r}) = 0 \end{align*} This statement is clearly wrong, but close to correct.
The correct formulation requires indirect thinking and the introduction of an auxiliary variable, $\epsilon$.

### Key observations:

1. If $\vec{p}$ is the shortest path, and if $\vec{\delta} = \vec{r} - \vec{p}$ is the deviation of $\vec{r}$ from $\vec{p}$ for some arbitrary real number $\epsilon$, then to show that $\vec{p}(t)$ is a line, it suffices to show $\ddot{\vec{p}}(t) = \vec{0}$.

2. If we "nudge" the shortest path by some small constant multiple $\epsilon$ of $\vec{\delta}$, the path cannot become shorter (by definition). Therefore, the rate of change of the length of the shortest path with respect to $\epsilon$ is zero when $\epsilon = 0$.

Make sure you understand the intuition behind why these are true before continuing.

\begin{align*} \frac{d}{d\epsilon} \left.\operatorname{Length}(\vec{p} + \epsilon\,\vec{\delta})\right|_{\epsilon=0} &= 0 && \text{(since $\vec{p} + \epsilon\,\vec{\delta}$ is a minimizer when $\epsilon = 0$)} \\ \frac{d}{d\epsilon} \left.\int_{t_1}^{t_2} \sqrt{\lVert{\dot{\vec{p}}(t) + \epsilon\,\dot{\vec{\delta}}(t)}\rVert^2}\,dt\right|_{\epsilon=0} &= 0 && \text{(definition of arc length)} \\ \int_{t_1}^{t_2} \frac{d}{d\epsilon} \left.\sqrt{\lVert{\dot{\vec{p}}(t) + \epsilon\,\dot{\vec{\delta}}(t)}\rVert^2}\right|_{\epsilon=0}\,dt &= 0 \\ \int_{t_1}^{t_2} \dot{\vec{\delta}}(t) \cdot \left.\frac{2(\dot{\vec{p}}(t) + \epsilon\,\dot{\vec{\delta}}(t))}{2\lVert{\dot{\vec{p}}(t) + \epsilon\,\dot{\vec{\delta}}(t)}\rVert}\right|_{\epsilon=0}\,dt &= 0 \\ \int_{t_1}^{t_2} \dot{\vec{\delta}}(t) \cdot \frac{\dot{\vec{p}}(t)}{\lVert{\dot{\vec{p}}(t)\rVert}} \,dt &= 0 && \text{(evaluate at $\epsilon = 0$)} \\ \frac{1}{\Vert{\dot{\vec{p}}}\rVert}\int_{t_1}^{t_2} \dot{\vec{\delta}}(t) \cdot \dot{\vec{p}}(t) \,dt &= 0 && \text{($\Vert{\dot{\vec{p}}}\rVert$ is constant)} \\ {\left.\vec{\delta}(t) \cdot \frac{\dot{\vec{p}}(t)}{\lVert{\dot{\vec{p}}(t)\rVert}}\right|_{t_1}^{t_2}} - \frac{1}{\Vert{\dot{\vec{p}}}\rVert}\int_{t_1}^{t_2} \vec{\delta}(t) \cdot \ddot{\vec{p}}(t) \,dt &= 0 && \text{(integrate by parts; note that $\vec{\delta}(t_1) = \vec{\delta}(t_2) = \vec{0}$)} \\ - \frac{1}{\Vert{\dot{\vec{p}}}\rVert}\int_{t_1}^{t_2} \vec{\delta}(t) \cdot \ddot{\vec{p}}(t) \,dt &= 0 && \text{(left part is zero because the endpoints must match)} \\ \therefore\ \ \ \forall t \in [t_1, t_2]\ \ \ \ \ddot{\vec{p}}(t) &= \vec{0} && \text{(since $\vec{\delta}$ could be zero throughout any parts of $\vec{p}$)} \end{align*}

-