OFFSET
1,4
LINKS
Antti Karttunen, Table of n, a(n) for n = 1..10080
FORMULA
PROG
(Scheme, with memoization-macro definec)
(Python)
from sympy import factorial as f
def a007623(n, p=2): return n if n<p else a007623(n//p, p+1)*10 + n%p
def a225901(n):
s=0
k=2
while n:
d=n%k
n=n//k
if d: s=s+(k - d)*f(k - 1)
k+=1
return s
def a257680(n): return 1 if '1' in str(a007623(n)) else 0
def a(n): return 0 if n==1 else a257680(a225901(n)) + a(n - 1)
l=[0, 0]
for n in range(2, 101): l.append(a257680(a225901(n)) + l[n - 1])
print(l[1:]) # Indranil Ghosh, Jun 24 2017
CROSSREFS
KEYWORD
nonn
AUTHOR
Antti Karttunen, May 30 2016
STATUS
approved