login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A239239
Number of strict partitions of n having fewer odd parts than even.
6
0, 0, 1, 0, 1, 0, 2, 1, 2, 2, 3, 4, 4, 7, 5, 11, 7, 16, 10, 23, 15, 32, 21, 43, 32, 57, 45, 74, 66, 96, 92, 123, 129, 157, 175, 199, 239, 253, 316, 320, 419, 406, 544, 514, 704, 652, 898, 825, 1142, 1045, 1435, 1321, 1798, 1669, 2234, 2103, 2766, 2646, 3404
OFFSET
0,7
COMMENTS
a(n) = Sum_{k<=-1} A240021(n,k). - Alois P. Heinz, Apr 02 2014
LINKS
FORMULA
a(n) + A239243(n) = A000009(n) for n >=1.
EXAMPLE
a(6) counts these partitions: 6, 42.
MAPLE
b:= proc(n, i, t) option remember; `if`(n>i*(i+1)/2, 0,
`if`(n=0, `if`(t<0, 1, 0 ), b(n, i-1, t)+`if`(i>n, 0,
b(n-i, i-1, t+`if`(irem(i, 2)=1, 1, -1)))))
end:
a:= n-> b(n$2, 0):
seq(a(n), n=0..60); # Alois P. Heinz, Mar 15 2014
MATHEMATICA
z = 55; p[n_] := p[n] = IntegerPartitions[n]; d[u_] := d[u] = DeleteDuplicates[u]; g[u_] := g[u] = Length[u];
Table[g[Select[Select[p[n], d[#] == # &], Count[#, _?OddQ] < Count[#, _?EvenQ] &]], {n, 0, z}] (* A239239 *)
Table[g[Select[Select[p[n], d[#] == # &], Count[#, _?OddQ] <= Count[#, _?EvenQ] &]], {n, 0, z}] (* A239240 *)
Table[g[Select[Select[p[n], d[#] == # &], Count[#, _?OddQ] == Count[#, _?EvenQ] &]], {n, 0, z}] (* A239241 *)
Table[g[Select[Select[p[n], d[#] == # &], Count[#, _?OddQ] > Count[#, _?EvenQ] &]], {n, 0, z}] (* A239242 *)
Table[g[Select[Select[p[n], d[#] == # &], Count[#, _?OddQ] >= Count[#, _?EvenQ] &]], {n, 0, z}] (* A239243 *)
(* Peter J. C. Moses, Mar 10 2014 *)
b[n_, i_, t_] := b[n, i, t] = If[n>i*(i+1)/2, 0, If[n == 0, If[t<0, 1, 0], b[n, i-1, t] + If[i>n, 0, b[n-i, i-1, t+If[Mod[i, 2] == 1, 1, -1]]]]]; a[n_] := b[n, n, 0]; Table[a[n], {n, 0, 60}] (* Jean-François Alcover, Aug 29 2016, after Alois P. Heinz *)
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Clark Kimberling, Mar 13 2014
STATUS
approved