login
Four consecutive nonprime odd numbers {n-1,n+1,n+3,n+5}.
0

%I #11 Sep 21 2016 18:11:56

%S 115,117,119,121,117,119,121,123,119,121,123,125,141,143,145,147,183,

%T 185,187,189,201,203,205,207,203,205,207,209,213,215,217,219,215,217,

%U 219,221,243,245,247,249,285,287,289,291,295,297,299,301,297,299,301

%N Four consecutive nonprime odd numbers {n-1,n+1,n+3,n+5}.

%C These quartets seem to correspond to larger Prime gaps: the larger the primes gaps the more runs of odd nonprimes.

%F a(n) = {n-1,n+1,n+3,n+5} for both odd and both nonprime.

%t Flatten[Table[If[OddQ[n - 1] && PrimeQ[n - 1] == False && PrimeQ[n + 1] == False && PrimeQ[n + 3] == False && PrimeQ[n + 5] == False, {{n - 1}, {n + 1}, {n + 3}, (n + 5)}, {}], {n, 2, 300}]]

%t Select[Partition[Range[1,311,2],4,1],NoneTrue[#,PrimeQ]&]//Flatten (* Requires Mathematica version 10 or later *) (* _Harvey P. Dale_, Sep 21 2016 *)

%K nonn,uned

%O 1,1

%A _Roger L. Bagula_, May 20 2007