# What is different between Euclidean distance and the Geodesic distance?

We have two kinds of distance in image: Euclidean distance and the Geodesic distance. What is different between them? Could you show mathematic formula or visualization to make it clear? The reference said

Difference between the Euclidean distance and the Geodesic distance calculated with the Fast Marching Method. The Geodesic distance is the distance of the minimum length inside the figure path and the Euclidean distance is the straight line distance

This is example

Simple: the Euclidean distance completely ignores the shape when finding a path from the start point to the end point while, for the geodesic distance, the path is constrained to be within the given shape.

That's why the distances at the bottom left of the figure are so different.

• Great explanation. I cannot upvote your answer because i have not enough score. Could you show to me some math function of geodesic distance? Does it related to gradient image eq. 2? researchgate.net/publication/… Jan 14 '19 at 19:39
• @MoonLee : As the text associated with equation (2) says, (2) is the same as the Euclidean distance of $\gamma = 0$. Otherwise, yes, equation (2) is aimed at finding the geodesic distance.
– Peter K.
Jan 14 '19 at 19:51
• K: I have implemented it but it does not looks likes geodesic distance. It takes image information in count. Jan 14 '19 at 19:58
• @MoonLee: See this answer on SO for some information about how to implement it.
– Peter K.
Jan 14 '19 at 20:03
• Thanks. I understood it. However, what term in the formula (2) shows the curve distance? It is not so clear Jan 16 '19 at 15:02