login
Least semiprime of a run of exactly n with alternating parity.
2

%I #12 May 12 2024 10:03:29

%S 4,14,6,622,93,1211,69,15746,1273,844147,21,3786374,1357511,37008721,

%T 20028781,201010021,91186105,6969801571,224163661,518479039339,

%U 15633784177,8191197319811,83460915203,669094978066,691286884697

%N Least semiprime of a run of exactly n with alternating parity.

%C Runs of semiprimes of alternating parity: {4}, {6, 9, 10}, {14, 15}, {21, 22, 25, 26, 33, 34, 35, 38, 39, 46, 49}, {51}, {55}, {57, 58}, {62, 65}, {69, 74, 77, 82, 85, 86, 87}, {91}, {93, 94, 95, 106, 111}, ...

%e a(1) = 4 since it is the first occurrence of a semiprime that is not part of a run of two or more semiprimes;

%e a(2) = 14 since it is the first of a run of exactly two consecutive semiprimes of alternating parity;

%e a(3) = 6 since 6 is the first of a run of exactly three consecutive semiprimes of alternating parity; etc.

%t Table[ SelectFirst[ Split[ Select[ Range@ 10000000, PrimeOmega@# == 2 &], Mod[#1, 2] != Mod[#2, 2] &], Length@# == n &][[1]], {n, 13}]

%Y Cf. A001358, A304456, A304457.

%K more,nonn

%O 1,1

%A _Zak Seidov_, _Silvester Resnik_ and _Robert G. Wilson v_, May 12 2018