OFFSET
1,1
COMMENTS
LINKS
Zak Seidov, Table of n, a(n) for n = 1..1000
Eric Weisstein's World of Mathematics, Almost Prime.
FORMULA
a(n) is equal to the product of 3 primes if the arithmetic mean of prime(n) and prime(n+1) is a semiprime.
EXAMPLE
a(2) = 12 because 12 = 5 + 7 = 3*2^2;
a(3) = 18 because 18 = 7 + 11 = 2*3^2.
MATHEMATICA
Select[Range[8, 10000, 2], 3 == PrimeOmega[#] && NextPrime[#/2] + NextPrime[#/2, -1] == # &] (* Zak Seidov, Jan 31 2017 *)
PROG
(PARI) list(lim)=my(v=List()); forprime(p=2, lim\2, forprime(q=2, min(p, lim\p\2), my(t=2*p*q); if(precprime(p*q)+nextprime(p*q)==t, listput(v, t)))); Set(v) \\ Charles R Greathouse IV, Feb 01 2017
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Giovanni Teofilatto, Apr 27 2005
EXTENSIONS
More terms from Reinhard Zumkeller, May 03 2005
STATUS
approved