def exterior_power(self, n): r""" Returns the anti-symmetrized product of self with itself ``n`` times. INPUT: - ``n`` -- a positive integer. OUTPUT: The ``n``-th anti-symmetrized power of ``self`` as a :class:`ClassFunction`. EXAMPLES:: sage: chi = ClassFunction(SymmetricGroup(4), [3, 1, -1, 0, -1]) sage: p = chi.exterior_power(3) # the highest anti-symmetric power for a 3-d character sage: p Character of Symmetric group of order 4! as a permutation group sage: p.values() [1, -1, 1, 1, -1] sage: p == chi.determinant_character() True """ n = Integer(n) tbl = gap.UnderlyingCharacterTable(self) return ClassFunction(self._group, gap.AntiSymmetricParts(tbl, [self], n)[1])
def symmetric_power(self, n): r""" Returns the symmetrized product of self with itself ``n`` times. INPUT: - ``n`` -- a positive integer. OUTPUT: The ``n``-th symmetrized power of ``self`` as a :class:`ClassFunction`. EXAMPLES:: sage: chi = ClassFunction(SymmetricGroup(4), [3, 1, -1, 0, -1]) sage: p = chi.symmetric_power(3) sage: p Character of Symmetric group of order 4! as a permutation group sage: p.values() [10, 2, -2, 1, 0] """ n = Integer(n) tbl = gap.UnderlyingCharacterTable(self) return ClassFunction(self._group, gap.SymmetricParts(tbl, [self], n)[1])