[Math] Compositions with all odd parts

combinatorics

How many compositions of n are there where all parts of the composition are odd?

I know how to solve for the number of composition when all are even. However, I'm getting stuck with finding all the odd ones.

Any help would be appreciated

Best Answer

The following lemma should help you out (or at least partially) for small cases of $n$:

The number of compositions of n into odd parts equals the number of compositions of n + 1 into parts greater than one.

proof: We'll construct a bijection. We'll start with a composition of $n$ of length $l$, $n=a_1+a_2+\dots+a_l$. We will represent this composition with a binary sequences of $n-l-1$ 0's and $l-1$ 1's, as follows:

$a_1-1$ zeros, $1$, $a_2-1$ zeros, $1$, $\dots$ $a_l-1$ zeros

(Thus, for example, the associated binary sequence to $13=3+1+5+3+1$ is $001100001001$)

Notice that a composition of $n$ where each $a_i$ is odd, then the associated binary sequence must have strings of zeros of even length. And thus if we take the conjugate composition (Which is, turn every zero in the corresponding binary sequence of the composition into a 1 and vice versa), we obtain a composition of $n$ of lenth $n-l+1$ with strings of $1$'s of even length. Denote this conjugate composition by $n-l+1=c_1+c_2+\dots+c_{n+l-1}$

(in our example, we have the conjugate composition $13=1+1+3+1+1+1+2+1+2$)

Next, we define $b_i=c_{2i-1}+c_{2i}$ for all $1\leq i \leq (n-l)/2$ and $b_{\frac{n-l}{2}+1}=c_{n-l+1}+1$ (notice how $n$ and $l$ must have the same parity)

Then $n+1=b_1+b_2+\dots +b_{\frac{n-l}{2}}+b_{\frac{n-l}{2}+1}$ is a composition of $n+1$ and length $\frac{n-l}{2}+1$, and moreover, all $b_i>1$!

(In our example: $14=2+4+2+3+3$)

To conclude the bijective relation, we have to check if all steps are reversible, but this is easy: Begin with a composition of n + 1 into parts greater than one, reduce the last part by 1, split each part $j$ (other than the last part) into the pair of parts $j − 1, 1$, and calculute the conjugate composition of the precedent composition. $\Box$

in the following article, Cayley showed that the number of compositions of n + 1 into parts greater than one equals the $n$th Fibonacci number $F_n$.

A. Cayley, Theorems in trigonometry and on partitions, Collected Mathematical Papers, vol. 10, 16.

Quite surprisingly, it follows that the number of compositions into odd parts equals the $n$'th fibonnaci number.

Which is suggested in this OEIS entry: http://oeis.org/A000045: "$F(n) =$ number of compositions of n into odd parts; e.g., $F_6$ counts 1+1+1+1+1+1, 1+1+1+3, 1+1+3+1, 1+3+1+1, 1+5, 3+1+1+1, 3+3, 5+1. - Clark Kimberling, Jun 22 2004"