Hacker News

New stories

Live mirror
30 storiesupdated just nowView source snapshot
  1. Douglas Davis: The First Collaborative Sentence(whitney.org)
    discuss
  2. Goose Robot(twitter.com/robotworksgoose)
    discuss
  3. Morpion Solitaire(morpionsolitaire.com)
    discuss
  4. High-mileage electric cars are more reliable than petrol ones, study finds(theguardian.com)
    discuss
  5. A Call for Control of Frontier AI Models(government.nl)
    discuss
  6. Why banning AI in the classroom will not be enough(theconversation.com)
    discuss
  7. Show HN: Cookbook – a workspace for your team and agents(cookbook.team)
    1comments
  8. Does an open-weight decision model beat a hosted one? Jev vs. Laya(astgl.com)
    discuss
  9. Zero-downtime Linux kernel zero-day mitigation via eBPF and SECCOMP(github.com/mc493)
    discuss
  10. Show HN: a0flow — paid micro-APIs for AI agents, x402/USDC, no signup(a0flow.com)
    discuss
  11. International Conference on Functional Programming (ICFP) 2026 talks released(youtube.com)
    discuss
  12. What does this assembly code do?(pagetable.com)
    1comments
  13. AgentsView(agentsview.io)
    discuss
  14. Playing with Jev for Daily Questions(yesno.fyi)
    discuss
  15. MiMo-v2.6-Flash(mi.com)
    discuss
  16. HTTP QUERY Method: The Grey Zone Between Get and Post(sans.edu)
    discuss
  17. The Apple Watch Has a Problem(YouTube – Marques Brownlee) [video](youtube.com)
    discuss
  18. Tell HN: Substack obfuscating text to break reading mode
    discuss
  19. DoorDash Agrees to $131.5M Settlement for Shortchanging Workers(nytimes.com)
    1comments
  20. Claude Opus 5.5 (High Effort) Intelligence, Performance and Price Analysis(artificialanalysis.ai)
    discuss
  21. Faster and local Jev like model for Mac(github.com/mizorewww)
    discuss
  22. Show HN: Botzilla – Web automation using visual scripting(botzilla.dev)
    discuss
  23. Show HN: Notes on Agentic AI – A text-first guide for practicing engineers(github.com/mrsachindixit)
    discuss
  24. Enjoy Every Sandwich(bradmontague.substack.com)
    discuss
  25. Shipping our game to twelve platforms on day one(m2h.nl)
    discuss
  26. Show HN: Last Internet Connection(github.com/rubinoslaw)
    discuss
  27. Harper Lee first edition novel found in Oxfam shop(bbc.com)
    discuss
  28. Meta Tests Muse AI Agent Calls That Are Made by Humans in a Call Center(404media.co)
    discuss
  29. Unreal Agent(github.com/unreallabsai)
    1comments
  30. Show HN: Parametric, low-poly assets for BIM/CAD(3dassetstudio.com)
    discuss

Engineering Memory: On learning to memorize first 100 digits of pi (2024)

54 pointsby 1d agogregorygundersen.com
36 comments
16h agoHN ↗

If Socrates were alive today, he'd encourage engineers to internalise the spigot algorithm

Then, like a MENTAT, they'd be able to tell you the 16afedf97fd4th digit of pi when prod

In hex, naturally https://en.wikipedia.org/wiki/Bailey%E2%80%93Borwein%E2%80%9...

The BBP formula gives rise to a spigot algorithm for computing the nth base-16 (hexadecimal) digit of π (and therefore also the 4nth binary digit of π) WITHOUT computing the preceding digits.

5h agoHN ↗

Reminds me of the old adage that if a famous person from the ancient world were alive today, they'd either be very, very old -- or not famous.

10h agoHN ↗

Moonwalking with Einstein is a fun read. I started using some tricks in real life. One of the key premises is that humans are much better at remembering sensory things than abstract ones.

A good example is remembering names: when one’s name is “John Baker”, it is so much easier to remember by silently adding “the” in front of it.

We’re also very good at remembering salacious stuff. I tried constructing my own memory palace for a grocery shopping list that included cream cheese. If you mentally make Claudia Schiffer take a bath in cream cheese, you’ll never forget that. (I read the book at least 10 years ago and still haven’t…)

5h agoHN ↗

The John Baker? Why is that easier to remember?

4h agoHN ↗

I have a feeling that original commenter might have already understand where the the was supposed to be placed :D

55m agoHN ↗

LMAO I don't want to even guess how long it would have taken me to do 2+2 here if this exchange hadn't already occured. Thanks!

I do something similar just not normally in the middle (e.g. "long john baker" and a mental image of someone baking ing long johns), maybe I should give middles more of a try.

10h agoHN ↗

In 1999 when I was about 12, I memorized 120 digits of pi with little issue. I had some extra motivation: once I got to 20-30 digits, a classmate bet me I couldn't get past 100, and he'd give me $1 for every digit I memorized past 100. Never saw my $20 :(. Pretty sure it was a well-executed nerd-snipe.

Having not practiced at all since about 2001 or so, I can still get to about 30 pretty easily. I didn't use any techniques specifically, I just kept practicing as far as I remember.

10h agoHN ↗

A chapter on memorising numbers from he book The Memory Book: The Classic Guide to Improving Your Memory by Harry Lorayne and Jerry Lucas uses a similar technique. They recommend memorising this mapping:

0: 's'

1: 't'

2: 'n'

3: 'm'

4: 'r'

5: 'l'

6: 'sh'

7: 'k'

8: 'v'

9: 'p/b'

To use it, just make images/stories that correspond to the digits you need to remember.

The more absurd the story, the less likely you'll forget.

E.g. pi (3.14159265359 ) could be the images of these objects: mit, rat, lab, Noah, shell, mail, bee. Then just sew them together in a story e.g. someone drops a mit, it lands on a rat, the rat runs up to someone in a lab, it's Noah, he throws a shell, it knocks over some mail which lands on a bee.

I don't use it often, but I like to memorise any 8+ digit door code when checking into a serviced apartment or airbnb, in case I forget my phone and would otherwise be without the code.

9h agoHN ↗

Funny, I just finished that book.

They were using a few more mappings per number for instance:

0: 's', 'z', soft 'c'

1: 't', 'd', 'th'

6: 'j', 'sh', 'ch', soft 'g'

etc

The problem I have, is that they present them from 1 to 0, and the first 4 have some mnemonic logic added to them: a bar in 't' for 1, two bars down in the 'n' for 2, three in 'm' for 3, and the 'r' from fouR in 4.

Great. And then mnemonic logic goes out the door. 5: 'l'. Ah. A single bar. Err.. is it 1 or 5..? 7: 'k'. Imagine the K looks like a 7. Ok, maybe.

So the mapping itself starts getting confusing. Unless you do what they claimed all along the book you shouldn't do: rote memorization.. Which was grinding my gears a bit..

2h agoHN ↗

At some level you do have to let rote memorization take place. For 10 digits for example, this is totally reasonable and you can memorize those associations in an hour easily. Then you can apply them to create mnemonics for 1000s of things.

10h agoHN ↗

Learning an entire Mozart sonata is probably easier. How much engineering there is in the memorizing or in the composition I don't know, a lot?

10h agoHN ↗

A lot of professional musicians memorize tons of music habitually. It's not very hard to be completely honest.

Mozart only wrote like 20 piano sonatas and about the same number of violin sonatas. It's no exaggeration to say that most concert pianists or violinists probably know at least 5 of them just as a matter of course because they will have learned them at some point in their musical education and someone who specialised in the classical period would probably know all of them. My wife learns tons of repertoire when she's performing as most of her concerts are completely from memory and this includes a vast range of repertoire from the middle ages through very complex 20th/21st century music.

Conductors often memorize monumental works as part of their preparation. Eg Zubin Mehta conducting Bruckner's 8th from memory age 89. That's a way way bigger piece of music than a Mozart sonata - super long and with massive forces. https://parsikhabar.net/music/zubin-mehta-at-89-still-comman...

This is the same as how chess grandmasters know literally hundreds or possibly thousands of games. Extreme example: David Howell tests Magnus Carlsen https://youtu.be/eC1BAcOzHyY?si=I-xJEo4NQUkLPDQ0

...or jazz musicians know hundreds or possibly thousands of standards.

You kind of have to know these things to perform. That being said with memorizing music you have a lot of structure that makes it easier whereas memorizing digits of pi or e you are learning a transcendental number so it may as well be random. You have to impose whatever structure you can, which must surely make it harder.

4h agoHN ↗

This reminds me of this video [0] of Maria João Pires, who realized that she had prepared the wrong concerto while on stage, being visibly shocked and panicked (and the conductor telling her that there would be no problems as she knows the piece very well). She apparently played the piece perfectly.

[0] https://www.youtube.com/watch?v=300t2DS3VdQ

9h agoHN ↗

I never found a real life use case for memory tricks. Would be curious to hear if someone has.

6h agoHN ↗

I will give you an encrypted message, from which you will be the transport medium, and will bring it across the border. No signals to flag alarm ...and you also wont know what it means...

5h agoHN ↗

I did that just lass week, but they headed me off at the pass before I could reach the dead letter box!

8h agoHN ↗

I used a memory palace for my A-Level Law exams. I was able to remember names and details for up to 250 different cases very easily, in fact so easily it felt like cheating.

The trick is to embrace incredulity. The more bizarre and strange the “tags” you assign to what you remember, the easier they stick in your head. It feels daft and cringeworthy, but it really, really works.

For this, however, I’d argue a memory palace is overkill. And I still don’t know how well it lends itself to remembering numbers by rote.

Consider this: how many telephone numbers have you memorised?

I can recall four of my own, each of my parents, my wife, and a handful of home phone numbers too.

That’s easily 100 digits in a specific order. Perhaps it’s possible to chunk the 100 digits of pie into smaller pieces, and memorise them like phrases, just as we do with phone numbers.

8h agoHN ↗

I know pi to 50 places learned through lots of repetition. I've always been good at remembering numbers though.

I don't find the memory palace tricks helpful at all though. I think that is a consequence of my Aphantasia and something I only realised recently. I can't visualise a memory palace so placing things in it is impossible!

7h agoHN ↗

I’m on the complete opposite part of the spectrum from aphantasia, but also don’t find the memory palace concept useful. Actually, I find any trick to memorize things to be a detriment to actually remembering things effectively! I still have to go through the whole alphabet song, instead of having the order internalized :)

On the other hand I learned 15 decimals of pi as a kid through pure rot training and feel they are way more internalized

3h agoHN ↗

Is there "benchmark data" on different memory techniques? I also wondered about this because I also memorized 50 digits on a lark back in high school, without the post's encoding technique and memory palace.

I added one block of 10 digits per night, spending maybe 10 minutes per night? Very roughly an hour total, ~same as the poster spent to get 100 digits, but without the prior investment they spent on the PAO (memorizing 300 key-value pairs, apparently).

You'd want to compare to Anki, too.

6h agoHN ↗

These memory trick posts are always interesting to read for someone with Aphantasia. Most of the tricks require visualization which is impossible for me. Memory palace means I have to now remember double the things. The rooms in the house and the thing I've placed in the room.

6h agoHN ↗

NASA requires 15 decimals of pi for interplanetary navigation. On the range of 16 bn miles to Voyager 1 it gives them calculations being off by 0.6 inch. For universe-sized circles they need 37 decimals of pi.

Trying to remember 100 digits of pi won't give you any advantage in cognitive functions apart from memorizing 100 digits of pi, for a little while. Better spend your time elsewhere.

https://www.jpl.nasa.gov/edu/news/how-many-decimals-of-pi-do...

5h agoHN ↗

You think they are memorizing the digits of pi because it’s useful?

6h agoHN ↗

None of these techniques are new, they were just described here in $50 words and in triple the time necessary.

I can teach you right now, the first 50 digits of Pi, after the 3 and the comma. And with almost zero effort. Just memorize the text below...

Congrats you little, little genius.

# ===========================================================

"A poem I write carefully to encode every new digit silently, reminding curious beginners how we can decipher each number in hidden text you see.

Whenever you go through beautiful green wilderness at midnight, remember when I carefully recited a simple paragraph and practiced repeating the numbers again; I remembered."

# ===========================================================

1h agoHN ↗

Sir I have a rhyme excelling In mystical force and magic spelling Celestial sprites elucidate All my own striving can’t relate

5h agoHN ↗

There’s a song on YouTube that my kid and a bunch of his classmates used to memorize the first 100 digits of pi. When they were 6 the entire class memorized the periodic table similarly using a YouTube song as well.

Funny thing is that another kid memorized pi to over 500 digits just from pure memorization.

4h agoHN ↗

I assume my daughter used that song as well. I remember us sitting at the dining room table and her peeling off 100 digits of pi. I explained to her that that would provide an accuracy such that a circle the size of the observable universe would be accurate to within a Planck length.

Fun memory from 16 years ago. Next month she'll be obtaining her PhD in physics.

5h agoHN ↗

Answer in Progress on YouTube has a cool video on memory tricks and memorizing Pi [1], worth a watch.

[1] i memorized 3,141 digits of pi to prove a point (https://www.youtube.com/watch?v=KAjkicwrD4I)

Edit: I had only skimmed through the OP when I posted this comment, turns out both the video and this article talk about the memory palace method! They diverge in the way it's applied though, with the AiP video associating digits with real life locations

4h agoHN ↗

Good read, even though I don't agree with the premise that memorizing 100 digits is a "superpower"

3h agoHN ↗

Livestreamer Extra Emily streamed herself using this approach to memorize the first 1000 digits of pi. It took her 11 hours.

3h agoHN ↗

Do all of these "provocative" visual imagery mappings work for those with aphantasia? Any anecdotal evidence or otherwise for that? Seems unlikely.

2h agoHN ↗

I memorized up to like 30 by singing the pi song over and over

1h agoHN ↗

I used the techniques described on this page to memorize pi. I've got 60 memorized where I can recall the digits by place. For example, the 40th decimal place is 1. In the table, it's the last digit of column A10. The phrase in A10 is ToP CaT, which translates to 1971, and the last 1 is the 40th digit.

https://www.ludism.org/mentat/PiMemorisation

43m agoHN ↗

I also read moonwalking with Einstein and it's such a great read that I committed to memorizing the first digits of Pi. Which I did using my own custom PAO system.

And then the payoff... When I would tell people I could recite the first 100 digits of Pi they would be interested and say I want to hear it. So I would start and after about 20 numbers they would just say I believe you and that would be it. So I let that skill lapse.

I think my new talent would be better spent memorizing my credit card numbers and driver's license ID.