#20921: LatticePoset: add function to get lattice of sublattices
-------------------------------------+-------------------------------------
       Reporter:  jmantysalo         |        Owner:
           Type:  enhancement        |       Status:  needs_work
       Priority:  major              |    Milestone:  sage-7.3
      Component:  combinatorics      |   Resolution:
       Keywords:  lattice poset      |    Merged in:
        Authors:  Jori Mäntysalo     |    Reviewers:  Travis Scrimshaw
Report Upstream:  N/A                |  Work issues:
         Branch:                     |       Commit:
  u/jmantysalo/latticeposet__add_function_to_get_lattice_of_sublattices|  
cf557bbcdbe1e6d8a306d586a6cd3820c145344c
   Dependencies:                     |     Stopgaps:
-------------------------------------+-------------------------------------
Changes (by vbraun):

 * status:  positive_review => needs_work


Comment:

 {{{
 sage -t --long src/sage/combinat/posets/lattices.py
 **********************************************************************
 File "src/sage/combinat/posets/lattices.py", line 1743, in
 sage.combinat.posets.lattices.FiniteLatticePoset.sublattices_lattice
 Failed example:
     sll = L.sublattices_lattice()
 Exception raised:
     Traceback (most recent call last):
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 499, in _run
         self.compile_and_execute(example, compiler, test.globs)
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 862, in compile_and_execute
         exec(compiled, globs)
       File "<doctest
 sage.combinat.posets.lattices.FiniteLatticePoset.sublattices_lattice[4]>",
 line 1, in <module>
         sll = L.sublattices_lattice()
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/combinat/posets/lattices.py", line 1868, in
 sublattices_lattice
         G.relabel(lambda x: self.sublattice(x))
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/graphs/generic_graph.py", line 19817, in relabel
         perm = dict( [ i, perm(i) ] for i in self.vertices() )
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/graphs/generic_graph.py", line 19817, in <genexpr>
         perm = dict( [ i, perm(i) ] for i in self.vertices() )
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/combinat/posets/lattices.py", line 1868, in <lambda>
         G.relabel(lambda x: self.sublattice(x))
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/combinat/posets/lattices.py", line 1680, in sublattice
         return LatticePoset(self.subposet(current_set))
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/combinat/posets/posets.py", line 4513, in subposet
         elements = [self(e) for e in elements]
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/combinat/posets/posets.py", line 1232, in __call__
         return super(FinitePoset, self).__call__(element)
       File "sage/structure/parent.pyx", line 1107, in
 sage.structure.parent.Parent.__call__
 
(/home/buildbot/slave/sage_git/build/src/build/cythonized/sage/structure/parent.c:9904)
         return mor._call_(x)
       File "sage/structure/coerce_maps.pyx", line 110, in
 sage.structure.coerce_maps.DefaultConvertMap_unique._call_
 
(/home/buildbot/slave/sage_git/build/src/build/cythonized/sage/structure/coerce_maps.c:4651)
         raise
       File "sage/structure/coerce_maps.pyx", line 105, in
 sage.structure.coerce_maps.DefaultConvertMap_unique._call_
 
(/home/buildbot/slave/sage_git/build/src/build/cythonized/sage/structure/coerce_maps.c:4539)
         return C._element_constructor(x)
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/combinat/posets/posets.py", line 1208, in
 _element_constructor_
         % type(element))
     ValueError: <type 'int'> is not an element of this poset
 **********************************************************************
 File "src/sage/combinat/posets/lattices.py", line 1844, in
 sage.combinat.posets.lattices.FiniteLatticePoset.sublattices_lattice
 Failed example:
     sll = L.sublattices_lattice()
 Exception raised:
     Traceback (most recent call last):
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 499, in _run
         self.compile_and_execute(example, compiler, test.globs)
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 862, in compile_and_execute
         exec(compiled, globs)
       File "<doctest
 sage.combinat.posets.lattices.FiniteLatticePoset.sublattices_lattice[4]>",
 line 1, in <module>
         sll = L.sublattices_lattice()
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/combinat/posets/lattices.py", line 1868, in
 sublattices_lattice
         G.relabel(lambda x: self.sublattice(x))
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/graphs/generic_graph.py", line 19817, in relabel
         perm = dict( [ i, perm(i) ] for i in self.vertices() )
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/graphs/generic_graph.py", line 19817, in <genexpr>
         perm = dict( [ i, perm(i) ] for i in self.vertices() )
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/combinat/posets/lattices.py", line 1868, in <lambda>
         G.relabel(lambda x: self.sublattice(x))
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/combinat/posets/lattices.py", line 1680, in sublattice
         return LatticePoset(self.subposet(current_set))
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/combinat/posets/posets.py", line 4513, in subposet
         elements = [self(e) for e in elements]
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/combinat/posets/posets.py", line 1232, in __call__
         return super(FinitePoset, self).__call__(element)
       File "sage/structure/parent.pyx", line 1107, in
 sage.structure.parent.Parent.__call__
 
(/home/buildbot/slave/sage_git/build/src/build/cythonized/sage/structure/parent.c:9904)
         return mor._call_(x)
       File "sage/structure/coerce_maps.pyx", line 110, in
 sage.structure.coerce_maps.DefaultConvertMap_unique._call_
 
(/home/buildbot/slave/sage_git/build/src/build/cythonized/sage/structure/coerce_maps.c:4651)
         raise
       File "sage/structure/coerce_maps.pyx", line 105, in
 sage.structure.coerce_maps.DefaultConvertMap_unique._call_
 
(/home/buildbot/slave/sage_git/build/src/build/cythonized/sage/structure/coerce_maps.c:4539)
         return C._element_constructor(x)
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/combinat/posets/posets.py", line 1208, in
 _element_constructor_
         % type(element))
     ValueError: <type 'int'> is not an element of this poset
 **********************************************************************
 File "src/sage/combinat/posets/lattices.py", line 1856, in
 sage.combinat.posets.lattices.FiniteLatticePoset.sublattices_lattice
 Failed example:
     sll.is_isomorphic(Posets.BoolenLattice(3))
 Exception raised:
     Traceback (most recent call last):
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 499, in _run
         self.compile_and_execute(example, compiler, test.globs)
       File "/home/buildbot/slave/sage_git/build/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 862, in compile_and_execute
         exec(compiled, globs)
       File "<doctest
 sage.combinat.posets.lattices.FiniteLatticePoset.sublattices_lattice[10]>",
 line 1, in <module>
         sll.is_isomorphic(Posets.BoolenLattice(Integer(3)))
     AttributeError: type object 'Posets' has no attribute 'BoolenLattice'
 **********************************************************************
 1 item had failures:
    3 of  24 in
 sage.combinat.posets.lattices.FiniteLatticePoset.sublattices_lattice
     [310 tests, 3 failures, 0.75 s]
 }}}

--
Ticket URL: <https://trac.sagemath.org/ticket/20921#comment:18>
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 https://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.

Reply via email to