login
A277903
a(n) = the least k such that A000123(k) >= n.
4
0, 1, 2, 2, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12
OFFSET
1,3
COMMENTS
Greatest monotonic left inverse of A000123.
Each n occurs A018819(n) times.
LINKS
FORMULA
a(n) = A048675(A277905(n)).
a(A000123(n)) = n.
PROG
(Scheme)
(definec (A277903 n) (let loop ((k 0)) (if (>= (A000123 k) n) k (loop (+ 1 k)))))
(define (A000123 n) (A018819 (+ n n)))
(definec (A018819 n) (cond ((zero? n) 1) ((even? n) (+ (A018819 (- n 1)) (A018819 (/ n 2)))) (else (A018819 (- n 1)))))
CROSSREFS
KEYWORD
nonn
AUTHOR
Antti Karttunen, Nov 14 2016
STATUS
approved