In case it's not 100% clear, the problem is with the
Maxima function 'sign,' not with the function 'max.'
I wrote most of the max and min code, so I like folks
to know this. ;)
If 'sign' were improved, so would max and min. There are
standard algorithms for linear constraints, but Maxima's sign
function doesn't seem to use them. It's been awhile since I've
looked, but I think the code in compar.lisp is hard to follow
and to trace.
Barton
maxima-admin at math.utexas.edu wrote on 08/01/2006 09:34:29 AM:
> Unfortunately, Maxima does not currently know that a>b implies a>b-5 :
>
> assume(a>b)$
> is(a>b-5);
> => Maxima was unable to evaluate the predicate
>
> Obviously this sort of thing should be improved.
> On 8/1/06, none none <lots.of.mailing.lists at gmail.com> wrote:
> (%i1) assume(a > b);
> (%o1) [a > b]
> (%i3) max(a, b - 5);
> (%o3) max(b - 5, a)
>
> Surely maxima is able to see that 'max(b - 5, a)' is always 'a'?