OFFSET
0,4
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.
FORMULA
EXAMPLE
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
PROG
(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))
CROSSREFS
KEYWORD
nonn,tabl
AUTHOR
Rémy Sigrist, Sep 14 2022
STATUS
approved