---
title: Exponential-SWAP (eSWAP) Gate
url: https://www.emergentmind.com/topics/exponential-swap-eswap
type: topic
---

# Exponential-SWAP (eSWAP) Gate

Exponential-SWAP (eSWAP) denotes, in one usage, the continuous two-qubit unitary family $U_{\mathrm{eSWAP}}(\theta)=e^{-i\theta\,\mathrm{SWAP}}$, which interpolates between the identity and the SWAP gate through a continuously tunable exchange angle. In the cited literature, the same label is also used for an exponential-basis extension of singularity-swap quadrature for nearly singular line integrals on closed curves in two dimensions. The shared acronym is therefore best read contextually: in quantum information it refers to exponentiation of the SWAP operator, whereas in numerical analysis it refers to swapping a target singularity to a point close to the unit circle and evaluating the resulting integral in a complex-exponential basis [2002.11728] [2304.11865].

## 1. Two-qubit definition and algebraic action

For two qubits, the SWAP operator is the unitary
\[
\mathrm{SWAP}\,|a,b\rangle = |b,a\rangle
\]
in the computational basis $\{|00\rangle,|01\rangle,|10\rangle,|11\rangle\}$. As a Hermitian involution $\mathrm{SWAP}^2=I$, it has two eigenvalues $+1$ and one eigenvalue $-1$. By spectral calculus one defines the “exponential-SWAP” family
\[
U_{\mathrm{eSWAP}}(\theta)\coloneqq e^{-i\theta\,\mathrm{SWAP}}
= \cos\theta\,I - i\sin\theta\,\mathrm{SWAP}.
\]
Its action is diagonal on $|00\rangle$ and $|11\rangle$,
\[
U_{\mathrm{eSWAP}}(\theta)|00\rangle = e^{-i\theta}|00\rangle,\qquad
U_{\mathrm{eSWAP}}(\theta)|11\rangle = e^{-i\theta}|11\rangle,
\]
while on the single-excitation subspace it acts as
\[
U_{\mathrm{eSWAP}}(\theta)|01\rangle = \cos\theta\,|01\rangle - i\sin\theta\,|10\rangle,
\]
\[
U_{\mathrm{eSWAP}}(\theta)|10\rangle = \cos\theta\,|10\rangle - i\sin\theta\,|01\rangle.
\]
Up to the overall phase $e^{-i\theta}$, this is exactly a rotation in the $\{|01\rangle,|10\rangle\}$ subspace by angle $2\theta$, passing continuously from the identity $(\theta=0)$ to the SWAP gate $(\theta=\pi/2)$ [2002.11728].

An equivalent description uses a natural two-qubit exchange Hamiltonian. In systems with an XY-type interaction
\[
H \propto \sigma_1^x\sigma_2^x+\sigma_1^y\sigma_2^y,
\]
the time evolution
\[
U(t)=\exp[-i\,J^x t\,(\sigma_1^+\sigma_2^-+\sigma_1^-\sigma_2^+)]
\]
coincides, up to local $Z$-phases, with a fractional $i$SWAP on the single-excitation subspace. Setting $\theta=J^x t$ realizes the continuously tunable exchange block that underlies the eSWAP construction.

## 2. Deterministic realization via XY exchange

A direct implementation uses two transmons connected by a tunable coupler. One applies a flux pulse on the coupler that brings the two target qubits into resonance for a duration
\[
t=\theta/J^x,
\]
where $J^x$ is the effective exchange-coupling strength. In a frame that removes the single-qubit energies and absorbs any dynamic $Z$-shifts into later calibrated $Z$-rotations on each qubit, the time evolution is
\[
U(t)
= |00\rangle\langle 00| + |11\rangle\langle 11|
+ \Big[
\cos(\theta)(|01\rangle\langle 01|+|10\rangle\langle 10|)
- i\sin(\theta)(|01\rangle\langle 10|+|10\rangle\langle 01|)
\Big]
\equiv e^{-i\theta(\sigma_1^+\sigma_2^-+\sigma_1^-\sigma_2^+)},
\]
so the native interaction is a fractional $i$SWAP [2002.11728].

To convert this fractional $i$SWAP into exactly $\exp(-i\theta\,\mathrm{SWAP})$, one inserts local $Z$-rotations $\pm\theta$ on each qubit before and after the exchange block. In practice one calibrates the net single-qubit phases and performs them in software as virtual $Z$ gates. The resulting implementation is deterministic, has depth $O(1)$, and uses a single flux-pulse window together with two virtual $Z$’s per side.

The same description gives a concrete duration scale: for $J^x/2\pi\sim 20$ MHz one finds $t\sim \theta\cdot(50\,\mathrm{ns})$, so a $\sqrt{\mathrm{SWAP}}$ at $\theta=\pi/4$ is $\sim 40$ ns. The paper’s central hardware point is that a simple single-flux-pulse on a tunable coupler turns the coupling on for time $t=\theta/J^x$ and directly implements the fractional $i$SWAP, which by local $Z$-rotations can be converted into the eSWAP above.

## 3. Ancilla-based exponentiation and branch correction

As an alternative, the cited work extends Marvian & Lloyd’s method to cyclic non-Hermitian gates. Since $\mathrm{SWAP}^2=I$, SWAP is a Hermitian involution of cyclic order $n=2$. The protocol introduces one ancilla qubit, prepares it in the superposition
\[
|\phi\rangle_a = \cos\theta\,|0\rangle_a - i\sin\theta\,|1\rangle_a,
\]
applies one controlled-SWAP (Fredkin) gate controlled by the ancilla and targeting the two data qubits, and then measures the ancilla in the $X$-basis $\{|+\rangle,|-\rangle\}$, with
\[
| \pm \rangle = (|0\rangle \pm |1\rangle)/\sqrt{2}.
\]
If the outcome is $|+\rangle_a$, the two-qubit register is projected onto
\[
[\cos\theta\,I - i\sin\theta\,\mathrm{SWAP}]\,|\psi\rangle_{12}
\propto e^{-i\theta\,\mathrm{SWAP}}|\psi\rangle_{12},
\]
so one exactly realizes $U_{\mathrm{eSWAP}}(\theta)$ up to a known global normalization [2002.11728].

If instead the result is $|-\rangle$, one obtains
\[
[\cos\theta\,I + i\sin\theta\,\mathrm{SWAP}]\,|\psi\rangle
= e^{+i\theta\,\mathrm{SWAP}}|\psi\rangle,
\]
which can be converted back to the target $U_{\mathrm{eSWAP}}(\theta)$ by a simple corrective routine, either a second controlled-SWAP or a post-measurement phase flip. The feed-forward for the “$-$” branch is described as trivial: because the outcome differs by an extra minus-sign on the SWAP term, a single controlled-$Z$ or a second controlled-SWAP yields the desired sign flip.

The success probability for the “$+$” branch is
\[
p_+ = (\cos\theta+\sin\theta)^2/2.
\]
For small $\theta$ this is $\simeq \tfrac{1}{2}+\theta$, and at $\theta=\pi/4$ one has $p_+=(1+1)/2=1$. With one additional Fredkin, or a controlled-$Z$ plus local SWAP, the protocol can be made fully deterministic.

## 4. Resource counts, fidelity, and simulated performance

The direct and ancilla-based realizations differ in qubit overhead and control primitives, but both were analyzed within the same superconducting-circuit setting. The direct implementation uses $2$ data qubits, $1$ flux-pulse window, two virtual $Z$’s per side, depth $O(1)$, and duration $t=\theta/J^x$. The probabilistic implementation uses $1$ additional ancilla, one controlled-SWAP (Fredkin) gate, two single-qubit rotations on the ancilla, one ancilla readout in the $X$-basis, and post-selection or one correction Fredkin for determinism [2002.11728].

| Method | Resources | Performance statement |
|---|---|---|
| Direct via coupler pulses | 2 data qubits; 1 flux-pulse window; virtual $Z$ gates | Gate times are $\sim 20$–$30$ ns |
| Ancilla-based | 1 ancilla; 1 Fredkin; ancilla rotations and readout | Overall exponentiation fidelities $\gtrsim 98\%$ for small $\theta$ |

The fidelity analysis in Rasmussen and Zinner includes realistic qubit coherence times $T_1=T_2=30\,\mu$s, flux-pulse shaping to avoid leakage, and random $5$–$10\%$ fabrication scatter in circuit parameters using QuTiP master-equation simulations. For the bare controlled-$i$SWAP $(n=1)$ with $J^z/J^x\approx 4$, the reported process fidelities are above $0.998$ in the noiseless case, and $\gtrsim 0.99$ once decoherence is included. Even for up to four controls $(n=4)$ the average fidelity stays $>0.99$ under the same $T_1,T_2$ assumptions. A large Monte-Carlo ensemble with $\pm 10\%$ jitter in Josephson energies and capacitances still yields $>90\%$ of runs above $0.98$ final fidelity.

The same hardware can directly implement the fractional eSWAP via the XY exchange pulse with identical performance numbers. Alternatively, the ancilla-based protocol inherits the underlying controlled-SWAP fidelity $\gtrsim 99\%$ per Fredkin plus single-qubit gates at $>99.9\%$ each, so overall exponentiation fidelities $\gtrsim 98\%$ are readily within reach for small $\theta$.

## 5. Generalizations and algorithmic relevance

The superconducting-coupler toolbox extends beyond a single pair of qubits. Section IV of the cited work shows how to wire up an all-to-all exchange network with each pair of “swapping” qubits gated by its own ancilla or tunable-bus element. One can build $\sqrt{\mathrm{SWAP}}$ or eSWAP operations between any chosen pair, or even three-way or four-way swaps, by the same “turn-on–turn-off” flux control [2002.11728].

The circuit-based exponentiation protocol also generalizes from SWAP to arbitrary cyclic operators. For a general cyclic gate of order $n$, satisfying $T^n=I$, the paper shows that one needs $n-1$ ancillas and $n-1$ controlled-$T$ operations, measured in the $\pm$ basis. The success probability of the all-plus branch scales as $1/2^{n-1}$ for small $\theta$, but may be improved by feed-forward. A specific example in the paper is controlled-$i$SWAP itself, which has order $4$; accordingly, one may build $e^{-i\theta\,i\mathrm{SWAP}}$ exactly with three ancillas and $3$ controlled-$i$SWAPs.

Fractional SWAPs arise in algorithms for quantum walks, Hamiltonian simulation, entanglement distribution and CV-cluster state generation. The cited discussion states that having a native, high-fidelity eSWAP that is continuously tunable in $\theta$ can dramatically reduce Trotter-step counts and gate depths in near-term devices. Within that framing, eSWAP is not merely a gate interpolation, but a hardware-level exchange primitive that can be invoked either directly through analog XY coupling or exactly through ancilla-assisted circuit exponentiation.

## 6. Distinct numerical-analysis usage: exponential-swap quadrature

In a separate numerical-analysis literature, “Exponential-Swap” or eSWAP denotes a quadrature method for evaluating nearly singular line integrals in two dimensions close to periodic boundaries, discretized using the trapezoidal rule. The problem is to evaluate, for a target point $x\in\mathbb{R}^2$ identified with $z\in\mathbb{C}$ close to a smooth closed curve $\Gamma\subset\mathbb{C}$, a layer-potential integral
\[
I(z)=\oint_{\Gamma} K(z,\tau)\sigma(\tau)|d\tau|,
\]
with $\Gamma$ parameterized by a $2\pi$-periodic analytic map $\gamma:[0,2\pi)\to\mathbb{C}$. As $z\to \Gamma$, the integrand ceases to be smooth because there is a nearby singularity at $t=t_0\in\mathbb{C}$ satisfying $\gamma(t_0)=z$, and standard trapezoidal-rule convergence deteriorates like $\exp(-N|\operatorname{Im} t_0|)$ [2304.11865].

The key idea is threefold: find the complex preimage $t_0$ via Newton’s method on the Fourier-interpolant of $\gamma$; swap the singular factor $(\gamma(t)-\gamma(t_0))^{-m}$ for a factor $(e^{it}-e^{it_0})^{-m}$, leaving a smooth remainder $f(t;t_0)$; and expand $f(t;t_0)$ in the basis $\{e^{ikt}\}$ and evaluate the remaining singular integral analytically using contour integrals on the unit circle. Because $f(t;t_0)$ is smooth and $2\pi$-periodic, one samples it at $t_j=2\pi j/N$, computes discrete Fourier coefficients by an FFT, and then approximates
\[
I_m(z)\approx \sum_{k=-N/2}^{N/2-1}\hat h_k\,p_k^{(m)}(t_0),
\]
where the weights
\[
p_k^{(m)}(t_0)=\int_0^{2\pi} e^{ikt}(e^{it}-e^{it_0})^{-m}\,dt
\]
are obtained analytically. For $m=1$ and $\operatorname{Im} t_0>0$,
\[
p_k^{(1)}(t_0)=2\pi e^{i(k-1)t_0}
\]
for $k\ge 1$, and $0$ for $k\le 0$.

The implementation described in the paper precomputes node values $\gamma_j=\gamma(t_j)$ and $\gamma'_j=\gamma'(t_j)$ and their forward FFT’s, finds $t_0\in\mathbb{C}$ starting from the real node whose $\gamma_j$ is closest to $z$, performs $2$–$3$ steps of Newton’s method, forms the regularized samples
\[
f_j=\sigma_j\gamma'_j\cdot
\frac{(e^{it_j}-e^{it_0})^m}{(\gamma_j-\gamma(t_0))^m},
\]
computes $\hat h_k$ by FFT in $O(N\log N)$, and evaluates the final dot product with the explicit residue-theorem formula for $p_k^{(m)}(t_0)$. The total cost per target is $O(N\log N)$. To achieve a relative precision $\epsilon$, one needs roughly
\[
N\gtrsim \frac{1}{|\operatorname{Im} t_0|}\log(1/\epsilon).
\]

The theoretical error estimate is
\[
|I_m(z)-I_m^{(N)}(z)|=O(e^{-cN}),\qquad c=|\operatorname{Im} t_0|,
\]
because $f(t;t_0)$ is analytic in the strip $|\operatorname{Im} t|<|\operatorname{Im} t_0|$ and its Fourier coefficients decay like $\exp(-|k|\,|\operatorname{Im} t_0|)$. Empirical results on the starfish geometry $\gamma(t)=(1+0.3\cos 5t)e^{it}$ with $N$ up to $400$ show that standard trapezoidal-rule suffers $O(1)$ loss in accuracy as $z\to \Gamma$, whereas eSWAP attains $10^{-12}\ldots 10^{-14}$ accuracy uniformly down to distances as small as $10^{-5}$, with exponential convergence in $N$ independently of distance, and takes $\sim O(10^{-3}\ldots 10^{-2}\,\mathrm{s})$ per target at $N=400$ on a laptop. In this usage, eSWAP is therefore a singular quadrature scheme rather than a quantum gate, despite the identical acronym.

Source: https://www.emergentmind.com/topics/exponential-swap-eswap