Topics /

Math & Algorithms

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

2023
34

BB(3, 3) is Hard

I’m excited to share a 3 state, 3 symbol Turing Machine that cannot be proven to halt or not (when starting on a blank tape) without solving a Collatz-like problem. Therefore, solving the \(BB(3, 3)\) problem is at least as hard as solving this Collatz-like problem, a class of problem for which Paul Erdős famously…

36

Estimating square roots in your head

Imagine we want to compute the square root of a number n n n . The basic idea of Heron’s method , named after the mathematician and engineer, Heron of Alexandria, is to find a number g g g that is close to n \sqrt{n} n ​ and to then average that with the number n / g n/g n / g , which corrects for the fact that g g g…

45

Breaking RSA with a quantum computer?

A group of Chinese researchers have just published a paper claiming that they can—although they have not yet done so—break 2048-bit RSA. This is something to take seriously. It might not be correct, but it’s not obviously wrong. We have long known from Shor’s algorithm that factoring with a quantum computer is easy…

48

Lerp

Lerp is the nickname for Linear Interpolation between two points. It's a fairly simple effect to implement but can really improve the look of your animations if you're moving an object from a point A to point B.

56

How far can you jump from a swing?

In this post I derive the physics of pumping a swing and the physics of jumping from a swing. Then, using both pieces I compute the optimal strategy of jumping from a swing to maximize the traveled distance. I propose this game as a new Olympic sport.

60

Is the reversal curse in LLMs real?

A recent paper The Reversal Curse points out an apparent failure in large large language models like GPT-4. From the abstract: We expose a surprising failure of generalization in auto-regressive large language models (LLMs). If a model is