login
A278512
Inverse permutation to A278511.
4
1, 2, 4, 3, 6, 5, 7, 8, 10, 12, 9, 17, 11, 23, 15, 30, 13, 38, 16, 47, 14, 57, 18, 68, 21, 80, 22, 93, 24, 107, 28, 122, 19, 138, 31, 155, 20, 173, 29, 192, 39, 212, 36, 233, 25, 255, 48, 278, 37, 302, 27, 327, 58, 353, 26, 380, 32, 408, 69, 437, 45, 467, 46, 498, 81, 530, 55, 563, 40, 597, 94, 632, 35, 668, 33
OFFSET
1,2
FORMULA
a(n) = (1/2) * ((c+r)^2 - r - 3*c + 2), where c = A278537(n) and r = A278538(n).
PROG
(define (A278512 n) (if (= 1 n) n (let ((row (A278538 n)) (col (A278537 n))) (+ 1 (* (/ 1 2) (- (expt (+ row col) 2) row col col col -2))))))
CROSSREFS
Inverse: A278511.
Cf. also A278504, A278506.
Sequence in context: A161920 A366943 A366945 * A278511 A255552 A255551
KEYWORD
nonn
AUTHOR
Antti Karttunen, Nov 23 2016
STATUS
approved