Let a tough-to-test composite be a positive integer that is composite, but not divisible by 2, nor 3, nor 5.
Given that there are 168 prime numbers between 1 and 1000, how many tough-to-test composite numbers are there between 1 and 1000?
Notes : 1 is neither prime nor composite. There are some tough-to-test composite numbers that many would recognize as composite. For example, 49 and 77.
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
Let M 2 , M 3 , and M 5 be the sets of integer multiples of 2 , 3 , and 5 , respectively, between 1 and 1 0 0 0 , inclusive.
∣ M 2 ∣ = 5 0 0
∣ M 3 ∣ = 3 3 3
∣ M 5 ∣ = 2 0 0
∣ M 2 ∩ M 3 ∣ = 1 6 6
∣ M 2 ∩ M 5 ∣ = 1 0 0
∣ M 3 ∩ M 5 ∣ = 6 6
∣ M 2 ∩ M 3 ∩ M 5 ∣ = 3 3
By PIE ,
∣ M 2 ∪ M 3 ∪ M 5 ∣ = ∣ M 2 ∣ + ∣ M 3 ∣ + ∣ M 5 ∣ − ∣ M 2 ∩ M 3 ∣ − ∣ M 2 ∩ M 5 ∣ − ∣ M 3 ∩ M 5 ∣ + ∣ M 2 ∩ M 3 ∩ M 5 ∣ = 5 0 0 + 3 3 3 + 2 0 0 − 1 6 6 − 1 0 0 − 6 6 + 3 3 = 7 3 4
By De Morgan's Laws , the number of integers between 2 and 1 0 0 0 inclusive that are not multiples of 2 , nor 3 , nor 5 is 9 9 9 − 7 3 4 = 2 6 5 ( 1 is excluded because it is neither prime nor composite).
It is given that there are 1 6 8 prime numbers between 1 and 1 0 0 0 inclusive. Excluding 2 , 3 , and 5 , there are 1 6 5 prime numbers. Therefore, the number of tough-to-test composite numbers is: 2 6 5 − 1 6 5 = 1 0 0 .