#9094: is_square and sqrt for polynomials and fraction fields
-------------------------------+--------------------------------------------
Reporter: robertwb | Owner: AlexGhitza
Type: defect | Status: needs_work
Priority: major | Milestone: sage-4.5
Component: algebra | Keywords:
Author: Robert Bradshaw | Upstream: N/A
Reviewer: John Cremona | Merged:
Work_issues: doctest failure |
-------------------------------+--------------------------------------------
Comment(by mderickx):
This patch also leaks memory, probably because of bug #9129
{{{
t=get_memory_usage()
Pr.<x>=ZZ[]
for i in range(500):
C=((x^2+1)*x+1)
B=C^2
print "memusage", get_memory_usage(t)
time x=B.sqrt()
}}}
executing the above gives:
{{{
memusage 0.0
Time: CPU 0.00 s, Wall: 0.00 s
memusage 0.0
Time: CPU 0.00 s, Wall: 0.00 s
memusage 0.0
Time: CPU 0.00 s, Wall: 0.00 s
memusage 0.0
Time: CPU 0.00 s, Wall: 0.00 s
memusage 0.0
Time: CPU 0.02 s, Wall: 0.02 s
memusage 1.20703125
Time: CPU 0.18 s, Wall: 0.19 s
memusage 23.79296875
Time: CPU 2.33 s, Wall: 2.36 s
memusage 148.12890625
Time: CPU 31.70 s, Wall: 32.24 s
memusage 1534.01171875
^C
^C
}}}
Ps. if you want to check this, please don't let the loop run as long as I
did ;). It might make your computer on the edge of crashing
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/9094#comment:9>
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.