Jekyll2021-02-06T10:57:39+01:00https://danielepaliotta.com/feed.xmldaniele paliottayet another technical blog.daniele paliottadanielepaliotta96@email.comTeaching Myself Quantum Mechanics, Part one.2021-02-04T00:00:00+01:002021-02-04T00:00:00+01:00https://danielepaliotta.com/qm-1<p>This series is about me learning something in my spare time. More specifically, it’s about me learning quantum mechanics, as a way of getting back into physics, and as a way of making good science.</p>
<p>I’ll explain: I have recently started a PhD in machine learning at the University of Geneva. The main project I’ll be working on is about applying machine learning and statistical methods to physics, mainly high energy physics (HEP) and solar astronomy. I am part of a very strong multidisciplinary team of physicists and AI people, so I could probably do without a strong physics background. Still, I feel like that can’t hurt, right?</p>
<p>So there you have it: I want to study and understand physics in order to do better research.</p>
<p>But that’s not the whole story. I also love physics, and I have tortured myself over and over as to whether I should have majored in physics rather that CS during my university career. This is not to say that I am any good at it. I only had one big physics exam during my bachelor (topics were kinematics, some classical mechanics, electromagnetism), and all the rest of my knowledge is made of bits and pieces coming from random youtube lectures and non-technical books I have read over the years. So yeah, it’s finally time to get serious.</p>
<h3 id="why-start-with-quantum-mechanics">Why start with Quantum Mechanics?</h3>
<p>Because I find it exciting, and that’s probably enough. Starting with classical mechanics would likely bore me to death. I know QM is not easy or intuitive, and that math can get hard. However, I don’t feel completely ill-equipped. Thanks to my engineering and ML background, I know one thing or two about probabilities, linear algebra, Fourier series and complex numbers, which I have been told are a substantial part of the required background.</p>
<h3 id="what-is-your-study-method">What is your study method?</h3>
<p>I usually try to be extremely deliberate about my study method. I won’t go into the details here, but I use active recall and spatial repetition tools such as Anki so that remembering what I study is no longer a random event but a purposeful act. There are many interesting resources about such techniques, such as <a href="http://augmentingcognition.com/ltm.html">this</a>, and <a href="https://aliabdaal.com/spacedrepetition/">this</a>. Michael Nielsen has even developed an <a href="https://quantum.country/qcvc">introduction to quantum computing</a> delivered in a “new mnemonic medium which makes it almost effortless to remember what you read” (hint: it’s active recall and spaced repetition).</p>
<p>As for the learning resources, I have chosen two introductory books: one is from the theoretical minimum series from the great Leonard Susskind. This is supposed to be a very simple introduction, starting from first principles. I have already flipped through the pages, and there actually seems to be quite a lot of content, or at least more than you would expect from a book of this kind.</p>
<p>The second book it more technical, and it comes up over and over as a suggestion for learning QM: Griffiths’ Introduction to Quantum Mechanics. Honestly, here I have no idea what to expect.</p>
<p>So here’t the plan: I’ll go through both books simultaneously and try to solve most exercises. I’ll also create flashcards and diagrams of the concepts, and let Anki do the rest. Additionally, I’ll write this blog series, which hopefully helps me understand things better. So if you are here to learn, don’t just count on my writing.</p>
<h3 id="requirements">Requirements</h3>
<p>The requirements are basic linear algebra and basic probability. And complex numbers. Some notions of classical physics can also help.</p>
<hr />
<h2 id="spins-and-qubits">Spins and Qubits</h2>
<p>The fact that we cannot fully grasp some things about the inner workings of our universe should come at no surprise. After all, we evolved to survive, not to understand. Ok yes, we have a strong intuition for many classical-mechanical things, but the reason is that things that behave classically are closer to our experience than things that behave relativistically or in a quantum mechanical way. So what we can do here is simple: let’s just go with the math and with the experiment. I don’t expect any of the concepts I encounter to be “relatable”. I am going to trust the result of the experiments, and link that to the math which hopefully explains them. And I’ll start with the <strong>spin</strong>.</p>
<p>Sooo, the spin is an extra degree of freedom that some particle have (all of them? I don’t know).</p>
<p>This spin is a very quantum mechanical concept, which is why trying to visualize it classically would miss the point.</p>
<p>Now, the spin of a particle is a quantum systems on its own right. In fact, it’s the “simplest and the most quantum of systems”, according to Susskind. Just by going through a very simple experiment involving the spin, we can already start to notice some important differences between classical physics and quantum mechanics.</p>
<p>The experiment involves a measuring system, which we call $\mathcal{A}$, that records the state of the spin of our system (we’ll call it $\sigma$). We can orient the measuring apparatus in order to measure this “something” along a specified axis. As a test, we rotate the apparatus along the $z$-axis, and notice that our measurement has the value of $1$ or $-1$.</p>
<p>Now, if we reset the apparatus to measure again the spin along the $z$-axis, and assume the simple evolution law</p>
\[\sigma(n+1) = \sigma(n)\]
<p>which tells us that the state of the system remains unchanged through time, then the previous measurement should be confirmed, again and again. We say that the measurement of a state <strong>prepares the system.</strong></p>
<p>In quantum experiments, performing the same measurement repeatedly gives the same answer until the system is prepared differently. We will see this in more detail now.</p>
<p>After we have prepared the system in the state $\sigma_z = 1$, let’s now rotate the apparatus of, say, 90 degrees, and measure the spin along the $x$-axis. Something weird happens. Sometimes we get +1, sometimes we get -1. It looks like the result is no longer deterministic, but in some peculiar way. In fact, if we repeat the experiment multiple times, we find that the average value of the measurement along the $x$-axis is $0$.</p>
<p>In fact, this is generalizable to any direction. We can pick any direction $\hat{m}$ and prepare a spin so that the apparatus measures a $+1$ in that direction. Then, we rotate the apparatus to any other direction $\hat{n}$. Again, the result of the measurement will still be either $+1$ or $-1$, but the expected value will be equal to the projection of $\hat{m}$ over $\hat{n}$ , that is, $\cos{\theta}$, with $\theta$ being the angle between the vectors.</p>
<p>In <em>bra-ket notation</em> (we’ll talk about this more in detail)<em>:</em></p>
\[\langle{\sigma}\rangle = \hat{m} \cdot\hat{n} = \cos{\theta}\]
<p>Notice that this is the same result that we would expect in classical physics for some vector quantity that we measure. However, in the classical sense, the result would be deterministic. In QM, the result is statistically random, but the average converges to the classical result.</p>
<h2 id="vector-spaces-inner-products-bases">Vector spaces, inner products, bases.</h2>
<p>In quantum mechanics the space of the states is a vector space. We call vectors <em>ket.</em> This is a <em>ket:</em> $\vert a\rangle$. Some simple axioms are defined in this space: the sum of two kets is a ket, ket addition is commutative and associative, and some other things like the existence of a 0 vector, an additive inverse, and linearity. Up to this point, everything looks normal, and the vector space we have defined is practically the same as the space of 3-vectors in Euclidean space. However, the space of our <em>kets</em> is a complex vector space, made of complex numbers, and where the multiplication by a scalar value also extends to complex numbers! This is a very abstract concept, but it’s absolutely needed to make the theory work mathematically.</p>
<p>Now, if you know something about complex vector, you will likely remember about the complex conjugate. Briefly, given a complex number $z$, there exists a complex conjugate $z^*$ that we obtain by reversing the sign of the imaginary part. So if $z=x+iy = re^{i\theta}$, then $z^*=x-iy = re^{-i\theta}$. Note that the product of a complex number and its complex conjugate is always positive, yielding $r^2$ in our case.</p>
<p>In the same way, a complex vector space has a <em>dual</em> space that is its complex conjugate vector space. In our case, for every <em>ket</em> $\vert A\rangle$, we can define a <em>bra</em> vector in that dual space: $\langle A \vert$, which is essentially its complex conjugate.</p>
<p>Now, if you got up to this point, I am pretty sure you remember about dot-products in Euclidean space, right? Well, that dot-product is a specific instance of so-called <em>inner products,</em> which we can also define in our complex space. In out quantum-mechanical magical world, the inner product is defined between a <em>bra</em> and a <em>ket</em>, and the notation is</p>
\[\langle B|A \rangle\]
<p>and, of course, the result is a complex number. These products are linear, and interchanging bras and kets corresponds to complex conjugation</p>
\[\langle B|A \rangle = \langle A|B \rangle ^*\]
<p>Concretely, the product is performed in the exact same way as for the dot-product: sum of the products of the components.</p>
<p>We can also bring with us some familiar concepts from Euclidean spaces:</p>
<ul>
<li>A vector is <em>normalized</em> if its inner products with itself is 1.</li>
<li>Two vectors are <em>orthogonal</em> if their inner products is 0.</li>
</ul>
<p>In our vector space, we can also define a <em>basis</em>, which is simply a set of vector that can be used to derive any other vector in the space through linear combinations. It’s often useful, and it is especially in QM, to talk about <em>orthonormal bases</em>, which are <em>bases</em> where the vectors are normalized and orthogonal between each other. Note that the number of vectors in a <em>basis</em> is equivalent to the dimension of the space.</p>
<h3 id="quantum-states">Quantum States</h3>
<p>With some math tools under our belt, let’s try to formalize the notion of a <em>spin state</em> from earlier. For this task, we will use vectors, and create a representation that captures what we know about how spins behave.</p>
<p>Let’s start but labelling all the possible spin states along the three axes. When the apparatus $\mathcal{A}$ is oriented along the $z$-axis, the two possible states are $\sigma_z = \pm1$. We can call them <em>up</em> and <em>down</em> states and assign them ket vectors $\vert u\rangle$ and $\vert d\rangle$. So, when $\mathcal{A}$ is oriented along the $z$-axis and registers $+1$, the system is in state $\vert u\rangle$. We also define the states for the directions along the $x$-axis and call them $\vert r\rangle$ and $\vert l\rangle$ (for <em>right</em> and left), and finally along the $y$-axis which we call $\vert i\rangle$ and $\vert o\rangle$ (<em>in</em> and <em>out</em>).</p>
<p>Now, a consequence of this formalization is that the space of the states for a single spin has only two dimensions. This means that all possible states of a spin can be represented in a two-dimensional vector space. If we choose $\vert u\rangle$ and $\vert d\rangle$ as the basis vectors for this space, following by the definition of a <em>basis</em>, we can then write any other state as a linear combination (or <em>superposition) of these two vectors.</em></p>
<p>Thus, a generic state $\vert A\rangle$ comes in the form</p>
\[|A\rangle = \alpha_u|u\rangle + a_d|d\rangle\]
<p>where $\alpha_u$ and $\alpha_d$ are the components of $\vert A\rangle$ along the two basis vectors.</p>
<p>We can retrieve these components through an inner product (which is essentially a projection) of the state vector on the respective basis vectors:</p>
\[\alpha_u = \langle u|A\rangle \\
\alpha_d = \langle d|A\rangle \\\]
<p>It is important to remember that these components are complex number, and carry no physical meaning by themselves. However, their magnitude does. In fact, given that the spin has been prepared in state $\vert A\rangle$, and that the apparatus is oriented along $z$, the quantity $\alpha_u^{*}\alpha_u$ is the probability that the spin would be measured as $\sigma_z = +1$ (an <em>up</em> spin along the $z$-axis).</p>
<p>Obviously, the same holds for $\alpha_d^*\alpha_d$, which is the probability of measuring $\sigma_z = -1$.</p>
<p>To be more precise, the quantities $\alpha_u$ and $\alpha_d$ are classed probability amplitudes and are not actual probabilities. To get actual probabilities, these quantities need to be squared, so that</p>
\[P_u = \langle A|u\rangle\langle u|A\rangle \\
P_d = \langle A|d\rangle\langle d|A\rangle\]
<p>Something important to notice is the state $\vert A\rangle$ is not what we measure. $\vert A\rangle$ is something we know <em>before</em> the measurement. It is our knowledge of the state of the system, or how the system was <em>prepared</em>. It represents the <em>potential</em> possibilities of the values of our measurements. Once we measure the spin along a certain direction, however, we can only get a $\vert u\rangle$ or a $\vert d\rangle$.</p>
<p>Two additional points are important. First, $\vert u\rangle$ an $\vert d\rangle$ have to be mutually orthogonal, meaning that</p>
\[\langle u|d\rangle = 0 \\
\langle d|u\rangle = 0 \\\]
<p>but what does this mean? It means that the <em>up</em> and <em>down</em> states are physically distinct and mutually exclusive. If the spin is prepared in the <em>up</em> state, then it can’t be detected to be in the <em>down</em> state, and viceversa. This is true not just for the spin, but for any quantum system.</p>
<p>Another point is that, since <em>up</em> and <em>down</em> are the only possible result of the measurement, their respective probabilities need to sum up to 1. Mathematically,</p>
\[\alpha_u^*\alpha_u + \alpha_d^*\alpha_d =1\]
<p>which is the same as saying that $\vert A\rangle$ is normalized:</p>
\[\langle A| A\rangle = 1\]
<p>And this is the last thing I’ll state for today, but it’s a very important principle: <em>the state of a system is represented by a unit vector in a vector space of states. Moreover, the squared magnitudes of the components of the state-vector, along particular basis vectors, represent probabilities for various experimental outcomes.</em> Prof. Susskind said that so it must be true.</p>
<h3 id="what-about-next-time">What about next time?</h3>
<p>To recap, we made some spin experiment, looked at the weird results we were getting, and developed a small part of a mathematical framework to represent these result, work with them, and one day make predictions.</p>
<p>I think this is enough for today, as we went thought quite some stuff. In the next episode, we’ll be deriving state vectors for the spin in any direction, and state the principles of quantum mechanics!</p>
<p>See ya!</p>daniele paliottadanielepaliotta96@email.comThis series is about me learning something in my spare time. More specifically, it’s about me learning quantum mechanics, as a way of getting back into physics, and as a way of making good science.Books I’ve been reading in 20202020-08-17T00:00:00+02:002020-08-17T00:00:00+02:00https://danielepaliotta.com/books-2020<ul>
<li><em>Pereira Maintains</em> by Antonio Tabucchi</li>
<li>All of <em>Game of Thrones</em></li>
<li><em>An Astronaut’s guide to Life on Earth</em> by Chris Hadfield</li>
<li><em>Love in the Time of Cholera</em> by Gabriel García Márquez</li>
<li><em>The Plague</em> by Albert Camus</li>
<li><em>Animal Liberation</em> by Peter Singer</li>
<li><em>Home Deus</em> by Yuval Noah Harari</li>
<li><em>Atomic Habits</em> by James Clear</li>
<li><em>The Madness of Crowds</em> by Douglas Murray</li>
<li><em>Thicker than Water</em> by Tyler Shultz (Audible)</li>
<li><em>Permanent Record</em> by Edward Snowden</li>
<li><em>Why We Sleep</em> by Matthew Walker</li>
<li><em>Talking to Strangers</em> by Malcolm Gladwell</li>
</ul>daniele paliottadanielepaliotta96@email.comPereira Maintains by Antonio Tabucchi All of Game of Thrones An Astronaut’s guide to Life on Earth by Chris Hadfield Love in the Time of Cholera by Gabriel García Márquez The Plague by Albert Camus Animal Liberation by Peter Singer Home Deus by Yuval Noah Harari Atomic Habits by James Clear The Madness of Crowds by Douglas Murray Thicker than Water by Tyler Shultz (Audible) Permanent Record by Edward Snowden Why We Sleep by Matthew Walker Talking to Strangers by Malcolm Gladwell