mersenneforum.org Primes as pictures
 Register FAQ Search Today's Posts Mark Forums Read

 2016-09-22, 22:05 #1 pepi37     Dec 2011 After milion nines:) 134710 Posts Primes as pictures Lets say we have mega prime So it can put in matrix of 1000*1000 pixels and then any of number in prime can be associated by another color. I look for solution where I can a: change size of matrix b change "color" of numbers as I wish Did you seen something like that on Net?
 2016-09-22, 22:28 #2 Batalov     "Serge" Mar 2008 Phi(4,2^7658614+1)/2 216438 Posts https://www.rstudio.com/wp-content/u...cheatsheet.pdf https://wiki.nbic.nl/index.php/R_ggplot2_tutorial or similar tools in python
 2016-09-22, 22:38 #3 pepi37     Dec 2011 After milion nines:) 3×449 Posts Thanks! I will now look at those links!
2017-07-21, 15:40   #4
storm5510
Random Account

Aug 2009
U.S.A.

22×401 Posts

Quote:
 Originally Posted by pepi37 Lets say we have mega prime So it can put in matrix of 1000*1000 pixels and then any of number in prime can be associated by another color...
I did something similar to this a few years ago. The most recent prime, which I believe to be M74207281, has 22,338,618 digits. If one wanted a truly square image, then said image would need to be 4327 x 4327 pixels. I arrived at this by taking the square root of the number of digits, and rounding up. This probably coudn't be done on a screen, but I believe ti could be done in RAM then saved to a bitmap file. Using colors could be misleading. I would use grayscale. A value of 0 (zero) would be white, and 9 would be black. The values between could be represented by increasing the grayscale value by 25.

 2017-07-21, 17:02 #5 CRGreathouse     Aug 2006 2·2,963 Posts I used something like this as my profile picture on mymathforum for many years.
2017-07-21, 19:09   #6
chalsall
If I May

"Chris Halsall"
Sep 2002

2×4,643 Posts

Quote:
 Originally Posted by storm5510 A value of 0 (zero) would be white, and 9 would be black. The values between could be represented by increasing the grayscale value by 25.
Based on your rules, wouldn't you immediately switch white to black?

2017-07-22, 01:11   #7
storm5510
Random Account

Aug 2009
U.S.A.

22×401 Posts

Quote:
 Originally Posted by chalsall Based on your rules, wouldn't you immediately switch white to black?
No, not for decimal numbers Below is a table of values for each decimal number, using the RGB color model.

Code:
0 = 250,250,250
1 = 225,225,225
2 = 200,200,200
3 = 175,175,175
4 = 150,150,150
5 = 125,125,125
6 = 100,100,100
7 = 50,50,50
8 = 25,25,25
9 = 0,0,0
If a person has the prime number in a text document, for example, you would read it, one digit at a time, and assign a color value, then place in the bitmap, starting at coordinate 0,0, then proceed right until coordinate 4326,0 was reached. Drop down to coordinate 0,1 and continue from there, repeating the process until the images was complete.

It would depend on what type of monitor a person has in regards to being able to see the entire image, without some type of resampling.

 2017-07-22, 04:42 #8 Jayder     Dec 2012 2·139 Posts I've been working on this as a side project for over a year. I'm having problems with R where lines that should overlap do not, and I can't figure out a way to correct that. The following images are intentionally in low resolution, because it does not meet my standards: M49, base 10 M30, base 6 This is a common idea, but I got it specifically from Nadieh Bremer. I will point you to her wonderful blog for the explanation of these: https://www.visualcinnamon.com/portfolio/the-art-in-pi (Her code has a few quirks and has trouble with large numbers, so I rewrote the bulk of it.) I also converted M49 to base 2^24-1 in order to have (almost) every colour in the 24-bit colour space represent a digit. Here is that image (I cannot upload it to a hosting site because they compress large files): Google drive link
2017-07-22, 17:01   #9
storm5510
Random Account

Aug 2009
U.S.A.

160410 Posts

Quote:
 Originally Posted by Jayder ...I also converted M49 to base 2^24-1 in order to have (almost) every colour in the 24-bit colour space represent a digit. Here is that image (I cannot upload it to a hosting site because they compress large files): Google drive link
When whoever converted it to a PNG, a lot of data was lost in that instant. It got very fuzzy when I zoomed in. Still, this is a good example of what an image representation can look lilke.

2017-07-23, 01:27   #10
chalsall
If I May

"Chris Halsall"
Sep 2002

2×4,643 Posts

Quote:
 Originally Posted by storm5510 Still, this is a good example of what an image representation can look like.
Are you guys reproducing work which has already been done? Please see as an example.

Amusingly, I remembered this previous work, and first searched using Google Images using the term "Prime Curve".

This is the result I got back. And, of course, my girlfriend then immediately entered the room asking what I would like for dinner.

Thankfully she has a good sense of humour, but I'm going to cook tonight....

2017-07-23, 03:11   #11
Jayder

Dec 2012

4268 Posts

Quote:
 Originally Posted by storm5510 When whoever converted it to a PNG, a lot of data was lost in that instant. It got very fuzzy when I zoomed in. Still, this is a good example of what an image representation can look lilke.
You were supposed to download it, not view the preview. I guess I wasn't clear.

Quote:
 Originally Posted by chalsall Are you guys reproducing work which has already been done? Please see as an example
Hopefully everybody here is familiar with Ulam's spiral already. What is the reason for your question, anyhow? I've already admitted that this is not an original idea.

 Similar Threads Thread Thread Starter Forum Replies Last Post LaurV LaurV 9 2020-04-20 05:56 mfgoode Puzzles 18 2007-09-21 08:06 Joe O Prime Sierpinski Project 3 2007-06-02 21:28 Xyzzy Lounge 3 2005-07-12 23:12 Orgasmic Troll Math 45 2005-06-15 05:31

All times are UTC. The time now is 05:03.

Wed Oct 21 05:03:28 UTC 2020 up 41 days, 2:14, 0 users, load averages: 1.41, 1.81, 1.79