Twin Composites

Author

Eric W. Weisstein
December 28, 2020

This notebook downloaded from http://mathworld.wolfram.com/notebooks/PrimeNumbers/TwinComposites.nb.

For more information, see Eric's MathWorld entry http://mathworld.wolfram.com/TwinComposites.html.

©2020 Wolfram Research, Inc. except for portions noted otherwise

Enumerate

All

Middle number prime or composite

Select[Range[1,100],PrimeQ[#]===False&&PrimeQ[#+2]===False&]

Middle number must be prime

Select[Range[1,100],PrimeQ[#]===False&&PrimeQ[#+1]===True&&PrimeQ[#+2]===False&]

Odd

Middle number prime or composite

A269345

Select[Range[1,200,2],PrimeQ[#]===False&&PrimeQ[#+2]===False&]

A025583

Select[Range[3,200,2],PrimeQ[#]===False&&PrimeQ[#-2]===False&]

Pairs:

{#,#+2}&/@Select[Range[1,100,2],PrimeQ[#]===False&&PrimeQ[#+2]===False&]

Bisection:

A061673

Select[Range[2,200,2],PrimeQ[#-1]===False&&PrimeQ[#+1]===False&]

Middle number must be even and so cannot be prime

Select[Range[1,200,2],PrimeQ[#]===False&&PrimeQ[#+1]===True&&PrimeQ[#+2]===False&]

Select[Range[3,200,2],PrimeQ[#]===False&&PrimeQ[#+1]===True&&PrimeQ[#-2]===False&]

Select[Range[2,200,2],PrimeQ[#-1]===False&&PrimeQ[#]===True&&PrimeQ[#+1]===False&]