Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

implement Adams operator for lazy power series #36396

Merged
merged 6 commits into from Feb 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
10 changes: 5 additions & 5 deletions src/doc/en/developer/coding_in_other.rst
Expand Up @@ -97,14 +97,14 @@ In case you are familiar with gp, please note that the PARI C function
may have a name that is different from the corresponding gp function
(for example, see ``mathnf``), so always check the manual.

We can also add a ``frobenius(flag)`` method to the ``matrix_integer``
We can also add a ``frobenius_form(flag)`` method to the ``matrix_integer``
class where we call the ``matfrobenius()`` method on the PARI object
associated to the matrix after doing some sanity checking. Then we
convert output from PARI to Sage objects:

.. CODE-BLOCK:: cython

def frobenius(self, flag=0, var='x'):
def frobenius_form(self, flag=0, var='x'):
"""
Return the Frobenius form (rational canonical form) of this matrix.

Expand All @@ -129,13 +129,13 @@ convert output from PARI to Sage objects:
EXAMPLES::

sage: A = MatrixSpace(ZZ, 3)(range(9))
sage: A.frobenius(0)
sage: A.frobenius_form(0)
[ 0 0 0]
[ 1 0 18]
[ 0 1 12]
sage: A.frobenius(1)
sage: A.frobenius_form(1)
[x^3 - 12*x^2 - 18*x]
sage: A.frobenius(1, var='y')
sage: A.frobenius_form(1, var='y')
[y^3 - 12*y^2 - 18*y]
"""
if not self.is_square():
Expand Down
20 changes: 12 additions & 8 deletions src/sage/categories/bialgebras_with_basis.py
Expand Up @@ -11,6 +11,7 @@

from sage.categories.category_with_axiom import CategoryWithAxiom_over_base_ring
from sage.categories.tensor import tensor
from sage.misc.superseded import deprecated_function_alias


class BialgebrasWithBasis(CategoryWithAxiom_over_base_ring):
Expand Down Expand Up @@ -146,7 +147,7 @@ def convolution_product(self, *maps):

class ElementMethods:

def adams_operator(self, n):
def convolution_power_of_id(self, n):
r"""
Compute the `n`-th convolution power of the identity morphism
`\mathrm{Id}` on ``self``.
Expand Down Expand Up @@ -176,31 +177,31 @@ def adams_operator(self, n):

sage: # needs sage.combinat sage.modules
sage: h = SymmetricFunctions(QQ).h()
sage: h[5].adams_operator(2)
sage: h[5].convolution_power_of_id(2)
2*h[3, 2] + 2*h[4, 1] + 2*h[5]
sage: h[5].plethysm(2*h[1])
2*h[3, 2] + 2*h[4, 1] + 2*h[5]
sage: h([]).adams_operator(0)
sage: h([]).convolution_power_of_id(0)
h[]
sage: h([]).adams_operator(1)
sage: h([]).convolution_power_of_id(1)
h[]
sage: h[3,2].adams_operator(0)
sage: h[3,2].convolution_power_of_id(0)
0
sage: h[3,2].adams_operator(1)
sage: h[3,2].convolution_power_of_id(1)
h[3, 2]

::

sage: S = NonCommutativeSymmetricFunctions(QQ).S() # needs sage.combinat sage.modules
sage: S[4].adams_operator(5) # needs sage.combinat sage.modules
sage: S[4].convolution_power_of_id(5) # needs sage.combinat sage.modules
5*S[1, 1, 1, 1] + 10*S[1, 1, 2] + 10*S[1, 2, 1]
+ 10*S[1, 3] + 10*S[2, 1, 1] + 10*S[2, 2] + 10*S[3, 1] + 5*S[4]


::

sage: m = SymmetricFunctionsNonCommutingVariables(QQ).m() # needs sage.combinat sage.modules
sage: m[[1,3],[2]].adams_operator(-2) # needs sage.combinat sage.modules
sage: m[[1,3],[2]].convolution_power_of_id(-2) # needs sage.combinat sage.modules
3*m{{1}, {2, 3}} + 3*m{{1, 2}, {3}} + 6*m{{1, 2, 3}} - 2*m{{1, 3}, {2}}
"""
if n < 0:
Expand All @@ -213,6 +214,9 @@ def adams_operator(self, n):
T = lambda x: x
return self.convolution_product([T] * n)

adams_operator = deprecated_function_alias(36396,
convolution_power_of_id)

def convolution_product(self, *maps):
r"""
Return the image of ``self`` under the convolution product (map) of
Expand Down
22 changes: 11 additions & 11 deletions src/sage/combinat/ncsf_qsym/ncsf.py
Expand Up @@ -771,8 +771,8 @@ def verschiebung(self, n):

.. SEEALSO::

:meth:`frobenius method of QSym
<sage.combinat.ncsf_qsym.qsym.QuasiSymmetricFunctions.Bases.ElementMethods.frobenius>`,
:meth:`adams_operator method of QSym
<sage.combinat.ncsf_qsym.qsym.QuasiSymmetricFunctions.Bases.ElementMethods.adams_operator>`,
:meth:`verschiebung method of Sym
<sage.combinat.sf.sfa.SymmetricFunctionAlgebra_generic_Element.verschiebung>`

Expand Down Expand Up @@ -825,7 +825,7 @@ def verschiebung(self, n):

sage: QSym = QuasiSymmetricFunctions(ZZ)
sage: M = QSym.M()
sage: all( all( M(I).frobenius(3).duality_pairing(S(J))
sage: all( all( M(I).adams_operator(3).duality_pairing(S(J))
....: == M(I).duality_pairing(S(J).verschiebung(3))
....: for I in Compositions(2) )
....: for J in Compositions(3) )
Expand Down Expand Up @@ -2767,8 +2767,8 @@ def verschiebung(self, n):

:meth:`verschiebung method of NCSF
<sage.combinat.ncsf_qsym.ncsf.NonCommutativeSymmetricFunctions.Bases.ElementMethods.verschiebung>`,
:meth:`frobenius method of QSym
<sage.combinat.ncsf_qsym.qsym.QuasiSymmetricFunctions.Bases.ElementMethods.frobenius>`,
:meth:`adams_operator method of QSym
<sage.combinat.ncsf_qsym.qsym.QuasiSymmetricFunctions.Bases.ElementMethods.adams_operator>`,
:meth:`verschiebung method of Sym
<sage.combinat.sf.sfa.SymmetricFunctionAlgebra_generic_Element.verschiebung>`

Expand Down Expand Up @@ -3343,8 +3343,8 @@ def verschiebung(self, n):

:meth:`verschiebung method of NCSF
<sage.combinat.ncsf_qsym.ncsf.NonCommutativeSymmetricFunctions.Bases.ElementMethods.verschiebung>`,
:meth:`frobenius method of QSym
<sage.combinat.ncsf_qsym.qsym.QuasiSymmetricFunctions.Bases.ElementMethods.frobenius>`,
:meth:`adams_operator method of QSym
<sage.combinat.ncsf_qsym.qsym.QuasiSymmetricFunctions.Bases.ElementMethods.adams_operator>`,
:meth:`verschiebung method of Sym
<sage.combinat.sf.sfa.SymmetricFunctionAlgebra_generic_Element.verschiebung>`

Expand Down Expand Up @@ -3984,8 +3984,8 @@ def verschiebung(self, n):

:meth:`verschiebung method of NCSF
<sage.combinat.ncsf_qsym.ncsf.NonCommutativeSymmetricFunctions.Bases.ElementMethods.verschiebung>`,
:meth:`frobenius method of QSym
<sage.combinat.ncsf_qsym.qsym.QuasiSymmetricFunctions.Bases.ElementMethods.frobenius>`,
:meth:`adams_operator method of QSym
<sage.combinat.ncsf_qsym.qsym.QuasiSymmetricFunctions.Bases.ElementMethods.adams_operator>`,
:meth:`verschiebung method of Sym
<sage.combinat.sf.sfa.SymmetricFunctionAlgebra_generic_Element.verschiebung>`

Expand Down Expand Up @@ -4245,8 +4245,8 @@ def verschiebung(self, n):

:meth:`verschiebung method of NCSF
<sage.combinat.ncsf_qsym.ncsf.NonCommutativeSymmetricFunctions.Bases.ElementMethods.verschiebung>`,
:meth:`frobenius method of QSym
<sage.combinat.ncsf_qsym.qsym.QuasiSymmetricFunctions.Bases.ElementMethods.frobenius>`,
:meth:`adams_operator method of QSym
<sage.combinat.ncsf_qsym.qsym.QuasiSymmetricFunctions.Bases.ElementMethods.adams_operator>`,
:meth:`verschiebung method of Sym
<sage.combinat.sf.sfa.SymmetricFunctionAlgebra_generic_Element.verschiebung>`

Expand Down
53 changes: 28 additions & 25 deletions src/sage/combinat/ncsf_qsym/qsym.py
Expand Up @@ -102,6 +102,7 @@
from sage.combinat.words.word import Word
from sage.combinat.tableau import StandardTableaux
from sage.misc.cachefunc import cached_method
from sage.misc.superseded import deprecated_function_alias


class QuasiSymmetricFunctions(UniqueRepresentation, Parent):
Expand Down Expand Up @@ -1064,12 +1065,12 @@ def internal_coproduct(self):

kronecker_coproduct = internal_coproduct

def frobenius(self, n):
def adams_operator(self, n):
r"""
Return the image of the quasi-symmetric function ``self``
under the `n`-th Frobenius operator.
under the `n`-th Adams operator.

The `n`-th Frobenius operator `\mathbf{f}_n` is defined to be
The `n`-th Adams operator `\mathbf{f}_n` is defined to be
the map from the `R`-algebra of quasi-symmetric functions
to itself that sends every symmetric function
`P(x_1, x_2, x_3, \ldots)` to
Expand All @@ -1084,18 +1085,18 @@ def frobenius(self, n):
for every composition `(i_1, i_2, i_3, \ldots)`
(where `M` means the monomial basis).

The `n`-th Frobenius operator is also called the `n`-th
The `n`-th Adams operator is also called the `n`-th
Frobenius endomorphism. It is not related to the Frobenius map
which connects the ring of symmetric functions with the
representation theory of the symmetric group.

The `n`-th Frobenius operator is also the `n`-th Adams operator
The `n`-th Adams operator is the `n`-th Adams operator
of the `\Lambda`-ring of quasi-symmetric functions over the
integers.

The restriction of the `n`-th Frobenius operator to the
The restriction of the `n`-th Adams operator to the
subring formed by all symmetric functions is, not
unexpectedly, the `n`-th Frobenius operator of the ring of
unexpectedly, the `n`-th Adams operator of the ring of
symmetric functions.

.. SEEALSO::
Expand All @@ -1109,50 +1110,50 @@ def frobenius(self, n):

OUTPUT:

The result of applying the `n`-th Frobenius operator (on the
The result of applying the `n`-th Adams operator (on the
ring of quasi-symmetric functions) to ``self``.

EXAMPLES::

sage: QSym = QuasiSymmetricFunctions(ZZ)
sage: M = QSym.M()
sage: F = QSym.F()
sage: M[3,2].frobenius(2)
sage: M[3,2].adams_operator(2)
M[6, 4]
sage: (M[2,1] - 2*M[3]).frobenius(4)
sage: (M[2,1] - 2*M[3]).adams_operator(4)
M[8, 4] - 2*M[12]
sage: M([]).frobenius(3)
sage: M([]).adams_operator(3)
M[]
sage: F[1,1].frobenius(2)
sage: F[1,1].adams_operator(2)
F[1, 1, 1, 1] - F[1, 1, 2] - F[2, 1, 1] + F[2, 2]

The Frobenius endomorphisms are multiplicative::
The Adams endomorphisms are multiplicative::

sage: all( all( M(I).frobenius(3) * M(J).frobenius(3)
....: == (M(I) * M(J)).frobenius(3)
sage: all( all( M(I).adams_operator(3) * M(J).adams_operator(3)
....: == (M(I) * M(J)).adams_operator(3)
....: for I in Compositions(3) )
....: for J in Compositions(2) )
True

Being Hopf algebra endomorphisms, the Frobenius operators
Being Hopf algebra endomorphisms, the Adams operators
commute with the antipode::

sage: all( M(I).frobenius(4).antipode()
....: == M(I).antipode().frobenius(4)
sage: all( M(I).adams_operator(4).antipode()
....: == M(I).antipode().adams_operator(4)
....: for I in Compositions(3) )
True

The restriction of the Frobenius operators to the subring
of symmetric functions are the Frobenius operators of
The restriction of the Adams operators to the subring
of symmetric functions are the Adams operators of
the latter::

sage: e = SymmetricFunctions(ZZ).e()
sage: all( M(e(lam)).frobenius(3)
....: == M(e(lam).frobenius(3))
sage: all( M(e(lam)).adams_operator(3)
....: == M(e(lam).adams_operator(3))
....: for lam in Partitions(3) )
True
"""
# Convert to the monomial basis, there apply Frobenius componentwise,
# Convert to the monomial basis, there apply componentwise,
# then convert back.
parent = self.parent()
M = parent.realization_of().M()
Expand All @@ -1162,6 +1163,8 @@ def frobenius(self, n):
result_in_M_basis = M._from_dict(dct)
return parent(result_in_M_basis)

frobenius = deprecated_function_alias(36396, adams_operator)

def star_involution(self):
r"""
Return the image of the quasisymmetric function ``self`` under
Expand Down Expand Up @@ -1825,8 +1828,8 @@ def lambda_of_monomial(self, I, n):
`\lambda^i(x_j)` is `x_j` if `i = 1` and `0` if `i > 1`).

The Adams operations of this `\lambda`-ring are the
Frobenius endomorphisms `\mathbf{f}_n` (see
:meth:`~sage.combinat.ncsf_qsym.qsym.QuasiSymmetricFunctions.Bases.ElementMethods.frobenius`
Adams endomorphisms `\mathbf{f}_n` (see
:meth:`~sage.combinat.ncsf_qsym.qsym.QuasiSymmetricFunctions.Bases.ElementMethods.adams_operator`
for their definition). Using these endomorphisms, the
`\lambda`-operations can be explicitly computed via the formula

Expand Down