%I #15 Nov 09 2024 17:28:28
%S 2,1,1,2,1,6,8,11,4,16,22,4,74,24,37,28,14,11,242,11,91,20,83,91,35,
%T 80,48,47,226,2,12,203,30,38,356,54,266,108,305,227,173,1185,738,13,
%U 382,277,455,433,173,1303,926,1162,164,298,69,121,702,1670,36,570,170,204
%N Smallest multiple a(n) of n-th primorial q(n) such that a(n)*q(n)-1 and a(n)*q(n)+1 are a pair of twin primes.
%H Pierre CAMI, <a href="/A060256/b060256.txt">Table of n, a(n) for n = 1..500</a>
%e 30030*j-1 or 30030*j+1 are not both primes for j=1,2,3,4,5. But for j=6 {180179,180181} are twin primes. So a(6)=6.
%t smp[n_]:=Module[{k=1},While[!PrimeQ[k*n+1]||!PrimeQ[k*n-1],k++];k]; Table[ smp[n],{n,FoldList[Times,Prime[Range[70]]]}] (* _Harvey P. Dale_, Oct 27 2016 *)
%o (PARI) a(n)=p=vecprod(primes(n));for(k=1,+oo,ispseudoprime(k*p+1)&&ispseudoprime(k*p-1)&&return(k)) \\ _Jeppe Stig Nielsen_, Nov 09 2024
%Y Cf. A001359, A002110, A060229-A060232, A060255, A057706.
%K nonn,changed
%O 1,1
%A _Labos Elemer_, Mar 22 2001
%E Corrected and extended by _Ray Chandler_, Apr 03 2009