Double Factorial Prime

Author

Eric W. Weisstein
July 28, 2016

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

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

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

n!!-1 is Prime

A007749

l={3,4,6,8,16,26,64,82,90,118,194,214,728,842,888,2328,3326,6404,8670,9682,27056,44318,76190,100654,145706};

TextGrid[MapIndexed[{#2[[1]],#,IntegerLength[#!!-1]}&,l],Alignment->Decimal,Dividers->All]

Do[
Print[{i,l[[i]],IntegerLength[l[[i]]!!-1],TimeConstrained[PrimeQ[l[[i]]!!-1],3600]//Timing}],
{i,Length[l]}]

n!+1 is Prime

A080778

l={0,1,2,518,33416,37310,52608,123998};

TextGrid[MapIndexed[{#2[[1]]-1,#,IntegerLength[#!!+1]}&,l],Alignment->Decimal,Dividers->All]

Do[
Print[{i-1,l[[i]],IntegerLength[l[[i]]!!+1],TimeConstrained[PrimeQ[l[[i]]!!+1],3600]//Timing}],
{i,Length[l]}]