ZX-calculus Green Phase Shift
   HOME

TheInfoList



OR:

The ZX-calculus is a rigorous graphical language for reasoning about
linear map In mathematics, and more specifically in linear algebra, a linear map (also called a linear mapping, linear transformation, vector space homomorphism, or in some contexts linear function) is a Map (mathematics), mapping V \to W between two vect ...
s between qubits, which are represented as
string diagrams String diagrams are a formal graphical language for representing morphisms in monoidal categories, or more generally 2-cells in 2-categories. They are a prominent tool in applied category theory. When interpreted in the monoidal category of vector ...
called ''ZX-diagrams''. A ZX-diagram consists of a set of generators called ''spiders'' that represent specific
tensor In mathematics, a tensor is an algebraic object that describes a multilinear relationship between sets of algebraic objects related to a vector space. Tensors may map between different objects such as vectors, scalars, and even other tenso ...
s. These are connected together to form a tensor network similar to
Penrose graphical notation In mathematics and physics, Penrose graphical notation or tensor diagram notation is a (usually handwritten) visual depiction of multilinear functions or tensors proposed by Roger Penrose in 1971. A diagram in the notation consists of several sha ...
. Due to the symmetries of the spiders and the properties of the underlying category, topologically deforming a ZX-diagram (i.e. moving the generators without changing their connections) does not affect the linear map it represents. In addition to the equalities between ZX-diagrams that are generated by topological deformations, the calculus also has a set of graphical rewrite rules for transforming diagrams into one another. The ZX-calculus is ''universal'' in the sense that any linear map between qubits can be represented as a diagram, and different sets of graphical rewrite rules are
complete Complete may refer to: Logic * Completeness (logic) * Completeness of a theory, the property of a theory that every formula in the theory's language or its negation is provable Mathematics * The completeness of the real numbers, which implies t ...
for different families of linear maps. ZX-diagrams can be seen as a generalisation of quantum circuit notation.


History

The ZX-calculus was first introduced by Bob Coecke and Ross Duncan in 2008 as an extension of the
categorical quantum mechanics Categorical quantum mechanics is the study of quantum foundations and quantum information using paradigms from mathematics and computer science, notably monoidal category theory. The primitive objects of study are physical processes, and the diff ...
school of reasoning. They introduced the fundamental concepts of spiders, strong complementarity and most of the standard rewrite rules. In 2009 Duncan and Perdrix found the additional Euler decomposition rule for the
Hadamard gate The Hadamard transform (also known as the Walsh–Hadamard transform, Hadamard–Rademacher–Walsh transform, Walsh transform, or Walsh–Fourier transform) is an example of a generalized class of Fourier transforms. It performs an orthogonal ...
, which was used by Backens in 2013 to establish the first completeness result for the ZX-calculus. Namely that there exists a set of rewrite rules that suffice to prove all equalities between stabilizer ZX-diagrams, where phases are multiples of \pi/2, up to global scalars. This result was later refined to completeness including scalar factors. Following an incompleteness result, in 2017, a completion of the ZX-calculus for the approximately universal \pi/4 fragment was found, in addition to two different completeness results for the universal ZX-calculus (where phases are allowed to take any real value). Also in 2017 the book ''Picturing Quantum Processes'' was released, that builds quantum theory from the ground up, using the ZX-calculus. See also the 2019 book ''Categories for Quantum Theory''.


Informal introduction

ZX-diagrams consist of green and red nodes called ''spiders'', which are connected by ''wires''. Wires may curve and cross, arbitrarily many wires may connect to the same spider, and multiple wires can go between the same pair of nodes. There are also Hadamard nodes, usually denoted by a yellow box, which always connect to exactly two wires. ZX-diagrams represent linear maps between qubits, similar to the way in which quantum circuits represent
unitary Unitary may refer to: Mathematics * Unitary divisor * Unitary element * Unitary group * Unitary matrix * Unitary morphism * Unitary operator * Unitary transformation * Unitary representation * Unitarity (physics) * ''E''-unitary inverse semigroup ...
maps between qubits. ZX-diagrams differ from quantum circuits in two main ways. The first is that ZX-diagrams do not have to conform to the rigid topological structure of circuits, and hence can be deformed arbitrarily. The second is that ZX-diagrams come equipped with a set of rewrite rules, collectively referred to as the ''ZX-calculus''. Using these rules, calculations can be performed in the graphical language itself.


Generators

The building blocks or generators of the ZX-calculus are graphical representations of specific states, unitary operators, linear isometries, and projections in the computational basis , 0 \rangle, , 1 \rangle and the Hadamard-transformed basis , + \rangle = \frac and , - \rangle = \frac. The colour green (or sometimes white) is used to represent the computational basis and the colour red (or sometimes grey) is used to represent the Hadamard-transformed basis. Each of these generators can furthermore be labelled by a phase, which is a real number from the interval controlled-NOT gate can be represented as follows:


Diagram rewriting

The following example of a quantum circuit constructs a
GHZ-state. By translating it into a ZX-diagram, using the rules that "adjacent spiders of the same color merge", "Hadamard changes the color of spiders", and "parity-2 spiders are identities", it can be graphically reduced to a GHZ-state: Any linear map between qubits can be represented as a ZX-diagram, i.e. ZX-diagrams are ''universal''. A given ZX-diagram can be transformed into another ZX-diagram using the rewrite rules of the ZX-calculus if and only if the two diagrams represent the same linear map, i.e. the ZX-calculus is sound In physics, sound is a vibration that propagates as an acoustic wave, through a transmission medium such as a gas, liquid or solid. In human physiology and psychology, sound is the ''reception'' of such waves and their ''perception'' by the ...
and
complete Complete may refer to: Logic * Completeness (logic) * Completeness of a theory, the property of a theory that every formula in the theory's language or its negation is provable Mathematics * The completeness of the real numbers, which implies t ...
.


Formal definition

The category of ZX-diagrams is a dagger compact category">Category theory">category of ZX-diagrams is a symmetric monoidal structure (a tensor product), is
compact closed (it has ''cups'' and ''caps'') and comes equipped with a Dagger category">dagger A dagger is a fighting knife with a very sharp point and usually two sharp edges, typically designed or capable of being used as a thrusting or stabbing weapon.State v. Martin, 633 S.W.2d 80 (Mo. 1982): This is the dictionary or popular-use de ...
, such that all these structures suitably interact. The objects of the category are the natural numbers, with the tensor product given by addition (the category is a PROP A prop, formally known as (theatrical) property, is an object used on stage or screen by actors during a performance or screen production. In practical terms, a prop is considered to be anything movable or portable on a stage or a set, distinct ...
). The morphisms of this category are ZX-diagrams. Two ZX-diagrams compose by juxtaposing them horizontally and connecting the outputs of the left-hand diagram to the inputs of the right-hand diagram. The monoidal product of two diagrams is represented by placing one diagram above the other. Indeed, all ZX-diagrams are built freely from a set of generators via composition and monoidal product, modulo the equalities induced by the compact structure and the rules of the ZX-calculus given below. For instance, the identity of the object n is depicted as n parallel wires from left to right, with the special case n=0 being the empty diagram. The following table gives the generators together with their standard interpretations as linear maps, expressed in
Dirac notation. The computational basis states are denoted by \mid 0 \rangle, \vert 1 \rangle and the
Hadamard Jacques Salomon Hadamard (; 8 December 1865 – 17 October 1963) was a French mathematician who made major contributions in number theory, complex analysis, differential geometry and partial differential equations. Biography The son of a teac ...
-transformed basis states are \mid \pm \rangle = \frac (\vert 0 \rangle \pm \vert 1 \rangle). The n-fold tensor-product of the vector \mid \psi \rangle is denoted by \mid \psi \rangle^. There are many different versions of the ZX-calculus, using different systems of rewrite rules as axioms. All share the meta rule "only the topology matters", which means that two diagrams are equal if they consist of the same generators connected in the same way, no matter how these generators are arranged in the diagram. The following are some of the core set of rewrite rules, here given "up to scalar factor": i.e. two diagrams are considered to be equal if their interpretations as linear maps differ by a non-zero complex factor.


Applications

The ZX-calculus has been used in a variety of
quantum information Quantum information is the information of the state of a quantum system. It is the basic entity of study in quantum information theory, and can be manipulated using quantum information processing techniques. Quantum information refers to both th ...
and computation Computation is any type of arithmetic or non-arithmetic calculation that follows a well-defined model (e.g., an algorithm). Mechanical or electronic devices (or, historically, people) that perform computations are known as ''computers''. An es ...
tasks. * It has been used to describe measurement-based quantum computation and graph state">MBQC">measurement-based quantum computation and graph states. * The ZX-calculus is a language for lattice surgery on surface codes. * It has been used to find and verify correctness of quantum error correcting codes. * It has been used to optimize quantum circuits.


Tools

The rewrite rules of the ZX-calculus can be implemented formally as an instance of double-pushout rewriting. This has been used in the software ''Quantomatic'' to allow automated rewriting of ZX-diagrams (or more general
string diagram String diagrams are a formal graphical language for representing morphisms in monoidal categories, or more generally 2-cells in 2-categories. They are a prominent tool in applied category theory. When interpreted in the monoidal category of vector ...
s). In order to formalise the usage of the "dots" to denote any number of wires, such as used in the spider fusion rule, this software uses ''bang-box'' notation to implement rewrite rules where the spiders can have any number of inputs or outputs. A more recent project to handle ZX-diagrams is PyZX, which is primarily focused on circuit optimisation. A
LaTeX Latex is an emulsion (stable dispersion) of polymer microparticles in water. Latexes are found in nature, but synthetic latexes are common as well. In nature, latex is found as a milky fluid found in 10% of all flowering plants (angiosperms ...
package zx-calculus] can be used to typeset ZX-diagrams.


Related graphical languages

The ZX-calculus is only one of several graphical languages for describing linear maps between qubits. The ''ZW-calculus'' was developed alongside the ZX-calculus, and can naturally describe the W state, W-state and Fermionic quantum computing. It was the first graphical language which had a complete rule-set for an approximately universal set of linear maps between qubits, and the early completeness results of the ZX-calculus use a reduction to the ZW-calculus. A more recent language is the ''ZH-calculus''. This adds the ''H-box'' as a generator, that generalizes the Hadamard gate from the ZX-calculus. It can naturally describe quantum circuits involving Toffoli gates.{{Cite journal, last1=Backens, first1=Miriam, last2=Kissinger, first2=Aleks, date=2019-01-31, title=ZH: A Complete Graphical Calculus for Quantum Computations Involving Classical Non-linearity, journal=Electronic Proceedings in Theoretical Computer Science, volume=287, pages=23–42, doi=10.4204/eptcs.287.2, issn=2075-2180, doi-access=free


Related algebraic concepts

Phaseless spiders in the ZX calculus satisfy the axioms of a
Hopf algebra Hopf is a German surname. Notable people with the surname include: *Eberhard Hopf (1902–1983), Austrian mathematician *Hans Hopf (1916–1993), German tenor *Heinz Hopf (1894–1971), German mathematician *Heinz Hopf (actor) (1934–2001), Swedis ...
with the trivial map as antipode. This can be checked by observing that it is isomorphic to the group algebra of Z_2.


See also

*
Categorical quantum mechanics Categorical quantum mechanics is the study of quantum foundations and quantum information using paradigms from mathematics and computer science, notably monoidal category theory. The primitive objects of study are physical processes, and the diff ...
*
Applied category theory Applied category theory is an Discipline (academia), academic discipline in which methods from category theory are used to study other fields including but not limited to computer science, physics (in particular Categorical quantum mechanics, quant ...
*
String diagram String diagrams are a formal graphical language for representing morphisms in monoidal categories, or more generally 2-cells in 2-categories. They are a prominent tool in applied category theory. When interpreted in the monoidal category of vector ...


References


External links


zxcalculus.com

Quantomatic
Quantum computing