A237593 Triangle read by rows in which row n lists the elements of the n-th row of A237591 followed by the same elements in reverse order.
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
Offset: 1
Examples
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 | Area = 13 | | . | . | | | . | . | | | . . . . . . . . | . 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). From _Omar E. Pol_, Aug 18 2015: (Start) 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)
Links
- Robert Price, Table of n, a(n) for n = 1..15008 (rows n = 1..412, flattened)
- Michel Marcus, A colored version of the symmetric representation of sigma(n), multipage, n = 1..85
- Omar E. Pol, An infinite stepped pyramid
- Omar E. Pol, Illustration of initial terms of A000203 in the pyramid
- Omar E. Pol, Illustration of initial terms of A001065 in the pyramid
- Omar E. Pol, Illustration of initial terms of A048050 in the pyramid
- Omar E. Pol, Illustration of initial terms of A067742 in the pyramid
- Omar E. Pol, Illustration of initial terms of A224613, (black spiders)
- Omar E. Pol, Illustration of initial terms as an isosceles triangle (rows: 1..28)
- Omar E. Pol, The symmetric representation of sigma(n), n = 1..64, (version with six colors)
- Index entries for sequences related to sigma(n)
Crossrefs
Row n has length 2*A003056(n).
Row sums give A005843, n >= 1.
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, A224613, 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.
Programs
-
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 *)
-
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
Formula
Let j(n)= floor((sqrt(8n+1)-1)/2) then T(n,k) = A237591(n,k), if k <= j(n); otherwise T(n,k) = A237591(n,2*j(n)+1-k). - Hartmut F. W. Hoft, Apr 07 2014 (corrected by Omar E. Pol, May 31 2015)
Extensions
A minor edit to the definition. - N. J. A. Sloane, Jul 31 2025
Comments