login
Least prime factor of 2^n + 5^n.
2

%I #37 Oct 01 2020 02:45:17

%S 2,7,29,7,641,7,29,7,17,7,29,7,641,7,29,7,97,7,29,7,641,7,29,7,17,7,

%T 29,7,641,7,29,7,193,7,29,7,73,7,29,7,17,7,29,7,641,7,29,7,97,7,29,7,

%U 641,7,29,7,17,7,29,7,641,7,29,7,274568286337,7,29,7,137,7,29,7,17,7,29,7,457

%N Least prime factor of 2^n + 5^n.

%C a(n_odd)=7, a(n=2+4k,k=0,1,...)=29, a(64)=274568286337 is unusually large.

%H Hans Havermann, <a href="/A122118/b122118.txt">Table of n, a(n) for n = 0..1023</a> (terms 0..319 from Antti Karttunen)

%F a(n) = A020639(A074600(n)). - _Antti Karttunen_, Nov 02 2018

%t Table[FactorInteger[2^n+5^n][[1,1]],{n,0,80}] (* or *) Riffle[Table[ FactorInteger[2^n+5^n][[1,1]],{n,0,80,2}],7] (* The second program is faster *) (* _Harvey P. Dale_, Mar 02 2015 *)

%o (PARI) A122118(n) = { my(k=(2^n+5^n)); forprime(p=if(64==n,274568286337,2),k,if(!(k%p),return(p))); }; \\ _Antti Karttunen_, Nov 02 2018

%Y Cf. A020639, A074600 (2^n + 5^n), A094475 (primes of form 2^n + 5^n), A122119, A337429.

%Y Cf. also A094473.

%K nonn

%O 0,1

%A _Zak Seidov_, Oct 19 2006