Re: abs(oo)

Karim Belabas <[email protected]> Wed, 10 Jul 2024 00:42:46 +0200
Newsgroups gmane.comp.mathematics.pari.devel
Message-ID <Zo285rtZWva5/[email protected]>
* Ilya Zakharevich [2024-07-10 00:09]:
> I know that oo and -oo should only be involved in comparisons and unary
> negation.  But they work in max and min — so it seems logical that
> they must work in everything EXPRESSIBLE in terms of these operations
> as well!  But then abs(-oo) should be allowed…

It is allowed since

commit 77266e7bacd8e3f35b036f4c6eae671f98faefe2
Author: Bill Allombert <[email protected]>
Date:   Sat Feb 3 17:31:39 2024 +0100

    gabs: allow t_INFINITY


? abs(-oo)
%1 = +oo

? abs(oo)
%2 = +oo

Cheers,

    K.B.
-- 
Pr. Karim Belabas, U. Bordeaux, Vice-président en charge du Numérique
Institut de Mathématiques de Bordeaux UMR 5251 - (+33) 05 40 00 29 77
http://www.math.u-bordeaux.fr/~kbelabas/