login
A255560
One-based row index of n in array A255555.
7
1, 2, 1, 2, 3, 4, 1, 2, 5, 3, 4, 6, 7, 8, 1, 2, 9, 5, 3, 10, 11, 4, 6, 12, 7, 8, 13, 14, 15, 16, 1, 2, 17, 9, 5, 18, 19, 3, 10, 20, 11, 4, 21, 22, 23, 6, 12, 24, 7, 8, 25, 26, 13, 14, 27, 15, 16, 28, 29, 30, 31, 32, 1, 2, 33, 17, 9, 34, 35, 5, 18, 36, 19, 3, 37, 38, 39, 10, 20, 40, 11, 4, 41, 42, 21, 22, 43, 23, 6
OFFSET
1,2
COMMENTS
Equally: One-based column index of n in array A255557.
LINKS
FORMULA
a(1) = 1; for n > 1, if A213714(n) = 0 [i.e., if n is one of the terms of A055938], then a(n) = 1+A234017(n), otherwise a(n) = a(A213714(n)-1).
In other words, a(1) = 1, and for n > 1, if n = A055938(k) for some k, then a(n) = k+1, otherwise it must be that n = A005187(h) for some h, in which case a(n) = a(h-1).
PROG
(Scheme, with memoization-macro definec)
(definec (A255560 n) (cond ((= 1 n) n) ((zero? (A213714 n)) (+ 1 (A234017 n))) (else (A255560 (+ -1 (A213714 n))))))
CROSSREFS
Cf. also A255559 (corresponding column index).
Sequence in context: A233972 A169778 A309776 * A328472 A046653 A308897
KEYWORD
nonn
AUTHOR
Antti Karttunen, Apr 14 2015
STATUS
approved