#12663: Partitions(-1).list() goes into infinte recursion
-------------------------------------------+--------------------------------
Reporter: mantepse | Owner: sage-combinat
Type: defect | Status: needs_review
Priority: minor | Milestone: sage-5.0
Component: combinatorics | Resolution:
Keywords: Partitions, corner case | Work issues:
Report Upstream: N/A | Reviewers:
Authors: Travis Scrimshaw | Merged in:
Dependencies: | Stopgaps:
-------------------------------------------+--------------------------------
Changes (by {'newvalue': u'Travis Scrimshaw', 'oldvalue': u'Martin Rubey'}):
* status: new => needs_review
* author: Martin Rubey => Travis Scrimshaw
Old description:
> Currently Partitions only checks whether its argument is an integer, but
> iterating through Partitions(-1) fails. The question is whether we want
> to accept only nonnegative integers or to return the empty list. (I vote
> for the empty list)
>
> Note that Partitions(-1, min_part=2).list() gives the empty list.
New description:
Currently Partitions only checks whether its argument is an integer, but
iterating through Partitions(-1) fails. It now creates an empty list.
{{{
sage: Partitions(-1).list()
[]
}}}
--
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/12663#comment:2>
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.