%I #21 Feb 22 2023 02:32:20
%S 161038,215326,209665666,4783964626,1656670046626,1202870727916606,
%T 52034993731418446,1944276680165220226,1877970990972707747326,
%U 1959543009026971258888306,102066199849378101848830606
%N Smallest base-2 even pseudoprime (A006935) with exactly n prime factors, or 0 if no such number exists.
%C From _Daniel Suteu_, Feb 21 2023: (Start)
%C a(14) <= 830980424310040957294391274226,
%C a(15) <= 108084747660126676387861365978526,
%C a(16) <= 37216678196711615864826518577193726,
%C a(17) <= 14165393571115472875428298421578481266,
%C a(18) <= 29754760201190206689697709808980720234206,
%C a(19) <= 83297267513662079869290363590704788631466446. (End)
%e a(5) = 209665666 because 209665666 belongs to A006935 (is an even pseudoprime) and Omega(209665666) = 5 (Omega(n) is the count of divisors of n with multiplicity), and 209665666 is minimal with these properties.
%o (PARI) a(n)=my(k=prod(i=1,n,prime(i))); while(Mod(2, k)^k!=2 || bigomega(k)!=n, k += 2); k \\ _Charles R Greathouse IV_, Mar 27 2016
%o (PARI)
%o even_fermat_psp(A, B, k, base) = A=max(A, vecprod(primes(k))); (f(m, l, p, j) = my(list=List()); forprime(q=p, sqrtnint(B\m, j), if(base%q == 0, next); my(v=m*q, t=q); while(v <= B, my(L=lcm(l, znorder(Mod(base, t)))); if(gcd(L, v) != 1, break); if(j==1, if(v>=A && if(k==1, !isprime(v), 1) && (v-1)%L == 0, listput(list, v)), list=concat(list, f(v, L, q+1, j-1))); v *= q; t *= q)); list); vecsort(Vec(f(2, 1, 3, k-1)));
%o a(n) = if(n < 3, return()); my(x=vecprod(primes(n)), y=3*x); while(1, my(v=even_fermat_psp(x, y, n, 2)); if(#v >= 1, return(v[1])); x=y+1; y=3*x); \\ _Daniel Suteu_, Feb 20 2023
%Y Cf. A006935, A001222.
%K nonn,more
%O 3,1
%A _Jeppe Stig Nielsen_, Mar 27 2016
%E Escape clause added by _Jianing Song_, Dec 12 2021
%E a(9)-a(13) from _Daniel Suteu_, Feb 20 2023