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.

A127948 Triangle, A004736 * A127899.

Original entry on oeis.org

1, 0, 2, -1, 1, 3, -2, 0, 2, 4, -3, -1, 1, 3, 5, -4, -2, 0, 2, 4, 6, -5, -3, -1, 1, 3, 5, 7, -6, -4, -2, 0, 2, 4, 6, 8, -7, -5, -3, -1, 1, 3, 5, 7, 9, -8, -6, -4, -2, 0, 2, 4, 6, 8, 10
Offset: 0

Views

Author

Gary W. Adamson, Feb 09 2007

Keywords

Comments

Row sums = n A127899 * A004736 = A002024

Examples

			First few rows of the triangle are:
1;
0, 2;
-1, 1, 3;
-2, 0, 2, 4;
-3, -1, 1, 3, 5;
-4, -2, 0, 2, 4, 6;
-5, -3, -1, 1, 3, 5, 7;
...
		

Crossrefs

Programs

  • Python
    from math import isqrt
    def A127948(n): return (m:=n<<1)-(isqrt(m<<2)+1>>1)**2 # Chai Wah Wu, Jun 20 2025

Formula

A004736 * A127899 as infinite lower triangular matrices; where A004736 = (1; 2,1; 3,2,1;...).
From Boris Putievskiy, Jan 15 2013: (Start)
a(n) = 2*A000027(n)-A002024(n)^2, n > 0,
a(n) = 2*n-(t+1)^2, where t = floor((-1+sqrt(8*n-7))/2) n > 0. (End)