Jump to content

Swap test

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by Lamontap (talk | contribs) at 14:08, 7 May 2021 (Removed the Pseudocode section: it contained an erroneous claim (that s approaches |<phi|psi>|^2 asymptotically) . Consider the counter-example |00...01> and |00...00>. They are orthogonal states, yet the value of s approaches 1 since all but one of the qubits are identical.). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.

The Swap test is a procedure in quantum computation that is used to check how much two quantum states differ.[1]

Consider two states: and . The state of the system at the beginning of the protocol is . After the Hadamard gate, the state of the system is . The controlled SWAP gate transforms the state into . The second Hadamard gate results in

The Measurement gate on the first qubit ensures that it's 0 with a probability of

when measured. If and are orthogonal , then the probability that 0 is measured is . If the states are equal , then the probability that 0 is measured is 1.[2]

References

  1. ^ Kang Min-Sung, Heo Jino, Choi Seong-Gon, Moon Sung, Han Sang-Wook (2019). "Implementation of SWAP test for two unknown states in photons via cross-Kerr nonlinearities under decoherence effect". Scientific Reports. 9 (1). doi:10.1038/s41598-019-42662-4.{{cite journal}}: CS1 maint: multiple names: authors list (link)
  2. ^ Harry Buhrman, Richard Cleve, John Watrous, Ronald de Wolf (2001). "Quantum Fingerprinting". Physical Review Letters. 87 (16). arXiv:quant-ph/0102001. doi:10.1103/PhysRevLett.87.167902.{{cite journal}}: CS1 maint: multiple names: authors list (link)