Subject: more about sign, CLEARSIGN, *LOCAL-SIGNS*
From: Robert Dodier
Date: Tue, 10 Sep 2013 18:59:48 +0000 (UTC)
I've looked into the problem caused by sign calling CLEARSIGN.
As you may know, asksign pushes facts into *LOCAL-SIGNS* and
CLEARSIGN cleans up those facts. It turns out that SIGN-MEXPT also
pushes stuff onto *LOCAL-SIGNS*, and that leads to unexpected
behavior which I attempted to fix (commit 3137b946b) by calling
CLEARSIGN. However that too leads to trouble. So now among other
things I am considering whether we can avoid modifying *LOCAL-SIGNS*
unnecessarily (tnx to Stavros for the suggestion).
It turns out that the code to modify *LOCAL-SIGNS* in SIGN-MEXPT is very
old -- it is present in Maxima 5.0 source code. I suppose that it is
intended to cache intermediate results -- perhaps only for efficiency?
or are there simplifications which rely on it? Any further info on
this point?
Incidentally there are several functions to detemine sign of different
kinds of expressions, but only SIGN-MEXPT modifies *LOCAL-SIGNS*.
best
Robert Dodier