You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
gh-37318: Allowing HeckeAlgebraSymmetricGroupT to accept elements of SymmetricGroup(n) as input
<!-- ^^^^^
Please provide a concise, informative and self-explanatory title.
Don't put issue numbers in there, do this in the PR body below.
For example, instead of "Fixes#1234" use "Introduce new method to
calculate 1+1"
-->
<!-- Describe your changes here in detail -->
Currently, the following fails in sage:
```
sage: S4 = SymmetricGroup(4)
sage: H4 = HeckeAlgebraSymmetricGroupT(ZZ, 4)
sage: H4( Permutations(4).an_element() )
T[4, 1, 2, 3]
sage: H4( S4.an_element() )
Traceback (most recent call last)
...
TypeError: do not know how to make x (= (2,3,4)) an element of self
(=Hecke algebra of the symmetric group of order 4 on the T basis over
Univariate Polynomial Ring in q over Integer Ring)
```
I view this as a bug because the elements of this algebra are indexed by
elements of the symmetric group and `HeckeAlgebraSymmetricGroupT` does
accept elements of `Permutations(n)`.
This PR makes works work as well as accepting elements of
`Permutations(N)`, for `N>n, that fix `n+1,...,N`.
Previously, `HeckeAlgebraSymmetricGroupT` contain a `_coerce_start`
method. I have renamed this as `_element_constructor_`, which is what I
think it should be, and made some minor changes there. Probably, I
should deprecate `_coerce_start` but this method does not seem to exist
anywhere else in sage, so I suspect that this belongs to some code that
was deprecated years ago.
<!-- Why is this change required? What problem does it solve? -->
<!-- If this PR resolves an open issue, please link to it here. For
example "Fixes#12345". -->
<!-- If your change requires a documentation PR, please link it
appropriately. -->
### 📝 Checklist
<!-- Put an `x` in all the boxes that apply. -->
<!-- If your change requires a documentation PR, please link it
appropriately -->
<!-- If you're unsure about any of these, don't hesitate to ask. We're
here to help! -->
<!-- Feel free to remove irrelevant items. -->
- [x] The title is concise, informative, and self-explanatory.
- [x] The description explains in detail what this PR is about.
- [x] I have linked a relevant issue or discussion.
- [x] I have created tests covering the changes.
- [x] I have updated the documentation accordingly.
### ⌛ Dependencies
<!-- List all open PRs that this PR logically depends on
- #12345: short description why this is a dependency
- #34567: ...
-->
<!-- If you're unsure about any of these, don't hesitate to ask. We're
here to help! -->
URL: #37318
Reported by: Andrew Mathas
Reviewer(s): Andrew Mathas, Giacomo Pope
0 commit comments