login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A334541 a(n) is the number of partitions of n into consecutive parts that differ by 5. 8

%I #52 Dec 02 2020 18:08:39

%S 1,1,1,1,1,1,2,1,2,1,2,1,2,1,2,1,2,2,2,1,3,1,2,2,2,1,3,1,2,2,2,1,3,2,

%T 2,2,2,2,3,1,2,3,2,1,3,2,2,2,2,2,3,1,2,3,3,1,3,2,2,3,2,2,3,1,3,3,2,1,

%U 3,3,2,2,2,2,4,1,2,3,2,2,4,2,2,2,3,2,4,1,2,4,2,1,4,2,3,2,2,2,4,2,2,3,2,1,5

%N a(n) is the number of partitions of n into consecutive parts that differ by 5.

%C Note that all sequences of this family as A000005, A001227, A038548, A117277, A334461, etc. could be prepended with a(0) = 1 when they are interpreted as sequences of number of partitions, since A000041(0) = 1. However here a(0) is omitted in accordance with the mentioned members of the same family.

%C For the relation to heptagonal numbers see also A334465.

%H David A. Corneth, <a href="/A334541/b334541.txt">Table of n, a(n) for n = 1..10000</a>

%F The g.f. for "consecutive parts that differ by d" is Sum_{k>=1} x^(k*(d*k-d+2)/2) / (1-x^k); cf. A117277. - _Joerg Arndt_, Nov 30 2020

%e For n = 27 there are three partitions of 27 into consecutive parts that differ by 5, including 27 as a valid partition. They are [27], [16, 11] and [14, 9, 4], so a(27) = 3.

%t first[n_] := Module[{res = Array[1&, n]}, For[i = 2, True, i++, start = i + 5 Binomial[i, 2]; If[start > n, Return[res]]; For[j = start, j <= n, j += i, res[[j]]++]]];

%t first[105] (* _Jean-François Alcover_, Nov 30 2020, after _David A. Corneth_ *)

%o (PARI) seq(N, d)=my(x='x+O('x^N)); Vec(sum(k=1, N, x^(k*(d*k-d+2)/2)/(1-x^k)));

%o seq(100, 5) \\ _Joerg Arndt_, May 06 2020

%o (PARI) first(n) = { my(res = vector(n, i, 1)); for(i = 2, oo, start = i + 5 * binomial(i, 2); if(start > n, return(res)); forstep(j = start, n, i, res[j]++ ) ); } \\ _David A. Corneth_, May 17 2020

%Y Row sums of A334465.

%Y Column k=5 of A323345.

%Y Sequences of this family whose consecutive parts differ by k are A000005 (k=0), A001227 (k=1), A038548 (k=2), A117277 (k=3), A334461 (k=4), this sequence (k=5).

%Y Cf. A000041, A000566, A303300.

%K nonn,easy

%O 1,7

%A _Omar E. Pol_, May 05 2020

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 11:39 EDT 2024. Contains 371969 sequences. (Running on oeis4.)