Belphegor Prime

Author

Eric W. Weisstein
January 24, 2017

This notebook downloaded from http://mathworld.wolfram.com/notebooks/PrimeNumbers/BelphegorPrime.nb.

For more information, see Eric's MathWorld entry http://mathworld.wolfram.com/BelphegorPrime.html.

©2017 Wolfram Research, Inc. except for portions noted otherwise

Compute

Belphegor[n_]:=(10^(2n+4))+666 (10^(n+1))+1

A232448

$Version

t=AbsoluteTime[];
Monitor[Do[If[PrimeQ[Belphegor[n]],Print[{AbsoluteTime[]-t,n}]],{n,0,3*^3}],n]//AbsoluteTiming

Check

p={0,13,42,506,608,2472,2623,28291,181298};

Grid[{#,IntegerLength[Belphegor[#]]}&/@p,Dividers->All,Alignment->Decimal]

i=0;
Do[Print[{i-1,p[[i]],PrimeQ[b=Belphegor[p[[i]]]]//Timing,IntegerLength[b]}],{i,Length[p]}]