login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A096374 Number of partitions of n such that the least part occurs with even multiplicity. 3
0, 1, 0, 3, 1, 5, 4, 11, 8, 19, 19, 35, 36, 59, 65, 104, 115, 168, 196, 276, 321, 440, 521, 694, 821, 1072, 1277, 1644, 1957, 2477, 2959, 3705, 4411, 5472, 6516, 8014, 9524, 11620, 13789, 16724, 19798, 23860, 28202, 33815, 39864, 47579, 55979, 66520, 78080 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,4

COMMENTS

Also number of partitions of n such that the difference between the two largest distinct parts is even (it is assumed that 0 is a part in each partition). Example: a(6)=5 because we have [6],[5,1],[4,2],[2,2,2] and [3,1,1,1]. - Emeric Deutsch, Apr 04 2006

LINKS

Alois P. Heinz, Table of n, a(n) for n = 1..1000

FORMULA

G.f.: Sum_{m>=1} ((x^(2*m)/(1+x^m))/Product_{i>=m}(1-x^i)).

a(n) + A096375(n) = A000041(n).

EXAMPLE

a(6) = 5 because we have [4,1,1], [3,3], [2,2,1,1], [2,1,1,1,1] and [1,1,1,1,1,1].

MAPLE

g:=sum(x^(2*k)/(1+x^k)/product(1-x^j, j=k..70), k=1..50): gser:=series(g, x=0, 50): seq(coeff(gser, x, n), n=1..48); # Emeric Deutsch, Apr 04 2006

# second Maple program:

b:= proc(n, i) option remember; `if`(n=0 or i<1, 0, `if`(irem(n, i, 'r')=0

      and irem(r, 2)=0, 1, 0)+ add(b(n-i*j, i-1), j=0..n/i))

    end:

a:= n-> b(n, n):

seq(a(n), n=1..50);  # Alois P. Heinz, Feb 27 2013

MATHEMATICA

f[n_] := Block[{p = IntegerPartitions[n], l = PartitionsP[n], c = 0, k = 1}, While[k < l + 1, If[ EvenQ[ Count[ p[[k]], p[[k]][[ -1]] ]], c++ ]; k++ ]; c]; Table[ f[n], {n, 50}] (* Robert G. Wilson v, Jul 23 2004 *)

b[n_, i_] := b[n, i] = If[n == 0 || i < 1, 0, {q, r} = QuotientRemainder[n, i]; If[r == 0 && Mod[q, 2] == 0, 1, 0] + Sum[b[n - i*j, i-1], {j, 0, n/i}]] ; a[n_] := b[n, n]; Table[a[n], {n, 1, 50}] (* Jean-Fran├žois Alcover, Jan 24 2014, after Alois P. Heinz *)

Table[Count[IntegerPartitions[n], _?(EvenQ[Length[Split[#][[-1]]]]&)], {n, 50}] (* Harvey P. Dale, Jun 02 2019 *)

PROG

(PARI) {q=sum(m=1, 100, (x^(2*m)/(1+x^m))/prod(i=m, 100, 1-x^i, 1+O(x^60)), 1+O(x^60)); for(n=1, 48, print1(polcoeff(q, n), ", "))} \\ Klaus Brockhaus, Jul 21 2004

CROSSREFS

Cf. A000041, A096375.

Sequence in context: A331698 A082129 A159970 * A007085 A094648 A096975

Adjacent sequences:  A096371 A096372 A096373 * A096375 A096376 A096377

KEYWORD

easy,nonn

AUTHOR

Vladeta Jovovic, Jul 19 2004

EXTENSIONS

Edited and extended by Robert G. Wilson v and Klaus Brockhaus, Jul 21 2004

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 19 15:09 EDT 2020. Contains 337178 sequences. (Running on oeis4.)