Skip to content
This repository was archived by the owner on Feb 1, 2023. It is now read-only.

Commit 4a1c0f0

Browse files
committed
trac 30806 details in Schubert polynomials
1 parent eecada2 commit 4a1c0f0

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/sage/combinat/schubert_polynomial.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
from sage.rings.polynomial.multi_polynomial import is_MPolynomial
2222
from sage.combinat.permutation import Permutations, Permutation
2323
import sage.libs.symmetrica.all as symmetrica
24+
from sage.misc.cachefunc import cached_method
2425

2526

2627
def SchubertPolynomialRing(R):
@@ -89,8 +90,7 @@ def expand(self):
8990

9091
def divided_difference(self, i, algorithm="sage"):
9192
r"""
92-
Return the ``i``-th divided difference operator, applied to
93-
``self``.
93+
Return the ``i``-th divided difference operator, applied to ``self``.
9494
9595
Here, ``i`` can be either a permutation or a positive integer.
9696
@@ -321,6 +321,7 @@ def __init__(self, R):
321321
category=GradedAlgebrasWithBasis(R),
322322
prefix='X')
323323

324+
@cached_method
324325
def one_basis(self):
325326
"""
326327
Return the index of the unit of this algebra.
@@ -331,7 +332,7 @@ def one_basis(self):
331332
sage: X.one() # indirect doctest
332333
X[1]
333334
"""
334-
return Permutations()([1])
335+
return self.indices()([1])
335336

336337
def _element_constructor_(self, x):
337338
"""

0 commit comments

Comments
 (0)