To test whether a continuous function has a root one simple root in a given interval [x0, x1] is relatively easy: according to Intermediate value theorem when the sign of function value at x0 is opposite to the sign at x1, there is (at least) one root.
For example, given a quadratic function:
g(x): a*x**2 + b*x + c = 0
The test looks like:
if sign of g(x0) is opposite of sign of g(x1)
then return true
else return false
For multivariate case there is Poincaré–Miranda theorem but I have a bit of difficulty to implement the test correctly from reading the linked article.
Given two quadratic bivariate functions:
g1(x, y): a1*x**2 + b1*y**2 + c1*x*y + d1*x + e1*y + f1 = 0
g2(x, y): a2*x**2 + b2*y**2 + c2*x*y + d2*x + e2*y + f2 = 0
and a rectangular region [x0, x1] x [y0, y1], how to check if there is at least one root in the region?
I mean, I assume the test should look somewhat like (this doesn't work):
if (sign of g1(x0, y0) is opposite of sign of g1(x1, y0) and
sign of g1(x0, y1) is opposite of sign of g1(x0, y1) and
sign of g2(x0, y0) is opposite of sign of g2(x1, y0) and
sign of g2(x0, y1) is opposite of sign of g2(x0, y1))
then return true
else return false
Please, does anyone know what pairs of functions, interval end-points, and logical operators to check and in what order?