# Natural Numbers contain all the Primes

• B
• PrimeExample
In summary, the conversation discusses the concept of prime numbers and their relationship to natural numbers. The conversation also introduces the concept of a prime line, which starts at p1, 2 and continues on the natural number line. It is mentioned that some definitions of natural numbers do not include zero, but the conversation focuses on the inclusion of zero in the natural number line.

#### PrimeExample

TL;DR Summary
So we know that all primes are encompassed in natural numbers, right?

But how do we show that?
w = {0,0 | 1,1 | 2,2...}

Let x = number of primes up to w+1
Let y = number of primes up to w-1

Now there's an empty prime box in the 0,0 slot not connected to anything.

So I let x = p-1 and y = p+1

p = [p0, p1, p2...]

Now p0 becomes 1,0/1

It can be either on or off.

For the sake of argument we'll turn it on.

Let x = prime numbers up to W
Let y = prime numbers up to W+1 counting 0 & 1

x = p+1
W = 0, x = 1, y = 2
W = 1, x = 2, y = 3
W = 2, x = 3, y = 4
W = 3, x = 4, y = 5
W = 4, x = 4, y = 5
W = 5, x = 5, y = 6
W = 6, x = 5, y = 6
W = 7, x = 6, y = 5
W = 8, x = 6, y = 5
W = 9, x = 6, y = 5
W = 10, x= 6, y = 5
W = 11, x = 7, y = 6
W = 12, x = 7, y = 6
W = 13, x = 8, y = 7
w = 14, x = 8, y = 7
w = 15, x = 8, y = 7
w = 16, x = 8, y = 7
w = 17, x = 9, y = 8
w = 18, x = 9, y = 8
w = 19, x = 8, y = 8
w = 20, x = 8, y = 8
w = 21, x = 8, y = 8
w = 22, x = 8, y = 9
w = 23, x = 9, y = 9
w = 24, x = 9, y = 9
w = 25, x = 9, y = 9
w = 26, x = 9, y = 9
w = 27, x = 9, y = 9
w = 28, x = 9, y = 10
w = 29, x = 10, y = 10

y = p-1
W = 0, x = 1, y = ? 1 or a 0 if you say 0 its 0/1 so i say 1 to close the loop
W = 1, x = 2, y = 1
W = 2, x = 3, y = 2
W = 3, x = 4, y = 3
W = 4, x = 4, y = 4
W = 5, x = 5, y = 4
W = 6, x = 5, y = 5
W = 7, x = 6, y = 5
W = 8, x = 6, y = 6
W = 9, x = 6, y = 6
W = 10, x= 6, y = 6
W = 11, x = 7, y = 6
W = 12, x = 7, y = 7
W = 13, x = 8, y = 7
w = 14, x = 8, y = 8
w = 15, x = 8, y = 8
w = 16, x = 8, y = 8
w = 17, x = 9, y = 8
w = 18, x = 9, y = 9
w = 19, x = 10, y = 9
w = 20, x = 10, y = 10
w = 21, x = 10,, y = 10
w = 22, x = 10, y = 10
w = 23, x = 11, y = 10
w = 24, x = 11, y = 11
w = 25, x = 11, y = 11
w = 26, x = 11, y = 11
w = 27, x = 11, y = 11
w = 28, x = 11, y = 11

So we know that all primes are encompassed in natural numbers, right?

But how do we show that?
By definition, prime numbers are natural numbers with special properties.

I have no idea what you are trying to do afterwards.

Mark44, PrimeExample, Vanadium 50 and 2 others
PrimeExample said:
Summary:: So we know that all primes are encompassed in natural numbers, right?

But how do we show that?

w = {0,0 | 1,1 | 2,2...}

Let x = number of primes up to w+1
Let y = number of primes up to w-1
What is w? is it a set of pairs, a sequence of pains? A natural number? What is | ? etc.

PrimeExample
Last edited:
PrimeExample
willem2 said:
What is w? is it a set of pairs, a sequence of pains? A natural number? What is | ? etc.
Sorry I think it's supposed to be R = {0,0 | 1,1 | 2,2...}

To show rational numbers 0,0, 1,1, 2,2...

jedishrfu said:
Also some definitions of natural numbers don't include ZERO. In that case, you question on zero may be mute.

https://en.wikipedia.org/wiki/Natural_number
That's right... The Natural number line starts at 1, though, not 0.

The whole number/rational number line starts at 0,0.

The prime line starts at p1, 2.
p2, 3. p3, 4, p4 5, p5 6 and then p6 becomes 5 again on the natural number line.

mfb said:
By definition, prime numbers are natural numbers with special properties.

I have no idea what you are trying to do afterwards.
Right. The properties aren't that special, though.

They have to abide by the rules of natural numbers.

it is hard for me to understand what motivated this question, or rather just what the questioner wants to know. If the question could be rephrased as "which numbers are prime?", the answer requires me to know what the questioner considers to be a number. But if the answer to that is: " a number is a positive integer", then the answer to his question would be a tautological "yes".

Thus it seems to me entirely possible that the questioner may have wanted to know if there are any non positive prime integers, in which case of course the answer is that there are, so then we must say that prime numbers are not always natural numbers. I.e. prime numbers are not a subset of the natural numbers unless you happen to think that all "numbers" are natural numbers. In the larger world of integers, of course -2, -3, -5, -7, -11,... are also prime. I.e. primality is a certain divisibility property which has nothing to do with positivity. I.e. an integer p is prime iff p is neither 0 nor a unit and whenever p divides a product ab of integers, then p divides either a or b. In this sense the prime integers are {±2, ±3, ±5, ±7, ±11,...}

After writing this, I researched several sources and found that in number theory books, which are concerned mainly with properties of the natural numbers, i.e. positive integers, the word "prime" does seem to be restricted to positive integer primes. But in commutative algebra books, which are concerned with more general rings, the definition of the word "prime" is extended as indicated above. So the meaning of "prime number" is a little fluid, and depends on whom you ask.

Last edited:
PrimeExample
mathwonk said:
it is hard for me to understand what motivated this question, or rather just what the questioner wants to know. If the question could be rephrased as "which numbers are prime?", the answer requires me to know what the questioner considers to be a number. But if the answer to that is: " a number is a positive integer", then the answer to his question would be a tautological "yes".

Thus it seems to me entirely possible that the questioner may have wanted to know if there are any non positive prime integers, in which case of course the answer is that there are, so then we must say that prime numbers are not always natural numbers. I.e. prime numbers are not a subset of the natural numbers unless you happen to think that all "numbers" are natural numbers. In the larger world of integers, of course -2, -3, -5, -7, -11,... are also prime. I.e. primality is a certain divisibility property which has nothing to do with positivity. I.e. an integer p is prime iff p is neither 0 nor a unit and whenever p divides a product ab of integers, then p divides either a or b. In this sense the prime integers are {±2, ±3, ±5, ±7, ±11,...}

After writing this, I researched several sources and found that in number theory books, which are concerned mainly with properties of the natural numbers, i.e. positive integers, the word "prime" does seem to be restricted to positive integer primes. But in commutative algebra books, which are concerned with more general rings, the definition of the word "prime" is extended as indicated above. So the meaning of "prime number" is a little fluid, and depends on whom you ask.
Thank you for the well thought-out response.

In exchange, I hand you the next piece of the puzzle.

x = N(p) y = R(p)

Please, I would love to hear what you make of this.

Your notation is still unclear.
PrimeExample said:
To show rational numbers 0,0, 1,1, 2,2...
0,0 is not a rational number. It looks like a pair of rational numbers. R = {{0,0},{1,1},{2,2},...} would be a set of pairs of rational numbers.

PrimeExample
mfb said:
Your notation is still unclear.0,0 is not a rational number. It looks like a pair of rational numbers. R = {{0,0},{1,1},{2,2},...} would be a set of pairs of rational numbers.
Well, yeah... R = {{0,0},{1,1},{2,2},...} is what I'm looking for, then. That's what I've been trying to say.
Take that and multiply R by P where p0,p1,p2 = {{0,1}{1,2}{2,3}...}

Something like this. I think I did that r(p+1) and r(p-1) for upper and lower limits?

Edit, sorry I think it's this:

p0 = 0,1 x = 0, y = 1

p1 = 1,2 x = 2, y = 1

p2 = 2,3 x = 3, y = 2

p3 = 3,4 x = 4, y = 3

p4 = 4,5 x = 4, y = 3

Last edited:
PrimeExample said:
Take that and multiply R by P where p0,p1,p2 = {{0,1}{1,2}{2,3}...}
How do you multiply a set of pairs of numbers by another set of pairs of numbers?

You really need to make your nonstandard notation clearer.

Mark44
mfb said:
How do you multiply a set of pairs of numbers by another set of pairs of numbers?

You really need to make your nonstandard notation clearer.
Haha okay so imagine you have an infinite number of primes within natural numbers.

How many primes are there outside of natural numbers? How many before? How many after? If primes are infinite, where does the infinite of natural numbers end? Are they the same infinite?

So when we plot natural numbers against prime numbers, we start at 0,1.

Why 0,1? Because for this example, we consider p1 as 2,1.

2 is the 1st prime number.

We call p0 (0,1) so that we always work on the same axis as natural numbers.

Once we set that into motion, the two lines are not dependent on each other anymore.

They split infinitely. They'll cross back over, but only between twin primes.

This means p = 2n-1 in the long run, right? As many times as the biggest number we know?

PrimeExample said:
Haha okay so imagine you have an infinite number of primes within natural numbers.
Sure. That is easy enough. I have the situation imagined.

PrimeExample said:
How many primes are there outside of natural numbers?
None. You only told us to imagine infinitely many natural numbers that are prime. The notion of a prime number outside of the context of the algebraic ring within which it is prime is nonsensical.

Since you talked about natural numbers, I am implicitly assuming the ring of natural numbers under the standard operations of addition and multiplication.
https://en.wikipedia.org/wiki/Prime_element said:
Being prime is relative to which ring an element is considered to be in; for example, 2 is a prime element in Z but it is not in Z[i]
Perhaps more simply, 2 is a prime in the naturals. But in the rational numbers there are no primes. 2 is a "unit" there since ##2 \times \frac{1}{2} = 1##.

Edit: @mathwonk had already pointed out much the same thing.

Last edited:
PrimeExample
jbriggs444 said:
Sure. That is easy enough. I have the situation imagined.

None. You only told us to imagine infinitely many natural numbers that are prime. The notion of a prime number outside of the context of the algebraic ring within which it is prime is nonsensical.

Since you talked about natural numbers, I am implicitly assuming the ring of natural numbers under the standard operations of addition and multiplication.

Perhaps more simply, 2 is a prime in the naturals. But in the rational numbers there are no primes. 2 is a "unit" there since ##2 \times \frac{1}{2} = 1##.

Edit: @mathwonk had already pointed out much the same thing.
1e+300 x 1.0 x 10^100 is what I came to the conclusion of regarding primes

search it like this then just click the next numbers in the sequence

jbriggs444
PrimeExample said:
1e+300 x 1.0 x 10^100 is what I came to the conclusion of regarding primes
That number is utterly miniscule compared to some others that are often tossed around. Google things like Ackermann function (itself pretty picayune), Knuth's ^ notation or Graham's number.

All of them are decidedly finite. They have nothing to do with infinity.

PrimeExample
jbriggs444 said:
That number is utterly miniscule compared to some others that are often tossed around. Google things like Ackermann function (itself pretty picayune), Knuth's ^ notation or Graham's number.

All of them are decidedly finite. They have nothing to do with infinity.
The number of primes is literally infinity, is what the equation shows.

I tried understanding Graham's number but it's hard to grasp ahaha. Knuths notation as well.

I understand that googol is miniscule, but infinity must contain all the numbers you mentioned earlier, right?

PrimeExample said:
The number of primes is literally infinity, is what the equation shows.

I tried understanding Graham's number but it's hard to grasp ahaha. Knuths notation as well.

I understand that googol is miniscule, but infinity must contain all the numbers you mentioned earlier, right?
There are infinitely many primes, yes. This has been known since Euclid's time.

Yes, the natural numbers (an infinite set) contains all of the numbers I mentioned (Graham's number, all numbers denoted by finite strings in Knuth up-arrow notation and all values of the Ackermann function for all pairs of natural number inputs).

We try not to use "infinity" as a noun in mathematics, but I understand what you mean. Instead, we often use "infinite" or "unbounded" as an adjective.

The first usage of "infinity" you had above, the number of primes, we would denote by Aleph null (##\aleph_0##). That is the "cardinality" of the set of natural numbers.

The second usage of "infinity" you had above, the set of natural numbers, we might denote by Omega (##\omega##) or as ##\mathbb{N}## depending on context.

PrimeExample
jbriggs444 said:
There are infinitely many primes, yes. This has been known since Euclid's time.

Yes, the natural numbers (an infinite set) contains all of the numbers I mentioned (Graham's number, all numbers denoted by finite strings in Knuth up-arrow notation and all values of the Ackermann function for all pairs of natural number inputs).

We try not to use "infinity" as a noun in mathematics, but I understand what you mean. Instead, we often use "infinite" or "unbounded" as an adjective.

The first usage of "infinity" you had above, the number of primes, we would denote by Aleph null (##\aleph_0##). That is the "cardinality" of the set of natural numbers.

The second usage of "infinity" you had above, the set of natural numbers, we might denote by Omega (##\omega##) or as ##\mathbb{N}## depending on context.
That's awesome so different infinites.

But aren't Mersenne Primes always 2n-1? Is it possible that the Natural Numbers stop and Mersenne Primes continue it?

You can see this if you make n = 1.0 x 10^100
You'd get Mn = 2(1.0 x 10^100-1)

Or maybe it would be (1.0 x 10^100-1)^2
You can also do (1.0 x 10^100-1)^3

Once you do (1.0 x 10^100-1)^4 it becomes infinity. But if you played around within the bounds of each, you have 2 additional infinites, no?

Or am I missing something?

Are these what a hexadecimal system is?

PrimeExample said:
That's awesome so different infinites.

But aren't Mersenne Primes always 2n-1? Is it possible that the Natural Numbers stop and Mersenne Primes continue it?
The Natural numbers do not stop. I believe that it is an open question whether the Mersenne Primes do.

PrimeExample said:
You can see this if you make n = 1.0 x 10^100
You'd get Mn = 2(1.0 x 10^100-1)

Or maybe it would be (1.0 x 10^100-1)^2
You can also do (1.0 x 10^100-1)^3

Once you do (1.0 x 10^100-1)^4 it becomes infinity.
That is not how infinity works. No finite expression using addition, multiplication and exponentiation of natural numbers can yield an infinite result. The set of natural numbers, all of which are finite, is "closed" under those operations.

A calculator that claims that such an expression yields an infinite result is telling lies. [Or using a non-standard arithmetic like IEEE floating point]

An IEEE floating point value of

If you want to add division and subtraction to the list, you can find that you can't get any infinite algebraic numbers either.

PrimeExample said:
But if you played around within the bounds of each, you have 2 additional infinites, no?

Or am I missing something?

Are these what a hexadecimal system is?
No. You are heading out into the weeds. Essentially nothing you are saying is sensible at this point. Hexadecimal notation is entirely mundane and just as is just as finite as decimal notation.

You may wish to review the forum policy around personal speculation.

Last edited:
jbriggs444 said:
The Natural numbers do not stop. I believe that it is an open question whether the Mersenne Primes do.

That is not how infinity works. No finite expression using addition, multiplication and exponentiation of natural numbers can yield an infinite result. The set of natural numbers, all of which are finite, is "closed" under those operations.

A calculator that claims that such an expression yields an infinite result is telling lies. [Or using a non-standard arithmetic like IEEE floating point]

If you want to add division and subtraction to the list, you can find that you can't get any infinite algebraic numbers either.

No. You are heading out into the weeds. Essentially nothing you are saying is sensible at this point. Hexadecimal notation is entirely mundane and just as is just as finite as decimal notation.

You may wish to review the forum policy around personal speculation.
If Natural numbers do not stop, and Mn = 2n-1, how would you calculate massive natural numbers other than through Mersenne Primes?

And you're more than welcome to try it on your calculator, please tell me if you get a different result.

Maybe my calculator is just lying to me.

PrimeExample said:
Maybe my calculator is just lying to me.
Your calculator is most definitely lying. We are in the mathematics forum here, not computing.

In mathematics, there are infinitely many natural numbers. No matter how high you go, there is always one higher.

In computing, the overwhelmingly common practice is to use representation standards that have only finitely many representable values. If you are using 64 bit integers, you can only count up to approximately ##2^{64}##. Or ##2^{63} - 1## (about ##10^{19}##) if you are using two's complement.

I'm old enough to have encountered one's complement on some CDC Cyber hardware. That gives you -0 as a distinct representable value and still let's you count up to ##2^{59}-1## on a 60 bit word.

If your calculator is allowing things like ##10^{300}## then it is likely using IEEE double or quad precision floating point representation.

https://en.wikipedia.org/wiki/Double-precision_floating-point_format said:
The 11 bit width of the exponent allows the representation of numbers between 10−308 and 10308, with full 15–17 decimal digits precision. By compromising precision, the subnormal representation allows even smaller values up to about 5 × 10−324.
The 308 here comes from the exponent range from -1023 up to +1023 or so. Those are binary exponents, so the maximum representable value is approximately ##2^{1023}## which is approximately ##10^{308}##.

I don't mess with the IEEE spec very often, so I don't keep track of the nitty gritty details of the exponent bias and encoding for INFs, NaNs and denorms. I do know that they steal an exponent value for that. If you've seen two or three binary floating point standards, you've pretty much seen them all. I've done DEC F, D, G and H floating and dabbled with IBM (hexadecimal exponent) and IEEE. Might have seen decimal floating point at one time. Memory gets fuzzy after a few decades, but it's not rocket science.

Now then, IEEE specifies more than just a representation standard. It specifies a standard for arithmetic. So that multiplying ##10^{308}## by 10 (for instance) would give a mathematically correct result that is too big to represent. So the IEEE spec says to use a special representation for positive infinity instead.

There are good computing reasons for doing this sort of thing. Branching on an exception path in the event of an overflow error is expensive. You have to flush the pipeline and repopulate the instruction cache. Huge slowdown. By contrast, creating a result that is a well-defined exceptional value is cheap. You can keep the pipeline going and the instruction cache is still prefetched and ready for action.

So the result that is returned is IEEE correct, but it is not mathematically correct.

Edit: My Windows calculator goes up to ##9.9999... \times 10^{9999}## and then reports "Overflow".

Last edited:
jbriggs444 said:
But in the rational numbers there are no primes.
Every natural number is a rational number.

sysprog said:
Every natural number is a rational number.
Yes. Those numbers are "prime" in the ring of natural numbers but they are not "prime" in the field of rational numbers.

sysprog
jbriggs444 said:
Yes. Those numbers are "prime" in the ring of natural numbers but they are not "prime" in the field of rational numbers.
Thanks for the clarification.