1 | initial version |
"When all else fails, RTFM..."
sage: x.is_infinity?
Docstring:
Return "True" if "self" is an infinite expression.
EXAMPLES:
sage: SR(oo).is_infinity()
True
sage: x.is_infinity()
False
Init docstring: Initialize self. See help(type(self)) for accurate signature.
File: /usr/local/sage-10/src/sage/symbolic/expression.pyx
Type: builtin_function_or_method
Illustration :
sage: foo=(1/x).limit(x=0)
sage: foo.is_infinity()
True
Note that :
sage: bool(foo>0)
---------------------------------------------------------------------------
ValueError Traceback (most recent call last)
Cell In[7], line 1
----> 1 bool(foo>Integer(0))
File /usr/local/sage-10/src/sage/symbolic/expression.pyx:3453, in sage.symbolic.expression.Expression.__bool__()
3451 pynac_result = decide_relational(self._gobj)
3452 if pynac_result == relational_undecidable:
-> 3453 raise ValueError('undecidable relation: ' + repr(self))
3454
3455 # pynac is guaranteed to give the correct answer for comparing infinities
ValueError: undecidable relation: Infinity > 0
HTH,