Prime Numbers

8 June 2025

I recently learned that any even number greater than 2 is the sum of two primes. That's shocking! I also learned that this is apparently not that shocking, because people have known for centuries. I also learned that people do not actually know this--that is, it's been shown to be true for all integers less than 4*10^18, but the conjecture has never been proven. It is called the Goldbach conjecture.

So lately I have been thinking a lot about primes. I know that Gauss and Reimann and countless others have found lots of interesting things about primes, and I want to look up more about their work. Especially Riemann's hypothesis, which is apparently a big deal to many fields. But they are also just fun to think about and explore by myself, even though I am doing things that people have been doing for ages.

I wrote a program in python to find the prime numbers between 2 and 100, because I am pretty sure we had to do that for a homework exercise in computer science, so it seemed manageable and relevant. It was harder than I thought it would be. For one thing, like math, computer science is not something I have learned a lot about previously. I learned Java in school, so switching to python was super fun. It is just like Java, but easier to type (I do kind of miss all the brackets and semicolons though; it feels weird without them). For another thing, I forgot how hard it can sometimes be to change a thought that makes sense to a person into a thought that makes sense to a computer program. There might be a function that says if one number is evenly divisible by another number, but I do not know it and could not easily find it while reading the documentation, so I decided to just do a lot of probably unnecessary work. I will probably try to tidy the program up and make it more efficient, but it was a fun challenge to figure out how to find prime numbers using only loops, addition, and subtraction.

I also woke up the next morning and realized it would be way faster to check all the factors starting from 2 and moving up to the given number, rather than starting at the given number - 1 and moving down to 2. So it could use some work for sure.

I am also curious about what happens if you add the prime numbers together in all their possible configurations, and what happens if you graph them. I recently learned about set theory, so of course I am curious what the Cartesian product would be PxP where P is the set of prime numbers, and what is the set where each element is the sum of the two numbers in the ordered pair of the Cartesian product? And then, of course, I am curious if this is just another unecessary complication, and realistically I will probably just iterate through lists of prime numbers to some point without any actual involvement of the idea of the Cartesian product besides that which is inherent. Like, the idea is maybe not exceptionally helpful to actually finding these sums, but it does provide an interesting way of thinking about finding them. So that's cool.

Maybe someday I will put something on here that is mathematically interesting, rather than writing only in rambling prose about things that are probably interesting but which I do not yet know much about. But half the point of this is to keep track of the things I want to learn more about, so it's not wholly useless. Maybe someday I'll learn how to use mathplotlib to make interesting visuals for these interesting things, and maybe I'll learn how to use that thing that lets you put math characters into HTML. Until then, this is pretty fun too.

Home