OFFSET
1,5
LINKS
FORMULA
If n = k, then A(n,k) = n, otherwise 0.
EXAMPLE
The top left 9 X 9 corner of the array:
1, 0, 0, 0, 0, 0, 0, 0, 0
0, 2, 0, 0, 0, 0, 0, 0, 0
0, 0, 3, 0, 0, 0, 0, 0, 0
0, 0, 0, 4, 0, 0, 0, 0, 0
0, 0, 0, 0, 5, 0, 0, 0, 0
0, 0, 0, 0, 0, 6, 0, 0, 0
0, 0, 0, 0, 0, 0, 7, 0, 0
0, 0, 0, 0, 0, 0, 0, 8, 0
0, 0, 0, 0, 0, 0, 0, 0, 9
MATHEMATICA
Table[Function[s, If[OddQ@ Length@ s, ReplacePart[s, {# -> #}] &[Ceiling[n/2]], s]]@ ConstantArray[0, n], {n, 15}] // Flatten (* Michael De Vlieger, May 04 2017 *)
PROG
(Scheme)
(define (A286100bi row col) (if (= row col) row 0))
(Python)
def A(n, k): return n if n==k else 0
for n in range(1, 21): print [A(k, n - k + 1) for k in range(1, n + 1)] # Indranil Ghosh, May 03 2017
CROSSREFS
KEYWORD
nonn,tabl
AUTHOR
Antti Karttunen, May 03 2017
STATUS
approved