Rolling up the Bloch Ball

In an earlier post, we discussed how to do quantum mechanics for the simplest possible quantum system, a single qubit, using expectation values. What if we want to apply quantum theory to a bigger system, like multiple qubits put together? This is where the standard mathematical language of the subject starts to pay off. It is possible to keep working with expectation values the way we were, and in some applications it is even beneficial. However, expressing what the valid set of preparations looks like is difficult to do without bringing in more of the linear algebra.

I’ve taught this to college students, after first reviewing how complex numbers work and some basics about how to manipulate matrices — adding them, multiplying them, taking the trace and the determinant, what eigenvalues and eigenvectors are.

For our own purposes, our next step will be to develop the framework in which we can consider multiple qubits together. It might not seem obvious now, but a good way to make progress is to combine our three expected values $(x,y,z)$ into a matrix, like so:
$$ \rho = \frac{1}{2} \begin{pmatrix} 1 + z & x – iy \\ x + iy & 1 – z \end{pmatrix} \, . $$
This matrix has some nice properties of the sort that we can generalize to bigger matrices. For example, its trace is 1, which feels kind of like how a list of probabilities sums up to 1. Meanwhile, the determinant is the pleasingly Pythagorean quantity
$$ \det\rho = \frac{1}{4}(1 – x^2 – y^2 – z^2) \, . $$
This will be nonnegative for all the valid preparation points. So, the product of the two eigenvalues of $\rho$ will be positive for every point in the interior; we can only get a zero eigenvalue by picking a point on the surface. Using the trace and the determinant, we can find the eigenvalues thanks to a nifty application of the quadratic formula:
$$ \lambda_\pm = \frac{\mathrm{tr}\rho \pm \sqrt{(\mathrm{tr}\rho)^2 – 4\det\rho}}{2} = \frac{1}{2}(1 \pm \sqrt{x^2 + y^2 + z^2}) \, . $$
And indeed, this will always give us positive real numbers, except on the surface of the Bloch ball where the $\lambda_+$ solution is 1 while the $\lambda_-$ solution is 0. Requiring that a matrix’s eigenvalues be nonnegative is another property we can generalize.

Another interesting thing happens if we take the square of $\rho$:
$$ \rho^2 = \frac{1}{4}
\begin{pmatrix} 1 + x^2 + y^2 + z^2 + 2z
& 2x – 2iy \\
2x + 2iy
& 1 + x^2 + y^2 + z^2 – 2z
\end{pmatrix} \, . $$
If the point $(x,y,z)$ is on the surface of the sphere, then $\rho^2 = \rho$. This will turn out to be a way to characterize the extreme elements in our set of valid preparations, no matter how big we make our matrices.

This gets us almost to the point of being able to do the quantum math for the parable of the muffins.

Friends Don’t Let Friends Learn Probability from Yudkowsky

Suppose I said, “I have this clock that I really like. It’s a very nice clock. So, I am going to measure everything I can in terms of the times registered on this clock.”

“OK,” you might say, while wondering what the big deal is.

“In fact, I am going to measure all speeds as the time it takes to travel a standard unit of distance.”

“Uh, hold on.”

“And this means that, contrary to what you learned in Big University, zero is not a speed! Because the right way to think of speed is the time it takes to travel 1 standard distance unit, and an object that never moves never travels.”

Now, you might try to argue with me. You could try to point out all the things that my screwy definition would break. (For starters, I am throwing out everything science has learned about inertia.) You could try showing examples where scientists I have praised, like Feynman or whoever, speak of “a speed equal to zero”. When all that goes nowhere and I dig in further with every reply, you might justifiably conclude that I am high on my own supply, in love with my own status as an iconoclast. Because that is my real motivation, neither equations nor expertise will sway me.
Continue reading Friends Don’t Let Friends Learn Probability from Yudkowsky

Calculus Made Easy

My way of taking a break from the … everything of everything has been to try my hand at an updated edition of Silvanus P. Thompson’s classic text, Calculus Made Easy (1914). The book deserves its reputation and holds up quite well overall; I have seen folks who aren’t at all “math people” be charmed by his writing style. However, it is outdated in places, with the occasional antiquated turn of phrase or poorly-aged example. Fortunately, Project Gutenberg has a transcribed version including a ZIP file of the LaTeX source code and auxiliary files. So, I went for a minimal update, fixing the archaisms that pose noticeable stumbling blocks. The result is now available as a PDF document and as source code.

The one thing in Thompson’s presentation that I didn’t particularly like is how he introduces derivatives of trig functions. It presumes that the reader has a lot of trig identities in their back pocket, and it makes a simplification that is hard to justify without going into limits, a topic that Thompson doesn’t explicitly teach. I’ve tried my hand at a replacement that appeals to the way he does teach.

Further modifications may come as people apprise me of all the things I missed. I do wish to keep it short and sweet, rather than adding multiple new chapters.

In Re Vopson’s “Mass-Energy-Information Equivalence” and “Infodynamics”

Time was, when I saw nonsensical pseudo-physics getting uncritical media boosts, I would write blog posts about it. Now, I see “A New Law of Physics Could Support the Idea We’re Living In a Simulation” and just go, “Shut up, fuck you.” I wasted more than enough of my short time on this Earth reading incoherent self-indulgence to see if there was something, anything under the clickbait, and in my professional opinion, the guy who wrote his thesis on a bathroom wall, starting with “Love is blind” and concluding with “Ray Charles is God”, made a better contribution in every respect.

As I have written before, it is very difficult to provide substantive criticism of a “theory” that has no substance. I could point to individual things that make no sense, but the people who care don’t need my help, and the people who don’t won’t be convinced by anything I say. (“I asked ChatGPT to summarize the paper, and I found the results quite inspirational!”) I could try to provide a little media literacy, like feel free to ignore any science “news” that’s just a press release from the guy who made it up. But again, if you’re thirsty for something else, that will hardly satisfy. (“Reality is all on the blockchain, buy GameStop!”)

For the Record

I left my Twitter account sitting disused and locked, on the off chance that one day I would have a use for it that I couldn’t foresee at the time. Today, after months of that not happening, I finally got around to deactivating it. Anything from “@blakestacey” won’t be from me.

The Parable of the Muffins

Let’s try to make a profound statement about reality by thinking hard about baked goods.

I promise this is going somewhere.

A certain bakery has a special deal on muffins. They sell mystery boxes for those who like to live dangerously: mix-and-match sets of three muffins apiece. Each day, Alice, Bob and Charlie buy a mystery box together, and each day, Alice, Bob and Charlie take one muffin apiece back to their respective laboratories for analysis. They each have two testing devices — say, a device that can test whether a muffin is positive for dairy, and another device that can test whether it is positive for tree nuts. We’ll call these $X$ tests and $Y$ tests for short. Each day, Alice chooses either to do an $X$ test or a $Y$ test. Bob likewise chooses, independently of Alice, and so does Charlie. Importantly, each muffin can only be tested once. Maybe the test destroys the muffin, or maybe it takes so long to do one that they eat their muffins immediately afterward. Whatever the rationale, one test per muffin — that’s a rule of the parable.

We can write what they choose to do in a compact way. For example, if all three of them choose to do the $X$ test on their respective muffins, we’ll write $A_X B_X C_X$. If Bob and Charlie choose to do the $Y$ test but Alice goes instead with the $X$ test, we’ll write $A_X B_Y C_Y$. And so on. We can also write the results compactly, using $+1$ to stand for a positive result and $-1$ to stand for a negative one. (We could also record the outcomes with zeros and ones, or with trues and falses, greens and blues, etc. Using $+1$ and $-1$ is just a notation that will turn out to be helpful in a moment.) So, for example, if Alice chooses $Y$, Bob chooses $X$ and Charlie goes with $Y$, the results might be $(+1, -1, -1)$. Or they might be $(+1, +1, +1)$, or perhaps $(-1, +1, -1)$.

Over many days of muffin investigation, comparing their notes, they find a dependable pattern. Whenever two of them choose to do the $Y$ test, then the product of their results is always $+1$. The specific outcome varies randomly from day to day, but there’s never only one $-1$, and they never get all three results being $-1$. From this pattern, they can draw a couple conclusions. First, once two of them obtain their results, the result of the third is predictable. Let’s say their choices are $A_Y B_X C_Y$, as in the previous example, and both Alice and Bob get the result $+1$. Then we can predict that Charlie will get $+1$, because that’s the only way the product of the three numbers can be $+1$. Or, suppose their choices are $A_Y B_Y C_X$, and both Bob and Charlie get a $-1$. The two of them report their results and wait for Alice. Knowing Bob and Charlie’s results, we can predict that Alice will report a $+1$ outcome, because that’s the only way the product of the three outcomes is $+1$. A minus times a minus makes a plus, and so a third minus would spoil the plus.

If we had used a different notation for the outcomes, like “green” and “blue” instead of $+1$ and $-1$, then we could express this pattern by saying that whenever two of them choose to do the $Y$ test, an even number of the results will be blue.

Now, we deduce something else from the pattern. We can make a prediction about what happens under very different conditions. What about the days when all three choose to measure $X$?
Continue reading The Parable of the Muffins

The Lunn–Schrödinger Equation?

Wikipedia claims that Arthur C. Lunn discovered what we now call the Schrödinger equation some years before Schrödinger. I wonder if there is more to say about this than what the references cited there provide (they have the feel of being faithful recollections, but are light on specifics).

In a 1964 interview, the physicist Karl Darrow calls the story “impossible to check”. And in another interview, Robert Mulliken (not to be confused with Robert Millikan) shares the story of Lunn having “sent a paper to the Physical Review which was turned down and which anticipated the quantum mechanics”. Mulliken heard the story from the physical chemist William Draper Harkins. Similarly, Leonard Loeb told Thomas Kuhn that Lunn “was probably a misunderstood genius, and who was completely frustrated, because his one great paper with his one great idea was turned down by a journal”.

Lunn did apparently try to present what sounds like a grandiose paper (“Relativity, quantum theory, and the wave theories of light and gravitation”) at the American Physical Society meeting in April 1923, but his paper was only “read by title”. The abstract ran as follows:

This paper is a preliminary report on a theory originally sought in order to meet the recognized need for a reconciliation between wave theory and quantum phenomena; its scope of adaptation proves to be quite wide. It includes (1) a wave theory of gravitation in quantitative connection with optical, electronic, and radioactivity data; (2) a related general suggestion of a theory connecting molecular properties with properties of matter in bulk; (3) alternatives for some of the current features in the theories of atomic structure; (4) a new interpretation and deduction of formulas for series and band spectra, using in lieu of the quantum condition a substitute directly related to long familiar physical notions; (5) a modification of Lagrangian dynamics which promises to be of service in the study of complex atomic and molecular structures; (6) a non-quantum theory of specific heat and black radiation. Results so far reached deal mostly with problems approachable by elementary methods or approximate computations. A set of formulas has been obtained which yield computation of the electron constants $e$, $h$, $m$ and mass ratios, assuming from observation only the Rydberg constant, velocity of light, gravitation constant, and Faraday constant, with results in each case in practical agreement with measured values.

Darrow says, “I know that in 1924 he wanted to give a twenty or a thirty minute paper before the American Physical Society in Washington, but then authorities of the Society refused him more than ten minutes”.

Lunn’s abstract in the 1924 proceedings has a similar explain-everything atmosphere:

Relativity, the quantum phenomena, and a kinematic geometry of matter and radiation. A. C. LUNN, University of Chicago. The theory indicated in an earlier paper (Phys. Rev. 21, 711, 1923), has since been developed, extended in scope, and so ordered as to permit of treatment as a deductive space-time geometry. It unites the treatment of the quantum phenomena with the rest of physical theory in a way that yields to illustration by familiar physical images. It resolves into matters of choice a number of hitherto controversial alternatives in the interpretation of phenomena, and allows freedom of use of a range of concrete types of representation including many other concepts commonly discarded. Among special topics more recently found to affiliate with the scheme may be mentioned the Stark and Zeeman effects and fine structure, resonance potentials, and the intensity and distribution of general x-radiation. Improvements have been made in the setting of the formulas connecting $e$, $h$, and $m$ with pre-electron data. A program has emerged for the foundation of a trial mathematical chemistry by determination of types of atoms, valence, number of isotopes, atomic weights, and spectrum levels.

I can easily imagine a paper with that attempted scope being incomprehensible to whoever had the task of evaluating it, and so any really good morsels within it would have been lost.

UPDATE (4 November): I wrote to the Physical Review offices on the chance that they had more information and received this reply from Robert Garisto, the Managing Editor of Physical Review Letters.

Thank you for your query. Our records from the early 20th century are fragmentary. I am not sure if we have any from before 1930, much less a complete set that could answer your question.

But I see that Arthur C. Lunn published 7 papers in the Physical Review from 1912-1922. So he was a known author to the editors. Those were different times, and while it is possible that he submitted a paper that was rejected and never published elsewhere, for what it’s worth, it strikes me as unlikely.

Friends Don’t Let Friends Learn Physics From Yudkowsky

With the demise of Reddit, we have lost /r/SneerClub, the Internet’s hot spot for mocking those who proclaim allegiance to capital-R Rationality and related ideologies like longtermism. Somewhere in between the discussions of heavy stuff like sexual harassment in Effective Altruism culture and total frivolity were the rambles about science. I thought I would pull a couple such comments out of the archives and edit them into something shaped like a blog post. So, consider this your Attention Conservation Notice: if you’d rather not work through a self-admittedly rough explanation of how Eliezer Yudkowsky’s claims about quantum physics are just silly, exit now.

Yudkowsky clearly intends to argue that the scientific community is broken and his brand of Rationalism(TM) is superior, but what he’s actually done is take all the weaknesses that physicists have when discussing quantum foundations and present them in a more concentrated form. There’s the accepting whatever mathematical formulation you learn first as the ultimate truth, the reliance upon oversimplified labels and third-hand accounts rather than studying what the pioneers themselves wrote, the general unwillingness to get out of the armchair and go even so far as the library…
Continue reading Friends Don’t Let Friends Learn Physics From Yudkowsky

Venting

I confess myself a bit baffled by people who act like “how to interact with ChatGPT” is a useful classroom skill. It’s not a word processor or a spreadsheet; it doesn’t have documented, well-defined, reproducible behaviors. No, it’s not remotely analogous to a calculator. Calculators are built to be right, not to sound convincing. It’s a bullshit fountain. Stop acting like you’re a waterbender making emotive shapes by expressing your will in the medium of liquid bullshit. The lesson one needs about a bullshit fountain is not to swim in it.

“Oh, but it’s a source of inspiration!”

So, you’ve never been to a writers’ workshop, spent 30 minutes with the staff on the school literary magazine, seen the original “You’re the man now, dog!” scene, or had any other exposure to the thousand and one gimmicks invented over the centuries to get people to put one word after another.

“It provides examples for teaching the art of critique!”

Why not teach with examples, just hear me out here, by actual humans?

“Students can learn to write by rewriting the output!”

Am I the only one who finds passing off an edit of an unattributable mishmash as one’s own work to be, well, flagrantly unethical?

“You’re just yelling at a cloud! What’s next, calling for us to reject modernity and embrace tradition?”

I’d rather we built our future using the best parts of our present rather than the worst.

A Picture for the Mind: the Bloch Ball

Now and then, stories will pop up in the news about the latest hot new thing in quantum computers. If the story makes any attempt to explain why quantum computing is special or interesting, it often recycles a remark along the lines of, “A quantum bit can be both 0 and 1 simultaneously.” This, well, ehhhhh… It’s rather like saying that Boston is at both the North Pole and the South Pole simultaneously. Something important has been lost. I figured I should take a stab at explaining what. Our goal today is to develop a mental picture for a qubit, the basic unit that quantum computers are typically regarded as built out of. To be more precise, we will develop a mental picture for the mathematics of a qubit, not for how to implement one in the lab. There are many ways to do so, and getting into the details of any one method would, for our purposes today, be a distraction. Instead, we will be brave and face the issue on a more abstract level.

A qubit is a thing that one prepares and that one measures. The mathematics of quantum theory tells us how to represent these actions algebraically. That is, it describes the set of all possible preparations, the set of all possible measurements, and how to compute the probability of getting a particular result from a chosen measurement given a particular preparation. To do something interesting, one would typically work with multiple qubits together, but we will start with a single one. And we will begin with the simplest kind of measurement, the binary ones. A binary test has two possible outcomes, which we can represent as 0 or 1, “plus” or “minus”, “ping” and “pong”, et cetera. In the lab, this could be sending an ion through a magnetic field and registering whether it swerved up or down; or, it could be sending a blip of light through a polarizing filter turned at a certain angle and registering whether there is or is not a flash. Or any of many other possibilities! The important thing is that there are two outcomes that we can clearly distinguish from each other.

For any physical implementation of a qubit, there are three binary measurements of special interest, which we can call the $X$ test, the $Y$ test and the $Z$ test. Let us denote the possible outcomes of each test by $+1$ and $-1$, which turns out to be a convenient choice. The expected value of the $X$ test is the average of these two possibilities, weighted by the probability of each. If we write $P(+1|X)$ for the probability of getting the $+1$ outcome given that we do the $X$ test, and likewise for $P(-1|X)$, then this expected value is $$ x = P(+1|X) \cdot (+1) + P(-1|X) \cdot (-1). $$ Because this is a weighted average of $+1$ and $-1$, it will always be somewhere in that interval. If for example we are completely confident that an $X$ test will return the outcome $+1$, then $x = 1$. If instead we lay even odds on the two possible outcomes, then $x = 0$. Likewise, $$ y = P(+1|Y) \cdot (+1) + P(-1|Y) \cdot (-1), $$ and $$ z = P(+1|Z) \cdot (+1) + P(-1|Z) \cdot (-1). $$

To specify the preparation of a single qubit, all we have to do is pick a value for $x$, a value for $y$ and a value for $z$. But not all combinations $(x,y,z)$ are physically allowed. The valid preparations are those for which the point $(x,y,z)$ lies on or inside the ball of radius 1 centered at the origin: $$ x^2 + y^2 + z^2 \leq 1. $$ We call this the Bloch ball, after the physicist Felix Bloch (1905–1983). The surface of the Bloch ball, at the distance exactly 1 from the origin, is the Bloch sphere. The points where the axes intersect the Bloch sphere — $(1,0,0)$, $(-1,0,0)$, $(0,1,0)$ and so forth — are the preparations where we are perfectly confident in the outcome of one of our three tests. Points in the interior of the ball, not on the surface, imply uncertainty about the outcomes of all three tests. But look what happens: If I am perfectly confident of what will happen should I choose to do an $X$ test, then my expected values $y$ and $z$ must both be zero, meaning that I am completely uncertain about what might happen should I choose to do either a $Y$ test or a $Z$ test. There is an inevitable tradeoff between levels of uncertainty, baked into the shape of the theory itself. One might even call that a matter… of principle.

Bloch ball, with the center point and the points where the axes intersect the outer sphere marked with dots

We are now well-poised to improve upon the language in the news stories. The point that specifies the preparation of a qubit can be at the North Pole $(0,0,1)$, the South Pole $(0,0,-1)$, or anywhere in the ball between them. We have a whole continuum of ways to be intermediate between completely confident that the $Z$ test will yield $+1$ (all the way north) and completely confident that it will yield $-1$ (all the way south).

Now, there are other things one can do to a qubit. For starters, there are other binary measurements beyond just the $X$, $Y$ and $Z$ tests. Any pair of points exactly opposite each other on the Bloch sphere define a test, with each point standing for an outcome. The closer the preparation point is to an outcome point, the more probable that outcome. To be more specific, let’s write the preparation point as $(x,y,z)$ and the outcome point as $(x’,y’,z’)$. Then the probability of getting that outcome given that preparation is $$ P = \frac{1}{2}(1 + x x’ + y y’ + z z’). $$

An interesting conceptual thing has happened here. We have encoded the preparation of a qubit by a set of expected values, i.e., a set of probabilities. Consequently, all those late-night jazz-cigarette arguments over what probability means will spill over into the arguments about what quantum mechanics means. Moreover, and not unrelatedly, we can ask, “Why three probabilities? Why is it the Bloch sphere, instead of the Bloch disc or the Bloch hypersphere?” It would be perfectly legitimate, mathematically, to require probabilities for only two tests in order to specify a preparation point, or to require more than three. That would not be quantum mechanics; the fact that three coordinates are needed to nail down the preparation of the simplest possible system is a structural fact of quantum theory. But is there a deeper truth from which that can be deduced?

One could go in multiple directions from here: What about tests with more than two outcomes? Systems composed of more than one qubit? Very quickly, the structures involved become more difficult to visualize, and familiarity with linear algebra — eigenvectors, eigenvalues and their friends — becomes a prerequisite. People have also tried a variety of approaches to understand what quantum theory might be derivable from. Any of those topics could justify something in between a blog post and a lifetime of study.

SUGGESTED READINGS:

  • E. Rieffel and W. Polak, Quantum Computing: A Gentle Introduction (MIT Press, 2011), chapter 2
  • J. Rau, Quantum Theory: An Information Processing Approach (Oxford University Press, 2021), section 3.3
  • M. Weiss, “Python tools for the budding quantum bettabilitarian” (2022)

"no matter how gifted, you alone cannot change the world"