AUTHORS:
Bases: sage.categories.realizations.Category_realization_of_parent
Category of multiplicative bases of symmetric functions in non-commuting variables.
A multiplicative basis is one for which
where
is the pipe() operation
on set partitions.
EXAMPLES:
sage: from sage.combinat.ncsym.bases import MultiplicativeNCSymBases
sage: NCSym = SymmetricFunctionsNonCommutingVariables(QQ)
sage: MultiplicativeNCSymBases(NCSym)
Category of multiplicative bases of symmetric functions in non-commuting variables over the Rational Field
The product on basis elements.
The product on a multiplicative basis is given by
.
The bases
are all multiplicative.
INPUT:
OUTPUT:
EXAMPLES:
sage: e = SymmetricFunctionsNonCommutingVariables(QQ).e()
sage: h = SymmetricFunctionsNonCommutingVariables(QQ).h()
sage: x = SymmetricFunctionsNonCommutingVariables(QQ).x()
sage: q = SymmetricFunctionsNonCommutingVariables(QQ).q()
sage: p = SymmetricFunctionsNonCommutingVariables(QQ).p()
sage: A = SetPartition([[1], [2, 3]])
sage: B = SetPartition([[1], [3], [2,4]])
sage: e.product_on_basis(A, B)
e{{1}, {2, 3}, {4}, {5, 7}, {6}}
sage: h.product_on_basis(A, B)
h{{1}, {2, 3}, {4}, {5, 7}, {6}}
sage: x.product_on_basis(A, B)
x{{1}, {2, 3}, {4}, {5, 7}, {6}}
sage: q.product_on_basis(A, B)
q{{1}, {2, 3}, {4}, {5, 7}, {6}}
sage: p.product_on_basis(A, B)
p{{1}, {2, 3}, {4}, {5, 7}, {6}}
sage: e.product_on_basis(A,B)==e(h(e(A))*h(e(B)))
True
sage: h.product_on_basis(A,B)==h(x(h(A))*x(h(B)))
True
sage: x.product_on_basis(A,B)==x(h(x(A))*h(x(B)))
True
sage: q.product_on_basis(A,B)==q(p(q(A))*p(q(B)))
True
sage: p.product_on_basis(A,B)==p(e(p(A))*e(p(B)))
True
Return the super categories of bases of the Hopf dual of the symmetric functions in non-commuting variables.
OUTPUT:
TESTS:
sage: from sage.combinat.ncsym.bases import MultiplicativeNCSymBases
sage: NCSym = SymmetricFunctionsNonCommutingVariables(QQ)
sage: MultiplicativeNCSymBases(NCSym).super_categories()
[Category of bases of symmetric functions in non-commuting variables over the Rational Field]
Bases: sage.categories.realizations.Category_realization_of_parent
Category of bases of symmetric functions in non-commuting variables.
EXAMPLES:
sage: from sage.combinat.ncsym.bases import NCSymBases
sage: NCSym = SymmetricFunctionsNonCommutingVariables(QQ)
sage: NCSymBases(NCSym)
Category of bases of symmetric functions in non-commuting variables over the Rational Field
Expand the symmetric function into n non-commuting variables in an alphabet, which by default is 'x'.
This computation is completed by coercing the element self into the monomial basis and computing the expansion in the alphabet there.
INPUT:
OUTPUT:
EXAMPLES:
sage: h = SymmetricFunctionsNonCommutingVariables(QQ).h()
sage: h[[1,3],[2]].expand(3)
2*x0^3 + x0^2*x1 + x0^2*x2 + 2*x0*x1*x0 + x0*x1^2 + x0*x1*x2 + 2*x0*x2*x0
+ x0*x2*x1 + x0*x2^2 + x1*x0^2 + 2*x1*x0*x1 + x1*x0*x2 + x1^2*x0 + 2*x1^3
+ x1^2*x2 + x1*x2*x0 + 2*x1*x2*x1 + x1*x2^2 + x2*x0^2 + x2*x0*x1 + 2*x2*x0*x2
+ x2*x1*x0 + x2*x1^2 + 2*x2*x1*x2 + x2^2*x0 + x2^2*x1 + 2*x2^3
sage: x = SymmetricFunctionsNonCommutingVariables(QQ).x()
sage: x[[1,3],[2]].expand(3)
-x0^2*x1 - x0^2*x2 - x0*x1^2 - x0*x1*x2 - x0*x2*x1 - x0*x2^2 - x1*x0^2
- x1*x0*x2 - x1^2*x0 - x1^2*x2 - x1*x2*x0 - x1*x2^2 - x2*x0^2 - x2*x0*x1
- x2*x1*x0 - x2*x1^2 - x2^2*x0 - x2^2*x1
Return the internal coproduct of self.
The internal coproduct is defined on the power sum basis as
and the map is extended linearly.
OUTPUT:
EXAMPLES:
sage: x = SymmetricFunctionsNonCommutingVariables(QQ).x()
sage: x[[1,3],[2]].internal_coproduct()
x{{1}, {2}, {3}} # x{{1, 3}, {2}} + x{{1, 3}, {2}} # x{{1}, {2}, {3}}
+ x{{1, 3}, {2}} # x{{1, 3}, {2}}
Return the involution applied to self.
The involution is defined by
and the result is extended linearly.
OUTPUT:
EXAMPLES:
sage: NCSym = SymmetricFunctionsNonCommutingVariables(QQ)
sage: m = NCSym.m()
sage: m[[1,3],[2]].omega()
-2*m{{1, 2, 3}} - m{{1, 3}, {2}}
sage: p = NCSym.p()
sage: p[[1,3],[2]].omega()
-p{{1, 3}, {2}}
sage: q = NCSym.q()
sage: q[[1,3],[2]].omega()
-2*q{{1, 2, 3}} - q{{1, 3}, {2}}
sage: x = NCSym.x()
sage: x[[1,3],[2]].omega()
-2*x{{1}, {2}, {3}} - x{{1, 3}, {2}}
Compute the projection of an element of symmetric function in non-commuting variables to the symmetric functions.
The projection of a monomial symmetric function in non-commuting variables indexed by the set partition A is defined as
where is the partition associated with
by
taking the sizes of the parts and
is the
multiplicity of
in
. For other bases this map is extended
linearly.
OUTPUT:
EXAMPLES:
sage: NCSym = SymmetricFunctionsNonCommutingVariables(QQ)
sage: e = NCSym.e()
sage: h = NCSym.h()
sage: p = NCSym.p()
sage: q = NCSym.q()
sage: x = NCSym.x()
sage: q[[1,3],[2]].to_symmetric_function()
m[2, 1]
sage: x[[1,3],[2]].to_symmetric_function()
-6*m[1, 1, 1] - 2*m[2, 1]
sage: e[[1,3],[2]].to_symmetric_function()
2*e[2, 1]
sage: h[[1,3],[2]].to_symmetric_function()
2*h[2, 1]
sage: p[[1,3],[2]].to_symmetric_function()
p[2, 1]
Return the image of the symmetric function f in self.
This is performed by converting to the monomial basis and extending the method sum_of_partitions() linearly. This is a linear map from the symmetric functions to the symmetric functions in non-commuting variables that does not preserve the product or coproduct structure of the Hopf algebra.
See also
to_symmetric_function()
INPUT:
OUTPUT:
EXAMPLES:
sage: NCSym = SymmetricFunctionsNonCommutingVariables(QQ)
sage: Sym = SymmetricFunctions(QQ)
sage: e = NCSym.e()
sage: elem = Sym.e()
sage: elt = e.from_symmetric_function(elem[2,1,1]); elt
1/12*e{{1}, {2}, {3, 4}} + 1/12*e{{1}, {2, 3}, {4}} + 1/12*e{{1}, {2, 4}, {3}}
+ 1/12*e{{1, 2}, {3}, {4}} + 1/12*e{{1, 3}, {2}, {4}} + 1/12*e{{1, 4}, {2}, {3}}
sage: elem(elt.to_symmetric_function())
e[2, 1, 1]
sage: e.from_symmetric_function(elem[4])
1/24*e{{1, 2, 3, 4}}
sage: p = NCSym.p()
sage: pow = Sym.p()
sage: elt = p.from_symmetric_function(pow[2,1,1]); elt
1/6*p{{1}, {2}, {3, 4}} + 1/6*p{{1}, {2, 3}, {4}} + 1/6*p{{1}, {2, 4}, {3}}
+ 1/6*p{{1, 2}, {3}, {4}} + 1/6*p{{1, 3}, {2}, {4}} + 1/6*p{{1, 4}, {2}, {3}}
sage: pow(elt.to_symmetric_function())
p[2, 1, 1]
sage: p.from_symmetric_function(pow[4])
p{{1, 2, 3, 4}}
sage: h = NCSym.h()
sage: comp = Sym.complete()
sage: elt = h.from_symmetric_function(comp[2,1,1]); elt
1/12*h{{1}, {2}, {3, 4}} + 1/12*h{{1}, {2, 3}, {4}} + 1/12*h{{1}, {2, 4}, {3}}
+ 1/12*h{{1, 2}, {3}, {4}} + 1/12*h{{1, 3}, {2}, {4}} + 1/12*h{{1, 4}, {2}, {3}}
sage: comp(elt.to_symmetric_function())
h[2, 1, 1]
sage: h.from_symmetric_function(comp[4])
1/24*h{{1, 2, 3, 4}}
Compute the internal coproduct of self.
If internal_coproduct_on_basis() is available, construct
the internal coproduct morphism from self to self
self by extending it by linearity. Otherwise, this uses
internal_coproduct_by_coercion(), if available.
OUTPUT:
EXAMPLES:
sage: q = SymmetricFunctionsNonCommutingVariables(QQ).q()
sage: q.internal_coproduct(q[[1,3],[2]] - 2*q[[1]])
-2*q{{1}} # q{{1}} + q{{1, 2, 3}} # q{{1, 3}, {2}} + q{{1, 3}, {2}} # q{{1, 2, 3}}
+ q{{1, 3}, {2}} # q{{1, 3}, {2}}
Return the internal coproduct by coercing the element to the powersum basis.
INPUT:
OUTPUT:
EXAMPLES:
sage: h = SymmetricFunctionsNonCommutingVariables(QQ).h()
sage: h[[1,3],[2]].internal_coproduct() # indirect doctest
2*h{{1}, {2}, {3}} # h{{1}, {2}, {3}} - h{{1}, {2}, {3}} # h{{1, 3}, {2}}
- h{{1, 3}, {2}} # h{{1}, {2}, {3}} + h{{1, 3}, {2}} # h{{1, 3}, {2}}
The internal coproduct of the algebra on the basis (optional).
INPUT:
OUPUT:
EXAMPLES:
sage: m = SymmetricFunctionsNonCommutingVariables(QQ).m()
sage: m.internal_coproduct_on_basis(SetPartition([[1,2]]))
m{{1, 2}} # m{{1, 2}}
Return the primitive associated to A in self.
See also
INPUT:
OUTPUT:
EXAMPLES:
sage: e = SymmetricFunctionsNonCommutingVariables(QQ).e()
sage: elt = e.primitive(SetPartition([[1,3],[2]])); elt
e{{1, 2}, {3}} - e{{1, 3}, {2}}
sage: elt.coproduct()
e{} # e{{1, 2}, {3}} - e{} # e{{1, 3}, {2}} + e{{1, 2}, {3}} # e{} - e{{1, 3}, {2}} # e{}
Return the super categories of bases of the Hopf dual of the symmetric functions in non-commuting variables.
OUTPUT:
TESTS:
sage: from sage.combinat.ncsym.bases import NCSymBases
sage: NCSym = SymmetricFunctionsNonCommutingVariables(QQ)
sage: NCSymBases(NCSym).super_categories()
[Category of bases of NCSym or NCSym^* over the Rational Field]
Bases: sage.combinat.free_module.CombinatorialFreeModule, sage.misc.bindable_class.BindableClass
Abstract base class for a basis of or its dual.
Bases: sage.categories.realizations.Category_realization_of_parent
Category of bases of dual symmetric functions in non-commuting variables.
EXAMPLES:
sage: from sage.combinat.ncsym.bases import NCSymDualBases
sage: DNCSym = SymmetricFunctionsNonCommutingVariables(QQ).dual()
sage: NCSymDualBases(DNCSym)
Category of bases of dual symmetric functions in non-commuting variables over the Rational Field
Return the super categories of bases of the Hopf dual of the symmetric functions in non-commuting variables.
OUTPUT:
TESTS:
sage: from sage.combinat.ncsym.bases import NCSymBases
sage: NCSym = SymmetricFunctionsNonCommutingVariables(QQ)
sage: NCSymBases(NCSym).super_categories()
[Category of bases of NCSym or NCSym^* over the Rational Field]
Bases: sage.categories.realizations.Category_realization_of_parent
Base category for the category of bases of symmetric functions in non-commuting variables or its Hopf dual for the common code.
Compute the pairing between self and an element other of the dual.
EXAMPLES:
sage: NCSym = SymmetricFunctionsNonCommutingVariables(QQ)
sage: m = NCSym.m()
sage: w = m.dual_basis()
sage: elt = m[[1,3],[2]] - 3*m[[1,2],[3]]
sage: elt.duality_pairing(w[[1,3],[2]])
1
sage: elt.duality_pairing(w[[1,2],[3]])
-3
sage: elt.duality_pairing(w[[1,2]])
0
sage: e = NCSym.e()
sage: w[[1,3],[2]].duality_pairing(e[[1,3],[2]])
0
The counit is defined by sending all elements of positive degree to zero.
INPUT:
OUPUT:
EXAMPLES:
sage: m = SymmetricFunctionsNonCommutingVariables(QQ).m()
sage: m.counit_on_basis(SetPartition([[1,3], [2]]))
0
sage: m.counit_on_basis(SetPartition([]))
1
sage: w = SymmetricFunctionsNonCommutingVariables(QQ).dual().w()
sage: w.counit_on_basis(SetPartition([[1,3], [2]]))
0
sage: w.counit_on_basis(SetPartition([]))
1
Compute the pairing between an element of self and an element of the dual.
Carry out this computation by converting x to the
basis and y to the
basis.
INPUT:
OUTPUT:
EXAMPLES:
sage: NCSym = SymmetricFunctionsNonCommutingVariables(QQ)
sage: h = NCSym.h()
sage: w = NCSym.m().dual_basis()
sage: matrix([[h(A).duality_pairing(w(B)) for A in SetPartitions(3)] for B in SetPartitions(3)])
[6 2 2 2 1]
[2 2 1 1 1]
[2 1 2 1 1]
[2 1 1 2 1]
[1 1 1 1 1]
sage: (h[[1,2],[3]] + 3*h[[1,3],[2]]).duality_pairing(2*w[[1,3],[2]] + w[[1,2,3]] + 2*w[[1,2],[3]])
32
The matrix of scalar products between elements of and
elements of
.
INPUT:
OUTPUT:
EXAMPLES:
The matrix between the basis and the
basis:
sage: NCSym = SymmetricFunctionsNonCommutingVariables(QQ)
sage: m = NCSym.m()
sage: w = NCSym.dual().w()
sage: m.duality_pairing_matrix(w, 3)
[1 0 0 0 0]
[0 1 0 0 0]
[0 0 1 0 0]
[0 0 0 1 0]
[0 0 0 0 1]
Similarly for some of the other basis of and the
basis:
sage: e = NCSym.e()
sage: e.duality_pairing_matrix(w, 3)
[0 0 0 0 1]
[0 0 1 1 1]
[0 1 0 1 1]
[0 1 1 0 1]
[1 1 1 1 1]
sage: p = NCSym.p()
sage: p.duality_pairing_matrix(w, 3)
[1 0 0 0 0]
[1 1 0 0 0]
[1 0 1 0 0]
[1 0 0 1 0]
[1 1 1 1 1]
sage: q = NCSym.q()
sage: q.duality_pairing_matrix(w, 3)
[1 0 0 0 0]
[1 1 0 0 0]
[0 0 1 0 0]
[1 0 0 1 0]
[1 1 1 1 1]
sage: x = NCSym.x()
sage: w.duality_pairing_matrix(x, 3)
[ 0 0 0 0 1]
[ 1 0 -1 -1 1]
[ 1 -1 0 -1 1]
[ 1 -1 -1 0 1]
[ 2 -1 -1 -1 1]
A base case test:
sage: m.duality_pairing_matrix(w, 0)
[1]
Return the index of the basis element containing .
OUTPUT:
EXAMPLES:
sage: m = SymmetricFunctionsNonCommutingVariables(QQ).m()
sage: m.one_basis()
{}
sage: w = SymmetricFunctionsNonCommutingVariables(QQ).dual().w()
sage: w.one_basis()
{}
Return the super categories of bases of (the Hopf dual of) the symmetric functions in non-commuting variables.
OUTPUT:
TESTS:
sage: from sage.combinat.ncsym.bases import NCSymOrNCSymDualBases
sage: NCSym = SymmetricFunctionsNonCommutingVariables(QQ)
sage: NCSymOrNCSymDualBases(NCSym).super_categories()
[Category of realizations of Symmetric functions in non-commuting variables over the Rational Field,
Category of graded hopf algebras with basis over Rational Field,
Join of Category of graded hopf algebras over Rational Field
and Category of realizations of hopf algebras over Rational Field]