Solution (source code)

= Solution

At an interior <stationary point>, a negative determinant of the symmetric <Hessian matrix> means its two eigenvalues have opposite signs. Along their eigenvectors the leading quadratic change has opposite signs, and the higher-order remainder cannot reverse these signs sufficiently close to the point. Hence the nondegenerate saddle condition is
$$
\boxed{f_x=f_y=0,\qquad f_{xx}f_{yy}-f_{xy}^2<0.}
$$
When the determinant vanishes, a saddle is still possible but is not determined by second derivatives alone: $x^4-y^4$ is a simple example. Thus these tests are decisive for nondegenerate stationary points, not an exhaustive classification from first and second derivatives of every smooth function.