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.

A192763 Symmetric square array read by antidiagonals up.

Original entry on oeis.org

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

Views

Author

Mats Granvik, Jul 09 2011

Keywords

Comments

The main diagonal is the Mobius function times the natural numbers A055615 (conjecture). For k>1 the first row is the Mertens function + 2 = A002321 + 2 (conjecture). There is one recurrence for n=1 and k=1, and another recurrence for n>1 and k>1.

Examples

			The array starts:
1..2..1..1..0..1..0..0..0..1...
2.-2..2.-2..2.-2..2.-2..2.-2...
1..2.-3..1..2.-3..1..2.-3..1...
1.-2..1..0..1.-2..1..0..1.-2...
0..2..2..1.-5..0..2..2..1.-5...
1.-2.-3.-2..0..6..1.-2.-3.-2...
0..2..1..1..2..1.-7..0..2..1...
0.-2..2..0..2.-2..0..0..0.-2...
0..2.-3..1..1.-3..2..0..0..0...
1.-2..1.-2.-5.-2..1.-2..0..10...
		

Crossrefs

Programs

  • Mathematica
    Clear[t]; t[1, 1] = 1; t[2, 1] = t[1, 2] = 2; t[n_Integer, k_Integer] := t[n, k] = Which[n == 1, (-t[n, k - 1] - Sum[t[i, k], {i, 2, k - 1}])/(k + 1) +  t[n, k - 1], k == 1, (-t[n - 1, k] - Sum[t[n, i], {i, 2, n - 1}])/(n + 1) + t[n - 1, k], n >= k, -Sum[t[n - i, k], {i, 1, k - 1}], True, -Sum[t[k - i, n], {i, 1, n - 1}]];
    nn = 12;
    MatrixForm[Array[t, {nn, nn}]];
    a = Flatten[Table[Reverse[Range[n]], {n, nn}]];
    b = Flatten[Table[Range[n], {n, nn}]];
    Table[t[a[[i]], b[[i]]], {i, 1, nn*(nn + 1)/2}]
    (* Mats Granvik, Olivier Gérard, Jul 10 2011 *)
    T[ n_, k_] := If[ n < 1 || k < 1, 0, If[ k > n, T[ k, n], T[n, k] = If[ k == 1, If[ n < 3, n, (-T[ n - 1, 1] - Sum[ T[ n, i], {i, 2, n - 1}]) / (n + 1) + T[ n - 1, 1]], If[ n > k, T[ k, Mod[ n, k, 1]], - Sum[ T[ n, i], {i, n - 1}]]]]]; (* Michael Somos, Jul 19 2011 *)
  • PARI
    {T(n, k) = if( n<1 || k<1, 0, if( k>n, T(k, n), if( k==1, if( n<3, n, (-T(n-1, 1) -sum( i=2, n-1, T(n, i))) / (n+1) + T(n-1, 1)), if( n>k, T(k, (n-1)%k+1), -sum( i=1,n-1, T(n, i))))))}; /* Michael Somos, Jul 19 2011 */

Formula

T(1,1)=1 or 3, T(1,2)=2, T(2,1)=2, T(1,k)=(-T(n,k-1)-Sum_(i=2)^(k-1) of T(i,k))/(k+1)+T(n,k-1), T(n,1)=(-T(n-1,k)-Sum_(i=2)^(n-1) of T(n,i))/(n+1)+T(n-1,k), n>=k: -Sum_(i=1)^(k-1) of T(n-i,k), n