A379407 a(n) is the smallest semiprime > primorial(n).
4, 9, 33, 213, 2315, 30031, 510515, 9699691, 223092871, 6469693233, 200560490134, 7420738134814, 304250263527221, 13082761331670031, 614889782588491414, 32589158477190044737, 1922760350154212639074, 117288381359406970983271, 7858321551080267055879091
Offset: 1
Keywords
Examples
primorial(2) = 2*3 = 6 so a(2) = 9 because 9 = 3*3 is next semiprime > 6.
Programs
-
Mathematica
a[n_] := Module[{m = Times @@ Prime[Range[n]] + 1}, While[PrimeOmega[m] != 2, m++]; m]; Array[a, 20] (* Amiram Eldar, Jan 01 2025 *)
-
Python
import sympy def ok(n): return sum(sympy.factorint(n).values()) == 2 primorial = 1 l = [] for i in range(1,20): primorial *= sympy.prime(i) next_sp = primorial + 1 while not(ok(next_sp)): next_sp += 1 l.append(next_sp) print(l)