New
The latest blog posts to take off on Hacker News. 2,391 posts.
Apple’s M1 processor and the full 128-bit integer product
If I multiply two 64-bit integers (having values in [0, 264)), the product requires 128 bits. Intel and AMD processors (x64) can compute the full (128-bit) product of two 64-bit integers using a single instruction (mul). ARM processors, such as those found in your mobile phone, require two instructions to achieve the…
Euler's Fizzbuzz (2020)
FizzBuzz is a common coding problem asked in technical screenings or interviews. It goes something like this:
Fitting Cubic Bézier Curves
Blog of Raph Levien.
Trapped priors as a basic problem of rationality
P(A|B) = [P(A)*P(B|A)]/P(B), all the rest is commentary.
No, RSA Is Not Broken
I have been seeing this paper by cryptographer Peter Schnorr making the rounds: “Fast Factoring Integers by SVP Algorithms.” It describes a new factoring method, and its abstract ends with the provocative sentence: “This destroys the RSA cryptosystem.” It does not. At best, it’s an improvement in factoring—and I’m not…
The Most-Used Mathematical Algorithm Idea in History (2016)
Stephen Wolfram shares a glimpse into his conversations with Solomon Golomb, developments on shift registers, polyominoes, scientific contributions.
Review: The Book of Why
The Book of Why: The New Science of Cause and Effect is a collaborative effort aimed at a general audience by Judea Pearl , a professor of computer science at UCLA, and Dana Mackenzie , a science writer. As a medical student with a laughably poor formal education in statistics, I believe I qualify as a card-carrying…
How does your programming language handle “minus zero” (-0.0)?
The ubiquitous IEEE floating-point standard defines two numbers to represent zero, the positive and the negative zeros. You also have the positive and negative infinity. If you compute the inverse of the positive zero, you get the positive infinity. If you compute the inverse of the negative zero, you get the negative…
Did Schnorr destroy RSA? Show me the factors
Schnorr has claimed new factoring methods that “destroy RSA”. This should be easy to demonstrate with well known challenges.
What’s Wrong with “Multiplication Is Repeated Addition”? (2008)
[Photo by Alejandra Mavroski.] Myrtle called it The article that launched a thousand posts…, and counting comments on this and several other blogs, that may not be too much of an exaggeration…
An Introduction to Hierarchical Modeling
A visual explanation of multi-level modeling
Translating My Z3 Tutorial to Coq
A blog about life, programming, math, logic, and physics.
Ancient Babylonian Algorithms: The Earliest Programs
An interactive, illustrated timeline of historic moments in humankind's quest for information. With annotations by Jeremy Norman.
Formalising Mathematics: An Introduction
An introduction to the TCC course “Formalising Mathematics”
Finite State Machines
To infinity and beyond!
Cleaner parallel curves with Euler spirals
Blog of Raph Levien.
Functorio
You might have heard people say that functional programming is more academic, and real engineering is done in imperative style. I’m going to show you that real engineering is functional, and …
Implementing the Elo Rating System (2020)
In this article we’ll look at how to implement the Elo rating system in code.
Foldable Words
Packing up the household for a recent move, I was delving into shoeboxes, photo albums, and file folders that had not been opened in decades. One of my discoveries, found in an envelope at the back of a file drawer, was the paper sleeve from a drinking straw, imprinted with a saccharine message:
Gradient Descent Models Are Kernel Machines
This paper shows that models which result from gradient descent training (e.g., deep neural nets) can be expressed as a weighted sum of simi...
RNA Memory Hypothesis
There’s an old theory that memory is actually encoded in part in RNA. The argument is pretty simple: there’s no obvious way for all that sensory data to be captured in synapses as long …
Knuth-Morris-Pratt string-searching algorithm: DFA-less version
You see, there are two memory accesses per one character of the input string (at average). Hence, the total number of all memory accesses can be len*2 at worst.
An interactive review of the Oklab perceptual color space
Blog of Raph Levien.
That XOR Trick (2020)
There are a whole bunch of popular interview questions that can be solved in one of two ways: Either using common data structures and algorithms in a sensible manner, or by using some properties of...
Donut.c Without a Math Library
My little donut.c has been making the rounds again, after being featured in a couple YouTube videos (e.g., Lex Fridman and Joma Tech ). If I had known how much attention this code would get over the years, I would have spent more time on it.