login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Least positive integer such that 2^m+3^n or 2^n+3^m is prime.
1

%I #6 Apr 06 2014 08:04:50

%S 1,1,1,1,1,2,1,1,1,2,1,4,1,3,1,1,1,6,1,4,3,8,2,2,1,7,1,4,1,10,1,4,4,8,

%T 15,6,1,2,3,8,3,3,2,6,3,11,6,2,5,4,18,4,12,6,26,1,4,2,9,6,4,10,18,1,4,

%U 6,2,1,8,10,26,12,17,12,10,4,13,3,7,9,11,4,2,17,1,7,3,2,3,26,22,6,12,8,9

%N Least positive integer such that 2^m+3^n or 2^n+3^m is prime.

%C It seems that a(n)<=n for all n>0.

%F a(n) = min { A123359(n), A159266(n) }

%e a(0)=1 since 2^1+3^0=3 is prime.

%e a(1)=1 since 2^1+3^1=5 is prime.

%e a(2)=1 since 2^2+3^1=7, or 2^1+3^2=11, is prime. (Only one prime is required).

%e a(3)=1 since 2^3+3^1=11 and also 2^1+3^3=29, are prime.

%e a(4)=1 since 2^4+3^1=19 (and also 2^1+3^4=83) are prime.

%e a(5)=2 is the least integer m such that 2^5+3^m (=41) is prime and 2^m+3^5 is not prime until A159267(5)=4.

%o (PARI) A159269(n,m=0)=until( is/*pseudo*/prime(2^n+3^m++) || is/*pseudo*/prime(3^n+2^m),);m

%K nonn

%O 0,6

%A _M. F. Hasler_, Apr 08 2009