# Power sum symmetric functions¶

class sage.combinat.sf.powersum.SymmetricFunctionAlgebra_power(Sym)

A class for methods associated to the power sum basis of the symmetric functions

INPUT:

• self – the power sum basis of the symmetric functions
• Sym – an instance of the ring of symmetric functions

TESTS:

sage: p = SymmetricFunctions(QQ).p()
True
sage: TestSuite(p).run(skip=['_test_associativity', '_test_distributivity', '_test_prod'])
sage: TestSuite(p).run(elements = [p[1,1]+p[2], p[1]+2*p[1,1]])

class Element(M, x)

Create a combinatorial module element. This should never be called directly, but only through the parent combinatorial free module’s __call__() method.

TESTS:

sage: F = CombinatorialFreeModule(QQ, ['a','b','c'])
sage: B = F.basis()
sage: f = B['a'] + 3*B['c']; f
B['a'] + 3*B['c']
True

expand(n, alphabet='x')

Expands the symmetric function as a symmetric polynomial in $$n$$ variables.

INPUT:

• self – an element of the symmetric functions in the power sum basis
• n – a positive integer
• alphabet – a variable for the expansion (default: $$x$$)

OUTPUT:

• a polynomial expansion of an instance of self in $$n$$ variables

EXAMPLES:

sage: p = SymmetricFunctions(QQ).p()
sage: a = p([2])
sage: a.expand(2)
x0^2 + x1^2
sage: a.expand(3, alphabet=['a','b','c'])
a^2 + b^2 + c^2
sage: p([2,1,1]).expand(2)
x0^4 + 2*x0^3*x1 + 2*x0^2*x1^2 + 2*x0*x1^3 + x1^4
sage: p([7]).expand(4)
x0^7 + x1^7 + x2^7 + x3^7
sage: p([7]).expand(4,alphabet='t')
t0^7 + t1^7 + t2^7 + t3^7
sage: p([7]).expand(4,alphabet='x,y,z,t')
x^7 + y^7 + z^7 + t^7
sage: p(1).expand(4)
1
sage: p(0).expand(4)
0
sage: (p([]) + 2*p([1])).expand(3)
2*x0 + 2*x1 + 2*x2 + 1

omega()

Returns the image of self under the Frobenius / omega automorphism.

INPUT:

• self – an element of the symmetric functions in the power sum basis

OUTPUT:

• the image of self under the omega automorphism

EXAMPLES:

sage: p = SymmetricFunctions(QQ).p()
sage: a = p([2,1]); a
p[2, 1]
sage: a.omega()
-p[2, 1]
sage: p([]).omega()
p[]
sage: p(0).omega()
0

scalar(x, zee=None)

Returns the standard scalar product of self and x.

INPUT:

• self – an element of the symmetric functions in the power sum basis
• x – an power sum symmetric function
• zee – optional input specifying the scalar product on the power sum basis with normalization $$<p_\mu, p_\mu> = zee(\mu)$$. zee should be a function on partitions. (default: uses standard zee function)

Note that the power-sum symmetric functions are orthogonal under this scalar product. The value of $$\langle p_\lambda, p_\lambda \rangle$$ is given by the size of the centralizer in $$S_n$$ of a permutation of cycle type $$\lambda$$.

OUTPUT:

• the standard scalar product between self and x or if the optional parameter zee is specified then the scalar product with respect to the normalization $$<p_\mu, p_\mu> = zee(\mu)$$ with the power sum bases elements are orthogonal

EXAMPLES:

sage: p = SymmetricFunctions(QQ).p()
sage: p4 = Partitions(4)
sage: matrix([ [p(a).scalar(p(b)) for a in p4] for b in p4])
[ 4  0  0  0  0]
[ 0  3  0  0  0]
[ 0  0  8  0  0]
[ 0  0  0  4  0]
[ 0  0  0  0 24]
sage: p(0).scalar(p(1))
0
sage: p(1).scalar(p(2))
2

sage: zee = lambda x : 1
sage: matrix( [[p[la].scalar(p[mu], zee) for la in Partitions(3)] for mu in Partitions(3)])
[1 0 0]
[0 1 0]
[0 0 1]

SymmetricFunctionAlgebra_power.antipode_on_basis(partition)

Returns the antipode of self[partition]. The antipode on the generator $$p_i$$ is $$-p_i$$ and the antipode on $$p_\mu$$ is $$(-1)^{length(\mu)} p_\mu$$.

INPUT:

• self – the power sum basis of the symmetric functions
• partition – a partition

OUTPUT:

• the result of the antipode on self(partition)

EXAMPLES:

sage: Sym = SymmetricFunctions(QQ)
sage: p = Sym.p()
sage: p.antipode_on_basis([2])
-p[2]
sage: p.antipode_on_basis([3])
-p[3]
sage: p.antipode_on_basis([2,2])
p[2, 2]

SymmetricFunctionAlgebra_power.coproduct_on_generators(i)

Returns coproduct on generators for power sums $$p_i$$. The elements $$p_i$$ are primitive elements.

INPUT:

• self – the power sum basis of the symmetric functions
• i – a positive integer

OUTPUT:

• the result of the coproduct on the generator $$p(i)$$

EXAMPLES:

sage: Sym = SymmetricFunctions(QQ)
sage: p = Sym.powersum()
sage: p.coproduct_on_generators(2)
p[] # p[2] + p[2] # p[]


#### Previous topic

Homogeneous symmetric functions

#### Next topic

Generic dual bases symmetric functions