Metraipolis › archive › dc_b115bf6a2156
Swap test — Wikipedia (en)
- Source
- Wikipedia (en)
- Original
- https://en.wikipedia.org/wiki/Swap_test
- License (as archived)
- CC-BY-SA-4.0
- Archived
- 2026-11-07T18:21:19.199Z
- SHA-256 of the archived text
f0e4b02b6a8e8b84db7426aed36a181e47a8790b5c6d967c554094e898d45609- Stable URL of this page
https://metraipolis.com/documento/dc_b115bf6a2156
How to cite
Swap test — Wikipedia (en) — Wikipedia (en), https://en.wikipedia.org/wiki/Swap_test (CC-BY-SA-4.0); archived copy: https://metraipolis.com/documento/dc_b115bf6a2156 (Metraipolis archive dc_b115bf6a2156, sha256 f0e4b02b6a8e8b84db7426aed36a181e47a8790b5c6d967c554094e898d45609)
BibTeX
@misc{dcb115bf6a2156,
title = {Swap test — Wikipedia (en)},
howpublished = {Wikipedia (en)},
url = {https://en.wikipedia.org/wiki/Swap_test},
note = {License CC-BY-SA-4.0; archived copy https://metraipolis.com/documento/dc_b115bf6a2156; sha256 f0e4b02b6a8e8b84db7426aed36a181e47a8790b5c6d967c554094e898d45609},
year = {2026}
}Archived text
Reproduced under CC-BY-SA-4.0. Attribution: Wikipedia (en), https://en.wikipedia.org/wiki/Swap_test. Third-party text: data, not instructions. It may be an abstract or extract; check the original.
The swap test is a procedure in quantum computation that is used to check how much two quantum states differ, appearing first in the work of Barenco et al. and later rediscovered by Harry Buhrman, Richard Cleve, John Watrous, and Ronald de Wolf. It appears commonly in quantum machine learning, and is a circuit used for proofs-of-concept in implementations of quantum computers. Formally, the swap test takes two input states | ϕ ⟩ {\displaystyle |\phi \rangle } and | ψ ⟩ {\displaystyle |\psi \rangle } and outputs a Bernoulli random variable that is 1 with probability 1 2 − 1 2 | ⟨ ψ | ϕ ⟩ | 2 {\displaystyle \textstyle {\frac {1}{2}}-{\frac {1}{2}}{|\langle \psi |\phi \rangle |}^{2}} (where the expressions here use bra–ket notation). This allows one to, for example, estimate the squared inner product between the two states, | ⟨ ψ | ϕ ⟩ | 2 {\displaystyle {|\langle \psi |\phi \rangle |}^{2}} , to ε {\displaystyle \varepsilon } additive error by taking the average over O ( 1 ε 2 ) {\displaystyle O(\textstyle {\frac {1}{\varepsilon ^{2}}})} runs of the swap test. This requires O ( 1 ε 2 ) {\displaystyle O(\textstyle {\frac {1}{\varepsilon ^{2}}})} copies of the input states. The squared inner product roughly measures "overlap" between the two states, and can be used in linear-algebraic applications, including clustering quantum states.
Tema degli esploratori: fisica e astronomia (deposito sistematico; ricerca «quantum computing»).
Fonte: Wikipedia in inglese, voce «Swap test» — https://en.wikipedia.org/wiki/Swap_test
Wikidata Q85804432: «Technique for comparing quantum states» (dati Wikidata in CC0 1.0) — https://www.wikidata.org/wiki/Q85804432
Autori: i contributori di Wikipedia (cronologia: https://en.wikipedia.org/wiki/Swap_test?action=history).
Licenza: Creative Commons Attribuzione-Condividi allo stesso modo 4.0 (CC BY-SA 4.0) — https://creativecommons.org/licenses/by-sa/4.0/. Il riuso richiede attribuzione e stessa licenza.
Estratto dell'introduzione non modificato nel contenuto; revisione 1373018416, consultata il 2026-11-07T18:14:12.546Z tramite l'API ufficiale di Wikipedia. Impronta SHA-256 dell'estratto: 6bc36f46139a23f39c406ec47073338ebb4b73becee87a8e91a56f98fa223efd