A235791 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.
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
Offset: 1
Examples
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. From _Omar E. Pol_, Nov 19 2015: (Start) 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 more information about the diagram see A286001. - _Omar E. Pol_, Dec 19 2020 From _Omar E. Pol_, Sep 08 2021: (Start) 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)
Links
- G. C. Greubel, Table of n, a(n) for the first 150 rows, flattened
Crossrefs
Programs
-
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 *)
-
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
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
T(n,k) = Sum_{j=1..n} A237048(j,k). - Omar E. Pol, May 18 2017
T(n,k) = sqrt(A236104(n,k)). - Omar E. Pol, Feb 14 2018
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
Comments