Use generating functions to find the number of partitions of $n>1$ that have an odd number of even parts $k=1,...,10$

387 Views Asked by At

Here are some examples where we find $f(n)$ - the number of partitions that satisfy our condition:

$\boldsymbol{2} = (1+1) \rightarrow \boldsymbol{f(2)=0} $

$\boldsymbol{3} = (1+1+1) = \boldsymbol{(1+2)} \rightarrow \boldsymbol{f(3)=1} $ (we have one '2' in (1+2), which satisfies the "odd number of even parts" condition)

$\boldsymbol{4} = (1+1+1+1) = \boldsymbol{(1+1+2)} = (2+2) = (1+3) \rightarrow \boldsymbol{f(4)=1} $

$\boldsymbol{5} = (1+1+1+1+1) = \boldsymbol{(1+1+1+2)} = (1+2+2) = (1+1+3) = \boldsymbol{(1+4)} \rightarrow \boldsymbol{f(5)=2} $

$\boldsymbol{6} = (1+1+1+1+1+1) = \boldsymbol{(1+1+1+1+2)} = (1+1+2+2) = \boldsymbol{(2+2+2)} = (1+1+1+3) = (3+3) = \boldsymbol{(1+2+3)} = \boldsymbol{(1+1+4)} = (2+4) = (1+5)\rightarrow \boldsymbol{f(6)=4} $

Now how can we do this for any number $n$, keeping in mind that all parts should be in range $1,...,10$?

2

There are 2 best solutions below

1
On

The counts you look for is http://oeis.org/A000701, where you can find a generating function.
Let P(n) be the count of partitions of n, and g(n) the coefficient of x^n in
f(x)= $\prod _{k=0}^{\infty } \left(x^{2 k+1}+1\right)$
then you want (P(n)- g(n) )/2.

2
On

The generating function in the oeis entry provided by Wouter M. can be modified.

For all the parts to be in $1,2,\ldots ,10$, the g.f. is:

$\displaystyle P(x)=\frac{1}{2}\left(1-\prod_{i=1}^{5}\dfrac{1-x^{2\, i}}{1+x^{2\, i}}\right)\left(\prod_{j=1}^{10}\dfrac{1}{1-x^i}\right) $

If the partion is to have more than one part, subtract that by $\frac{x^2}{1-x^2}$