.. DO NOT EDIT. .. THIS FILE WAS AUTOMATICALLY GENERATED BY SPHINX-GALLERY. .. TO MAKE CHANGES, EDIT THE SOURCE PYTHON FILE: .. "api/gallery/condensed/josephson/plot_josephson_rcsj.py" .. LINE NUMBERS ARE GIVEN BELOW. .. only:: html .. note:: :class: sphx-glr-download-link-note :ref:`Go to the end ` to download the full example code. .. rst-class:: sphx-glr-example-title .. _sphx_glr_api_gallery_condensed_josephson_plot_josephson_rcsj.py: Josephson's tunnelling supercurrent: the RCSJ junction and the SQUID ===================================================================== Josephson (1962) predicted that Cooper pairs tunnel between two superconductors with a current :math:`I = I_c\sin\varphi`, set by the difference of their phases, while a voltage makes the phase wind at :math:`\dot\varphi = 2eV/\hbar`. Shunting the junction by its resistance and capacitance (Stewart and McCumber, 1968) turns it into a damped pendulum driven by the bias current, :math:`\beta_c\ddot\varphi + \dot\varphi + \sin\varphi = I/I_c` (:func:`~physicskit.condensed.josephson.rcsj_trajectory`). Below :math:`I_c` the phase stands still and no voltage appears; above it the phase runs and the overdamped junction shows :math:`\langle V\rangle = I_cR\sqrt{(I/I_c)^2 - 1}` (:func:`~physicskit.condensed.josephson.rcsj_iv_curve`), while a capacitive one (:math:`\beta_c > 1`) is hysteretic. Two junctions in a loop form a dc SQUID whose critical current oscillates with the enclosed flux in units of :math:`\Phi_0 = h/2e` (:func:`~physicskit.condensed.josephson.squid_critical_current`; Jaklevic et al., 1964). .. GENERATED FROM PYTHON SOURCE LINES 22-28 .. code-block:: Python import matplotlib.pyplot as plt import numpy as np from physicskit.condensed.josephson import FLUX_QUANTUM, rcsj_iv_curve, rcsj_trajectory, squid_critical_current .. GENERATED FROM PYTHON SOURCE LINES 29-31 Phase dynamics: locked below I_c, running above ------------------------------------------------ .. GENERATED FROM PYTHON SOURCE LINES 31-41 .. code-block:: Python fig, axes = plt.subplots(1, 2, figsize=(12, 4.5)) for i in [0.8, 1.05, 1.5]: t, phi, v = rcsj_trajectory(i, beta_c=0.0, dt=0.02, n_steps=3000) axes[0].plot(t, v, lw=1.5, label=f"$I/I_c$ = {i}") axes[0].set_xlabel(r"time ($\hbar / 2eRI_c$)") axes[0].set_ylabel(r"$V / I_cR = \dot\varphi$") axes[0].set_title("Overdamped junction: voltage pulses at each phase slip") axes[0].legend(fontsize=8) .. image-sg:: /api/gallery/condensed/josephson/images/sphx_glr_plot_josephson_rcsj_001.png :alt: Overdamped junction: voltage pulses at each phase slip :srcset: /api/gallery/condensed/josephson/images/sphx_glr_plot_josephson_rcsj_001.png :class: sphx-glr-single-img .. rst-class:: sphx-glr-script-out .. code-block:: none .. GENERATED FROM PYTHON SOURCE LINES 42-47 I-V curves and hysteresis ------------------------- The current is swept up and back down; the state carries over, as in the laboratory. .. GENERATED FROM PYTHON SOURCE LINES 47-63 .. code-block:: Python i_up = np.linspace(0.0, 2.0, 41) v_od = rcsj_iv_curve(i_up, beta_c=0.0) beta_c = 10.0 v_up = rcsj_iv_curve(i_up, beta_c=beta_c) v_down = rcsj_iv_curve(i_up[::-1], beta_c=beta_c)[::-1] axes[1].plot(v_od, i_up, lw=2, label=r"$\beta_c = 0$") axes[1].plot(np.sqrt(np.clip(i_up**2 - 1, 0, None)), i_up, "k:", lw=1, label=r"$\sqrt{i^2 - 1}$") axes[1].plot(v_up, i_up, "C1-", lw=2, label=rf"$\beta_c = {beta_c:g}$, sweep up") axes[1].plot(v_down, i_up, "C1--", lw=2, label=rf"$\beta_c = {beta_c:g}$, sweep down") axes[1].set_xlabel(r"$\langle V\rangle / I_cR$") axes[1].set_ylabel(r"$I / I_c$") axes[1].set_title("RCSJ current-voltage curves") axes[1].legend(fontsize=8) fig.tight_layout() .. GENERATED FROM PYTHON SOURCE LINES 64-66 The dc SQUID ------------ .. GENERATED FROM PYTHON SOURCE LINES 66-77 .. code-block:: Python flux = np.linspace(-2, 2, 500) fig2, ax2 = plt.subplots(figsize=(7, 4.5)) for alpha in [0.0, 0.3]: ax2.plot(flux, squid_critical_current(flux, asymmetry=alpha), lw=2, label=rf"asymmetry $\alpha$ = {alpha}") ax2.set_xlabel(r"$\Phi / \Phi_0$") ax2.set_ylabel(r"$I_{max} / I_c$") ax2.set_title(rf"dc SQUID, $\Phi_0 = h/2e = {FLUX_QUANTUM:.4e}$ Wb") ax2.legend(fontsize=8) fig2.tight_layout() .. image-sg:: /api/gallery/condensed/josephson/images/sphx_glr_plot_josephson_rcsj_002.png :alt: dc SQUID, $\Phi_0 = h/2e = 2.0678e-15$ Wb :srcset: /api/gallery/condensed/josephson/images/sphx_glr_plot_josephson_rcsj_002.png :class: sphx-glr-single-img .. GENERATED FROM PYTHON SOURCE LINES 78-83 Check ----- Phi_0 = 2.0678e-15 Wb; no voltage below I_c; v = sqrt(i^2 - 1) above it for beta_c = 0; the beta_c = 10 junction is hysteretic and ohmic at high bias; the SQUID modulates with period Phi_0, vanishing at Phi_0 / 2. .. GENERATED FROM PYTHON SOURCE LINES 83-92 .. code-block:: Python assert abs(FLUX_QUANTUM / 2.067833848e-15 - 1) < 1e-9 assert np.all(np.abs(v_od[i_up < 0.95]) < 1e-6) above = i_up > 1.1 np.testing.assert_allclose(v_od[above], np.sqrt(i_up[above] ** 2 - 1), rtol=5e-3) mid = (i_up > 0.6) & (i_up < 0.95) assert np.all(v_up[mid] < 1e-4) and np.all(v_down[mid] > 0.5 * i_up[mid]) assert abs(v_down[-1] / i_up[-1] - 1) < 0.05 np.testing.assert_allclose(squid_critical_current(flux + 1), squid_critical_current(flux), atol=1e-12) assert squid_critical_current(0.5) < 1e-12 .. rst-class:: sphx-glr-timing **Total running time of the script:** (0 minutes 1.295 seconds) .. _sphx_glr_download_api_gallery_condensed_josephson_plot_josephson_rcsj.py: .. only:: html .. container:: sphx-glr-footer sphx-glr-footer-example .. container:: sphx-glr-download sphx-glr-download-jupyter :download:`Download Jupyter notebook: plot_josephson_rcsj.ipynb ` .. container:: sphx-glr-download sphx-glr-download-python :download:`Download Python source code: plot_josephson_rcsj.py ` .. container:: sphx-glr-download sphx-glr-download-zip :download:`Download zipped: plot_josephson_rcsj.zip ` .. only:: html .. rst-class:: sphx-glr-signature `Gallery generated by Sphinx-Gallery `_