cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A194452 Total number of repeated parts in all partitions of n.

This page as a plain text file.
%I A194452 #46 Jun 12 2024 12:24:37
%S A194452 0,0,2,3,8,12,24,35,60,87,136,192,287,396,567,773,1074,1439,1958,2587,
%T A194452 3454,4514,5931,7666,9951,12736,16341,20743,26354,33184,41807,52262,
%U A194452 65329,81144,100721,124344,153390,188303,230940,282063,344100,418242,507762
%N A194452 Total number of repeated parts in all partitions of n.
%H A194452 Alois P. Heinz, <a href="/A194452/b194452.txt">Table of n, a(n) for n = 0..1000</a>
%F A194452 a(n) = A006128(n) - A024786(n+1).
%F A194452 a(n) = Sum_{k=2..n} k*A264405(n,k). - _Alois P. Heinz_, Dec 07 2015
%F A194452 G.f.: g = Sum_{j>0} (x^{2*j}*(2 - x^j)/(1-x^j))/Product_{k>0}(1 - x^k) (obtained by logarithmic differentiation of the bivariate g.f. given in A264405). - _Emeric Deutsch_, Feb 02 2016
%e A194452 For n = 6 we have:
%e A194452 --------------------------------------
%e A194452 .                        Number of
%e A194452 Partitions             repeated parts
%e A194452 --------------------------------------
%e A194452 6 .......................... 0
%e A194452 3 + 3 ...................... 2
%e A194452 4 + 2 ...................... 0
%e A194452 2 + 2 + 2 .................. 3
%e A194452 5 + 1 ...................... 0
%e A194452 3 + 2 + 1 .................. 0
%e A194452 4 + 1 + 1 .................. 2
%e A194452 2 + 2 + 1 + 1 .............. 4
%e A194452 3 + 1 + 1 + 1 .............. 3
%e A194452 2 + 1 + 1 + 1 + 1 .......... 4
%e A194452 1 + 1 + 1 + 1 + 1 + 1 ...... 6
%e A194452 ------------------------------------
%e A194452 Total ..................... 24
%e A194452 So a(6) = 24.
%p A194452 b:= proc(n, i) option remember; local h, j, t;
%p A194452       if n<0 then [0, 0]
%p A194452     elif n=0 then [1, 0]
%p A194452     elif i<1 then [0, 0]
%p A194452     else h:= [0, 0];
%p A194452          for j from 0 to iquo(n, i) do
%p A194452            t:= b(n-i*j, i-1);
%p A194452            h:= [h[1]+t[1], h[2]+t[2]+`if`(j<2, 0, t[1]*j)]
%p A194452          od; h
%p A194452       fi
%p A194452     end:
%p A194452 a:= n-> b(n, n)[2]:
%p A194452 seq(a(n), n=0..50);  # _Alois P. Heinz_, Nov 20 2011
%p A194452 g := add(x^(2*j)*(2-x^j)/(1-x^j), j = 1 .. 80)/mul(1-x^j, j = 1 .. 80): gser := series(g, x = 0, 50): seq(coeff(gser, x, n), n = 0 .. 45); # _Emeric Deutsch_, Feb 02 2016
%t A194452 myCount[p_List] := Module[{t}, If[p == {}, 0, t = Transpose[Tally[p]][[2]]; Sum[If[t[[i]] == 1, 0, t[[i]]], {i, Length[t]}]]]; Table[Total[Table[myCount[p], {p, IntegerPartitions[i]}]], {i, 0, 20}] (* _T. D. Noe_, Nov 19 2011 *)
%t A194452 b[n_, i_] := b[n, i] = Module[{h, j, t}, Which[n<0, {0, 0}, n==0, {1, 0}, i < 1, {0, 0}, True, h={0, 0}; For[j=0, j <= Quotient[n, i], j++, t = b[n - i*j, i-1]; h = {h[[1]]+t[[1]], h[[2]]+t[[2]] + If[j<2, 0, t[[1]]*j]}]; h] ]; a[n_] := b[n, n][[2]]; Table[a[n], {n, 0, 50}] (* _Jean-François Alcover_, Oct 25 2015, after _Alois P. Heinz_ *)
%t A194452 Table[Length[Flatten[Select[Flatten[Split[#]&/@IntegerPartitions[n],1],Length[#]>1&]]],{n,0,60}] (* _Harvey P. Dale_, Jun 12 2024 *)
%Y A194452 Cf. A006128, A024786, A047967, A135010, A138121, A194544, A264405.
%K A194452 nonn
%O A194452 0,3
%A A194452 _Omar E. Pol_, Nov 19 2011