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.

A354522 Square array A(n, k), n, k >= 0, read by antidiagonals; A(n, k) = g(f(n) + f(k)) where f denotes A001057 and g denotes its inverse.

Original entry on oeis.org

0, 1, 1, 2, 3, 2, 3, 0, 0, 3, 4, 5, 4, 5, 4, 5, 2, 1, 1, 2, 5, 6, 7, 6, 7, 6, 7, 6, 7, 4, 3, 0, 0, 3, 4, 7, 8, 9, 8, 9, 8, 9, 8, 9, 8, 9, 6, 5, 2, 1, 1, 2, 5, 6, 9, 10, 11, 10, 11, 10, 11, 10, 11, 10, 11, 10, 11, 8, 7, 4, 3, 0, 0, 3, 4, 7, 8, 11, 12, 13, 12, 13, 12, 13, 12, 13, 12, 13, 12, 13, 12
Offset: 0

Views

Author

Rémy Sigrist, Sep 14 2022

Keywords

Comments

This sequence is directly related to A355278.
The function f is a bijection from the nonnegative integers to the integers (Z).
The nonnegative integers, together with (x,y) -> A(x,y), form an abelian group isomorph to the additive group Z (f and g act as isomorphisms).
As a consequence, each row and each column is a permutation of the nonnegative integers.

Examples

			Array A(n, k) begins:
  n\k |  0   1   2   3   4   5   6   7   8   9  10  11  12
  ----+---------------------------------------------------
    0 |  0   1   2   3   4   5   6   7   8   9  10  11  12
    1 |  1   3   0   5   2   7   4   9   6  11   8  13  10
    2 |  2   0   4   1   6   3   8   5  10   7  12   9  14
    3 |  3   5   1   7   0   9   2  11   4  13   6  15   8
    4 |  4   2   6   0   8   1  10   3  12   5  14   7  16
    5 |  5   7   3   9   1  11   0  13   2  15   4  17   6
    6 |  6   4   8   2  10   0  12   1  14   3  16   5  18
    7 |  7   9   5  11   3  13   1  15   0  17   2  19   4
    8 |  8   6  10   4  12   2  14   0  16   1  18   3  20
    9 |  9  11   7  13   5  15   3  17   1  19   0  21   2
   10 | 10   8  12   6  14   4  16   2  18   0  20   1  22
   11 | 11  13   9  15   7  17   5  19   3  21   1  23   0
   12 | 12  10  14   8  16   6  18   4  20   2  22   0  24
		

Crossrefs

Programs

  • PARI
    f(n) = - (-1)^n * ((n+1)\2)
    g(n) = if (n<=0, -2*n, 2*n-1)
    A(n, k) = g(f(n) + f(k))

Formula

A355278(n+1, k+1) = prime(1 + A(n, k)) (where prime(m) denotes the m-th prime number).
A(n, k) = A(k, n).
A(n, 0) = n.
A(n, A014681(n)) = 0.
A(m, A(n, k)) = A(A(m, n), k).
A(n, n) = A014601(n).
A(n, A(n, n)) = A047264(n+1).
A(A(n, n), A(n, n)) = A047521(n+1).