infinity correct maxima



Barton Willis wrote:
> maxima-bounces at math.utexas.edu wrote on 08/28/2008 09:01:21 AM:
> 
> 
>> I'm not sure what is implemented, but the following sequence:
>>
>> x: inf;
>> x-x; 
>> could result in zero, because it is the same infinity.
>> so should (x^2-1)-(x+1)*(x-1).
>>
>> However,
>> y:inf;
>> x-y  should result in undefined.
>> Getting undefined arithmetic right would be just as important.
>>
>> Labeling each unique inf with an identifier is a way to do this.
> 
> No, my code doesn't tag infinities this way. If we simply tagged
> each infinity with a gensym identifier, it wouldn't be all that
> hard to do, but getting through the test suite might be a chore.

How would such a tagged inf be printed?  Will it be printed inf<junk>? 
Or just inf?

With or without tagging, I'm not sure I like the example of x-x 
returning 0, but inf-inf being undefined.  I find that rather confusing.

Ray