OFFSET
0,1
LINKS
David A. Corneth, Table of n, a(n) for n = 0..3321
MATHEMATICA
pwQ[n_] := n == 1 || GCD @@ (Last /@ FactorInteger@n) > 1; a[n_] := Block[{t = 2^n + 1}, While[! pwQ@t, t++]; t]; a /@ Range[0, 30] (* Giovanni Resta, Oct 12 2022 *)
PROG
(PARI) for (n=0, 35, for (k=2^n+1, oo, if(ispower(k), print1(k, ", "); break)))
(PARI) a(n) = { if(n < 2, return(4)); my(p2 = 1<<n, res = 1 << (n+1), c); forprime(i = 2, n + 1, c = (sqrtnint(p2, i)+1)^i; res = min(res, c); ); res } \\ David A. Corneth, Oct 12 2022
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Hugo Pfoertner, Oct 12 2022
STATUS
approved