

A319895


a(n) is the number of partitions of n into consecutive parts, plus the total number of parts in those partitions.


1



2, 2, 5, 2, 5, 6, 5, 2, 9, 7, 5, 6, 5, 7, 15, 2, 5, 11, 5, 8, 16, 7, 5, 6, 11, 7, 16, 10, 5, 17, 5, 2, 16, 7, 19, 15, 5, 7, 16, 8, 5, 19, 5, 11, 32, 7, 5, 6, 13, 13, 16, 11, 5, 21, 22, 10, 16, 7, 5, 21, 5, 7, 34, 2, 22, 23, 5, 11, 16, 21, 5, 16, 5, 7, 33, 11, 25, 24, 5, 8, 26, 7, 5, 23, 22, 7, 16, 14, 5
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

1,1


COMMENTS

a(n) is also the total length of all pairs of orthogonal line segments whose horizontal and upper parts are in the nth row of the diagram associated to partitions into consecutive parts as shown in the Example section.
a(n) = 2 iff n is a power of 2.
a(n) = 5 iff n is an odd prime.


LINKS



FORMULA



EXAMPLE

Illustration of a diagram of partitions into consecutive parts (first 28 rows):
. _
. _1
. _2 _
. _3 2
. _4 _1
. _5 3 _
. _6 _23
. _7 4 2
. _8 _3 _1
. _9 5 4 _
. _10 _4 34
. _11 6 _23
. _12 _5 5 2
. _13 7 4 _1
. _14 _6 _35 _
. _15 8 6 45
. _16 _7 5 34
. _17 9 _4 _23
. _18 _8 7 6 2
. _19 10 6 5 _1
. _20 _9 _5 46 _
. _21 11 8 _356
. _22 _10 7 7 45
. _23 12 _6 6 34
. _24 _11 9 5 _23
. _25 13 8 _47 2
. _26 _12 _7 8 6 _1
. _27 14 10 7 57 _
. 28 13 9 6 467
...
For n = 21 we have that there are four partitions of 21 into consecutive parts, they are [21], [11, 10], [8, 7, 6], [6, 5, 4, 3, 2, 1]. The total number of parts is 1 + 2 + 3 + 6 = 12. Therefore the number of partitions plus the total number of parts is 4 + 12 = 16, so a(21) = 16.
On the other hand, in the above diagram there are four pairs of orthogonal line segments whose horizontal upper part are located on the 21st row, as shown below:
. _ _ _ _
. 21 11 8 6
. 10 7 5
. 6 4
. 3
. 2
. 1
.
The four horizontal line segments have length 1, and the vertical line segments have lengths 1, 2, 3, 6 respectively. Therefore the total length of the line segments is 1 + 1 + 1 + 1 + 1 + 2 + 3 + 6 = 16, so a(21) = 16.


PROG

(PARI)
A001227(n) = numdiv(n>>valuation(n, 2));


CROSSREFS

For tables of partitions into consecutive parts see A286000 and A286001.
Cf. A000079, A001227, A065091, A204217, A237048, A237593, A285898, A285899, A285900, A285900, A285901, A285902, A288529, A288772, A288773, A288774, A299765.


KEYWORD

nonn


AUTHOR



EXTENSIONS



STATUS

approved



