experimental meqp



-----"Stavros Macrakis"  wrote: -----

>So q[1]:r[1]:1$ is(equal('q,'r)) => true
>but q:q[1]:r[1]:1$ is(equal('q,'r)) => false
>>Is that right?
>
>That is treating 'q' as a single object which has
>both a scalar value and an array value, and comparing on both of
>them.  I think this is confusing.  I would think it would be clearer to
>compare just the scalar values.

I just changed meqp. Now when an argument to meqp
has both the array property and the value property,
meqp compares the scalar values:

(%i2) q[1]:r[1]:1$
(%i3) is(equal(q,r));
(%o3) true   <-- because the arrays are equal

(%i4) is(equal('q,'r));
(%o4) true

Let's give 'q' a value. Now meqpp checks the scalar values
of q and r

(%i5) q : 42$
(%i6) is(equal('q,'r));
Maxima was unable to evaluate the predicate: equal(q,r)

(%i7) is(equal('q,'r)), prederror : false;
(%o7) unknown

I'm not in love with:
(%i11) is(equal(0.1,1/10));
`rat' replaced 0.0 by 0//1 = 0.0
(%o11) true

What do you all think?

Barton