#17979: Reimplementation of IntegerListsLex
-------------------------------------+-------------------------------------
Reporter: aschilling | Owner:
Type: defect | Status: needs_work
Priority: blocker | Milestone: sage-6.6
Component: combinatorics | Resolution:
Keywords: days64 | Merged in:
Authors: Bryan Gillespie, | Reviewers: Nathann Cohen, Jeroen
Anne Schilling, Nicolas M. Thiery | Demeyer, Travis Scrimshaw
Report Upstream: N/A | Work issues:
Branch: | Commit:
public/ticket/17979 | 92bc243feb2f3f8645dbe28970a77fd5e8edd578
Dependencies: | Stopgaps:
-------------------------------------+-------------------------------------
Comment (by aschilling):
Replying to [comment:412 ncohen]:
> - I do not understand this comment:
> {{{If a part has no bound on its value, it will be detected at some
point}}}
> Do you mean that "at some point in __iter__" it will be detected?
Probably
> not, as this function is called only once.
It will be detected during the algorithm that builds up the integer vector
successively.
The algorithm tries to add each part and if at some point the bound on a
part is
infinite, then it will raise an error.
> - The function `_check_finiteness` assumes that the alphabet size is
bounded. It
> is always true when this function is called, but the following raises
no
> warning:
> {{{
> sage: for x in IntegerListsLex(NonNegativeIntegers(),max_length=3):
> ....: pass
> }}}
> For the reason given earlier, the output is not sorted
lexicographically. It
> is not detected as infinite either.
`_check_finiteness` only tests this for each piece in the
DisjointEnumeratedSet
(when a list is given for `n`) and checks that each piece is a finite set.
--
Ticket URL: <http://trac.sagemath.org/ticket/17979#comment:434>
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 unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.