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

 

Logo

Thanks to everyone who made a donation during our annual appeal!
To see the list of donors, or make a donation, see the OEIS Foundation home page.

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A240447 Number of partitions of 2n such that (sum of parts having multiplicity 1) = sum of all other parts. 5
1, 0, 1, 1, 3, 2, 8, 5, 18, 19, 39, 34, 105, 74, 183, 202, 381, 344, 818, 684, 1459, 1499, 2662, 2578, 5279, 4756, 8835, 9287, 15655, 15538, 28319, 27178, 46709, 49166, 78303, 80747, 135134, 134945, 216255, 231483, 353557, 369918, 581337, 600500, 915010, 987925 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,5

COMMENTS

The number of partitions of 2n+1 such that (sum of parts having multiplicity 1) = sum of all other parts is 0; see the Mathematica program at A240448 for related sequences.

LINKS

Manfred Scheucher and Alois P. Heinz, Table of n, a(n) for n = 0..650 (first 64 terms from Manfred Scheucher)

Manfred Scheucher, C Code

EXAMPLE

a(6) counts these 8 partitions of 12:  633, 6222, 62211, 6111111, 5331, 52221, 4332, 42111111 .

MAPLE

f := proc(L, p)

    a := 0 ;

    for i in L do

        if i = p then

            a := a+1 ;

        end if;

    end do:

    a;

end proc:

sp1 := proc(L)

    a1 :=0 ;

    ao :=0 ;

    for i in L do

        if f(L, i) = 1 then

            a1 := a1+i;

        else

            ao := ao+i;

        end if;

    end do:

    if ( a1 = ao) then

        true;

    else

        false;

    end if;

end proc:

A240447 := proc(n)

    a := 0 ;

    for p in combinat[partition](2*n) do

        if sp1(p) then

            a := a+1 ;

        end if;

    end do:

    a ;

end proc: # R. J. Mathar, Mar 06 2015

# second Maple program:

b:= proc(n, i, s) option remember; `if`(n=0, `if`(s=0, 1, 0),

      `if`(i<1 or s>0 and i*(i+1)/2<s or abs(s)>n, 0,

       add(b(n-i*j, i-1, s+`if`(j=1, -i, i*j)), j=0..n/i)))

    end:

a:= n-> b(2*n$2, 0):

seq(a(n), n=0..70);  # Alois P. Heinz, May 31 2015

MATHEMATICA

ColumnForm[t = Table[Select[IntegerPartitions[n], 2 Total[First[Transpose[Select[#, Last[#] == 1 &] /. {} -> {{0, 0}}]]] &[Tally[#]] == n &], {n, 0, 30, 2}]] (* shows partitions *)

Map[Length, t] (* A240447 *)  (* Peter J. C. Moses, Apr 02 2014 *)

b[n_, i_, s_] := b[n, i, s] = If[n == 0, If[s == 0, 1, 0], If[i<1 || s>0 && i*(i+1)/2 < s || Abs[s] > n, 0, Sum[b[n-i*j, i-1, s + If[j == 1, -i, i*j]], {j, 0, n/i}]]]; a[n_] := b[2*n, 2*n, 0]; Table[a[n], {n, 0, 70}] (* Jean-Fran├žois Alcover, Oct 28 2015, after Alois P. Heinz *)

CROSSREFS

Cf. A240448, A240449, A240451, A240452.

Sequence in context: A126320 A322845 A307705 * A135992 A182638 A172084

Adjacent sequences:  A240444 A240445 A240446 * A240448 A240449 A240450

KEYWORD

nonn,easy

AUTHOR

Clark Kimberling, Apr 05 2014

EXTENSIONS

More terms from Manfred Scheucher, May 30 2015

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 January 20 20:35 EST 2020. Contains 331096 sequences. (Running on oeis4.)