File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -7143,12 +7143,16 @@ def element_in_conjugacy_classes(self, nu):
7143
7143
sage: PP = Permutations(5)
7144
7144
sage: PP.element_in_conjugacy_classes([2,2]) # optional - sage.combinat
7145
7145
[2, 1, 4, 3, 5]
7146
+ sage: PP.element_in_conjugacy_classes([5, 5])
7147
+ Traceback (most recent call last):
7148
+ ...
7149
+ ValueError: the size of the partition (=10) should be at most the size of the permutations (=5)
7146
7150
"""
7147
7151
from sage .combinat .partition import Partition
7148
7152
nu = Partition (nu )
7149
7153
if nu .size () > self .n :
7150
- raise ValueError ("The size of the partition (=%s) should be lower or equal "
7151
- " to the size of the permutations (=%s)" % (nu .size , self .n ))
7154
+ raise ValueError ("the size of the partition (=%s) should be at most "
7155
+ " the size of the permutations (=%s)" % (nu .size (), self .n ))
7152
7156
l = []
7153
7157
i = 0
7154
7158
for nui in nu :
You can’t perform that action at this time.
0 commit comments