[Math] The shortest path connecting three points

calculusgeometrygraph theorylagrange multipliermultivariable-calculus

I have 3 points X,Y,Z, lets call them buildings.

I need to find the shortest amount of path that connects the 3 buildings, these buildings can be in any sort of shape and any distance from each other, lets call the distance between each building xy, xz, yz.

I know that the paths need to converge at a point, but I am unsure how to get there given the information I have.

If they formed an equilateral triangle it would look like (or at least I think):

    X
    |           
   / \
  Y   Z

But they can be in any shape and that's only one of them, I need help finding the equation(s) that will give the shortest path connecting all 3 of the buildings.

I was thinking of using the Pythagorean Theorem but am not 100% sure, I was also thinking about using Lagrange Multipliers but with the information given am not sure how to implement them.

I'm just looking for a push in the right direction, I don't need the full solution (it would help but not needed.) If you need any more information about the problem I can try my best but this is about all I have.

Best Answer

I believe that Napoleon (himself!) was interested in this problem.

Distinguish between two cases.

  1. If the given triangle has an angle that exceeds ${2\pi}\over 3$, then that particular vertex itself is the point you seek. In this case, the sought-after minimum total distance is comprised of the two shortest sides.

  2. OTHERWISE, the point can be constructed as follows: On each of the three sides, construct an outward-pointing equilateral triangle. Connect each outward point with the opposing vertex of the original triangle. The three connecting lines are concurrent, and their common point (the Fermat point, or the first isogonal center of the triangle) is the point you seek. Lines drawn from this point to the three original vertices are the paths whose total length constitutes the sought-after minimum total distance.

Related Question