OFFSET
1,1
LINKS
Chai Wah Wu, Table of n, a(n) for n = 1..10000
FORMULA
EXAMPLE
a(1) = a(01_2) = 2^1 * 3^0 + 1 = 3;
a(2) = a(10_2) = 2^0 * 3^1 + 1 = 2^2 = 2;
a(3) = a(11_2) = 2^1 * 3^1 + 1 = 7.
PROG
(PARI) a(n) = {my(b = binary(n), x = 1 + prod(k=1, #b, prime(#b-k+1)^b[k])); factor(x)[1, 1]; } \\ Michel Marcus, Jun 02 2019
(Python)
from functools import reduce
from operator import mul
from sympy import prime, primefactors
def A308439(n):
return min(primefactors(1 + reduce(mul, (prime(i+1) for i, j in enumerate(bin(n)[:1:-1]) if j == '1')))) # Chai Wah Wu, Jun 03 2019
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Brendan Hickey, May 27 2019
STATUS
approved