Sam Hocevar
thenumb.at · Personal blog · on HN since 2022
The blog of a graphics programmer with math-heavy articles on differentiable programming, Monte Carlo rendering, rotations and hash tables.
What HN saysHN commenters link it as a clear explanation of functions as vectors, with proofs, and discuss its open addressing article in terms of hashing.
15HN people shared it
6linked it in comments
19stories submitted
1.1Kstory points
10 months agolast shared
2022people per year2026
Most-shared posts
- 1Differentiable programming from scratch4 people · 309 points · first shared 2022 · 107 comments on HN
- 2Functions Are Vectors (2023)4 people · 235 points · first shared 2023 · 127 comments on HN
- 3Exponentially Better Rotations (2022)3 people · 285 points · first shared 2024 · 63 comments on HN
- 4Monte Carlo Crash Course: Quasi-Monte Carlo2 people · 147 points · first shared 2025 · 14 comments on HN
- 5Optimizing Open Addressing2 people · 4 points · first shared 2023 · discussion on HN
- 6Monte Carlo Crash Course: Sampling1 people · 108 points · first shared 2025 · 20 comments on HN
- 7Monte Carlo Crash Course: Rendering1 people · 12 points · first shared 2025 · discussion on HN
- 8Oxidizing C++1 people · 5 points · first shared 2024 · 1 comments on HN
- 9Exponentially Better Integration1 people · 4 points · first shared 2025 · discussion on HN
- 10Exploring Neural Graphics Primitives1 people · 3 points · first shared 2022 · discussion on HN
- 11Graphics Blogroll1 people · 2 points · first shared 2023 · 1 comments on HN
- 12Spherical Integration. Or, where does that come from?1 people · 1 points · first shared 2023 · discussion on HN
- 13Homepage1 people · first shared 2026
What HN people wrote when they linked it
vlmutolo · 2024-03-01
This may be more about the indexing strategy than the hash function. Meaning: once we have the hash(es), how do we decide what index to use for the key?
Open-addressing schemes like linear probing, quadratic probing, certain variants of Robinhood hashing (which is kind of on a different axis anyway) commonly have 50–70% expected space efficiency. Performance is bad above 90%.
But Cuckoo hash tables can get above 90% with great lookup performance (non-amortized constant time) and decent insert performance. Insert performance tends to suffer closer to 100%.
Whether or not cuckoo hash tables qualify as “open addressing” will depend on the implementation, but the main point is that the addressing/indexing strategy mainly determines the operable “load factor” of the hash table.
This is a great article on open addressing schemes (including cuckoo):
https://thenumb.at/Hashtables/
TheNumbat · 2026-01-14
Tainnor · 2025-07-07
I think you are confused about the analogies at the beginning at the article (although there is nothing technically wrong about them).
Here's the definition of a vector space which agrees with the one everyone in mathematics use: https://thenumb.at/Functions-are-Vectors/#vector-spaces
From this it's fairly easy to prove (and done in the article) that the set of all functions R->R is a vector space.
gizmo686 · 2025-07-06
https://thenumb.at/Functions-are-Vectors/#proofs
It's not a particularly interesting proof, but the author does prove that real valued functions are vectors. The bulk of the article is less about proofs, and more about showing how the above result is useful.
lynaghk · 2025-05-05
For my application I need just the translations and Euler angles. The range of poses is mechanically constrained so I don't have to worry about gimbal lock. But yeah, my limited understanding matches yours that other parameterizations are more useful in general contexts.
This post and interactive explanations have been on my backlog to read and internalize: https://thenumb.at/Exponential-Rotations/
(Also: Thanks for pointing out the typo, I just deployed a fix.)
myhf · 2024-09-23
Differentiable Programming from Scratch
https://thenumb.at/Autodiff/