# Quaternions

Boy did this end up being a large project! I first came across quaternions in the context of math, as a noteworthy number system extending the complex number. Many programmers and animators may have come across them as the bit of black magic within 3d graphics engines that makes descriptions of rotations and orientations "just work".

In either case, there is a common frustration with not being able to think about four dimensions, and hence not being able to visualize what quaternion multiplication is doing. The aim of this project is to give a way to concretely think about this multiplication within the confines of three-dimensions. The first installment is a 30-minute video, the bulk of which builds up the idea of stereographically projecting a 4d hypersphere into the entirety of 3d space.

The next part gets into how quaternions apply to 3d rotation. This is introduced with a short video on YouTube, but things get much more interesting after that...

The bulk of this lesson is actually hosted off YouTube, where thanks to the fantastic web development wizardly of Ben Eater it is done in the form of "explorable videos" that you can interact with during the narration. To accommodate anyone landing on the page of explorable videos without having watched the ~36 minutes of YouTube content above, some of the explorables are a bit redundant with the previous video. But a little repetition never hurts when we're dealing with a difficult topic.

# The hardest problem on the hardest test

"But Grant, the Putnam's not really the hardest test, and if you really want to find the hardest problem..."

Yeah, yeah, of course.  But if having an imprecise-but-not-totally-off-base title means this lesson reaches more people, great!

For one thing, it's just a very elegant solution well worth sharing.  But I'm always fascinated by the question of how one would find elegant solutions that just look like they were plucked out of thin air.  That is, rather than perpetuating the illusion of innate genius by just showing the solution, try shedding some light on what background/tactics might lead someone to the relevant insight.

More often than not, the answer has more to do with someone's past experiences than with the problem-solving techniques they used in the moment of the puzzle.  But every now and then there actually is a lesson to be taken away in terms of how you might systematically expose yourself to interesting insights, and the goal of this video is to share one such lesson.

# Collaboration with MinutePhysics

Henry Reich, who runs the channel MinutePhysics, has been incredibly helpful to me as I've started up the channel. He's offered mentorship and advice when I needed it, he gave some meaningful encouragement early on, and he's just that rare combination of very talented and very kind.

So when my friend Evan Miyazono, a newly minted physics Ph.D. from CalTech, mentioned that he'd be willing to help me out if ever I wanted to cover something in quantum mechanics, I thought it could be a good opportunity to actually work with Henry in creating something together. Fast forward a few months (which involved one particularly fun weekend in Montana when Evan, Henry and I all got together with a few other physics folks), and we have two videos for you.

The one on my channel is meant to lay down some of the fundamental intuitions for the math behind quantum, without giving too much of a "look at how crazy quantum is!" vibe. At its heart, a large portion of quantum mechanics is about wave mechanics. While the field certainly has some strange components, some of the things that people often think of as weird (superposition, uncertainty principle, etc.) are ideas that come up very naturally in the context of waves. It's just that the meaning of these waves in the context of quantum gives these ideas some unusual physical manifestations.

The approach I decided on was to spend most of the video just talking about classical electromagnetic waves, giving a feel for the meaning of superposition and polarity in that context. Once that's laid down, it's more meaningful to talk about what actually becomes different in quantum mechanics. What I love is that the formulas for describing polarization barely change, it's just that the constraint that the energy of light comes in discrete little chunks gives a slight twist to the physical manifestation of this math.

The other video, which we put on MinutePhysics, is about Bell's theorem. This is a really clever experimental result, with very deep implications. The entire collaboration centered around this project, really, since it's a topic that Henry had wanted to do for a while, and one which I found thoroughly captivating when Evan first told me about it. I hope you enjoy!

# A trick to visualizing higher dimensions

Perhaps it's worth saying a few words on why those interested in math care about higher dimensions.  Why care about 20-dimensional space when the world we live in is not 20-dimensional?  Broadly speaking, spatial reasoning is not just useful for describing the physical world, it's a sort of problem-solving tactic for any scenario where you want to think about collections of things (like lists of numbers) as individual points of some object.

For example, viewers of the "Who cares about topology" video will remember how nice it was to associate pairs of points on a loop with individual points on a Mobius strip.  But this is only associating collections of two things with individual points.  As the relevant collection gets larger, the corresponding object is harder to hold in one's mind, since it lives in a higher dimensional space.  For example, there is something analogous to a Mobius strip that represents unordered quintuplets of points on a loop, but seeing it would require being able to visualize 6 dimensions.  That doesn't stop mathematicians from working with such objects, though, it's just that the work becomes a bit more abstruse.

The tactic I provide in this video is not some magic make-you-feel-like-neo-from-the-matrix visual that lets you hold a full high-dimensional object in your head.  Instead, its main function is to emphasize that what we really mean by "a point in n dimensions" is "a list of n real numbers", and moreover that it can still be fruitful to think visually about that idea even when you can't conceptual the list of numbers as an individual point in space as we can for 1, 2 and 3 dimensions.

# Ever wonder how Bitcoin (and other cryptocurrencies) actually work?

I don't know about you, but I used to think of the prefix "crypto" as applying mainly to secret messages.   One of the neatest takeaways from the study of cryptography as a whole is just how much more widely applicable the mathematical tools at its core are.  Really this prefix serves more as an antonym for "trust" than it does as a synonym for "secrecy".  One of the first times this really sank in for me was upon reading the Bitcoin white paper.

I decided to cover this topic now partially in light of the recent rise in attention towards other cryptocurrencies; a level of attention which is not always accompanied with a real understanding of what these currencies actually are.  While there are a handful of really good explanations of the blockchain I've seen out there, it seems that the more prominent search results one will get when trying to learn about them lean too heavily on vague analogies with gold-mining, and the more technical ones don't always motivate why the system works the way that it does. (An excellent exception, by the way, is this post by Michael Nielsen).

Here I try to frame things in the context of you stumbling into inventing your own cryptocurrency, which hopefully helps clarify why the various technical constructs involved come into play the way that they do.

The supplemented video here was something I originally had as part of the script of the main video to illustrate what "infeasible" means in the context of digital signatures and cryptographic hash functions.  It's too peripheral to justify the amount of time it would add to the main video, but I had fun thinking through the example, so it was pulled out into an isolated footnote.

# All possible pythagorean triples, visualized

This is kind of a fun one.  The first time I ever learned about the formula for generating pythagorean triples, it was in the context of stereographic projections onto the unit circle with rational slopes.  The visual intuition of that is nice, but the actual algebra to work out a formula is quite a mess, and (at least for me) the final result is easy to forget.

However, you can land on that same general formula just by squaring complex numbers with integer coordinates, which lends itself to a different visualization entirely.  I still talk about the projections onto the unit circle, as it makes for a very nice little proof at the end, but I hope this offers a different perspective even to those familiar with the question of finding pythagorean triples.

# Pi hiding in prime regularities

There are only so many times that one can use the phrase "This is my favorite piece of math" before it starts to lose meaning.  So instead I'll restrain myself and say this is my favorite piece of number theory.

A surprising number of formulas relate things the Riemann zeta function, as well as some of its cousins, to pi.  Most notably the values of zeta on positive even integers.  Here I explain one example from this family, where it's most clear how circles are involved.  What I think is fascinating is that you could set out to find a formula for pi by counting lattice points in the way described here, with no intention of talking about prime number or multiplicative functions or any of that, and moreover the final formula itself seems to be clean of primes, but nevertheless the natural course of exploration seems to have this gravitational pull towards patterns in primes.

The fact that similar formulas arise from the zeta function itself, which is known to encode the information regarding the distribution of primes, is one more piece of evidence that this connection is not just a coincidence.