Lagrangian:
![L(x,y,z,\lambda)=x^2+(y-2)^2+(z-5)^2+\lambda(x-2y+3z-6)](https://tex.z-dn.net/?f=L%28x%2Cy%2Cz%2C%5Clambda%29%3Dx%5E2%2B%28y-2%29%5E2%2B%28z-5%29%5E2%2B%5Clambda%28x-2y%2B3z-6%29)
where the function we want to minimize is actually
![\sqrt{x^2+(y-2)^2+(z-5)^2}](https://tex.z-dn.net/?f=%5Csqrt%7Bx%5E2%2B%28y-2%29%5E2%2B%28z-5%29%5E2%7D)
, but it's easy to see that
![\sqrt{f(\mathbf x)}](https://tex.z-dn.net/?f=%5Csqrt%7Bf%28%5Cmathbf%20x%29%7D)
and
![f(\mathbf x)](https://tex.z-dn.net/?f=f%28%5Cmathbf%20x%29)
have critical points at the same vector
![\mathbf x](https://tex.z-dn.net/?f=%5Cmathbf%20x)
.
Derivatives of the Lagrangian set equal to zero:
![L_x=2x+\lambda=0\implies x=-\dfrac\lambda2](https://tex.z-dn.net/?f=L_x%3D2x%2B%5Clambda%3D0%5Cimplies%20x%3D-%5Cdfrac%5Clambda2)
![L_y=2(y-2)-2\lambda=0\implies y=2+\lambda](https://tex.z-dn.net/?f=L_y%3D2%28y-2%29-2%5Clambda%3D0%5Cimplies%20y%3D2%2B%5Clambda)
![L_z=2(z-5)+3\lambda=0\implies z=5-\dfrac{3\lambda}2](https://tex.z-dn.net/?f=L_z%3D2%28z-5%29%2B3%5Clambda%3D0%5Cimplies%20z%3D5-%5Cdfrac%7B3%5Clambda%7D2)
![L_\lambda=x-2y+3z-6=0](https://tex.z-dn.net/?f=L_%5Clambda%3Dx-2y%2B3z-6%3D0)
Substituting the first three equations into the fourth gives
![-\dfrac\lambda2-2(2+\lambda)+3\left(5-\dfrac{3\lambda}2\right)=6](https://tex.z-dn.net/?f=-%5Cdfrac%5Clambda2-2%282%2B%5Clambda%29%2B3%5Cleft%285-%5Cdfrac%7B3%5Clambda%7D2%5Cright%29%3D6)
![11-7\lambda=6\implies \lambda=\dfrac57](https://tex.z-dn.net/?f=11-7%5Clambda%3D6%5Cimplies%20%5Clambda%3D%5Cdfrac57)
Solving for
![x,y,z](https://tex.z-dn.net/?f=x%2Cy%2Cz)
, we get a single critical point at
![\left(-\dfrac5{14},\dfrac{19}7,\dfrac{55}{14}\right)](https://tex.z-dn.net/?f=%5Cleft%28-%5Cdfrac5%7B14%7D%2C%5Cdfrac%7B19%7D7%2C%5Cdfrac%7B55%7D%7B14%7D%5Cright%29)
, which in turn gives the least distance between the plane and (0, 2, 5) of
![\dfrac5{\sqrt{14}}](https://tex.z-dn.net/?f=%5Cdfrac5%7B%5Csqrt%7B14%7D%7D)
.