On 9/5/10, Marek Pietrow <mrk at kft.umcs.lublin.pl> wrote:
> notone(x):=if x=1 then true else false;
Well, this is a typographical error. Should be:
notone(x) := if x#1 then true else false
Or more briefly, notone(x) := x#1;
Or matchdeclare(n1, lambda([x], x#1));
Or still more briefly, matchdeclare(n1, "#"(1));
> How to tell maxima that the rule should be applied to any constant?
Something like
matchdeclare (whatever, lambda ([x], x#1 and constantp(x)));
HTH
Robert Dodier