On Sun, 2002-02-03 at 13:29, Richard Fateman wrote:
> My expectation is that the simultaneous use of
> A and a confuses some part of the simplifier
> that depends on the sorting order of the symbols.
>
> ... in particular, alphalessp thinks |$a| > $A and $A > |$a|.
> one of the GCL hackers should fix this.
>
>
> There is an easy work-around for this bug.
>
> If you do something like substitute AA for A you will get
> zero. Maxima can do this: subst(AA,A,%);
>
> So it is either a GCL bug or it is a bug in the
> source code that is particular to GCL.
>
> You can avoid it by not using the same symbols with
> different capitalization.
> Or a different compiled version of Maxima.
I'm afraid the problem is not restricted to GCL. I see the same behavior
under GCL, clisp and CMUCL. Would someone please add this problem to the
bug tracker at sourceforge?
Here's the results of a simple test under the three lisps. The last two
answers should not both be NIL.
We could probably clean up the output of the batch command!
---------------------------------------------------------
|abacus>cat alphalessp.mac
:lisp (alphalessp 'a 'b)
:lisp (alphalessp 'b 'a)
:lisp (alphalessp '|$a| '$A)
:lisp (alphalessp '$A '|$a|)
|abacus>maxima --lisp=gcl --batch=alphalessp.mac
GCL (GNU Common Lisp) Version(2.4.0) Tue Dec 18 17:59:26 CST 2001
Licensed under GNU Library General Public License
Contains Enhancements by W. Schelter
Maxima 5.6 Tue Jul 10 15:41:45 CDT 2001 (with enhancements by W.
Schelter).
Licensed under the GNU Public License (see file COPYING)
(C1)
batching #p/home/amundson/tmp/alphalessp.mac
T
NIL
NIL
NIL
(D2) alphalessp.mac
(C2)
|abacus>maxima --lisp=clisp --batch=alphalessp.mac
Maxima 5.6 Tue Jul 10 15:41:45 CDT 2001 (with enhancements by W.
Schelter).
Licensed under the GNU Public License (see file COPYING)
(C1)
batching /home/amundson/tmp/alphalessp.mac
T
NIL
NIL
NIL
(D2) alphalessp.mac
(C2)
|abacus>maxima --lisp=cmucl --batch=alphalessp.mac
CMU Common Lisp release x86-linux 2.5.1 8 March 2001 build 1768,
running on abacus
Send bug reports and questions to your local CMU CL maintainer,
or to pvaneynd@debian.org
or to cmucl-help@cons.org. (prefered)
type (help) for help, (quit) to exit, and (demo) to see the demos
Loaded subsystems:
Python 1.0, target Intel x86
CLOS based on PCL version: September 16 92 PCL (f)
Maxima 5.6 Tue Jul 10 15:41:45 CDT 2001 (with enhancements by W.
Schelter).
Licensed under the GNU Public License (see file COPYING)
(C1)
batching /home/amundson/tmp/alphalessp.mac
T
NIL
NIL
NIL
(D2) alphalessp.mac
(C2)
---------------------------------------------------------
--Jim