News for hackers. Stuff that matters.
Re:The Connection That Changed Number Theory by PartiallyTyped on Saturday November 04, 2023 @07:39PM (#38146402)
> There are three kinds of prime numbers. The first is a solitary outlier: 2, the only even prime. After that, half the primes leave a remainder of 1 when divided by 4.

We can generalize this. There are 2 kinds of primes with respect to mod. Those whose modulo x for x large is 2 or 5, and those whose mod x falls into some other odd number. Of the latter numbers, the more primes you consider the more it looks like a uniform distribution. This is related to the Riemann hypothesis [1].

But for the purposes of this article; we have that x=4.

[1] https://www.youtube.com/watch?v=dwe4-OiRw7M

Re:The Connection That Changed Number Theory by fatherzine on Saturday November 04, 2023 @08:15PM (#38146626)
Why do people say '2 is a solitary outlier'? Sure, by a quirk of English there is a special word 'even' denoting 'number divisible by 2'. By that logic, every prime k is a "solitary outlier", being the only prime divisible by k. E.g. '5 is a solitary outlier, the only fiven prime'.
Re:The Connection That Changed Number Theory by ducttapecrown on Saturday November 04, 2023 @08:24PM (#38146682)
Because many formulas associated to a prime have a factor of p-1, so it's trivial in the case of p=2. There's also other weird stuff like no negatives and no quadratic formula in characteristic 2.
Re:The Connection That Changed Number Theory by lisper on Saturday November 04, 2023 @08:21PM (#38146657)
And while we are at it why is 1 not a prime? It conforms to the definition.
Re:The Connection That Changed Number Theory by ducttapecrown on Saturday November 04, 2023 @08:25PM (#38146689)
Because primes are about factoring and the number of 1's in a factorization is boundless and immaterial.
Re:The Connection That Changed Number Theory by zmgsabst on Saturday November 04, 2023 @08:27PM (#38146703)
You can’t uniquely factor if you include units, which in the naturals is 1.

You’d also remove every other prime number, since in general we can say that a prime isn’t divisible by a smaller prime.

That we have to add “except 1” to both the factoring theorem and the definition of prime itself is why we don’t include 1 as a prime.

Re:The Connection That Changed Number Theory by tzs on Saturday November 04, 2023 @08:44PM (#38146812)
Up until sometime in the 19th century 1 was often considered to be prime.

If it is considered to be a prime, then you end up with a lot of theorems that start "for all primes p != 1" or "for all odd primes != 1".

If it is not considered to be a prime, you end up with other theorems that start "for all primes and 1" or "for all odd primes and 1".

There are more really important theorems in the former set than the latter set and so considering it to not be prime became the convention.

Re:The Connection That Changed Number Theory by tromp on Sunday November 05, 2023 @06:35AM (#38150227)
Are there any in the latter set?
Re:The Connection That Changed Number Theory by empath75 on Saturday November 04, 2023 @09:18PM (#38147009)
If 1 is a prime, then the prime factorization of any number can include an arbitrary number of 1s.
Re:The Connection That Changed Number Theory by devit on Saturday November 04, 2023 @09:22PM (#38147040)
"An element p of a commutative ring R is said to be prime if it is not the zero element or a unit and whenever p divides ab for some a and b in R, then p divides a or p divides b"

1 is a unit.

Re:The Connection That Changed Number Theory by svat on Saturday November 04, 2023 @09:49PM (#38147207)
Some good answers and discussion at https://math.stackexchange.com/questions/120/why-is-1-not-a-...

In particular, the papers "What is the smallest prime?" https://arxiv.org/abs/1209.2007 and "The History of the Primality of One: A Selection of Sources" https://cs.uwaterloo.ca/journals/JIS/VOL15/Caldwell2/cald6.h... have good history on the matter (e.g. 1, 2, and 3 were all answers at various points — note that at some point in history 1 wasn't even considered a number).

Re:The Connection That Changed Number Theory by contravariant on Saturday November 04, 2023 @10:11PM (#38147345)
I did once try to run through all the definitions and their generalisations, and it basically boils down to the fact that the zero ring is not a field. This gives the following stacktrace as for why you can't make 1 a prime:

- A prime number is a positive prime element of Z

- A prime element is an element p which is not a unit such that whenever p divides ab then p divides a or p divides b (or both)

- An element which generates a prime ideal is a prime element

- A ring divided by a prime ideal is an integral domain

- All integral domains have a field of fractions

- The zero ring is not a field

Make 1 a prime at the first step and things go wrong at the final step. Most of these definitions have a good argument, except the first arbitrarily excludes the non-positive numbers. This includes 0 which is a perfectly acceptable prime according to all other definitions (and unlike the negative primes, is not simply the negative of a prime number).

Re:The Connection That Changed Number Theory by tgv on Sunday November 05, 2023 @06:34AM (#38150224)
The exclusion of negative numbers is not arbitrary. Depending on your exact definition, you would be left with the current prime numbers, these plus their negatives, or none at all (since 2 is divisible by -2).
Re:The Connection That Changed Number Theory by contravariant on Sunday November 05, 2023 @10:05AM (#38151727)
The notion of 'negative' doesn't transfer too well to other rings. It vaguely makes sense to only look at the natural numbers (excluding 0), primality predates negative numbers as a concept after all, but from the point of view of the more general definition it is mostly arbitrary.
Re:The Connection That Changed Number Theory by gizmo686 on Sunday November 05, 2023 @10:13AM (#38151791)
Primality is defined for any ring (although some rings have no primes). If you are asking about prime integers, then negative primes are themselves prime. Most of what you know of primality still holds if you add 'up to unit multiples' to all of your theroums.
Re:The Connection That Changed Number Theory by kevinventullo on Sunday November 05, 2023 @09:20AM (#38151323)
Why stop there; why can’t we consider the zero ring a field? It has addition, subtraction, multiplication, and (vacuously!) every nonzero element has a multiplicative inverse.

I realize the definition of fields usually includes the axiom 0 != 1, but I think this is just as arbitrary as “1 is not prime”.

You can even extend this to scheme theory, where Spec of the zero ring is the empty set, and conversely the zero ring is the ring of regular functions on the empty set. Note that the empty set is always open in the Zariski topology!

Anyway I’m not actually seriously advocating for this position, just that it does seem to be consistent.

Re:The Connection That Changed Number Theory by contravariant on Sunday November 05, 2023 @10:08AM (#38151751)
Yeah, best argument I can come up with is that the multiplication over the zero ring minus 0 does not form a group. But you'd need to modify the usual definition of a field for this to look natural.

There is quite a lot of research on a zero field, which shows up sometimes (never as a conceret object, but more like A_p is to the field of p elements what A_0 is to the zero field). Apparently you can't just use the zero ring, though the reasons why are beyond my pay-grade.

Re:The Connection That Changed Number Theory by not2b on Saturday November 04, 2023 @10:59PM (#38147642)
Making 1 a prime would break unique factorization (any number has a unique set of prime factors).
Re:The Connection That Changed Number Theory by toosimpletobe on Sunday November 05, 2023 @01:37AM (#38148596)
Non-primality of 1 is a design decision made by the mathematical community. A convention with which one can agree or disagree.

But it is part of a general pattern that certain objects are "too simple to be simple" [0].

Here "simple" should be thought of as atomic, indecompossible, without smaller parts.

- prime numbers are simple wrt multiplication, 1 is too simple to be prime

- the zero ring is too simple to be a field

- the trivial group is too simple to be a simple group

- the empty topological space is not connected

- etc...

It turns out that if one adheres to this convention, then theorem statements generally become shorter, and have fewer side conditions.

[0]: https://ncatlab.org/nlab/show/too+simple+to+be+simple

Re:The Connection That Changed Number Theory by bmacho on Sunday November 05, 2023 @03:12AM (#38149277)
If it conforms the definition, then 1 is a prime. This is evident.

Why would they choose a definition so that 1 is not a prime? They found it the best and most useful definition that they knew at that time.

While there are many bad definitions, concepts and names in math, I don't think prime number is an example.

Also please notice that sometimes the more useful concepts have longer definitions, especially if one limits themselves in the terms they want to define it. (That is they don't use the nicest properties to define prime numbers, but they define them as:)

  A prime number (or a prime) is a natural number greater than 1 that is not a product of two smaller natural numbers. [0]
This is indeed longer and more complicated than if we did not exclude 1. But the concept is (at least in the current state of math) more useful than if 1 weren't excluded. Who knows, maybe in the future math they will find a new structure or theory, where the prime numbers + {1} is a really useful concept.

[0] : https://en.wikipedia.org/wiki/Prime_number

Re:The Connection That Changed Number Theory by bonzini on Sunday November 05, 2023 @08:32AM (#38150968)
It only makes sense to define factorization on numbers that don't have an inverse, otherwise you can make infinite factorizations of a number by multiplying by a number that has an inverse and then by its inverse.

Therefore it makes sense to classify numbers as either primes (they are their own unique factorization), or composites (they are the result of the multiplication of other numbers, and the factorization may or may not be unique), or units (numbers that have an inverse). 1 is the only unit of the natural numbers.

If you add negative integers, this results into all negated primes being also primes, and there is no unique factorization (for example 6 is 2*3 but also -2*-3).

Re:The Connection That Changed Number Theory by bmacho on Sunday November 05, 2023 @01:29PM (#38154007)
Yeah, I don't buy this argument. Or anything similar for analogue questions. They obviously have zero proving strength. Especially if it is only 1 example.

To the question "why professionals use the tool they use instead of a slightly different version of that tool", the answer is either:

  - they like it, or
  - they don't like it, but they still use it, say for historic reasons
Now you can list various examples to illustrate your point why would they prefer the tool as it is, instead of a hypothetical, slightly different version of said tool. But you can't just point at 1 example and say that this is the reason. That is just a wrong answer. Logically wrong. Lying. Annoying and hurting the readers head. Don't do that.
Re:The Connection That Changed Number Theory by bonzini on Sunday November 05, 2023 @02:24PM (#38154645)
Ok, then the answer is "they do use a slightly different version of the tool than what you learnt at school. That version is more rigorous (which is why they like it) and in that version 1 is neither a prime nor a composite. In the version you learnt at school you're told that 1 is not a prime and you can't really say that it's composite either, but no clear explanation of why it is not a prime; in the version that mathematicians use there's a name for what 1 is, and a rule to find things like it in other number systems."
Re:The Connection That Changed Number Theory by empath75 on Saturday November 04, 2023 @09:20PM (#38147026)
> Why do people say '2 is a solitary outlier'?

In this particular split of the prime numbers there are 3 categories, and 2 is the only member of one of the categories, while the rest are evenly divided. So it's a solitary outlier.

Re:The Connection That Changed Number Theory by svat on Saturday November 04, 2023 @10:32PM (#38147504)
You're replying to a comment that already answers your question. :-) I'd use slightly different words and say:

• When you work modulo 4 (as in the article in the context where this comes up), there are three kinds of primes: 2 is a solitary outlier, and all other primes are equally distributed between being 1 and 3 mod 4.

• When you work modulo 10, there are six kinds of primes: 2 and 5 are outliers, and all other primes are equally distributed between being 1, 3, 7 and 9 mod 10.

So 2 is an outlier when working mod 4 (or any even number). Mod 4 is crucially important in the context of quadratic reciprocity, so it matters here.

Re:The Connection That Changed Number Theory by priprimer on Saturday November 04, 2023 @10:22PM (#38147433)
what I am amazed by is how of the primes congruent 1 mod 4 can be factored into complex numbers

but what puzzles me is that 11,13,17,19 are primes just like 101,103,107,109

but the real punchline is that 23 is the next prime after 19 AND 113 is the next prime after 109. WHY!?

this must be connected to 2*5

but I only have questions and confusion