(F x1)(F x2)...(F xn)[ p(x1,...,xn) < 0 ]where, recall, "F" means "there exist infinitely many". Clearly if this formula is true p is not semi-definite. After all, it would have been enough to find one point at which p is negative and we would have found infinitely many. However, what if this formula returns false? Is it possible that p could none-the-less not be positive semi-definite? No, because if p is not positive semi-definite there is an open set of points in which p < 0, and this open set provides infinitely many values of x1 such that there are infinitely many values of x2 such that ... such that there are inifinitely many values of xn such that p(x1,...,xn) < 0.
Why is this formulation better? Intuituvely, deciding "there exists infinitely many x" is easier because you can miss or ignore finitely many values of x and you'll still get the right answer. In QEPCAD's case, it chooses to ignore the finitely many test values it has for x that not rational. This way it doesn't have to do algebraic number computations and that's a HUGE win in terms of performance.
p = w^6 + 2 z^2 w^3 + x^4 + y^4 + z^4 + 2 x^2 w + 2 x^2 z + 3 x^2 + w^2 + 2 z w + z^2 + 2 z + 2 w + 1CAD construction is very sensitive to variable ordering, and this example demonstrates that well. As a general rule of thumb when producing a CAD for a single polynomial try to order variables in
The following QEPCAD session, run on a ??? MHz Pentium IV with ??? MB RAM, shows that p is in fact positive semidefinite. QEPCAD was run with the default size for Saclib's garbage collected space, which is 2MB, and required 0.15 seconds of CPU time to produce its result.
=======================================================
Quantifier Elimination
in
Elementary Algebra and Geometry
by
Partial Cylindrical Algebraic Decomposition
Version B 1.30, 05 Feb 2004
by
Hoon Hong
(hhong@math.ncsu.edu)
With contributions by: Christopher W. Brown, George E.
Collins, Mark J. Encarnacion, Jeremy R. Johnson
Werner Krandick, Richard Liska, Scott McCallum,
Nicolas Robidoux, and Stanly Steinberg
=======================================================
Enter an informal description between '[' and ']':
[ Computes the "not" of "is p positive semidefinite?" ]
Enter a variable list:
(w,z,x,y)
Enter the number of free variables:
0
Enter a prenex formula:
(F w)(F z)(F x)(F y)[
w^6 + 2 z^2 w^3 + x^4 + y^4 + z^4 + 2 x^2 w +
2 x^2 z + 3 x^2 + w^2 + 2 z w + z^2 + 2 z + 2 w + 1 < 0
].
=======================================================
Before Normalization >
finish
An equivalent quantifier-free formula:
FALSE
===================== The End =======================
-----------------------------------------------------------------------------
1 Garbage collections, 492023 Cells and 0 Arrays reclaimed, in 20 milliseconds.
411729 Cells in AVAIL, 500000 Cells in SPACE.
System time: 150 milliseconds.
System time after the initialization: 140 milliseconds.
-----------------------------------------------------------------------------