# Why may geodesic not be the shortest path on a surface?

As said in Geodesic in Wikipedia:

In metric geometry, a geodesic is a curve which is everywhere locally a distance minimizer

but implied that it doesn't have to be the shortest path, so in brief why does it minimize all local distance on its path, but does not minimize the total length? Is that something like greedy algorithm?

• Think about two nearby points on a great circle on a sphere. There are two geodesic joining them and only one of them truely minimize the total length. Sep 13, 2015 at 2:39
• Yes but what's the internal reason of that? It does minimize the local distance, do you mean that the length difference occurred because of the initial direction difference? Sep 13, 2015 at 2:41
• Another example: take two points in a cylinder (one exactly above the other), which has helices, horizontal circles, and vertical lines as geodesics. You can join them by a suitable helix, but the shortest geodesic will be the vertical line segment joining them. Sep 13, 2015 at 2:41
• @IvoTerek: so what does 'locally a distance minimizer' really mean? Sep 13, 2015 at 2:44
• Given a point $p$, there is a neighbourhood of $p$ such that if you go from $p$ to another point $q$ in the neighbourhood by a geodesic which is contained in the neighbourhood, then the geodesic minimizes length over all curves from $p$ to $q$ in the neighbourhood; Sep 13, 2015 at 2:49

## 2 Answers

The point is that local minimization does not imply global minimization. Local minimization says there is no nearby path that is shorter. That does not guarantee that there is no shorter path. Two comments give examples where you can find a local minimum in the sense that no nearby path is shorter, but if you are clever enough to find a very different path you will find it shorter. It is similar to the failures of greedy algorithms. In the path case, we assume that the path we want is reachable with small perturbations of the path we have. The examples show where that is not the case. In failures of a greedy algorithm, early choices constrain the global solution, and a later choice may show that the early choice was not correct.

• As least in Riemannian geometry, local minimization does not mean that there is no nearby path that is shorter. Indeed for the picture in the other answer, there are nearby paths which is shorter than the geodesic passing through the top of the mountain. Indeed in the definition of a geodesic, it is just a critical point. Jun 22, 2020 at 3:22

Attach a image example for the above explanation, The geodesic between A and B longer than the curve from A to B:

• But there is another geodesic from A to B which is the shortest. By eye, it is above the curve you have drawn in the middle, but not too much. You can think about putting a string from A to B along the almost horizontal curve, then pulling on the ends. That will get the locally shortest curve, which will be shorter than the curve over the hump. There might be an even shorter one around the back side, but we can't see what happens there. Jun 21, 2020 at 22:06