diff --git a/_book/Introduction-to-Quantum-Computing.epub b/_book/Introduction-to-Quantum-Computing.epub index 3d51fcf910bde620fc9c7041448937049013261b..52557a79d2dd57a14ecf3a4f900c852e98704af3 100644 Binary files a/_book/Introduction-to-Quantum-Computing.epub and b/_book/Introduction-to-Quantum-Computing.epub differ diff --git a/_book/Introduction-to-Quantum-Computing.pdf b/_book/Introduction-to-Quantum-Computing.pdf index b56cce3a99e47c99a1692c0380b1dcb8a3f570aa..ee3710b1ff9ea0c9cb6f4f0f56c97d4f04d94b1f 100644 Binary files a/_book/Introduction-to-Quantum-Computing.pdf and b/_book/Introduction-to-Quantum-Computing.pdf differ diff --git a/_book/index.html b/_book/index.html index dda181b8d9ad1ff682ee751ceb147843511e759f..f8c1e98f2c731b500f53572fdddaf6cb15d4c517 100644 --- a/_book/index.html +++ b/_book/index.html @@ -8,7 +8,7 @@ <meta name="author" content="Jannik Hellenkamp"> <meta name="author" content="Dominique Unruh"> -<meta name="dcterms.date" content="2024-05-16"> +<meta name="dcterms.date" content="2024-05-21"> <title>Introduction to Quantum Computing</title> <style> @@ -198,7 +198,7 @@ ul.task-list li input[type="checkbox"] { <div> <div class="quarto-title-meta-heading">Published</div> <div class="quarto-title-meta-contents"> - <p class="date">May 16, 2024</p> + <p class="date">May 21, 2024</p> </div> </div> @@ -213,7 +213,7 @@ ul.task-list li input[type="checkbox"] { <section id="welcome" class="level1 unnumbered"> <h1 class="unnumbered">Welcome</h1> <p>These are the lecture notes for the “Introduction to Quantum Computing” lecture held by Dominique Unruh at RWTH Aachen in the summer term 2024. The lecture notes are updated throughout the semester and should be viewed as an addition to the handwritten notes and the lecture recordings.</p> -<p>If you prefer a <code>.pdf</code> or <code>.epub</code> file, there is a download available at the top left corner. Please note, that these files are autogenerated and some of the ebook readers have difficulties with the formulas. We are still working on a universal solution.</p> +<p>If you prefer a <code>.pdf</code> or <code>.epub</code> file, there is a download available at the top left corner. Please note, that these files are autogenerated and some of the ebook readers have difficulties with the formulas. We are still working on a universal solution. You can also find the source code in the top left corner.</p> <p>If you spot an error, please send Jannik Hellenkamp an e-mail. You can contact Jannik by sending an e-mail to firstname.lastname@rwth-aachen.de (please replace first and lastname with Jannik’s full name). If you have a question of understanding, please ask it in the Moodle forum.</p> <p>These lecture notes are released under the CC BY-NC 4.0 license, which can be found <a href="https://creativecommons.org/licenses/by-nc/4.0/">here</a>.</p> <section id="changelog" class="level2 unnumbered"> diff --git a/_book/probabilisticSystems.html b/_book/probabilisticSystems.html index 649fc58208edf89dc18d76d41f064f130f31398b..740fa9b7ba196a1f16bb8267b02dc4be24914d76 100644 --- a/_book/probabilisticSystems.html +++ b/_book/probabilisticSystems.html @@ -244,7 +244,7 @@ Example: Random 2-bit number </section> <section id="probability-distribution" class="level2" data-number="2.2"> <h2 data-number="2.2" class="anchored" data-anchor-id="probability-distribution"><span class="header-section-number">2.2</span> Probability distribution</h2> -<p>Next, we need to assign each possibility a probability. We write this as <span class="math inline">\(\Pr[X]=p\)</span> where <span class="math inline">\(p \in [0,1]\)</span> is the probability of the classical possibility <span class="math inline">\(X\)</span>.</p> +<p>Next, we need to assign each possibility a probability. We write this as <span class="math inline">\(\Pr[x]=p\)</span> where <span class="math inline">\(p \in [0,1]\)</span> is the probability of the classical possibility <span class="math inline">\(x\)</span>.</p> <div class="callout callout-style-simple callout-tip no-icon callout-titled"> <div class="callout-header d-flex align-content-center"> <div class="callout-icon-container"> @@ -266,12 +266,12 @@ Example: Coin flip </div> <div class="callout-body-container"> <div id="def-prob-distribution" class="definition theorem"> -<p><span class="theorem-title"><strong>Definition 2.1 (Probability distribution)</strong></span> A vector <span class="math inline">\(M \in \mathbb{R}^n\)</span> is a valid probability distribution iff <span class="math inline">\(\sum M_i = 1\)</span> and <span class="math inline">\(\forall i\)</span> <span class="math inline">\(M_i \geq 0\)</span></p> +<p><span class="theorem-title"><strong>Definition 2.1 (Probability distribution)</strong></span> A vector <span class="math inline">\(d \in \mathbb{R}^n\)</span> is a valid probability distribution iff <span class="math inline">\(\sum d_i = 1\)</span> and <span class="math inline">\(\forall i\)</span> <span class="math inline">\(d_i \geq 0\)</span></p> </div> </div> </div> </div> -<p>This vector has <span class="math inline">\(n\)</span> entries, where each entry corresponds to a classical possibility <span class="math inline">\(X\)</span> and the probability of <span class="math inline">\(X\)</span> is <span class="math inline">\(\Pr[X] = M_i\)</span>. The sum over all probabilities has to be <span class="math inline">\(1\)</span> and each entry needs to be nonnegative in order to be a valid probability.</p> +<p>This vector has <span class="math inline">\(n\)</span> entries, where each entry corresponds to a classical possibility <span class="math inline">\(X\)</span> and the probability of <span class="math inline">\(X\)</span> is <span class="math inline">\(\Pr[X] = d_i\)</span>. The sum over all probabilities has to be <span class="math inline">\(1\)</span> and each entry needs to be nonnegative in order to be a valid probability.</p> <div class="callout callout-style-simple callout-tip no-icon callout-titled"> <div class="callout-header d-flex align-content-center"> <div class="callout-icon-container"> @@ -282,7 +282,7 @@ Example (continued): Coin flip </div> </div> <div class="callout-body-container callout-body"> -<p>For a coin flip the probability distribution would be <span class="math inline">\(M_{\text{coin}} \in \mathbb{R}^2\)</span> with <span class="math inline">\(M = \begin{pmatrix}\frac{1}{2}\\ \frac{1}{2} \end{pmatrix}\)</span></p> +<p>For a coin flip the probability distribution would be <span class="math inline">\(d_{\text{coin}} \in \mathbb{R}^2\)</span> with <span class="math inline">\(d = \begin{pmatrix}\frac{1}{2}\\ \frac{1}{2} \end{pmatrix}\)</span></p> </div> </div> <div class="callout callout-style-simple callout-tip no-icon callout-titled"> @@ -296,7 +296,7 @@ Example (continued): Random 2-bit number </div> <div class="callout-body-container callout-body"> <p>Recall your random 2-bit number generator from above. Imagine your generator outputs each classical possibility with equal probability, except for the possibility <span class="math inline">\(00\)</span>, which is never generated. The corresponding probability distribution would be <span class="math display">\[ -M_{\text{2-bit}} = \begin{pmatrix} 0 \\ \frac{1}{3}\\ \frac{1}{3} \\ \frac{1}{3} \end{pmatrix} +d_{\text{2-bit}} = \begin{pmatrix} 0 \\ \frac{1}{3}\\ \frac{1}{3} \\ \frac{1}{3} \end{pmatrix} \]</span></p> </div> </div> @@ -304,7 +304,7 @@ M_{\text{2-bit}} = \begin{pmatrix} 0 \\ \frac{1}{3}\\ \frac{1}{3} \\ \frac{1}{3} <section id="probabilistic-processes" class="level2" data-number="2.3"> <h2 data-number="2.3" class="anchored" data-anchor-id="probabilistic-processes"><span class="header-section-number">2.3</span> Probabilistic processes</h2> <p>With a probability distribution, we can only describe the probabilities of possibilities without any knowledge of a prior state. We therefore add another element to our toolbox of probabilistic systems called a <em>probabilistic process</em>.</p> -<p>A probabilistic process is a collection of <span class="math inline">\(n\)</span> probability distributions, where for each classical possibility there is a probability distribution under the condition of that possibility. This lets us have conditional probabilities. We can write this as a matrix, where each column is a probability distribution.</p> +<p>A probabilistic process is a collection of <span class="math inline">\(n\)</span> probability distributions, where for each classical possibility <span class="math inline">\(i\)</span> there is a probability distribution <span class="math inline">\(a_i\)</span>. This means, that if the system is in classical possibility <span class="math inline">\(i\)</span> before the process is applied, the system will afterwards be distributed according to <span class="math inline">\(a_i\)</span>. We can write this as a matrix, where each column is a probability distribution <span class="math inline">\(a_i\)</span>.</p> <div class="callout callout-style-simple callout-note no-icon"> <div class="callout-body d-flex"> <div class="callout-icon-container"> @@ -317,7 +317,7 @@ M_{\text{2-bit}} = \begin{pmatrix} 0 \\ \frac{1}{3}\\ \frac{1}{3} \\ \frac{1}{3} </div> </div> </div> -<p>From <a href="#def-prob-distribution" class="quarto-xref">Definition <span>2.1</span></a> we know that a valid probability distribution <span class="math inline">\(a\)</span> has the properties <span class="math inline">\(\sum a_i = 1\)</span> and <span class="math inline">\(\forall i\)</span> <span class="math inline">\(a_i \geq 0\)</span>, so a matrix <span class="math inline">\(A \in \mathbb{R}^{n \times n}\)</span> with <span class="math inline">\(\sum a_i = 1\)</span> and <span class="math inline">\(\forall i\)</span> <span class="math inline">\(a_i \geq 0\)</span> is a probabilistic process. This matrix is also called a <em>stochastic matrix</em>.</p> +<p>From <a href="#def-prob-distribution" class="quarto-xref">Definition <span>2.1</span></a> we know that a valid probability distribution <span class="math inline">\(a\)</span> has the properties <span class="math inline">\(\sum a_i = 1\)</span> and <span class="math inline">\(\forall i\)</span> <span class="math inline">\(a_i \geq 0\)</span>, therefore a matrix <span class="math inline">\(A\)</span> is a probabilistic process iff <span class="math inline">\(A \in \mathbb{R}^{n \times n}\)</span> with <span class="math inline">\(\sum a_i = 1\)</span> and <span class="math inline">\(\forall i\)</span> <span class="math inline">\(a_i \geq 0\)</span> . Such a matrix is also called a <em>stochastic matrix</em>.</p> <div class="callout callout-style-simple callout-tip no-icon callout-titled"> <div class="callout-header d-flex align-content-center"> <div class="callout-icon-container"> @@ -363,7 +363,7 @@ Example (continued): Random 2-bit number </div> <div class="callout-body-container callout-body"> <p>Recall the 2-bit number generator and the bit flip from above. Imagine you would first draw a random 2-bit number from the generator and then run the bit flip device. We already know that the probability distribution of the generator is <span class="math inline">\(M_\text{2-bit}\)</span>. Using <span class="math inline">\(A_\text{flip}\)</span> we can calculate the final probability distribution: <span class="math display">\[ -A_\text{flip} \cdot M_\text{2-bit} = \begin{pmatrix} \frac{2}{3} & 0 & 0 & \frac{1}{3} \\ 0 & \frac{2}{3} & \frac{1}{3} & 0 \\ 0 & \frac{1}{3} & \frac{2}{3} & 0 \\ \frac{1}{3} & 0 & 0 & \frac{2}{3} \end{pmatrix}\begin{pmatrix} 0 \\ \frac{1}{3}\\ \frac{1}{3} \\ \frac{1}{3} \end{pmatrix} = \begin{pmatrix} \frac{1}{9} \\ \frac{1}{3}\\ \frac{1}{3} \\ \frac{2}{9} \end{pmatrix} +A_\text{flip} \cdot d_\text{2-bit} = \begin{pmatrix} \frac{2}{3} & 0 & 0 & \frac{1}{3} \\ 0 & \frac{2}{3} & \frac{1}{3} & 0 \\ 0 & \frac{1}{3} & \frac{2}{3} & 0 \\ \frac{1}{3} & 0 & 0 & \frac{2}{3} \end{pmatrix}\begin{pmatrix} 0 \\ \frac{1}{3}\\ \frac{1}{3} \\ \frac{1}{3} \end{pmatrix} = \begin{pmatrix} \frac{1}{9} \\ \frac{1}{3}\\ \frac{1}{3} \\ \frac{2}{9} \end{pmatrix} \]</span></p> </div> </div> diff --git a/_book/search.json b/_book/search.json index 8012a37ba2ab7800c5c85fd3daa5dd0bcc711f25..0b0e61141909b609b5ebc8d9cf206d5d2398172e 100644 --- a/_book/search.json +++ b/_book/search.json @@ -4,7 +4,7 @@ "href": "index.html", "title": "Introduction to Quantum Computing", "section": "", - "text": "Welcome\nThese are the lecture notes for the “Introduction to Quantum Computing” lecture held by Dominique Unruh at RWTH Aachen in the summer term 2024. The lecture notes are updated throughout the semester and should be viewed as an addition to the handwritten notes and the lecture recordings.\nIf you prefer a .pdf or .epub file, there is a download available at the top left corner. Please note, that these files are autogenerated and some of the ebook readers have difficulties with the formulas. We are still working on a universal solution.\nIf you spot an error, please send Jannik Hellenkamp an e-mail. You can contact Jannik by sending an e-mail to firstname.lastname@rwth-aachen.de (please replace first and lastname with Jannik’s full name). If you have a question of understanding, please ask it in the Moodle forum.\nThese lecture notes are released under the CC BY-NC 4.0 license, which can be found here.", + "text": "Welcome\nThese are the lecture notes for the “Introduction to Quantum Computing” lecture held by Dominique Unruh at RWTH Aachen in the summer term 2024. The lecture notes are updated throughout the semester and should be viewed as an addition to the handwritten notes and the lecture recordings.\nIf you prefer a .pdf or .epub file, there is a download available at the top left corner. Please note, that these files are autogenerated and some of the ebook readers have difficulties with the formulas. We are still working on a universal solution. You can also find the source code in the top left corner.\nIf you spot an error, please send Jannik Hellenkamp an e-mail. You can contact Jannik by sending an e-mail to firstname.lastname@rwth-aachen.de (please replace first and lastname with Jannik’s full name). If you have a question of understanding, please ask it in the Moodle forum.\nThese lecture notes are released under the CC BY-NC 4.0 license, which can be found here.", "crumbs": [ "Welcome" ] @@ -68,7 +68,7 @@ "href": "probabilisticSystems.html#probability-distribution", "title": "2 Probabilistic systems", "section": "2.2 Probability distribution", - "text": "2.2 Probability distribution\nNext, we need to assign each possibility a probability. We write this as \\(\\Pr[X]=p\\) where \\(p \\in [0,1]\\) is the probability of the classical possibility \\(X\\).\n\n\n\n\n\n\nExample: Coin flip\n\n\n\nFor a coin flip the probability of heads would be \\(\\Pr[\\text{heads}] = \\frac{1}{2}\\) and the probability for tails would be \\(\\Pr[\\text{tails}] = \\frac{1}{2}\\).\n\n\nIf we combine all probabilities for all the possible outcomes and write them as a vector, we get a probability distribution.\n\n\n\n\n\n\n\nDefinition 2.1 (Probability distribution) A vector \\(M \\in \\mathbb{R}^n\\) is a valid probability distribution iff \\(\\sum M_i = 1\\) and \\(\\forall i\\) \\(M_i \\geq 0\\)\n\n\n\n\nThis vector has \\(n\\) entries, where each entry corresponds to a classical possibility \\(X\\) and the probability of \\(X\\) is \\(\\Pr[X] = M_i\\). The sum over all probabilities has to be \\(1\\) and each entry needs to be nonnegative in order to be a valid probability.\n\n\n\n\n\n\nExample (continued): Coin flip\n\n\n\nFor a coin flip the probability distribution would be \\(M_{\\text{coin}} \\in \\mathbb{R}^2\\) with \\(M = \\begin{pmatrix}\\frac{1}{2}\\\\ \\frac{1}{2} \\end{pmatrix}\\)\n\n\n\n\n\n\n\n\nExample (continued): Random 2-bit number\n\n\n\nRecall your random 2-bit number generator from above. Imagine your generator outputs each classical possibility with equal probability, except for the possibility \\(00\\), which is never generated. The corresponding probability distribution would be \\[\nM_{\\text{2-bit}} = \\begin{pmatrix} 0 \\\\ \\frac{1}{3}\\\\ \\frac{1}{3} \\\\ \\frac{1}{3} \\end{pmatrix}\n\\]", + "text": "2.2 Probability distribution\nNext, we need to assign each possibility a probability. We write this as \\(\\Pr[x]=p\\) where \\(p \\in [0,1]\\) is the probability of the classical possibility \\(x\\).\n\n\n\n\n\n\nExample: Coin flip\n\n\n\nFor a coin flip the probability of heads would be \\(\\Pr[\\text{heads}] = \\frac{1}{2}\\) and the probability for tails would be \\(\\Pr[\\text{tails}] = \\frac{1}{2}\\).\n\n\nIf we combine all probabilities for all the possible outcomes and write them as a vector, we get a probability distribution.\n\n\n\n\n\n\n\nDefinition 2.1 (Probability distribution) A vector \\(d \\in \\mathbb{R}^n\\) is a valid probability distribution iff \\(\\sum d_i = 1\\) and \\(\\forall i\\) \\(d_i \\geq 0\\)\n\n\n\n\nThis vector has \\(n\\) entries, where each entry corresponds to a classical possibility \\(X\\) and the probability of \\(X\\) is \\(\\Pr[X] = d_i\\). The sum over all probabilities has to be \\(1\\) and each entry needs to be nonnegative in order to be a valid probability.\n\n\n\n\n\n\nExample (continued): Coin flip\n\n\n\nFor a coin flip the probability distribution would be \\(d_{\\text{coin}} \\in \\mathbb{R}^2\\) with \\(d = \\begin{pmatrix}\\frac{1}{2}\\\\ \\frac{1}{2} \\end{pmatrix}\\)\n\n\n\n\n\n\n\n\nExample (continued): Random 2-bit number\n\n\n\nRecall your random 2-bit number generator from above. Imagine your generator outputs each classical possibility with equal probability, except for the possibility \\(00\\), which is never generated. The corresponding probability distribution would be \\[\nd_{\\text{2-bit}} = \\begin{pmatrix} 0 \\\\ \\frac{1}{3}\\\\ \\frac{1}{3} \\\\ \\frac{1}{3} \\end{pmatrix}\n\\]", "crumbs": [ "Quantum Basics", "<span class='chapter-number'>2</span> <span class='chapter-title'>Probabilistic systems</span>" @@ -79,7 +79,7 @@ "href": "probabilisticSystems.html#probabilistic-processes", "title": "2 Probabilistic systems", "section": "2.3 Probabilistic processes", - "text": "2.3 Probabilistic processes\nWith a probability distribution, we can only describe the probabilities of possibilities without any knowledge of a prior state. We therefore add another element to our toolbox of probabilistic systems called a probabilistic process.\nA probabilistic process is a collection of \\(n\\) probability distributions, where for each classical possibility there is a probability distribution under the condition of that possibility. This lets us have conditional probabilities. We can write this as a matrix, where each column is a probability distribution.\n\n\n\n\n\n\n\nDefinition 2.2 (Probabilistic process) A matrix \\(A \\in \\mathbb{R}^{n\\times n}\\) is a valid probabilistic process iff for every column \\(a\\) of \\(A\\), \\(a\\) is a valid probability distribution.\n\n\n\n\nFrom Definition 2.1 we know that a valid probability distribution \\(a\\) has the properties \\(\\sum a_i = 1\\) and \\(\\forall i\\) \\(a_i \\geq 0\\), so a matrix \\(A \\in \\mathbb{R}^{n \\times n}\\) with \\(\\sum a_i = 1\\) and \\(\\forall i\\) \\(a_i \\geq 0\\) is a probabilistic process. This matrix is also called a stochastic matrix.\n\n\n\n\n\n\nExample (continued): Random 2-bit number\n\n\n\nImagine a second device, which receives a 2-bit number as an input and flips both bits at the same time with a probability of \\(\\frac{1}{3}\\). The probability distributions for each of the classical possibility would then be \\[\na_{00} = \\begin{pmatrix} \\frac{2}{3} \\\\ 0 \\\\ 0 \\\\ \\frac{1}{3} \\end{pmatrix}, a_{01} =\\begin{pmatrix} 0 \\\\ \\frac{2}{3} \\\\ \\frac{1}{3} \\\\ 0 \\end{pmatrix}, a_{10} =\\begin{pmatrix} 0 \\\\ \\frac{1}{3} \\\\ \\frac{2}{3} \\\\ 0 \\end{pmatrix}, a_{11} = \\begin{pmatrix} \\frac{1}{3} \\\\ 0 \\\\ 0 \\\\ \\frac{2}{3} \\end{pmatrix}\n\\] From this we can construct the process as a matrix from these processes as follows: \\[\nA_{\\text{flip}} = \\begin{pmatrix} a_{00} & a_{01} & a_{10} & a_{11} \\end{pmatrix} = \\begin{pmatrix} \\frac{2}{3} & 0 & 0 & \\frac{1}{3} \\\\ 0 & \\frac{2}{3} & \\frac{1}{3} & 0 \\\\ 0 & \\frac{1}{3} & \\frac{2}{3} & 0 \\\\ \\frac{1}{3} & 0 & 0 & \\frac{2}{3} \\end{pmatrix}\n\\]\n\n\n\nApplying a probabilistic process\nHaving defined probability distributions and probabilistic processes, we can now combine these two elements and apply a probabilistic process on a probability distribution.\n\n\n\n\n\n\n\nDefinition 2.3 (Applying a probabilistic process) Given an initial probability distribution \\(x\\) and a probabilistic process \\(A\\), the result \\(y\\) of applying the process \\(A\\) is defined as \\[\ny = Ax\n\\]\n\n\n\n\n\n\n\n\n\n\nExample (continued): Random 2-bit number\n\n\n\nRecall the 2-bit number generator and the bit flip from above. Imagine you would first draw a random 2-bit number from the generator and then run the bit flip device. We already know that the probability distribution of the generator is \\(M_\\text{2-bit}\\). Using \\(A_\\text{flip}\\) we can calculate the final probability distribution: \\[\nA_\\text{flip} \\cdot M_\\text{2-bit} = \\begin{pmatrix} \\frac{2}{3} & 0 & 0 & \\frac{1}{3} \\\\ 0 & \\frac{2}{3} & \\frac{1}{3} & 0 \\\\ 0 & \\frac{1}{3} & \\frac{2}{3} & 0 \\\\ \\frac{1}{3} & 0 & 0 & \\frac{2}{3} \\end{pmatrix}\\begin{pmatrix} 0 \\\\ \\frac{1}{3}\\\\ \\frac{1}{3} \\\\ \\frac{1}{3} \\end{pmatrix} = \\begin{pmatrix} \\frac{1}{9} \\\\ \\frac{1}{3}\\\\ \\frac{1}{3} \\\\ \\frac{2}{9} \\end{pmatrix}\n\\]", + "text": "2.3 Probabilistic processes\nWith a probability distribution, we can only describe the probabilities of possibilities without any knowledge of a prior state. We therefore add another element to our toolbox of probabilistic systems called a probabilistic process.\nA probabilistic process is a collection of \\(n\\) probability distributions, where for each classical possibility \\(i\\) there is a probability distribution \\(a_i\\). This means, that if the system is in classical possibility \\(i\\) before the process is applied, the system will afterwards be distributed according to \\(a_i\\). We can write this as a matrix, where each column is a probability distribution \\(a_i\\).\n\n\n\n\n\n\n\nDefinition 2.2 (Probabilistic process) A matrix \\(A \\in \\mathbb{R}^{n\\times n}\\) is a valid probabilistic process iff for every column \\(a\\) of \\(A\\), \\(a\\) is a valid probability distribution.\n\n\n\n\nFrom Definition 2.1 we know that a valid probability distribution \\(a\\) has the properties \\(\\sum a_i = 1\\) and \\(\\forall i\\) \\(a_i \\geq 0\\), therefore a matrix \\(A\\) is a probabilistic process iff \\(A \\in \\mathbb{R}^{n \\times n}\\) with \\(\\sum a_i = 1\\) and \\(\\forall i\\) \\(a_i \\geq 0\\) . Such a matrix is also called a stochastic matrix.\n\n\n\n\n\n\nExample (continued): Random 2-bit number\n\n\n\nImagine a second device, which receives a 2-bit number as an input and flips both bits at the same time with a probability of \\(\\frac{1}{3}\\). The probability distributions for each of the classical possibility would then be \\[\na_{00} = \\begin{pmatrix} \\frac{2}{3} \\\\ 0 \\\\ 0 \\\\ \\frac{1}{3} \\end{pmatrix}, a_{01} =\\begin{pmatrix} 0 \\\\ \\frac{2}{3} \\\\ \\frac{1}{3} \\\\ 0 \\end{pmatrix}, a_{10} =\\begin{pmatrix} 0 \\\\ \\frac{1}{3} \\\\ \\frac{2}{3} \\\\ 0 \\end{pmatrix}, a_{11} = \\begin{pmatrix} \\frac{1}{3} \\\\ 0 \\\\ 0 \\\\ \\frac{2}{3} \\end{pmatrix}\n\\] From this we can construct the process as a matrix from these processes as follows: \\[\nA_{\\text{flip}} = \\begin{pmatrix} a_{00} & a_{01} & a_{10} & a_{11} \\end{pmatrix} = \\begin{pmatrix} \\frac{2}{3} & 0 & 0 & \\frac{1}{3} \\\\ 0 & \\frac{2}{3} & \\frac{1}{3} & 0 \\\\ 0 & \\frac{1}{3} & \\frac{2}{3} & 0 \\\\ \\frac{1}{3} & 0 & 0 & \\frac{2}{3} \\end{pmatrix}\n\\]\n\n\n\nApplying a probabilistic process\nHaving defined probability distributions and probabilistic processes, we can now combine these two elements and apply a probabilistic process on a probability distribution.\n\n\n\n\n\n\n\nDefinition 2.3 (Applying a probabilistic process) Given an initial probability distribution \\(x\\) and a probabilistic process \\(A\\), the result \\(y\\) of applying the process \\(A\\) is defined as \\[\ny = Ax\n\\]\n\n\n\n\n\n\n\n\n\n\nExample (continued): Random 2-bit number\n\n\n\nRecall the 2-bit number generator and the bit flip from above. Imagine you would first draw a random 2-bit number from the generator and then run the bit flip device. We already know that the probability distribution of the generator is \\(M_\\text{2-bit}\\). Using \\(A_\\text{flip}\\) we can calculate the final probability distribution: \\[\nA_\\text{flip} \\cdot d_\\text{2-bit} = \\begin{pmatrix} \\frac{2}{3} & 0 & 0 & \\frac{1}{3} \\\\ 0 & \\frac{2}{3} & \\frac{1}{3} & 0 \\\\ 0 & \\frac{1}{3} & \\frac{2}{3} & 0 \\\\ \\frac{1}{3} & 0 & 0 & \\frac{2}{3} \\end{pmatrix}\\begin{pmatrix} 0 \\\\ \\frac{1}{3}\\\\ \\frac{1}{3} \\\\ \\frac{1}{3} \\end{pmatrix} = \\begin{pmatrix} \\frac{1}{9} \\\\ \\frac{1}{3}\\\\ \\frac{1}{3} \\\\ \\frac{2}{9} \\end{pmatrix}\n\\]", "crumbs": [ "Quantum Basics", "<span class='chapter-number'>2</span> <span class='chapter-title'>Probabilistic systems</span>" diff --git a/_book/sitemap.xml b/_book/sitemap.xml index 0d56db2d1460aa034264c604f1e59a1a5ec1f9bf..0b12044e8367babbbe30336e7704587c5c82a15f 100644 --- a/_book/sitemap.xml +++ b/_book/sitemap.xml @@ -2,7 +2,7 @@ <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"> <url> <loc>https://qis.rwth-aachen.de/teaching/24ss/intro-quantum-computing/script/index.html</loc> - <lastmod>2024-05-16T20:04:26.408Z</lastmod> + <lastmod>2024-05-21T10:35:50.245Z</lastmod> </url> <url> <loc>https://qis.rwth-aachen.de/teaching/24ss/intro-quantum-computing/script/quantumBasics.html</loc> @@ -14,14 +14,14 @@ </url> <url> <loc>https://qis.rwth-aachen.de/teaching/24ss/intro-quantum-computing/script/probabilisticSystems.html</loc> - <lastmod>2024-05-16T20:56:59.061Z</lastmod> + <lastmod>2024-05-21T10:42:49.300Z</lastmod> </url> <url> <loc>https://qis.rwth-aachen.de/teaching/24ss/intro-quantum-computing/script/Introduction-to-Quantum-Computing.pdf</loc> - <lastmod>2024-05-16T20:57:31.023Z</lastmod> + <lastmod>2024-05-21T10:43:34.623Z</lastmod> </url> <url> <loc>https://qis.rwth-aachen.de/teaching/24ss/intro-quantum-computing/script/Introduction-to-Quantum-Computing.epub</loc> - <lastmod>2024-05-16T20:58:05.405Z</lastmod> + <lastmod>2024-05-21T10:44:01.453Z</lastmod> </url> </urlset> diff --git a/_quarto.yml b/_quarto.yml index 52be34a7cf347849f27593835ba066141ac3052a..abeb049e027df4d4954496e4814ec358da00b330 100644 --- a/_quarto.yml +++ b/_quarto.yml @@ -31,7 +31,7 @@ format: callout-appearance: simple pdf: documentclass: scrreprt - papersize: letter + papersize: letter # Necessary for scrreprt! include-in-header: text: | \usepackage{physics} @@ -42,4 +42,4 @@ format: epub: callout-appearance: simple toc: true - html-math-method: webtex \ No newline at end of file + html-math-method: webtex # Requires an internet connection to compile \ No newline at end of file diff --git a/index.qmd b/index.qmd index a09cd380a0db842375b1b3c75df0965cd47c382c..ae3095971822909835687fd94152700212628da8 100644 --- a/index.qmd +++ b/index.qmd @@ -3,7 +3,7 @@ These are the lecture notes for the "Introduction to Quantum Computing" lecture held by Dominique Unruh at RWTH Aachen in the summer term 2024. The lecture notes are updated throughout the semester and should be viewed as an addition to the handwritten notes and the lecture recordings. ::: {.content-visible when-format="html:js"} -If you prefer a `.pdf` or `.epub` file, there is a download available at the top left corner. Please note, that these files are autogenerated and some of the ebook readers have difficulties with the formulas. We are still working on a universal solution. +If you prefer a `.pdf` or `.epub` file, there is a download available at the top left corner. Please note, that these files are autogenerated and some of the ebook readers have difficulties with the formulas. We are still working on a universal solution. You can also find the source code in the top left corner. ::: If you spot an error, please send Jannik Hellenkamp an e-mail. You can contact Jannik by sending an e-mail to firstname.lastname\@rwth-aachen.de (please replace first and lastname with Jannik's full name). If you have a question of understanding, please ask it in the Moodle forum. diff --git a/probabilisticSystems.qmd b/probabilisticSystems.qmd index 91fca788bc1bf8987f3a8a14b46271d994f7b4d6..b5bace12e5554fe059f70b7fe4c61addcb755bc2 100644 --- a/probabilisticSystems.qmd +++ b/probabilisticSystems.qmd @@ -11,7 +11,7 @@ Imagine you have a random number generator, which outputs 2-bit numbers. The cla ::: ## Probability distribution -Next, we need to assign each possibility a probability. We write this as $\Pr[X]=p$ where $p \in [0,1]$ is the probability of the classical possibility $X$. +Next, we need to assign each possibility a probability. We write this as $\Pr[x]=p$ where $p \in [0,1]$ is the probability of the classical possibility $x$. ::: {.callout-tip icon=false} @@ -25,16 +25,16 @@ If we combine all probabilities for all the possible outcomes and write them as ::: {.definition #def-prob-distribution} ## Probability distribution -A vector $M \in \mathbb{R}^n$ is a valid probability distribution iff $\sum M_i = 1$ and $\forall i$ $M_i \geq 0$ +A vector $d \in \mathbb{R}^n$ is a valid probability distribution iff $\sum d_i = 1$ and $\forall i$ $d_i \geq 0$ ::: ::: -This vector has $n$ entries, where each entry corresponds to a classical possibility $X$ and the probability of $X$ is $\Pr[X] = M_i$. The sum over all probabilities has to be $1$ and each entry needs to be nonnegative in order to be a valid probability. +This vector has $n$ entries, where each entry corresponds to a classical possibility $X$ and the probability of $X$ is $\Pr[X] = d_i$. The sum over all probabilities has to be $1$ and each entry needs to be nonnegative in order to be a valid probability. ::: {.callout-tip icon=false} ## Example (continued): Coin flip -For a coin flip the probability distribution would be $M_{\text{coin}} \in \mathbb{R}^2$ with $M = \begin{pmatrix}\frac{1}{2}\\ \frac{1}{2} \end{pmatrix}$ +For a coin flip the probability distribution would be $d_{\text{coin}} \in \mathbb{R}^2$ with $d = \begin{pmatrix}\frac{1}{2}\\ \frac{1}{2} \end{pmatrix}$ ::: ::: {.callout-tip icon=false} @@ -42,14 +42,14 @@ For a coin flip the probability distribution would be $M_{\text{coin}} \in \math ## Example (continued): Random 2-bit number Recall your random 2-bit number generator from above. Imagine your generator outputs each classical possibility with equal probability, except for the possibility $00$, which is never generated. The corresponding probability distribution would be $$ -M_{\text{2-bit}} = \begin{pmatrix} 0 \\ \frac{1}{3}\\ \frac{1}{3} \\ \frac{1}{3} \end{pmatrix} +d_{\text{2-bit}} = \begin{pmatrix} 0 \\ \frac{1}{3}\\ \frac{1}{3} \\ \frac{1}{3} \end{pmatrix} $$ ::: ## Probabilistic processes With a probability distribution, we can only describe the probabilities of possibilities without any knowledge of a prior state. We therefore add another element to our toolbox of probabilistic systems called a *probabilistic process*. -A probabilistic process is a collection of $n$ probability distributions, where for each classical possibility there is a probability distribution under the condition of that possibility. This lets us have conditional probabilities. We can write this as a matrix, where each column is a probability distribution. +A probabilistic process is a collection of $n$ probability distributions, where for each classical possibility $i$ there is a probability distribution $a_i$. This means, that if the system is in classical possibility $i$ before the process is applied, the system will afterwards be distributed according to $a_i$. We can write this as a matrix, where each column is a probability distribution $a_i$. ::: {.callout-note appearance="minimal" icon=false} ::: {.definition #def-prob-process} @@ -60,7 +60,7 @@ A matrix $A \in \mathbb{R}^{n\times n}$ is a valid probabilistic process iff for ::: ::: -From @def-prob-distribution we know that a valid probability distribution $a$ has the properties $\sum a_i = 1$ and $\forall i$ $a_i \geq 0$, so a matrix $A \in \mathbb{R}^{n \times n}$ with $\sum a_i = 1$ and $\forall i$ $a_i \geq 0$ is a probabilistic process. This matrix is also called a *stochastic matrix*. +From @def-prob-distribution we know that a valid probability distribution $a$ has the properties $\sum a_i = 1$ and $\forall i$ $a_i \geq 0$, therefore a matrix $A$ is a probabilistic process iff $A \in \mathbb{R}^{n \times n}$ with $\sum a_i = 1$ and $\forall i$ $a_i \geq 0$ . Such a matrix is also called a *stochastic matrix*. ::: {.callout-tip icon=false} @@ -96,7 +96,7 @@ $$ ## Example (continued): Random 2-bit number Recall the 2-bit number generator and the bit flip from above. Imagine you would first draw a random 2-bit number from the generator and then run the bit flip device. We already know that the probability distribution of the generator is $M_\text{2-bit}$. Using $A_\text{flip}$ we can calculate the final probability distribution: $$ -A_\text{flip} \cdot M_\text{2-bit} = \begin{pmatrix} \frac{2}{3} & 0 & 0 & \frac{1}{3} \\ 0 & \frac{2}{3} & \frac{1}{3} & 0 \\ 0 & \frac{1}{3} & \frac{2}{3} & 0 \\ \frac{1}{3} & 0 & 0 & \frac{2}{3} \end{pmatrix}\begin{pmatrix} 0 \\ \frac{1}{3}\\ \frac{1}{3} \\ \frac{1}{3} \end{pmatrix} = \begin{pmatrix} \frac{1}{9} \\ \frac{1}{3}\\ \frac{1}{3} \\ \frac{2}{9} \end{pmatrix} +A_\text{flip} \cdot d_\text{2-bit} = \begin{pmatrix} \frac{2}{3} & 0 & 0 & \frac{1}{3} \\ 0 & \frac{2}{3} & \frac{1}{3} & 0 \\ 0 & \frac{1}{3} & \frac{2}{3} & 0 \\ \frac{1}{3} & 0 & 0 & \frac{2}{3} \end{pmatrix}\begin{pmatrix} 0 \\ \frac{1}{3}\\ \frac{1}{3} \\ \frac{1}{3} \end{pmatrix} = \begin{pmatrix} \frac{1}{9} \\ \frac{1}{3}\\ \frac{1}{3} \\ \frac{2}{9} \end{pmatrix} $$ ::: diff --git a/quantumSystems.qmd b/quantumSystems.qmd index 00d590adfcb1c830b21a3e1f0d388ce7408c0f1b..d1922d6b5cb12a3dc76d214df579e83210431592 100644 --- a/quantumSystems.qmd +++ b/quantumSystems.qmd @@ -3,7 +3,7 @@ With the basics for a probabilistic system defined, we now look into describing | Probabilistic world | Quantum world | | --------- | ----------- | -| Header | Title | +| Probability distributions | Quantum states | | Paragraph | Text | @@ -13,4 +13,6 @@ With the basics for a probabilistic system defined, we now look into describing ## Quantum State A quantum state is a vector $\psi \in \mathbb{C}^n$ with $\sqrt{\sum |\psi|^2} = 1$ -::: \ No newline at end of file +::: + +## Unitary transformation \ No newline at end of file