Topics /

Math & Algorithms

The most popular blog posts about math & algorithms on Hacker News. 2,851 posts.

Any year
843

How Tail Call Optimization Works

Most undergraduate computer sciences courses teach students about tail call optimization (TCO) , and even if you don't have a formal computer science background the concept is talked about enough that you might be familiar with it anyway, especially if you've ever done any functional programming. However, I think the…

845

Tritone Substitutions

A ‘tritone substitution’ is a popular trick for making your music sound more sophisticated. I’ll show you a couple of videos with lots of examples. But since I’m mathematici…

846

Upper stage impacting the moon on 2026 August 5

On 2026 August 5, within a few minutes of 06:35 UTC, an upper stage (section) of a rocket used for a lunar mission will hit the moon. This may be of some (probably minor) scientific interest, and we may learn some things from it. It doesn't present any danger to anyone, though it does highlight a certain carelessness…

849

A High-Level Technical Overview of Homomorphic Encryption

About two years ago, I switched teams at Google to focus on fully homomorphic encryption (abbreviated FHE, or sometimes HE). Since then I’ve got to work on a lot of interesting projects, learning along the way about post-quantum cryptography, compiler design, and the ins and outs of fully homomorphic encryption. If…

853

The Riemann Hypothesis Says 5040 Is the Last

Note: These pages make extensive use of the latest XHTML and CSS Standards . They ought to look great in any standards-compliant modern browser. Unfortunately, they will probably look horrible in older browsers, like Netscape 4.x and IE 4.x. Moreover, many posts use MathML, which is, currently only supported in…

855

Secrets of smooth Béziers

I haven’t posted here much lately, and I admit, it’s because I’ve gotten sidetracked thinking about curves again. I did my PhD thesis on curves, so spent years thinking about them, then put that on hold for a while, aside from some work in crunching font file sizes down.

859

Category Theory Illustrated – Sets

Ready, set , begin… (you don’t know how hard I tried to resist to making that pun). We begin our inquiry with the theory of sets. Set theory and category theory share many similarities. We can view category theory as a generalization of set theory. That is, it’s meant to describe the same thing as set theory…

862

Symmetry in Chaos

The following is based upon systems of equations found in "Symmetry in Chaos, A Search for Pattern in Mathematics, Art, and Nature" (the second edition) by Michael Field and Martin Golubitsky. They ask the question whether there are aperiodic chaotic attractors that generate symmetric patterns? Can there be order…

867

An Introduction to Cache-Oblivious Data Structures

If you read my recent post about Postgres you may have noted that Postgres operates primarily with fixed-size blocks of memory called “pages.” By default, Postgres pages are 8KB. This number is tuned to match operating system page sizes which are tuned to match hardware cache sizes. If you were to run Postgres on…

869

Cache Oblivious Algorithms

Cache-Oblivious Algorithms Cache-oblivious algorithms seemed incredible to me when I first heard about it in 6.854 (Advanced Algorithms). It’s relatively straightforward to imagine algorithms that utilizes information about page size $B$ and cache size $M$ to create efficient data structures. However, cache-oblivious…