OFFSET
0,2
COMMENTS
LINKS
Antti Karttunen, Table of n, a(n) for n = 0..8192
PROG
(Scheme)
(define (A285110 n) (cond ((zero? n) n) ((or (= 1 (A000120 n)) (> (A000040 (+ 1 (A285099 n))) (A000290 (A000040 (+ 1 (A007814 n)))))) 2) (else 1)))
(Python)
from operator import mul
from sympy import prime, primefactors
from functools import reduce
def a001222(n): return 0 if n<2 else a001222(n//min(primefactors(n))) + 1
def a019565(n): return reduce(mul, (prime(i+1) for i, v in enumerate(bin(n)[:1:-1]) if v == '1')) if n > 0 else 1 # This function from Chai Wah Wu
def a007947(n): return 1 if n<2 else reduce(mul, primefactors(n))
def a065642(n):
if n==1: return 1
r=a007947(n)
n += r
while a007947(n)!=r:
n+=r
return n
def a285323(n): return a065642(a065642(a019565(n)))//a019565(n)
def a(n): return a001222(a285323(n))
print([a(n) for n in range(121)]) # Indranil Ghosh, Apr 20 2017
CROSSREFS
KEYWORD
nonn
AUTHOR
Antti Karttunen, Apr 19 2017
STATUS
approved