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”).

Primes of the form 4^k mod 3^k.
0

%I #22 May 19 2019 06:37:54

%S 7,13,119923,146050183,4039362385345521139,

%T 289247481259011497824466400997481269,

%U 1765256712749403700417549596608786383,395766070055468241613007225643003404495980782673,2596786183076854435238229837938226284218037897451862682304077097493117

%N Primes of the form 4^k mod 3^k.

%F { A000040 } intersect { A064629 }.

%p select(isprime, [4&^n mod 3^n$n=1..200])[]; # _Alois P. Heinz_, May 18 2019

%t Select[Table[PowerMod[4, n, 3^n], {n, 100}], PrimeQ] (* _Alonso del Arte_, Jan 03 2011 *)

%o (PARI) terms(n) = my(i=0); for(k=0, oo, if(i>=n, break); my(x=lift(Mod(4, 3^k)^k)); if(ispseudoprime(x), print1(x, ", "); i++))

%o /* Print initial 7 terms as follows: */

%o terms(7) \\ _Felix Fröhlich_, May 18 2019

%Y Cf. A000040, A000079, A000244, A064629, A178985.

%K nonn

%O 1,1

%A _Juri-Stepan Gerasimov_, Jan 03 2011