Skip to content

Commit

Permalink
deploy: 096a54b
Browse files Browse the repository at this point in the history
  • Loading branch information
asemposki committed Jan 9, 2024
1 parent 6c73018 commit 82f7a60
Show file tree
Hide file tree
Showing 7 changed files with 49 additions and 49 deletions.
Binary file added _images/josephson_junction_circuit.JPG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added _images/lc_circuit.JPG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 3 additions & 3 deletions _sources/markdown-notebooks.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"cells": [
{
"cell_type": "markdown",
"id": "56e13288",
"id": "49df5fc3",
"metadata": {},
"source": [
"# Notebooks with MyST Markdown\n",
Expand All @@ -19,7 +19,7 @@
{
"cell_type": "code",
"execution_count": 1,
"id": "cf120166",
"id": "637a303b",
"metadata": {},
"outputs": [
{
Expand All @@ -36,7 +36,7 @@
},
{
"cell_type": "markdown",
"id": "6b6b630e",
"id": "0835a823",
"metadata": {},
"source": [
"When your book is built, the contents of any `{code-cell}` blocks will be\n",
Expand Down
36 changes: 18 additions & 18 deletions horbm/classical.html
Original file line number Diff line number Diff line change
Expand Up @@ -463,19 +463,19 @@ <h1>Quantum Harmonic Oscillator as a two level system<a class="headerlink" href=
<section id="background">
<h2>Background<a class="headerlink" href="#background" title="Permalink to this heading">#</a></h2>
<p>Let us consider the Schrodinger equation for the 1-d Harmonic Oscillator:</p>
<div class="amsmath math notranslate nohighlight" id="equation-9a80f6ed-5241-4fe7-8669-03ced7cf42c7">
<span class="eqno">(6)<a class="headerlink" href="#equation-9a80f6ed-5241-4fe7-8669-03ced7cf42c7" title="Permalink to this equation">#</a></span>\[\begin{align}
<div class="amsmath math notranslate nohighlight" id="equation-085840ec-a7a8-4e88-9622-477b1761009d">
<span class="eqno">(6)<a class="headerlink" href="#equation-085840ec-a7a8-4e88-9622-477b1761009d" title="Permalink to this equation">#</a></span>\[\begin{align}
&amp;\Big(- \frac{d^{2}}{dx^{2}} + V_\alpha (x) - \lambda \Big) \phi = 0, \\
\end{align}\]</div>
<p>where <span class="math notranslate nohighlight">\(V_\alpha(x)=\alpha x^{2}\)</span>. This equation can be written a</p>
<div class="amsmath math notranslate nohighlight" id="equation-641108b3-00f9-44e0-b3f6-ee81769ebace">
<span class="eqno">(7)<a class="headerlink" href="#equation-641108b3-00f9-44e0-b3f6-ee81769ebace" title="Permalink to this equation">#</a></span>\[\begin{align}
<div class="amsmath math notranslate nohighlight" id="equation-e4aa45a5-d492-4a0f-9251-134ccd81a68f">
<span class="eqno">(7)<a class="headerlink" href="#equation-e4aa45a5-d492-4a0f-9251-134ccd81a68f" title="Permalink to this equation">#</a></span>\[\begin{align}
&amp;F_{\alpha}\Big[ \phi_{\alpha}(x) \Big] = H_\alpha\phi - \lambda \phi=0
\end{align}\]</div>
<p>where <span class="math notranslate nohighlight">\(\lambda = 2 m E\)</span> is the eigenvalue with energy <span class="math notranslate nohighlight">\(E\)</span> and <span class="math notranslate nohighlight">\(\alpha = m^{2} \omega^{2}\)</span> is the harmonic oscilation parameter with oscilation frequency <span class="math notranslate nohighlight">\(\omega\)</span>.</p>
<p>The shooting method and finite elements methods are among the many approaches to solve such types of equations using classical computers. During this notebook we will follow the finite element method, in which every object is projected onto a discretized space, the functions <span class="math notranslate nohighlight">\(\phi(x)\)</span> becomes vectors, and the operators <span class="math notranslate nohighlight">\(H_\alpha\)</span> matrices. These vectors and matrices could be composed of houndreds or thousands of elements, making it impossible to store such amount of information in a quantum computer with few qbits. For example, 7 qbits are available in the case of the free version of the IBM services. Therefore, if we want to implement an algorithm in a quantum circuit to find solutions to this equation for many values of the parameter <span class="math notranslate nohighlight">\(\alpha\)</span> we need another strategy. We approximate this equation using dimensionality reduction techniques, such as the <a class="reference external" href="https://link.springer.com/book/10.1007/978-3-319-22470-1">Reduced Basis Method</a>, as was done in <a class="reference external" href="https://kylegodbey.github.io/nuclear-rbm/ho/1dHO.html">this book</a>. These techniques aim at reducing the redundant, or unnecessary, degrees of freedom of the system from many thousand to just a handful. This is done by first restricting the solution to the equation to lay in the span of a basis of <span class="math notranslate nohighlight">\(n\)</span> states:</p>
<div class="amsmath math notranslate nohighlight" id="equation-61c6e760-1ca3-4e81-9058-9c81252cc465">
<span class="eqno">(8)<a class="headerlink" href="#equation-61c6e760-1ca3-4e81-9058-9c81252cc465" title="Permalink to this equation">#</a></span>\[\begin{align}
<div class="amsmath math notranslate nohighlight" id="equation-007f0572-609a-4830-b595-4b849c90bc67">
<span class="eqno">(8)<a class="headerlink" href="#equation-007f0572-609a-4830-b595-4b849c90bc67" title="Permalink to this equation">#</a></span>\[\begin{align}
\hat{\phi}_{\alpha}(x) = \sum_{i=1}^{n} a_{i} \phi_{i}(x)
\end{align}\]</div>
<p>where <span class="math notranslate nohighlight">\(\phi_{i}(x)\)</span> are informed on previous solutions built on a classical computer to the Schrodinger equation for chosen values of <span class="math notranslate nohighlight">\(\alpha\)</span>.</p>
Expand Down Expand Up @@ -745,35 +745,35 @@ <h3>Proper Orthogonal Decomposition<a class="headerlink" href="#proper-orthogona
<h3>Effective two level system “Hamiltonian”<a class="headerlink" href="#effective-two-level-system-hamiltonian" title="Permalink to this heading">#</a></h3>
<p>We will now model an effective hamiltonian in which two “particles” interact, each one represents one of these two components.</p>
<p>Here we explicitly construct <span class="math notranslate nohighlight">\( \hat{\phi}_{\alpha}= a_{1} \phi_{1}+a_2\phi_2\)</span> and use the Galerkin method, that is, projecting <span class="math notranslate nohighlight">\(F_{\alpha}\big( \hat{\phi}_{\alpha}(x) \big)\)</span> over <span class="math notranslate nohighlight">\(2\)</span> linearly independent functions projecting functions <span class="math notranslate nohighlight">\(\{ \psi_{i}\}_{i=1}^{2}\)</span>.</p>
<div class="amsmath math notranslate nohighlight" id="equation-b753dac4-452d-422a-9fea-9fff1e0dc9e0">
<span class="eqno">(9)<a class="headerlink" href="#equation-b753dac4-452d-422a-9fea-9fff1e0dc9e0" title="Permalink to this equation">#</a></span>\[\begin{align}
<div class="amsmath math notranslate nohighlight" id="equation-efd3d85d-642c-4269-aa16-a4abdb2308aa">
<span class="eqno">(9)<a class="headerlink" href="#equation-efd3d85d-642c-4269-aa16-a4abdb2308aa" title="Permalink to this equation">#</a></span>\[\begin{align}
&amp;\langle \psi{1}| F_{\alpha}\big( \hat{\phi}_{\alpha}(x) \big) \rangle = 0 \\
&amp;\langle \psi{2}| F_{\alpha}\big( \hat{\phi}_{\alpha}(x) \big) \rangle = 0
\end{align}\]</div>
<p>We can interpret this as enforcing the orthogonality of <span class="math notranslate nohighlight">\(F_{\alpha}\big( \hat{\phi}_{\alpha}(x) \big)\)</span> to the subspace spanned by <span class="math notranslate nohighlight">\(\{\psi_{i}\}\)</span> that is, by finding <span class="math notranslate nohighlight">\(\hat{\phi}_{\alpha}\)</span> such that <span class="math notranslate nohighlight">\(F_{\alpha}(\hat{\phi}_{\alpha})\)</span> is approximately zero up to the ability of the set <span class="math notranslate nohighlight">\(\{\psi_{i}\}\)</span>. The choice of projecting functions <span class="math notranslate nohighlight">\(\{ \psi_{i} \}\)</span> is arbitrary, but here we choose the solution set <span class="math notranslate nohighlight">\(\{ \phi_{i} \}\)</span> to be our projecting functions to make our lives easier. Since <span class="math notranslate nohighlight">\(\lambda\)</span> is also unknown, we need an additional equation. This comes from the normalization conditions:</p>
<div class="amsmath math notranslate nohighlight" id="equation-97dca402-c132-477e-b2d0-76ec2fcf33b9">
<span class="eqno">(10)<a class="headerlink" href="#equation-97dca402-c132-477e-b2d0-76ec2fcf33b9" title="Permalink to this equation">#</a></span>\[\begin{align}
<div class="amsmath math notranslate nohighlight" id="equation-2a44f50b-6731-4987-847a-1fcbc64b4e46">
<span class="eqno">(10)<a class="headerlink" href="#equation-2a44f50b-6731-4987-847a-1fcbc64b4e46" title="Permalink to this equation">#</a></span>\[\begin{align}
\langle \hat{\phi}_{\alpha_{k}}|\hat{\phi}_{\alpha_{k}} \rangle = 1
\end{align}\]</div>
<p>We can re-write the projecting equations taking advantage of the linear form of <span class="math notranslate nohighlight">\(F_\alpha\)</span> to obtain an effective 2-level system Hamiltonian. We note that:</p>
<div class="amsmath math notranslate nohighlight" id="equation-8592d920-b432-4757-9c3a-54b76d8844a3">
<span class="eqno">(11)<a class="headerlink" href="#equation-8592d920-b432-4757-9c3a-54b76d8844a3" title="Permalink to this equation">#</a></span>\[\begin{align}
<div class="amsmath math notranslate nohighlight" id="equation-564973e6-c6c1-447c-b1ca-18eb7e38c871">
<span class="eqno">(11)<a class="headerlink" href="#equation-564973e6-c6c1-447c-b1ca-18eb7e38c871" title="Permalink to this equation">#</a></span>\[\begin{align}
&amp;\langle \phi_{i}| F_{\alpha}\big( \hat{\phi}_{\alpha}(x) \big) \rangle = \\
&amp;\langle \phi_{i}| a_1 H_\alpha \phi_1 + a_2 H_\alpha \phi_2 - a_1\hat \lambda \phi_1 - a_2\hat \lambda \phi_2\rangle
\end{align}\]</div>
<p>Since <span class="math notranslate nohighlight">\(\langle \phi_i|\phi_j\rangle = \delta _{i,j}\)</span>, we arrive at the following matrix equation for the projecting equations:</p>
<div class="amsmath math notranslate nohighlight" id="equation-2445c96a-f691-49b7-a984-ab1f507e32c4">
<span class="eqno">(12)<a class="headerlink" href="#equation-2445c96a-f691-49b7-a984-ab1f507e32c4" title="Permalink to this equation">#</a></span>\[\begin{equation}
<div class="amsmath math notranslate nohighlight" id="equation-09aa6e6e-ddad-464b-a0de-376a1a082b1d">
<span class="eqno">(12)<a class="headerlink" href="#equation-09aa6e6e-ddad-464b-a0de-376a1a082b1d" title="Permalink to this equation">#</a></span>\[\begin{equation}
\tilde H_\alpha |a\rangle = \hat\lambda |a\rangle
\end{equation}\]</div>
<p>where <span class="math notranslate nohighlight">\(|a\rangle = \{a_1,a_2\}\)</span> and</p>
<div class="amsmath math notranslate nohighlight" id="equation-75e73328-b2bb-4b23-b8be-7bd873f4fc3b">
<span class="eqno">(13)<a class="headerlink" href="#equation-75e73328-b2bb-4b23-b8be-7bd873f4fc3b" title="Permalink to this equation">#</a></span>\[\begin{equation}
<div class="amsmath math notranslate nohighlight" id="equation-9616f70d-0c38-4c53-9ba1-128b74cbcf21">
<span class="eqno">(13)<a class="headerlink" href="#equation-9616f70d-0c38-4c53-9ba1-128b74cbcf21" title="Permalink to this equation">#</a></span>\[\begin{equation}
\tilde H_\alpha = \begin{bmatrix} \langle \phi_1|H_\alpha|\phi_1\rangle &amp; \langle \phi_1|H_\alpha|\phi_2\rangle \\ \langle \phi_2|H_\alpha|\phi_1\rangle &amp; \langle \phi_2|H_\alpha|\phi_2\rangle \end{bmatrix}
\end{equation}\]</div>
<p>while the normalization condition translates into:</p>
<div class="amsmath math notranslate nohighlight" id="equation-c2fc97b3-b13f-4130-a818-2b31cf1a6933">
<span class="eqno">(14)<a class="headerlink" href="#equation-c2fc97b3-b13f-4130-a818-2b31cf1a6933" title="Permalink to this equation">#</a></span>\[\begin{equation}
<div class="amsmath math notranslate nohighlight" id="equation-1ea2aa10-bce7-46e3-aa7f-6fe43414cabf">
<span class="eqno">(14)<a class="headerlink" href="#equation-1ea2aa10-bce7-46e3-aa7f-6fe43414cabf" title="Permalink to this equation">#</a></span>\[\begin{equation}
\langle a|a \rangle = a_1^2+a_2^2= 1
\end{equation}\]</div>
<p>Now we proceed to construct this Hamiltonian matrix for our problem at hand. We note that although <span class="math notranslate nohighlight">\(\tilde H_\alpha\)</span> depends on <span class="math notranslate nohighlight">\(\alpha\)</span>, the dependance is only in the potential part and it is affine (linear): <span class="math notranslate nohighlight">\(H_\alpha=H_0+\alpha H_1\)</span>, where <span class="math notranslate nohighlight">\(H_0= - \frac{d^{2}}{dx^{2}}\)</span> and <span class="math notranslate nohighlight">\(H_1= x^2\)</span>. We then decompose <span class="math notranslate nohighlight">\(\tilde H_\alpha= \tilde H_0 + \alpha \tilde H_1\)</span>. We now construct these matrices:</p>
Expand Down
4 changes: 2 additions & 2 deletions intro-qc/real_hardware.html
Original file line number Diff line number Diff line change
Expand Up @@ -500,9 +500,9 @@ <h3>Superconducting qubits (IBM, Rigetti)<a class="headerlink" href="#supercondu
<p>Superconductor fabrication has long been one of the most impactful technologies of the 20th century. Superconductors are conductors that possess <strong>infinite conductivity</strong>, a concept that seems quite far-fetched but is real! It happens when conduction electrons form Cooper pairs at very low temperatures in a material, and therefore no longer need to obey the Pauli Exclusion Principle [3]. This leads to infinite conductivity, and hence superconductivity.</p>
<p>How do we build this in real life? We can construct a circuit with superconducting wires, cool it to very low temperatures (mK level) and voila! we have a small quantum system! This system exhibits quantum properties and discrete energy levels at a macroscopic level [3]. However, we will need these energy levels to possess nonuniform spacing, or our excitement of electrons to other energy levels will not be as controlled as we would want.</p>
<p>We can begin by constructing a circuit like so:</p>
<p><img alt="image" src="intro-qc/lc_circuit.JPG" /></p>
<p><img alt="image" src="../_images/lc_circuit.JPG" /></p>
<p>Here we have an inductor to store the magnetic field, a capacitor to store electric charge, and superconducting wires. However, this is not enough to create the nonuniform energy levels—to do that, we’ll need to insert what is called a <strong>Josephson junction</strong>. This is shown below, in place of the inductor:</p>
<p><img alt="image" src="intro-qc/josephson_junction_circuit.JPG" /></p>
<p><img alt="image" src="../_images/josephson_junction_circuit.JPG" /></p>
<p>The Josephson junction serves as a capacitor with a non-linear inductance. These are small pieces of insulating material placed between our superconducting materials—hence enabling <em>quantum tunnelling</em> [3]. This also creates the effect of nonuniform energy levels, so our circuit will now work as a robust quantum device! We <em>do</em> still need to have some capacitance control so that our qubit works as part of a quantum computer, however—this is so that the qubit has external controls [3]. To do this, we add a gate capacitor, and make sure that our capacitance is large enough that the energy levels stay separated. This is called entering the <strong>transmon regime</strong>, and hence our qubit is referred to as a <strong>transmon</strong> [3]. These devices are built into a quantum computer.</p>
<div class="highlight-{admonition}Superconducting notranslate"><div class="highlight"><pre><span></span>SQUID devices are instances of superconducting qubits that possess two Josephson junctions directly across from one another. These devices are extremely sensitive to magnetic fields and can detect even extremely weak fields very precisely.
```{glue:figure} squid
Expand Down
Loading

0 comments on commit 82f7a60

Please sign in to comment.