Displaying 1-10 of 68 results found.
Sum of first n parts of the spiral described in A239660.
+20
1
1, 4, 6, 8, 15, 18, 21, 33, 37, 41, 56, 61, 64, 69, 78, 87, 93, 99, 127, 134, 141, 153, 165, 173, 181, 189, 220, 229, 238, 277, 287, 297, 339, 350, 355, 360, 371, 389, 407, 419, 431, 491, 504, 509, 522, 543, 564, 578, 584, 590, 604, 660, 675, 690, 762, 778, 794, 857, 874, 881, 888, 905, 932, 959, 977, 989, 1007, 1098
COMMENTS
We can find the spiral on the terraces of the stepped pyramid described in A244050. - Omar E. Pol, Dec 07 2016
EXAMPLE
If written as an irregular triangle in which row lengths is A237271 the sequence begins:
1;
4;
6, 8;
15;
18, 21;
33;
37, 41;
56;
61, 64, 69;
78, 87;
93, 99;
127;
134, 141;
153, 165;
173, 181, 189;
220;
229, 238;
277;
287, 297;
339;
350, 355, 360, 371;
389, 407;
419, 431;
491;
504, 509, 522;
...
Triangle read by rows in which row n lists the elements of the n-th row of A237591 and then the elements of the same row but in reverse order.
+10
523
1, 1, 2, 2, 2, 1, 1, 2, 3, 1, 1, 3, 3, 2, 2, 3, 4, 1, 1, 1, 1, 4, 4, 2, 1, 1, 2, 4, 5, 2, 1, 1, 2, 5, 5, 2, 2, 2, 2, 5, 6, 2, 1, 1, 1, 1, 2, 6, 6, 3, 1, 1, 1, 1, 3, 6, 7, 2, 2, 1, 1, 2, 2, 7, 7, 3, 2, 1, 1, 2, 3, 7, 8, 3, 1, 2, 2, 1, 3, 8, 8, 3, 2, 1, 1, 1, 1, 2, 3, 8
COMMENTS
Row n is a palindromic composition of 2*n.
T(n,k) is also the length of the k-th segment in a Dyck path on the first quadrant of the square grid, connecting the x-axis with the y-axis, from (n, 0) to (0, n), starting with a segment in vertical direction, see example.
Conjecture 1: the area under the n-th Dyck path equals A024916(n), the sum of all divisors of all positive integers <= n.
If the conjecture is true then the n-th Dyck path represents the boundary segments after the alternating sum of the elements of the n-th row of A236104.
Conjecture 2: two adjacent Dyck paths never cross (checked by hand up to n = 128), hence the total area between the n-th Dyck path and the (n-1)-st Dyck path is equal to sigma(n) = A000203(n), the sum of divisors of n.
PARI scripts area(n) and chkcross(n) have been written to check the 2 properties and have been run up to n=10000. - Michel Marcus, Mar 27 2014
Mathematica functions have been written that verified the 2 properties through n=30000. - Hartmut F. W. Hoft, Apr 07 2014
The place to start is with A235791, which is very simple. Then go to A237591, also very simple, and A237593, still very simple.
You then need to interpret the rows of A237593 as Dyck paths. This interpretation is in terms of run lengths, so 2,1,1,2 means up twice, down once, up once, and down twice. Because the rows of A237593 are symmetric and of even length, this path will always be symmetric.
Now the surprising fact is that the areas enclosed by the Dyck path for n (laid on its side) always includes the area enclosed for n-1; and the number of squares added is sigma(n).
Finally, look at the connected areas enclosed by n but not by n-1; the size of these areas is the symmetric representation of sigma. (End)
The symmetric representation of sigma, so defined, is row n of A237270. - Peter Munn, Jan 06 2025
It appears that, for the n-th set, the number of cells lying on the first diagonal is equal to A067742(n), the number of middle divisors of n. - Michel Marcus, Jun 21 2014
A003056(n) is also the number of peaks of the Dyck path related to the n-th row of triangle. - Omar E. Pol, Nov 03 2015
The number of peaks of the Dyck path associated to the row A000396(n) of this triangle equals the n-th Mersenne prime A000668(n), hence Mersenne primes are visible in two ways at the pyramid described in A245092. - Omar E. Pol, Dec 19 2016
The limit as n approaches infinity (area under the Dyck path described in the n-th row of triangle divided by n^2) equals Pi^2/12 = zeta(2)/2. (Cf. A072691.) - Omar E. Pol, Dec 18 2021
The connection between the isosceles triangle and the stepped pyramid is due to the fact that this object can also be interpreted as a pop-up card. - Omar E. Pol, Nov 09 2022
EXAMPLE
Triangle begins:
n
1 | 1, 1;
2 | 2, 2;
3 | 2, 1, 1, 2;
4 | 3, 1, 1, 3;
5 | 3, 2, 2, 3;
6 | 4, 1, 1, 1, 1, 4;
7 | 4, 2, 1, 1, 2, 4;
8 | 5, 2, 1, 1, 2, 5;
9 | 5, 2, 2, 2, 2, 5;
10 | 6, 2, 1, 1, 1, 1, 2, 6;
11 | 6, 3, 1, 1, 1, 1, 3, 6;
12 | 7, 2, 2, 1, 1, 2, 2, 7;
13 | 7, 3, 2, 1, 1, 2, 3, 7;
14 | 8, 3, 1, 2, 2, 1, 3, 8;
15 | 8, 3, 2, 1, 1, 1, 1, 2, 3, 8;
16 | 9, 3, 2, 1, 1, 1, 1, 2, 3, 9;
17 | 9, 4, 2, 1, 1, 1, 1, 2, 4, 9;
18 | 10, 3, 2, 2, 1, 1, 2, 2, 3, 10;
19 | 10, 4, 2, 2, 1, 1, 2, 2, 4, 10;
20 | 11, 4, 2, 1, 2, 2, 1, 2, 4, 11;
21 | 11, 4, 3, 1, 1, 1, 1, 1, 1, 3, 4, 11;
22 | 12, 4, 2, 2, 1, 1, 1, 1, 2, 2, 4, 12;
23 | 12, 5, 2, 2, 1, 1, 1, 1, 2, 2, 5, 12;
24 | 13, 4, 3, 2, 1, 1, 1, 1, 2, 3, 4, 13;
...
Illustration of rows 8 and 9 interpreted as Dyck paths in the first quadrant and the illustration of the symmetric representation of sigma(9) = 5 + 3 + 5 = 13, see below:
.
y y
. .
. ._ _ _ _ _ _ _ _ _ _ 5
._ _ _ _ _ . | |_ _ _ _ _|
. | . |_ _ |_ _ 3
. |_ . | |_ |
. |_ _ . |_ _ |_|_ _ 5
. | . | | |
. Area = 56 | . Area = 69 | | |
. | . | | |
. | . | | |
. . . . . . . . | . x . . . . . . . . . | . x |_|
.
. Fig. 1 Fig. 2 Fig. 3
.
Figure 1. For n = 8 the 8th row of triangle is [5, 2, 1, 1, 2, 5] and the area under the symmetric Dyck path is equal to A024916(8) = 56.
Figure 2. For n = 9 the 9th row of triangle is [5, 2, 2, 2, 2, 5] and the area under the symmetric Dyck path is equal to A024916(9) = 69.
Figure 3. The symmetric representation of sigma(9): between both symmetric Dyck paths there are three regions (or parts) of sizes [5, 3, 5].
The sum of divisors of 9 is 1 + 3 + 9 = A000203(9) = 13. On the other hand the difference between the areas under the Dyck paths equals the sum of the parts of the symmetric representation of sigma(9) = 69 - 56 = 5 + 3 + 5 = 13, equaling the sum of divisors of 9.
.
Illustration of initial terms as Dyck paths in the first quadrant:
(row n = 1..28)
. _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
|_ _ _ _ _ _ _ _ _ _ _ _ _ _ |
|_ _ _ _ _ _ _ _ _ _ _ _ _ _| |
|_ _ _ _ _ _ _ _ _ _ _ _ _ | |
|_ _ _ _ _ _ _ _ _ _ _ _ _| | |
|_ _ _ _ _ _ _ _ _ _ _ _ | | |_ _ _
|_ _ _ _ _ _ _ _ _ _ _ _| | |_ _ _ |
|_ _ _ _ _ _ _ _ _ _ _ | | |_ _ | |_
|_ _ _ _ _ _ _ _ _ _ _| | |_ _ _| |_ |_
|_ _ _ _ _ _ _ _ _ _ | | |_ _| |_
|_ _ _ _ _ _ _ _ _ _| | |_ _ |_ |_ _ |_ _
|_ _ _ _ _ _ _ _ _ | |_ _ _| |_ | |_ _ |
|_ _ _ _ _ _ _ _ _| | |_ _ |_ |_|_ _ | |
|_ _ _ _ _ _ _ _ | |_ _ |_ _|_ | | | |_ _ _ _ _
|_ _ _ _ _ _ _ _| | | | |_ _ | |_|_ _ _ _ _ |
|_ _ _ _ _ _ _ | |_ _ |_ |_ | | |_ _ _ _ _ | | |
|_ _ _ _ _ _ _| |_ _ |_ |_ _ | | |_ _ _ _ _ | | | | |
|_ _ _ _ _ _ | |_ |_ |_ | |_|_ _ _ _ | | | | | | |
|_ _ _ _ _ _| |_ _| |_ | |_ _ _ _ | | | | | | | | |
|_ _ _ _ _ | |_ _ | |_ _ _ _ | | | | | | | | | | |
|_ _ _ _ _| |_ | |_|_ _ _ | | | | | | | | | | | | |
|_ _ _ _ |_ _|_ |_ _ _ | | | | | | | | | | | | | | |
|_ _ _ _| |_ | |_ _ _ | | | | | | | | | | | | | | | | |
|_ _ _ |_ |_|_ _ | | | | | | | | | | | | | | | | | | |
|_ _ _| |_ _ | | | | | | | | | | | | | | | | | | | | |
|_ _ |_ _ | | | | | | | | | | | | | | | | | | | | | | |
|_ _|_ | | | | | | | | | | | | | | | | | | | | | | | | |
|_ | | | | | | | | | | | | | | | | | | | | | | | | | | |
|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|_|
.
n: 1 2 3 4 5 6 7 8 9 10..12..14..16..18..20..22..24..26..28
.
It appears that the total area (also the total number of cells) in the first n set of symmetric regions of the diagram is equal to A024916(n), the sum of all divisors of all positive integers <= n.
It appears that the total area (also the total number of cells) in the n-th set of symmetric regions of the diagram is equal to sigma(n) = A000203(n) (checked by hand up n = 128).
The above diagram is also the top view of the stepped pyramid described in A245092 and it is also the top view of the staircase described in A244580, in both cases the figure represents the first 28 levels of the structure. Note that the diagram contains (and arises from) a hidden pattern which is shown below.
.
Illustration of initial terms as an isosceles triangle:
Row _ _
1 _|1|1|_
2 _|2 _|_ 2|_
3 _|2 |1|1| 2|_
4 _|3 _|1|1|_ 3|_
5 _|3 |2 _|_ 2| 3|_
6 _|4 _|1|1|1|1|_ 4|_
7 _|4 |2 |1|1| 2| 4|_
8 _|5 _|2 _|1|1|_ 2|_ 5|_
9 _|5 |2 |2 _|_ 2| 2| 5|_
10 _|6 _|2 |1|1|1|1| 2|_ 6|_
11 _|6 |3 _|1|1|1|1|_ 3| 6|_
12 _|7 _|2 |2 |1|1| 2| 2|_ 7|_
13 _|7 |3 |2 _|1|1|_ 2| 3| 7|_
14 _|8 _|3 _|1|2 _|_ 2|1|_ 3|_ 8|_
15 _|8 |3 |2 |1|1|1|1| 2| 3| 8|_
16 |9 |3 |2 |1|1|1|1| 2| 3| 9|
...
This diagram is the simpler representation of the sequence.
The number of horizontal line segments in the n-th level in each side of the diagram equals A001227(n), the number of odd divisors of n.
The number of horizontal line segments in the left side of the diagram plus the number of the horizontal line segment in the right side equals A054844(n).
The total number of vertical line segments in the n-th level of the diagram equals A131507(n).
Note that this symmetric pattern also emerges from the front view of the stepped pyramid described in A245092, which is related to sigma A000203, the sum-of-divisors function, and other related sequences. The diagram represents the first 16 levels of the pyramid. (End)
MATHEMATICA
row[n_]:=Floor[(Sqrt[8n+1]-1)/2]
s[n_, k_]:=Ceiling[(n+1)/k-(k+1)/2]-Ceiling[(n+1)/(k+1)-(k+2)/2]
f[n_, k_]:=If[k<=row[n], s[n, k], s[n, 2 row[n]+1-k]]
TableForm[Table[f[n, k], {n, 1, 50}, {k, 1, 2 row[n]}]] (* Hartmut F. W. Hoft, Apr 08 2014 *)
PROG
(PARI) row(n) = {my(orow = row237591(n)); vector(2*#orow, i, if (i <= #orow, orow[i], orow[2*#orow-i+1])); }
area(n) = {my(rown = row(n)); surf = 0; h = n; odd = 1; for (i=1, #row, if (odd, surf += h*rown[i], h -= rown[i]; ); odd = !odd; ); surf; }
heights(v, n) = {vh = vector(n); ivh = 1; h = n; odd = 1; for (i=1, #v, if (odd, for (j=1, v[i], vh[ivh] = h; ivh++), h -= v[i]; ); odd = !odd; ); vh; }
isabove(hb, ha) = {for (i=1, #hb, if (hb[i] < ha[i], return (0)); ); return (1); }
chkcross(nn) = {hga = concat(heights(row(1), 1), 0); for (n=2, nn, hgb = heights(row(n), n); if (! isabove(hgb, hga), print("pb cross at n=", n)); hga = concat(hgb, 0); ); } \\ Michel Marcus, Mar 27 2014
(Python)
from sympy import sqrt
import math
def row(n): return int(math.floor((sqrt(8*n + 1) - 1)/2))
def s(n, k): return int(math.ceil((n + 1)/k - (k + 1)/2)) - int(math.ceil((n + 1)/(k + 1) - (k + 2)/2))
def T(n, k): return s(n, k) if k<=row(n) else s(n, 2*row(n) + 1 - k)
for n in range(1, 11): print([T(n, k) for k in range(1, 2*row(n) + 1)]) # Indranil Ghosh, Apr 21 2017
CROSSREFS
Column k starts in row A008805(k-1).
Column 1 = right border = A008619, n >= 1.
For further information see A262626.
Cf. A000203, A000217, A001065, A001227, A024916, A048050, A054844, A067742, A072691, A131507, A196020, A221529, A235791, A236104, A237048, A237270, A237271, A237590, A237591, A239660, A239931- A239934, A244050, A244580, A245092, A249351, A261350, A261699, A262611, A262612, A279387, A280850, A280851, A286000, A286001, A296508, A335616, A340035.
Triangle read by rows in which row n lists the parts of the symmetric representation of sigma(n).
+10
283
1, 3, 2, 2, 7, 3, 3, 12, 4, 4, 15, 5, 3, 5, 9, 9, 6, 6, 28, 7, 7, 12, 12, 8, 8, 8, 31, 9, 9, 39, 10, 10, 42, 11, 5, 5, 11, 18, 18, 12, 12, 60, 13, 5, 13, 21, 21, 14, 6, 6, 14, 56, 15, 15, 72, 16, 16, 63, 17, 7, 7, 17, 27, 27, 18, 12, 18, 91, 19, 19, 30, 30, 20, 8, 8, 20, 90
COMMENTS
T(n,k) is the number of cells in the k-th region of the n-th set of regions in a diagram of the symmetry of sigma(n), see example.
Row n is a palindromic composition of sigma(n).
In the row 2n-1 of triangle both the first term and the last term are equal to n.
If n is an odd prime then row n is [m, m], where m = (1 + n)/2.
For the boundary segments in an octant see A237591.
For the boundary segments in a quadrant see A237593.
For the boundary segments in the spiral see also A239660.
We can find the spiral on the terraces of the stepped pyramid described in A244050. - Omar E. Pol, Dec 07 2016
T(n,k) is also the area of the k-th terrace, from left to right, at the n-th level, starting from the top, of the stepped pyramid described in A245092 (see Links section). - Omar E. Pol, Aug 14 2018
EXAMPLE
Illustration of the first 27 terms as regions (or parts) of a spiral constructed with the first 15.5 rows of A239660:
.
. _ _ _ _ _ _ _ _
. | _ _ _ _ _ _ _|_ _ _ _ _ _ _ 7
. | | |_ _ _ _ _ _ _|
. 12 _| | |
. |_ _| _ _ _ _ _ _ |_ _
. 12 _ _| | _ _ _ _ _|_ _ _ _ _ 5 |_
. _ _ _| | 9 _| | |_ _ _ _ _| |
. | _ _ _| 9 _|_ _| |_ _ 3 |_ _ _ 7
. | | _ _| | _ _ _ _ |_ | | |
. | | | _ _| 12 _| _ _ _|_ _ _ 3 |_|_ _ 5 | |
. | | | | _| | |_ _ _| | | | |
. | | | | | _ _| |_ _ 3 | | | |
. | | | | | | 3 _ _ | | | | | |
. | | | | | | | _|_ 1 | | | | | |
. _|_| _|_| _|_| _|_| |_| _|_| _|_| _|_| _
. | | | | | | | | | | | | | | | |
. | | | | | | |_|_ _ _| | | | | | | |
. | | | | | | 2 |_ _|_ _| _| | | | | | |
. | | | | |_|_ 2 |_ _ _|7 _ _| | | | | |
. | | | | 4 |_ _| _ _| | | | |
. | | |_|_ _ |_ _ _ _ | _| _ _ _| | | |
. | | 6 |_ |_ _ _ _|_ _ _ _| | 15 _| _ _| | |
. |_|_ _ _ |_ 4 |_ _ _ _ _| _| | _ _ _| |
. 8 | |_ _ | | _| | _ _ _|
. |_ | |_ _ _ _ _ _ | _ _|28 _| |
. |_ |_ |_ _ _ _ _ _|_ _ _ _ _ _| | _| _|
. 8 |_ _| 6 |_ _ _ _ _ _ _| _ _| _|
. | | _ _| 31
. |_ _ _ _ _ _ _ _ | |
. |_ _ _ _ _ _ _ _|_ _ _ _ _ _ _ _| |
. 8 |_ _ _ _ _ _ _ _ _|
.
.
[For two other drawings of the spiral see the links. - N. J. A. Sloane, Nov 16 2020]
If the sequence does not contain negative terms then its terms can be represented in a quadrant. For the construction of the diagram we use the symmetric Dyck paths of A237593 as shown below:
---------------------------------------------------------------
Triangle Diagram of the symmetry of sigma (n = 1..24)
---------------------------------------------------------------
. _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
1; |_| | | | | | | | | | | | | | | | | | | | | | | |
3; |_ _|_| | | | | | | | | | | | | | | | | | | | | |
2, 2; |_ _| _|_| | | | | | | | | | | | | | | | | | | |
7; |_ _ _| _|_| | | | | | | | | | | | | | | | | |
3, 3; |_ _ _| _| _ _|_| | | | | | | | | | | | | | | |
12; |_ _ _ _| _| | _ _|_| | | | | | | | | | | | | |
4, 4; |_ _ _ _| |_ _|_| _ _|_| | | | | | | | | | | |
15; |_ _ _ _ _| _| | _ _ _|_| | | | | | | | | |
5, 3, 5; |_ _ _ _ _| | _|_| | _ _ _|_| | | | | | | |
9, 9; |_ _ _ _ _ _| _ _| _| | _ _ _|_| | | | | |
6, 6; |_ _ _ _ _ _| | _| _| _| | _ _ _ _|_| | | |
28; |_ _ _ _ _ _ _| |_ _| _| _ _| | | _ _ _ _|_| |
7, 7; |_ _ _ _ _ _ _| | _ _| _| _| | | _ _ _ _|
12, 12; |_ _ _ _ _ _ _ _| | | | _|_| |* * * *
8, 8, 8; |_ _ _ _ _ _ _ _| | _ _| _ _|_| |* * * *
31; |_ _ _ _ _ _ _ _ _| | _ _| _| _ _|* * * *
9, 9; |_ _ _ _ _ _ _ _ _| | |_ _ _| _|* * * * * *
39; |_ _ _ _ _ _ _ _ _ _| | _ _| _|* * * * * * *
10, 10; |_ _ _ _ _ _ _ _ _ _| | | |* * * * * * * *
42; |_ _ _ _ _ _ _ _ _ _ _| | _ _ _|* * * * * * * *
11, 5, 5, 11; |_ _ _ _ _ _ _ _ _ _ _| | |* * * * * * * * * * *
18, 18; |_ _ _ _ _ _ _ _ _ _ _ _| |* * * * * * * * * * *
12, 12; |_ _ _ _ _ _ _ _ _ _ _ _| |* * * * * * * * * * *
60; |_ _ _ _ _ _ _ _ _ _ _ _ _|* * * * * * * * * * *
...
The total number of cells in the first n set of symmetric regions of the diagram equals A024916(n), the sum of all divisors of all positive integers <= n, hence the total number of cells in the n-th set of symmetric regions of the diagram equals sigma(n) = A000203(n).
For n = 9 the 9th row of A237593 is [5, 2, 2, 2, 2, 5] and the 8th row of A237593 is [5, 2, 1, 1, 2, 5] therefore between both symmetric Dyck paths there are three regions (or parts) of sizes [5, 3, 5], so row 9 is [5, 3, 5].
The sum of divisors of 9 is 1 + 3 + 9 = A000203(9) = 13. On the other hand the sum of the parts of the symmetric representation of sigma(9) is 5 + 3 + 5 = 13, equaling the sum of divisors of 9.
For n = 24 the 24th row of A237593 is [13, 4, 3, 2, 1, 1, 1, 1, 2, 3, 4, 13] and the 23rd row of A237593 is [12, 5, 2, 2, 1, 1, 1, 1, 2, 2, 5, 12] therefore between both symmetric Dyck paths there are only one region (or part) of size 60, so row 24 is 60.
The sum of divisors of 24 is 1 + 2 + 3 + 4 + 6 + 8 + 12 + 24 = A000203(24) = 60. On the other hand the sum of the parts of the symmetric representation of sigma(24) is 60, equaling the sum of divisors of 24.
Note that the number of *'s in the diagram is 24^2 - A024916(24) = 576 - 491 = A004125(24) = 85.
Also consider the infinite double-staircases diagram defined in A335616 (see the theorem).
For n = 15 the diagram with first 15 levels looks like this:
.
Level "Double-staircases" diagram
. _
1 _|1|_
2 _|1 _ 1|_
3 _|1 |1| 1|_
4 _|1 _| |_ 1|_
5 _|1 |1 _ 1| 1|_
6 _|1 _| |1| |_ 1|_
7 _|1 |1 | | 1| 1|_
8 _|1 _| _| |_ |_ 1|_
9 _|1 |1 |1 _ 1| 1| 1|_
10 _|1 _| | |1| | |_ 1|_
11 _|1 |1 _| | | |_ 1| 1|_
12 _|1 _| |1 | | 1| |_ 1|_
13 _|1 |1 | _| |_ | 1| 1|_
14 _|1 _| _| |1 _ 1| |_ |_ 1|_
15 |1 |1 |1 | |1| | 1| 1| 1|
.
Starting from A196020 and after the algorithm described in A280850 and A296508 applied to the above diagram we have a new diagram as shown below:
.
Level "Ziggurat" diagram
. _
6 |1|
7 _ | | _
8 _|1| _| |_ |1|_
9 _|1 | |1 1| | 1|_
10 _|1 | | | | 1|_
11 _|1 | _| |_ | 1|_
12 _|1 | |1 1| | 1|_
13 _|1 | | | | 1|_
14 _|1 | _| _ |_ | 1|_
15 |1 | |1 |1| 1| | 1|
.
The 15th row
of A249351 : [1,1,1,1,1,1,1,1,0,0,0,1,1,1,2,1,1,1,0,0,0,1,1,1,1,1,1,1,1]
The 15th row
of triangle: [ 8, 8, 8 ]
The 15th row
The 15th row
.
More generally, for n >= 1, it appears there is the same correspondence between the original diagram of the symmetric representation of sigma(n) and the "Ziggurat" diagram of n.
MATHEMATICA
T[n_, k_] := Ceiling[(n + 1)/k - (k + 1)/2] (* from A235791 *)
path[n_] := Module[{c = Floor[(Sqrt[8n + 1] - 1)/2], h, r, d, rd, k, p = {{0, n}}}, h = Map[T[n, #] - T[n, # + 1] &, Range[c]]; r = Join[h, Reverse[h]]; d = Flatten[Table[{{1, 0}, {0, -1}}, {c}], 1];
rd = Transpose[{r, d}]; For[k = 1, k <= 2c, k++, p = Join[p, Map[Last[p] + rd[[k, 2]] * # &, Range[rd[[k, 1]]]]]]; p]
segments[n_] := SplitBy[Map[Min, Drop[Drop[path[n], 1], -1] - path[n - 1]], # == 0 &]
a237270[n_] := Select[Map[Apply[Plus, #] &, segments[n]], # != 0 &]
Flatten[Map[a237270, Range[40]]] (* data *)
CROSSREFS
Cf. A000203, A004125, A023196, A024916, A153485, A196020, A221529, A231347, A235791, A235796, A236104, A236112, A236540, A237046, A237048, A237271, A237590, A237591, A237593, A239050, A239660, A239663, A239665, A239931, A239932, A239933, A239934, A240020, A240062, A244050, A245092, A249351, A262626, A280850, A280851, A296508, A335616, A340035.
EXTENSIONS
Drawing of the spiral extended by Omar E. Pol, Nov 22 2020
Irregular triangle read by rows: T(n,k) is the difference between the total number of partitions of all positive integers <= n into exactly k consecutive parts, and the total number of partitions of all positive integers <= n into exactly k+1 consecutive parts (n>=1, 1<=k<= A003056(n)).
+10
279
1, 2, 2, 1, 3, 1, 3, 2, 4, 1, 1, 4, 2, 1, 5, 2, 1, 5, 2, 2, 6, 2, 1, 1, 6, 3, 1, 1, 7, 2, 2, 1, 7, 3, 2, 1, 8, 3, 1, 2, 8, 3, 2, 1, 1, 9, 3, 2, 1, 1, 9, 4, 2, 1, 1, 10, 3, 2, 2, 1, 10, 4, 2, 2, 1, 11, 4, 2, 1, 2, 11, 4, 3, 1, 1, 1, 12, 4, 2, 2, 1, 1, 12, 5, 2, 2, 1, 1, 13, 4, 3, 2, 1, 1, 13, 5, 3, 1, 2, 1, 14, 5, 2, 2, 2, 1
COMMENTS
The original name was: Triangle read by rows: T(n,k) = A235791(n,k) - A235791(n,k+1), assuming that the virtual right border of triangle A235791 is A000004.
T(n,k) is also the length of the k-th segment in a zig-zag path on the first quadrant of the square grid, connecting the point (n, 0) with the point (m, m), starting with a segment in vertical direction, where m <= n.
Conjecture: the area of the polygon defined by the x-axis, this zig-zag path and the diagonal [(0, 0), (m, m)], is equal to A024916(n)/2, one half of the sum of all divisors of all positive integers <= n. Therefore the reflected polygon, which is adjacent to the y-axis, with the zig-zag path connecting the point (0, n) with the point (m, m), has the same property. And so on for each octant in the four quadrants.
For the representation of A024916 and A000203 we use two octants, for example: the first octant and the second octant, or the 6th octant and the 7th octant, etc., see A237593.
At least up to n = 128, two zig-zag paths never cross (checked by hand).
The finite sequence formed by the n-th row of triangle together with its mirror row gives the n-th row of triangle A237593.
The place to start is with A235791, which is very simple. Then go to A237591, also very simple, and A237593, still very simple.
You then need to interpret the rows of A237593 as Dyck paths. This interpretation is in terms of run lengths, so 2,1,1,2 means up twice, down once, up once, and down twice. Because the rows of A237593 are symmetric and of even length, this path will always be symmetric.
Now the surprising fact is that the areas enclosed by the Dyck path for n (laid on its side) always includes the area enclosed for n-1; and the number of squares added is sigma(n).
Finally, look at the connected areas enclosed by n but not by n-1; the size of these areas is the symmetric representation of sigma. (End)
The row sum is A235791(n,1) - A235791(n,floor((sqrt(8n+1)-1)/2)+1) = n - 0.
Mathematica function has been written to check the conjecture as well as non-crossing zig-zag paths (Dyck paths rotated by 90 degrees) up through n=30000 (same applies to A237593). (End)
The n-th zig-zag path ending at the point (m, m), where m = A240542(n). - Omar E. Pol, Apr 16 2014
n is an odd prime if and only if T(n,2) = 1 + T(n-1,2) and T(n,k) = T(n-1,k) for the rest of the values of k.
The elements of the n-th row of triangle together with the elements of the n-th row of triangle A261350 give the n-th row of triangle A237593.
T(n,k) is also the area (or the number of cells) of the k-th vertical side at the n-th level (starting from the top) in the left hand part of the front view of the stepped pyramid described in A245092, see Example section.
(End)
T(n,k) is also the number of cells between the k-th and the (k+1)st line segments (from left to right) in the n-th row of the diagram as shown in Example section.
Note that the number of horizontal line segments in the n-th row of the diagram equals A001227(n), the number of odd divisors of n. (End)
Conjecture: the values f(n,k) in the n-th row of the triangle are either 1 or 2 for all k with ceiling((sqrt(4*n+1)-1)/2) <= k <= floor((sqrt(8*n+1)-1)/2) = r(n), the length of the n-th row, though the lower bound need not be minimal; tested through 2500000. See also A285356. - Hartmut F. W. Hoft, Apr 17 2017
Conjecture: T(n,k) is the difference between the total number of partitions of all positive integers <= n into exactly k consecutive parts, and the total number of partitions of all positive integers <= n into exactly k+1 consecutive parts. - Omar E. Pol, Apr 30 2017
It appears that T(n,2)/T(n,1) converges to 1/3.
It appears that T(n,3)/T(n,2) converges to 1/2.
It appears that T(n,4)/T(n,3) converges to 3/5.
It appears that T(n,5)/T(n,4) converges to 2/3. (End)
In other words: T(n,k) is the length of the k-th line segment of the largest Dyck path of the symmetric representation of sigma(n). - Omar E. Pol, Sep 08 2021
FORMULA
T(n,k) = ceiling((n+1)/k - (k+1)/2) - ceiling((n+1)/(k+1) - (k+2)/2), for 1 <= n and 1 <= k <= floor((sqrt(8n+1)-1)/2). - Hartmut F. W. Hoft, Apr 07 2014
EXAMPLE
Triangle begins:
1;
2;
2, 1;
3, 1;
3, 2;
4, 1, 1;
4, 2, 1;
5, 2, 1;
5, 2, 2;
6, 2, 1, 1;
6, 3, 1, 1;
7, 2, 2, 1;
7, 3, 2, 1;
8, 3, 1, 2;
8, 3, 2, 1, 1;
9, 3, 2, 1, 1;
9, 4, 2, 1, 1;
10, 3, 2, 2, 1;
10, 4, 2, 2, 1;
11, 4, 2, 1, 2;
11, 4, 3, 1, 1, 1;
12, 4, 2, 2, 1, 1;
12, 5, 2, 2, 1, 1;
13, 4, 3, 2, 1, 1;
13, 5, 3, 1, 2, 1;
14, 5, 2, 2, 2, 1;
14, 5, 3, 2, 1, 2;
15, 5, 3, 2, 1, 1, 1;
...
For n = 10 the 10th row of triangle A235791 is [10, 4, 2, 1] so row 10 is [6, 2, 1, 1].
Illustration of initial terms:
Row _
1 _|1|
2 _|2 _|
3 _|2 |1|
4 _|3 _|1|
5 _|3 |2 _|
6 _|4 _|1|1|
7 _|4 |2 |1|
8 _|5 _|2 _|1|
9 _|5 |2 |2 _|
10 _|6 _|2 |1|1|
11 _|6 |3 _|1|1|
12 _|7 _|2 |2 |1|
13 _|7 |3 |2 _|1|
14 _|8 _|3 _|1|2 _|
15 _|8 |3 |2 |1|1|
16 _|9 _|3 |2 |1|1|
17 _|9 |4 _|2 _|1|1|
18 _|10 _|3 |2 |2 |1|
19 _|10 |4 |2 |2 _|1|
20 _|11 _|4 _|2 |1|2 _|
21 _|11 |4 |3 _|1|1|1|
22 _|12 _|4 |2 |2 |1|1|
23 _|12 |5 _|2 |2 |1|1|
24 _|13 _|4 |3 |2 _|1|1|
25 _|13 |5 |3 _|1|2 |1|
26 _|14 _|5 _|2 |2 |2 _|1|
27 _|14 |5 |3 |2 |1|2 _|
28 |15 |5 |3 |2 |1|1|1|
...
Also the diagram represents the left part of the front view of the pyramid described in A245092. For the other half front view see A261350. For more information about the pyramid and the symmetric representation of sigma see A237593. (End)
For n = 12 the symmetric representation of sigma(12) in the fourth quadrant is as shown below:
. _
| |
| |
| |
| |
| |
_ _ _| |
_| _ _|
_| |
| _|
| _ _|1
_ _ _ _ _ _| | 2
|_ _ _ _ _ _ _|2
7
.
The lengths of the successive line segments from the first vertex to the central vertex of the largest Dyck path are [7, 2, 2, 1] respectively, the same as the 12th row of triangle. (End)
MATHEMATICA
row[n_]:= Floor[(Sqrt[8*n+1] -1)/2]; f[n_, k_]:= Ceiling[(n+1)/k-(k+1)/2] - Ceiling[(n+1)/(k+1)-(k+2)/2];
Table[f[n, k], {n, 1, 50}, {k, 1, row[n]}]//Flatten
PROG
(PARI) row235791(n) = vector((sqrtint(8*n+1)-1)\2, i, 1+(n-(i*(i+1)/2))\i);
row(n) = {my(orow = concat(row235791(n), 0)); vector(#orow -1, i, orow[i] - orow[i+1]); } \\ Michel Marcus, Mar 27 2014
(Python)
from sympy import sqrt
import math
def T(n, k): return int(math.ceil((n + 1)/k - (k + 1)/2)) - int(math.ceil((n + 1)/(k + 1) - (k + 2)/2))
for n in range(1, 29): print([T(n, k) for k in range(1, int((sqrt(8*n + 1) - 1)/2) + 1)]) # Indranil Ghosh, Apr 30 2017
CROSSREFS
Cf. A000203, A001227, A024916, A196020, A235791, A236104, A237048, A237270, A237271, A237593, A239660, A239931- A239934, A240542, A244580, A245092, A249351, A259176, A259177, A261350, A261699, A262626, A285356, A286000, A286001.
EXTENSIONS
New name from a comment dated Apr 30 2017. - Omar E. Pol, Jun 18 2023
Triangle read by rows: T(n,k), n >= 1, k >= 1, in which column k lists k copies of the positive squares in nondecreasing order, and the first element of column k is in row k(k+1)/2.
+10
261
1, 4, 9, 1, 16, 1, 25, 4, 36, 4, 1, 49, 9, 1, 64, 9, 1, 81, 16, 4, 100, 16, 4, 1, 121, 25, 4, 1, 144, 25, 9, 1, 169, 36, 9, 1, 196, 36, 9, 4, 225, 49, 16, 4, 1, 256, 49, 16, 4, 1, 289, 64, 16, 4, 1, 324, 64, 25, 9, 1, 361, 81, 25, 9, 1, 400, 81, 25, 9, 4
COMMENTS
These are the squares of the entries of the triangle in A235791: T(n,k) = ( A235791(n,k))^2.
Row n has length A003056(n) hence the first element of column k is in row A000217(k).
Also column k lists the partial sums of the k-th column of triangle A196020 which gives an identity for sigma.
Since all the elements of this sequence are squares, we can draw an illustration of the alternating sum of row n step by step, and a symmetric diagram for A000203, A024916, A004125; see example.
For more information about the diagram see A237593.
FORMULA
Sum_{k=1.. A003056(n)} (-1)^(k-1)*T(n,k) = A024916(n). [Although this was stated as a fact, as far as I can tell, no proof was known. However, Don Reble has recently found a proof, which will be added here soon. - N. J. A. Sloane, Nov 23 2020]
A000203(n) = Sum_{k=1.. A003056(n)} (-1)^(k-1) * (T(n,k) - T(n-1,k)), assuming that T(k*(k+1)/2-1,k) = 0. - Omar E. Pol, Oct 10 2018
EXAMPLE
Triangle begins:
1;
4;
9, 1;
16, 1;
25, 4;
36, 4, 1;
49, 9, 1;
64, 9, 1;
81, 16, 4;
100, 16, 4, 1;
121, 25, 4, 1;
144, 25, 9, 1;
169, 36, 9, 1;
196, 36, 9, 4;
225, 49, 16, 4, 1;
256, 49, 16, 4, 1;
289, 64, 16, 4, 1;
324, 64, 25, 9, 1;
361, 81, 25, 9, 1;
400, 81, 25, 9, 4;
441, 100, 36, 9, 4, 1;
484, 100, 36, 16, 4, 1;
529, 121, 36, 16, 4, 1;
576, 121, 49, 16, 4, 1;
...
For n = 6 the sum of all divisors of all positive integers <= 6 is [1] + [1+2] + [1+3] + [1+2+4] + [1+5] + [1+2+3+6] = 1 + 3 + 4 + 7 + 6 + 12 = 33. On the other hand the 6th row of triangle is 36, 4, 1, therefore the alternating row sum is 36 - 4 + 1 = 33, equaling the sum of all divisors of all positive integers <= 6.
Illustration of the alternating sum of the 6th row as the area of a polygon (or the number of cells), step by step, in the fourth quadrant:
. _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
. | | | | | |
. | | | | | |
. | | | | | |
. | | | _ _| | _|
. | | | | | _|
. |_ _ _ _ _ _| |_ _ _ _| |_ _ _ _|
.
. 36 36 - 4 = 32 36 - 4 + 1 = 33
.
--------------------------------------------------
--------------------------------------------------
. _ _ _ _ _ _ _ _ _ _ _ _
1 1 1 |_| | | | | | | | | | | |
2 3 4 |_ _|_| | | | | | | | | |
3 4 8 |_ _| _|_| | | | | | | |
4 7 15 |_ _ _| _|_| | | | | |
5 6 21 |_ _ _| _| _ _|_| | | |
6 12 33 |_ _ _ _| _| | _ _|_| |
7 8 41 |_ _ _ _| |_ _|_| _ _|
8 15 56 |_ _ _ _ _| _| |* *
9 13 69 |_ _ _ _ _| | _|* *
10 18 87 |_ _ _ _ _ _| _ _|* * *
11 12 99 |_ _ _ _ _ _| |* * * * *
12 28 127 |_ _ _ _ _ _ _|* * * * *
.
The total number of cells in the first n set of symmetric regions of the diagram equals A024916(n). It appears that the total number of cells in the n-th set of symmetric regions of the diagram equals sigma(n) = A000203(n). Example: for n = 12 the 12th row of triangle is 144, 25, 9, 1, hence the alternating sums is 144 - 25 + 9 - 1 = 127. On the other hand we have that A000290(12) - A004125(12) = 144 - 17 = A024916(12) = 127, equaling the total number of cells in the diagram after 12 stages. The number of cells in the 12th set of symmetric regions of the diagram is sigma(12) = A000203(12) = 28. Note that in this case there is only one region. Finally, the number of *'s is A004125(12) = 17.
Note that the diagram is also the top view of the stepped pyramid described in A245092. - Omar E. Pol, Feb 12 2018
PROG
(Python)
from sympy import sqrt
import math
def T(n, k): return int(math.ceil((n + 1)/k - (k + 1)/2))
for n in range(1, 21): print([T(n, k)**2 for k in range(1, int(math.floor((sqrt(8*n + 1) - 1)/2)) + 1)]) # Indranil Ghosh, Apr 25 2017
CROSSREFS
Cf. A000203, A000217, A000290, A001227, A003056, A008794, A024916, A004125, A196020, A211343, A228813, A231345, A231347, A235791, A235794, A235799, A236106, A236112, A236540, A237270, A237591, A237593, A239660, A244050, A245092, A262626, A286000.
Irregular triangle read by rows: T(n,k), n >= 1, k >= 1, in which column k lists k copies of every positive integer in nondecreasing order, and the first element of column k is in row k(k+1)/2.
+10
251
1, 2, 3, 1, 4, 1, 5, 2, 6, 2, 1, 7, 3, 1, 8, 3, 1, 9, 4, 2, 10, 4, 2, 1, 11, 5, 2, 1, 12, 5, 3, 1, 13, 6, 3, 1, 14, 6, 3, 2, 15, 7, 4, 2, 1, 16, 7, 4, 2, 1, 17, 8, 4, 2, 1, 18, 8, 5, 3, 1, 19, 9, 5, 3, 1, 20, 9, 5, 3, 2, 21, 10, 6, 3, 2, 1, 22, 10, 6, 4, 2, 1, 23, 11, 6, 4, 2, 1, 24, 11, 7, 4, 2, 1
COMMENTS
The alternating sum of the squares of the elements of the n-th row equals the sum of all divisors of all positive integers <= n, i.e., Sum_{k=1.. A003056(n)} (-1)^(k-1)*(T(n,k))^2 = A024916(n).
Row n has length A003056(n) hence the first element of column k is in row A000217(k).
The sum of row n gives A060831(n), the sum of the number of odd divisors of all positive integers <= n. - Omar E. Pol, Mar 01 2014. [An equivalent assertion is that the sum of row n of A237048 is the number of odd divisors of n, and this was proved by Hartmut F. W. Hoft in a comment in A237048. - N. J. A. Sloane, Dec 07 2020]
The place to start is with A235791, which is very simple. Then go to A237591, also very simple, and A237593, still very simple.
You then need to interpret the rows of A237593 as Dyck paths. This interpretation is in terms of run lengths, so 2,1,1,2 means up twice, down once, up once, and down twice. Because the rows of A237593 are symmetric and of even length, this path will always be symmetric.
Now the surprising fact is that the areas enclosed by the Dyck path for n (laid on its side) always includes the area enclosed for n-1; and the number of squares added is sigma(n).
Finally, look at the connected areas enclosed by n but not by n-1; the size of these areas is the symmetric representation of sigma. (End)
Mathematica function has been written to check the first property up to n = 20000.
T(n,(sqrt(8n+1)-1)/2+1) = 0 for all n >= 1, which is useful for formulas for A237591 and A237593. (End)
Conjecture: T(n,k) is also the total number of partitions of all positive integers <= n into exactly k consecutive parts, i.e., the partial column sum of A285898, or in accordance with the triangles of the same family: the partial column sum of A237048. - Omar E. Pol, Apr 28 2017, Nov 24 2020
The above conjecture is true. The proof will be added soon (it uses the generating function for the columns). - N. J. A. Sloane, Nov 24 2020
T(n,k) is also the total length of all line segments between the k-th vertex and the central vertex of the largest Dyck path of the symmetric representation of sigma(n). In other words: T(n,k) is the sum of the last ( A003056(n)-k+1) terms of the n-th row of A237591. - Omar E. Pol, Sep 07 2021
T(n,k) is also the Manhattan distance between the k-th vertex and the central vertex of the Dyck path described in the n-th row of the triangle A237593. - Omar E. Pol, Jan 11 2023
FORMULA
T(n,k) = ceiling((n+1)/k - (k+1)/2) for 1 <= n, 1 <= k <= floor((sqrt(8n+1)-1)/2) = A003056(n). - Hartmut F. W. Hoft, Apr 07 2014
G.f. for column k (k >= 1): x^(k*(k+1)/2)/( (1-x)*(1-x^k) ). - N. J. A. Sloane, Nov 24 2020
Sigma(n) = Sum_{k=1.. A003056(n)} (-1)^(k-1) * (T(n,k)^2 - T(n-1,k)^2), assuming that T(k*(k+1)/2-1,k) = 0. - Omar E. Pol, Oct 10 2018
a(s(n,k)) = T(n,k), n >= 1, 1 <= k <= r = floor((sqrt(8*n + 1) - 1)/2), where s(n,k) = r*n - r*(r+1)*(r+2)/6 + k translates position (row n, column k) in the triangle of this sequence to its position in the sequence. - Hartmut F. W. Hoft, Feb 24 2021
EXAMPLE
Triangle begins:
1;
2;
3, 1;
4, 1;
5, 2;
6, 2, 1;
7, 3, 1;
8, 3, 1;
9, 4, 2;
10, 4, 2, 1;
11, 5, 2, 1;
12, 5, 3, 1;
13, 6, 3, 1;
14, 6, 3, 2;
15, 7, 4, 2, 1;
16, 7, 4, 2, 1;
17, 8, 4, 2, 1;
18, 8, 5, 3, 1;
19, 9, 5, 3, 1;
20, 9, 5, 3, 2;
21, 10, 6, 3, 2, 1;
22, 10, 6, 4, 2, 1;
23, 11, 6, 4, 2, 1;
24, 11, 7, 4, 2, 1;
25, 12, 7, 4, 3, 1;
26, 12, 7, 5, 3, 1;
27, 13, 8, 5, 3, 2;
28, 13, 8, 5, 3, 2, 1;
...
For n = 10 the 10th row of triangle is 10, 4, 2, 1, so we have that 10^2 - 4^2 + 2^2 - 1^2 = 100 - 16 + 4 - 1 = 87, the same as A024916(10) = 87, the sum of all divisors of all positive integers <= 10.
Illustration of initial terms in the third quadrant:
. y
Row _|
1 _|1|
2 _|2 _|
3 _|3 |1|
4 _|4 _|1|
5 _|5 |2 _|
6 _|6 _|2|1|
7 _|7 |3 |1|
8 _|8 _|3 _|1|
9 _|9 |4 |2 _|
10 _|10 _|4 |2|1|
11 _|11 |5 _|2|1|
12 _|12 _|5 |3 |1|
13 _|13 |6 |3 _|1|
14 _|14 _|6 _|3|2 _|
15 _|15 |7 |4 |2|1|
16 _|16 _|7 |4 |2|1|
17 _|17 |8 _|4 _|2|1|
18 _|18 _|8 |5 |3 |1|
19 _|19 |9 |5 |3 _|1|
20 _|20 _|9 _|5 |3|2 _|
21 _|21 |10 |6 _|3|2|1|
22 _|22 _|10 |6 |4 |2|1|
23 _|23 |11 _|6 |4 |2|1|
24 _|24 _|11 |7 |4 _|2|1|
25 _|25 |12 |7 _|4|3 |1|
26 _|26 _|12 _|7 |5 |3 _|1|
27 _|27 |13 |8 |5 |3|2 _|
28 |28 |13 |8 |5 |3|2|1|
...
T(n,k) is also the number of cells between the k-th vertical line segment (from left to right) and the y-axis in the n-th row of the structure.
Note that the number of horizontal line segments in the n-th row of the structure equals A001227(n), the number of odd divisors of n.
Also the diagram represents the left part of the front view of the pyramid described in A245092. (End)
For n = 12 the symmetric representation of sigma(12) in the fourth quadrant is as shown below:
_
| |
| |
| |
| |
| |
_ _ _| |
_| _ _|
_| |
| _|
| _ _|
_ _ _ _ _ _| |3 1
|_ _ _ _ _ _ _|
12 5
.
For n = 12 and k = 1 the total length of all line segments between the first vertex and the central vertex of the largest Dyck path is equal to 12, so T(12,1) = 12.
For n = 12 and k = 2 the total length of all line segments between the second vertex and the central vertex of the largest Dyck path is equal to 5, so T(12,2) = 5.
For n = 12 and k = 3 the total length of all line segments between the third vertex and the central vertex of the largest Dyck path is equal to 3, so T(12,3) = 3.
For n = 12 and k = 4 the total length of all line segments between the fourth vertex and the central vertex of the largest Dyck path is equal to 1, so T(12,4) = 1.
Hence the 12th row of triangle is [12, 5, 3, 1]. (End)
MATHEMATICA
row[n_] := Floor[(Sqrt[8*n + 1] - 1)/2]; f[n_, k_] := Ceiling[(n + 1)/k - (k + 1)/2]; Table[f[n, k], {n, 1, 150}, {k, 1, row[n]}] // Flatten (* Hartmut F. W. Hoft, Apr 07 2014 *)
PROG
(PARI) row(n) = vector((sqrtint(8*n+1)-1)\2, i, 1+(n-(i*(i+1)/2))\i); \\ Michel Marcus, Mar 27 2014
(Python)
from sympy import sqrt
import math
def T(n, k): return int(math.ceil((n + 1)/k - (k + 1)/2))
for n in range(1, 21): print([T(n, k) for k in range(1, int(math.floor((sqrt(8*n + 1) - 1)/2)) + 1)]) # Indranil Ghosh, Apr 25 2017
CROSSREFS
Cf. A000203, A000217, A001227, A196020, A211343, A228813, A231345, A231347, A235794, A236106, A236112, A237270, A237271, A237593, A239660, A245092, A261699, A262626, A286000, A286001, A280850, A280851, A296508, A335616.
Irregular triangle read by rows: T(n,k), n >= 1, k >= 1, in which column k lists the odd numbers interleaved with k-1 zeros, and the first element of column k is in row k(k+1)/2.
+10
248
1, 3, 5, 1, 7, 0, 9, 3, 11, 0, 1, 13, 5, 0, 15, 0, 0, 17, 7, 3, 19, 0, 0, 1, 21, 9, 0, 0, 23, 0, 5, 0, 25, 11, 0, 0, 27, 0, 0, 3, 29, 13, 7, 0, 1, 31, 0, 0, 0, 0, 33, 15, 0, 0, 0, 35, 0, 9, 5, 0, 37, 17, 0, 0, 0, 39, 0, 0, 0, 3, 41, 19, 11, 0, 0, 1, 43, 0, 0, 7, 0, 0, 45, 21, 0, 0, 0, 0, 47, 0, 13, 0, 0, 0
COMMENTS
Gives an identity for sigma(n): alternating sum of row n equals the sum of divisors of n. For proof see Max Alekseyev link.
The number of positive terms in row n is A001227(n), the number of odd divisors of n.
If n = 2^j then the only positive integer in row n is T(n,1) = 2^(j+1) - 1.
If n is an odd prime then the only two positive integers in row n are T(n,1) = 2n - 1 and T(n,2) = n - 2.
If T(n,k) = 3 then T(n+1,k+1) = 1, the first element of the column k+1.
The partial sums of column k give the column k of A236104.
Alternating sum of row n equals the number of units cubes that protrude from the n-th level of the stepped pyramid described in A245092. - Omar E. Pol, Oct 28 2015
Conjecture: T(n,k) is the difference between the square of the total number of partitions of all positive integers <= n into exactly k consecutive parts, and the square of the total number of partitions of all positive integers < n into exactly k consecutive parts. - Omar E. Pol, Feb 14 2018
T(n,k) is also the number of steps in the first n levels of the k-th double-staircase that has at least one step in the n-th level of the "Double- staircases" diagram, otherwise T(n,k) = 0, (see the Example section).
Apart from the alternating row sums and the sum of divisors function A000203 another connection with Euler's pentagonal theorem is that in the irregular triangle of A238442 the k-th column starts in the row that is the k-th generalized pentagonal number A001318(k) while here the k-th column starts in the row that is the k-th generalized hexagonal number A000217(k). Both A001318 and A000217 are successive members of the same family: the generalized polygonal numbers. - Omar E. Pol, Sep 23 2021
Other triangle with the same row lengths and alternating row sums equals sigma(n) is A252117. - Omar E. Pol, May 03 2022
FORMULA
T(n,k) = 2* A211343(n,k) - 1, if A211343(n,k) >= 1 otherwise T(n,k) = 0.
If n==k/2 (mod k) and n>=k(k+1)/2, then T(n,k) = 2*n/k - k; otherwise T(n,k) = 0. - Max Alekseyev, Nov 18 2013
EXAMPLE
Triangle begins:
1;
3;
5, 1;
7, 0;
9, 3;
11, 0, 1;
13, 5, 0;
15, 0, 0;
17, 7, 3;
19, 0, 0, 1;
21, 9, 0, 0;
23, 0, 5, 0;
25, 11, 0, 0;
27, 0, 0, 3;
29, 13, 7, 0, 1;
31, 0, 0, 0, 0;
33, 15, 0, 0, 0;
35, 0, 9, 5, 0;
37, 17, 0, 0, 0;
39, 0, 0, 0, 3;
41, 19, 11, 0, 0, 1;
43, 0, 0, 7, 0, 0;
45, 21, 0, 0, 0, 0;
47, 0, 13, 0, 0, 0;
49, 23, 0, 0, 5, 0;
51, 0, 0, 9, 0, 0;
53, 25, 15, 0, 0, 3;
55, 0, 0, 0, 0, 0, 1;
...
For n = 15 the divisors of 15 are 1, 3, 5, 15, so the sum of divisors of 15 is 1 + 3 + 5 + 15 = 24. On the other hand, the 15th row of the triangle is 29, 13, 7, 0, 1, so the alternating row sum is 29 - 13 + 7 - 0 + 1 = 24, equaling the sum of divisors of 15.
If n is even then the alternating sum of the n-th row is simpler to evaluate than the sum of divisors of n. For example the sum of divisors of 24 is 1 + 2 + 3 + 4 + 6 + 8 + 12 + 24 = 60, and the alternating sum of the 24th row of triangle is 47 - 0 + 13 - 0 + 0 - 0 = 60.
For an illustration of the rows of triangle consider the infinite "double-staircases" diagram defined in A335616 (see also the theorem there).
For n = 15 the diagram with first 15 levels looks like this:
.
Level "Double-staircases" diagram
. _
1 _|1|_
2 _|1 _ 1|_
3 _|1 |1| 1|_
4 _|1 _| |_ 1|_
5 _|1 |1 _ 1| 1|_
6 _|1 _| |1| |_ 1|_
7 _|1 |1 | | 1| 1|_
8 _|1 _| _| |_ |_ 1|_
9 _|1 |1 |1 _ 1| 1| 1|_
10 _|1 _| | |1| | |_ 1|_
11 _|1 |1 _| | | |_ 1| 1|_
12 _|1 _| |1 | | 1| |_ 1|_
13 _|1 |1 | _| |_ | 1| 1|_
14 _|1 _| _| |1 _ 1| |_ |_ 1|_
15 |1 |1 |1 | |1| | 1| 1| 1|
.
The first largest double-staircase has 29 horizontal steps, the second double-staircase has 13 steps, the third double-staircase has 7 steps, and the fifth double-staircases has only one step. Note that the fourth double-staircase does not count because it does not have horizontal steps in the 15th level, so the 15th row of triangle is [29, 13, 7, 0, 1].
For a connection with the "Ziggurat" diagram and the parts and subparts of the symmetric representation of sigma(15) see also A237270. (End)
MAPLE
T_row := proc(n) local T;
T := (n, k) -> if modp(n-k/2, k) = 0 and n >= k*(k+1)/2 then 2*n/k-k else 0 fi;
seq(T(n, k), k=1..floor((sqrt(8*n+1)-1)/2)) end:
MATHEMATICA
T[n_, k_] := If[Mod[n - k*(k+1)/2, k] == 0 , 2*n/k - k, 0]
row[n_] := Floor[(Sqrt[8n+1]-1)/2]
line[n_] := Map[T[n, #]&, Range[row[n]]]
a196020[m_, n_] := Map[line, Range[m, n]]
Flatten[a196020[1, 22]] (* data *)
A196020row = Function[n, Table[If[Divisible[Numerator[n-k/2], k] && CoprimeQ[ Denominator[n- k/2], k], 2*n/k-k, 0], {k, 1, Floor[(Sqrt[8 n+1]-1)/2]}]]
Flatten[Table[A196020row[n], {n, 1, 24}]] (* Peter Luschny, Oct 28 2015 *)
PROG
(Sage)
def T(n, k):
q = (2*n-k)/2
b = k.divides(q.numerator()) and gcd(k, q.denominator()) == 1
return 2*n/k - k if b else 0
for n in (1..24): [T(n, k) for k in (1..floor((sqrt(8*n+1)-1)/2))] # Peter Luschny, Oct 28 2015
CROSSREFS
Cf. A000203, A000217, A001227, A001318, A003056, A211343, A212119, A228813, A231345, A231347, A235791, A235794, A236104, A236106, A236112, A237048, A237271, A237591, A237593, A238005, A239660, A244050, A245092, A261699, A262626, A286000, A286001, A280850, A335616, A338721.
The even numbers ( A005843) and the values of sigma function ( A000203) interleaved.
+10
241
0, 1, 2, 3, 4, 4, 6, 7, 8, 6, 10, 12, 12, 8, 14, 15, 16, 13, 18, 18, 20, 12, 22, 28, 24, 14, 26, 24, 28, 24, 30, 31, 32, 18, 34, 39, 36, 20, 38, 42, 40, 32, 42, 36, 44, 24, 46, 60, 48, 31, 50, 42, 52, 40, 54, 56, 56, 30, 58, 72, 60, 32, 62, 63, 64, 48
COMMENTS
Consider an irregular stepped pyramid with n steps. The base of the pyramid is equal to the symmetric representation of A024916(n), the sum of all divisors of all positive integers <= n. Two of the faces of the pyramid are the same as the representation of the n-th triangular numbers as a staircase. The total area of the pyramid is equal to 2* A024916(n) + A046092(n). The volume is equal to A175254(n). By definition a(2n-1) is A000203(n), the sum of divisors of n. Starting from the top a(2n-1) is also the total area of the horizontal part of the n-th step of the pyramid. By definition, a(2n) = A005843(n) = 2n. Starting from the top, a(2n) is also the total area of the irregular vertical part of the n-th step of the pyramid.
On the other hand the sequence also has a symmetric representation in two dimensions, see Example.
The structure of this infinite pyramid arises after the 90-degree-zig-zag folding of the diagram of the isosceles triangle A237593 (see the links).
The terraces at the m-th level of the pyramid are also the parts of the symmetric representation of sigma(m), m >= 1, hence the sum of the areas of the terraces at the m-th level equals A000203(m).
Note that the stepped pyramid is also one of the 3D-quadrants of the stepped pyramid described in A244050.
For more information about the pyramid see A237593 and all its related sequences. (End)
EXAMPLE
Illustration of initial terms:
----------------------------------------------------------------------
a(n) Diagram
----------------------------------------------------------------------
0 _
1 |_|\ _
2 \ _| |\ _
3 |_ _| | |\ _
4 \ _ _|_| | |\ _
4 |_ _| _| | | |\ _
6 \ _ _| _| | | | |\ _
7 |_ _ _| _|_| | | | |\ _
8 \ _ _ _| _ _| | | | | |\ _
6 |_ _ _| | _| | | | | | |\ _
10 \ _ _ _| _| _|_| | | | | | |\ _
12 |_ _ _ _| _| _ _| | | | | | | |\ _
12 \ _ _ _ _| _| _ _| | | | | | | | |\ _
8 |_ _ _ _| | _| _ _|_| | | | | | | | |\ _
14 \ _ _ _ _| | _| | _ _| | | | | | | | | |\ _
15 |_ _ _ _ _| |_ _| | _ _| | | | | | | | | | |\ _
16 \ _ _ _ _ _| _ _|_| _ _|_| | | | | | | | | | |\
13 |_ _ _ _ _| | _| _| _ _ _| | | | | | | | | | |
18 \ _ _ _ _ _| | _| _| _ _| | | | | | | | | |
18 |_ _ _ _ _ _| | _| | _ _|_| | | | | | | |
20 \ _ _ _ _ _ _| | _| | _ _ _| | | | | | |
12 |_ _ _ _ _ _| | _ _| _| | _ _ _| | | | | |
22 \ _ _ _ _ _ _| | _ _| _|_| _ _ _|_| | | |
28 |_ _ _ _ _ _ _| | _ _| _ _| | _ _ _| | |
24 \ _ _ _ _ _ _ _| | _| | _| | _ _ _| |
14 |_ _ _ _ _ _ _| | | _| _| _| | _ _ _|
26 \ _ _ _ _ _ _ _| | |_ _| _| _| |
24 |_ _ _ _ _ _ _ _| | _ _| _| _|
28 \ _ _ _ _ _ _ _ _| | _ _| _|
24 |_ _ _ _ _ _ _ _| | | _ _|
30 \ _ _ _ _ _ _ _ _| | |
31 |_ _ _ _ _ _ _ _ _| |
32 \ _ _ _ _ _ _ _ _ _|
...
a(n) is the total area of the n-th set of symmetric regions in the diagram.
.
The above structure contains a hidden pattern, simpler, as shown below:
Level _ _
1 _| | |_
2 _| _|_ |_
3 _| | | | |_
4 _| _| | |_ |_
5 _| | _|_ | |_
6 _| _| | | | |_ |_
7 _| | | | | | |_
8 _| _| _| | |_ |_ |_
9 _| | | _|_ | | |_
10 _| _| | | | | | |_ |_
11 _| | _| | | | |_ | |_
12 _| _| | | | | | |_ |_
13 _| | | _| | |_ | | |_
14 _| _| _| | _|_ | |_ |_ |_
15 _| | | | | | | | | | |_
16 | | | | | | | | | | |
...
The symmetric pattern emerges from the front view of the stepped pyramid.
Note that starting from this diagram A000203 is obtained as follows:
In the pyramid the area of the k-th vertical region in the n-th level on the front view is equal to A237593(n,k), and the sum of all areas of the vertical regions in the n-th level on the front view is equal to 2n.
The area of the k-th horizontal region in the n-th level is equal to A237270(n,k), and the sum of all areas of the horizontal regions in the n-th level is equal to sigma(n) = A000203(n).
(End)
Illustration of the top view of the pyramid with 16 levels:
.
1 1 = 1 |_| | | | | | | | | | | | | | | |
2 3 = 3 |_ _|_| | | | | | | | | | | | | |
3 4 = 2 + 2 |_ _| _|_| | | | | | | | | | | |
4 7 = 7 |_ _ _| _|_| | | | | | | | | |
5 6 = 3 + 3 |_ _ _| _| _ _|_| | | | | | | |
6 12 = 12 |_ _ _ _| _| | _ _|_| | | | | |
7 8 = 4 + 4 |_ _ _ _| |_ _|_| _ _|_| | | |
8 15 = 15 |_ _ _ _ _| _| | _ _ _|_| |
9 13 = 5 + 3 + 5 |_ _ _ _ _| | _|_| | _ _ _|
10 18 = 9 + 9 |_ _ _ _ _ _| _ _| _| |
11 12 = 6 + 6 |_ _ _ _ _ _| | _| _| _|
12 28 = 28 |_ _ _ _ _ _ _| |_ _| _|
13 14 = 7 + 7 |_ _ _ _ _ _ _| | _ _|
14 24 = 12 + 12 |_ _ _ _ _ _ _ _| |
15 24 = 8 + 8 + 8 |_ _ _ _ _ _ _ _| |
16 31 = 31 |_ _ _ _ _ _ _ _ _|
... (End)
MATHEMATICA
Table[If[EvenQ@ n, n, DivisorSigma[1, (n + 1)/2]], {n, 0, 65}] (* or *)
Transpose@ {Range[0, #, 2], DivisorSigma[1, #] & /@ Range[#/2 + 1]} &@ 65 // Flatten (* Michael De Vlieger, Dec 31 2016 *)
With[{nn=70}, Riffle[Range[0, nn, 2], DivisorSigma[1, Range[nn/2]]]] (* Harvey P. Dale, Aug 05 2024 *)
CROSSREFS
Cf. A000203, A004125, A024916, A005843, A175254, A196020, A224880, A235791, A236104, A237270, A237271, A237591, A237593, A239050, A239660, A239931- A239934, A243980, A244050, A244360- A244363, A244370, A244371, A244970, A244971, A245093, A261350, A262626, A277437, A279387, A280223, A280295.
Irregular triangle read by rows: T(n,k), n >= 1, k >= 1, in which column k lists 1's interleaved with k-1 zeros, and the first element of column k is in row k(k+1)/2.
+10
218
1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0, 1, 1, 1, 1, 0, 0, 1, 1, 1, 0, 0, 1, 0, 1, 0, 1, 1, 0, 0, 1, 0, 0, 1, 1, 1, 1, 0, 1, 1, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1, 0, 1, 1, 0, 1, 1, 0, 0, 0, 1, 0, 0, 0, 1, 1, 1, 1, 0, 0, 1, 1, 0, 0, 1, 0, 0, 1, 1, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0
COMMENTS
The sum of row n gives A001227(n), the number of odd divisors of n.
If n = 2^j then the only positive integer in row n is T(n,1) = 1.
If n is an odd prime then the only two positive integers in row n are T(n,1) = 1 and T(n,2) = 1.
The partial sums of column k give the column k of A235791.
Property: Let n = 2^m*s*t with m >= 0 and 1 <= s, t odd, and r(n) = floor((sqrt(8*n+1) - 1)/2) = A003056(n). T(n, k) = 1 precisely when k is odd and k|n, or k = 2^(m+1)*s when 1 <= s < 2^(m+1)*s <= r(n) < t. Thus each odd divisor greater than r(n) is matched by a unique even index less than or equal to r(n).
For further connections with the symmetric representation of sigma see also A249223. (End)
Conjecture 1: alternating sum of row n gives A067742(n), the number of middle divisors of n.
The sum of row n also gives the number of subparts in the symmetric representation of sigma(n), equaling A001227(n), the number of odd divisors of n. For more information see A279387. (End)
Conjecture 2: Alternating sum of row n also gives the number of central subparts in the symmetric representation of sigma(n), equaling the width of the terrace at the n-th level in the main diagonal of the pyramid described in A245092.
Conjecture 3: The sum of the odd-indexed terms in row n gives A082647(n): the number of odd divisors of n less than sqrt(2*n), also the number of partitions of n into an odd number of consecutive parts.
Conjecture 4: The sum of the even-indexed terms in row n gives A131576(n): the number of odd divisors of n greater than sqrt(2*n), also the number of partitions of n into an even number of consecutive parts.
Conjecture 5: The sum of the even-indexed terms in row n also gives the number of pairs of equidistant subparts in the symmetric representation of sigma(n). (End)
Conjecture 6: T(n,k) is also the number of partitions of n into exactly k consecutive parts. - Omar E. Pol, Apr 28 2017
This triangle is a member of an infinite family of irregular triangles read by rows in which column k lists 1's interleaved with k-1 zeros, and the first element of column k is where the row number equals the k-th (m+2)-gonal number, with n >= 1, k >= 1, m >= 0. T(n,k) is also the number of partitions of n into k consecutive parts that differ by m. This is the case for m = 1. For other values of m see the cross-references. - Omar E. Pol, Sep 29 2021
The indices of the rows where the number of 1's increases to a record give A053624. - Omar E. Pol, Mar 04 2023
FORMULA
For n >= 1 and k = 1, ..., A003056(n): if k is odd then T(n, k) = 1 if k|n, otherwise 0, and if k is even then T(n, k) = 1 if k|(n-k/2), otherwise 0. - Hartmut F. W. Hoft, Oct 23 2014
A000203(n) = Sum_{k=1.. A003056(n)} (-1)^(k-1) * ((Sum_{j=k*(k+1)/2..n} T(j,k))^2 - (Sum_{j=k*(k+1)/2..n} T(j-1,k))^2), assuming that T(k*(k+1)/2-1,k) = 0. - Omar E. Pol, Oct 10 2018
Another way of expressing the formula above, using S(n,k) for entries in the triangle of A235791, is:
T(n,k) = S(n,k) - S(n-1,k), for all n >= 1 and 1 <= k <= A003056(n), noting that for triangular numbers n(n+1)/2, S(n(n+1)/2 - 1, A003056(n(n+1)/2)) = S(n(n+1)/2 - 1, n) = 0.
Also, T(n,k) = 1 if n - k(k+1)/2 (mod k) = 0, and 0 otherwise. (End)
EXAMPLE
Triangle begins (rows 1..28):
1;
1;
1, 1;
1, 0;
1, 1;
1, 0, 1;
1, 1, 0;
1, 0, 0;
1, 1, 1;
1, 0, 0, 1;
1, 1, 0, 0;
1, 0, 1, 0;
1, 1, 0, 0;
1, 0, 0, 1;
1, 1, 1, 0, 1;
1, 0, 0, 0, 0;
1, 1, 0, 0, 0;
1, 0, 1, 1, 0;
1, 1, 0, 0, 0;
1, 0, 0, 0, 1;
1, 1, 1, 0, 0, 1;
1, 0, 0, 1, 0, 0;
1, 1, 0, 0, 0, 0;
1, 0, 1, 0, 0, 0;
1, 1, 0, 0, 1, 0;
1, 0, 0, 1, 0, 0;
1, 1, 1, 0, 0, 1;
1, 0, 0, 0, 0, 0, 1;
...
For n = 20 the divisors of 20 are 1, 2, 4, 5, 10, 20.
There are two odd divisors: 1 and 5. On the other hand the 20th row of triangle is [1, 0, 0, 0, 1] and the row sum is 2, equaling the number of odd divisors of 20.
For n = 18 the divisors are 1, 2, 3, 6, 9, 18.
There are three odd divisors: 1 and 3 are in their respective columns, but 9 is accounted for in column 4 = 2^2*1 since 18 = 2^1*1*9 and 9>5, the number of columns in row 18. (End)
Illustration of initial terms:
Row _
1 _|1|
2 _|1 _|
3 _|1 |1|
4 _|1 _|0|
5 _|1 |1 _|
6 _|1 _|0|1|
7 _|1 |1 |0|
8 _|1 _|0 _|0|
9 _|1 |1 |1 _|
10 _|1 _|0 |0|1|
11 _|1 |1 _|0|0|
12 _|1 _|0 |1 |0|
13 _|1 |1 |0 _|0|
14 _|1 _|0 _|0|1 _|
15 _|1 |1 |1 |0|1|
16 _|1 _|0 |0 |0|0|
17 _|1 |1 _|0 _|0|0|
18 _|1 _|0 |1 |1 |0|
19 _|1 |1 |0 |0 _|0|
20 _|1 _|0 _|0 |0|1 _|
21 _|1 |1 |1 _|0|0|1|
22 _|1 _|0 |0 |1 |0|0|
23 _|1 |1 _|0 |0 |0|0|
24 _|1 _|0 |1 |0 _|0|0|
25 _|1 |1 |0 _|0|1 |0|
26 _|1 _|0 _|0 |1 |0 _|0|
27 _|1 |1 |1 |0 |0|1 _|
28 |1 |0 |0 |0 |0|0|1|
...
Note that the 1's are placed exactly below the horizontal line segments.
Also the above structure represents the left hand part of the front view of the pyramid described in A245092. For more information about the pyramid and the symmetric representation of sigma see A237593. (End)
MAPLE
r := proc(n) floor((sqrt(1+8*n)-1)/2) ; end proc: # A003056
A237048:=proc(n, k) local i; global r;
if n<(k-1)*k/2 or k>r(n) then return(0); fi;
if (k mod 2)=1 and (n mod k)=0 then return(1); fi;
if (k mod 2)=0 and ((n-k/2) mod k) = 0 then return(1); fi;
return(0);
end;
MATHEMATICA
cd[n_, k_] := If[Divisible[n, k], 1, 0]
row[n_] := Floor[(Sqrt[8n+1] - 1)/2]
a237048[n_, k_] := If[OddQ[k], cd[n, k], cd[n - k/2, k]]
a237048[n_] := Map[a237048[n, #]&, Range[row[n]]]
Flatten[Map[a237048, Range[24]]] (* data: 24 rows of triangle *)
PROG
(PARI) t(n, k) = if (k % 2, (n % k) == 0, ((n - k/2) % k) == 0);
tabf(nn) = {for (n=1, nn, for (k=1, floor((sqrt(1+8*n)-1)/2), print1(t(n, k), ", "); ); print(); ); } \\ Michel Marcus, Sep 20 2015
(Python)
from sympy import sqrt
import math
def T(n, k): return (n%k == 0)*1 if k%2 == 1 else (((n - k/2)%k) == 0)*1
for n in range(1, 21): print([T(n, k) for k in range(1, int(math.floor((sqrt(8*n + 1) - 1)/2)) + 1)]) # Indranil Ghosh, Apr 21 2017
CROSSREFS
Indices of 1's are also the indices of nonzero terms in A196020, A211343, A236106, A239662, A261699, A272026, A280850, A285891, A285914, A286013, A339275.
The MMA code here is also used in A262045.
Triangles of the same family related to partitions into consecutive parts that differ by m are: A051731 (m=0), this sequence (m=1), A303300 (m=2), A330887 (m=3), A334460 (m=4), A334465 (m=5).
Cf. A000203, A001227, A003056, A053624, A057427, A067742, A082647, A131576, A236104, A235791, A237270, A237271, A237591, A237593, A238005, A239657, A245092, A249351, A262611, A262626, A279387, A279693, A285898, A334466.
Sum of all parts of all partitions of n.
+10
184
0, 1, 4, 9, 20, 35, 66, 105, 176, 270, 420, 616, 924, 1313, 1890, 2640, 3696, 5049, 6930, 9310, 12540, 16632, 22044, 28865, 37800, 48950, 63336, 81270, 104104, 132385, 168120, 212102, 267168, 334719, 418540, 520905, 647172, 800569, 988570, 1216215, 1493520
COMMENTS
Sum of the zeroth moments of all partitions of n.
Also the number of one-element transitions from the integer partitions of n to the partitions of n-1 for labeled parts with the assumption that any part z is composed of labeled elements of amount 1, i.e., z = 1_1 + 1_2 + ... + 1_z. Then one can take from z a single element in z different ways. E.g., for n=3 to n=2 we have A066186(3) = 9 and [111] --> [11], [111] --> [11], [111] --> [11], [12] --> [111], [12] --> [111], [12] --> [2], [3] --> 2, [3] --> 2, [3] --> 2. For the unlabeled case, one can take a single element from z in only one way. Then the number of one-element transitions from the integer partitions of n to the partitions of n-1 is given by A000070. E.g., A000070(3) = 4 and for the transition from n=3 to n=2 one has [111] --> [11], [12] --> [11], [12] --> [2], [3] --> [2]. - Thomas Wieder, May 20 2004
Apart from initial zero this is also as follows:
For n >= 1, a(n) is also the number of cells in a symmetric polycube in which the terraces are the symmetric representation of sigma(k), for k = n..1, (cf. A237593) starting from the base and located at the levels A000041(0).. A000041(n-1) respectively. The polycube looks like a symmetric tower (cf. A221529). A dissection is a three-dimensional spiral whose top view is described in A239660. The growth of the volume of the polycube represents each convolution mentioned above. (End)
a(n) is also the sum of all divisors of all positive integers in a sequence with n blocks where the m-th block consists of A000041(n-m) copies of m, with 1 <= m <= n. The mentioned divisors are also all parts of all partitions of n.
Apart from initial zero this is also the convolution of A340793 and A000070. (End)
FORMULA
G.f.: x * (d/dx) Product_{k>=1} 1/(1-x^k), i.e., derivative of g.f. for A000041. - Jon Perry, Mar 17 2004 (adjusted to match the offset by Geoffrey Critzer, Nov 29 2014)
a(n) ~ exp(Pi*sqrt(2*n/3))/(4*sqrt(3)) * (1 - (sqrt(3/2)/Pi + Pi/(24*sqrt(6))) / sqrt(n)). - Vaclav Kotesovec, Oct 24 2016
EXAMPLE
a(3)=9 because the partitions of 3 are: 3, 2+1 and 1+1+1; and (3) + (2+1) + (1+1+1) = 9.
a(4)=20 because A000041(4)=5 and 4*5=20.
MAPLE
with(combinat): a:= n-> n*numbpart(n): seq(a(n), n=0..50); # Zerinvary Lajos, Apr 25 2007
MATHEMATICA
PartitionsP[ Range[0, 60] ] * Range[0, 60]
PROG
(Haskell)
a066186 = sum . concat . ps 1 where
ps _ 0 = [[]]
ps i j = [t:ts | t <- [i..j], ts <- ps t (j - t)]
(Sage)
[n*Partitions(n).cardinality() for n in range(41)] # Peter Luschny, Jul 29 2014
(Python)
from sympy import npartitions
CROSSREFS
Row sums of triangles A138785, A181187, A245099, A337209, A339106, A340423, A340424, A221529, A302246, A338156, A340035, A340056, A340057, A346741. - Omar E. Pol, Aug 02 2021
Search completed in 0.051 seconds
|