Pi Day


16 posts
by bryanandaimee » Fri Mar 14, 2014 3:49 am
I figured I ought to do something with the Pi for Pi day (3/14) so i installed Pi on my Pi,

sudo apt-get install pi

then i calculated Pi on the Pi to 3.141593 (rounded) million decimal places.

pi 3141593 > pimil.txt

The calculation took 132 seconds on my old Pi (256 MB version B) running at 1100 Mhz arm, 500 ram, and 500 core.

If you were to run a heavily overclocked Pi all day (on Pi day) calculating Pi, I think you could probably get close to calculating Pi-billion decimal places of Pi but I'm not sure if Pi would calculate that many digits of Pi on the Pi due to memory size constraints.

Bryan
Posts: 28
Joined: Fri Sep 14, 2012 4:32 pm
by Douglas6 » Fri Mar 14, 2014 4:06 am
Makes me think of that distributed SETI project. With 2.5 million Pis, we should have found ET by now.
If they weren't busy mining bitcoins, I guess.
User avatar
Posts: 1510
Joined: Sat Mar 16, 2013 5:34 am
Location: Chicago, IL
by bryanandaimee » Fri Mar 14, 2014 2:14 pm
How many digits per day could a beowulf cluster of 314 Pi's calculate? The world may never know.

Turns out that my Pi runs out of memory after only 20 minutes or so and kills the process. So the max number of digits I can calculate is something like 20 million. The 512 MB Pi's could probably do quite a bit better.

Bryan
Posts: 28
Joined: Fri Sep 14, 2012 4:32 pm
by lazarus78 » Fri Mar 14, 2014 6:25 pm
Douglas6 wrote:Makes me think of that distributed SETI project. With 2.5 million Pis, we should have found ET by now.
If they weren't busy mining bitcoins, I guess.

The Pis are actually very very VERY terrible for mining any type of cryptocoin, let alone bitcoin. It is literally a waste of power to even attempt it.

If you are talking about people who spend thousands of dollars on 6 GPU systems for mining, then yes, that is indeed also a waste of effort.
Posts: 228
Joined: Thu Jul 25, 2013 5:16 pm
by pluggy » Fri Mar 14, 2014 6:34 pm
Its getting to be a waste of money using dedicated ASICs to mine Bitcoin nowadays. It a lot cheaper to just buy it....

Ebay is awash with S/H Bitcoin ASICs at knock down rates.
Don't judge Linux by the Pi.......
I must not tread on too many sacred cows......
User avatar
Posts: 3487
Joined: Thu May 31, 2012 3:52 pm
Location: Barnoldswick, Lancashire,UK
by DougieLawson » Fri Mar 14, 2014 6:37 pm
pluggy wrote:Its getting to be a waste of money using dedicated ASICs to mine Bitcoin nowadays. It a lot cheaper to just buy it....

Ebay is awash with S/H Bitcoin ASICs at knock down rates.

Is it?

http://www.raspberrypi.org/archives/6437
Please post technical questions on the forum, not by personal message. Thanks.

Hacker on ZX80, Microtan65, Raspberry Pi & Arduinos
Mainframe Database troubleshooter
MQTT Evangelist
RPi owner since 2012.
Twitter: @DougieLawson

2B, B+, A+, 5Bs, C
User avatar
Posts: 13097
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
by pluggy » Fri Mar 14, 2014 6:44 pm
Cheap power, if you watch the video. Its not viable at consumer power prices.
Don't judge Linux by the Pi.......
I must not tread on too many sacred cows......
User avatar
Posts: 3487
Joined: Thu May 31, 2012 3:52 pm
Location: Barnoldswick, Lancashire,UK
by bryanandaimee » Sat Jul 26, 2014 12:26 am
Just found a post on Mathematica about calculating pi and it looks like that speeds things up quite a bit.
Code below:

(*Clear Cache*)
ClearSystemCache[]

(*Calculate pi to 1 million decimal places and store the result*)
AbsoluteTiming[pi = N[Pi, 1000000];]


On the same setup as before I got:
pi million decimal places 38.4 seconds
2pi million decimal places 93.8 seconds
4pi million dp 241.4 seconds

Same memory limits seem to apply. Limit is somewhere around 20 million dp
Posts: 28
Joined: Fri Sep 14, 2012 4:32 pm
by bryanandaimee » Sat Mar 14, 2015 8:56 pm
In honor of the special once a century pi day I repeated the above calc on a B+ with maximum memory allocated to the CPU. I got clear up to 5.654866 x 10^7 decimal places of pi. Calculation took 1662 seconds using a standard turbo mode at 900 Mhz. No other overclocking features were used.

Maybe next year I'll try with a B2

Gotta go make some pie

Bryan
Posts: 28
Joined: Fri Sep 14, 2012 4:32 pm
by adlambert » Sat Mar 14, 2015 10:06 pm
lazarus78 wrote:The Pis are actually very very VERY terrible for mining any type of cryptocoin, let alone bitcoin. It is literally a waste of power to even attempt it.


For doing the actual crypto work you are correct. However, because low power Pis make ideal controller interfaces to the ASICs and run CGMiner very well and extremely stable. My CGMiner host is an old 256MB Model B. So, many thousands of Pis are in fact employed in crypto-coin mining supporting roles and are very good at it.

pluggy wrote:Its getting to be a waste of money using dedicated ASICs to mine Bitcoin nowadays. It a lot cheaper to just buy it....


Bitcoin prices over the last 2 weeks recovered to around £200, and this has caused a lot of ASICs to switch on, and pools have become very well populated again.
- G6FIR
Posts: 359
Joined: Tue Jan 03, 2012 3:18 pm
by solar3000 » Sun Mar 15, 2015 11:19 pm
so did anything actually happen on pi day?
Posts: 399
Joined: Sat May 18, 2013 12:14 am
by DougieLawson » Mon Mar 16, 2015 12:18 am
solar3000 wrote:so did anything actually happen on pi day?


Yep. A bunch of silly people who write their dates backwards (compared to EUR, JIS & ISO standards) fussed about the day of the month and the month of the year and got ever more silly at 9:26:53 on that same day.
Please post technical questions on the forum, not by personal message. Thanks.

Hacker on ZX80, Microtan65, Raspberry Pi & Arduinos
Mainframe Database troubleshooter
MQTT Evangelist
RPi owner since 2012.
Twitter: @DougieLawson

2B, B+, A+, 5Bs, C
User avatar
Posts: 13097
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
by solar3000 » Mon Mar 16, 2015 2:17 pm
DougieLawson wrote:
solar3000 wrote:so did anything actually happen on pi day?


Yep. A bunch of silly people who write their dates backwards (compared to EUR, JIS & ISO standards) fussed about the day of the month and the month of the year and got ever more silly at 9:26:53 on that same day.


There was no mention this Saturday in the new at all (USA).

As for dates, I use this format to name my files: YYYY-MM-DD. Sorts out just fine.

We should use this date: The date and time now is: 1426515396
Posts: 399
Joined: Sat May 18, 2013 12:14 am
by bertwert » Mon Mar 16, 2015 2:31 pm
DougieLawson wrote:
solar3000 wrote:so did anything actually happen on pi day?


Yep. A bunch of silly people who write their dates backwards (compared to EUR, JIS & ISO standards) fussed about the day of the month and the month of the year and got ever more silly at 9:26:53 on that same day.

I do not like that date format, it makes no sense. :x
Their argument:
It is like saying March 14 2015 and you wouldn't say 14th of March 2015.

Uh yes I would....

Unfortunately 2015 doesn't have 14 months...
Please correct me if I am wrong ;-)

BERTWERT
www.techni.ca
User avatar
Posts: 418
Joined: Tue Aug 13, 2013 8:15 pm
Location: Golden, BC, Canada
by DougieLawson » Mon Mar 16, 2015 2:36 pm
bertwert wrote:I do not like that date format, it makes no sense. :x
Their argument:
It is like saying March 14 2015 and you wouldn't say 14th of March 2015.

Uh yes I would....

Unfortunately 2015 doesn't have 14 months...

Here in Rightpondia we really do say "Saturday, 14th of March" it comes from the mouthful "The fourteenth day of March in the year of our Lord two thousand and fifteen" (from when we were just a bit more religious).

We can have our own Pi approximation day on 22nd July.
Please post technical questions on the forum, not by personal message. Thanks.

Hacker on ZX80, Microtan65, Raspberry Pi & Arduinos
Mainframe Database troubleshooter
MQTT Evangelist
RPi owner since 2012.
Twitter: @DougieLawson

2B, B+, A+, 5Bs, C
User avatar
Posts: 13097
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
by pluggy » Mon Mar 16, 2015 2:41 pm
Goddamned parochial yanks......

It really was the 14th of March, like today is the 16th of March.
Don't judge Linux by the Pi.......
I must not tread on too many sacred cows......
User avatar
Posts: 3487
Joined: Thu May 31, 2012 3:52 pm
Location: Barnoldswick, Lancashire,UK