THE ROLE OF COMPOSITIONALITY IN CONSTRUCTING COMPLEMENTARY CLASSICAL STRUCTURES WITHIN QUBIT SYSTEMS

SITI AQILAH BINTI MUHAMAD RASAT
Thesis Submitted to the School of Graduate Studies, Universiti Putra Malaysia,

in Fulfilment of the Requirements for the Degree of Master of Science

All material contained within the thesis, including without limitation text, logos, icons, photographs and all other artwork, is copyright material of Universiti Putra Malaysia unless otherwise stated. Use may be made of any material contained within the thesis for non-commercial purposes from the copyright holder. Commercial use of material may only be made with the express, prior, written permission of Universiti Putra Malaysia.

Copyright $\copyright$ Universiti Putra Malaysia

Abstract of thesis presented to the Senate of Universiti Putra Malaysia in fulfilment of the requirement for the degree of Master of Science.

THE ROLE OF COMPOSITIONALITY IN CONSTRUCTING COMPLEMENTARY CLASSICAL STRUCTURES WITHIN QUBIT SYSTEMS

SITI AQILAH BINTI MUHAMAD RASAT

Chair     :     Prof. Madya Dr. Hishamuddin Bin Zainuddin

Faculty     :     Institute For Mathematical Research

Observables in a quantum system, represented by a Hilbert space, are given by the orthogonal bases of the aforementioned Hilbert space. Categorical Quantum Mechanics provides further abstraction of such observables, allowing for a diagrammatic representation of measurements that extends to quantum processes. Our research studies this abstraction of observables, which has been dubbed as classical structures, in a subtheory of quantum mechanics which focuses on qubit systems (or 2-dimensional quantum system and its composites). We have constructed a procedure that takes the complementary classical structures of a single qubit system and compose them separably via the Kronecker product or 'entangle' them via Bell states to obtain complementary classical structures in $n$-qubit systems. In this present work, we apply our procedure to two qubit and three qubit systems as examples. Then, using rewriting rules of ZX-calculus and tools in graph theory, we searched for maximal complete sets of mutually complementary classical structures (the categorical counterpart of mutually unbiased bases)  among our constructed composite classical structures. For two qubits, we found 13 maximal complete sets of mutually complementary classical structures, and for three qubits, we found 32,448 maximal complete sets of mutually complementary classical structures.

Abstrak tesis yang dikemukakan kepada Senat Universiti Putra Malaysia sebagai memenuhi keperluan untuk ijazah Sarjana Sains.

PERANAN PENGGUBAHAN DALAM MEMBINA STRUKTUR KLASIK PELENGKAP DALAM SISTEM QUBIT

SITI AQILAH BINTI MUHAMAD RASAT

Pengerusi     :     Prof. Madya Dr. Hishamuddin Bin Zainuddin

Fakulti     :     Institut Penyelidikan Matematik

Pembolehcerap dalam sistem kuantum, diwakili oleh ruang Hilbert, diberi oleh asas ortogon ruang Hilbert. Mekanik Kuantum Berkategori menyediakan selanjutnya keabstrakan pembolehcerap tersebut, membenarkan perwakilan berdiagram pengukuran yang merangkumi proses kuantum. Penyelidikan kami mengkaji keabstrakan pembolehcerap yang dijuluki sebagai struktur klasik, dalam subteori mekanik kuantum yang memfokuskan sistem qubit (atau sistem kuantum dua dimensi dan kompositnya). Kami telah membangunkan satu prosedur bagi struktur klasik pelengkap satu sistem qubit tunggal dan menghurainya secara terpisah melalui hasil darab Kronecker atau mengusutkannya melalui keadaan Bell bagi memperolehi struktur klasik pelengkap dalam sistem n-qubit. Dalam kajian ini, kami menggunakan prosedur tersebut untuk sistem dua dan tiga qubit sebagai contoh. Kemudian, dengan petua penulisan semula kalkulus ZX dan alatan teori graf, kami menggelintar bagi set lengkap maksimum struktur klasik yang saling melengkapi (struktur berkategori setara bagi asas saling saksama) antara struktur klasik komposit yang terbina. Bagi dua qubit, kami menjumpai 13 set lengkap maksimum struktur klasik yang saling melengkapi, dan bagi 3 qubit, kami menjumpai 32,448 set lengkap maksimum struktur klasik yang saling melengkapi.

tocchapterList of Figures

tocchapterList of Tables

tocchapterList of Abbreviations

CHAPTER: LIST OF ABBREVIATIONS

SLOCC     Stochastic Local Operations and Classical Communications

TQFT     Topological Quantum Field Theory

CQM     Categorical Quantum Mechanics

CPM     Completely Positive Map(s)

LHS     Left Hand Side

RHS     Right Hand Side

CS     Classical Structure(s)

SC     Separably Composed

NS     Non-Separable

SCCS     Separably Composed Classical Structure(s)

NSCS     Non-Separable Classical Structure(s)

CD     Complementarity Diagram(s)

CHAPTER: INTRODUCTION

Categorical quantum mechanics (CQM) reconstructs quantum processes as diagrams, providing an intuitive way of performing computations that significantly simplifies complex equation-based calculations in quantum mechanics. For example, quantum teleportation can be described using the following picture in CQM:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/01-intro.pdf}
\end{equation*}

where the boxes labelled `System $A$' and `System $B$' represent spatially separated systems.

The same picture could be translated into a quantum circuit. However, the diagrams of CQM not only can be translated into mathematical terms, they form a category, specifically of the monoidal type, and if one wishes to express these diagrams as morphisms within a category in a more traditional manner, they can do so via a functor (details can be found in [Abramsky and Coecke, 2009, Selinger, 2007]). CQM has also evolved since its inception to provide a more general setting for processes which allows for a more detailed picture of quantum processes. This can be found in Section 4.2 of [Coecke and Kissinger, 2016].

In this chapter, we review some basic concepts of the so called process theories and structures within process theories that are integral to our work. The definitions are taken from various articles on CQM and process theories [Abramsky and Coecke, 2009, Coecke, 2006, Coecke and Duncan, 2011, Coecke, 2011, Coecke and Kissinger, 2015]. Then we provide a brief outline of this thesis: our objectives, the procedure used to obtain our objective, and our results.

§ PROCESS THEORIES

A process theory contains two main ingredients: a collection of systems (e.g. natural numbers, grocery items, information), classified by their types, and a collection of processes (e.g. arithmetic, food preparation, algorithm) which transform those systems. For each process, the type of system that it can transform and the type of system it produces must be specified. Furthermore, there is a means of composing processes of which the composition itself is a process in the theory.

Sequential composition of processes.

In this thesis, we adopt the convention of reading diagrams from bottom to top. So, in Fig. <ref>, we have two processes which are composed sequentially, that is, the process labelled $p_1$ is followed by the process labelled $p_2$. Notice that the two processes are joined together by the wire between them. Here, we need a compatibility condition. $p_1$ transforms some system of type $A$ into some system of type $B$. If $p_2$ does not transform a system of type $B$, it should not be able to transform the system produced by $p_1$ and the diagram above is meaningless. Therefore, when composing two processes, $p_1$ and $p_2$, sequentially, the type of system produced by $p_1$ must match the type of system which $p_2$ transforms.

In summary,

A process theory consists of:

* A collection $T$ of system-types, denoted by wires:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/03a-def-systems.pdf}
\end{equation*}

* A collection $P$ of processes, denoted by boxes, where the type of system transformed by a process and the type of system it produces belong to $T$:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/03b-def-processes.pdf}
\end{equation*}

* Each system-type has a unique identity process satisfying the following equation for any process $p\in P$ and pair of system-types $A,B\in T$:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/03c-def-identity.pdf}
\end{equation*}

* A means of composing processes which forms a diagram that is also a process in $P$, that is, $P$ is closed under (sequential) composition (see Fig. <ref>).

The identity process can be considered as the `do nothing' process, i.e. composing it to another process, say $p$ results in $p$. So we can define the identity process for a system-type $A$ as follows:

\begin{equation}
\includegraphics[scale=0.3]{images/01-25/04-do-nothing.pdf}
\end{equation}

A process theory is a category (definition given below); where the system-types are the objects, the processes are the morphisms, the composition of morphisms is defined by the sequential composition between processes.

A category consists of the following data:

* Objects, usually denoted by uppercase letters: $A$, $B$, $C$, ...

* Morphisms, usually denoted by lowercase letters: $f$, $g$, $h$, ...

* For each morphism $f$, there are given objects,

dom$(f)$, cod$(f)$

called the domain and codomain of $f$. We write:

$$f:A\rightarrow B$$

to indicate that $A=\text{dom}(f)$ and $B=\text{cod}(f)$.

* Given morphisms $f:A\rightarrow B$ and $g:B\rightarrow C$, that is, with

there is a given morphism

$$g\circ f:A\rightarrow C$$

* For each object $A$, there is given an morphism

$$1_A:A\rightarrow A$$

called the identity morphism of $A$.

These data are require to satisfy the following laws:

* Associativity:

$$h\circ(g\circ f)=(h\circ g)\circ f$$

for all $f:A\rightarrow B$, $g:B\rightarrow C$, $h:C\rightarrow D$.

* Unit:

$$f\circ 1_A=f=1_B\circ f$$

for all $f:A\rightarrow B$.

A great interest in physics is the study of multipartite systems. We can describe a multipartite system by composing its subsystems but this type of composition must be different than the sequential composition we described above. Since we have set the directional convention to be along the vertical axis, we can compose two systems by placing them side by side so we may distinguish it from the sequential composition. We call this type of composition as parallel composition. Then it follows that we can transform the resulting composite system using two distinct processes, each of which acts on a different subsystem as in Fig. <ref>.

Parallel composition of two processes.

Now we have two ways of composing processes: sequentially and in parallel. However, unlike sequential composition, there is no compatibility condition which needs to be satisfied in order to compose two process in a parallel manner. That is, with parallel composition, the processes remain independent.

As a shorthand, we adopt the symbols $\otimes$ and $\circ$ for parallel and sequential compositions, respectively. That is:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/06-symbol-composition.pdf}
\end{equation*}

Sequential composition has an order built into it, but to express different orderings for parallel composition, we need a process called `swap' which satisfies the equation below:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/07-swap.pdf}
\end{equation*}

Sequentially composing swaps allow us to permute the ordering of a composite system. For example, we can transform $A\otimes B\otimes C\otimes D$ to one of its permutations in the following way:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/08-permutation.pdf}
\end{equation*}

Notice that the associativity of both compositions are built into their diagrams:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/09-associativity.pdf}
\end{equation*}

We already have the identity process for each system-type with respect to sequential composition, i.e. the do nothing process. For parallel composition, there is no identity with respect to process. Instead, there is a special system, given the symbol $I$, which is the so called identity for system-types:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/10-empty-system.pdf}
\end{equation*}

We shall forgo the dashed squares in forthcoming diagrams. The reason we included them to the diagrams above is to highlight the emptiness of $I$. So then, $A$, $A\otimes I$ and $I\otimes A$ are all equivalent to each other:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/11-system-empty.pdf}
\end{equation*}

$I$ is called the `empty system', which is represented by the empty diagram. Therefore, we are able to include those processes with no input and/or no output within our collection of processes. We call a process with no input as `state', a process with no output as `effect', and a process with neither input nor output as `scalar'. As the reader might have noticed, these terms are borrowed from physics. In fact, within a quantum process theory, these special processes match their names [Abramsky and Coecke, 2009].

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/12-state-effect-scalar.pdf}
\end{equation*}

When $\circ$-composing a state and effect, we obtain the Born rule, that is, the following diagram is the probability amplitude of obtaining the effect $\phi$  when measuring the state $\psi$:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/13-born-rule.pdf}
\end{equation*}

A circuit diagram is a diagram constructed from processes, including identities and swaps, by $\circ$- and $\otimes$-compositions.

A process theory equipped with a $\otimes$-composition, where every diagram is a circuit diagram, is a symmetric monoidal category, with $\otimes$-composition as the equipped bifunctor and the empty system as the unit object. This correspondence between a process theory and a category is in fact an equivalence [Joyal and Street, 1991].

A symmetric monoidal category is a category $\mathbf{C}$ equipped with a binary operation $\otimes:\mathbf{C}\times \mathbf{C}\rightarrow \mathbf{C}$ which is functorial, and there exist natural isomorphisms $\alpha,\sigma,\lambda,\rho$ for objects $A$, $B$, $C$ together with a distinguished object $I$:

$$\alpha_{A,B,C}:A\otimes(B\otimes C)\cong(A\otimes B)\otimes C,$$

$$\sigma_{A,B}:A\otimes B\cong B\otimes A,$$

$$\rho_C:I\otimes C\cong C \cong C\otimes I:\lambda_C$$

$\alpha,\sigma,\lambda,\rho$ satisfy certain coherence conditions.

A key difference between $\circ$ and $\otimes$ is the dependency between the processes which they compose:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/14-connectedness.pdf}
\end{equation*}

If we ignore any directional convention, the $\circ$-composition of two processes can be viewed as a correlation, giving us an option to ignore the causal component that is inherent in input-output reading of processes. However, on the other hand, imposing a directional convention on a process theory gives context to its diagrams whereby we know the starting point when reading a diagram. We can obtain both these features if we impose what we shall call a `compact structure' on a process theory.

[Abramsky and Coecke, 2009]
A system-type $A$ is compact if $A\otimes A$ has a state – called cup, $\cup$ – and an effect – called cap, $\cap$ – which satisfy the following equation:

\begin{equation}\label{eq:pre-yank}
\includegraphics[scale=0.3]{images/01-25/15-compact.pdf}
\end{equation}

We call a process theory where every system-type is compact as a compact process theory. A diagram in a compact process theory is called a string diagram.

Since cups and caps are so special, we use the following diagrams for them:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/15-cup-cap.pdf}
\end{equation*}

Then Eq. <ref> becomes:

\begin{equation}\label{eq:yank}
\includegraphics[scale=0.3]{images/01-25/16-yank.pdf}
\end{equation}

The categorical counterpart of a compact process theory is a compact closed category; where the cup and cap of each system-type are its unit and counit, respectively, and the dual object of the system-type is itself. Note that an object in a compact closed category is not necessarily self-dual in general. However, we shall only encounter objects of a compact closed category which are self-dual in this thesis. As such, whenever we mention a compact closed category, we mean a compact closed category where every object is self-dual.

In a compact process theory, there is a bijective correspondence between states and processes:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/17-process-state-duality.pdf}
\end{equation*}

The result above is called the `process-state duality'. In category theory, this equivalence is captured by an isomorphism between two functors which are the categorical counterparts of the mappings in the previous diagrams [Selinger, 2007].

A compact closed category is a symmetric monoidal category where each object $A$ is assigned a dual object $A^*$, together with a unit morphism $\eta_A:I\rightarrow A^*\otimes A$ and a counit morphism $\epsilon_A:A\otimes A^*\rightarrow I$, such that $\lambda_A^{-1}\circ(\epsilon_A\otimes 1_A)\circ\alpha_{A,A^*,A}^{-1}\circ(1_A\otimes\eta_A)\circ\rho_A=1_A$ and $\rho_{A^*}^{-1}\circ(1_{A^*}\otimes\epsilon_A)\circ\alpha_{A^*,A,A^*}\circ(\eta_A\otimes 1_{A^*})\circ\lambda_A=1_{A^*}$.

We can also obtain the process-effect duality from the cup and cap but later, we shall introduce the dagger structure which renders these dualities as equivalent, that is, if we have  process-state duality, then we must have process-effect duality, and vice versa.

Within a compact process theory, any correlation that a pair of systems might have is generated by either the cup or the cap. That is, when two systems $A$ and $B$ are correlated via a state $\chi$, there must be a process $c$ such that:

\begin{equation}
\includegraphics[scale=0.3]{images/01-25/18-state-process.pdf}
\end{equation}

In quantum theory, the process-state duality makes sure that there is only a single class of maximally entangled states (with respect to SLOCC) for a bipartite system [Coecke and Kissinger, 2010]. Another phenomena which can be expressed using the compact structure is quantum teleportation (see Fig. <ref>).

Quantum Teleportation

The diagram in Fig. <ref> is not yet a complete description of quantum teleportation since the measurement performed by Alice is probabilistic and hence, the state which reaches Bob is one of $U_i\circ \psi$ where $U_i$ is a collection of unitary operators (or processes) which represent the possible outcomes of Alice's measurement.

To describe unitary processes, we need a structure which describes adjoints. This is captured by the dagger structure [Selby and Coecke, 2017]. In writing, we use the symbol $\dagger$ to denote the dagger structure. When applying $\dagger$ to a process, we obtain its adjoint, which is also a process.

Within a process theory with a dagger structure, when applying $\dagger$ to a process twice, we obtain the process again. Therefore, it makes sense to graphically represent the adjoint of a diagram (and consequently, processes) as its reflection on the horizontal axis:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/20-dagger.pdf}
\end{equation*}

The categorical counterpart of a process theory with a $\dagger$ structure is called a dagger category [Abramsky and Coecke, 2009, Selinger, 2007].

A dagger category is a category $\mathbf{C}$ together with an involutive, identity-on-objects, contravariant functor $\dagger:\mathbf{C}\rightarrow\mathbf{C}$.

A compact structure and a dagger is compatible when:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/21-dagger-compact.pdf}
\end{equation*}

A process is unitary if it satisfies the following equation:

\begin{equation}\label{eq:unitary}
\includegraphics[scale=0.3]{images/01-25/22-unitary.pdf}
\end{equation}

Therefore, in the quantum teleportation diagram from Fig. <ref>, Bob may obtain the state that Alice sent by performing the adjoint of $U_i$ on the resulting state:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/23-teleport-correct.pdf}
\end{equation*}

But how would Bob know which $U_i^\dagger$ to perform? This can only be done by telling Alice the outcome of his measurement through a classical channel since another quantum communication would result in another probabilistic measurement. In the next section, we provide a brief review on how to present `classicality' in the diagrammatic language of process theories.

We can also introduce diagrammatic counterparts of familiar concepts from the compact and dagger structures.

[Abramsky and Coecke, 2009]
The transpose of a process $f$ is defined as follows:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/24-transpose.pdf}
\end{equation*}

The conjugate of a process $f$ is defined as follows:

\begin{equation*}
\includegraphics[scale=0.3]{images/01-25/25-conjugate.pdf}
\end{equation*}

§ MEASUREMENTS AS DIAGRAMMATIC ALGEBRAS

In quantum theory, there are several no-go theorems which distinguish between quantum data-types and classical data-types. Two of them are the no-cloning and the no-deleting theorems which state that quantum data-types cannot be copied or deleted as can be done to classical data-types. In a process theory, these two features of quantum data-types are the basis for describing classicality.

The mathematical framework for quantum theory relies on linear algebra: a state of a system is represented by the elements of a Hilbert space and the processes performed on states are represented by linear maps between Hilbert spaces. Due to linearity, quantum states cannot be copied uniformly. That is, given the possible states of a quantum system, only a portion of those states can be copied by the same cloning process. These states turn out to be orthogonal to each other. In fact, the vectors representing these states form an orthogonal basis of the Hilbert space which contains the system's possible states. The same applies to the deletion of quantum states.

The category of finite-dimensional complex Hilbert spaces (objects) and the linear maps between them (morphisms) is a dagger compact category. Therefore, quantum processes can be depicted as diagrams of a compact process theory equipped with a dagger structure. Let $\mathcal{B}$ be an orthogonal basis of a finite-dimensional complex Hilbert space $H$. There is a process $\triangledown: H\rightarrow H\otimes H$, which copies the elements of $\mathcal{B}$, and a process $\top:H\rightarrow\mathbb{C}$, which deletes the elements of $\mathcal{B}$. Suppose $\mathcal{B}=\{\ket{j}\}_{j=1}^N$ where $N$ is dimension of $H$. Then:

\begin{eqnarray}
\triangledown(\ket{j})=\ket{j}\ket{j}\\
\top(\ket{j})=1
\end{eqnarray}

$H$ together with $\triangledown,\top,\triangledown^\dagger,\top^\dagger$ form a classical structure. In a process theory, we represent copying and deleting along with their adjoints as the following diagrams:

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/26-classical-structure.pdf}
\end{equation*}

Coecke et al., 2013 showed that any orthogonal basis of a finite-dimensional complex Hilbert space correspond to a classical structure of the Hilbert space. Furthermore, this correspondence is bijective.

We only deal with finite-dimensional complex Hilbert spaces in this work, so henceforth, when we mention Hilbert spaces, we are referring to finite-dimensional complex Hilbert spaces.

The following is an alternative definition of a classical structure which takes the copying and deleting processes as particular spiders.

For a system-type $A$, a classical structure of $A$ consists of spiders with $m$ inputs and $n$ outputs, where $m,n\in\mathbb{N}\cup 0$:

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/27-spider.pdf}
\end{equation*}

such that $m_1,n_1$- and $m_2,n_2$-spiders fuse together when $k$ outputs of one are joined to the $k$ inputs of the other:

\begin{equation}\label{eq:spider-fuse}
\includegraphics[scale=0.2]{images/26-50/28-spider-fusion.pdf}
\end{equation}

and a spider with permuted inputs/outputs is the same as the unpermuted one:

\begin{equation}
\includegraphics[scale=0.2]{images/26-50/29-spider-permutation.pdf}
\end{equation}

A system with a classical structure is automatically compact. That is, the cup is the 2,0-spider and the cap is the 0,2-spider.

\begin{equation}
\includegraphics[scale=0.2]{images/26-50/30-compact.pdf}
\end{equation}

Notice that spiders in a classical structure include those without an input or output, i.e. when $m$ or $n$ is equal to 0. When a spider is fused with these types of spiders, the inputs/outputs joined are terminated. For example:

\begin{equation}
\includegraphics[scale=0.2]{images/26-50/31-spider-delete.pdf}
\end{equation}

The categorical treatment of spiders can be found in [Lack, 2004] and a graphical proof showing the equivalence between the definition of classical structures as an algebra and the one consisting of spiders can be found in [Coecke and Paquette, 2008].

Incidentally, when a measurement is performed on a pure quantum state, the outcomes are represented by an orthogonal basis. In particular, when a measurement with $N$ outcomes is performed on a state $\ket{\psi}=\sum_{j=1}^N\psi_j\ket{j}$, $\ket{\psi}$ will be transformed to one of the states in $\{\ket{j}\}_{j=1}^N$, which forms an orthogonal basis, and the probability of obtaining the $j$-th outcome is $|\psi_j|^2$. In fact, the 2,1-spider takes on the role of measurement in the `single-line means classical' and `double-line means quantum' interpretation of processes [Coecke and Kissinger, 2016]. The 1,2-spider, otherwise known as the adjoint of the 2,1-spider, then becomes the process which encodes classical data into a quantum system.

So when classical data is encoded into a quantum system and then measured, we obtain the identity process:

\begin{equation}\label{eq:decoherence}
\includegraphics[scale=0.2]{images/26-50/32-decoherence.pdf}
\end{equation}

However, a system-type can have more than a single classical structure. So, suppose we have two classical structures. If we encode a quantum system with classical data using the 1,2-spider of one of the classical structures and then measure it with the 2,1-spider of the other classical structure, what will happen to the previous diagram?

The two extremes of the measurement of a state in a basis $\mathcal{B}$ are
(1) accurate result when the measurement is described by $\mathcal{B}$, and (2) Completely random result when the measurement is described by a basis complementary to $\mathcal{B}$. (1) is described by the Eq. <ref>, but (2) is a different story. One would expect a disconnection between the input and output of a similar procedure to Eq. <ref> for (2) as the measurement gives us no information on the system. However, to obtain this disconnection, the diagram on LHS of Eq. <ref> needs a slight modification:

Two classical structures, distinguished by the colours of their nodes are complementary if:

\begin{equation}
\includegraphics[scale=0.2]{images/26-50/33-complementarity.pdf}
\end{equation}

§ THESIS OUTLINE

This thesis is inspired by Romero et al., 2005, where the authors took the complete[In this thesis, a set of mutually unbiased bases is complete if no other basis can be added into the set to form a larger set of mutually unbiased bases. The same goes for a set of mutually complementary classical structures where it is complete if no other classical structure can be added to the set to form a larger set of mutually complementary classical structure.] set of 9 mutually unbiased bases for $N$ qubits from [Wootters and Fields, 1989], say $\mathsf{MUB}_0$, and constructed new complete sets of 9 mutually unbiased bases through the following procedure:

* Each of the basis in $\mathsf{MUB}_0$ is described by a set of $2^N-1$ mutually commuting operators which are the Kronecker products of Pauli operators;

* These constituent Pauli operators are `rotated' by multiplying them with local unitary operators;

* Entanglement between two qubits are generated or eliminated by applying the controlled-$Z$ operator to them.

This procedure is able to produce all the entanglement configurations available for complete sets of 9 mutually unbiased bases. For example, the entanglement configurations for three qubits are (2,3,4), (1,6,2), (0,9,0), and (3,0,6), where the first coordinate is the number of separable bases, the second coordinate is the number of biseparable bases, and the third coordinate is the number of non-separable bases in the set of MUBs. However, the separability of each basis is not immediately obvious. One would need to perform some straightforward but tedious computations to find out the separability of the basis represented by each set of mutually commuting operators.

In this section, we showed how a classical structure is an abstraction of an orthogonal basis. Conceptually, complementarity between classical structures and unbiasedness between orthogonal bases coincide since they both represent an incompatible measurement of an observable which gives a completely random result. Section 8 of reference [Coecke and Duncan, 2011] shows the relationship between complementarity and unbiasedness. So, replicating the results of [Romero et al., 2005] should be possible within the framework of process theories. This is the subject of our current interest as a successful translation of those results in process theories shall provide a more explicit presentation of the entanglement structure in members of a complete set of MUBs on $N$ qubits.

In Chapter <ref>, we shall devise two methods for composing two classical structures on a single qubit so that we can obtain a classical structure on two qubits. One method composes two classical structures on a single qubit and forms a classical structure on two qubits where the constituent classical structures remain separable. The other method composes two classical structures on a single qubit via one of three processes which are entangled on two qubits and forms a non-separable classical structure on two qubits. We shall call these bipartite processes `connecting wires'. We then extend the two methods so we could construct classical structures on $N$ qubits where $N>2$.

The aforementioned constituent classical structures are classical structures on a single qubit that are abstractions of the eigenbases of the Pauli $X$, Pauli $Y$ and Pauli $Z$ operators. We provide a review of of the classical structures which correspond to the Pauli $X$ and $Z$ operators which form a diagrammatic calculus called ZX-calculus in Chapter <ref>. Using ZX-calculus, we construct the classical structure which corresponds to the Pauli $Y$ operator. Composing these classical structures, either separably or via the connecting wires, we shall obtain a collection of classical structures on multiple qubits.

In Chapter <ref>, we identified the precise condition for a pair of classical structures, obtained via the procedure devised in Chapter <ref>, to be complementary. Then we found maximal complete sets of mutually complementary classical structures for the cases of two and three qubits. This is done using tools in graph theory where complete sets of mutually complementary classical structures are complete subgraphs of the graph consisting of classical structures as its vertices and there is an edge between two classical structures if they are complementary. To identify these edges, we found a generating set of pairs of classical structures. Each member of this set represents a class of pairs of classical structures with equivalent complementarity diagrams. This allows us to significantly reduce the number of pairs of classical structures to be checked for complementarity.

§ OBJECTIVES

The objectives of this study are twofold:

* First, we construct classical structures on $N$ qubits ($N\geq 2)$ by identifying its constituents as complementary classical structures on a single qubit, and two methods of composing these constituents, i.e. separably and non-separably, which make explicit the entanglement structure of the composite classical structure.

* Then, we study how the entanglement structure of the composite classical structures that we have constructed relates to their complementarity. In this thesis, we present our findings through examples in two qubits and three qubits. In particular, we searched for maximal complete sets of mutually complementary classical structures among composite classical structures on two and three qubits.

CHAPTER: LITERATURE REVIEW

Mac Lane and Eilenberg introduced category theory while working on problems in algebraic topology, a field which applies the tools of algebra to topological spaces. The paper which introduced the concept of categories, General Theory of Natural Equivalences [Eilenberg and MacLane, 1945], was not well received as it was said to lack any content, and category theory was later dubbed "general abstract nonsense." At the time, Mac Lane and Eilenberg did not seriously consider expanding their study on categories, and instead thought of it more as a convenient language for mathematicians in diverse fields to understand each other [Mac Lane, 1988]. However, it is out of that simple objective that a new mathematics, which in the following decades became an active area of research, was born.

§ APPLIED CATEGORY THEORY VIA DIAGRAMS

In the decades since the publication of [Eilenberg and MacLane, 1945]'s seminal work, category theory has become an important tool for studying the foundation of mathematics [Lambek and J. Scott, 1988], but more than that, it provides a way for various fields, in and outside of mathematics, to communicate with each other [Baez and Stay, 2010]. For example, in computer science, we can form a category by taking data types as objects and the programs which process the data as morphisms. We can find similar structures between the aforementioned category with the category whose objects are propositions, and morphisms are proofs that lead one proposition (the assumption) to another (the conclusion), providing a bridge between computation and logic. Both form monoidal categories, which are categories equipped with a bifunctor that allows for the parallel composition of objects and morphisms.

Another application of category theory is topological quantum field theory (TQFT), a field of study which attempts to reconcile between Einstein's theory of relativity and quantum mechanics by exploring similar structures in the space occupied by the two theories [Atiyah, 1988, Kock, 2004]. It does this by associating compact oriented manifolds to Hilbert spaces. This association can be represented by a monoidal functor between nCob, a category with compact oriented $(n-1)$-dimensional manifolds as objects and oriented $n$-dimensional cobordisms as morphisms, and FHilb, a category with complex Hilbert spaces as objects and linear operators between the Hilbert spaces as morphisms [Baez and Lauda, 2011].

TQFT is not the sole branch of physics that was discovered to contain applications of category theory. The famed Feynman diagrams were found to have categorical roots and were formalized in reference [Joyal and Street, 1991]. [Joyal and Street, 1991] then showed the connection between the Yang-Baxter equation and braiding in Knot Theory [Joyal and Street, 1993] using what they called braided tensor categories. Before Joyal and Street, 1991, physicists have used diagrams such as those invented by Feynman and Penrose to assist in complicated computations. By formalizing these diagrams to be objects and morphisms in a category, specifically a monoidal category, Joyal and Street provided a way for physicists to reason using diagrams in a mathematically rigorous way. More recently, Selinger, 2011 provided a systematic survey of the various graphical languages and their corresponding monoidal categories.

§ CATEGORICAL QUANTUM MECHANICS

Categorical quantum mechanics (henceforth, abbreviated to CQM) is a field of study which not only aims to reconstruct the formalism of quantum mechanics with categories as its backbone, but it also seeks to formalize a graphical description that provides a high level computational method for quantum theory while seeking for new insights into its logical structure [Abramsky and Coecke, 2009]. In this section, we shall provide a review of CQM from its inception in 2004 to recent progress that is relevant to the present thesis.

In their paper A Categorical Semantics of Quantum Protocols [Abramsky and Coecke, 2004], Abramsky and Coecke proposed what they called a strongly closed compact category with biproducts to be the mathematical framework for quantum mechanics, abstracting from FHilb. Throughout the years, the term strongly closed compact category has evolved into dagger compact category, emphasizing the functor equipped with the category that is normally referred to as a dagger. In the same paper [Abramsky and Coecke, 2004], it was shown that well-known quantum protocols — teleportation, logic-gate teleportation, and entanglement swapping — are compatible with a quantum mechanical description in a dagger compact category. Abramsky and Coecke further showed that dagger compact categories are able to accommodate abstract notions of scalars, adjoints, and Born Rule.

As CQM evolved into what it is today, Abramsky, Coecke, and their colleague, Aleks Kissinger made sure to provide updated reviews of the topic [Abramsky and Coecke, 2009, Coecke, 2006, Coecke et al., 2016, Coecke and Kissinger, 2015, Coecke and Kissinger, 2016, Coecke and Kissinger, 2017], each with a different perspective and provides new insights on CQM. To familiarize with the categories behind CQM, reference [Selinger, 2007] by Peter Selinger provides a comprehensive look into them. In the same work, the correspondence between the diagrams in CQM and dagger compact categories was also shown. For a more current and comprehensive paper on the underlying categories of CQM, the reader may refer to [Coecke et al., 2014].

§.§ Additive vs Multiplicative

CQM shifts the question about the logical structure of quantum mechanics away from the study of lattices, which lacks a satisfactory treatment of composite systems, and brought forth the tensor product as a primitive. Coecke emphasized this multiplicative structure in [Coecke, 2007] by showing that the bulk of the required linear structures is purely multiplicative and arises from the tensor (or monoidal) product that is equipped with a dagger compact category. As CQM aims to reduce any unnecessary baggage that comes with the Hilbert space formalism in order to build a more efficient formalism, it is important to examine the roles of additive and multiplicative structures in quantum mechanics.

As a consequence of references [Coecke, 2007] and [Selinger, 2007], Coecke provided an axiomatic description of mixed states [Coecke, 2008]. A quantum mixed state is described by a convex combination of linear operators. The following is an equational description of a mixed quantum state:

\begin{equation*}
\rho = \sum_{j=1}^n p_j \ket{\psi_j}\bra{\psi_j}
\end{equation*}

where each $p_j$ is the probability that $\rho$ is in the pure state described by the vector $\ket{\psi_j}$. Using Selinger's abstract completely positive maps, Coecke makes the sum in the description above implicit, allowing for a less cumbersome graphical representation of mixed states.

This suggests that CQM may render sums as redundant. However, due to the probabilistic nature of quantum mechanics which relies heavily on the use of sums, [Abramsky and Coecke, 2009] included biproducts in their categorical description of quantum mechanics. This is unfortunate as their 2-dimensional string diagrams do not allow for another type of composition.

We shall discuss this issue further in the next section, but eventually, a description that does not rely on sums was found [Coecke and Pavlovic, 2008, Coecke and Paquette, 2008, Selinger, 2007, Coecke, 2008]. This led to the construction of a category of observable algebras and superoperators [Coecke et al., 2014], which was shown to embed the category of completely positive maps with biproducts [Heunen et al., 2014].

§.§ Abstract Bases

In reference [Coecke and Pavlovic, 2008], it was found that sums are an implicit implementation of the capability to copy and delete quantum and classical data types. The key to this procedure is the no-cloning and no-deleting theorems in quantum mechanics. These theorems tell us that quantum and classical data types can be distinguished through their respective capabilities to be copied and deleted; that is, classical data types can be copied and deleted and quantum data types cannot.

For a system represented by an object $A$ in a symmetric monoidal category, we can represent the capability to copy information about the system by the existence of a morphism of the form $A\rightarrow A\otimes A$, called comultiplication, and the capability to delete information by the existence of a morphism of the form $A\rightarrow I$, called counit, where $I$ is the monoidal unit of the category and $\otimes$ is the tensor product equipped with the category. These morphisms must satisfy the axioms of a cocommutative comonoid (the dual of a commutative monoid), and a classical structure can be described as an object equipped with a comultiplication and a counit morphisms.

In a dagger symmetric monoidal category, we automatically obtain a monoid from a comonoid as the equipped dagger functor dualizes the morphisms in the category. To obtain abstract bases, we need a comonoid and the induced monoid to satisfy the Frobenius law, resulting in a dagger Frobenius algebra. It was shown by Coecke et al., 2013 that there is a bijective correspondence between orthogonal bases of finite complex Hilbert spaces with special dagger commutative Frobenius algebras in FHilb. Coecke and Paquette, 2008 also provided an abstraction of POVMs, and showed Naimark's theorem using a purely graphical proof technique. Coecke et al., 2009 then extended their work on abstract quantum measurements to provide a categorical description of classical operations which consequently, provided a resource sensitive account of quantum-classical interactions.

§.§ Observables

In the Hilbert space formalism of quantum mechanics, an observable can be described by an eigenbasis of a Hermitian operator, and so we can use the abstract bases in reference [Coecke et al., 2013] to describe observables in the setting of a symmetric monoidal category. Unlike observables in classical physics which always admit sharp values at the same time, not all quantum observables are compatible in such a way.

This kind of incompatibility is referred to as complementarity in quantum mechanics. Coecke and Duncan, 2008 showed that any pair of complementary observables forms a bialgebra. They then extended their idea on complementarity in a longer paper with a similar title [Coecke and Duncan, 2011] which showed that two complementary observables not only form a bialgebra, but they also form a Hopf algebra. Other developments on complementarity in CQM are detailed in [Coecke et al., 2012] which introduced a stronger notion of complementarity, and [Heunen, 2012] which relates notion of complementarity in von Neumann algebras, Hilbert spaces, and orthomodular lattices.

Abstract observables also allow for a comparison between local and non-local theories. In reference [Coecke et al., 2011], a category for stabilizer qubit theory — which is non-local — and a category for Spekkens' toy theory – which is local — were constructed. The two categories, denoted as Stab and Spek, were shown to be similar except for one key aspect: their phase groups. That is, the phase group for Stab is the cyclic group of order 2, and the phase group for Spek is the Klein group. Reference Coecke et al., 2011 further showed the relationship between phase groups and GHZ state correlations, introducing a key property for classifying between local and non-local behaviours.

Mutually unbiased qubit theories led to the invention of ZX-calculus, a graphical calculus based on the Pauli $Z$ and $X$ spin observables which is intended to be used for quantum computation. In fact, ZX-calculus has been implemented in Quantomatic, an open source software which uses string diagrams to construct equational proofs [Dixon and Duncan, 2009, Kissinger and Zamdzhiev, 2015, Kissinger et al., 2018]. ZX-calculus was shown to be complete for stabilizer quantum mechanics[Backens, 2014], and similar graphical calculus was also developed for Spekkens' toy bit theory [Backens, 2016]. In an article by Duncan, 2012, ZX-calculus was applied to measurement-based quantum computation. More recently, a revised version of ZX-calculus was considered in the setting qutrits [Wang, 2018].

Another important consequence of abstract observables is the ability to depict classical-quantum interactions using the graphical language of CQM. As far as we can tell, Coecke and Pavlovic, 2008 provided the first graphical description of classical-quantum interactions. Coecke and Perdrix, 2012 then refined the notion of classicality by proposing that the distinguishing property between classical and quantum data types as their abilities to be broadcast. In the article, [Coecke and Perdrix, 2012] unified a notion of environment with classical structures to define abstract classical channels, quantum measurements, and classical control. Furthermore, they adjoined the notion of complementarity we discussed earlier to derive some classically controlled quantum protocols. Coecke and Kissinger, 2016 provided an updated discussion on classical-quantum interactions in CQM which could aide comprehension of the articles mentioned as it focuses more on the diagrammatic language of CQM than its categorical counterpart.

The construction of abstract observables highlights the internal algebraic structure of observables. That is, the multiplication morphism of an abstract observable can be treated as a binary operation where the unit morphism is its identity element. It turns out that we can also reveal the algebraic structure of maximally entangled states through this construction. Coecke and Kissinger, 2010 showed that the GHZ-state and W-state (maximally entangled states for tripartite states) induce commutative Frobenius algebras. However, the commutative Frobenius algebra induced by the GHZ-state is special, and the one induced by the W-state is anti-special. This classification of maximally entangled tripartite states yields a compositional graphical model for expressing general multipartite states.

§.§ Foundational Issues

In reference [Coecke et al., 2013], [Coecke et al., 2013] proposed an alternative framework to quantum logic. They recast the order theoretic structure that quantum logic is built upon so that it comes with a primitive composition operation, making the construction completely compositional. When interpreted in FHilb, this construction yields the projection lattices of arbitrary finite-dimensional $C^*$-algebras. This hints at the viability of a root concept in CQM, i.e compositionality, as an alternative to quantum logic's propositional structure. Harding, 2009 has also showed the connection between the notion of a preparation (of a system), as defined by Abramsky and Coecke, 2004, to the notion of orthoalgebras in quantum logic.

Outside of quantum logic, there are also works investigating the connection between CQM and other areas of study which aim to answer the foundational issues of quantum mechanics. Barnum et al., 2013 investigated the connection between CQM and the so called convex operational models, which generalize the probabilistic structure of quantum mechanics using techniques from measure theory and functional analysis. In the article, the category for convex operational models, which is symmetric monoidal, was constructed, along with compact and dagger structures in such a category. Chiribella, 2014 also studied CQM from the context of generalized probabilistic theories. This is part of Chiribella's research to construct a framework for operational-probabilistic theories [Chiribella et al., 2011, Chiribella et al., 2010], which uses diagrams similar to those in CQM. Chiribella's work on causality has also been applied to causal structures in CQM by Coecke and Lal, 2013.

Furthermore, the graphical language of CQM is general enough that one of its founders, Bob Coecke, has dubbed it generalized process theories [Coecke and Kissinger, 2015, Coecke and Kissinger, 2016], and it became the framework for the construction of theories that can be applied beyond quantum mechanics. Examples include resource theories [Coecke et al., 2016] and natural language processing [Piedeleu et al., 2015].

§ CONTRIBUTION TO THE LITERATURE

Since its introduction in 2004, CQM has become an active field of research, so much so that its graphical approach has been applied to areas outside of quantum mechanics. Along with natural language processing, the techniques of CQM has been adapted for network theory [Baez and Biamonte, 2018] — providing pathways to applications in chemistry and biology —  and important tools in mathematical modelling and signal flow graphs, such as [Bonchi et al., 2017, Fong, 2016] and control theory [Baez and Erbele, 2015].

A benefit of CQM's graphical approach, otherwise known as process theories, is its ability to make explicit difficult mathematical concepts, rewriting them as intuitive diagrams. One example is quantum teleportation, which we touched upon in Section <ref>. Another example is linear algebra where a matrix — usually presented as number arrays — are replaced by flow diagrams, which makes explicit the linear map equivalent to it [Sobociński, 2015]. That is, a vector can be inputted into the matrix, like a mathematical machine, and inside the machine, the entries of the vector are multiplied by numbers that are the entries of the matrix, resulting in an output that is a vector.

In this work, we would like to depict the entanglement structure of mutually unbiased bases in qubit systems that appeals to our intuition in ways similar to [Coecke and Kissinger, 2017] and [Sobociński, 2015]. We do this by utilizing the compositionality of process theories to construct classical structures on multiple qubits from classical structures on a single qubit and compose them via parallel composition (see Section <ref>) or bipartite processes that we call `connecting wires'. Then we determine the complementarity between each pair of the resulting classical structures by checking whether or not they satisfy Definition <ref>.

There have been studies related to mutually unbiased bases within the setting of CQM such as the work by Musto, 2017 and that by [Evans et al., 2009]. However, as far as we are aware, our method of composing classical structures has not appeared in any existing literature and we have not found any literature which utilizes the compositionality of process theories to study entanglement structure on mutually unbiased bases in the same way that we do in the present work.

CHAPTER: COMPLEMENTARY CLASSICAL STRUCTURES

Applications of MUBs can be found in quantum key distribution, quantum state determination, detection of quantum entanglement, and various other areas of study in quantum mechanics. Therefore, for any model of quantum mechanics, it should be of utmost interest to have a description of MUBs. Indeed, we gave this description in Definition <ref> within a process-theoretic framework.

While techniques for finding a pair of MUBS in Hilbert spaces are available [Durt et al., 2010], searching for maximal complete sets of MUBs is much trickier. In fact, searching for a maximal complete set of MUBs for a Hilbert space with non prime power dimension is such a notoriously difficult problem that even for the smallest dimension of six, experts only have a strong suspicion that there are at most three mutually unbiased bases.

As far as we are aware, CQM has not provided anything new towards solving this problem, nor do we claim that our procedure will lead to a solution, but we do believe that the compositionality of quantum processes — in particular, how it depicts correlation and separability — will provide a better understanding towards the advantages
of composing complementary classical structures on systems to obtain complementary structures for a larger system.

§ STRONG COMPLEMENTARITY

Before we proceed to our main goal, we introduce strong complementarity. As the name suggests, it is a stronger version of complementarity. In particular, it implies complementarity, but the converse is not true in general.

[Coecke et al., 2012]
Two classical structures with spiders $\black$ and $\blackb$, respectively, are strongly complementary if they satisfy the following equations:

\begin{equation}\label{eq:strong-complement-copy1}
\includegraphics[scale=0.2]{images/26-50/34-bialgebra1.pdf}
\end{equation}

\begin{equation}\label{eq:strong-complement-copy-2}
\includegraphics[scale=0.2]{images/26-50/34-bialgebra2.pdf}
\end{equation}

\begin{equation}\label{eq:strong-complement-scalar}
\includegraphics[scale=0.2]{images/26-50/34-bialgebra3.pdf}
\end{equation}

\begin{equation}\label{eq:strong-complement-bialg}
\includegraphics[scale=0.2]{images/26-50/34-bialgebra4.pdf}
\end{equation}

Note that the equations in Definition <ref> are symmetric, i.e. the colours of the nodes can be swapped.

For a Hilbert space with dimension $\geq 2$, it was shown that the largest set of pairwise strongly complementary classical structures cannot contain more than two members [Coecke et al., 2012].

Two strongly complementary structures — albeit, with some additions — forms a graphical calculus for qubits called ZX-calculus. ZX-calculus is shown to be sound and universal for pure qubit quantum mechanics and was shown to be complete for stabilizer quantum mechanics [Backens, 2016].

In the next section, we briefly recount the generators and rewrite rules of ZX-calculus and show how ZX-calculus relates to the Pauli operators on a single qubit.

§ ZX-CALCULUS

Before we proceed, we shall summarize our notations for the eigenbases of the Pauli operators. The eigenbasis for the Pauli $Z$ operator is denoted by $\{\ket{0},\ket{1}\}$. This is our chosen standard basis. We denote the eigenbases of the Pauli $X$ and $Y$ operators respectively as $\{\ket{0_X},\ket{1_X}\}$ and $\{\ket{0_Y},\ket{1_Y}\}$. Members of both bases can be rewritten with respect to the standard basis:

\begin{eqnarray}
\ket{j_X}=\frac{1}{\sqrt{2}}(\ket{0}+(-1)^j\ket{1})\\
\ket{k_Y}=\frac{1}{\sqrt{2}}(\ket{0}+(-1)^k i\ket{1})
\end{eqnarray}

ZX-calculus consists of two classical structures, commonly represented by $\zspider$ and $\xspider$, which are strongly complementary. We refer to the classical structure consisting of $\zspider$ as $\mathcal{Z}$ and the classical structure consisting of $\xspider$ as $\mathcal{X}$. Spiders of $\mathcal{Z}$ and $\mathcal{X}$ can have phases $-\pi <\theta\leq\pi$, and a plain spider is a spider with phase 0. In addition to the spiders of $\mathcal{Z}$ and $\mathcal{X}$, ZX-calculus also consists of a scalar called star and an operation called Hadamard, denoted by the following diagrams:

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/35-star-hadamard.pdf}
\end{equation*}

Each generator of ZX-calculus has an interpretation in pure qubit quantum mechanics:

\begin{eqnarray*}
\includegraphics[scale=0.2]{images/26-50/36-z-spider.pdf}\\
\includegraphics[scale=0.2]{images/26-50/36-x-spider.pdf}\\
\includegraphics[scale=0.2]{images/26-50/36-had.pdf}\\
\includegraphics[scale=0.2]{images/26-50/36-star.pdf}
\end{eqnarray*}

where $\alpha\in[-\pi,\pi]$.

The interpretation above can be represented formally as a monoidal functor. Details can be found in [Backens, 2016].

Recall from Section <ref> where sequential composition of processes is $\circ$ and parallel composition of processes is $\otimes$. A diagram in ZX-calculus is a composition, either in sequence or in parallel, of the generators above. So to interpret a diagram in ZX-calculus as operations on qubit systems, one shall need to apply either $\circ$ or $\otimes$ on the interpretations of the generators above. Below is an example of an interpretation of a diagram in ZX-calculus to an operation on qubit systems:

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/37-example-interpret.pdf}
\end{equation*}

where the diagram is partitioned into three subdiagrams with their interpretations on the right. The complete interpretation of the diagram is then $[(\ket{0_X}^{\otimes 4}\bra{0_X}^{\otimes 4}+e^{i\alpha}\ket{1_X}^{\otimes 4}\bra{1_X}^{\otimes 4})\otimes (1_{\mathbb{C}_2})^{\otimes 3}]\circ[(1_{\mathbb{C}^2})^{\otimes 2}\otimes\frac{1}{2}(\ket{0}\bra{0}+\ket{0}\bra{1}+\ket{1}\bra{0}-\ket{1}\bra{1})^{\otimes 2}\otimes (1_{\mathbb{C}^2})^{\otimes 3}]\circ[(1_{\mathbb{C}^2})^{\otimes 2}\otimes(\ket{0}^{\otimes 5}\bra{0}^{\otimes 6}+e^{i\beta}\ket{1}^{\otimes 5}\bra{1}^{\otimes 6})]$. While it is certainly straightforward to switch between diagrams and their equational counterparts, we opt not to provide interpretations of all diagrams in ZX-calculus since the resulting interpretation of even a simple diagram is space-consuming.

The generators of ZX-calculus satisfy certain axioms called rewrite rules. These rewrite rules are given as Eqs. <ref>-<ref>. The following rewrite rules are necessary to obtain a complete description of stabilizer quantum mechanics [Backens, 2016]:

The green fuse rule:

\begin{equation}\label{eq:zx1-fuse-green}
\includegraphics[scale=0.2]{images/26-50/37-fuse-green.pdf}
\end{equation}

The green loop rule:

\begin{equation}\label{eq:zx3-loop-green}
\includegraphics[scale=0.2]{images/26-50/37-loop-green.pdf}
\end{equation}

The red fuse rule:

\begin{equation}\label{eq:zx2-fuse-red}
\includegraphics[scale=0.2]{images/26-50/37-fuse-red.pdf}
\end{equation}

The red loop rule:

\begin{equation}\label{eq:zx4-loop-red}
\includegraphics[scale=0.2]{images/26-50/37-loop-red.pdf}
\end{equation}

The green cup rule:

\begin{equation}\label{eq:zx5-cup-green}
\includegraphics[scale=0.2]{images/26-50/37-cup-green.pdf}
\end{equation}

The red cup rule:

\begin{equation}\label{eq:zx6-cup-red}
\includegraphics[scale=0.2]{images/26-50/37-cup-red.pdf}
\end{equation}

The green $\pi$-copy rule:

\begin{equation}\label{eq:zx7-copy-green-pi}
\includegraphics[scale=0.2]{images/26-50/37-green-pi.pdf}
\end{equation}

The red $\pi$-copy rule:

\begin{equation}\label{eq:zx8-copy-red-pi}
\includegraphics[scale=0.2]{images/26-50/37-red-pi.pdf}
\end{equation}

The green copy rule:

\begin{equation}\label{eq:zx9-copy-green}
\includegraphics[scale=0.2]{images/26-50/37-copy-green.pdf}
\end{equation}

The red copy rule:

\begin{equation}\label{eq:zx10-copy-red}
\includegraphics[scale=0.2]{images/26-50/37-copy-red.pdf}
\end{equation}

The bialgebra rule:

\begin{equation}\label{eq:zx11-bialgebra}
\includegraphics[scale=0.2]{images/26-50/37-bialgebra.pdf}
\end{equation}

The colour change rule:

\begin{equation}\label{eq:zx12-had-transform}
\includegraphics[scale=0.2]{images/26-50/37-had-transform.pdf}
\end{equation}

The Euler decomposition rule:

\begin{equation}\label{eq:zx13-had-euler}
\includegraphics[scale=0.2]{images/26-50/37-had-euler.pdf}
\end{equation}

The zero rule:

\begin{equation}\label{eq:zx14-pi-disconnect}
\includegraphics[scale=0.2]{images/26-50/37-pi-terminate.pdf}
\end{equation}

The zero rule:

\begin{equation}\label{eq:zx15-star}
\includegraphics[scale=0.2]{images/26-50/37-star.pdf}
\end{equation}

The zero scalar rule:

\begin{equation}\label{eq:zx16-zero}
\includegraphics[scale=0.2]{images/26-50/37-pi-terminate-scalar.pdf}
\end{equation}

From Eqs. <ref>-<ref>, we can derive the following equations:

The Hopf rule:

\begin{equation}\label{eq:dzx1-hopf}
\includegraphics[scale=0.2]{images/26-50/37-hopf.pdf}
\end{equation}

The yanking rule:

\begin{equation}\label{eq:dzx2-yank}
\includegraphics[scale=0.2]{images/26-50/37-yank.pdf}
\end{equation}

The identity rule:

\begin{equation}\label{eq:dzx3-identity}
\includegraphics[scale=0.2]{images/26-50/37-identity.pdf}
\end{equation}

The star-inverse rule:

\begin{equation}\label{eq:dzx4-star-inverse}
\includegraphics[scale=0.2]{images/26-50/37-star-inverse.pdf}
\end{equation}

The Hadamard-unitary rule:

\begin{equation}\label{eq:dzx5-had-unitary}
\includegraphics[scale=0.2]{images/26-50/37-had-unitary.pdf}
\end{equation}

The proofs for Eqs. <ref>-<ref> can be found in reference [Backens, 2016]. We highlight these derived rewrite rules since we shall use them frequently in proving our results.

If a spider has a loop with a Hadamard, it is equal to the same spider sans the loop and its phase is added by $\pi$, up to scalars:

\begin{equation}\label{eq:dzx6-loop-green-had}
\includegraphics[scale=0.2]{images/26-50/37-loop-green-had.pdf}
\end{equation}

\begin{equation}\label{eq:dzx7-loop-red-had}
\includegraphics[scale=0.2]{images/26-50/37-loop-red-had.pdf}
\end{equation}

\begin{eqnarray*}
\includegraphics[scale=0.18]{images/26-50/37-loop-green-had-proof.pdf}\\
\includegraphics[scale=0.18]{images/26-50/37-loop-red-had-proof.pdf}
\end{eqnarray*}

Eq. <ref> can be re-expressed as the following equations:

\begin{equation}
\includegraphics[scale=0.2]{images/26-50/37-hopf-green.pdf}
\end{equation}

\begin{equation}
\includegraphics[scale=0.2]{images/26-50/37-hopf-red.pdf}
\end{equation}

\begin{eqnarray}
\includegraphics[scale=0.2]{images/26-50/37-hopf-green-proof.pdf}\\
\includegraphics[scale=0.2]{images/26-50/37-hopf-red-proof.pdf}
\end{eqnarray}

For the sake of simplicity, when rewriting diagrams using Eqs. <ref>-<ref>, we ignore scalars. That is, when two diagrams are equivalent up to scalars, we treat them as equal to each other.

It is no accident that the classical structures in the ZX-calculus are labelled $\mathcal{Z}$ and $\mathcal{X}$. The corresponding bases for the classical structures are, respectively, the eigenbases of the Pauli $Z$ and Pauli $X$ operators. Furthermore, we can obtain the Pauli $Z$ and $X$ operators from the 1,1-spiders with phase $\pi$ of $\mathcal{Z}$ and $\mathcal{X}$, respectively.

If we omit the star, the Hadamard, and the rewrite rules which involve phase $\pi$ from the ZX-calculus, we could be describing any pair of strongly complementary classical structures. Thus, a (modified) ZX-calculus can be applied to qudit systems. The only caveat is the fact that the ZX-calculus as described above is not complete for quantum mechanics [Backens, 2016, Jeandel et al., 2019], but this should not prevent us from using it to study fragments of quantum mechanics as long as we are cautious about the Euler decompositions that we use in our computations. In our case, we do not utilize any Euler decompositions of unitaries other than $\had$ so the incomplete version of ZX-calculus that we use does not affect our computations.

§ CONSTRUCTING TEXT

As in the approach by Romero et al., 2005, we need the three representatives of the complete set of 3 MUBs of a single qubit system. We already have $\mathcal{Z}$ and $\mathcal{X}$ — which correspond to the Pauli $Z$ and $X$ operators, respectively  — but how do we represent the classical structure corresponding to the Pauli $Y$ operator?

ZX-calculus is universal for pure qubit quantum mechanics [Backens, 2016]. That is, for any state or operator on qubits, there exists a diagram in the ZX-calculus which represents it. So, it is possible to construct the classical structure corresponding to the Pauli $Y$ operator, using only the generators of the ZX-calculus. We denote this classical structure by $\mathcal{Y}$. By doing this, we do not have to define additional rewrite rules since the ones in the ZX-calculus already suffice.

A $m,n$-spider of the $\mathcal{Y}$ structure is the following linear map, where $j^k\in\{0,1\}$:

\begin{align*}
\ket{(j^1)_Y}\otimes\ket{(j^2)_Y}\otimes\cdots\otimes\ket{(j^m)_Y} &\mapsto \ket{(j^1)_Y}^{\otimes n}\\
\text{if }\ket{(j^k)_Y}=\ket{(j^{k'})_Y}& \text{ for all } k,k'\in\{1,...,m\}\\ \ket{(j^1)_Y}\otimes\ket{(j^2)_Y}\otimes\cdots\otimes\ket{(j^m)_Y} & \mapsto 0\\
\text{if }\ket{(j^k)_Y}\not=\ket{(j^{k'})_Y} & \text{ for some } k,k'\in\{1,...,m\}
\end{align*}

Rewriting the linear map above in terms of $\ket{0}$ and $\ket{1}$ will not simplify it. So, instead of doing that, we exploit the symmetry provided by $\dagger$ (see Section <ref>).

First, we consider the $m,1$-spider of $\mathcal{Y}$. Let $c_k$ be the number of $k\in\{0,1\}$ in $\ket{j^1}\otimes\ket{j^2}\otimes\cdots\otimes\ket{j^m}$ where $j^l\in\{0,1\}$ for each $l\in\{1,2,...m\}$. The $m,1$-spider of $\mathcal{Y}$ can be written as:

\begin{align*}
\ket{j^1}\otimes\ket{j^2}\otimes\cdots\otimes\ket{j^m}& \mapsto (-i)^{c_1}\ket{0} \\
\text{ if } & c_1 \text{ is even or }0\\
\ket{j^1}\otimes\ket{j^2}\otimes\cdots\otimes\ket{j^m}& \mapsto (-i)^{c_1-1}\ket{1}\\
\text{ if } & c_1 \text{ is odd}
\end{align*}

We obtained the above linear map from the result that the 2,1-spider of a classical structure — as the binary operation — forms a group with the unbiased states of the classical structure (see Section 7.4 of [Coecke and Duncan, 2011]).

Compare this to the $m,1$-spider of the $\mathcal{X}$:

\begin{align*}
\ket{j^1}\otimes\ket{j^2}\otimes\cdots\otimes\ket{j^m}& \mapsto \ket{0} \\
\text{ if } & c_1 \text{ is even or }0\\
\ket{j^1}\otimes\ket{j^2}\otimes\cdots\otimes\ket{j^m}& \mapsto \ket{1}\\
\text{ if } & c_1 \text{ is odd}
\end{align*}

The difference between the $m,1$-spiders of $\mathcal{Y}$ and $\mathcal{X}$ is the scalar factor on RHS of the mappings. That is, the $m,1$-spider of $\mathcal{Y}$ will take a tensor product of states in the standard basis and produce a state in the standard basis with some scalar factor 1 or $-1$. In contrast, the $m,1$-spider of $\mathcal{X}$ will take a tensor product of states in the standard basis and produce a state in the standard basis with scalar factor 1.

This provides us with a hint about the spiders of the $\mathcal{Y}$, i.e they can be constructed from spiders of $\mathcal{X}$. Now, the value of $(-i)^{c_1}$ depends on the number of $\ket{1}$ on LHS of the mapping above. We obtain 1 if $c_1$ or $c_1-1$ is a multiple of four, and -1 if $c_1$ or $c_1-1$ is not divisible by 4. So, to obtain the $m,1$-spider of the $\mathcal{Y}$, we need to compose the $m,1$-spider of $\mathcal{X}$ with some process which `checks' the number of $\ket{1}$ inputted to the spider. Furthermore, such a process should only change the scalar part of the state. We can do this using the controlled-$Z$ operator, which, in ZX-calculus, is denoted by:

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/38-CZ-gate.pdf}
\end{equation*}

The derivation of the diagram for the controlled-$Z$ operator can be found in reference [Coecke and Duncan, 2011].

The controlled-$Z$ operator is an operator on two qubits, and it can be viewed as a process which checks whether one of the two qubits inputted into it is $\ket{0}$ or not.

We argue that the following process composed of controlled-$Z$ operators checks the number $\ket{1}$ in a product state on $m$ qubits consisting of $\ket{0}$ and $\ket{1}$, which we shall denote as $\mathsf{CZ}_m$:

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/39-check-basis.pdf}
\end{equation*}

An example of the previous diagram for 4 qubits:

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/40-check-basis-eg.pdf}
\end{equation*}

We can break $\mathsf{CZ}_m$ down into levels. At the $k$-th level (see Fig. <ref>), there are $m-k$ controlled-Z operators acting on the $k$-th qubit and the qubits to its right. If the $k$-th qubit is $\ket{1}$ and the number of $\ket{1}$ to the right of the $k$-th qubit is odd, -1 should be multiplied to the scalar factor of the output state. Otherwise, the sign of the scalar factor remains the same.

Level $k$ of $\mathsf{CZ}_m$

The sign of the scalar factor changes $\frac{c_1-1}{2}$ times if $c_1$ is odd, and the sign of the scalar factor changes $\frac{c_1}{2}$ times if $c_1$ is even. Starting from +1, the resulting sign is then -1 if it changes an odd number of times, and it is +1 if it changes an even number of times. Thus, for $\ket{j^1j^2...j^m}$, where $j^k\in\{0,1\}$, $\mathsf{CZ}_m$ transforms $\ket{j^1j^2...j^m}$ into $-\ket{j^1j^2...j^m}$ if $c_1$ or $c_1-1$ is divisible by 4. Otherwise, $\mathsf{CZ}_m$ does nothing to it. Therefore, if we compose $\mathsf{CZ}_m$ to the $m,1$-spider of the $\mathcal{X}$, we obtain the $m,1$-spider of $\mathcal{Y}$.

The $1,n$-spider of a classical structure is the adjoint of its $n,1$-spider. So, the diagram in Fig. <ref> should be the $m,n$-spider of $\mathcal{Y}$.

Spider of $\mathcal{Y}$

There is an alternative way to express the spiders of $\mathcal{Y}$. In this thesis, we have opted to use the spider in Fig. <ref> since it does not involve spiders with phases other than 0 or $\pi$. The following theorem provides this alternative spider:

The diagram in Fig. <ref> has the following equivalent form:

\begin{equation}\label{eq:y-equivalence}
\includegraphics[scale=0.2]{images/26-50/43-y-equivalence.pdf}
\end{equation}

for some scalar $s$.

For the following results, we define $\theta=\frac{\pi}{2}$.

We need to prove the following propositions before we can prove Theorem <ref>.

The following equation gives Eq. <ref> for the case of $m=2$ and $n=1$:

\begin{equation}
\includegraphics[scale=0.2]{images/26-50/43-y-equivalence-4.pdf}
\end{equation}

for some scalar $s$.

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/43-y-equivalence-proof-2.pdf}
\end{equation*}

Above, the first equality is obtained from Eq. <ref>, and the final equality is obtained from Eq. <ref>.

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/43-y-equivalence-proof-1.pdf}
\end{equation*}

Above, the second equality is obtained from Eq. <ref>, and the final equality is obtained from Eqs. <ref> and <ref>.
Thus, we have:

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/43-y-equivalence-proof-3.pdf}
\end{equation*}

By Eq. <ref>,

\begin{equation}
\includegraphics[scale=0.2]{images/26-50/43-y-equivalence-proof-4.pdf}
\end{equation}

Let us temporarily denote the diagram in Fig. <ref> as $S_{m,n}$. We can obtain $S_{m+1,1}$ by composing $S_{2,1}$ to any of the input legs of $S_{m,1}$:

\begin{equation}
\includegraphics[scale=0.2]{images/26-50/43-y-equivalence-6.pdf}
\end{equation}

First, we prove for the case where $m=2$.

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/43-y-equivalence-proof-6-1.pdf}
\end{equation*}

Then, we show for the case of arbitrary $m\in\mathbb{N}$ where $m>2$:

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/43-y-equivalence-proof-6-2.pdf}
\end{equation*}

In the second diagram, the purple box is $\mathsf{CZ}_m$ and the diagram inside it is a sub-diagram of $\mathsf{CZ}_m$. To obtain the second equality, Eq. <ref> is repeatedly applied to the part of the second diagram that is outlined blue. The green node in $\mathsf{CZ}_m$ of the second diagram is then rewritten into $m-1$ red node and these nodes fuse to the other green nodes in $\mathsf{CZ}_m$ of the second diagram, resulting in $\mathsf{CZ}_{m-1}$ in the third diagram. The green nodes which are outlined blue in the third diagram are joined to each green node in $\mathsf{CZ}_{m-1}$ once via $\had$. The two green nodes are also joined to each other by $\had$. Thus, we have the final diagram.

Before proceeding, we define:

\begin{equation}\label{eq:green-phase}
\includegraphics[scale=0.2]{images/26-50/43-phase.pdf}
\end{equation}

(Theorem <ref>)

According to Proposition <ref>:

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/43-y-equivalence-proof-5.pdf}
\end{equation*}

for some scalar $s$.

However, applying Proposition <ref> to LHS of equation above, we have:

\begin{equation}\label{eq:y-equiv-1}
\includegraphics[scale=0.2]{images/26-50/43-y-equivalence-7.pdf}
\end{equation}

for some scalar $s'$,
which means the following equation also holds:

\begin{equation}\label{eq:y-equiv-2}
\includegraphics[scale=0.2]{images/26-50/43-y-equivalence-7-adjoint.pdf}
\end{equation}

for some scalar $s''$.

Combining Eqs. <ref> and <ref>, we have:

\begin{equation}\label{eq:y-equiv-final}
\includegraphics[scale=0.2]{images/26-50/43-y-equivalence-final.pdf}
\end{equation}

for some scalar $r$, which means the two are equivalent up to scalars. So if the collection of the spiders on RHS of the above equation forms a classical structure, then so does the collection of the spiders on LHS, and vice versa.

The collection of the following spiders for $m,n\in\mathbb{N}\cup\{0\}$ form a classical structure on single qubit:

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/42-y-CS.pdf}
\end{equation*}

Furthermore, the classical structure corresponds to the eigenbasis of the Pauli $Y$ operator. Thus, we denote it by $\mathcal{Y}$.

First, we show that the collection of the spider on RHS of Eq. <ref> forms a classical structure:

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/44-y-CS-proof-1.pdf}
\end{equation*}

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/44-y-CS-proof-2.pdf}
\end{equation*}

Due to Eq. <ref>, the collection of the spiders of the following form is a classical structure:

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/42-y-CS.pdf}
\end{equation*}

The aforementioned classical structure corresponds to the Pauli $Y$ operator (in the same context as in [Coecke et al., 2013]). So we shall denote it by $\mathcal{Y}$.

§ CHAPTER SUMMARY

In this chapter:

* We introduced strong complementarity which is the basis for a graphical calculus called ZX-calculus;

* We provided a brief review of ZX-calculus;

* ZX-calculus includes classical structures corresponding to the eigenbases of Pauli $Z$ and Pauli $X$ operators, which we denote by $\mathcal{Z}$ and $\mathcal{X}$, respectively;

* Using the generators of ZX-calculus, we constructed the classical structure corresponding to the eigenbasis of the Pauli $Y$ operator, which we denote by $\mathcal{Y}$.

CHAPTER: COMPOSING CLASSICAL STRUCTURES

Due to its equivalence to orthogonal bases, we may think of a classical structure as a representative of an observable and particular spiders could have special roles. For example, the $2,1$-spider could be interpreted as measurement on a process theory consisting of completely positive maps (CPM) as processes and the state of the system may be mixed — which is more precise in its description of quantum systems — and the $1,2$-spider could be interpreted as encoding classical data into a system [Selinger, 2007, Coecke, 2008, Coecke, 2007, Coecke et al., 2014, Coecke and Kissinger, 2016]. While we shall not delve deeper into CPM-based process theory, we find its model of quantum-classical interactions to be remarkable. As such, we find it important to study one of its core concepts — classical structures. In this chapter, we seek to exploit the compositionality of CQM/process theories in order to provide a more precise picture of classical structures on multiple qubits with classical structures on a single qubit as their building blocks.

§ COMPOSING CLASSICAL STRUCTURES

To construct complementary classical structures on multiple qubits, we first outline the methods for composing complementary classical structures on a single qubit. In addition, we shall justify our chosen unitaries for joining spiders, i.e. the Hadamard and the identity, in the context of obtaining complementary classical structures on multiple qubits.

§.§ Separably Composing Spiders

Suppose $\mathcal{A}$ and $\mathcal{B}$ are classical structures on some systems $T_A$ and $T_B$, respectively, where spiders of $\mathcal{A}$ is $\black$ and spiders of $\mathcal{B}$ is $\blue$, respectively. Then the collection of processes of the following type, formed by composing $\black$ and $\blue$, with the same number of input and output legs, in parallel is a classical structure on $T_A\otimes T_B$:

Separably composed spider on a bipartite system. The legs of the spider is $T_A\otimes T_B$.

In Fig. <ref>, we used different coloured wires for the legs of the black and blue spiders. This is to distinguish the legs of the two spiders. Each leg still represents a single qubit, and not any other system. In the rest of this thesis, we would sometimes use the same method to distinguish the legs of constituent spiders within a composite spider.

Since the spiders in Fig. <ref> are composed in parallel, the resulting process inherits its constituents' ability to fuse and invariance under permutation of the spiders' legs.

A classical structure on a bipartite system $T_A\otimes T_B$ is called separably composed (SC) if its $m,n$-spider is formed by composing the $m,n$-spider of a classical structure on $T_A$ and the $m,n$-spider of a classical structure on $T_B$ in parallel, and the legs are permuted as in Fig. <ref>. Suppose the aforementioned classical structures on $T_A$ and $T_B$ are $\mathcal{A}$ and $\mathcal{B}$, respectively. We denote the SC classical structure on $T_A\otimes T_B$ by $\mathcal{AB}$.

§.§ Joining Spiders

The method of composing classical structures in the previous section only gives rise to classical structures with an underlying basis consisting of separable states. To find a more exhaustive collection of classical structures on two qubits, we must devise another way of constructing classical structures via composition, i.e. one that gives rise to a classical structure on two qubits with an underlying basis consisting of entangled states.

To entangle two qubits (or a bipartite system), we need a bipartite process that is non-separable, i.e. a bipartite process such that:

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/46-bipartite-process.pdf}
\end{equation*}

for any processes $f_1$ and $f_2$.

In a separably composed spider on two qubits, a single leg is two qubits or $\mathbb{C}^2\otimes\mathbb{C}^2$. So, to entangle the constituent spiders of a SC spider, we propose composing a bipartite process on each of its legs as in Fig. <ref>.

Joining spiders via a non-separable bipartite process.

The input or output legs of the diagram in Fig. <ref> are invariant under permutation:

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/48-mn-permute.pdf}
\end{equation*}

since the legs of spiders within the dashed lines can be permuted.

However, the process $f$ cannot be just be any non-separable bipartite process.

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/49-mn-fuse.pdf}
\end{equation*}

In order for the diagram in Fig. <ref> to satisfy the fusion rule for spiders as in the previous diagram, the process $f$ must be unitary.

Vidal and Dawson, 2004 showed that any special unitary process

on two qubits can be decomposed into up to three $\mathsf{CNOT}$ gates and single qubit unitaries. That is:

\begin{equation*}
\includegraphics[scale=0.2]{images/26-50/50-decompose-unitary.pdf}
\end{equation*}

We shall not explore all possible values of $u_j$ and $v_k$, but the decomposition above does give us an idea about the degree of complexity we can impose on the entanglement to be generated. Suppose we choose $\cwgr$ as our entanglement generator since it is the simplest non-separable bipartite process that is unitary based on the previous equation. Then we obtain the following diagram for Fig. <ref>:

Fig <ref> where $f$ is the $\mathsf{CNOT}$ gate.

From the rewrite rules of $ZX$-calculus, we can derive the following[Recall that scalars are ignored.]:

\begin{equation}\label{eq:gen-bialg}
\includegraphics[scale=0.2]{images/51-75/52-gen-bialg.pdf}
\end{equation}

That is, for every green-red node pair in the left diagram, there is a single wire between them. We shall use Eq. <ref> to discuss the various possibilities for the simplest entanglement generator mentioned above.

* If $\black=\zspider=\blue$, then we have:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/53-mn-cw1-case1.pdf}
\end{equation*}

In the middle diagram, there is exactly one wire between every green-red node-pair. So we can use Eq. <ref> to obtain the second equality.

* If $\black=\xspider=\blue$, then we have:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/53-mn-cw1-case3.pdf}
\end{equation*}

where the third equality is obtained via the same reasoning as Case 1.

* If $\black=\zspider$ and $\blue=\xspider$:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/53-mn-cw1-case2.pdf}
\end{equation*}

where we obtain a separably composed spider (first diagram on RHS) if $m+n$ is even as in Fig. <ref>, and we obtain the second diagram on RHS  if $m+n$ is odd.

* If $\black=\xspider$ and $\blue=\zspider$, Fig. <ref> cannot be simplified as in Cases 1 to 3 so we maintain its original appearance:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/53-mn-cw1-case4.pdf}
\end{equation*}

Cases 1 and 2 can immediately be excluded since the resulting spiders from each case are equal to separably composed spiders. For Case 3, half of the spiders produced are separably composed while the other half can be described as separably composed spiders with a wire connecting the two central nodes. If we look at the underlying basis for such a classical structure, it does indeed consist of separable states.

The underlying basis of the classical structure in Case 3 above is equal to, up to scalars, the underlying basis of the classical structure formed by separably composing $\mathcal{X}$ and $\mathcal{Z}$ which results in the classical structure $\mathcal{XZ}$ on two qubits.

The underlying basis of $\mathcal{XZ}$ is:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/54-proof-case3.pdf}
\end{equation*}

which is equal to $\{\ket{00_X},\ket{01_X},\ket{10_X},\ket{11_X}\}$ up to scalars.

Suppose $\wunit\bunit\in B_{XZ}$. Then:

\begin{eqnarray*}
\includegraphics[scale=0.2]{images/51-75/55-proof-case3-copy-basis.pdf}\\
\includegraphics[scale=0.2]{images/51-75/55-proof-case3-delete-basis.pdf}
\end{eqnarray*}

This means that the 2,1-spider and 0,1-spider of the classical structure in Case 3, respectively, copies and deletes $B_{XZ}$ or an orthogonal basis equivalent to $B_{XZ}$ up to scalars. Thus, the underlying basis of the classical structure in Case 3 must be equivalent to $B_{XZ}$ up to scalars.

While a pair of classical structures with underlying bases that contain the same states but with differing global phases are not necessarily equivalent (see Section <ref> for further discussion), the separability of these bases is preserved, i.e. the classical structure in Case 3 has an underlying basis that is separable. Thus, we are left with the classical structure in Case 4 as a classical structure that is not equivalent to $\mathcal{XZ}$.

The classical structure produced by Case 4 has an underlying basis consisting of non-separable states.

For this proposition, we shall use the scalar inclusive version of ZX-calculus as outlined in the previous chapter. First, suppose $B$ is the underlying basis of the classical structure in Case 4 and suppose $B$ consists of separable states. Let $\ket{\psi}\ket{\phi}$ be a normalized state that is proportional to one of the states in $B$. Then we have:

\begin{equation}\label{eq:case4-1}
\includegraphics[scale=0.2]{images/51-75/56-proof-case4-SC1.pdf}
\end{equation}

for some scalar $s\in\mathbb{C}$.

From the rewrite rules of ZX-calculus, we obtain:

\begin{equation}\label{eq:case4-2}
\includegraphics[scale=0.2]{images/51-75/56-proof-case4-SC3.pdf}
\end{equation}

where we applied Eqs. <ref>, <ref> and <ref> on the part highlighted blue in the first diagram to obtain the first equality. The same equations are then applied to the second diagram to obtain the final diagram.

By Eq. <ref> and <ref>, we have:

\begin{equation}\label{eq:case4-3}
\includegraphics[scale=0.2]{images/51-75/56-proof-case4-SC4.pdf}
\end{equation}

Now, the 1,0-spider of the classical structure in Case 4 is:

\begin{equation}\label{eq:case4-4}
\includegraphics[scale=0.2]{images/51-75/56-proof-case4-SC2.pdf}
\end{equation}

due to Eqs. <ref> and <ref>.
So then:

\begin{equation}\label{eq:case4-5}
\includegraphics[scale=0.2]{images/51-75/56-proof-case4-SC5.pdf}
\end{equation}

Eqs. <ref> and <ref> give us:

\begin{equation}\label{eq:case4-6}
\includegraphics[scale=0.2]{images/51-75/56-proof-case4-SC6.pdf}
\end{equation}

So, we have:

\begin{equation}
\includegraphics[scale=0.2]{images/51-75/56-proof-case4-SC7.pdf}
\end{equation}

which is not true since $\starscalar$ and $\sqrtwo\sqrtwo$ are inverses of each other and neither are equal to 1.

§.§ Connecting Wires for Joining Spiders

Proposition <ref> tells us that the classical structure produced by Case 4 above must have an underlying basis consisting of non-separable states. We call it a non-separable classical structure on two qubits with constituents $\mathcal{X}$ and $\mathcal{Z}$, denoted by $\mathcal{X}\diamond\mathcal{Z}$. From $\mathcal{X}\diamond\mathcal{Z}$, we can construct other non-separable classical structures on two qubits with different constituents:

\begin{eqnarray}
\includegraphics[scale=0.2]{images/51-75/57-XX.pdf} \label{eq:XX}\\
\includegraphics[scale=0.2]{images/51-75/57-ZZ.pdf} \label{eq:ZZ}\\
\includegraphics[scale=0.2]{images/51-75/57-XY.pdf} \label{eq:XY}\\
\includegraphics[scale=0.2]{images/51-75/57-YZ.pdf} \label{eq:YZ}
\end{eqnarray}

If we compose the spider from Case 4 with $\cwgg$ as in Eq. <ref>, and also compose on its legs $\cwrr$ and $\had$ as in Eq. <ref>, we shall obtain a non-separable classical structures on two qubits where both of its constituents are $\mathcal{Y}$.

We can permute the constituents of the known spiders. For example:

\begin{equation}\label{eq:ZX}
\includegraphics[scale=0.2]{images/51-75/57-ZX.pdf}
\end{equation}

Thus, we have obtained non-separable classical structures on two qubits for any combination of constituents from $\{\mathcal{X},\mathcal{Y},\mathcal{Z}\}$.

We call the bipartite process which entangles a pair of classical structures as connecting wires. Table <ref> shows the connecting wire for each pair of classical structures from $\{\mathcal{X},\mathcal{Y},\mathcal{Z}\}$.

Connecting wires for pairs of classical structures, where CS1 is the classical structure on the first qubit and CS2 is the classical structure on the second qubit. The rightmost column gives the notation of the resulting composed classical structure.

|c|c|c|c|CS1     CS2     Connecting Wire     Notation
$\mathcal{X}$     $\mathcal{X}$          $\mathcal{X}\diamond\mathcal{X}$
$\mathcal{X}$     $\mathcal{Y}$          $\mathcal{X}\diamond\mathcal{Y}$
$\mathcal{X}$     $\mathcal{Z}$          $\mathcal{X}\diamond\mathcal{Z}$
$\mathcal{Y}$     $\mathcal{X}$          $\mathcal{Y}\diamond\mathcal{X}$
$\mathcal{Y}$     $\mathcal{Y}$          $\mathcal{Y}\diamond\mathcal{Y}$
$\mathcal{Y}$     $\mathcal{Z}$          $\mathcal{Y}\diamond\mathcal{Z}$
$\mathcal{Z}$     $\mathcal{X}$          $\mathcal{Z}\diamond\mathcal{X}$
$\mathcal{Z}$     $\mathcal{Y}$           $\mathcal{Z}\diamond\mathcal{Y}$
$\mathcal{Z}$     $\mathcal{Z}$           $\mathcal{Z}\diamond\mathcal{Z}$

§ COMPOSITE CLASSICAL STRUCTURES ON TEXT QUBITS

Based on the constructions in the previous sections, we introduce some notations:

A composite classical structure on two qubits is formed by composing two classical structures on a single qubit. We call these classical structures on a single qubit as constituents of the composite classical structure. With respect to the present work, a constituent is either $\mathcal{X},\mathcal{Y}$ or $\mathcal{Z}$.

A separably composed classical structure (SCCS) on two qubits is a composite classical structure which consists of spiders composed separably as in Section <ref>. For $\mathcal{O}_1,\mathcal{O}_2\in\{\mathcal{X,Y,Z}\}$, a SCCS with constituents $\mathcal{O}_1$ and $\mathcal{O}_2$ is denoted by $\mathcal{O}_1\mathcal{O}_2$.

A non-separable classical structure (NSCS) on two qubits is a composite classical structure which consists of entangled spiders as in Section <ref>. For $\mathcal{O}_1,\mathcal{O}_2\in\{\mathcal{X,Y,Z}\}$, a NSSC with constituents $\mathcal{O}_1$ and $\mathcal{O}_2$ is denoted by $\mathcal{O}_1\diamond\mathcal{O}_2$.

We can extend Definition <ref> to multiple qubits. However, for $N$ qubits where $N>2$, there are more than one pair of qubits. So, the degree of entanglement of a classical structure is more varied. That is, it is no longer necessary for a classical structure to be separable on all qubits or non-separable on all qubits. A classical structure can be separable on one pair of qubits and non-separable on another pair of qubits. For a example, a classical structure on three qubits could be non-separable on the first two qubits, but separable on the second and third qubits and on the third and first qubits. So, we should be able to compose a SCCS and a NSCS to form a classical structure on $N$ qubits where $N>2$.

To show that this is indeed possible, we introduce a diagram which subsumes both SCCS and NSCS:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/58-gen-composite.pdf}
\end{equation*}

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/58-gen-composite-condition.pdf}
\end{equation*}

depending on separability of the classical structure and the spiders $\blackb$ and $\blueb$.

$m,n$-spider of a composite classical structure on $N$ qubits. The diagrams in the blue boxes are repeated $m$ times, and the diagrams in the red boxes are repeated $n$ times.

Before we proceed further, we shall recall !-boxes, which we view as a convenient tool to draw diagrams for an arbitrary number of qubits. Note that the following definition is a simplified one as not to distract from our main study. For a more detailed description of !-boxes, one may refer to references [Kissinger et al., 2014, Merry, 2014].

Let $D$ be a diagram. A !-box in $D$ is its subdiagram which can be repeated an arbitrary number of times, starting from 0. In a diagram, a !-box is marked by a coloured box around it. !-boxes of the same colour represent the same number of repetitions of those subdiagrams.

A simple example of a diagram with !-boxes is a generic spider:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/58-bang-box-1-eg.pdf}
\end{equation*}

or, a spider belonging to $\mathcal{XZ}$:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/58-bang-box-2-eg.pdf}
\end{equation*}

The process in Fig. <ref>
is a spider of a classical structure on $N$ qubits.

If a diagram of the form in Fig. <ref> with $m_1$ input legs and $n_1$ output legs is composed with another diagram of the form in Fig. <ref> with $m_2$ input legs and $n_2$ output legs at $p$ legs, then the two diagrams will fuse at the black spiders $S_1,S_2,...,S_N$ and form a diagram of the form Fig. <ref> with a total of $m_1+m_2+n_1+n_2-p$ legs since:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/58-conwire.pdf}
\end{equation*}

for any $j,k\in\{1,2,...,N\}$.

The 0,1-spider of a composite classical structure on $N qubits$ is equivalent (up to scalars) to:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/58-gen-composite-0,1.pdf}
\end{equation*}

From Fig. <ref>, the 0,1-spider of a composite classical structure on $N$ qubits is:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/58-gen-composite-0,1-proof.pdf}
\end{equation*}

since the white spider labelled $S_j$ copies the black spider labelled $S_j$ by definition.

§ CHAPTER SUMMARY

In this chapter:

* We showed how to compose two classical structures on a single qubit to form a composite classical structure on two qubits via two methods:

C1 Separably composing their spiders with matching number of legs, i.e. the spiders composed remain separable or not entangled (see Section <ref>);

C2 Joining their spiders with matching number of legs via one of the following connecting wires (see Section <ref>):
c c c c

to form a non-separable classical structure.

* We also showed how to construct a composite classical structure on $N$ qubits, where $N>2$, by composing constituents on each pair of qubits in $N$ qubits via Methods C1 or C2.

CHAPTER: SEPARABILITY OF COMPLEMENTARY CS

Classical structures and their spiders provide intuitive images of compatible observables and measurements, and those that are incompatible. The former is depicted by the equation in Eq. <ref> which could be interpreted as zero information loss, and the latter could be described by Eq. <ref>, where the discontinuity between the input system and the output system can be interpreted as complete information loss on the input system. There is a stronger version of complementarity, called strong complementarity (see Definition <ref>) [Coecke et al., 2012]. An implication of strong complementarity between two classical structures, represented by $\black$ and $\blue$, is the following equation:

\begin{equation}
\includegraphics[scale=0.2]{images/51-75/59-hopf-gen.pdf}
\end{equation}

which can be thought of as the exact opposite of Eq. <ref>.

Previously, we presented two procedures for composing classical structures on a single qubit, namely $\mathcal{X},\mathcal{Y}$ and $\mathcal{Z}$, in order to obtain classical structures on multiple qubits. We devised these procedures so that we may study the entanglement structure of sets of mutually unbiased bases in qubit systems. As was discussed in the previous chapter, the separability of classical structures obtained through these procedure are apparent from the presence of the connecting wires on the legs of their spiders. In this chapter, we shall present the complete sets of complementary classical structures on two and three qubits that can be obtained by composing the complementary classical structures on a single qubit via Methods C1 and C2 from Section <ref>.

§ ON NOTATIONS

To denote arbitrary spiders, we shall use spiders with nodes that are neither green nor red. Some examples are $\black$,$\blue$,$\purple$,$\pink$,$\orange$, etc. At times, we shall use spiders to represent classical structures and write $\black\in\mathcal{A}$ to mean classical structure $\mathcal{A}$ consists of spiders $\black$.

Within the diagram of a spider belonging to a composite classical structure, there are two types of spiders. The first one is the central spiders which belong to constituents of the composite classical structure. We shall use coloured nodes with their interior filled in along with their outlines. The second one is the spiders which form part of the connecting wires on the legs of the central spiders. For these spiders, we shall use nodes with only their outlines coloured while their interiors are blank. The colour of the outline of such spider depends on the central spider to which it is connected. For example, if the central spider is $\black$, then the spider on its leg is $\blackb$.

Fig. <ref> is an example of an arbitrary composite classical structure on two qubits.

An arbitrary composite classical structure on two qubits.

The first option for $\cwbkp$ is given to include separably composed classical structures. In this case, $\blackb$ and $\pinkb$ can belong to either $\mathcal{X}$ or $\mathcal{Z}$. Due to Eqs. <ref> and <ref>, the leg nodes would simply disappear. If the composite classical structure is non-separable, then
the diagram:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/58-cw.pdf}
\end{equation*}

is a connecting wire. This means that $\cwbkp$, $\blackb$, and $\pinkb$ depend on $\black$ and $\pink$ as prescribed in Table <ref>. For example, if $\black\in\mathcal{X}$ and $\pink\in\mathcal{Y}$, then $\blackb,\pinkb\in\mathcal{Z}$ and $\cwbkp=\had$.

§ COMPLEMENTARITY DIAGRAMS IN QUBIT SYSTEMS

Two classical structures are complementary if they satisfy the following equation:

\begin{equation}\label{eq:complementarity}
\includegraphics[scale=0.2]{images/51-75/60-complementarity.pdf}
\end{equation}

We call the above equation the complementarity condition, and the LHS diagram in the equation as the complementarity diagram, abbreviated as CD, between $\blue$ and $\purple$.

From Eq. <ref>, we define the antipode between $\blue$ and $\purple$ as follows:

\begin{equation}
\includegraphics[scale=0.2]{images/51-75/61-antipode.pdf}
\end{equation}

Suppose $\mathcal{A},\mathcal{B},\mathcal{C},\mathcal{D}\in\{\mathcal{X},\mathcal{Y},\mathcal{Z}\}$. Let $\blue\in\mathcal{A}$, $\pink\in\mathcal{B}$, $\purple\in\mathcal{C}$ and $\orange\in\mathcal{D}$. For a complementarity diagram between a composite classical structure with constituents $\mathcal{A}$ and $\mathcal{B}$, and a composite classical structure with constituents $\mathcal{C}$ and $\mathcal{D}$, the following is true:

\begin{equation}
\includegraphics[scale=0.2]{images/51-75/61-antipode-cw.pdf}
\end{equation}

For the 0,2-spiders of $\mathcal{X,Y}$ and $\mathcal{Z}$, we have:

\begin{equation}
\includegraphics[scale=0.2]{images/51-75/62-cup-zx.pdf}\label{eq:cupZX}
\end{equation}

\begin{equation}
\includegraphics[scale=0.2]{images/51-75/62-cup-y.pdf}\label{eq:cupY}
\end{equation}

\begin{equation}
\includegraphics[scale=0.2]{images/51-75/63-sliding-on-cup.pdf}
\end{equation}

\begin{equation}
\includegraphics[scale=0.2]{images/51-75/63-sliding-on-cup-x.pdf}
\end{equation}

\begin{equation}
\includegraphics[scale=0.2]{images/51-75/63-sliding-on-cup-y.pdf}
\end{equation}

This means that for a classical structure that is either $\mathcal{X},\mathcal{Y}$ or $\mathcal{Z}$, represented by $\black$, we have:

\begin{equation}
\includegraphics[scale=0.2]{images/51-75/63-sliding-on-cup-gen.pdf}
\end{equation}

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/64-antipode-cw-proof.pdf}
\end{equation*}

Eqs <ref> and <ref> also imply that a complementarity diagram between a pair of classical structures in $\{\mathcal{X},\mathcal{Y},\mathcal{Z}\}$ can be simplified as follows:

\begin{equation}\label{eq:fuse-antipode}
\includegraphics[scale=0.2]{images/51-75/65-CD1Q.pdf}
\end{equation}

where $\theta=0$ if $\blue$ and $\purple$ both belong to either $\mathcal{X}$ or $\mathcal{Z}$ or they both belong to $\mathcal{Y}$,

and $\theta=\pi$ if $\blue$ belongs to either $\mathcal{X}$ or $\mathcal{Z}$ and $\purple\in\mathcal{Y}$ or vice versa.

If $\blue$ and $\purple$ belong to either $\mathcal{X}$ or $\mathcal{Z}$, then both sides of Eq. <ref> are equal to:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/65-CD1Q-opt1.pdf}
\end{equation*}

due to eq. <ref> for LHS and due to the fact that the 1,1-spider with zero phase of any classical structure is the identity for RHS.

If both $\blue$ and $\purple$ belong to $\mathcal{Y}$, then the antipode must be the identity as the antipode between any classical structure and itself is the identity.

If $\blue\in\mathcal{Y}$ and $\purple$ belong to either $\mathcal{X}$ or $\mathcal{Z}$, then LHS of eq. <ref> is equal to:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/65-CD1Q-opt2.pdf}
\end{equation*}

If $\purple\in\mathcal{Y}$ and $\blue$ either belongs to $\mathcal{X}$ or $\mathcal{Z}$, then LHS of eq. <ref> is equal to a similar diagram as the adjoint of the diagram above, except the purple node is replaced with a blue node.

As a consequence of Propositions <ref> and <ref>, there are three types of complementarity diagrams we may obtain between composite classical structures on two qubits that are produced by Method C1 or C2, or both. These are the diagrams below:

where $\alpha_i,\beta_j\in\{0,\pi\}$ for $i,j\in\{1,2\}$.

Each of the diagrams above satisfies the complementarity condition if it is equal to the following diagram:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/68-comp-cond.pdf}
\end{equation*}

However, we will not be able to rewrite the preceding diagrams using the rules of ZX-calculus unless we fix the classical structures to which $\blue,\pink,\purple$ and $\orange$ belong. This would be quite tedious since we would have to consider all the possibilities for each spider and connecting wires in the diagrams above, and even more so when determining the complementarity between a pair of composite classical structures on $N$ qubits where $N>2$.

A simpler way to go about this is to partition all the complementarity diagrams into equivalence classes. In doing so, we only need to check the complementarity of a representative diagram for each class.

For $N$ qubits, let $\mathsf{D}_N$ be the set of all complementarity diagrams between a pair of composite classical structures on $N$ qubits as defined in Definition <ref>. Suppose the relation $r\in\mathsf{D}_N\times\mathsf{D}_N$ is defined as follows: $D_1rD_2$ if and only if there exists a unitary $U=P\circ V_1\otimes V_2\otimes\cdots\otimes V_N$ where $V_j\in\{\text{id}_{\mathbb{C}^2},\had\}$ and $P$ is a permutation on $N$ qubits, such that $D_2=U^\dagger\circ D_1\circ U$ or $D_2=U^\dagger\circ D_1^\dagger\circ U$. Then $r$ is an equivalence.

For a diagram $D\in\mathsf{D}_N$, $DrD$ since the identity of $(\mathbb{C}^2)^{\otimes N}$ for any $N\in\mathbb{N}$ is unitary.

Suppose for $D_1,D_2\in\mathsf{D}$, $D_1rD_2$. Then there is some unitary $U$ on $N$ qubits such that $D_2=U^\dagger\circ D_1\circ U$ or $D_2=U^\dagger\circ D_1^\dagger\circ U$. This means that $D_1=U\circ D_2 U^\dagger$ or $D_1=U\circ D_2^\dagger \circ U^\dagger$. So, $D_2rD_1$.

Suppose for $D_1,D_2,D_3\in\mathsf{D}$, $D_1rD_2$ and $D_2rD_3$. Then $D_2=U_1^\dagger\circ D_1\circ U_1$ or $D_2=U_1^\dagger\circ D_1^\dagger\circ U_1$, or $D_3=U_2^\dagger\circ D_2\circ U_2$ or $D_3=U_2^\dagger\circ D_2^\dagger\circ U_2$ for some unitaries $U_1, U_2$ on $N$ qubits. So  $D_3$ must be equal to either $U_3^\dagger\circ D_1\circ U_3$ or $U_3^\dagger\circ D_1^\dagger\circ U_3$ where $U_3\in\{U_2\circ U_1,U_2\circ U_1^\dagger, U_2^\dagger\circ U_1,U_2^\dagger\circ U_1^\dagger\}$. So, $D_1rD_3$.

The proof for Theorem <ref> uses the property of the unitary instead of its specific definition in the statement, i.e. as a composition of a permutation on $N$ qubits, $\text{id}_{\mathbb{C}^2}$ and $\had$. So the theorem would still hold even if we are not as precise about the unitary as we were in the theorem's statement. However, since we have limited the constituents of the composite classical structures in the present work to $\mathcal{X},\mathcal{Y}$ and $\mathcal{Z}$, only a unitary as defined in Theorem <ref> can transform a diagram in $\mathsf{D}_N$ and into another diagram in the set.

Let $\mathsf{D}_N$ be defined as in Theorem <ref>. A diagram in $\mathsf{D}_N$ can be split into $N$ slices. Each slice takes the following form:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/69-unitary-proof.pdf}
\end{equation*}

We have used !-boxes (see Definition <ref>) to indicate the connecting wires on the top and bottom spiders in the diagram. Above, !-boxes with the same colour must contain the same number of wires.

Suppose for $D_1,D_2\in\mathsf{D}_N$, $D_1=U^\dagger\circ D_2\circ U$ where $U=V_1\otimes\cdots\otimes V_N$ such that for some $m\in\{1,...,N\}$, $V_m=\had$ and $V_j=\text{id}_{\mathbb{C}^2}$ for $j\not=m$. Then $D_1$ is equivalent to $D_2$. So the slice above can be represented by the following diagrams:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/70-unitary-proof-all.pdf}
\end{equation*}

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/71-unitary-proof-condition.pdf}
\end{equation*}

For $sD_1$ we have allowed for bottom spider to take the form:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/72-y-equivalence.pdf}
\end{equation*}

However, we have not introduced a classical structure with such a spider. We do this because the connecting wires on the top and bottom spiders are not interchangeable. So $sD_1$ includes the following diagram:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/74-unitary-proof-type3.pdf}%unitary-proof-type-3
\end{equation*}

There are three forms which $sD_1$ can take:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/73-type1-options.pdf}
\end{equation*}

And $sD_2$ can take two forms:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/75-type2-options.pdf}
\end{equation*}

To check complementarity between all pairs of composite classical structures on $N$ qubits, it is sufficient to look at composite complementarity diagrams consisting of $sD_{11},sD_{12},sD_{13},sD_{21}$ and $sD_{22}$.

Let $m$ be the number of wires contained in the blue !-box and $n$ be the number wires contained in the purple !-box. Then $sD_{11}=sD_{12}$ if $m=0$ and $sD_{11}=sD_{13}$ if $n=0$.

Suppose $m=0$. Then $sD_{11}$ can be rewritten as:

\begin{equation*}
\includegraphics[scale=0.2]{images/76-100/76-type1-special-case.pdf}
\end{equation*}

$sD_{11}=sD_{13}$ if $n=0$ can be proven in a similar way.

Proposition <ref> tells us that $sD_{12}$ if $m=0$ and $sD_{13}$ if $n=0$ can be subsumed by $sD_{11}$.

For slices $sD_{11}, sD_{12}, sD_{13}, sD_{21}$ and $sD_{22}$, let $m$ be the number of wires contained in the blue !-box and $n$ be the number of wires contained in the purple !-box.
The generating set of $\mathsf{D}_N$, denoted as $\mathsf{G}_N$, is a subset of $\mathsf{D}_N$ such that each slice of a complementarity diagram in $\mathsf{G}_N$ is either
$sD_{11}$, $sD_{21}$ and $sD_{22}$ for any $m,n\in\mathbb{N}\cup\{0\}$, $sD_{12}$ for $m\in\mathbb{N}, n\in\mathbb{N}\cup\{0\}$, and $sD_{13}$ for $n\in\mathbb{N}, m\in\mathbb{N}\cup\{0\}$.

To find maximal complete sets of mutually complementary classical structures on $N$ qubits, we shall form a graph where the vertices are the composite classical structures on $N$ qubits. A pair of vertices/classical structures have an edge between them if they are complementary. However, it is highly inefficient to check the complementarity of every pair of classical structures on $N$ qubits. For example, there are 171 unique pairs of composite classical structure on two qubits, and there are 23,435 unique pairs of composite classical structures on three qubits. So instead, we shall check the complementarity condition of a smaller set of complementarity diagrams which generate all complementarity diagrams on $N$ qubits, i.e. complementarity diagrams consisting of the slices mentioned previously. Then we shall encode the information of those complementarity diagrams which satisfy the complementarity condition as matrices called `names' (to be defined), and gathered to form a test set.

Let $\mathcal{A}$ be a composite classical structure on $N$ qubits. The name of $\mathcal{A}$ is a $(N+1)\times N$ matrix, $A$, with entries $A_{pq}$, defined as follow:

* The first row of $A$ consists of information on the constituents of $\mathcal{A}$, i.e.

\begin{equation}
\begin{cases}
0 & \text{if the } q \text{-th constituent of } \mathcal{A} \text{ is } \mathcal{X}\\
1 & \text{if the } q \text{-th constituent of } \mathcal{A} \text{ is } \mathcal{Y}\\
Z & \text{if the } q \text{-th constituent of } \mathcal{A} \text{ is } \mathcal{Z}
\end{cases}
\end{equation}

* The $p,q$-th entry of $A$ where $p>1$ gives the information on the separability of $\mathcal{A}$ on the $(p-1)$-th and $q$-th qubits, i.e. for $p>2$,

\begin{equation}
\begin{cases}
0 & \text{if there is no connecting wire between}\\
& \text{the } (p-1) \text{-th and } q \text{-th qubits in }\mathcal{A}\\
1 & \text{if } A_{1p},A_{1q}\in\{0,1\}\\
i & \text{if } A_{1p}=A_{1q}=Z\\
j & \text{if } A_{1q}\in\{0,1\}\text{ and }A_{1p}=Z\\
k & \text{if } A_{1q}=Z\text{ and }A_{1p}\in\{0,1\}
\end{cases}
\end{equation}

To represent a complementarity diagram between a pair of classical structures, we define a binary operation between the names of those classical structures.

Let $\mathcal{A}$ and $\mathcal{B}$ be composite classical structures on $N$ qubits with names $A$ and $B$, respectively. The name of the complementarity diagram between $\mathcal{A}$ and $\mathcal{B}$ is denoted by $A*B$, and is defined as entry-wise addition modulo 2 of $A$ and $B$, i.e. $(A*B)_{pq}=A_{pq}+_{\text{mod }2}B_{pq}$.

Below is an example of a complementarity diagram (diagram on the left) and its name (the matrix on the right):

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/76-CD-name.pdf}
\end{equation*}

Partitioning complementarity diagrams on $N$ qubits with respect to the equivalence defined in Theorem <ref>, we shall obtain equivalence classes where we can say that every member of a class satisfies the complementarity condition if a single member of the class satisfies the complementarity condition.

Let $|P|$ be a partition of $\mathsf{D}_N$ with respect to $r$ in Theorem <ref>. Let $C\in|P|$ and $D_0\in C$. Suppose $D_0$ satisfies the complementarity condition. Then all $D\in C$ satisfies the complementarity condition.

If $D_0$ satisfies the complementarity condition, then:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/76-CD-pass.pdf}
\end{equation*}

Applying any permutation or $\had$ on any of the qubits to $D_0$, we shall obtain a diagram of the following form:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/76-CD-pass-proof.pdf}
\end{equation*}

which tells us that any other complementarity diagram belonging to $C$ also satisfies the complementarity condition.

Correspondence between criteria of equivalence for complementarity diagrams and their names.

Equivalence Criteria     Change in Name
Adjoint     No change since $*$ is commutative.
The $p$-th and $q$-th slices in a complementarity diagram are permuted     The $p$-th and $q$-th columns of the name are permuted, along with the $(p+1)$-th and $(q+1)$-th rows are permuted.
Apply $\had$ on the $p$-th slice

* No change in first entry of $p$-th column;

* The entries in the second to $N$-th entry of the $p$-th column are tranformed in the following way:

\begin{eqnarray*}
0 \mapsto 0\\
1 \mapsto k\\
i \mapsto j\\
j \mapsto i\\
k \mapsto 1
\end{eqnarray*}

* The entries in the $(p+1)$-th row are transformed in the following way:

\begin{eqnarray*}
0 \mapsto 0\\
1 \mapsto j\\
i \mapsto k\\
j \mapsto 1\\
k \mapsto i
\end{eqnarray*}

Slices that represent different pairs of constituents

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/76-slice-xy.pdf}
\end{equation*}

No change in name.
Slices that represent different pairs of constituents

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/76-slice-equivalent.pdf}
\end{equation*}

First entry of the corresponding column in the name is transformed in the following way:

$$Z\mapsto 1+Z$$

For some of the criteria in Theorem <ref> and consequently Corollary <ref>, the names of complementarity diagrams do not change but there are others where the names are transformed. In Table <ref>, we shows this correspondence.

Finally, we have all the tools we need to devise a strategy for finding maximal complete sets of mutually complementary classical structures on $N$ qubits. The following is an outline of our strategy:

* Check whether or not each member of $\mathsf{G}_N$ satisfies the complementarity condition;

* Gather all members of $\mathsf{G}_N$ which satisfy the complementarity condition into a set denoted as $\mathsf{G}_N^\text{pass}$;

* Identify the name of each member in $\mathsf{G}_N^\text{pass}$ and collect them in a set denoted as $\mathsf{P}_N$;

* Expand $\mathsf{P}_N$ to include other names of complementarity diagrams within the same equivalence class (see Table <ref>), and denote the expanded set as $\mathsf{T}_N$;

* Generate the names of the complementarity diagrams between all pairs of composite CS on $N$ qubits;

* Check whether or not each name obtained from the previous step is a member of $\mathsf{T}_N$;

* If a name is a member of $\mathsf{T}_N$, then the pair of composite CS it represents are complementary;

* If not, then the pair of composite CS the name represents are not complementary;

* Form a graph where its vertices are composite CS on $N$ qubits, and for each pair of vertices, there exists an edge if, as composite CS, the vertices are complementary, and we denote this graph as $\mathbf{G}_N$;

* Search for complete subgraphs in $\mathbf{G}_N$ and each subgraph will give us a complete set of mutually complementary CS on $N$ qubits.

In the procedure above, we used Quantomatic [Kissinger et al., 2018] to compute the results for step 1 and we used Mathematica [47] to compute the results for steps 4 to 8.

In the next two sections, we shall apply this strategy to search for maximal complete sets of mutually complementary CS on two and three qubits. To simplify and improve readability of complementarity diagrams, we shall forego the connecting wires on the input and output wires of the diagrams and any phases contained in them. For the latter, whether or not a complementarity diagram contains a phase is apparent. That is, there is a phase in a particular slice of a complementarity diagram when only the constituent on the top of the slice or only the one at the bottom is $\mathcal{Y}$. Otherwise, there is no phase in the slice. For the former, we can indeed prove that a complementarity diagram satisfies the complementarity condition if and only if that same complementarity diagram without connecting wires on its input and output wires also satisfies the complementarity condition.

A complementarity diagram on $N$ qubits satisfies the complementarity condition if and only if that same complementarity diagram without connecting wires on its input and output wires also satisfies the complementarity condition.

Let $D$ be a complementarity diagram on $N$ qubits. Suppose $D$ satisfies the complementarity condition. Then, the $p$-th and $q$-th slices of the diagram take the following form:

\begin{equation*}
\includegraphics[scale=0.2]{images/51-75/68-comp-cond.pdf}
\end{equation*}

Meanwhile, the diagram $D$ without connecting wires on its input and output wires, denoted by $D'$, has the following as its $p$-th and $q$-th slices:

\begin{equation*}
\includegraphics[scale=0.2]{images/76-100/95-CD-2.pdf}
\end{equation*}

The labels of the red !-boxes indicate that the repetitions within the boxes may vary in frequency.

Since we have taken the pair of slices to be arbitrary, we can apply the above result to all pairs of slices in $D'$. Thus, any pair of slices in $D'$ must take the following form:

\begin{equation*}
\includegraphics[scale=0.2]{images/76-100/95-CD-final.pdf}
\end{equation*}

which means that $D$ and $D'$ are equivalent up to scalars.

The converse can be proven in a similar way.

§ COMPLEMENTARY CS ON TWO QUBITS

Entangled Complementarity Diagrams in $\mathsf{G}_2$

Fig. <ref> gives the members of $\mathsf{G}_2$ which are entangled, and those complementarity diagrams within boxes in the figure are the ones which satisfy the complementarity condition, i.e. they are members of $\mathsf{G}_2^\text{pass}$.

To complete $\mathsf{G}_2^\text{pass}$, we need to include those complementarity diagrams which are separable. This can be easily obtained from complementarity diagrams on a single qubit, of which there are three (see Fig. <ref>). The middle and rightmost diagrams in Fig. <ref> are complementarity diagrams which satisfy the complementarity condition. We can separably compose them to obtain separable complementarity diagrams on $N$ qubits which satisfy the complementarity condition. For two qubits, those complementarity diagrams are given in Fig. <ref>.

Complementarity diagrams on a single qubit.

Separable Complementarity Diagrams in $G_2^\text{pass}$

The three diagrams in Fig. <ref> along with the boxed complementarity diagrams in Fig. <ref> are all the members of $\mathsf{G}_2^\text{pass}$. From $\mathsf{G}_2^\text{pass}$, we obtain $\mathsf{P}_2$:

\begin{align*}
\mathsf{P}_2 & = &
\left\{
\begin{pmatrix}
1+Z & 1+Z\\
0 & 1+i\\
1+i & 0
\end{pmatrix},
\begin{pmatrix}
1+Z & 0\\
0 & 1+j\\
1+k & 0
\end{pmatrix},
\begin{pmatrix}
Z & 1\\
0 & 1+j\\
1+k & 0
\end{pmatrix},
\begin{pmatrix}
Z & Z\\
0 & 1\\
1 & 0
\end{pmatrix},
\begin{pmatrix}
1+Z & Z\\
0 & j\\
k & 0
\end{pmatrix}\right.,
\\
& &
\quad \left.
\begin{pmatrix}
0 & 0\\
0 & 1\\
1 & 0
\end{pmatrix},
\begin{pmatrix}
1 & 0\\
0 & 1\\
1 & 0
\end{pmatrix},
\begin{pmatrix}
1 & Z\\
0 & 1\\
1 & 0
\end{pmatrix},
\begin{pmatrix}
0 & 1+Z\\
0 & k\\
j & 0
\end{pmatrix},
\begin{pmatrix}
1 & 1\\
0 & 0\\
0 & 0
\end{pmatrix},
\begin{pmatrix}
1 & Z\\
0 & 0\\
0 & 0
\end{pmatrix},
\begin{pmatrix}
Z & Z\\
0 & 0\\
0 & 0
\end{pmatrix}
\right\}
\end{align*}

Performing steps 5 to 8 in the previous section, we obtain the graph $\mathbf{G}_2$ and its complete subgraphs, which are given in Fig. <ref>. Recall that the vertices of $\mathbf{G}_2$ are composite classical structures on two qubits, and edges in the graph are between those pairs of classical structures which are complementary.

Complete subgraphs of $\mathbf{G}_2$

As maximal complete sets of mutually complementary classical structures on two qubits, the complete subgraphs in Fig. <ref> are given as the following sets of names of classical structures:

\begin{eqnarray*}
\left\{
\begin{pmatrix}0&0\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}0&1\\0&1\\1&0\end{pmatrix},
\begin{pmatrix}1&0\\0&1\\1&0\end{pmatrix},
\begin{pmatrix}1&1\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}Z&Z\\0&0\\0&0\end{pmatrix}
\right\}\\
\left\{
\begin{pmatrix}0&1\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}1&0\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}1&1\\0&1\\1&0\end{pmatrix},
\begin{pmatrix}Z&Z\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}Z&Z\\0&i\\i&0\end{pmatrix}
\right\}\\
\left\{
\begin{pmatrix}0&0\\0&1\\1&0\end{pmatrix},
\begin{pmatrix}0&1\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}1&0\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}1&1\\0&1\\1&0\end{pmatrix},
\begin{pmatrix}Z&Z\\0&0\\0&0\end{pmatrix}
\right\}\\
\left\{
\begin{pmatrix}0&Z\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}1&0\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}1&0\\0&1\\1&0\end{pmatrix},
\begin{pmatrix}Z&0\\0&j\\k&0\end{pmatrix},
\begin{pmatrix}Z&1\\0&0\\0&0\end{pmatrix}
\right\}\\
\left\{
\begin{pmatrix}0&Z\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}0&Z\\0&k\\j&0\end{pmatrix},
\begin{pmatrix}1&0\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}1&0\\0&1\\1&0\end{pmatrix},
\begin{pmatrix}Z&1\\0&0\\0&0\end{pmatrix}
\right\}\\
\left\{
\begin{pmatrix}0&Z\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}1&1\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}1&1\\0&1\\1&0\end{pmatrix},
\begin{pmatrix}Z&0\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}Z&1\\0&j\\k&0\end{pmatrix}
\right\}\\
\left\{
\begin{pmatrix}0&Z\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}1&1\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}1&1\\0&1\\1&0\end{pmatrix},
\begin{pmatrix}1&Z\\0&k\\j&0\end{pmatrix},
\begin{pmatrix}Z&0\\0&0\\0&0\end{pmatrix}
\right\}\\
\left\{
\begin{pmatrix}0&1\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}0&1\\0&1\\1&0\end{pmatrix},
\begin{pmatrix}1&Z\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}Z&0\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}Z&0\\0&j\\k&0\end{pmatrix}
\right\}\\
\left\{
\begin{pmatrix}0&1\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}0&1\\0&1\\1&0\end{pmatrix},
\begin{pmatrix}0&Z\\0&k\\j&0\end{pmatrix},
\begin{pmatrix}1&Z\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}Z&0\\0&0\\0&0\end{pmatrix}
\right\}\\
\left\{
\begin{pmatrix}0&0\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}1&Z\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}Z&1\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}Z&1\\0&j\\k&0\end{pmatrix},
\begin{pmatrix}Z&Z\\0&i\\i&0\end{pmatrix}
\right\}\\
\left\{
\begin{pmatrix}0&0\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}1&Z\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}1&Z\\0&k\\j&0\end{pmatrix},
\begin{pmatrix}Z&1\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}Z&Z\\0&i\\i&0\end{pmatrix}
\right\}\\
\left\{
\begin{pmatrix}0&0\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}0&0\\0&1\\1&0\end{pmatrix},
\begin{pmatrix}1&Z\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}Z&1\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}Z&1\\0&j\\k&0\end{pmatrix}
\right\}\\
\left\{
\begin{pmatrix}0&0\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}0&0\\0&1\\1&0\end{pmatrix},
\begin{pmatrix}1&Z\\0&0\\0&0\end{pmatrix},
\begin{pmatrix}1&Z\\0&k\\j&0\end{pmatrix},
\begin{pmatrix}Z&1\\0&0\\0&0\end{pmatrix}
\right\}
\end{eqnarray*}

§ COMPLEMENTARY CS ON THREE QUBITS

For three qubits, a complementarity diagram formed by composite classical structures $\mathcal{A}$ and $\mathcal{B}$ — where the constituents of $\mathcal{A}$ have spiders $\blue, \purple$ and $\orange$, and constituents of $\mathcal{B}$ have spiders $\pink$, $\brown$ and $\cyan$ — satisfies the complementarity condition if it is equal to the following diagram:

\begin{equation*}
\includegraphics[scale=0.2]{images/76-100/80-comp-cond-3Q.pdf}
\end{equation*}

To obtain LHS of the complementarity condition (Eq. <ref>), we find complementarity diagrams on three qubits which consists of the following slices:

\begin{equation*}
\includegraphics[scale=0.2]{images/76-100/80-3qslices.pdf}
\end{equation*}

However, we already know the complementarity diagrams on a single qubit and two qubits which generate complementarity diagrams on those respective number of qubits. So, we can ignore, for the moment, those complementarity diagrams on three qubits which are separable on all qubits and those which are biseparable, i.e. complementarity diagrams which are separable on two pairs of qubits and non-separable on one pair of qubits.

Out of the non-separable complementarity diagrams on three qubits which contain $sD_{11}, sD_{12}, sD_{13}, sD_{21},$ and $sD_{22}$ as subdiagrams, we can eliminate those with names containing at least one column for which the first entry is $1+Z$ and the other entries of the column do not belong in $\{i,k,1+i,1+k,j+i,j+k\}$. We can further reduce the complementarity diagrams by keeping one representative of complementarity diagrams which are equivalent up to permutation on qubits, and discarding the rest. Such a reduced complementarity diagrams on three qubits form a subset of $\mathsf{G}_3$ which contain members which are non-separable on all qubits. We denote this set as $\mathsf{G}_3^\text{ent}$. The members of the $\mathsf{G}_3^\text{ent}$ are given in Section <ref>. The matrices within boxes in Section <ref> are names of complementarity diagrams belonging to $\mathsf{G}^\text{ent}_3\cap\mathsf{G}^\text{pass}_3$. We can obtain the rest of the members of $\mathsf{G}^\text{pass}_3$ from $\mathsf{G}^\text{pass}_1$ and $\mathsf{G}^\text{pass}_2$.

The following are the separable complementarity diagrams on three qubits which satisfy the complementarity condition:

\begin{equation*}
\includegraphics[scale=0.18]{images/76-100/80-3qsep.pdf}
\end{equation*}

For the biseparable complementarity diagrams on three qubits, we can simply separably compose those complementarity diagrams on a single qubit and those on two qubits, shown below, which satisfy the complementarity condition:

\begin{equation*}
\includegraphics[scale=0.2]{images/76-100/80-bisep.pdf}
\end{equation*}

So, in total, $\mathsf{G}^\text{pass}_3$ has 251 members. With this, we are able to obtain $\mathsf{P}_3$, and consequently, $\mathsf{T}_3$. Then we can check complementarity between every pair of composite classical structures on three qubits and form the graph $\mathbf{G}_3$. Via our computation using Mathematica, we found 32,448 complete sets of mutually complementary classical structures on three qubits. All such sets have entanglement configurations in accordance to the results in reference [Romero et al., 2005]. Here, we give one example for each entanglement configuration. By entanglement configuration, we mean $(n_\text{SC},n_\text{BS},n_\text{NS})$ of a complete set of mutually complementary classical structures where $n_\text{SC}$ is the number of separably-composed classical structures in the set, $n_\text{BS}$ is the number of biseparable classical structures in the set, and $n_\text{NS}$ is the number of non-separable classical structures in the set. For three qubits, there are four entanglement configurations: (3,0,6), (2,3,4), (1,6,2), and (0,9,0) [Romero et al., 2005].

An example of a complete set of mutually complementary classical structures for (3,0,6) is:

\begin{eqnarray*}\{\begin{pmatrix}0&1&0\\0&1&1\\1&0&1\\1&1&0\end{pmatrix},\begin{pmatrix}1&0&0\\0&1&1\\1&0&0\\1&0&0\end{pmatrix},\begin{pmatrix}0&0&1\\0&1&0\\1&0&1\\0&1&0\end{pmatrix},\begin{pmatrix}Z&Z&0\\0&0&j\\0&0&j\\k&k&0\end{pmatrix},\begin{pmatrix}1&1&1\\0&0&1\\0&0&1\\1&1&0\end{pmatrix},\\\begin{pmatrix}0&1&Z\\0&0&k\\0&0&k\\j&j&0\end{pmatrix},\begin{pmatrix}Z&1&1\\0&0&0\\0&0&0\\0&0&0\end{pmatrix},\begin{pmatrix}1&Z&0\\0&0&0\\0&0&0\\0&0&0\end{pmatrix},\begin{pmatrix}0&0&Z\\0&0&0\\0&0&0\\0&0&0\end{pmatrix}\}\end{eqnarray*}

An example of a complete set of mutually complementary classical structures for (2,3,4) is:

\begin{eqnarray*}\{\begin{pmatrix}1&0&0\\0&1&1\\1&0&1\\1&1&0\end{pmatrix},\begin{pmatrix}1&1&0\\0&1&0\\1&0&1\\0&1&0\end{pmatrix},\begin{pmatrix}0&0&0\\0&1&0\\1&0&0\\0&0&0\end{pmatrix},\begin{pmatrix}Z&1&Z\\0&0&i\\0&0&k\\i&j&0\end{pmatrix},\begin{pmatrix}0&0&1\\0&0&1\\0&0&1\\1&1&0\end{pmatrix},\\\begin{pmatrix}1&1&1\\0&0&1\\0&0&0\\1&0&0\end{pmatrix},\begin{pmatrix}0&1&1\\0&0&0\\0&0&1\\0&1&0\end{pmatrix},\begin{pmatrix}Z&Z&Z\\0&0&0\\0&0&0\\0&0&0\end{pmatrix},\begin{pmatrix}1&0&1\\0&0&0\\0&0&0\\0&0&0\end{pmatrix}\}\end{eqnarray*}

An example of a complete set of mutually complementary classical structures for (1,6,2) is:

\begin{eqnarray*}\{\begin{pmatrix}1&0&0\\0&1&0\\1&0&0\\0&0&0\end{pmatrix},\begin{pmatrix}0&1&Z\\0&1&0\\1&0&0\\0&0&0\end{pmatrix},\begin{pmatrix}Z&Z&0\\0&0&j\\0&0&j\\k&k&0\end{pmatrix},\begin{pmatrix}1&1&Z\\0&0&k\\0&0&k\\j&j&0\end{pmatrix},\begin{pmatrix}1&Z&1\\0&0&1\\0&0&0\\1&0&0\end{pmatrix},\\\begin{pmatrix}0&1&0\\0&0&1\\0&0&0\\1&0&0\end{pmatrix},\begin{pmatrix}Z&0&0\\0&0&0\\0&0&1\\0&1&0\end{pmatrix},\begin{pmatrix}1&1&1\\0&0&0\\0&0&1\\0&1&0\end{pmatrix},\begin{pmatrix}0&0&1\\0&0&0\\0&0&0\\0&0&0\end{pmatrix}\}\end{eqnarray*}

An example of a complete set of mutually complementary classical structures for (0,9,0) is:

\begin{eqnarray*}\{\begin{pmatrix}1&0&Z\\0&1&0\\1&0&0\\0&0&0\end{pmatrix},\begin{pmatrix}0&Z&0\\0&k&0\\j&0&0\\0&0&0\end{pmatrix},\begin{pmatrix}0&1&1\\0&1&0\\1&0&0\\0&0&0\end{pmatrix},\begin{pmatrix}1&0&0\\0&0&1\\0&0&0\\1&0&0\end{pmatrix},\begin{pmatrix}0&Z&1\\0&0&1\\0&0&0\\1&0&0\end{pmatrix},\\\begin{pmatrix}0&1&Z\\0&0&k\\0&0&0\\j&0&0\end{pmatrix},\begin{pmatrix}Z&1&Z\\0&0&0\\0&0&k\\0&j&0\end{pmatrix},\begin{pmatrix}1&1&1\\0&0&0\\0&0&1\\0&1&0\end{pmatrix},\begin{pmatrix}0&0&0\\0&0&0\\0&0&1\\0&1&0\end{pmatrix}\}\end{eqnarray*}

§ CHAPTER SUMMARY

In this chapter,

* We introduced complementarity diagrams in Section <ref> and presented its general form for composite classical structures on two qubits;

* Generalizing to $N$ qubits, we showed how to partition complementarity diagrams into equivalence classes so that we may search for those diagrams which satisfy the complementarity diagrams more efficiently;

* We also highlighted those complementarity diagrams which can be formed by more than a single pair of composite classical structures by splitting a complementarity diagram into slices which correspond to a subdiagram on an individual qubit;

* Finally, we introduced a procedure for obtaining every pair of complementary classical structures for the case of two and three qubits (see Section <ref>);