Vector Generation of Contextual Sets

As quantum contextuality proves to be a necessary resource for universal quantum computation, we present a general method for vector generation of Kochen-Specker (KS) contextual sets in the form of hypergraphs. The method supersedes all three previous methods: (i) fortuitous discoveries of smallest KS sets, (ii) exhaustive upward hypergraph-generation of sets, and (iii) random downward generation of sets from fortuitously obtained big master sets. In contrast to previous works, we can generate master sets which contain all possible KS sets starting with nothing but a few simple vector components. From them we can readily generate all KS sets obtained in the last half a century and any specified new KS sets. Herewith we can generate sufficiently large sets as well as sets with definite required features and structures to enable varieties of different implementations in quantum computation and communication.


Introduction
It has recently been recognized that "contextuality [can serve] as a [quantum] computational resource" [1]. In particular, in [1] it is shown "that what makes magic states [superposed states of qubits initialized by quantum stabilizers] special is precisely their contextuality. Specifically, they find that magic states possess exactly the properties needed to prove that quantum physics is contextual using an experimental test that relies only on stabilizer operations. That is, the authors demonstrate that this particular measurable aspect of quantum weirdness-contextuality-is the source of a quantum computer's power" [2].
Further elaboration and future implementation of contextual sets within such a framework of providing a computational resource for quantum computation would require an optimal way for their massive generation with desired properties and structures. In this paper we give a method for generating the kind of contextual sets that so far has been explored the mostthe so-called Kochen-Specker (KS) sets, which are constructive proofs of the KS theorem [3] which "implies the impossibility of explaining the statistical predictions of quantum theory in a natural way. In particular, the actual outcome observed under a quantum measurement cannot be understood as simply revealing a preexisting value[s]" [1] of a classical theory or [13], and solid state molecular nuclear spins [14]. Experiments have also been done with 6D systems via six paths [15,16] and with photons in an 8D space [17].
In quantum communication and quantum cryptography, KS sets are used for protecting [18] and securing [19] quantum key distribution (QKD) protocols. Quantum contextuality can be used to reveal quantum nonlocality [20]. KS sets can serve as generators of higherorder generalized orthoarguesian lattices in lattice theory [21,22]. Also, operator-generated 4D complex KS sets provide a design for constructing quantum gates [23].
The features of the previous approaches to KS sets in the literature are as follows.
The smallest KS sets [8,12,15,[24][25][26][27][28][29][30][31][32] are of just historical relevance because practically all of them in even dimensional (from 4D up to 32D) Hilbert spaces are already known and because all of them are by-products of more comprehensive KS set generation. On the other hand, experimentally, the complexity of implementation grows only linearly with the complexity of the sets and it has been found out that the simplest of KS sets often do not possess features that bigger KS sets exhibit, like, e.g., the so-called δ-feature, absence of real coordinatization, absence of parity proofs, etc.
Exhaustive upward generation of KS sets [33,34] faces computational limits of supercomputers and is limited to ca. 40 hypergraph vertices in 3D, to ca. 25 ones in 4D, and so on. For these there is the additional task of rejecting hypergraphs that do not admit a vector coordinatization, a problem whose existing algorithms are still computationally infeasible in some cases. However, this approach remains the only deterministic and completely exhaustive generation method for obtaining KS sets.
Polytopes or Pauli operators can serve as providers of big master sets which enable random downward generation of smaller sets [23,[35][36][37][38][39][40][41][42][43][44]. However, this method is based on serendipitous or intuitively found polytopes or operators. Also, they do not generalize. Still, they are a valuable source of coordinatization and many KS set features as we also show below [44].
In the present paper, we present a new method of generating KS sets from a small set of components of orthogonal vectors. In other words, we show that sets of simple orthogonal vectors inherently lead to KS sets. Such simple components we obtain either from the coordinatization of the master sets from the aforementioned polytope approach or directly from an automated computer search. It provides us not only with a uniform and general method for KS set generation but also with a larger scope and a bigger, more thorough picture of quantum contextuality than any of the previous approaches.
Most of the results in the paper are generated within our hypergraph language and its algorithms and programs written in C we developed in [21,34,36,37,[45][46][47][48] and extended here, as well as the parity-proof algorithms and programs developed in [23,35,38,42].
In the end, we discuss several new features and interconnectedness of the KS sets from the 4D and 6D KS classes which serve us as examples of our method.
The paper is organized as follows. Formalism, algorithms, and programs are introduced in Sec. 2. A small KS set master is vector generated in Sec. 3, where also a method of stripping edges and generating a KS class is introduced. A general vector generation of large, so far unknown, KS master sets and KS classes is presented in Sec. 4. Sec. 5 deals with controlling the sizes of vector generated sets. In Sec. 6 we generated a new 6D class which contains the so-called star set, herewith closing a related open question. Sec. 7 contains our conclusions.

Contextual hypergraph language-algorithms and programs
We encode KS sets via McKay-Megill-Pavičić (MMP) hypergraphs which are defined as hypergraphs in which edges that intersect each other in n−2 vertices contain at least n vertices.
Vertices correspond to vectors and edges to their orthogonalities. The MMP hypergraph formalism has been developed in [34,44,48].
The essence of the KS formalism lies in the inability to assign predetermined values, 1 and 0, to vertices and edges (vectors and their orthogonal 4-tuples) of MMP hypergraphs, graphically visualised as dots and lines (straight or curved) connecting each (orthogonal) four of them. They form sets, called KS sets, in which the following condition is violated: "One and only one of the vertices from any edge of the set is assigned 1, while the others are assigned 0." Each KS set is thus represented by a collection of edges mutually connected into a single hypergraph which, by its very design, amounts to a proof of the Kochen-Specker theorem, provided its coordinatization can be given. [3,44].
MMP hypergraphs are encoded by means of printable ASCII characters. Vertices are denoted by one of the following characters: [47]. When all of them are exhausted one reuses them prefixed by '+', then again by '++', and so forth. A number of examples are given below. We generate, process, and handle MMP hypergraphs by means of algorithms in the programs SHORTD, MMPSTRIP, MMPSUBGRAPH, VECFIND, STATES01, and others [21,34,37,45,47,49]. We have also defined extensions to the notation (prefixes and suffixes) that allow us to attach additional information such as a vector assignment to the vertices [48]. All of our programs work seamlessly within this language that unambiguously describes hypergraphs and associated information. Our programs are available for general use in our repository [50].

{-1,0,1}-component generation of the smallest KS class
Our program VECFIND provides us with master sets generated by vector components. As shown in [51] {-1,0,1} components give us a master set with 40 vertices and 32 edges, denoted as 40-32. It consists of two disconnected subsets: a 24-24 KS set and a 16-8 non-KS set, as shown in Fig. 1. The 24-24 set is isomorphic with the 24-24 set found by A. Peres in 1991 [24]. Had Peres recognized that his set can be given a graphical representation as in Fig. 1, he would have immediately seen all the smaller sets contained in it. Without it, it took three years until M. Kernaghan [25] found one of the subsets.  Two years later, A. Cabello et al. [27] found another KS set (18-9) also from Peres ' 24-24. Note that the two 24-24s from Figs. 1 and 2 are isomorphic to each other.
In 2005 we carried out an exhaustive constructive upward hypergraph-generation of KS sets of up to 23 edges and a single 24-24, i.e., Peres' set [33]. In that paper we extracted all KS sets whose vertices could be given a coordinatization with {-1,0,1} components. We also proved that the aforementioned 18-9 is the smallest 4D KS set with such a coordinatization.
Simple vector components, in our case {-1,0,1}, introduced as inputs into our program exhaustively gives a KS master set 40-32. Exhaustively here means that all vectors with the given components are used up for the construction of the master. That also means that the 24-24 set does not make use of all vectors with these components. Some serve to build the non-KS 16-8 also contained in the 40-32.
Graphical representation of MMP hypergraphs first given in [33] and shown in Figs. 1 and 2 prompted us to design a stripping algorithm and program MMPSTRIP which served us to strip the edges from the 24-24 KS set and obtain all 1232 KS sets contained in it within less than 2 mins on a PC [47]. We say that such KS subsets of a master KS set form a KS class. 24-24 contains many more non-KS subsets and we filter out the KS subsets by means of our program STATES01.
Thus our method consists of, first, generating a KS master set from simple vector components by means of VECFIND, then stripping its edges with MMPSTRIP, and finally filtering out its KS subsets via STATES01 so as to keep only minimal KS subsets; minimal, in the sense that a removal of any edge (i.e., any n-tuple of mutual orthogonalities, of n vectors from an n-dimensional Hilbert space), turns such a KS subset into a non-KS set. In other words, they represent a KS setup that has no redundancy. We call these critical KS sets. They are all we need for an experimental implementation-additional orthogonalities that bigger KS sets that contain critical ones might possess do not add any new property to the ones that the minimal critical core already has.
But even this smaller set of components immediately reveals that the master set we would obtain by our vector generation method must contain the 40-32 class from Sec. 3 while the polytope-derived 148-265 class does not contain KS sets smaller than the 40-23 critical KS set, as one can see from Fig. 10 in [44]. Thus the master set turns out to be much larger than the polytope-generated one-it has 400 vertices and 1012 edges and that 400-1012 master set does not split into disconnected subsets as the 40-32 master set. By means of MMPSTRIP and STATES01 we then extract smaller KS subsets contained in the master set. A distribution of the smallest critical subsets is shown in Fig. 3, and we see that it populates the span between the 40-32 class whose maximal critical is 24-15 and the polytope 148-265 class whose minimal critical is 40-23. Only smaller criticals with up to 118 vertices and 65 edges have parity proofs while most of the sets starting with 27-15 lack it. Also practically all KS sets apart from the smallest one 18-9 possess the so-called δ-feature of two edges sharing two vertices, i.e., intersecting each other at two vertices [44]. This is in contrast to the 300-675 class [44] where none of 10 10 KS criticals possesses the δ-feature.

Controlling the size of KS classes
In Sec. 4 we obtained a big KS class from the set of components {0, ±1, ±ω, ±ω 2 } which closed the gap from the 40-32  and 148-256 KS classes. However, if we just wanted to generate smaller KS sets that would include sets from that gap, then starting with a big master set is a waste of resources and slows down the generation.
To resolve such a problem we consider the components and choose the most efficient ones either by an automated selection or by examination of components. For instance, we see that {-1,0,1} and (−ω,0,ω) when considered alone are equivalent. Combined, they form a bigger set but if we dispense with {-1,0,1} and just combine ±ω and +ω 2 , so as to make use of {−ω,0,ω,ω 2 } components, we obtain a fairly small 180-203 KS master set which can be processed within hours on a supercomputer. A distribution of its criticals is given in Fig. 5. We can see that there are KS criticals with 16 and 18 edges which, as can be seen from the Fig. 3, we still have not obtained within 400-1012 distribution although we run the generation of the latter class ten times longer than of the former.

Generation in a new territory
The 4D KS space was extensively examined, and many ways of finding KS sets were explored. Not so in the other dimensions, though. For example, the first KS set in the 6D was found only recently [15]. It is the star set shown in Fig. 6(a).  The question emerged on whether we could find a KS class that contains the star set. In [44], another huge 6D class was generated, but it did not contain the star set. It was only shown that there exists a triangular representation of the star set shown in Fig. 6(b).