- labels: --> Lisp Core
expr:
LOG(x^2+SQRT(2)*x+1)
-LOG(x^2-SQRT(2)*x+1)
+2*ATAN((2*x+SQRT(2))/SQRT(2))
+2*ATAN((2*x-SQRT(2))/SQRT(2))
+SQRT(2)*LOG(x+1)
-SQRT(2)*LOG(x-1)
-2*SQRT(2)*ATAN(1/x)$
zeroequiv(expr,x) takes over a minute, though it is not at
all subtle how non-zero it is:
rectform(expr),numer,
..., x=0.1 => -3.31-4.44i
..., x=0.9 => 6.39-4.44i
..., x=1.1 => 7.38
..., x=1.5 => 6.38
..., x=20 => 6.28
Zeroequiv is really supposed to be quick and dirty....
This bug report is related to SF[593530] "Zeroequiv issues". zeroequiv is not used for in core functions. Problems are known and documented. This is the result for the example:
(%i9) expr:LOG(x^2+SQRT(2)*x+1)-LOG(x^2-SQRT(2)*x+1)+2*ATAN((2*x+SQRT(2))/SQRT(2))
+2*ATAN((2*x-SQRT(2))/SQRT(2))+SQRT(2)*LOG(x+1)
-SQRT(2)*LOG(x-1)-2*SQRT(2)*ATAN(1/x)
(%i10) zeroequiv(expr,x);
(%o10) dontknow
On a Windows system with GCL 2.6.8 and a CPU with 1.8 GHZ we get
(%i11) for i:1 thru 100000 do zeroequiv(expr,x);
Evaluation took 15.8900 seconds (15.8900 elapsed)
(%o11) done
One call to zeroequiv needs about 16/100,000 seconds. Setting resolution to "wont fix" and status to pending.
Dieter Kaiser
In Maxima 5.15, the original expression (but in lower case) takes 0.02 sec and correctly gives false.
zeroequiv(LOG(1),x) correctly gives dontknow and returns instantaneously since Maxima function names are now lower-case (unlike in 2002 when the bug report was submitted).
Closing as fixed.