*****************************************************************************
*       www.FindStat.org - The Combinatorial Statistic Finder               *
*                                                                           *
*       Copyright (C) 2019 The FindStatCrew <info@findstat.org>             *
*                                                                           *
*    This information is distributed in the hope that it will be useful,    *
*    but WITHOUT ANY WARRANTY; without even the implied warranty of         *
*    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.                   *
*****************************************************************************

-----------------------------------------------------------------------------
Statistic identifier: St000936

-----------------------------------------------------------------------------
Collection: Integer partitions

-----------------------------------------------------------------------------
Description: The number of even values of the symmetric group character corresponding to the partition.

For example, the character values of the irreducible representation $S^{(2,2)}$ are $2$ on the conjugacy classes $(4)$ and $(2,2)$, $0$ on the conjugacy classes $(3,1)$ and $(1,1,1,1)$, and $-1$ on the conjugace class $(2,1,1)$.  Therefore, the statistic on the partition $(2,2)$ is $4$.

It is shown in [1] that the sum of the values of the statistic over all partitions of a given size is even. 


-----------------------------------------------------------------------------
References: [1]   Miller, A. R. Note on parity and the irreducible characters of the symmetric group [[arXiv:1708.03267]]

-----------------------------------------------------------------------------
Code:
def table(n):
    s = SymmetricFunctions(ZZ).s()
    p = SymmetricFunctions(ZZ).p()
    res = dict()
    P = Partitions(n)
    r = P.cardinality()
    for mu in P:
        res[mu] = [0]*r
    for i, la in enumerate(P):
        for mu, v in s(p(la)):
            res[mu][i] = v
    return res

def statistic(la):
    t = table(la.size())
    return len([1 for e in t[la] if is_even(e)])


-----------------------------------------------------------------------------
Statistic values:

[2]                       => 0
[1,1]                     => 0
[3]                       => 0
[2,1]                     => 2
[1,1,1]                   => 0
[4]                       => 0
[3,1]                     => 1
[2,2]                     => 4
[2,1,1]                   => 1
[1,1,1,1]                 => 0
[5]                       => 0
[4,1]                     => 4
[3,2]                     => 1
[3,1,1]                   => 6
[2,2,1]                   => 1
[2,1,1,1]                 => 4
[1,1,1,1,1]               => 0
[6]                       => 0
[5,1]                     => 3
[4,2]                     => 4
[4,1,1]                   => 7
[3,3]                     => 3
[3,2,1]                   => 10
[3,1,1,1]                 => 7
[2,2,2]                   => 3
[2,2,1,1]                 => 4
[2,1,1,1,1]               => 3
[1,1,1,1,1,1]             => 0
[7]                       => 0
[6,1]                     => 8
[5,2]                     => 11
[5,1,1]                   => 4
[4,3]                     => 9
[4,2,1]                   => 3
[4,1,1,1]                 => 14
[3,3,1]                   => 3
[3,2,2]                   => 3
[3,2,1,1]                 => 3
[3,1,1,1,1]               => 4
[2,2,2,1]                 => 9
[2,2,1,1,1]               => 11
[2,1,1,1,1,1]             => 8
[1,1,1,1,1,1,1]           => 0
[8]                       => 0
[7,1]                     => 7
[6,2]                     => 13
[6,1,1]                   => 9
[5,3]                     => 13
[5,2,1]                   => 18
[5,1,1,1]                 => 8
[4,4]                     => 15
[4,3,1]                   => 14
[4,2,2]                   => 15
[4,2,1,1]                 => 21
[4,1,1,1,1]               => 8
[3,3,2]                   => 21
[3,3,1,1]                 => 15
[3,2,2,1]                 => 14
[3,2,1,1,1]               => 18
[3,1,1,1,1,1]             => 9
[2,2,2,2]                 => 15
[2,2,2,1,1]               => 13
[2,2,1,1,1,1]             => 13
[2,1,1,1,1,1,1]           => 7
[1,1,1,1,1,1,1,1]         => 0
[9]                       => 0
[8,1]                     => 15
[7,2]                     => 11
[7,1,1]                   => 19
[6,3]                     => 25
[6,2,1]                   => 8
[6,1,1,1]                 => 18
[5,4]                     => 20
[5,3,1]                   => 24
[5,2,2]                   => 22
[5,2,1,1]                 => 9
[5,1,1,1,1]               => 29
[4,4,1]                   => 19
[4,3,2]                   => 18
[4,3,1,1]                 => 17
[4,2,2,1]                 => 17
[4,2,1,1,1]               => 9
[4,1,1,1,1,1]             => 18
[3,3,3]                   => 29
[3,3,2,1]                 => 18
[3,3,1,1,1]               => 22
[3,2,2,2]                 => 19
[3,2,2,1,1]               => 24
[3,2,1,1,1,1]             => 8
[3,1,1,1,1,1,1]           => 19
[2,2,2,2,1]               => 20
[2,2,2,1,1,1]             => 25
[2,2,1,1,1,1,1]           => 11
[2,1,1,1,1,1,1,1]         => 15
[1,1,1,1,1,1,1,1,1]       => 0
[10]                      => 0
[9,1]                     => 15
[8,2]                     => 19
[8,1,1]                   => 23
[7,3]                     => 19
[7,2,1]                   => 32
[7,1,1,1]                 => 22
[6,4]                     => 25
[6,3,1]                   => 8
[6,2,2]                   => 19
[6,2,1,1]                 => 25
[6,1,1,1,1]               => 28
[5,5]                     => 28
[5,4,1]                   => 33
[5,3,2]                   => 27
[5,3,1,1]                 => 24
[5,2,2,1]                 => 18
[5,2,1,1,1]               => 41
[5,1,1,1,1,1]             => 28
[4,4,2]                   => 26
[4,4,1,1]                 => 23
[4,3,3]                   => 28
[4,3,2,1]                 => 41
[4,3,1,1,1]               => 18
[4,2,2,2]                 => 23
[4,2,2,1,1]               => 24
[4,2,1,1,1,1]             => 25
[4,1,1,1,1,1,1]           => 22
[3,3,3,1]                 => 28
[3,3,2,2]                 => 26
[3,3,2,1,1]               => 27
[3,3,1,1,1,1]             => 19
[3,2,2,2,1]               => 33
[3,2,2,1,1,1]             => 8
[3,2,1,1,1,1,1]           => 32
[3,1,1,1,1,1,1,1]         => 23
[2,2,2,2,2]               => 28
[2,2,2,2,1,1]             => 25
[2,2,2,1,1,1,1]           => 19
[2,2,1,1,1,1,1,1]         => 19
[2,1,1,1,1,1,1,1,1]       => 15
[1,1,1,1,1,1,1,1,1,1]     => 0
[11]                      => 0
[10,1]                    => 27
[9,2]                     => 33
[9,1,1]                   => 23
[8,3]                     => 35
[8,2,1]                   => 18
[8,1,1,1]                 => 42
[7,4]                     => 8
[7,3,1]                   => 38
[7,2,2]                   => 22
[7,2,1,1]                 => 43
[7,1,1,1,1]               => 35
[6,5]                     => 43
[6,4,1]                   => 22
[6,3,2]                   => 34
[6,3,1,1]                 => 46
[6,2,2,1]                 => 49
[6,2,1,1,1]               => 32
[6,1,1,1,1,1]             => 55
[5,5,1]                   => 35
[5,4,2]                   => 44
[5,4,1,1]                 => 16
[5,3,3]                   => 35
[5,3,2,1]                 => 34
[5,3,1,1,1]               => 34
[5,2,2,2]                 => 27
[5,2,2,1,1]               => 34
[5,2,1,1,1,1]             => 32
[5,1,1,1,1,1,1]           => 35
[4,4,3]                   => 38
[4,4,2,1]                 => 44
[4,4,1,1,1]               => 27
[4,3,3,1]                 => 55
[4,3,2,2]                 => 44
[4,3,2,1,1]               => 34
[4,3,1,1,1,1]             => 49
[4,2,2,2,1]               => 16
[4,2,2,1,1,1]             => 46
[4,2,1,1,1,1,1]           => 43
[4,1,1,1,1,1,1,1]         => 42
[3,3,3,2]                 => 38
[3,3,3,1,1]               => 35
[3,3,2,2,1]               => 44
[3,3,2,1,1,1]             => 34
[3,3,1,1,1,1,1]           => 22
[3,2,2,2,2]               => 35
[3,2,2,2,1,1]             => 22
[3,2,2,1,1,1,1]           => 38
[3,2,1,1,1,1,1,1]         => 18
[3,1,1,1,1,1,1,1,1]       => 23
[2,2,2,2,2,1]             => 43
[2,2,2,2,1,1,1]           => 8
[2,2,2,1,1,1,1,1]         => 35
[2,2,1,1,1,1,1,1,1]       => 33
[2,1,1,1,1,1,1,1,1,1]     => 27
[1,1,1,1,1,1,1,1,1,1,1]   => 0
[12]                      => 0
[11,1]                    => 29
[10,2]                    => 42
[10,1,1]                  => 35
[9,3]                     => 42
[9,2,1]                   => 55
[9,1,1,1]                 => 36
[8,4]                     => 32
[8,3,1]                   => 37
[8,2,2]                   => 44
[8,2,1,1]                 => 22
[8,1,1,1,1]               => 44
[7,5]                     => 24
[7,4,1]                   => 71
[7,3,2]                   => 40
[7,3,1,1]                 => 46
[7,2,2,1]                 => 39
[7,2,1,1,1]               => 59
[7,1,1,1,1,1]             => 49
[6,6]                     => 60
[6,5,1]                   => 23
[6,4,2]                   => 50
[6,4,1,1]                 => 50
[6,3,3]                   => 45
[6,3,2,1]                 => 73
[6,3,1,1,1]               => 67
[6,2,2,2]                 => 44
[6,2,2,1,1]               => 62
[6,2,1,1,1,1]             => 76
[6,1,1,1,1,1,1]           => 49
[5,5,2]                   => 48
[5,5,1,1]                 => 40
[5,4,3]                   => 59
[5,4,2,1]                 => 41
[5,4,1,1,1]               => 57
[5,3,3,1]                 => 49
[5,3,2,2]                 => 44
[5,3,2,1,1]               => 76
[5,3,1,1,1,1]             => 62
[5,2,2,2,1]               => 57
[5,2,2,1,1,1]             => 67
[5,2,1,1,1,1,1]           => 59
[5,1,1,1,1,1,1,1]         => 44
[4,4,4]                   => 55
[4,4,3,1]                 => 47
[4,4,2,2]                 => 76
[4,4,2,1,1]               => 44
[4,4,1,1,1,1]             => 44
[4,3,3,2]                 => 47
[4,3,3,1,1]               => 49
[4,3,2,2,1]               => 41
[4,3,2,1,1,1]             => 73
[4,3,1,1,1,1,1]           => 39
[4,2,2,2,2]               => 40
[4,2,2,2,1,1]             => 50
[4,2,2,1,1,1,1]           => 46
[4,2,1,1,1,1,1,1]         => 22
[4,1,1,1,1,1,1,1,1]       => 36
[3,3,3,3]                 => 55
[3,3,3,2,1]               => 59
[3,3,3,1,1,1]             => 45
[3,3,2,2,2]               => 48
[3,3,2,2,1,1]             => 50
[3,3,2,1,1,1,1]           => 40
[3,3,1,1,1,1,1,1]         => 44
[3,2,2,2,2,1]             => 23
[3,2,2,2,1,1,1]           => 71
[3,2,2,1,1,1,1,1]         => 37
[3,2,1,1,1,1,1,1,1]       => 55
[3,1,1,1,1,1,1,1,1,1]     => 35
[2,2,2,2,2,2]             => 60
[2,2,2,2,2,1,1]           => 24
[2,2,2,2,1,1,1,1]         => 32
[2,2,2,1,1,1,1,1,1]       => 42
[2,2,1,1,1,1,1,1,1,1]     => 42
[2,1,1,1,1,1,1,1,1,1,1]   => 29
[1,1,1,1,1,1,1,1,1,1,1,1] => 0

-----------------------------------------------------------------------------
Created: Aug 11, 2017 at 22:54 by Martin Rubey

-----------------------------------------------------------------------------
Last Updated: Aug 11, 2017 at 22:54 by Martin Rubey