# Why aren't $P-1,P+1$ primes where $P = p_1p_2…p_n$? [duplicate]

This question already has an answer here:

Euclid's theorem states:

Consider any finite list of prime numbers $$p_1, p_2, ..., p_n$$. It will be shown that at least one additional prime number not in this list exists. Let $$P$$ be the product of all the prime numbers in the list: $$P = p_1p_2...p_n$$. Let $$q = P + 1$$. Then $$q$$ is either prime or not.

If $$q$$ is prime, then there is at least one more prime that is not in the list. If $$q$$ is not prime, then some prime factor $$p$$ divides $$q$$. If this factor $$p$$ were in our list, then it would divide $$P$$ (since $$P$$ is the product of every number in the list); but $$p$$ divides $$P + 1 = q$$. If $$p$$ divides $$P$$ and $$q$$, then $$p$$ would have to divide the difference of the two numbers, which is $$(P + 1) − P$$ or just $$1$$. Since no prime number divides $$1$$, $$p$$ cannot be on the list. This means that at least one more prime number exists beyond those in the list. This proves that for every finite list of prime numbers there is a prime number not in the list, and therefore there must be infinitely many prime numbers.

My question:

Does this theorem also hold if you let $$q = P - 1$$?

Wouldn't $$P-1$$ also be necessarily a new prime number? And if so, it and $$P+1$$ would be a set of twin primes.

So the proof would be:

Assume there are a finite number of twin primes such that $$p_{n+1} - p_n = 2$$.

Then, from the final set of twin primes, choose the larger of these two primes $$p_{n+1}$$. Calculate $$S=p_1p_2...p_{n+1}$$. So you now have a product of all primes up to $$p_{n+1}$$. Call this $$S$$. $$S + 1$$ is a prime number and so is $$S - 1$$. This is a new set of twin primes not in our original list, thus there cannot be a finite list of twin primes.

Of course, if $$S - 1$$ is not prime, then this falls apart.

## marked as duplicate by Bill Dubuque prime-numbers StackExchange.ready(function() { if (StackExchange.options.isMobile) return; $('.dupe-hammer-message-hover:not(.hover-bound)').each(function() { var$hover = $(this).addClass('hover-bound'),$msg = $hover.siblings('.dupe-hammer-message');$hover.hover( function() { $hover.showInfoMessage('', { messageElement:$msg.clone().show(), transient: false, position: { my: 'bottom left', at: 'top center', offsetTop: -7 }, dismissable: false, relativeToBody: true }); }, function() { StackExchange.helpers.removeMessages(); } ); }); }); Mar 26 at 22:29

• There’s absolutely no reason why S+1 or S-1 should be a prime number though, it merely has an unlisted prime factor. – Noe Blassel Mar 16 at 0:59
• By the way, take a look at the edits. It's a courtesy to other contributors to use MathJax to format your posts. If you're not familiar with it, it's not hard to learn -- I've been on this site for less than two months and it has become second nature. – Robert Shore Mar 16 at 1:11
• (2)(3)(5)(7)(11)(13)(17)+1 is divisible by 19. – DanielWainfleet Mar 17 at 8:22

Remember, your original argument doesn't show that $$P+1$$ is itself prime. It shows that $$P+1$$ has a prime factor that you haven't already accounted for. So while you could make the same argument for $$P-1$$, you'd also reach the same conclusion, not that $$P-1$$ is itself necessarily prime, but only that it has some prime factor not in your original list. So that's of no help in proving the Twin Prime Conjecture.

Similarly, you don't know that $$S+1$$ or $$S-1$$ is prime. You just know that they have prime factors that aren't on your original list of twin primes, but that doesn't help you.

• Ah you're right. 2 * 3 * 5 * 7 = 210. But 209 is not prime. – Jeffrey Scott Mar 16 at 1:00
• Glad I could help. Acceptances of answers that you find useful are always welcome. – Robert Shore Mar 16 at 1:51
• in fact you know they are composite, unless the product contains 2, or both 2 and 3. – Roddy MacPhee Mar 17 at 2:23

A few flaws in this method:

• P+1, and P-1 aren't guaranteed to be prime just not divisible by a prime on the supposedly complete list.
• Any product of only primes of forms 6n+1 and/or 6j-1 (aka above 3) will always land in one of these two forms, The best you have is $$S\pm 6$$ could be prime or not in any case like that.
• 2 is required in the product, or both S-1 and S+1 are even.
• Other constraints.