Doing First Grade Math in Rust's Type System
MIT student who enjoys performance engineering, compilers, and creating unconventional code
Topics /
The most popular blog posts about math & algorithms on Hacker News. 266 posts.
MIT student who enjoys performance engineering, compilers, and creating unconventional code
February 24, 2020. The computational power of a humble napkin is awesome. I discuss three napkin algorithms — dimensional analysis, Fermi estimates, and random walks — and use them to figure out why rain falls, the length of the E. coli genome, and the mass of a proton, among other things. These examples suggest a…
I first encountered Jenkins in 2007 while contributing to the Apache Nutch project. It was called Hudson back then. The nightly builds for the project ran on Hudson at that time. I remember sifting through my emails and reviewing build result notifications to keep an eye on the patches that got merged into the trunk…
A brief numerical and graphical check on a 3Blue1Brown video.
floating-points-between-zero-and-one - Chad Nauseam Home
Suppose you have an array of floating-point numbers, and wish to sum them. You might naively think you can simply add them, e.g. in Rust:
Follow me on Bluesky! A Log-Structured Merge tree, or LSM, is a popular data structure for storage engines. It’s what is used by RocksDB, which is sort of...
When I started learning about loss functions, I could always understand the intuition behind them. For example, the mean squared error (MSE) for regression seemed logical—penalizing large deviations from the ground-truth makes sense. But one thing always bothered me: I could never come up with those loss functions on…
A real explanation of discrete Fourier transform (DFT, FFT), discrete cosine transform (DCT), and their inverses.
Interactive Mathematical Applets and Animations
My currently understanding of types
A deep dive into the Probabilistic B-tree or Prolly Tree data structure including examples. Prolly Trees are used to create version controlled databases.
This is Bob. And I’d like to know the best way for us to code a bunch of models in JAX to use to evaluate parallel algorithms including normalizing flows. I’m going to dump out my current thinking, but I’m really hoping to get feedback from experts on the best way to do this without starting a flame war in the…
It's pretty easy to imagine how to represent relational algebra expressions as a tree—they are already structurally rooted trees where each operator has its...
Hello there. This is an open access book entitled: “Romeo and Julia, where Romeo is Basic Statistics”. So I guess it’s gonna be about a programming language named Julia and its usage for basic statistics.
I’ve been on a weird kick lately making images using Excel. [Here’s one post. I hope to post more soon.] If you add a background color to each cell in a spreadsheet and resize the cell …
An interactive introduction to Turing machines, the theoretical foundation of modern computing.
It gives my brain a pleasant thrum to learn new mathematics which mimics the algebra I learned in middle school. Basically this means that the new system has operations with properties that match those of regular numbers as much as possible. Two pretty important operations are addition and multiplication with the…
From the highly eclectic blog of Mark Dominus
Bézier curves are widely used for defining vector graphics. They are basically polynomial parametric curves, but given in the Bernstein basis, which enables us to define the curve using control points. The first and last control point define the start and endpoint of the curves, the intermediate control points kind of…
if $n \equiv 0 \, (\text{mod}\, 2)$ the ant turns 90º clockwise, else the ant turns 90º counter-clockwise. On both accounts, the state of the cell is flipped and the ant moves forward one unit. This is repeated until $n = 1$.
In 1890 Giuseppe Peano discovered a square-filling curve , and a year later David Hilbert published his variation . In those days people did not waste readers’ attention with dribble – Peano explained it all on 3 pages, and Hilbert on just 2 pages, with a picture!
“Although Abel shared with many mathematicians a complete lack of musical talent, I will not sound absurd if I compare his kind of productivity and his personality with Mozart’s.” — Felix Klein
I wanted to point someone to a short explanation of this today and noticed, with some surprise, that I couldn’t find something concise within 5 minutes of googling. So it seems worth writing …
The existence claim for the singular value decomposition (SVD) is quite strong: “Every matrix is diagonal, provided one uses the proper bases for the domain and range spaces” (Trefethen & Bau III, 1997) . MIT professor Gilbert Strang has a wonderful lecture on the SVD, and he includes an existence proof for the SVD…
Conway’s Game of Life is one of the most popular and iconic cellular automata. It is so famous that googling it loads up a working simulation right in your browser! The rules for the Game o…