Software apps and online services
The world of π is vast and complex. Lot of people struggle to memorize Pi decimals for some reason. Current unofficial record is being held by a guy named Akari Haraguchi who memorized around 100.000 Pi decimals. How can he do such a thing? One common way to memorize Pi decimals is using something called Piems. What are Piems? Piems are some sort of poems that represent Pi in a way such that the length of each word (in letters) represents a digit.
A Piem example by Nobel prize sir James Hopwood Jeans:
“How I want a drink, alcoholic of course, after the heavy lectures involving quantum mechanics!”
So, Pi number, letters, words, poems... and a Raspberry Zero I had for some time waiting in a drawer: the Piem machine was about to happen.Parts
- Raspberry Pi Zero
- Thermal printer
- 7 segment 4 digit display
- DFRobot Self locking switch
- Custom 3d printed case
- 5V 4A Power Supply
There are many algorithms to calculate Pi digits. After some research I´ve decided to use the Chudnovsky algorithm, since there was a clean and good Python implementation and tutorial by Joshua Salako
I did modify the original function in order to get the last Pi decimal in every iteration. I have also downloaded an English dictionary with 10.000 words and connected the last Pi decimal in a function to get a random word with the same number of characters.
Then I have added functions to compile and print the words checking paper width. I have also coded a log function to save the Piems, a self locking pause start and pause button just in case you need to replace the paper roll and time calculations.Settings
# send to printer
# how many decimals
# Paper width
# Gpio button
# dictionary file
# pause between iterations
Using Fusion 360 I have designed an enclosure in 3 parts to hide the thermal printer aesthetic and to provide easy access to the button and 4 digit display.What about 0 length words?
The first 0 appears in the 33 decimal and in fact around 10% of decimals are 0, but there are no 0 letter words, right? So I had to make a decision here: whenever a 0 appears, the PiemPi machine will print an empty line.Why didn’t you wait until Pi Day
Pi Day is celebrated on March 14 and it is a common date to release anything related to Pi number but being in April, the wait was too long.
Could PiemPiuse other languages?
Sure. You only have to replace english.txt file by any other language file using one word per line. Words don’t have to be ordered by length.
Are thesepiems any good?
At first I though about using predictive techniques or even AI to make more sense but I kind of like the search for meaning in the endless roll.
You can specify any number of decimals but I have configured the PiemPi machine to generate piems up to the Feynmann point. What is the Feynmann point? A sequence of six consecutive nines starting at the 762nd decimal place with a really low probability (0.06% aprox)
While making this project I was listening to AC/DC T.N.T.
Follow me on Instagram
Check out my web Site