cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A056559 Tetrahedron with T(t,n,k) = t - n; succession of growing finite triangles with declining values per row.

Original entry on oeis.org

0, 1, 0, 0, 2, 1, 1, 0, 0, 0, 3, 2, 2, 1, 1, 1, 0, 0, 0, 0, 4, 3, 3, 2, 2, 2, 1, 1, 1, 1, 0, 0, 0, 0, 0, 5, 4, 4, 3, 3, 3, 2, 2, 2, 2, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 6, 5, 5, 4, 4, 4, 3, 3, 3, 3, 2, 2, 2, 2, 2, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 7, 6, 6, 5, 5, 5, 4, 4, 4, 4, 3, 3, 3, 3, 3, 2, 2, 2, 2, 2, 2
Offset: 0

Views

Author

Henry Bottomley, Jun 26 2000

Keywords

Examples

			First triangle: [0]; second triangle: [1; 0 0]; third triangle: [2; 1 1; 0 0 0]; ...
		

Crossrefs

Together with A056558 and A056560 might enable reading "by antidiagonals" of cube arrays as 3-dimensional analog of A002262 and A025581 with square arrays.
Bisection (y-coordinates) of A332662.

Programs

  • Julia
    function a_list(N)
        a = Int[]
        for n in 1:N
            for j in ((k:-1:1) for k in 1:n)
                t = n - j[1]
                for m in j
                    push!(a, t)
    end end end; a end
    A = a_list(10) # Peter Luschny, Feb 19 2020
    
  • Python
    from math import isqrt, comb
    from sympy import integer_nthroot
    def A056559(n): return (m:=integer_nthroot(6*(n+1),3)[0])-(a:=nChai Wah Wu, Dec 11 2024

Formula

a(n) = A056556(n) - A056557(n).