Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
A266116
The last nonzero term on each row of A265751.
4
7, 7, 13, 7, 8, 7, 13, 7, 8, 13, 20, 13, 25, 13, 20, 19, 24, 19, 25, 19, 20, 37, 25, 37, 24, 25, 40, 37, 28, 37, 50, 37, 40, 33, 50, 37, 36, 37, 50, 43, 40, 43, 49, 43, 50, 67, 49, 67, 56, 49, 50, 67, 52, 67, 68, 55, 56, 67, 68, 67, 136, 67, 68, 63, 64, 67, 66, 67, 68, 79, 74, 79, 136, 79, 74, 75, 103, 79, 98, 79, 88, 103, 98, 103, 136, 85
OFFSET
0,1
COMMENTS
Starting from j = n, search for a smallest number k such that k - d(k) = j, and if found such a number, replace j with k and repeat the procedure. When eventually such k is no longer found, then the (last such) j must be one of the terms of A045765, and it is set as the value of a(n).
LINKS
FORMULA
a(n) = A265751(n, A266110(n)).
If A060990(n) = 0, a(n) = n, otherwise a(n) = a(A082284(n)), where A082284(n) = smallest number k such that k - d(k) = n, or 0 if no such number exists, and d(n) = the number of divisors of n (A000005).
Other identities and observations. For all n >= 0:
a(n) >= n.
A060990(a(n)) = 0. [All terms are in A045765.]
EXAMPLE
Starting from n = 21, we get the following chain: 21 -> 23 -> 27 -> 29 -> 31 -> 35 -> 37, with A082284 iterated 6 times before the final term 37 (for which A060990(37) = A082284(37) = 0) is encountered. Thus a(21) = 37.
PROG
(Scheme)
(definec (A266116 n) (cond ((A082284 n) => (lambda (lad) (if (zero? lad) n (A266116 lad))))))
;; Alternatively:
(define (A266116 n) (A265751bi n (A266110 n))) ;; Code for A265751bi given in A265751.
CROSSREFS
Cf. A266110 (gives the number of iterations of A082284 needed before a(n) is found).
Cf. also tree A263267 (and its illustration).
Sequence in context: A152672 A003883 A212535 * A344329 A116934 A143429
KEYWORD
nonn
AUTHOR
Antti Karttunen, Dec 21 2015
STATUS
approved