#8074: corner cases in RealField and real numbers
-------------------------+--------------------------------------------------
Reporter: jason | Owner: jkantor
Type: defect | Status: needs_info
Priority: major | Milestone: sage-4.3.3
Component: numerical | Keywords:
Author: | Upstream: N/A
Reviewer: | Merged:
Work_issues: |
-------------------------+--------------------------------------------------
Description changed by jason:
Old description:
> What should these return?
>
> {{{
>
> sage: RR('inf').is_real()
> True
> sage: RR('nan').is_real()
> True
> sage: RR('inf').is_unit()
> True
> }}}
New description:
What should these return?
{{{
sage: RR('inf').is_real()
True
sage: RR('nan').is_real()
True
sage: RR('inf').is_unit()
True
sage: RR('nan')==RR('nan')
True
sage: RR('nan').__nonzero__()
False
sage: RR('nan').__pow(0.5)
Exception RuntimeError: 'maximum recursion depth exceeded while calling a
Python object' in <type 'exceptions.RuntimeError'> ignored
^CERROR: Internal Python error in the inspect module.
Below is the traceback from this internal error.
Traceback (most recent call last):
File "/home/grout/sage/local/lib/python2.6/site-
packages/IPython/ultraTB.py", line 614, in text
records = _fixed_getinnerframes(etb, context,self.tb_offset)
File "/home/grout/sage/local/lib/python2.6/site-
packages/IPython/ultraTB.py", line 230, in _fixed_getinnerframes
records = fix_frame_records_filenames(inspect.getinnerframes(etb,
context))
File "/home/grout/sage/local/lib/python/inspect.py", line 942, in
getinnerframes
framelist.append((tb.tb_frame,) + getframeinfo(tb, context))
File "/home/grout/sage/local/lib/python/inspect.py", line 902, in
getframeinfo
filename = getsourcefile(frame) or getfile(frame)
File "/home/grout/sage/local/lib/python/inspect.py", line 451, in
getsourcefile
if hasattr(getmodule(object, filename), '__loader__'):
File "/home/grout/sage/local/lib/python/inspect.py", line 485, in
getmodule
if ismodule(module) and hasattr(module, '__file__'):
File "/home/grout/sage/local/lib/python2.6/site-
packages/sage/interfaces/get_sigs.py", line 9, in my_sigint
raise KeyboardInterrupt
KeyboardInterrupt
Unfortunately, your original traceback can not be constructed.
sage: RR('-inf').__pow(0.5)
+infinity
sage: sqrt(RR('-inf'))
+infinity*I
}}}
--
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/8074#comment:7>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en.