Skip to content

Commit 355d630

Browse files
committed
Adding PR details from github
1 parent 421821f commit 355d630

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/sage/combinat/symmetric_group_algebra.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3075,6 +3075,9 @@ def _element_constructor_(self, x):
30753075
sage: H3( SymmetricGroup(3).an_element() )
30763076
[1, 3, 2]
30773077
sage: H3( [2, 1] )
3078+
T[2, 1, 3]
3079+
sage: H3( [2, 1, 3, 4, 5, 6] )
3080+
T[2, 1, 3]
30783081
"""
30793082
###################################################
30803083
# Coerce permutations of size smaller that self.n #
@@ -3086,13 +3089,11 @@ def _element_constructor_(self, x):
30863089
return self.monomial(self._indices(
30873090
list(x) + list(range(len(x) + 1, self.n + 1))
30883091
))
3089-
if all(x[i] == i for i in range(self.n+1, len(x))):
3092+
if all(x[i] == i+1 for i in range(self.n, len(x))):
30903093
return self.monomial(self._indices(x[:self.n]))
30913094

30923095
return self._indices(x)
30933096

3094-
raise TypeError
3095-
30963097

30973098
class HeckeAlgebraSymmetricGroup_t(HeckeAlgebraSymmetricGroup_generic):
30983099

0 commit comments

Comments
 (0)