So a LONG time ago I watched a 3blue1brown video about prime numbers, and today it suddenly just came to me and I made this (fixed link) visual representation of it.
PS: If anyone could make the prime calculator faster, I will be very happy ![]()
So a LONG time ago I watched a 3blue1brown video about prime numbers, and today it suddenly just came to me and I made this (fixed link) visual representation of it.
PS: If anyone could make the prime calculator faster, I will be very happy ![]()
I think you inserted the wrong link … the link just goes to 3blue1brown video …
I did, sorry guys
Corrected: Polar Primes | Desmos
You can substitute Expression#4 with:
D_ivResult = mod(P_find, P_rimes)
this will make it immediately much faster
You can also update P like this:
P \to P+2
to skip even numbers.
And here’s a better way to check for primes:
I_sprime = \prod_{n=1}^{L.count} sign(mod(P,L[n]))
I did, I actually figured that out before you said this ![]()
I will add all of this, tysm
I will do this after I get out of school and see the results
And you can make it much faster by limiting the checks up to
the square root of the number you are checking:
\prod_{n=1}^floor(sqrt(P) sign(mod(P,L[n]))
I think the biggest issue is that as the list growers larger, it will be slower. Because when I am running it with a 6200 long list, it is still very slow.
i also have a graph of all numbers,with their angles being squared that would be interesting to be graphed with only primes:
zoom out and you can see it
the graph is (in polar cordanites)(a,a^2)
A possible trick (or cheat) could be to just create the list of the first 10000 primes once and for all … so you don’t need to run any code …
Yes, things get slower because of the length of the list but also because for each number you need to test hundreds of divisors …
thats what I’m trying to do
Btw, you can see the 280 rays now
(anyone wanna count to verify?)
you can sort of count them with Desmos:
https://www.desmos.com/calculator/amiqtrgn9h