Classical symmetric functions - Combinatorics

Skip to content
Back to top
View this page
Edit this page

# Classical symmetric functions

class sage.combinat.sf.classical.SymmetricFunctionAlgebra_classical(Sym, basis_name=None, prefix=None, graded=True)

  Bases: `SymmetricFunctionAlgebra_generic`

  The class of classical symmetric functions.

  Todo

  delete this class once all coercions will be handled by Sage’s coercion model

  class Element

    Bases: `SymmetricFunctionAlgebra_generic_Element`

    A symmetric function.

sage.combinat.sf.classical.init()

  Set up the conversion functions between the classical bases.

  EXAMPLES:

  Sage

      sage: from sage.combinat.sf.classical import init
      sage: sage.combinat.sf.classical.conversion_functions = {}
      sage: init()
      sage: sage.combinat.sf.classical.conversion_functions[('Schur', 'powersum')]
      <cyfunction t_SCHUR_POWSYM_symmetrica at ...>

  Python

      >>> from sage.all import *
      >>> from sage.combinat.sf.classical import init
      >>> sage.combinat.sf.classical.conversion_functions = {}
      >>> init()
      >>> sage.combinat.sf.classical.conversion_functions[('Schur', 'powersum')]
      <cyfunction t_SCHUR_POWSYM_symmetrica at ...>

  The following checks if the bug described in Issue #15312 is fixed.

  Sage

      sage: change = sage.combinat.sf.classical.conversion_functions[('powersum', 'Schur')]
      sage: hideme = change({Partition([1]*47):ZZ(1)}) # long time
      sage: change({Partition([2,2]):QQ(1)})
      s[1, 1, 1, 1] - s[2, 1, 1] + 2*s[2, 2] - s[3, 1] + s[4]

  [Python]

      >>> from sage.all import *
      >>> change = sage.combinat.sf.classical.conversion_functions[('powersum', 'Schur')]
      >>> hideme = change({Partition([Integer(1)]*Integer(47)):ZZ(Integer(1))}) # long time
      >>> change({Partition([Integer(2),Integer(2)]):QQ(Integer(1))})
      s[1, 1, 1, 1] - s[2, 1, 1] + 2*s[2, 2] - s[3, 1] + s[4]