A004736 Triangle read by rows: row n lists the first n positive integers in decreasing order.
1, 2, 1, 3, 2, 1, 4, 3, 2, 1, 5, 4, 3, 2, 1, 6, 5, 4, 3, 2, 1, 7, 6, 5, 4, 3, 2, 1, 8, 7, 6, 5, 4, 3, 2, 1, 9, 8, 7, 6, 5, 4, 3, 2, 1, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 14, 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1
Offset: 1
Examples
The triangle T(n, k) starts: n\k 1 2 3 4 5 6 7 8 9 10 11 12 ... 1: 1 2: 2 1 3: 3 2 1 4: 4 3 2 1 5: 5 4 3 2 1 6: 6 5 4 3 2 1 7: 7 6 5 4 3 2 1 8: 8 7 6 5 4 3 2 1 9: 9 8 7 6 5 4 3 2 1 10: 10 9 8 7 6 5 4 3 2 1 11: 11 10 9 8 7 6 5 4 3 2 1 12: 12 11 10 9 8 7 6 5 4 3 2 1 ... Reformatted. - _Wolfdieter Lang_, Feb 04 2015 T(6, 3) = 4 because the four consecutive 3-subsets of [6] = {1, 2, ..., 6} are {1, 2, 3}, {2, 3, 4}, {3, 4, 5} and {4, 5, 6}. - _Wolfdieter Lang_, May 30 2018
References
- H. S. M. Coxeter, Regular Polytopes, 3rd ed., Dover, NY, 1973, pp 159-162.
Links
- Reinhard Zumkeller, Rows n = 1..100 of triangle, flattened
- Isabel Cação, Helmuth R. Malonek, Maria Irene Falcão, and Graça Tomaz, Combinatorial Identities Associated with a Multidimensional Polynomial Sequence, J. Int. Seq., Vol. 21 (2018), Article 18.7.4.
- Isabel Cação, Helmuth R. Malonek, Maria Irene Falcão, and Graça Tomaz, Intrinsic Properties of a Non-Symmetric Number Triangle, J. Int. Seq., Vol. 26 (2023), Article 23.4.8.
- Glen Joyce C. Dulatre, Jamilah V. Alarcon, Vhenedict M. Florida, and Daisy Ann A. Disu, On Fractal Sequences, DMMMSU-CAS Science Monitor (2016-2017) Vol. 15 No. 2, 109-113.
- Joaquín Figueroa, Ivan Gonzalez, and Daniel Salinas-Arizmendi, A Novel Transfer Matrix Framework for Multiple Dirac Delta Potentials, arXiv:2503.23134 [quant-ph], 2025. See pp. 4, 9.
- Clark Kimberling, Fractal sequences
- Clark Kimberling, Numeration systems and fractal sequences, Acta Arithmetica 73 (1995) 103-117.
- Boris Putievskiy, Transformations Integer Sequences And Pairing Functions arXiv:1212.2732 [math.CO], 2012.
- F. Smarandache, Sequences of Numbers Involved in Unsolved Problems.
- Michael Somos, Sequences used for indexing triangular or square arrays
- Eric Weisstein's World of Mathematics, Ladder Graph
- Eric Weisstein's World of Mathematics, Smarandache Sequences
Crossrefs
Programs
-
Excel
=if(row()>=column();row()-column()+1;"") [Mats Granvik, Jan 19 2009]
-
Haskell
a004736 n k = n - k + 1 a004736_row n = a004736_tabl !! (n-1) a004736_tabl = map reverse a002260_tabl -- Reinhard Zumkeller, Aug 04 2014, Jul 22 2012
-
Maple
A004736 := proc(n,m) n-m+1 ; end: T := (n, k) -> n-k+1: seq(seq(T(n,k), k=1..n), n=1..13); # Johannes W. Meijer, Sep 28 2013
-
Mathematica
Flatten[ Table[ Reverse[ Range[n]], {n, 12}]] (* Robert G. Wilson v, Apr 27 2004 *) Table[Range[n,1,-1],{n,20}]//Flatten (* Harvey P. Dale, May 27 2020 *)
-
PARI
{a(n) = 1 + binomial(1 + floor(1/2 + sqrt(2*n)), 2) - n}
-
PARI
{t1(n) = binomial( floor(3/2 + sqrt(2*n)), 2) - n + 1} /* A004736 */
-
PARI
{t2(n) = n - binomial( floor(1/2 + sqrt(2*n)), 2)} /* A002260 */
-
PARI
apply( A004736(n)=1-n+(n=sqrtint(8*n)\/2)*(n+1)\2, [1..99]) \\ M. F. Hasler, Mar 31 2020
-
Python
def agen(rows): for n in range(1, rows+1): yield from range(n, 0, -1) print([an for an in agen(13)]) # Michael S. Branicky, Aug 17 2021
-
Python
from math import comb, isqrt def A004736(n): return comb((m:=isqrt(k:=n<<1))+(k>m*(m+1))+1,2)+1-n # Chai Wah Wu, Nov 08 2024
Formula
a(n+1) = 1 + A025581(n).
a(n) = (2 - 2*n + round(sqrt(2*n)) + round(sqrt(2*n))^2)/2. - Brian Tenneson, Oct 11 2003
G.f.: 1 / ((1-x)^2 * (1-x*y)). - Ralf Stephan, Jan 23 2005
Recursion: e(n,k) = (e(n - 1, k)*e(n, k - 1) + 1)/e(n - 1, k - 1). - Roger L. Bagula, Mar 25 2009
a(n) = (t*t+3*t+4)/2-n, where t = floor((-1+sqrt(8*n-7))/2). - Boris Putievskiy, Dec 13 2012
From Johannes W. Meijer, Sep 28 2013: (Start)
T(n, k) = n - k + 1, n >= 1 and 1 <= k <= n.
T(n, k) = A002260(n+k-1, n-k+1). (End)
Extensions
New name from Omar E. Pol, Jul 15 2012
Comments