Wikipedia gives the following illustration for the method of Lagrange multipliers. In this case, $d_1$ is the highest-valued contour line, so clearly the method works.
But what if $d_2$ or $d_3$ were higher than $d_1$? Wouldn't the method fail? If so, what conditions must $f$ satisfy for the method of Lagrange multipliers to apply? If not, why not?