Skip to content

Commit

Permalink
sage -fixdoctests src/sage/combinat
Browse files Browse the repository at this point in the history
  • Loading branch information
mkoeppe committed Dec 19, 2023
1 parent e6ac103 commit 8ee19f2
Show file tree
Hide file tree
Showing 15 changed files with 338 additions and 355 deletions.
2 changes: 1 addition & 1 deletion src/sage/combinat/binary_tree.py
Original file line number Diff line number Diff line change
Expand Up @@ -4262,7 +4262,7 @@ def random_element(self):
EXAMPLES::
sage: BinaryTrees(5).random_element() # random # needs sage.combinat
sage: BinaryTrees(5).random_element() # random # needs sage.combinat
[., [., [., [., [., .]]]]]
sage: BinaryTrees(0).random_element() # needs sage.combinat
.
Expand Down
2 changes: 1 addition & 1 deletion src/sage/combinat/designs/difference_family.py
Original file line number Diff line number Diff line change
Expand Up @@ -1749,7 +1749,7 @@ def supplementary_difference_set_from_rel_diff_set(q, existence=False, check=Tru
EXAMPLES::
sage: from sage.combinat.designs.difference_family import supplementary_difference_set_from_rel_diff_set
sage: supplementary_difference_set_from_rel_diff_set(17) #random # needs sage.libs.pari
sage: supplementary_difference_set_from_rel_diff_set(17) #random # needs sage.libs.pari
(Additive abelian group isomorphic to Z/16,
[[(1), (5), (6), (7), (9), (13), (14), (15)],
[(0), (2), (3), (5), (6), (10), (11), (13), (14)],
Expand Down
4 changes: 2 additions & 2 deletions src/sage/combinat/designs/latin_squares.py
Original file line number Diff line number Diff line change
Expand Up @@ -291,12 +291,12 @@ def mutually_orthogonal_latin_squares(k, n, partitions=False, check=True):
sage: designs.orthogonal_arrays.is_available(5+2, 5) # 5 MOLS of order 5
False
sage: designs.orthogonal_arrays.is_available(4+2,6) # 4 MOLS of order 6 # needs sage.schemes
sage: designs.orthogonal_arrays.is_available(4+2,6) # 4 MOLS of order 6 # needs sage.schemes
False
Sage, however, is not able to prove that the second MOLS do not exist::
sage: designs.orthogonal_arrays.exists(4+2,6) # 4 MOLS of order 6 # needs sage.schemes
sage: designs.orthogonal_arrays.exists(4+2,6) # 4 MOLS of order 6 # needs sage.schemes
Unknown
If you ask for such a MOLS then you will respectively get an informative
Expand Down
2 changes: 1 addition & 1 deletion src/sage/combinat/free_module.py
Original file line number Diff line number Diff line change
Expand Up @@ -937,7 +937,7 @@ def get_order(self):
EXAMPLES::
sage: QS2 = SymmetricGroupAlgebra(QQ,2) # needs sage.combinat
sage: QS2.get_order() # note: order changed on 2009-03-13 # needs sage.combinat
sage: QS2.get_order() # note: order changed on 2009-03-13 # needs sage.combinat
[[2, 1], [1, 2]]
"""
if self._order is None:
Expand Down
2 changes: 1 addition & 1 deletion src/sage/combinat/multiset_partition_into_sets_ordered.py
Original file line number Diff line number Diff line change
Expand Up @@ -3394,7 +3394,7 @@ def val(self, q='q'):
Verifying Example 4.5 from [BCHOPSY2017]_::
sage: B = crystals.Minimaj(3, 4, 2) # for `Val_{4,1}^{(3)}` # needs sage.modules
sage: B = crystals.Minimaj(3, 4, 2) # for `Val_{4,1}^{(3)}` # needs sage.modules
sage: B.val() # needs sage.modules
(q^2+q+1)*s[2, 1, 1] + q*s[2, 2]
"""
Expand Down
10 changes: 5 additions & 5 deletions src/sage/combinat/partition.py
Original file line number Diff line number Diff line change
Expand Up @@ -5549,9 +5549,9 @@ def simple_module_dimension(self, base_ring=None):
sage: Partition([2,2,1]).simple_module_dimension()
5
sage: Partition([2,2,1]).specht_module_dimension(GF(3)) # optional - sage.rings.finite_rings
sage: Partition([2,2,1]).specht_module_dimension(GF(3)) # needs sage.rings.finite_rings
5
sage: Partition([2,2,1]).simple_module_dimension(GF(3)) # optional - sage.rings.finite_rings
sage: Partition([2,2,1]).simple_module_dimension(GF(3)) # needs sage.rings.finite_rings
4
sage: for la in Partitions(6, regular=3):
Expand Down Expand Up @@ -6736,9 +6736,9 @@ def random_element(self, measure='uniform'):
EXAMPLES::
sage: Partitions(5).random_element() # random # needs sage.libs.flint
sage: Partitions(5).random_element() # random # needs sage.libs.flint
[2, 1, 1, 1]
sage: Partitions(5).random_element(measure='Plancherel') # random # needs sage.libs.flint
sage: Partitions(5).random_element(measure='Plancherel') # random # needs sage.libs.flint
[2, 1, 1, 1]
"""
if measure == 'uniform':
Expand All @@ -6756,7 +6756,7 @@ def random_element_uniform(self):
sage: Partitions(5).random_element_uniform() # random # needs sage.libs.flint
[2, 1, 1, 1]
sage: Partitions(20).random_element_uniform() # random # needs sage.libs.flint
sage: Partitions(20).random_element_uniform() # random # needs sage.libs.flint
[9, 3, 3, 2, 2, 1]
TESTS::
Expand Down
2 changes: 1 addition & 1 deletion src/sage/combinat/plane_partition.py
Original file line number Diff line number Diff line change
Expand Up @@ -1548,7 +1548,7 @@ def __init__(self, box_size):
EXAMPLES::
sage: PP = PlanePartitions([4,3,2])
sage: TestSuite(PP).run() # long time, needs sage.modules
sage: TestSuite(PP).run() # long time # needs sage.modules
"""
super().__init__(box_size, category=FiniteEnumeratedSets())

Expand Down
2 changes: 1 addition & 1 deletion src/sage/combinat/root_system/cartan_matrix.py
Original file line number Diff line number Diff line change
Expand Up @@ -452,7 +452,7 @@ def reflection_group(self, type="matrix"):
EXAMPLES::
sage: C = CartanMatrix(['A',3]) # needs sage.graphs
sage: C.reflection_group() # needs sage.libs.gap sage.graphs
sage: C.reflection_group() # needs sage.graphs sage.libs.gap
Weyl Group of type ['A', 3] (as a matrix group acting on the root space)
"""
RS = self.root_space()
Expand Down
Loading

0 comments on commit 8ee19f2

Please sign in to comment.