login
Numbers n such that 2*n*3^n + 1 is prime.
1

%I #35 Sep 08 2022 08:46:15

%S 1,2,3,14,19,21,27,33,46,70,80,441,540,567,625,1057,1119,1213,1542,

%T 4263,4419,4507,5186,7345,8626,8853,11256,12885,14688,15236,17697,

%U 26770,57801,71665

%N Numbers n such that 2*n*3^n + 1 is prime.

%C Primes: 2, 3, 19, 1213, 4507, ...

%C No further terms < 10^5. - _Ray Chandler_, Apr 13 2016

%e 1 is in this sequence because 2*1*3^1 + 1 = 7 is prime.

%t Select[Range[1600], PrimeQ[2 # 3^# + 1] &] (* _Vincenzo Librandi_, Jan 03 2016 *)

%o (Magma) [n: n in [1..2000]| IsPrime(2*n*3^n+1)]; // _Vincenzo Librandi_, Jan 03 2016

%o (PARI) is(n)=ispseudoprime(2*n*3^n+1) \\ _Charles R Greathouse IV_, Feb 08 2016

%Y Cf. A006552.

%K nonn,more

%O 1,2

%A _Juri-Stepan Gerasimov_, Jan 02 2016

%E a(24) and a(26) inserted by _Charles R Greathouse IV_, Feb 08 2016

%E a(28)-a(30) from _Charles R Greathouse IV_, Feb 08 2016

%E a(31)-a(32) from _Ray Chandler_, Apr 05 2016

%E a(33) from _Ray Chandler_, Apr 08 2016

%E a(34) from _Ray Chandler_, Apr 09 2016