# How to generate a list of primes using the fundamental theorem of arithmetic

I've been told it's possible to generate a list of primes using the fundamental theorem of arithmetic, will someone show me how?

-
Do you know about the Sieve of Erasthotenes? –  Pedro Tamaroff Jul 1 '12 at 0:52
I am aware of prime sieves. –  Leila Jul 1 '12 at 1:20

I'm at a loss to understand the question, but maybe if I post this answer it will help OP to refine the question.

Add 1, you get 3 --- that's a prime.

Multiply the primes you have so far, and add 1. By the Fundamental Theorem of Arithmetic, the new number will have a prime factor, and it can't be any of the primes you already have, so it must be a new one.

So: $2\times3+1=7$ --- that's a prime.

$2\times3\times7+1=43$ --- that's a prime.

$2\times3\times7\times43+1$ isn't a prime, but it has the new prime factor 13 (and also 139, but let's just take the smaller one).

So far, we have the list, $$2, 3, 7, 43, 13,\dots$$ so we have generated a list of primes using the Fundamental Theorem of Arithmetic. For the next few terms, see this entry at the Online Encyclopedia of Integer Sequences.

If that's not the kind of thing you had in mind, then please clarify.

-