Topics /

Math & Algorithms

The most popular blog posts about math & algorithms on Hacker News. 204 posts.

2026
152

Anatomy of a Lean proof for software engineers

Intro I recently worked through a problem from a theory of computation textbook that asked me to prove a property of a language using finite automata. The informal proof is a simple constructive proof where you build an automaton and show that it recognizes the language. This is kind of similar to program…

153

Unicode's transliteration rules are Turing-complete

Claim: as specified, the UTS #35 transliteration-rule language is Turing-complete. This is an exception in Unicode, where algorithms are deliberately bounded and always terminate. The specification defines a revisiting cursor with no rewrite limit. ICU's implementation implements a per-call cap, but the spec itself…

154

Learning Lean: Part 1

Motivation I’ve been captivated by the recent movement to popularize mathematics formalization through the Lean theorem prover, and this year I’m diving deeper into learning it. For those unfamiliar with this revolution, I highly recommend watching Kevin Buzzard’s talks on YouTube for an overview of why formal…

158

Dates That Don't Exist (2015)

In 1582, under the inter gravissimas papal bull, the Catholic world transitioned from the Julian Calendar to the Gregorian Calendar . This new calendar shortened the length of the year from 365.25 days to 365.2425 , a reduction of just 0.002% .

164

Rathbun's Operator

First, I’m a human typing this post. I’m not going to tell you who I am. Sure, many will say that is cowardly and fair, but I actually don’t think it would bring much value. What matters more is that I describe why, and what I did and didn’t do during the last two weeks or so with the OpenClaw agent I set up, known as…

165

All 23-Bit Still Lifes Are Glider Constructible

In the Game of Life, which still lifes can be produced by crashing gliders together? We’ve known for a few years that the answer cannot be “all of them”, because in 2022 Ilkka Törmä and Ville Salo found a patch of still life that, if it exists in the universe, must have existed since the beginning of time. And so…

173

The Shape of Inequalities

…symmetry isn’t just a preference for “pretty” shapes. Contents Introduction The HM-GM-AM-QM Inequality The two circles The Semicircle The Container The 3D container The Sum of Squares Inequality Nesbitt’s Inequality Conclusion Introduction While I was randomly browsing the web, I came across this nice picture: Roland…

175

Floating-Point Printing and Parsing Can Be Simple and Fast

A floating point number f has the form f = m · 2 e where m is called the mantissa and e is a signed integer exponent . We like to read numbers scaled by powers of ten, not two, so computers need algorithms to convert binary floating-point to and from decimal text. My 2011 post “ Floating Point to Decimal Conversion is…