Skip to content

Commit

Permalink
Circuit: improve gates (3qb and param'd)
Browse files Browse the repository at this point in the history
  • Loading branch information
jcmgray committed Sep 10, 2023
1 parent d4c8b82 commit f95252e
Show file tree
Hide file tree
Showing 5 changed files with 372 additions and 211 deletions.
2 changes: 2 additions & 0 deletions quimb/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@
ccY,
ccZ,
controlled_swap,
cswap,
fredkin,
toffoli,
ham_heis,
Expand Down Expand Up @@ -367,6 +368,7 @@
"ccY",
"ccZ",
"controlled_swap",
"cswap",
"fredkin",
"toffoli",
"ham_heis",
Expand Down
2 changes: 1 addition & 1 deletion quimb/gen/operators.py
Original file line number Diff line number Diff line change
Expand Up @@ -491,7 +491,7 @@ def cZ(dtype=complex, sparse=False):

@functools.lru_cache(8)
def ccX(dtype=complex, sparse=False):
"""The double controlled X gate.
"""The double controlled X gate, or Toffoli gate.
"""
op = ncontrolled_gate(2, pauli('X'), dtype=dtype, sparse=sparse)
make_immutable(op)
Expand Down
Loading

0 comments on commit f95252e

Please sign in to comment.