From 4d1ac5c973efbf266a6451a88bc3ed81b58cdb6c Mon Sep 17 00:00:00 2001 From: Craig Gidney Date: Tue, 23 Jan 2024 23:01:50 -0800 Subject: [PATCH] regen --- doc/gates.md | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) diff --git a/doc/gates.md b/doc/gates.md index 05b314b59..de61175c3 100644 --- a/doc/gates.md +++ b/doc/gates.md @@ -26,6 +26,7 @@ - [CXSWAP](#CXSWAP) - [CY](#CY) - [CZ](#CZ) + - [CZSWAP](#CZSWAP) - [ISWAP](#ISWAP) - [ISWAP_DAG](#ISWAP_DAG) - [SQRT_XX](#SQRT_XX) @@ -36,6 +37,7 @@ - [SQRT_ZZ_DAG](#SQRT_ZZ_DAG) - [SWAP](#SWAP) - [SWAPCX](#SWAPCX) + - [SWAPCZ](#SWAPCZ) - [XCX](#XCX) - [XCY](#XCY) - [XCZ](#XCZ) @@ -1103,6 +1105,51 @@ Decomposition (into H, S, CX, M, R): H 1 + +### The 'CZSWAP' Gate + +Alternate name: `SWAPCZ` + +A combination CZ-and-SWAP gate. +This gate is kak-equivalent to the iswap gate. + +Parens Arguments: + + This instruction takes no parens arguments. + +Targets: + + Qubit pairs to operate on. + +Example: + + CZSWAP 5 6 + CZSWAP 42 43 + CZSWAP 5 6 42 43 + +Stabilizer Generators: + + X_ -> ZX + Z_ -> _Z + _X -> XZ + _Z -> Z_ + +Unitary Matrix (little endian): + + [+1 , , , ] + [ , , +1 , ] + [ , +1 , , ] + [ , , , -1 ] + +Decomposition (into H, S, CX, M, R): + + # The following circuit is equivalent (up to global phase) to `CZSWAP 0 1` + H 0 + CX 0 1 + CX 1 0 + H 1 + + ### The 'ISWAP' Gate