Bresenham's Circle Drawing Algorithm (2021)
Once upon a time I was given the following problem for a technical programming interview:
The latest blog posts to take off on Hacker News. 2,391 posts.
Once upon a time I was given the following problem for a technical programming interview:
floating-points-between-zero-and-one - Chad Nauseam Home
I recently learned an interesting fact about Fibonacci numbers while watching a random number theory video on YouTube. Fibonacci numbers can be used to approximately convert from miles to kilometers and back. Here is how. Take two consecutive Fibonacci numbers, for example 5 and 8. And you're done converting. No...
EDIT: Be warned that this post is angry. If you’re easily offended when someone goes on a rant, then leave now because I’m very unforgiving in several places below. The tone of my writing is unusually harsh, but the people whose work I’m talking about deserve it, and here’s why. Even though I had been working with…
Visualizations and techniques for different maze generation algorithms.
Stephen Wolfram explores minimal models and their visualizations, aiming to explain the underneath functionality of neural nets and ultimately machine learning.
Pathfinding applied to the software solution domain
1) Foundational math. 2) Classical machine learning. 3) Deep learning. 4) Cutting-edge machine learning.
“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
Personal website of Dr. Peder M. Isager
Efficient filtering of polygonal shapes with closed-form solutions based on Green’s theorem with piecewise-polynomial filters (e.g. box/bilinear/bicubic).
Sweep-and-prune is my go-to algorithm when I want to quickly implement collision detection for a game. I think it’s an awesome and elegant algorithm, so I wrote a post about it.
About eight years ago, I was playing a game of Codenames where the game state was such that our team would almost certainly lose if we didn't correctly guess all of our remaining words on our turn. From the given clue, we were unable to do this. Although the game is meant to be a word guessing game based on word…
I’ve been reading Pearl’s Causal Inference in Statistics , and one of the exercises poses this problem:
When do music stars achieve fame, and how long does fame typically last?
We build complex mathematical formulas bottom-up using pure lambda calculus. Includes instructions of how to translate Taylor series and other approximations to lambda terms.
A family of infinite sums that evaluate to rational numbers, sometimes integers, and and effective algorithm for finding the sum.
Programmers on the internet often use Turing-completeness terminology. Typically, not being Turing-complete is extolled as a virtue or even a requirement in specific domains. I claim that most such discussions are misinformed --- that not being Turing complete doesn't actually mean what folks want it to mean, and is…
This is basically a compilation of the lecture notes I wrote when teaching 36-401, Modern Regression, in fall 2015 . I offer it here on the chance that it might be of interest to those learning, or teaching, linear regression. There's no shortage of resources on that, but I have tried to present the subject as though…
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…
A traditional subjective Bayesian will assume a data generating distribution (aka a likelihood when viewed as a function of the parameters). Then, conditional on this assumption, they encode their prior beliefs as a prior distribution over parameters. After this, they turn the crank on posterior inference and don’t…
Finding the median in a list seems like a trivial problem, but doing so in linear time turns out to be tricky. In this post I’m going to walk through one of my favorite algorithms, the median-of-medians approach to find the median of a list in deterministic linear time. Although proving that this algorithm runs in…
A guide on how to generate sudokus of any difficulty.
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!
Recently one of my colleagues was reading Alan Turing’s groundbreaking 1936 article “On Computable Numbers with an Application to the Entscheidungsproblem.” This is the article in…
I wrote a little book about entropy; here’s the current draft: • What is Entropy? If you see typos and other mistakes, or have trouble understanding things, please let me know! An altern…
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…
Hugo Hadfield - Cross stack robotics engineer and computer vision researcher specializing in deep learning, sensor fusion, geometric algebra and applications in self-driving cars and robotic manipulation.