Questions tagged [swap-test]
For questions related to the "Swap test": a quantum algorithm whose purpose is to quantify the distance between two given quantum states.
40
questions
2
votes
1
answer
566
views
Can IBM Quantum hardware handle any CSWAP at all?
I am designing quantum algorithms where the quantum circuit uses CSWAP gates a lot. The result is very noisy on the quantum hardwares. So I designed really simple circuits to test whether it is indeed ...
2
votes
1
answer
57
views
How to compute the measurement probability in the Hadamard test?
In the Hadamard test (e.g., page 40 of these lecture notes) we have:
But if you look at standard textbook reference, like Nielsen and Chuang, there's an example for how to compute the measurement ...
2
votes
0
answers
34
views
Efficient way to compute the $L^1$ norm of quantum state
We all know that the $L^2$ norm
$$
||\psi||_2 = \sqrt{\sum_i |c_i|^2}
$$
of a quantum state $|\psi\rangle = \sum_i c_i |i\rangle$ is always equal to $1$. It is possible to compute the $L^1$ norm
$$
||\...
2
votes
0
answers
77
views
Given three quantum states, how to compute the triple product of amplitudes $\sum_i u_i v_i w_i$?
Assume I have three quantum states $|u\rangle$, $|v\rangle$ and $|w\rangle$ which can be obtained with three quantum circuits $U$, $V$ and $W$.
We know that we can easily estimate the inner product $\...
2
votes
2
answers
331
views
Alternatives to the swap test using a smaller number of qubits
I need to compute the inner product between two generic quantum states. To this aim, one can use the swap test as explained in https://en.wikipedia.org/wiki/Swap_test .
In my case, both of the quantum ...
2
votes
1
answer
69
views
How to implement the state $|\psi\rangle = \frac{1}{\sqrt{2}}\left[|0\rangle \otimes |X_i\rangle + |1\rangle \otimes |X_j\rangle\right]$
I am trying to implement the quantum k-means algorithm proposed in https://arxiv.org/pdf/1909.04226.pdf.
In the equation (8) of the manuscript we need to implement a state $|\psi\rangle = \frac{1}{\...
3
votes
1
answer
102
views
Can we test whether $|\psi\rangle$ is orthogonal to $|\phi\rangle$ without creating a coherent superposition therebetween?
Let a first register store $|\psi\rangle$ and a second register store $|\phi\rangle$, and let us be promised that either $\vert\langle\psi|\phi\rangle\vert^2=0$ or $\vert\langle\psi|\phi\rangle\vert^2=...
0
votes
1
answer
134
views
How to apply error-correction to the swap test circuit?
Swap test is a simple quantum circuit to measure the inner product of two quantum states [Wiki: swap test], it only contains three quantum gates. However, due to the error in the real quantum computer ...
4
votes
1
answer
292
views
What is the "additive error" of Swap Test?
I'm learning the Swap Test, a quantum circuit to calculate the inner product of two quantum states $|\langle \phi|\psi\rangle|^2 $:
For the error analysis of this quantum circuit, according to Swap ...
0
votes
1
answer
119
views
perform a SWAP measurement using local operations and classical feedback
I am interested in performing a SWAP measurement, namely, measure 2 qubits and project their state onto either the triplet state manifold $\{|00\rangle, |11\rangle, |01\rangle + |10\rangle\}$ or the ...
1
vote
0
answers
227
views
Is it possible to design a swap test for three qubits? If it is possible how is it different from 2 and 4 qubits? share the design of the swap test?
Explain the swap test for 2 qubits to find the distance between qubits. Extend the swap test for 3 and 4 qubits. Will the design differ from each other and share the design for both the swap tests?
1
vote
0
answers
36
views
What are the estimate-estimate and estimate-project algorithms for quantum overlap?
In this paper on improvements to the traditional SWAP test to measure quantum state overlap (or fidelity), they mention two methods called estimate-estimate and estimate-project.
I googled about these ...
5
votes
0
answers
210
views
Explanation of the generalized SWAP test: the permutation test?
I am reading this paper on the state separability problem, and came across the term “Permutation Test.” This is on page 7 section 2.3.
Apparently, the more famous SWAP test is a special case of ...
0
votes
1
answer
59
views
How are mixed states given to a quantum algorithm?
I've been reading this paper about quantum fidelity estimation, but really have no idea what's going on when it comes to density matrix notation. In the abstract, they have the following quote:
...
1
vote
1
answer
341
views
pennylane:fidelity calculation after swap test between entagled states. Swap test issue
What I am trying to do is first take an image and encode it into quantum states, for this I have taken an image from the MNIST dataset and then reshaped it to (4,4) and now I wrote the following ...