\documentclass[%
  reprint,
  superscriptaddress,
  amsmath,amssymb,
  pra,
  floatfix,
  longbibliography
]{revtex4-2}

\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{bm}
\usepackage{longtable}
\usepackage[colorlinks=true,allcolors=blue]{hyperref}
\usepackage{orcidlink}

\usepackage{braket}

\begin{document}

%\title{Phase-adjusted realification of a \texorpdfstring{$\mathbb{C}^3$}{C3} Kochen-Specker configuration into \texorpdfstring{$\mathbb{R}^6$}{R6}}
\title{Faithful real embedding of a three-dimensional complex Kochen-Specker configuration}

\author{Andrei Khrennikov\,\orcidlink{0000-0002-9857-0938}}
\email{andrei.khrennikov@lnu.se}
\homepage{https://lnu.se/personal/andrei.khrennikov/}

\affiliation{Institutionen f\"or Matematik, Fakulteten f\"or Teknik,
Linnaeus University, SE-351~95 V\"axj\"o, Sweden}

\author{Karl Svozil\,\orcidlink{0000-0001-6554-2802}}
\email{karl.svozil@tuwien.ac.at}
\homepage{http://tph.tuwien.ac.at/~svozil}

\affiliation{Institute for Theoretical Physics,
TU Wien,
Wiedner Hauptstrasse 8-10/136,
1040 Vienna,  Austria}

\date{\today}

\begin{abstract}
We describe a phase-adjusted realification procedure that embeds any finite set of rays in $\mathbb{C}^3$ into $\mathbb{R}^6$. By assigning an appropriate phase to each ray before applying the standard coordinate-wise map, we can arrange that two rays are orthogonal in $\mathbb{C}^3$ if and only if their images are orthogonal in $\mathbb{R}^6$, so the construction yields a faithful orthogonal representation of the original complex configuration. As a concrete example, we consider the 165 projectively distinct rays used in a $\mathbb{C}^3$ Kochen-Specker configuration obtained from mutually unbiased bases, list these 165 rays explicitly in $\mathbb{C}^3$, and give for each of them its image in $\mathbb{R}^6$ under the canonical realification map. We also note that, because the original 3-element contexts are no longer maximal in $\mathbb{R}^6$, the embedded configuration admits two-valued states even though its realisation with maximal contexts in $\mathbb{C}^3$ is Kochen-Specker uncolourable.
\end{abstract}

\maketitle

\section{A Kochen-Specker Proof for the Nonequivalence of Real and Complex Hilbert Space}

A foundational question in quantum theory is whether the use of complex
numbers is merely a matter of mathematical convenience or a fundamental
feature of the physical formalism~\cite{renou-2021,Weilenmann2025PartialIndependencePRL,Hoffreumon2025NoComplex,Hita2025RealQM,Ying2025FoilComplex,Hardy2012LimitedHolism,Stueckelberg1961RealHilbertII,Bednorz2022OptimalDiscrimination,Aleksandrova2013UniversalQubit,Wootters2016OptimalInformationTransfer,Rudolph2002TwoRebitUniversal,McKague2009SimulatingRealHilbert,Erba2024CompositionRule}.
On the one hand, any finite-dimensional complex Hilbert space $\mathbb{C}^n$ can be
represented as a real Hilbert space $\mathbb{R}^{2n}$ via the usual
``realification'' map that separates real and imaginary parts. This is a
typical instance of the general fact that, under sufficiently permissive
assumptions (allowing a change of dimension and additional structure such as
a complex-structure operator), a real formulation of a complex theory is
always possible. Moreover, for many quantum information processing tasks
such as quantum computation and Bell nonlocality, standard real quantum
theory in this sense is already sufficient to reproduce the operational
predictions of the complex theory
\cite{Aleksandrova2013UniversalQubit,Wootters2016OptimalInformationTransfer,Rudolph2002TwoRebitUniversal,McKague2009SimulatingRealHilbert}.
On the other hand, recent theoretical and experimental work has shown that
if one insists on keeping fixed certain natural structural ingredients
(composition via tensor products, the notion of locality, and the usual
Hilbert-space interpretation of contexts as maximal orthonormal sets), then
there exist correlations and logical structures that are realised in complex
Hilbert spaces but cannot be obtained from any purely real Hilbert-space
model~\cite{renou-2021,Weilenmann2025PartialIndependencePRL,Hoffreumon2025NoComplex,Hita2025RealQM,Ying2025FoilComplex,Bednorz2022OptimalDiscrimination,Erba2024CompositionRule}.

It is therefore useful to distinguish three viewpoints:
(i) Whether quantum theory can be formulated over the reals depends on which
structural assumptions one demands to be preserved.
(ii) For a large class of quantum information tasks, real quantum theory is
operationally sufficient.
(iii) There are also more pragmatic, representation-focused approaches that
encode complex quantum mechanics into a real framework at the price of
introducing a formal structure different from quantum theory~\cite{BarriosHita2025RealQM}.

Against this background, in this paper we present a complementary, Kochen-Specker (KS) type argument on the ``no-go'' side for the logical
inequivalence of three-dimensional real and complex Hilbert-space quantum
theories, within the standard Hilbert-space framework where sharp yes--no
propositions correspond to rays and physical contexts are identified with
maximal sets of mutually orthogonal rays. Rather than working with
inequalities and probabilities, our approach is based on the logical
framework of the Kochen-Specker theorem: we consider a finite set of
rays and their orthogonality relations and derive a direct contradiction
with the existence of classical truth assignments, formalised by
two-valued states. In addition, we exploit a concrete phase-adjusted realification into
$\mathbb{R}^6$, which provides an explicit example of the representation-focused
approach in~(iii).

We focus on a specific KS-type configuration introduced by Cabello~\cite{Cabello2025}
as a threefold extension of the Yu--Oh configuration~\cite{Yu-2012}. As pointed
out by Harding and Salinas Schmeis~\cite{harding2025remarksIJTP} and analysed
in detail by Navara and Svozil~\cite{svozil-2025-MYOCHS}, a key structural
ingredient of this configuration is the existence, in $\mathbb{C}^3$, of a complete
set of mutually unbiased bases (MUBs). Two orthonormal bases are mutually
unbiased if every vector of one basis has equal ``overlap'' with every vector
of the other. The theory of MUBs is a rich subject with deep connections to
quantum information and finite geometry
\cite{Schwinger.60,WooFie,Brierley2009,springerlink:10.1007/978-3-540-24633-6_10,durt,mcnulty2024mutually}.
For the present work, the crucial facts are~\cite{durt,mcnulty2024mutually}:
\begin{enumerate}
  \item In $\mathbb{C}^3$ one can construct a complete set of $D+1=4$ MUBs.
  \item In $\mathbb{R}^3$ it is impossible to find even two mutually unbiased
        orthonormal bases.
\end{enumerate}

The Yu-Oh-Cabello-KS configuration we consider~\cite{Cabello2025} is built
explicitly from the four MUBs in $\mathbb{C}^3$ and consists of 165 rays arranged
into 130 contexts; in Section~\ref{sec:KSconfig} we describe this
configuration in detail.

The present paper has two aims. First, building on the work of Harding and
Salinas Schmeis~\cite{harding2025remarksIJTP} and of Navara and
Svozil~\cite{svozil-2025-MYOCHS}, we recast their observations in a
MUB-based setting by collecting in one place the explicit 165-ray,
130-context KS configuration in $\mathbb{C}^3$ due to Cabello~\cite{Cabello2025}
and explaining, in this concrete example, why its orthogonality relations
cannot be realised by any set of unit vectors in $\mathbb{R}^3$ when contexts are
required to be maximal. Thus, while neither the configuration nor the
impossibility of such a real realisation are new, our treatment provides a
self-contained finite illustration of a logical structure---a set of
propositions and contexts---that exists in three-dimensional complex quantum
theory but not in three-dimensional real quantum theory under the same
interpretation of contexts.

Second, and this is the genuinely new part of the present work, we show that
the same orthogonality hypergraph does admit a faithful orthogonal
representation~\cite{lovasz-79} in $\mathbb{R}^6$: by appropriately choosing the
phase of each ray before applying the standard coordinate-wise separation
into real and imaginary parts, we embed all 165 rays as vectors in $\mathbb{R}^6$
so that two rays are orthogonal in $\mathbb{C}^3$ if and only if their images are
orthogonal in $\mathbb{R}^6$. However, in this real embedding each 3-element
context now spans only a 3-dimensional subspace of $\mathbb{R}^6$ and is no longer
maximal. It can always be extended to a full orthonormal basis of $\mathbb{R}^6$
by adding three extra vectors outside the configuration. This allows one to
construct two-valued states by assigning value $0$ to all 165 embedded rays
and value $1$ to a suitable extra basis vector in each completed context.

In this way, the same finite orthogonality hypergraph, realised as maximal
contexts in $\mathbb{C}^3$, is KS-uncolourable and admits no classical two-valued
states, whereas its faithful realisation in $\mathbb{R}^6$ does admit classical
two-valued states once contexts are interpreted as maximal in the larger
space. Our analysis therefore highlights a nuanced picture: at fixed
dimension $3$, and with the usual identification of contexts with maximal
orthonormal sets, there exist logical structures realisable in complex but
not in real quantum theory, in line with earlier work
\cite{harding2025remarksIJTP,svozil-2025-MYOCHS}. At the same time, our
phase-adjusted realification shows that \emph{orthogonality relations
alone} do not separate real from complex quantum theory, since any finite
orthogonality hypergraph arising from rays in $\mathbb{C}^3$ admits a faithful
orthogonal representation in a suitable real Hilbert space. This clarifies
the scope of KS-style arguments in the real--complex debate and complements
earlier correlation-based separations between real and complex
Hilbert-space models.

Our argument is, in this sense, system-dependent but basis-independent: it
singles out a specific three-dimensional configuration and shows that it can
be realised in complex but not in real Hilbert space of the same dimension
when contexts are required to be maximal, yet the statement does not depend
on any preferred basis. This positions our work between basis- and
system-dependent, representation-focused approaches (such as resource
theories of coherence or imaginarity) and more global, semi-device-independent
separations between real and complex quantum theories in the style of
Renou \emph{et al.}~\cite{renou-2021}.



\section{Phase-adjusted realification in \texorpdfstring{$\mathbb{C}^3$}{C3}}

\subsection{Set-up}

Let $\{\,[\psi_k]\,\}_{k=1}^N$ be a finite set of rays in $\mathbb{C}^3$, with normalized representatives $\psi_k\in\mathbb{C}^3$, and let
\begin{equation}
  c_{k\ell} := \langle \psi_k,\psi_\ell\rangle_{\mathbb{C}}
\end{equation}
denote their complex inner products.

For each ray we may multiply $\psi_k$ by an arbitrary unit complex phase
$e^{\mathrm{i}\theta_k}$ without changing the ray. We first define the canonical realification map $\Phi_0: \mathbb{C}^3 \to \mathbb{R}^6$ as
\begin{equation}
  \Phi_0(z_1, z_2, z_3) := (\Re z_1, \Re z_2, \Re z_3, \Im z_1, \Im z_2, \Im z_3).
  \label{eq:phi0}
\end{equation}
In the physics literature this
invariance under multiplication by a global phase $e^{\mathrm{i}\theta_k}\in U(1)$
is often referred to as an (abelian) gauge freedom. We exploit this freedom
and define a \emph{phase-adjusted realification}
\begin{equation}
  R_k := \Phi_0\bigl( e^{\mathrm{i}\theta_k}\,\psi_k\bigr)\in\mathbb{R}^6,
\label{2025-rvc-padef}
\end{equation}

Note that the real part of the complex inner product is exactly the real dot
product:
\begin{align}
  R_k\cdot R_\ell
  &= \Phi_0(e^{\mathrm{i}\theta_k}\psi_k)\cdot \Phi_0(e^{\mathrm{i}\theta_\ell}\psi_\ell) \nonumber\\
  &= \Re\Bigl\langle e^{\mathrm{i}\theta_k}\psi_k, e^{\mathrm{i}\theta_\ell}\psi_\ell\Bigr\rangle_{\mathbb{C}} \nonumber\\
  &= \Re\bigl( e^{\mathrm{i}(\theta_\ell-\theta_k)} c_{k\ell}\bigr).
  \label{eq:real-dot}
\end{align}
If $c_{k\ell}=0$, then $R_k\cdot R_\ell=0$ for all phases, so complex orthogonality is always preserved. The only potential issue is that for $c_{k\ell}\neq 0$ we might accidentally choose phases such that $R_k\cdot R_\ell=0$, thereby introducing a spurious orthogonality.

\subsection{Forbidden phase differences for non-orthogonal pairs}

Assume $c_{k\ell}\neq 0$. Write $c_{k\ell}=|c_{k\ell}|e^{\mathrm{i}\varphi_{k\ell}}$. Then Eq.~\eqref{eq:real-dot} becomes
\begin{equation}
  R_k\cdot R_\ell
  = |c_{k\ell}|\,\cos\bigl( (\theta_\ell-\theta_k)+\varphi_{k\ell}\bigr).
\end{equation}
Thus $R_k\cdot R_\ell=0$ if and only if
\begin{equation}
  (\theta_\ell-\theta_k)+\varphi_{k\ell} \equiv \frac{\pi}{2}\pmod{\pi}.
\end{equation}
For a fixed $\theta_k$ and fixed nonzero $c_{k\ell}$, this excludes at most two values of $\theta_\ell$ modulo $2\pi$:
\begin{equation}
  \theta_\ell \equiv \theta_k -\varphi_{k\ell} + \frac{\pi}{2}
  \quad\text{or}\quad
  \theta_\ell \equiv \theta_k -\varphi_{k\ell} + \frac{3\pi}{2}
  \pmod{2\pi}.
\label{2025-rvc-pa}
\end{equation}

Changing $\theta_k$ shifts both forbidden values of $\theta_\ell$ by the same amount, reflecting the overall phase (gauge) freedom in the choice of ray representatives.


\subsection{Existence of a faithful embedding}

We construct the phases $\theta_1,\dots,\theta_N$ inductively.

\begin{itemize}
  \item Set $\theta_1:=0$ arbitrarily.
  \item Suppose $\theta_1,\dots,\theta_{m-1}$ have been chosen such that for all non-orthogonal pairs $(k,\ell)$ with $1\le k<\ell<m$ we have $R_k\cdot R_\ell\neq 0$.
  \item For the new ray $m$, consider all pairs $(k,m)$ with $1\le k<m$ and $c_{km}\neq 0$. For each such pair, the two forbidden values of $\theta_m$ described above define a finite set $F_{k,m}\subset S^1$, where $S^1$ denotes the unit circle.
\end{itemize}

Let
\begin{equation}
  F_m := \bigcup_{\substack{1\le k<m \\ c_{km}\neq 0}} F_{k,m},
\end{equation}
which is a finite subset of the unit circle. Choose $\theta_m$ anywhere on $S^1\setminus F_m$---that is, from the set of admissible phase values excluding the finite forbidden set $F_m$.
By construction, for every non-orthogonal pair $(k,m)$ we have $R_k\cdot R_m\neq 0$, while pairs with $c_{km}=0$ remain orthogonal for all phases. Since the forbidden set $F_m$ is finite and the circle is connected, such a $\theta_m$ always exists; in fact, all but finitely many phases work. Proceeding by induction on $m$, we can successively choose the phases $\theta_m$ so that no unwanted orthogonality is introduced, obtaining a full set of phases $\{\theta_k\}_{k=1}^N$ such that
\begin{equation}
  c_{k\ell}=0 \iff R_k\cdot R_\ell=0.
\end{equation}
Thus $\{R_k\}_{k=1}^N\subset\mathbb{R}^6$ is a faithful orthogonal representation of the original finite set of rays in $\mathbb{C}^3$.

In particular, if $\{\psi_{i},\psi_{j},\psi_{k}\}$ form an orthonormal basis of $\mathbb{C}^3$, then each pair is orthogonal in $\mathbb{C}^3$, hence each pair $R_i,R_j,R_k$ is orthogonal in $\mathbb{R}^6$, so orthogonal triples (contexts) are preserved.

\section{Explicit list of the 165 rays and their images in \texorpdfstring{$\mathbb{R}^6$}{R6}}
\label{sec:KSconfig}

\subsection{Complex notation}

In the previous section we showed in general that any finite family of rays in $\mathbb{C}^3$
admits a faithful orthogonal representation in $\mathbb{R}^6$ by an appropriate choice of
phases and the realification map $\Phi_0$. We now specialise this construction to the
concrete KS-type configuration introduced by Cabello and described in
Sect.~\ref{sec:KSconfig}: in this section we fix explicit representatives for the 165
rays and write down their images in $\mathbb{R}^6$.

To keep the expressions compact, it is convenient to exploit the algebraic structure of
this configuration. Since it is built from four mutually unbiased bases in dimension
three, all vector coordinates lie in the cyclotomic field generated by a primitive
third root of unity. We therefore introduce the shorthand
\begin{equation}
  \omega := e^{2\pi\mathrm{i}/3} = -\frac12 + \mathrm{i}\,\frac{\sqrt{3}}{2}, \qquad
  \omega^2 = \overline{\omega} = -\frac12 - \mathrm{i}\,\frac{\sqrt{3}}{2},
\end{equation}
with $1+\omega+\omega^2=0$.

Every coordinate in the 165 rays below is a real multiple of $1$, $\omega$, or $\omega^2$ with integer coefficients in $\{-2,-1,0,1,2\}$. For any $z=a+b\,\omega+c\,\omega^2$ ($a,b,c\in\mathbb{R}$) we have
\begin{align}
  \Re z &= a - \frac{b+c}{2},\\
  \Im z &= \frac{\sqrt{3}}{2}\,(b-c).
\end{align}
In particular, $0 \mapsto (0,0)$, and
\begin{align}
  1 &\mapsto (1,0), &
  -1 &\mapsto (-1,0), \nonumber\\
  \omega &\mapsto \Bigl(-\tfrac12,\ \tfrac{\sqrt{3}}{2}\Bigr), &
  \omega^2 &\mapsto \Bigl(-\tfrac12,\ -\tfrac{\sqrt{3}}{2}\Bigr), \nonumber\\
  2\omega &\mapsto \bigl(-1,\ \sqrt{3}\bigr), &
  2\omega^2 &\mapsto \bigl(-1,\ -\sqrt{3}\bigr), \nonumber\\
  -\omega &\mapsto \Bigl(\tfrac12,\ -\tfrac{\sqrt{3}}{2}\Bigr), &
  -\omega^2 &\mapsto \Bigl(\tfrac12,\ \tfrac{\sqrt{3}}{2}\Bigr), \\
  -2\omega &\mapsto \bigl(1,\ -\sqrt{3}\bigr), &
  -2\omega^2 &\mapsto \bigl(1,\ \sqrt{3}\bigr). \nonumber
\end{align}

Since three complex components are encoded as six real ones, the resulting
$\mathbb{R}^6$ representation is not unique: any permutation of the six real
coordinates gives an orthogonally equivalent configuration. In particular,
there are $3!\cdot 2^3 = 48$ permutations that merely reshuffle the three
complex entries and, for each entry, possibly swap its real and imaginary
part. For example, the vector $(1,1,1,\,0,0,0)$ is permutationally
equivalent to $(1,0,1,0,1,0)$ via the permutation $(2\,4\,5\,3)$ on
$\{1,\dots,6\}$; that is,
\[
(x_1,x_2,x_3,x_4,x_5,x_6)\mapsto(x_1,x_4,x_2,x_5,x_3,x_6).
\]
More generally, composing our phase-adjusted realification with any real
orthogonal transformation of $\mathbb{R}^6$ yields another faithful orthogonal
representation of the same 165-ray configuration: all such choices are
isomorphic from the point of view of the orthogonality hypergraph and of
KS-colourability. In the table below we fix a particularly simple
``canonical gauge'', namely the ordering
$(\Re z_1,\Re z_2,\Re z_3,\Im z_1,\Im z_2,\Im z_3)$, but none of our
conclusions depend on this specific coordinate choice.

\subsection{Explicit realification}
\label{sec:explicit_realification}


For concreteness, in Table~\ref{tab:all-vectors} we provide the explicit coordinates for all 165 rays in the configuration. The orthogonality graph of these rays---which visualises the logical structure of the proof---is depicted in Fig.~2 of Ref.~\cite{harding2025remarksIJTP}, as well as in Fig.~1 of Ref.~\cite{Cabello2025} and Fig.~1 of Ref.~\cite{svozil-2025-MYOCHS}. In our tabulation, each row contains a label, the corresponding ray in $\mathbb{C}^3$, and its image in $\mathbb{R}^6$ under the canonical realification map~\eqref{eq:phi0} (i.e., with phases $\theta_k=0$). For a vector $(z_1,z_2,z_3)\in\mathbb{C}^3$ we write its real image as
\begin{equation}
  (\Re z_1,\Re z_2,\Re z_3,\Im z_1,\Im z_2,\Im z_3)\in\mathbb{R}^6.
\end{equation}

\begingroup
\renewcommand{\arraystretch}{1.5} % Increases vertical spacing for fractions
\begin{longtable}{lll}
\caption{All 165 rays in $\mathbb{C}^3$ and their images in $\mathbb{R}^6$
under the canonical realification~\eqref{eq:phi0} (i.e. with all phase adjustments $\theta_k=0 $ as defined in~\eqref{2025-rvc-padef}).
This brings about spurious orthogonalities in $\mathbb{R}^6$, such as between $u_{1}$ and $u_{4}$ that are not present in $\mathbb{C}^3$. A strictly faithful embedding with no spurious orthogonalities requires the additional phase adjustments described in~\eqref{2025-rvc-pa}.}
\label{tab:all-vectors}\\
\hline\hline
Label & $\mathbb{C}^3$ vector & $\mathbb{R}^6$ vector \\
\hline
\endfirsthead
\hline\hline
Label & $\mathbb{C}^3$ vector & $\mathbb{R}^6$ vector \\
\hline
\endhead
\hline\hline
\endfoot
$a_{11}$ & $(1,0,0)$ &
$\bigl(1,0,0,\,0,0,0\bigr)$ \\
$a_{21}$ & $(0,1,0)$ &
$\bigl(0,1,0,\,0,0,0\bigr)$ \\
$a_{31}$ & $(0,0,1)$ &
$\bigl(0,0,1,\,0,0,0\bigr)$ \\
$u_{1}$ & $(1,1,1)$ &
$\bigl(1,1,1,\,0,0,0\bigr)$ \\
$u_{2}$ & $(1,\omega,\omega^2)$ &
$\Bigl(1,-\tfrac12,-\tfrac12,\,0,\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$u_{3}$ & $(1,\omega^2,\omega)$ &
$\Bigl(1,-\tfrac12,-\tfrac12,\,0,-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$u_{4}$ & $(1,\omega,\omega)$ &
$\Bigl(1,-\tfrac12,-\tfrac12,\,0,\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$u_{5}$ & $(1,\omega^2,1)$ &
$\Bigl(1,-\tfrac12,1,\,0,-\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$u_{6}$ & $(1,1,\omega^2)$ &
$\Bigl(1,1,-\tfrac12,\,0,0,-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$u_{7}$ & $(1,\omega^2,\omega^2)$ &
$\Bigl(1,-\tfrac12,-\tfrac12,\,0,-\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$u_{8}$ & $(1,\omega,1)$ &
$\Bigl(1,-\tfrac12,1,\,0,\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$u_{9}$ & $(1,1,\omega)$ &
$\Bigl(1,1,-\tfrac12,\,0,0,\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{11}$ & $(0,1,1)$ &
$\bigl(0,1,1,\,0,0,0\bigr)$ \\
$b_{12}$ & $(0,\omega,\omega^2)$ &
$\Bigl(0,-\tfrac12,-\tfrac12,\,0,\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{13}$ & $(0,\omega^2,\omega)$ &
$\Bigl(0,-\tfrac12,-\tfrac12,\,0,-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{21}$ & $(1,0,1)$ &
$\bigl(1,0,1,\,0,0,0\bigr)$ \\
$b_{22}$ & $(1,0,\omega^2)$ &
$\Bigl(1,0,-\tfrac12,\,0,0,-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{23}$ & $(1,0,\omega)$ &
$\Bigl(1,0,-\tfrac12,\,0,0,\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{31}$ & $(1,1,0)$ &
$\bigl(1,1,0,\,0,0,0\bigr)$ \\
$b_{32}$ & $(1,\omega,0)$ &
$\Bigl(1,-\tfrac12,0,\,0,\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$b_{33}$ & $(1,\omega^2,0)$ &
$\Bigl(1,-\tfrac12,0,\,0,-\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$c_{11}$ & $(0,1,-1)$ &
$\bigl(0,1,-1,\,0,0,0\bigr)$ \\
$c_{12}$ & $(0,\omega,-\omega^2)$ &
$\Bigl(0,-\tfrac12,\tfrac12,\,0,\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$c_{13}$ & $(0,\omega^2,-\omega)$ &
$\Bigl(0,-\tfrac12,\tfrac12,\,0,-\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$c_{21}$ & $(-1,0,1)$ &
$\bigl(-1,0,1,\,0,0,0\bigr)$ \\
$c_{22}$ & $(-\omega,0,1)$ &
$\Bigl(\tfrac12,0,1,\,-\tfrac{\sqrt{3}}{2},0,0\Bigr)$ \\
$c_{23}$ & $(-\omega^2,0,1)$ &
$\Bigl(\tfrac12,0,1,\,\tfrac{\sqrt{3}}{2},0,0\Bigr)$ \\
$c_{31}$ & $(1,-1,0)$ &
$\bigl(1,-1,0,\,0,0,0\bigr)$ \\
$c_{32}$ & $(\omega^2,-1,0)$ &
$\Bigl(-\tfrac12,-1,0,\,-\tfrac{\sqrt{3}}{2},0,0\Bigr)$ \\
$c_{33}$ & $(\omega,-1,0)$ &
$\Bigl(-\tfrac12,-1,0,\,\tfrac{\sqrt{3}}{2},0,0\Bigr)$ \\
$d_{11}$ & $(-2,1,1)$ &
$\bigl(-2,1,1,\,0,0,0\bigr)$ \\
$d_{12}$ & $(-2,\omega,\omega^2)$ &
$\Bigl(-2,-\tfrac12,-\tfrac12,\,0,\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$d_{13}$ & $(-2,\omega^2,\omega)$ &
$\Bigl(-2,-\tfrac12,-\tfrac12,\,0,-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$d_{14}$ & $(-2,\omega,\omega)$ &
$\Bigl(-2,-\tfrac12,-\tfrac12,\,0,\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$d_{15}$ & $(-2,\omega^2,1)$ &
$\Bigl(-2,-\tfrac12,1,\,0,-\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$d_{16}$ & $(-2,1,\omega^2)$ &
$\Bigl(-2,1,-\tfrac12,\,0,0,-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$d_{17}$ & $(-2,\omega^2,\omega^2)$ &
$\Bigl(-2,-\tfrac12,-\tfrac12,\,0,-\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$d_{18}$ & $(-2,\omega,1)$ &
$\Bigl(-2,-\tfrac12,1,\,0,\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$d_{19}$ & $(-2,1,\omega)$ &
$\Bigl(-2,1,-\tfrac12,\,0,0,\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$d_{21}$ & $(1,-2,1)$ &
$\bigl(1,-2,1,\,0,0,0\bigr)$ \\
$d_{22}$ & $(\omega^2,-2,\omega)$ &
$\Bigl(-\tfrac12,-2,-\tfrac12,\,-\tfrac{\sqrt{3}}{2},0,\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$d_{23}$ & $(\omega,-2,\omega^2)$ &
$\Bigl(-\tfrac12,-2,-\tfrac12,\,\tfrac{\sqrt{3}}{2},0,-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$d_{24}$ & $(\omega^2,-2,1)$ &
$\Bigl(-\tfrac12,-2,1,\,-\tfrac{\sqrt{3}}{2},0,0\Bigr)$ \\
$d_{25}$ & $(\omega,-2,\omega)$ &
$\Bigl(-\tfrac12,-2,-\tfrac12,\,\tfrac{\sqrt{3}}{2},0,\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$d_{26}$ & $(1,-2,\omega^2)$ &
$\Bigl(1,-2,-\tfrac12,\,0,0,-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$d_{27}$ & $(\omega,-2,1)$ &
$\Bigl(-\tfrac12,-2,1,\,\tfrac{\sqrt{3}}{2},0,0\Bigr)$ \\
$d_{28}$ & $(\omega^2,-2,\omega^2)$ &
$\Bigl(-\tfrac12,-2,-\tfrac12,\,-\tfrac{\sqrt{3}}{2},0,-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$d_{29}$ & $(1,-2,\omega)$ &
$\Bigl(1,-2,-\tfrac12,\,0,0,\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$d_{31}$ & $(1,1,-2)$ &
$\bigl(1,1,-2,\,0,0,0\bigr)$ \\
$d_{32}$ & $(\omega,\omega^2,-2)$ &
$\Bigl(-\tfrac12,-\tfrac12,-2,\,\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$d_{33}$ & $(\omega^2,\omega,-2)$ &
$\Bigl(-\tfrac12,-\tfrac12,-2,\,-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$d_{34}$ & $(\omega^2,1,-2)$ &
$\Bigl(-\tfrac12,1,-2,\,-\tfrac{\sqrt{3}}{2},0,0\Bigr)$ \\
$d_{35}$ & $(1,\omega^2,-2)$ &
$\Bigl(1,-\tfrac12,-2,\,0,-\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$d_{36}$ & $(\omega,\omega,-2)$ &
$\Bigl(-\tfrac12,-\tfrac12,-2,\,\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$d_{37}$ & $(\omega,1,-2)$ &
$\Bigl(-\tfrac12,1,-2,\,\tfrac{\sqrt{3}}{2},0,0\Bigr)$ \\
$d_{38}$ & $(1,\omega,-2)$ &
$\Bigl(1,-\tfrac12,-2,\,0,\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$d_{39}$ & $(\omega^2,\omega^2,-2)$ &
$\Bigl(-\tfrac12,-\tfrac12,-2,\,-\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$b_{121}$ & $(1,1,-1)$ &
$\bigl(1,1,-1,\,0,0,0\bigr)$ \\
$b_{122}$ & $(1,\omega,-\omega^2)$ &
$\Bigl(1,-\tfrac12,\tfrac12,\,0,\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{123}$ & $(1,\omega^2,-\omega)$ &
$\Bigl(1,-\tfrac12,\tfrac12,\,0,-\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{124}$ & $(\omega,\omega^2,-\omega^2)$ &
$\Bigl(-\tfrac12,-\tfrac12,\tfrac12,\,\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{125}$ & $(\omega,1,-\omega)$ &
$\Bigl(-\tfrac12,1,\tfrac12,\,\tfrac{\sqrt{3}}{2},0,-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{126}$ & $(\omega,\omega,-1)$ &
$\Bigl(-\tfrac12,-\tfrac12,-1,\,\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$b_{127}$ & $(\omega^2,\omega,-\omega)$ &
$\Bigl(-\tfrac12,-\tfrac12,\tfrac12,\,-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{128}$ & $(\omega^2,1,-\omega^2)$ &
$\Bigl(-\tfrac12,1,\tfrac12,\,-\tfrac{\sqrt{3}}{2},0,\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{129}$ & $(\omega^2,\omega^2,-1)$ &
$\Bigl(-\tfrac12,-\tfrac12,-1,\,-\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$b_{131}$ & $(1,-1,1)$ &
$\bigl(1,-1,1,\,0,0,0\bigr)$ \\
$b_{132}$ & $(1,-\omega,\omega^2)$ &
$\Bigl(1,\tfrac12,-\tfrac12,\,0,-\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{133}$ & $(1,-\omega^2,\omega)$ &
$\Bigl(1,\tfrac12,-\tfrac12,\,0,\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{134}$ & $(\omega,-\omega^2,\omega^2)$ &
$\Bigl(-\tfrac12,\tfrac12,-\tfrac12,\,\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{135}$ & $(\omega,-1,\omega)$ &
$\Bigl(-\tfrac12,-1,-\tfrac12,\,\tfrac{\sqrt{3}}{2},0,\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{136}$ & $(\omega,-\omega,1)$ &
$\Bigl(-\tfrac12,\tfrac12,1,\,\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$b_{137}$ & $(\omega^2,-\omega,\omega)$ &
$\Bigl(-\tfrac12,\tfrac12,-\tfrac12,\,-\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{138}$ & $(\omega^2,-1,\omega^2)$ &
$\Bigl(-\tfrac12,-1,-\tfrac12,\,-\tfrac{\sqrt{3}}{2},0,-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{139}$ & $(\omega^2,-\omega^2,1)$ &
$\Bigl(-\tfrac12,\tfrac12,1,\,-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$b_{231}$ & $(-1,1,1)$ &
$\bigl(-1,1,1,\,0,0,0\bigr)$ \\
$b_{232}$ & $(-1,\omega,\omega^2)$ &
$\Bigl(-1,-\tfrac12,-\tfrac12,\,0,\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{233}$ & $(-1,\omega^2,\omega)$ &
$\Bigl(-1,-\tfrac12,-\tfrac12,\,0,-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{234}$ & $(-\omega,\omega^2,\omega^2)$ &
$\Bigl(\tfrac12,-\tfrac12,-\tfrac12,\,-\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{235}$ & $(-\omega,1,\omega)$ &
$\Bigl(\tfrac12,1,-\tfrac12,\,-\tfrac{\sqrt{3}}{2},0,\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{236}$ & $(-\omega,\omega,1)$ &
$\Bigl(\tfrac12,-\tfrac12,1,\,-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$b_{237}$ & $(-\omega^2,\omega,\omega)$ &
$\Bigl(\tfrac12,-\tfrac12,-\tfrac12,\,\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{238}$ & $(-\omega^2,1,\omega^2)$ &
$\Bigl(\tfrac12,1,-\tfrac12,\,\tfrac{\sqrt{3}}{2},0,-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{239}$ & $(-\omega^2,\omega^2,1)$ &
$\Bigl(\tfrac12,-\tfrac12,1,\,\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$e_{11}$ & $(1,2,1)$ &
$\bigl(1,2,1,\,0,0,0\bigr)$ \\
$e_{12}$ & $(\omega^2,2,\omega)$ &
$\Bigl(-\tfrac12,2,-\tfrac12,\,-\tfrac{\sqrt{3}}{2},0,\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$e_{13}$ & $(\omega,2,\omega^2)$ &
$\Bigl(-\tfrac12,2,-\tfrac12,\,\tfrac{\sqrt{3}}{2},0,-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$e_{14}$ & $(\omega,2\omega^2,\omega^2)$ &
$\Bigl(-\tfrac12,-1,-\tfrac12,\,\tfrac{\sqrt{3}}{2},-\sqrt{3},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$e_{15}$ & $(1,2\omega^2,1)$ &
$\bigl(1,-1,1,\,0,-\sqrt{3},0\bigr)$ \\
$e_{16}$ & $(\omega^2,2\omega^2,\omega)$ &
$\Bigl(-\tfrac12,-1,-\tfrac12,\,-\tfrac{\sqrt{3}}{2},-\sqrt{3},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$e_{17}$ & $(\omega^2,2\omega,\omega)$ &
$\Bigl(-\tfrac12,-1,-\tfrac12,\,-\tfrac{\sqrt{3}}{2},\sqrt{3},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$e_{18}$ & $(1,2\omega,1)$ &
$\bigl(1,-1,1,\,0,\sqrt{3},0\bigr)$ \\
$e_{19}$ & $(\omega,2\omega,\omega^2)$ &
$\Bigl(-\tfrac12,-1,-\tfrac12,\,\tfrac{\sqrt{3}}{2},\sqrt{3},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$e_{21}$ & $(1,1,2)$ &
$\bigl(1,1,2,\,0,0,0\bigr)$ \\
$e_{22}$ & $(\omega,\omega^2,2)$ &
$\Bigl(-\tfrac12,-\tfrac12,2,\,\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$e_{23}$ & $(\omega^2,\omega,2)$ &
$\Bigl(-\tfrac12,-\tfrac12,2,\,-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$e_{24}$ & $(\omega,\omega^2,2\omega^2)$ &
$\Bigl(-\tfrac12,-\tfrac12,-1,\,\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2},-\sqrt{3}\Bigr)$ \\
$e_{25}$ & $(\omega^2,\omega,2\omega^2)$ &
$\Bigl(-\tfrac12,-\tfrac12,-1,\,-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2},-\sqrt{3}\Bigr)$ \\
$e_{26}$ & $(1,1,2\omega^2)$ &
$\bigl(1,1,-1,\,0,0,-\sqrt{3}\bigr)$ \\
$e_{27}$ & $(\omega^2,\omega,2\omega)$ &
$\Bigl(-\tfrac12,-\tfrac12,-1,\,-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2},\sqrt{3}\Bigr)$ \\
$e_{28}$ & $(\omega,\omega^2,2\omega)$ &
$\Bigl(-\tfrac12,-\tfrac12,-1,\,\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2},\sqrt{3}\Bigr)$ \\
$e_{29}$ & $(1,1,2\omega)$ &
$\bigl(1,1,-1,\,0,0,\sqrt{3}\bigr)$ \\
$e_{31}$ & $(2,1,1)$ &
$\bigl(2,1,1,\,0,0,0\bigr)$ \\
$e_{32}$ & $(2,\omega,\omega^2)$ &
$\Bigl(2,-\tfrac12,-\tfrac12,\,0,\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$e_{33}$ & $(2,\omega^2,\omega)$ &
$\Bigl(2,-\tfrac12,-\tfrac12,\,0,-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$e_{34}$ & $(2\omega^2,1,1)$ &
$\bigl(-1,1,1,\,-\sqrt{3},0,0\bigr)$ \\
$e_{35}$ & $(2\omega^2,\omega,\omega^2)$ &
$\Bigl(-1,-\tfrac12,-\tfrac12,\,-\sqrt{3},\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$e_{36}$ & $(2\omega^2,\omega^2,\omega)$ &
$\Bigl(-1,-\tfrac12,-\tfrac12,\,-\sqrt{3},-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$e_{37}$ & $(2\omega,1,1)$ &
$\bigl(-1,1,1,\,\sqrt{3},0,0\bigr)$ \\
$e_{38}$ & $(2\omega,\omega^2,\omega)$ &
$\Bigl(-1,-\tfrac12,-\tfrac12,\,\sqrt{3},-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$e_{39}$ & $(2\omega,\omega,\omega^2)$ &
$\Bigl(-1,-\tfrac12,-\tfrac12,\,\sqrt{3},\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{1121}$ & $(2,-1,1)$ &
$\bigl(2,-1,1,\,0,0,0\bigr)$ \\
$b_{1122}$ & $(2,-\omega,\omega^2)$ &
$\Bigl(2,\tfrac12,-\tfrac12,\,0,-\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{1123}$ & $(2,-\omega^2,\omega)$ &
$\Bigl(2,\tfrac12,-\tfrac12,\,0,\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{1124}$ & $(2,-\omega,\omega)$ &
$\Bigl(2,\tfrac12,-\tfrac12,\,0,-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{1125}$ & $(2,-\omega^2,1)$ &
$\Bigl(2,\tfrac12,1,\,0,\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$b_{1126}$ & $(2,-1,\omega^2)$ &
$\Bigl(2,-1,-\tfrac12,\,0,0,-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{1127}$ & $(2,-\omega^2,\omega^2)$ &
$\Bigl(2,\tfrac12,-\tfrac12,\,0,\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{1128}$ & $(2,-\omega,1)$ &
$\Bigl(2,\tfrac12,1,\,0,-\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$b_{1129}$ & $(2,-1,\omega)$ &
$\Bigl(2,-1,-\tfrac12,\,0,0,\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{2121}$ & $(-1,2,1)$ &
$\bigl(-1,2,1,\,0,0,0\bigr)$ \\
$b_{2122}$ & $(-1,2\omega,\omega^2)$ &
$\Bigl(-1,-1,-\tfrac12,\,0,\sqrt{3},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{2123}$ & $(-1,2\omega^2,\omega)$ &
$\Bigl(-1,-1,-\tfrac12,\,0,-\sqrt{3},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{2124}$ & $(-1,2\omega,\omega)$ &
$\Bigl(-1,-1,-\tfrac12,\,0,\sqrt{3},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{2125}$ & $(-1,2\omega^2,1)$ &
$\bigl(-1,-1,1,\,0,-\sqrt{3},0\bigr)$ \\
$b_{2126}$ & $(-1,2,\omega^2)$ &
$\Bigl(-1,2,-\tfrac12,\,0,0,-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{2127}$ & $(-1,2\omega^2,\omega^2)$ &
$\Bigl(-1,-1,-\tfrac12,\,0,-\sqrt{3},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{2128}$ & $(-1,2\omega,1)$ &
$\bigl(-1,-1,1,\,0,\sqrt{3},0\bigr)$ \\
$b_{2129}$ & $(-1,2,\omega)$ &
$\Bigl(-1,2,-\tfrac12,\,0,0,\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{1131}$ & $(2,1,-1)$ &
$\bigl(2,1,-1,\,0,0,0\bigr)$ \\
$b_{1132}$ & $(2,\omega,-\omega^2)$ &
$\Bigl(2,-\tfrac12,\tfrac12,\,0,\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{1133}$ & $(2,\omega^2,-\omega)$ &
$\Bigl(2,-\tfrac12,\tfrac12,\,0,-\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{1134}$ & $(2,\omega,-\omega)$ &
$\Bigl(2,-\tfrac12,\tfrac12,\,0,\tfrac{\sqrt{3}}{2},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{1135}$ & $(2,\omega^2,-1)$ &
$\Bigl(2,-\tfrac12,-1,\,0,-\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$b_{1136}$ & $(2,1,-\omega^2)$ &
$\Bigl(2,1,\tfrac12,\,0,0,\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{1137}$ & $(2,\omega^2,-\omega^2)$ &
$\Bigl(2,-\tfrac12,\tfrac12,\,0,-\tfrac{\sqrt{3}}{2},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{1138}$ & $(2,\omega,-1)$ &
$\Bigl(2,-\tfrac12,-1,\,0,\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$b_{1139}$ & $(2,1,-\omega)$ &
$\Bigl(2,1,\tfrac12,\,0,0,-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{3131}$ & $(-1,1,2)$ &
$\bigl(-1,1,2,\,0,0,0\bigr)$ \\
$b_{3132}$ & $(-1,\omega,2\omega^2)$ &
$\Bigl(-1,-\tfrac12,-1,\,0,\tfrac{\sqrt{3}}{2},-\sqrt{3}\Bigr)$ \\
$b_{3133}$ & $(-1,\omega^2,2\omega)$ &
$\Bigl(-1,-\tfrac12,-1,\,0,-\tfrac{\sqrt{3}}{2},\sqrt{3}\Bigr)$ \\
$b_{3134}$ & $(-1,\omega,2\omega)$ &
$\Bigl(-1,-\tfrac12,-1,\,0,\tfrac{\sqrt{3}}{2},\sqrt{3}\Bigr)$ \\
$b_{3135}$ & $(-1,\omega^2,2)$ &
$\Bigl(-1,-\tfrac12,2,\,0,-\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$b_{3136}$ & $(-1,1,2\omega^2)$ &
$\bigl(-1,1,-1,\,0,0,-\sqrt{3}\bigr)$ \\
$b_{3137}$ & $(-1,\omega^2,2\omega^2)$ &
$\Bigl(-1,-\tfrac12,-1,\,0,-\tfrac{\sqrt{3}}{2},-\sqrt{3}\Bigr)$ \\
$b_{3138}$ & $(-1,\omega,2)$ &
$\Bigl(-1,-\tfrac12,2,\,0,\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$b_{3139}$ & $(-1,1,2\omega)$ &
$\bigl(-1,1,-1,\,0,0,\sqrt{3}\bigr)$ \\
$b_{2231}$ & $(1,2,-1)$ &
$\bigl(1,2,-1,\,0,0,0\bigr)$ \\
$b_{2232}$ & $(1,2\omega,-\omega^2)$ &
$\Bigl(1,-1,\tfrac12,\,0,\sqrt{3},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{2233}$ & $(1,2\omega^2,-\omega)$ &
$\Bigl(1,-1,\tfrac12,\,0,-\sqrt{3},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{2234}$ & $(1,2\omega,-\omega)$ &
$\Bigl(1,-1,\tfrac12,\,0,\sqrt{3},-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{2235}$ & $(1,2\omega^2,-1)$ &
$\bigl(1,-1,-1,\,0,-\sqrt{3},0\bigr)$ \\
$b_{2236}$ & $(1,2,-\omega^2)$ &
$\Bigl(1,2,\tfrac12,\,0,0,\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{2237}$ & $(1,2\omega^2,-\omega^2)$ &
$\Bigl(1,-1,\tfrac12,\,0,-\sqrt{3},\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{2238}$ & $(1,2\omega,-1)$ &
$\bigl(1,-1,-1,\,0,\sqrt{3},0\bigr)$ \\
$b_{2239}$ & $(1,2,-\omega)$ &
$\Bigl(1,2,\tfrac12,\,0,0,-\tfrac{\sqrt{3}}{2}\Bigr)$ \\
$b_{3231}$ & $(1,-1,2)$ &
$\bigl(1,-1,2,\,0,0,0\bigr)$ \\
$b_{3232}$ & $(1,-\omega,2\omega^2)$ &
$\Bigl(1,\tfrac12,-1,\,0,-\tfrac{\sqrt{3}}{2},-\sqrt{3}\Bigr)$ \\
$b_{3233}$ & $(1,-\omega^2,2\omega)$ &
$\Bigl(1,\tfrac12,-1,\,0,\tfrac{\sqrt{3}}{2},\sqrt{3}\Bigr)$ \\
$b_{3234}$ & $(1,-\omega,2\omega)$ &
$\Bigl(1,\tfrac12,-1,\,0,-\tfrac{\sqrt{3}}{2},\sqrt{3}\Bigr)$ \\
$b_{3235}$ & $(1,-\omega^2,2)$ &
$\Bigl(1,\tfrac12,2,\,0,\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$b_{3236}$ & $(1,-1,2\omega^2)$ &
$\bigl(1,-1,-1,\,0,0,-\sqrt{3}\bigr)$ \\
$b_{3237}$ & $(1,-\omega^2,2\omega^2)$ &
$\Bigl(1,\tfrac12,-1,\,0,\tfrac{\sqrt{3}}{2},-\sqrt{3}\Bigr)$ \\
$b_{3238}$ & $(1,-\omega,2)$ &
$\Bigl(1,\tfrac12,2,\,0,-\tfrac{\sqrt{3}}{2},0\Bigr)$ \\
$b_{3239}$ & $(1,-1,2\omega)$ &
$\bigl(1,-1,-1,\,0,0,\sqrt{3}\bigr)$ \\
\end{longtable}
\endgroup

The 165 rays listed in Table~\ref{tab:all-vectors} are defined only up to
overall complex phases.  In order to compare their realifications in
$\mathbb{R}^6$, it is necessary to make a consistent phase choice.  A
direct symbolic computation shows that one can assign to each ray
$v_k\in\mathbb{C}^3$ a phase
\(
  \theta_k = n_k\pi/K
\)
with integers $n_k$ and some fixed (nonunique) integer $K$
(we may take, for instance, $K=1009$), such that the following two conditions
hold simultaneously:
(i) whenever $\langle v_i,v_j\rangle=0$ in $\mathbb{C}^3$, the corresponding
realified vectors $R_i,R_j\in\mathbb{R}^6$ satisfy $R_i\cdot R_j=0$; and
(ii) whenever $\langle v_i,v_j\rangle\neq0$, the realifications satisfy
$R_i\cdot R_j\neq0$.
In particular, this phase choice introduces no spurious orthogonality
relations in $\mathbb{R}^6$ and preserves all of the orthogonality relations
that define the original KS hypergraph in $\mathbb{C}^3$.
We verified the existence of such phases numerically with a simple
backtracking script and confirmed that $K=1009$ suffices.
The existence of such a rational phase assignment demonstrates that the
entire configuration admits an analytic (real-algebraic) realification
without altering its orthogonality structure.





\section{Breakdown of Admissibility Criteria in \texorpdfstring{$\mathbb{R}^6$}{R6}}

Having established the explicit embedding of the 165-ray configuration into $\mathbb{R}^6$, we now turn to its implications for quantum contextuality. This section serves as a concrete illustration of the general fact that faithful real embeddings do not preserve the KS property when contexts are interpreted as maximal in the larger space. We analyse the admissibility criteria for two-valued states on the embedded set and quantify, via numerical optimization, the extent to which the logical contradiction present in $\mathbb{C}^3$ is relaxed in $\mathbb{R}^6$.

The Kochen-Specker contradiction arises from the impossibility of assigning a two-valued state (also called a valuation) $v(P) \in \{0,1\}$ to every projector $P$ in a set $\mathcal{S}$ such that the assignment satisfies two fundamental admissibility criteria:
\begin{enumerate}
    \item \textbf{Exclusivity:} For any pair of mutually orthogonal projectors $P_i, P_j$, the values must satisfy $v(P_i + P_j) = v(P_i) + v(P_j)$. In particular, if $v(P_i)=1$, then $v(P_j)=0$ for all $P_j \perp P_i$.
    \item \textbf{Completeness:} The assignment must respect the identity observable, $v(\mathbb{I}) = 1$.
\end{enumerate}

In the original complex space $\mathbb{C}^3$, any context $\mathcal{C} = \{ P_1, P_2, P_3 \}$ consisting of rank-1 projectors onto an orthonormal basis satisfies $\sum_{i=1}^3 P_i = \mathbb{I}_{\mathbb{C}^3}$. Combining Exclusivity and Completeness yields the strict sum rule:
\begin{equation}
    \sum_{i=1}^3 v(P_i) = v\left( \sum_{i=1}^3 P_i \right) = v(\mathbb{I}_{\mathbb{C}^3}) = 1.
    \label{eq:complex-sum-rule}
\end{equation}
Thus, within every context in $\mathbb{C}^3$, exactly one projector must be assigned the value $1$.

However, under the faithful embedding into $\mathbb{R}^6$, we denote the
projectors mapped from a single complex context by
$\{\Pi_1,\Pi_2,\Pi_3\}$; more generally, we write $\Pi_{i,j}$ for the
projector onto the $i$-th ray in the $j$-th context. The triple
$\{\Pi_1,\Pi_2,\Pi_3\}$ spans only a three-dimensional subspace.
While they remain mutually orthogonal (satisfying Exclusivity), they do not sum to the identity of the embedding space:
\begin{equation}
    \sum_{i=1}^3 \Pi_i = \Pi_{\text{sub}} \neq \mathbb{I}_{\mathbb{R}^6}.
\end{equation}
Completeness applies only to the full space $\mathbb{R}^6$. To invoke it, one must extend the set $\{ \Pi_1, \Pi_2, \Pi_3 \}$ with orthogonal projectors $\{ \Pi_4, \Pi_5, \Pi_6 \}$ completing the basis, such that $\sum_{k=1}^6 \Pi_k = \mathbb{I}_{\mathbb{R}^6}$. The Completeness criterion then imposes:
\begin{equation}
    \sum_{k=1}^6 v(\Pi_k) = 1.
\end{equation}
Restricted to the original embedded context, the strict equality of Eq.~\eqref{eq:complex-sum-rule} relaxes to an inequality:
\begin{equation}
    0 \leq \sum_{i=1}^3 v(\Pi_i) \leq 1.
    \label{eq:relaxed-sum}
\end{equation}
This relaxation permits the assignment $v(\Pi_1)=v(\Pi_2)=v(\Pi_3)=0$ (provided $v(\Pi_k)=1$ for some $k \in \{4,5,6\}$). Consequently, one can assign the value $0$ to all 165 embedded rays in $\mathbb{R}^6$ simultaneously without violating Exclusivity or Completeness, thereby avoiding the KS contradiction.
In $\mathbb{C}^3$ the same ``all-zero'' assignment on the $165$ rays would yield
$\sum_{i=1}^3 v(\Pi_i)=0$ in \emph{every} context, thereby violating the completeness
requirement $v(\mathbb{I}_{\mathbb{C}^3})=1$.

While Eq.~\eqref{eq:relaxed-sum} allows for the local possibility that a specific embedded context sums to 1 (i.e., retains the ``1'' within the embedded subspace), the KS obstruction in $\mathbb{C}^3$ manifests globally in $\mathbb{R}^6$ as a strict bound on the total valuation. Considering the complete set of $|\mathcal{C}| = 130$ contexts in the configuration, as analysed in detail by Navara and Svozil~\cite{svozil-2025-MYOCHS}, if it were possible to assign values such that every embedded context retained the value 1, the total sum would be exactly 130. However, since this is equivalent to a Kochen-Specker coloring in $\mathbb{C}^3$ (which is impossible), the global sum is strictly bounded:
\begin{equation}
     0 \leq \sum_{j=1}^{130} \sum_{i=1}^3 v(\Pi_{i,j}) < 130.
\end{equation}
The lower bound of $0$ corresponds to the ``all-zeros'' assignment mentioned earlier where the value $1$ is placed in the orthogonal complement for every context. The strict upper bound ($<130$) implies that there is a minimum non-zero deficit.
Numerical optimization over all two-valued assignments compatible with Exclusivity and Completeness confirms that at least two contexts must unavoidably surrender the value $1$ to the extra dimensions of $\mathbb{R}^6$ to resolve the logical contradiction. Thus, the final bound is tightened to:
\begin{equation}
    0 \leq \sum_{j=1}^{130} \sum_{i=1}^3 v(\Pi_{i,j}) \leq 128.
\end{equation}




\section{Discussion}

We have described a simple phase-adjusted realification procedure that embeds any finite set of rays in $\mathbb{C}^3$ into $\mathbb{R}^6$ in a way that preserves and reflects complex orthogonality. The construction is purely algebraic and uses only the phase freedom inherent in projective rays. Applied to the 165-ray configuration built from MUBs, it yields a faithful orthogonal representation in $\mathbb{R}^6$ (after suitable phase choices), and, by trivial extension, in $\mathbb{R}^7$ and above.


Table~\ref{tab:all-vectors} lists all 165 rays explicitly in $\mathbb{C}^3$ together with their canonical realifications in $\mathbb{R}^6$. For applications requiring strict faithfulness (no extra orthogonality among non-orthogonal rays), one additionally picks phases $\theta_k$ as in Sec.~II before applying $\Phi_0$, which simply rotates each pair $(\Re z_j,\Im z_j)$ in its two-dimensional real subspace.

Whereas, in its original complex realisation in $\mathbb{C}^3$, the 165-ray,
130-context configuration is KS uncolourable (there is no
two-valued state assigning $0$ and $1$ such that in each 3-element context
exactly one projector has value $1$~\cite{Cabello2025}), the same set of rays, when embedded
in $\mathbb{R}^6$, does admit classical two-valued states if we keep only
the embedded 165 rays and the original 3-element contexts.

The reason is that, in $\mathbb{R}^6$, each such triple now spans only a
3-dimensional subspace and is no longer a maximal context: it can always be
completed to a full orthonormal basis of $\mathbb{R}^6$ by adding three extra
vectors not belonging to our configuration. A valuation that assigns the
value $0$ to all 165 given rays, and places the value $1$ on one of these
additional basis vectors for each completed context, then satisfies all
Kochen-Specker constraints on the restricted set. Because there is a
continuum of choices for the orthonormal complements (each 3-dimensional
subspace has infinitely many orthonormal bases of its orthogonal complement),
one can arrange the completions so that no consistency problems arise across
different contexts.

This contrast highlights that a faithful orthogonal representation of a KS
hypergraph in a higher-dimensional real space does not automatically preserve
KS uncolourability: classical two-valued interpretations exist for the
embedded configuration in $\mathbb{R}^6$, whereas they are forbidden for its
realisation as maximal contexts in $\mathbb{C}^3$.

There are two conceptual messages that emerge from this analysis.
First, our construction recovers and reformulates, in explicitly MUB-based
terms, the central conclusion of Harding and Salinas Schmeis
\cite{harding2025remarksIJTP}: in three dimensions there exist finite
orthogonality configurations of rank-1 projectors that are representable in
$\mathbb{C}^3$ but admit no faithful orthogonal representation~\cite{lovasz-79} in
$\mathbb{R}^3$. In particular, the triple Yu--Oh construction
\cite{Yu-2012,Cabello2025}, which can be implemented experimentally for a
single qutrit (for instance via generalized multiport interferometers
\cite{rzbb}), realises such a configuration: its hypergraph of orthogonality
relations can be realised by unit vectors in $\mathbb{C}^3$ but not by unit
vectors in $\mathbb{R}^3$.

Second, the same triple Yu--Oh configuration, when completed to a
Kochen-Specker set in $\mathbb{C}^3$, is KS-uncolourable: there is no
two-valued state (global $0$--$1$ assignment) compatible with all its
3-element contexts. Our phase-adjusted embedding shows that this
configuration does admit a faithful orthogonal representation in
$\mathbb{R}^6$ (and trivially in $\mathbb{R}^D$ for all $D\ge 6$). However,
in $\mathbb{R}^6$ each 3-element context spans only a 3-dimensional subspace
and is no longer maximal; it can always be extended to a full orthonormal
basis of $\mathbb{R}^6$ by adding three extra vectors outside the given set.
One can then construct classical two-valued states by assigning the value
$0$ to all 165 embedded rays and the value $1$ to one of the additional
basis vectors in each completed context. Because each 3-dimensional subspace
has a continuum of orthogonal complements, the completions can be chosen
consistently across contexts. Thus, the complex realisation in $\mathbb{C}^3$
is inherently KS-nonclassical, whereas the real realisation in
$\mathbb{R}^6$ admits classical hidden-variable (two-valued state) models once the
contexts are interpreted as maximal in the larger space.

This sharpens and complements earlier tests that distinguish real and
complex quantum theory at the level of measurement statistics
\cite{mckague-2009,renou-2021,wu-2022}: here the separation appears already
at the level of the logical structure, in the existence or absence of
two-valued states on the same finite orthogonality hypergraph when realised
in $\mathbb{C}^3$ versus in $\mathbb{R}^6$.


\begin{acknowledgments}
The authors thank Felix Effenberger for communications related to the subject.

This text was partially created and revised with assistance from one or more of the following large language models:  Gemini (2.5 Pro as well as 3.0 Pro Preview)
as well as gpt-5.1-high. All content, ideas, and prompts were provided by the authors.


AK was supported by JST, CREST Grant Number JPMJCR23P4, Japan.
KS was funded by the Austrian Science Fund (FWF) Grant \href{https://doi.org/10.55776/PIN5424624}{10.55776/PIN5424624}.
The authors acknowledge TU Wien Bibliothek for financial support through its Open Access Funding Programme.

\end{acknowledgments}

\bibliography{svozil}

\end{document}


(*
  Mathematica Program to Verify Orthogonality Relations
  of 165 Real-Valued Vectors in R^6 (Final Corrected Version)
*)

ClearAll["Global`*"];

(*************************************************************************)
(* PART 1: COMPLEX VECTOR DEFINITIONS                                    *)
(*************************************************************************)
(*
  We start by defining the primitive third root of unity and the original
  165 vectors in C^3, as these are the source for the realification.
*)
omega = Exp[2 Pi I / 3];

complexVectors = <|
  "a11" -> {1, 0, 0}, "a21" -> {0, 1, 0}, "a31" -> {0, 0, 1},
  "u1" -> {1, 1, 1}, "u2" -> {1, omega, omega^2}, "u3" -> {1, omega^2, omega},
  "u4" -> {1, omega, omega}, "u5" -> {1, omega^2, 1}, "u6" -> {1, 1, omega^2},
  "u7" -> {1, omega^2, omega^2}, "u8" -> {1, omega, 1}, "u9" -> {1, 1, omega},
  "b11" -> {0, 1, 1}, "b12" -> {0, omega, omega^2}, "b13" -> {0, omega^2, omega},
  "b21" -> {1, 0, 1}, "b22" -> {1, 0, omega^2}, "b23" -> {1, 0, omega},
  "b31" -> {1, 1, 0}, "b32" -> {1, omega, 0}, "b33" -> {1, omega^2, 0},
  "c11" -> {0, 1, -1}, "c12" -> {0, omega, -omega^2}, "c13" -> {0, omega^2, -omega},
  "c21" -> {-1, 0, 1}, "c22" -> {-omega, 0, 1}, "c23" -> {-omega^2, 0, 1},
  "c31" -> {1, -1, 0}, "c32" -> {omega^2, -1, 0}, "c33" -> {omega, -1, 0},
  "d11" -> {-2, 1, 1}, "d12" -> {-2, omega, omega^2}, "d13" -> {-2, omega^2, omega},
  "d14" -> {-2, omega, omega}, "d15" -> {-2, omega^2, 1}, "d16" -> {-2, 1, omega^2},
  "d17" -> {-2, omega^2, omega^2}, "d18" -> {-2, omega, 1}, "d19" -> {-2, 1, omega},
  "d21" -> {1, -2, 1}, "d22" -> {omega^2, -2, omega}, "d23" -> {omega, -2, omega^2},
  "d24" -> {omega^2, -2, 1}, "d25" -> {omega, -2, omega}, "d26" -> {1, -2, omega^2},
  "d27" -> {omega, -2, 1}, "d28" -> {omega^2, -2, omega^2}, "d29" -> {1, -2, omega},
  "d31" -> {1, 1, -2}, "d32" -> {omega, omega^2, -2}, "d33" -> {omega^2, omega, -2},
  "d34" -> {omega^2, 1, -2}, "d35" -> {1, omega^2, -2}, "d36" -> {omega, omega, -2},
  "d37" -> {omega, 1, -2}, "d38" -> {1, omega, -2}, "d39" -> {omega^2, omega^2, -2},
  "b121" -> {1, 1, -1}, "b122" -> {1, omega, -omega^2}, "b123" -> {1, omega^2, -omega},
  "b124" -> {omega, omega^2, -omega^2}, "b125" -> {omega, 1, -omega}, "b126" -> {omega, omega, -1},
  "b127" -> {omega^2, omega, -omega}, "b128" -> {omega^2, 1, -omega^2}, "b129" -> {omega^2, omega^2, -1},
  "b131" -> {1, -1, 1}, "b132" -> {1, -omega, omega^2}, "b133" -> {1, -omega^2, omega},
  "b134" -> {omega, -omega^2, omega^2}, "b135" -> {omega, -1, omega}, "b136" -> {omega, -omega, 1},
  "b137" -> {omega^2, -omega, omega}, "b138" -> {omega^2, -1, omega^2}, "b139" -> {omega^2, -omega^2, 1},
  "b231" -> {-1, 1, 1}, "b232" -> {-1, omega, omega^2}, "b233" -> {-1, omega^2, omega},
  "b234" -> {-omega, omega^2, omega^2}, "b235" -> {-omega, 1, omega}, "b236" -> {-omega, omega, 1},
  "b237" -> {-omega^2, omega, omega}, "b238" -> {-omega^2, 1, omega^2}, "b239" -> {-omega^2, omega^2, 1},
  "e11" -> {1, 2, 1}, "e12" -> {omega^2, 2, omega}, "e13" -> {omega, 2, omega^2},
  "e14" -> {omega, 2 omega^2, omega^2}, "e15" -> {1, 2 omega^2, 1}, "e16" -> {omega^2, 2 omega^2, omega},
  "e17" -> {omega^2, 2 omega, omega}, "e18" -> {1, 2 omega, 1}, "e19" -> {omega, 2 omega, omega^2},
  "e21" -> {1, 1, 2}, "e22" -> {omega, omega^2, 2}, "e23" -> {omega^2, omega, 2},
  "e24" -> {omega, omega^2, 2 omega^2}, "e25" -> {omega^2, omega, 2 omega^2}, "e26" -> {1, 1, 2 omega^2},
  "e27" -> {omega^2, omega, 2 omega}, "e28" -> {omega, omega^2, 2 omega}, "e29" -> {1, 1, 2 omega},
  "e31" -> {2, 1, 1}, "e32" -> {2, omega, omega^2}, "e33" -> {2, omega^2, omega},
  "e34" -> {2 omega^2, 1, 1}, "e35" -> {2 omega^2, omega, omega^2}, "e36" -> {2 omega^2, omega^2, omega},
  "e37" -> {2 omega, 1, 1}, "e38" -> {2 omega, omega^2, omega}, "e39" -> {2 omega, omega, omega^2},
  "b1121" -> {2, -1, 1}, "b1122" -> {2, -omega, omega^2}, "b1123" -> {2, -omega^2, omega},
  "b1124" -> {2, -omega, omega}, "b1125" -> {2, -omega^2, 1}, "b1126" -> {2, -1, omega^2},
  "b1127" -> {2, -omega^2, omega^2}, "b1128" -> {2, -omega, 1}, "b1129" -> {2, -1, omega},
  "b2121" -> {-1, 2, 1}, "b2122" -> {-1, 2 omega, omega^2}, "b2123" -> {-1, 2 omega^2, omega},
  "b2124" -> {-1, 2 omega, omega}, "b2125" -> {-1, 2 omega^2, 1}, "b2126" -> {-1, 2, omega^2},
  "b2127" -> {-1, 2 omega^2, omega^2}, "b2128" -> {-1, 2 omega, 1}, "b2129" -> {-1, 2, omega},
  "b1131" -> {2, 1, -1}, "b1132" -> {2, omega, -omega^2}, "b1133" -> {2, omega^2, -omega},
  "b1134" -> {2, omega, -omega}, "b1135" -> {2, omega^2, -1}, "b1136" -> {2, 1, -omega^2},
  "b1137" -> {2, omega^2, -omega^2}, "b1138" -> {2, omega, -1}, "b1139" -> {2, 1, -omega},
  "b3131" -> {-1, 1, 2}, "b3132" -> {-1, omega, 2 omega^2}, "b3133" -> {-1, omega^2, 2 omega},
  "b3134" -> {-1, omega, 2 omega}, "b3135" -> {-1, omega^2, 2}, "b3136" -> {-1, 1, 2 omega^2},
  "b3137" -> {-1, omega^2, 2 omega^2}, "b3138" -> {-1, omega, 2}, "b3139" -> {-1, 1, 2 omega},
  "b2231" -> {1, 2, -1}, "b2232" -> {1, 2 omega, -omega^2}, "b2233" -> {1, 2 omega^2, -omega},
  "b2234" -> {1, 2 omega, -omega}, "b2235" -> {1, 2 omega^2, -1}, "b2236" -> {1, 2, -omega^2},
  "b2237" -> {1, 2 omega^2, -omega^2}, "b2238" -> {1, 2 omega, -1}, "b2239" -> {1, 2, -omega},
  "b3231" -> {1, -1, 2}, "b3232" -> {1, -omega, 2 omega^2}, "b3233" -> {1, -omega^2, 2 omega},
  "b3234" -> {1, -omega, 2 omega}, "b3235" -> {1, -omega^2, 2}, "b3236" -> {1, -1, 2 omega^2},
  "b3237" -> {1, -omega^2, 2 omega^2}, "b3238" -> {1, -omega, 2}, "b3239" -> {1, -1, 2 omega}
|>;

(*************************************************************************)
(* PART 2: REALIFICATION MAP AND REAL VECTOR GENERATION                  *)
(*************************************************************************)
(*
  Define the canonical realification map from C^3 to R^6.
*)
realify[v_] := {
   Re[v[[1]]], Re[v[[2]]], Re[v[[3]]],
   Im[v[[1]]], Im[v[[2]]], Im[v[[3]]]
   };

(*
  Apply the realification map to every complex vector to create
  a new Association of 165 real vectors in R^6. We use Map
  to correctly apply the function to the values of the association.
*)
realVectors = Map[FullSimplify@*realify, complexVectors];


(*************************************************************************)
(* PART 3: CONTEXT DEFINITIONS (Corrected)                               *)
(*************************************************************************)
(*
  This is the corrected list of 130 contexts based on your feedback,
  matching the original paper's Table III.
*)
contexts = {
  {"a11", "a21", "a31"}, {"a11", "b11", "c11"}, {"a11", "b12", "c12"},
  {"a11", "b13", "c13"}, {"a21", "b21", "c21"}, {"a21", "b22", "c22"},
  {"a21", "b23", "c23"}, {"a31", "b31", "c31"}, {"a31", "b32", "c32"},
  {"a31", "b33", "c33"}, {"u1", "u2", "u3"}, {"u1", "c11", "d11"},
  {"u1", "c21", "d21"}, {"u1", "c31", "d31"}, {"u2", "c12", "d12"},
  {"u2", "c22", "d22"}, {"u2", "c32", "d32"}, {"u3", "c13", "d13"},
  {"u3", "c23", "d23"}, {"u3", "c33", "d33"}, {"u4", "u5", "u6"},
  {"u4", "c11", "d14"}, {"u4", "c23", "d24"}, {"u4", "c32", "d34"},
  {"u5", "c12", "d15"}, {"u5", "c21", "d25"}, {"u5", "c33", "d35"},
  {"u6", "c13", "d16"}, {"u6", "c22", "d26"}, {"u6", "c31", "d36"},
  {"u7", "u8", "u9"}, {"u7", "c11", "d17"}, {"u7", "c22", "d27"},
  {"u7", "c33", "d37"}, {"u8", "c13", "d18"}, {"u8", "c21", "d28"},
  {"u8", "c32", "d38"}, {"u9", "c12", "d19"}, {"u9", "c23", "d29"},
  {"u9", "c31", "d39"}, {"b11", "b121", "b1121"}, {"b11", "b124", "b1124"},
  {"b11", "b127", "b1127"}, {"b11", "b131", "b1131"}, {"b11", "b134", "b1134"},
  {"b11", "b137", "b1137"}, {"b12", "b122", "b1122"}, {"b12", "b125", "b1125"},
  {"b12", "b129", "b1129"}, {"b12", "b132", "b1132"}, {"b12", "b135", "b1135"},
  {"b13", "b138", "b1138"}, (* Corrected from b12 *)
  {"b13", "b123", "b1123"}, {"b13", "b126", "b1126"},
  {"b13", "b128", "b1128"}, {"b13", "b133", "b1133"}, {"b13", "b136", "b1136"},
  {"b12", "b139", "b1139"}, (* Corrected from b13 *)
  {"b21", "b121", "b2121"}, {"b21", "b125", "b2125"},
  {"b21", "b128", "b2128"}, {"b21", "b231", "b2231"}, {"b21", "b235", "b2235"},
  {"b21", "b238", "b2238"}, {"b22", "b122", "b2122"}, {"b22", "b126", "b2126"},
  {"b22", "b127", "b2127"}, {"b22", "b232", "b2232"}, {"b22", "b236", "b2236"},
  {"b22", "b237", "b2237"}, {"b23", "b123", "b2123"}, {"b23", "b124", "b2124"},
  {"b23", "b129", "b2129"}, {"b23", "b233", "b2233"}, {"b23", "b234", "b2234"},
  {"b23", "b239", "b2239"}, {"b31", "b131", "b3131"},
  {"b31", "b136", "b3136"}, (* Was b31,b135,b3135 *)
  {"b31", "b139", "b3139"}, {"b31", "b231", "b3231"}, {"b31", "b236", "b3236"},
  {"b31", "b239", "b3239"}, {"b32", "b132", "b3132"}, {"b32", "b134", "b3134"},
  {"b32", "b138", "b3138"}, {"b32", "b232", "b3232"}, {"b32", "b234", "b3234"},
  {"b32", "b238", "b3238"}, {"b33", "b133", "b3133"},
  {"b33", "b135", "b3135"}, (* Corrected from b31 *)
  {"b33", "b137", "b3137"}, {"b33", "b233", "b3233"}, {"b33", "b235", "b3235"},
  {"b33", "b237", "b3237"}, {"c11", "b231", "e31"}, {"c11", "b234", "e34"},
  {"c11", "b237", "e37"}, {"c12", "b232", "e32"}, {"c12", "b235", "e35"},
  {"c12", "b239", "e39"}, {"c13", "b233", "e33"}, {"c13", "b236", "e36"},
  {"c13", "b238", "e38"}, {"c21", "b131", "e11"}, {"c21", "b135", "e15"},
  {"c21", "b138", "e18"}, {"c22", "b132", "e12"}, {"c22", "b136", "e16"},
  {"c22", "b137", "e17"}, {"c23", "b133", "e13"}, {"c23", "b134", "e14"},
  {"c23", "b139", "e19"}, {"c31", "b121", "e21"}, {"c31", "b126", "e26"},
  {"c31", "b129", "e29"}, {"c32", "b122", "e22"}, {"c32", "b124", "e24"},
  {"c32", "b128", "e28"}, {"c33", "b123", "e23"}, {"c33", "b125", "e25"},
  {"c33", "b127", "e27"}, {"b121", "b122", "b123"}, {"b124", "b125", "b126"},
  {"b127", "b128", "b129"}, {"b131", "b132", "b133"}, {"b134", "b135", "b136"},
  {"b137", "b138", "b139"}, {"b231", "b232", "b233"}, {"b234", "b235", "b236"},
  {"b237", "b238", "b239"}
};

(*************************************************************************)
(* PART 4: VERIFICATION LOGIC for R^6                                    *)
(*************************************************************************)

Print["Starting verification for ", Length[contexts], " contexts in R^6..."];
Print["Using the standard real vector dot product: v1.v2"];
Print["---------------------------------------------------------------------"];

failures = {};

Do[
  Module[{labels, v1, v2, v3, pairs, checkResults},

    labels = contexts[[i]];

    (* Look up the REAL vectors from the 'realVectors' association *)
    {v1, v2, v3} = Lookup[realVectors, labels];

    pairs = {{v1, v2}, {v1, v3}, {v2, v3}};

    (*
      Calculate the standard dot product for each pair of REAL vectors.
    *)
    checkResults = Simplify[Dot[#1, #2]] & @@@ pairs;

    If[Not@SameQ[checkResults, {0, 0, 0}],
      Print[Style["FAILED: Context #" <> ToString[i] <> " " <> ToString[labels], Red]];
      Print["  -> v1.v2 = ", checkResults[[1]]];
      Print["  -> v1.v3 = ", checkResults[[2]]];
      Print["  -> v2.v3 = ", checkResults[[3]]];
      AppendTo[failures, labels];
    ];
  ],
  {i, 1, Length[contexts]}
];

Print["---------------------------------------------------------------------"];
Print["Verification Complete."];

If[Length[failures] == 0,
  Print[Style[
    "SUCCESS: All " <> ToString[Length[contexts]] <>
      " realified contexts are fully orthogonal in R^6.", Green, Bold]];
  ,
  Print[Style[
    "FAILURE: Found " <> ToString[Length[failures]] <>
      " realified contexts that are not fully orthogonal in R^6.", Red, Bold]];
  Print["Failing contexts: ", failures];
];


###############################################################################################


(* CHECK FOR COLLINEARITY *)

(* Define the list of 165 vectors *)
vectors = {
  {1, 0, 0, 0, 0, 0}, {0, 1, 0, 0, 0, 0}, {0, 0, 1, 0, 0, 0},
  {1, 1, 1, 0, 0, 0}, {1, -1/2, -1/2, 0, Sqrt[3]/2, -Sqrt[3]/2},
  {1, -1/2, -1/2, 0, -Sqrt[3]/2, Sqrt[3]/2}, {1, -1/2, -1/2, 0,
  Sqrt[3]/2, Sqrt[3]/2}, {1, -1/2, 1, 0, -Sqrt[3]/2, 0}, {1,
  1, -1/2, 0, 0, -Sqrt[3]/2}, {1, -1/2, -1/2, 0, -Sqrt[3]/2, -Sqrt[
   3]/2}, {1, -1/2, 1, 0, Sqrt[3]/2, 0}, {1, 1, -1/2, 0, 0, Sqrt[3]/
  2}, {0, 1, 1, 0, 0, 0}, {0, -1/2, -1/2, 0, Sqrt[3]/2, -Sqrt[3]/
  2}, {0, -1/2, -1/2, 0, -Sqrt[3]/2, Sqrt[3]/2}, {1, 0, 1, 0, 0,
  0}, {1, 0, -1/2, 0, 0, -Sqrt[3]/2}, {1, 0, -1/2, 0, 0, Sqrt[3]/
  2}, {1, 1, 0, 0, 0, 0}, {1, -1/2, 0, 0, Sqrt[3]/2, 0}, {1, -1/2,
  0, 0, -Sqrt[3]/2, 0}, {0, 1, -1, 0, 0, 0}, {0, -1/2, 1/2, 0,
  Sqrt[3]/2, Sqrt[3]/2}, {0, -1/2, 1/2, 0, -Sqrt[3]/2, -Sqrt[3]/
  2}, {-1, 0, 1, 0, 0, 0}, {1/2, 0, 1, -Sqrt[3]/2, 0, 0}, {1/2, 0,
  1, Sqrt[3]/2, 0, 0}, {1, -1, 0, 0, 0, 0}, {-1/2, -1,
  0, -Sqrt[3]/2, 0, 0}, {-1/2, -1, 0, Sqrt[3]/2, 0, 0}, {-2, 1, 1,
  0, 0, 0}, {-2, -1/2, -1/2, 0, Sqrt[3]/2, -Sqrt[3]/2}, {-2, -1/2, -1/
  2, 0, -Sqrt[3]/2, Sqrt[3]/2}, {-2, -1/2, -1/2, 0, Sqrt[3]/2, Sqrt[
   3]/2}, {-2, -1/2, 1, 0, -Sqrt[3]/2, 0}, {-2, 1, -1/2, 0,
  0, -Sqrt[3]/2}, {-2, -1/2, -1/2, 0, -Sqrt[3]/2, -Sqrt[3]/
  2}, {-2, -1/2, 1, 0, Sqrt[3]/2, 0}, {-2, 1, -1/2, 0, 0, Sqrt[3]/
  2}, {1, -2, 1, 0, 0, 0}, {-1/2, -2, -1/2, -Sqrt[3]/2, 0, Sqrt[3]/
  2}, {-1/2, -2, -1/2, Sqrt[3]/2, 0, -Sqrt[3]/2}, {-1/2, -2,
  1, -Sqrt[3]/2, 0, 0}, {-1/2, -2, -1/2, Sqrt[3]/2, 0, Sqrt[3]/
  2}, {1, -2, -1/2, 0, 0, -Sqrt[3]/2}, {-1/2, -2, 1, Sqrt[3]/2, 0,
  0}, {-1/2, -2, -1/2, -Sqrt[3]/2, 0, -Sqrt[3]/2}, {1, -2, -1/2, 0,
  0, Sqrt[3]/2}, {1, 1, -2, 0, 0, 0}, {-1/2, -1/2, -2, Sqrt[3]/
  2, -Sqrt[3]/2, 0}, {-1/2, -1/2, -2, -Sqrt[3]/2, Sqrt[3]/2,
  0}, {-1/2, 1, -2, -Sqrt[3]/2, 0, 0}, {1, -1/2, -2, 0, -Sqrt[3]/2,
  0}, {-1/2, -1/2, -2, Sqrt[3]/2, Sqrt[3]/2, 0}, {-1/2, 1, -2, Sqrt[
   3]/2, 0, 0}, {1, -1/2, -2, 0, Sqrt[3]/2, 0}, {-1/2, -1/2, -2, -Sqrt[
   3]/2, -Sqrt[3]/2, 0}, {1, 1, -1, 0, 0, 0}, {1, -1/2, 1/2, 0,
  Sqrt[3]/2, Sqrt[3]/2}, {1, -1/2, 1/2, 0, -Sqrt[3]/2, -Sqrt[3]/
  2}, {-1/2, -1/2, 1/2, Sqrt[3]/2, -Sqrt[3]/2, Sqrt[3]/
  2}, {-1/2, 1, 1/2, Sqrt[3]/2, 0, -Sqrt[3]/2}, {-1/2, -1/2, -1, Sqrt[
   3]/2, Sqrt[3]/2, 0}, {-1/2, -1/2, 1/2, -Sqrt[3]/2, Sqrt[3]/
  2, -Sqrt[3]/2}, {-1/2, 1, 1/2, -Sqrt[3]/2, 0, Sqrt[3]/2}, {-1/2, -1/
  2, -1, -Sqrt[3]/2, -Sqrt[3]/2, 0}, {1, -1, 1, 0, 0, 0}, {1, 1/2, -1/
  2, 0, -Sqrt[3]/2, -Sqrt[3]/2}, {1, 1/2, -1/2, 0, Sqrt[3]/2, Sqrt[
   3]/2}, {-1/2, 1/2, -1/2, Sqrt[3]/2, Sqrt[3]/2, -Sqrt[3]/
  2}, {-1/2, -1, -1/2, Sqrt[3]/2, 0, Sqrt[3]/2}, {-1/2, 1/2, 1, Sqrt[
   3]/2, -Sqrt[3]/2, 0}, {-1/2, 1/2, -1/2, -Sqrt[3]/2, -Sqrt[3]/
  2, Sqrt[3]/2}, {-1/2, -1, -1/2, -Sqrt[3]/2, 0, -Sqrt[3]/
  2}, {-1/2, 1/2, 1, -Sqrt[3]/2, Sqrt[3]/2, 0}, {-1, 1, 1, 0, 0,
  0}, {-1, -1/2, -1/2, 0, Sqrt[3]/2, -Sqrt[3]/2}, {-1, -1/2, -1/2,
  0, -Sqrt[3]/2, Sqrt[3]/2}, {1/2, -1/2, -1/2, -Sqrt[3]/
  2, -Sqrt[3]/2, -Sqrt[3]/2}, {1/2, 1, -1/2, -Sqrt[3]/2, 0, Sqrt[3]/
  2}, {1/2, -1/2, 1, -Sqrt[3]/2, Sqrt[3]/2, 0}, {1/2, -1/2, -1/2, Sqrt[
   3]/2, Sqrt[3]/2, Sqrt[3]/2}, {1/2, 1, -1/2, Sqrt[3]/2,
  0, -Sqrt[3]/2}, {1/2, -1/2, 1, Sqrt[3]/2, -Sqrt[3]/2, 0}, {1, 2,
  1, 0, 0, 0}, {-1/2, 2, -1/2, -Sqrt[3]/2, 0, Sqrt[3]/2}, {-1/2,
  2, -1/2, Sqrt[3]/2, 0, -Sqrt[3]/2}, {-1/2, -1, -1/2, Sqrt[3]/
  2, -Sqrt[3], -Sqrt[3]/2}, {1, -1, 1, 0, -Sqrt[3], 0}, {-1/2, -1, -1/
  2, -Sqrt[3]/2, -Sqrt[3], Sqrt[3]/2}, {-1/2, -1, -1/2, -Sqrt[3]/
  2, Sqrt[3], Sqrt[3]/2}, {1, -1, 1, 0, Sqrt[3], 0}, {-1/2, -1, -1/
  2, Sqrt[3]/2, Sqrt[3], -Sqrt[3]/2}, {1, 1, 2, 0, 0, 0}, {-1/2, -1/
  2, 2, Sqrt[3]/2, -Sqrt[3]/2, 0}, {-1/2, -1/2, 2, -Sqrt[3]/2, Sqrt[
   3]/2, 0}, {-1/2, -1/2, -1, Sqrt[3]/2, -Sqrt[3]/2, -Sqrt[
   3]}, {-1/2, -1/2, -1, -Sqrt[3]/2, Sqrt[3]/2, -Sqrt[3]}, {1,
  1, -1, 0, 0, -Sqrt[3]}, {-1/2, -1/2, -1, -Sqrt[3]/2, Sqrt[3]/
  2, Sqrt[3]}, {-1/2, -1/2, -1, Sqrt[3]/2, -Sqrt[3]/2, Sqrt[3]}, {1,
  1, -1, 0, 0, Sqrt[3]}, {2, 1, 1, 0, 0, 0}, {2, -1/2, -1/2, 0, Sqrt[
   3]/2, -Sqrt[3]/2}, {2, -1/2, -1/2, 0, -Sqrt[3]/2, Sqrt[3]/
  2}, {-1, 1, 1, -Sqrt[3], 0, 0}, {-1, -1/2, -1/2, -Sqrt[
   3], Sqrt[3]/2, -Sqrt[3]/2}, {-1, -1/2, -1/2, -Sqrt[3], -Sqrt[3]/
  2, Sqrt[3]/2}, {-1, 1, 1, Sqrt[3], 0, 0}, {-1, -1/2, -1/2, Sqrt[
   3], -Sqrt[3]/2, Sqrt[3]/2}, {-1, -1/2, -1/2, Sqrt[3], Sqrt[3]/
  2, -Sqrt[3]/2}, {2, -1, 1, 0, 0, 0}, {2, 1/2, -1/2, 0, -Sqrt[3]/
  2, -Sqrt[3]/2}, {2, 1/2, -1/2, 0, Sqrt[3]/2, Sqrt[3]/2}, {2, 1/2, -1/
  2, 0, -Sqrt[3]/2, Sqrt[3]/2}, {2, 1/2, 1, 0, Sqrt[3]/2, 0}, {2, -1, -1/
  2, 0, 0, -Sqrt[3]/2}, {2, 1/2, -1/2, 0, Sqrt[3]/2, -Sqrt[3]/
  2}, {2, 1/2, 1, 0, -Sqrt[3]/2, 0}, {2, -1, -1/2, 0, 0, Sqrt[3]/
  2}, {-1, 2, 1, 0, 0, 0}, {-1, -1, -1/2, 0, Sqrt[3], -Sqrt[3]/
  2}, {-1, -1, -1/2, 0, -Sqrt[3], Sqrt[3]/2}, {-1, -1, -1/2, 0, Sqrt[
   3], Sqrt[3]/2}, {-1, -1, 1, 0, -Sqrt[3], 0}, {-1, 2, -1/2, 0,
  0, -Sqrt[3]/2}, {-1, -1, -1/2, 0, -Sqrt[3], -Sqrt[3]/2}, {-1, -1,
  1, 0, Sqrt[3], 0}, {-1, 2, -1/2, 0, 0, Sqrt[3]/2}, {2, 1, -1, 0, 0,
  0}, {2, -1/2, 1/2, 0, Sqrt[3]/2, Sqrt[3]/2}, {2, -1/2, 1/
  2, 0, -Sqrt[3]/2, -Sqrt[3]/2}, {2, -1/2, 1/2, 0, Sqrt[3]/
  2, -Sqrt[3]/2}, {2, -1/2, -1, 0, -Sqrt[3]/2, 0}, {2, 1, 1/2, 0,
  0, Sqrt[3]/2}, {2, -1/2, 1/2, 0, -Sqrt[3]/2, Sqrt[3]/2}, {2, -1/
  2, -1, 0, Sqrt[3]/2, 0}, {2, 1, 1/2, 0, 0, -Sqrt[3]/2}, {-1, 1, 2,
  0, 0, 0}, {-1, -1/2, -1, 0, Sqrt[3]/2, -Sqrt[3]}, {-1, -1/2, -1,
  0, -Sqrt[3]/2, Sqrt[3]}, {-1, -1/2, -1, 0, Sqrt[3]/2, Sqrt[
   3]}, {-1, -1/2, 2, 0, -Sqrt[3]/2, 0}, {-1, 1, -1, 0, 0, -Sqrt[
   3]}, {-1, -1/2, -1, 0, -Sqrt[3]/2, -Sqrt[3]}, {-1, -1/2, 2, 0,
  Sqrt[3]/2, 0}, {-1, 1, -1, 0, 0, Sqrt[3]}, {1, 2, -1, 0, 0,
  0}, {1, -1, 1/2, 0, Sqrt[3], Sqrt[3]/2}, {1, -1, 1/
  2, 0, -Sqrt[3], -Sqrt[3]/2}, {1, -1, 1/2, 0, Sqrt[3], -Sqrt[3]/
  2}, {1, -1, -1, 0, -Sqrt[3], 0}, {1, 2, 1/2, 0, 0, Sqrt[3]/2}, {1, -1,
   1/2, 0, -Sqrt[3], Sqrt[3]/2}, {1, -1, -1, 0, Sqrt[3], 0}, {1, 2,
  1/2, 0, 0, -Sqrt[3]/2}, {1, -1, 2, 0, 0, 0}, {1, 1/2, -1,
  0, -Sqrt[3]/2, -Sqrt[3]}, {1, 1/2, -1, 0, Sqrt[3]/2, Sqrt[3]}, {1,
  1/2, -1, 0, -Sqrt[3]/2, Sqrt[3]}, {1, 1/2, 2, 0, Sqrt[3]/2, 0}, {1, -1,
   -1, 0, 0, -Sqrt[3]}, {1, 1/2, -1, 0, Sqrt[3]/2, -Sqrt[3]}, {1,
  1/2, 2, 0, -Sqrt[3]/2, 0}, {1, -1, -1, 0, 0, Sqrt[3]}
};

(* Get the total number of vectors *)
n = Length[vectors];
foundCollinear = False;

(* Iterate through all unique pairs of vectors *)
For[i = 1, i <= n, i++,
  For[j = i + 1, j <= n, j++,
    (* Two non-zero vectors are collinear if the matrix they form has rank 1 *)
    If[MatrixRank[{vectors[[i]], vectors[[j]]}] == 1,
      Print["Vectors at index ", i, " and ", j, " are collinear:"];
      Print["Vector ", i, ": ", vectors[[i]]];
      Print["Vector ", j, ": ", vectors[[j]], "\n"];
      foundCollinear = True;
    ]
  ]
]

(* Print a message if no collinear pairs were found *)
If[!foundCollinear,
  Print["No collinear pairs were found in the list."]
]

###########################################################################


(*Phase-solver for the 165-ray configuration.\
All labels from the user's table are entered as Mathematica symbols,\
each assigned a 3-component complex vector using \[Omega]=Exp[2 Pi I/\
3].The program picks rational-multiple-of-Pi phases \[Theta][label]=n*\
Pi/K with an algorithmic choice of K (large prime) such that no spurio\
us realified orthogonality arises:\
for each pair with nonzero complex inner product,\
the realified inner product is nonzero.*)(*------------------------------*)(*1\
) Primitive third root of unity*)(*------------------------------*)\
\[Omega] = Exp[2 Pi I/3];

(*------------------------------*)
(*2) All vectors as in original table (3-component complex form)*)
(*Note:labels are Mathematica symbols like a11,u2,b1121,etc.*)
(*------------------------------*)

(*a-group*)
a11 = {1, 0, 0};
a21 = {0, 1, 0};
a31 = {0, 0, 1};

(*u-group*)
u1 = {1, 1, 1};
u2 = {1, \[Omega], \[Omega]^2};
u3 = {1, \[Omega]^2, \[Omega]};
u4 = {1, \[Omega], \[Omega]};
u5 = {1, \[Omega]^2, 1};
u6 = {1, 1, \[Omega]^2};
u7 = {1, \[Omega]^2, \[Omega]^2};
u8 = {1, \[Omega], 1};
u9 = {1, 1, \[Omega]};

(*b 1x group*)
b11 = {0, 1, 1};
b12 = {0, \[Omega], \[Omega]^2};
b13 = {0, \[Omega]^2, \[Omega]};

b21 = {1, 0, 1};
b22 = {1, 0, \[Omega]^2};
b23 = {1, 0, \[Omega]};

b31 = {1, 1, 0};
b32 = {1, \[Omega], 0};
b33 = {1, \[Omega]^2, 0};

(*c group*)
c11 = {0, 1, -1};
c12 = {0, \[Omega], -\[Omega]^2};
c13 = {0, \[Omega]^2, -\[Omega]};

c21 = {-1, 0, 1};
c22 = {-\[Omega], 0, 1};
c23 = {-\[Omega]^2, 0, 1};

c31 = {1, -1, 0};
c32 = {\[Omega]^2, -1, 0};
c33 = {\[Omega], -1, 0};

(*d group*)
d11 = {-2, 1, 1};
d12 = {-2, \[Omega], \[Omega]^2};
d13 = {-2, \[Omega]^2, \[Omega]};
d14 = {-2, \[Omega], \[Omega]};
d15 = {-2, \[Omega]^2, 1};
d16 = {-2, 1, \[Omega]^2};
d17 = {-2, \[Omega]^2, \[Omega]^2};
d18 = {-2, \[Omega], 1};
d19 = {-2, 1, \[Omega]};

d21 = {1, -2, 1};
d22 = {\[Omega]^2, -2, \[Omega]};
d23 = {\[Omega], -2, \[Omega]^2};
d24 = {\[Omega]^2, -2, 1};
d25 = {\[Omega], -2, \[Omega]};
d26 = {1, -2, \[Omega]^2};
d27 = {\[Omega], -2, 1};
d28 = {\[Omega]^2, -2, \[Omega]^2};
d29 = {1, -2, \[Omega]};

d31 = {1, 1, -2};
d32 = {\[Omega], \[Omega]^2, -2};
d33 = {\[Omega]^2, \[Omega], -2};
d34 = {\[Omega]^2, 1, -2};
d35 = {1, \[Omega]^2, -2};
d36 = {\[Omega], \[Omega], -2};
d37 = {\[Omega], 1, -2};
d38 = {1, \[Omega], -2};
d39 = {\[Omega]^2, \[Omega]^2, -2};

(*b12x group*)
b121 = {1, 1, -1};
b122 = {1, \[Omega], -\[Omega]^2};
b123 = {1, \[Omega]^2, -\[Omega]};
b124 = {\[Omega], \[Omega]^2, -\[Omega]^2};
b125 = {\[Omega], 1, -\[Omega]};
b126 = {\[Omega], \[Omega], -1};
b127 = {\[Omega]^2, \[Omega], -\[Omega]};
b128 = {\[Omega]^2, 1, -\[Omega]^2};
b129 = {\[Omega]^2, \[Omega]^2, -1};

(*b13x group*)
b131 = {1, -1, 1};
b132 = {1, -\[Omega], \[Omega]^2};
b133 = {1, -\[Omega]^2, \[Omega]};
b134 = {\[Omega], -\[Omega]^2, \[Omega]^2};
b135 = {\[Omega], -1, \[Omega]};
b136 = {\[Omega], -\[Omega], 1};
b137 = {\[Omega]^2, -\[Omega], \[Omega]};
b138 = {\[Omega]^2, -1, \[Omega]^2};
b139 = {\[Omega]^2, -\[Omega]^2, 1};

(*b23x group*)
b231 = {-1, 1, 1};
b232 = {-1, \[Omega], \[Omega]^2};
b233 = {-1, \[Omega]^2, \[Omega]};
b234 = {-\[Omega], \[Omega]2 :> \[Omega], \[Omega]2}; \
(*placeholder:but original table had-\[Omega],\[Omega]2,\[Omega]2 etc.\
We'll use exact entries below*)
(*Fixing b234..b239 explicitly from original:*)
b234 = {-\[Omega], \[Omega]^2, \[Omega]^2};
b235 = {-\[Omega], 1, \[Omega]};
b236 = {-\[Omega], \[Omega], 1};
b237 = {-\[Omega]^2, \[Omega], \[Omega]};
b238 = {-\[Omega]^2, 1, \[Omega]^2};
b239 = {-\[Omega]^2, \[Omega]^2, 1};

(*e group (e11..e39)*)
e11 = {1, 2, 1};
e12 = {\[Omega]^2, 2, \[Omega]};
e13 = {\[Omega], 2, \[Omega]^2};
e14 = {\[Omega], 2 \[Omega]^2, \[Omega]^2};
e15 = {1, 2 \[Omega]^2, 1};
e16 = {\[Omega]^2, 2 \[Omega]^2, \[Omega]};
e17 = {\[Omega]^2, 2 \[Omega], \[Omega]};
e18 = {1, 2 \[Omega], 1};
e19 = {\[Omega], 2 \[Omega], \[Omega]^2};

e21 = {1, 1, 2};
e22 = {\[Omega], \[Omega]^2, 2};
e23 = {\[Omega]^2, \[Omega], 2};
e24 = {\[Omega], \[Omega]^2, 2 \[Omega]^2};
e25 = {\[Omega]^2, \[Omega], 2 \[Omega]^2};
e26 = {1, 1, 2 \[Omega]^2};
e27 = {\[Omega]^2, \[Omega], 2 \[Omega]};
e28 = {\[Omega], \[Omega]^2, 2 \[Omega]};
e29 = {1, 1, 2 \[Omega]};

e31 = {2, 1, 1};
e32 = {2, \[Omega], \[Omega]^2};
e33 = {2, \[Omega]^2, \[Omega]};
e34 = {2 \[Omega]^2, 1, 1};
e35 = {2 \[Omega]^2, \[Omega], \[Omega]^2};
e36 = {2 \[Omega]^2, \[Omega]^2, \[Omega]};
e37 = {2 \[Omega], 1, 1};
e38 = {2 \[Omega], \[Omega]^2, \[Omega]};
e39 = {2 \[Omega], \[Omega], \[Omega]^2};

(*b112x group*)
b1121 = {2, -1, 1};
b1122 = {2, -\[Omega], \[Omega]^2};
b1123 = {2, -\[Omega]^2, \[Omega]};
b1124 = {2, -\[Omega], \[Omega]};
b1125 = {2, -\[Omega]^2, 1};
b1126 = {2, -1, \[Omega]^2};
b1127 = {2, -\[Omega]^2, \[Omega]^2};
b1128 = {2, -\[Omega], 1};
b1129 = {2, -1, \[Omega]};

(*b212x group*)
b2121 = {-1, 2, 1};
b2122 = {-1, 2 \[Omega], \[Omega]^2};
b2123 = {-1, 2 \[Omega]^2, \[Omega]};
b2124 = {-1, 2 \[Omega], \[Omega]};
b2125 = {-1, 2 \[Omega]^2, 1};
b2126 = {-1, 2, \[Omega]^2};
b2127 = {-1, 2 \[Omega]^2, \[Omega]^2};
b2128 = {-1, 2 \[Omega], 1};
b2129 = {-1, 2, \[Omega]};

(*b113x group*)
b1131 = {2, 1, -1};
b1132 = {2, \[Omega], -\[Omega]^2};
b1133 = {2, \[Omega]^2, -\[Omega]};
b1134 = {2, \[Omega], -\[Omega]};
b1135 = {2, \[Omega]^2, -1};
b1136 = {2, 1, -\[Omega]^2};
b1137 = {2, \[Omega]^2, -\[Omega]^2};
b1138 = {2, \[Omega], -1};
b1139 = {2, 1, -\[Omega]};

(*b313x group*)
b3131 = {-1, 1, 2};
b3132 = {-1, \[Omega], 2 \[Omega]^2};
b3133 = {-1, \[Omega]^2, 2 \[Omega]};
b3134 = {-1, \[Omega], 2 \[Omega]};
b3135 = {-1, \[Omega]^2, 2};
b3136 = {-1, 1, 2 \[Omega]^2};
b3137 = {-1, \[Omega]^2, 2 \[Omega]^2};
b3138 = {-1, \[Omega], 2};
b3139 = {-1, 1, 2 \[Omega]};

(*b223x group*)
b2231 = {1, 2, -1};
b2232 = {1, 2 \[Omega], -\[Omega]^2};
b2233 = {1, 2 \[Omega]^2, -\[Omega]};
b2234 = {1, 2 \[Omega], -\[Omega]};
b2235 = {1, 2 \[Omega]^2, -1};
b2236 = {1, 2, -\[Omega]^2};
b2237 = {1, 2 \[Omega]^2, -\[Omega]^2};
b2238 = {1, 2 \[Omega], -1};
b2239 = {1, 2, -\[Omega]};

(*b323x group*)
b3231 = {1, -1, 2};
b3232 = {1, -\[Omega], 2 \[Omega]^2};
b3233 = {1, -\[Omega]^2, 2 \[Omega]};
b3234 = {1, -\[Omega], 2 \[Omega]};
b3235 = {1, -\[Omega]^2, 2};
b3236 = {1, -1, 2 \[Omega]^2};
b3237 = {1, -\[Omega]^2, 2 \[Omega]^2};
b3238 = {1, -\[Omega], 2};
b3239 = {1, -1, 2 \[Omega]};

(*The above entries mirror the full Table I from your prompt.\
If you notice any label mismatch or you want a different ordering,\
edit the assignments above accordingly.*)

(*------------------------------*)
(*3) Build ordered key list in original order*)
(*------------------------------*)
keys = {a11, a21, a31, u1, u2, u3, u4, u5, u6, u7, u8, u9, b11, b12,
   b13, b21, b22, b23, b31, b32, b33, c11, c12, c13, c21, c22, c23,
   c31, c32, c33, d11, d12, d13, d14, d15, d16, d17, d18, d19, d21,
   d22, d23, d24, d25, d26, d27, d28, d29, d31, d32, d33, d34, d35,
   d36, d37, d38, d39, b121, b122, b123, b124, b125, b126, b127, b128,
    b129, b131, b132, b133, b134, b135, b136, b137, b138, b139, b231,
   b232, b233, b234, b235, b236, b237, b238, b239, e11, e12, e13, e14,
    e15, e16, e17, e18, e19, e21, e22, e23, e24, e25, e26, e27, e28,
   e29, e31, e32, e33, e34, e35, e36, e37, e38, e39, b1121, b1122,
   b1123, b1124, b1125, b1126, b1127, b1128, b1129, b2121, b2122,
   b2123, b2124, b2125, b2126, b2127, b2128, b2129, b1131, b1132,
   b1133, b1134, b1135, b1136, b1137, b1138, b1139, b3131, b3132,
   b3133, b3134, b3135, b3136, b3137, b3138, b3139, b2231, b2232,
   b2233, b2234, b2235, b2236, b2237, b2238, b2239, b3231, b3232,
   b3233, b3234, b3235, b3236, b3237, b3238, b3239};

(*------------------------------*)
(*4) Create association label->complex 3-vector for convenience*)
(*------------------------------*)
vec = Association[
   Table[keys[[i]] -> Evaluate[keys[[i]]], {i, Length[keys]}]];

(*Quick sanity check*)
Print["Number of vectors in vec: ", Length[vec]];

(*------------------------------*)
(*5) Complex inner products in C^3*)
(*------------------------------*)
innerC[i_, j_] := Simplify[vec[i] . Conjugate[vec[j]]];

(*Build list of non-orthogonal pairs (i<\
j) and their complex inner products*)
pairsNonZero =
  Reap[Do[Module[{c = innerC[keys[[i]], keys[[j]]]},
      If[! Simplify[c === 0], Sow[{keys[[i]], keys[[j]], c}]]], {i,
      Length[keys]}, {j, i + 1, Length[keys]}]][[2, 1]];

Print["Non-orthogonal pairs count: ", Length[pairsNonZero]];

(*------------------------------*)
(*6) Realification map \[CapitalPhi]\
0 and realified dot product for phases*)
(*For symbolic \[Theta] we expand Re/Im manually:if z=x+i y,\
and we multiply by e^{i \[Theta]}:Re(e^{i \[Theta]} z)=cos \[Theta] x-\
sin \[Theta] y Im(e^{i \[Theta]} z)=sin \[Theta] x+cos \[Theta]\
 y so the 6-vector is Join[cos \[Theta] x-sin \[Theta] y,sin \[Theta]\
 x+cos \[Theta] y]*)
(*------------------------------*)

(*Precompute real and imaginary parts for each complex vector*)
realPart = Association[# -> Re[vec[#]] & /@ Keys[vec]];
imagPart = Association[# -> Im[vec[#]] & /@ Keys[vec]];

(*Function returning the real 6-vector for label with phase \[Theta]\
sym (a symbolic variable or expression)*)
real6[label_, \[Theta]sym_] :=
  Module[{x = realPart[label], y = imagPart[label],
    c = Cos[\[Theta]sym], s = Sin[\[Theta]sym]},
   Join[Simplify[c x - s y], Simplify[s x + c y]]];

(*Realified dot product between label i (phase \[Theta]\
i) and label j (phase \[Theta]j)*)
realDot[labeli_, \[Theta]i_, labelj_, \[Theta]j_] :=
  Simplify[real6[labeli, \[Theta]i] . real6[labelj, \[Theta]j]];

(*------------------------------*)
(*7) Construct constructive analytic phases \[Theta]_k=n_k*Pi/\
K We'll try with a large prime K (e.g.,\
1009) and choose distinct numerators.\
If a conflict arises (some realDot==\
0 for a nonzero complex inner product),\
we increase K to the next prime and retry.The final solution prints\
 \[Theta][label] in terms of Pi.*)
(*------------------------------*)

needsCheckQ :=
  Module[{K = 1009, numerators, \[Theta]Assoc, okQ,
    pairs = pairsNonZero},(*function to attempt with given K*)
   Module[{tryK, conflicts},
    tryK[K0_Integer] :=
     Module[{K1 = K0, nList, \[Theta]s, \[Theta]Map,
       conflictPairs},(*choose numerators 0..(N-\
1) to make distinct angles in[0,\[Pi]) maybe use 0..N-1*)
      nList = Range[0, Length[keys] - 1];
      \[Theta]s = Table[(nList[[i]]*Pi)/K1, {i, Length[nList]}];
      \[Theta]Map = AssociationThread[keys -> \[Theta]s];
      (*check all nonzero-pairs*)
      conflictPairs =
       Select[pairs,
        Simplify[
           Chop[realDot[#[[1]], \[Theta]Map[#[[1]]], #[[2]], \
\[Theta]Map[#[[2]]]]]] == 0 &];
      If[Length[conflictPairs] == 0,(*success*)
       Return[{True, K1, \[Theta]Map}],(*else failure*)
       Return[{False, conflictPairs}]]];
    (*try K and if fails,get next prime and retry up to some attempts*)
    Module[{Ktry = K, attempts = 0, res},
     While[attempts < 200, res = tryK[Ktry];
      If[res[[1]] === True, Return[res],(*else pick next prime*)
       Ktry = NextPrime[Ktry + 1];
       attempts++;]];
     Return[{False, "No K found in attempts"}]]]];

Print["Attempting to find a rational-multiple-of-Pi solution for \
\[Theta]s ..."];
res = needsCheckQ;
If[res[[1]] === True, Print["Found K = ", res[[2]]];
  \[Theta]MapFinal = res[[3]];,
  Print["Failed to find K via automatic search. Result: ", res];
  Abort[]];

(*------------------------------*)
(*8) Report and verify final phases*)
(*------------------------------*)
Print["--- Final phases \[Theta][label] (in exact form as multiple of \
Pi):"];
Do[Print[ToString[keys[[i]]], " -> ",
   TraditionalForm[\[Theta]MapFinal[keys[[i]]]]], {i, Length[keys]}];

(*Verify numeric nonzero real dot products for all non-\
orthogonal pairs with high precision*)
chk = Table[{pair[[1]], pair[[2]],
    N[realDot[pair[[1]], \[Theta]MapFinal[pair[[1]]],
      pair[[2]], \[Theta]MapFinal[pair[[2]]]], 40]}, {pair,
    pairsNonZero}];

conflictsNumeric = Select[chk, Abs[#[[3]]] < 10^-12 &];

If[Length[conflictsNumeric] == 0,
  Print["Verification passed: no spurious realified orthogonality \
(numerical check)."],
  Print["WARNING: Numerical conflicts found (should be none):"];
  Print[conflictsNumeric // Short]];

(*Output phases in a usable form:association label->\
rational multiple of Pi*)
thetaRational =
  AssociationMap[
   Function[lbl,
    Together[Numerator[\[Theta]MapFinal[lbl]/Pi]]*
     Pi/Together[Denominator[\[Theta]MapFinal[lbl]/Pi]]], keys];

Print["Phases as rational multiples of Pi (\[Theta] = n Pi / K form):"];
Do[Print[keys[[i]], " -> ", Simplify[\[Theta]MapFinal[keys[[i]]]/Pi],
   " * Pi"], {i, Length[keys]}];

(*Save results to a file for convenience*)
Export["phases_association.mx", \[Theta]MapFinal]; \
(*binary Mathematica format*)
Export["phases_readable.txt",
  TableForm[
   Table[{keys[[i]], \[Theta]MapFinal[keys[[i]]]}, {i, Length[keys]}]]];

Print["Done. Phases exported to phases_association.mx and \
phases_readable.txt"];


#####################################################################################



(* ========================================================== *)
(* 1. SETUP & DATA *)
(* ========================================================== *)
w = Exp[2 Pi I / 3]; (* Define omega numerically *)

(* Paste the LaTeX data exactly as is *)
latexData = "

$a_{11}$ & $(1,0,0)$ &
$a_{21}$ & $(0,1,0)$ &
$a_{31}$ & $(0,0,1)$ &
$u_{1}$ & $(1,1,1)$ &
$u_{2}$ & $(1,\omega,\omega^2)$ &
$u_{3}$ & $(1,\omega^2,\omega)$ &
$u_{4}$ & $(1,\omega,\omega)$ &
$u_{5}$ & $(1,\omega^2,1)$ &
$u_{6}$ & $(1,1,\omega^2)$ &
$u_{7}$ & $(1,\omega^2,\omega^2)$ &
$u_{8}$ & $(1,\omega,1)$ &
$u_{9}$ & $(1,1,\omega)$ &
$b_{11}$ & $(0,1,1)$ &
$b_{12}$ & $(0,\omega,\omega^2)$ &
$b_{13}$ & $(0,\omega^2,\omega)$ &
$b_{21}$ & $(1,0,1)$ &
$b_{22}$ & $(1,0,\omega^2)$ &
$b_{23}$ & $(1,0,\omega)$ &
$b_{31}$ & $(1,1,0)$ &
$b_{32}$ & $(1,\omega,0)$ &
$b_{33}$ & $(1,\omega^2,0)$ &
$c_{11}$ & $(0,1,-1)$ &
$c_{12}$ & $(0,\omega,-\omega^2)$ &
$c_{13}$ & $(0,\omega^2,-\omega)$ &
$c_{21}$ & $(-1,0,1)$ &
$c_{22}$ & $(-\omega,0,1)$ &
$c_{23}$ & $(-\omega^2,0,1)$ &
$c_{31}$ & $(1,-1,0)$ &
$c_{32}$ & $(\omega^2,-1,0)$ &
$c_{33}$ & $(\omega,-1,0)$ &
$d_{11}$ & $(-2,1,1)$ &
$d_{12}$ & $(-2,\omega,\omega^2)$ &
$d_{13}$ & $(-2,\omega^2,\omega)$ &
$d_{14}$ & $(-2,\omega,\omega)$ &
$d_{15}$ & $(-2,\omega^2,1)$ &
$d_{16}$ & $(-2,1,\omega^2)$ &
$d_{17}$ & $(-2,\omega^2,\omega^2)$ &
$d_{18}$ & $(-2,\omega,1)$ &
$d_{19}$ & $(-2,1,\omega)$ &
$d_{21}$ & $(1,-2,1)$ &
$d_{22}$ & $(\omega^2,-2,\omega)$ &
$d_{23}$ & $(\omega,-2,\omega^2)$ &
$d_{24}$ & $(\omega^2,-2,1)$ &
$d_{25}$ & $(\omega,-2,\omega)$ &
$d_{26}$ & $(1,-2,\omega^2)$ &
$d_{27}$ & $(\omega,-2,1)$ &
$d_{28}$ & $(\omega^2,-2,\omega^2)$ &
$d_{29}$ & $(1,-2,\omega)$ &
$d_{31}$ & $(1,1,-2)$ &
$d_{32}$ & $(\omega,\omega^2,-2)$ &
$d_{33}$ & $(\omega^2,\omega,-2)$ &
$d_{34}$ & $(\omega^2,1,-2)$ &
$d_{35}$ & $(1,\omega^2,-2)$ &
$d_{36}$ & $(\omega,\omega,-2)$ &
$d_{37}$ & $(\omega,1,-2)$ &
$d_{38}$ & $(1,\omega,-2)$ &
$d_{39}$ & $(\omega^2,\omega^2,-2)$ &
$b_{121}$ & $(1,1,-1)$ &
$b_{122}$ & $(1,\omega,-\omega^2)$ &
$b_{123}$ & $(1,\omega^2,-\omega)$ &
$b_{124}$ & $(\omega,\omega^2,-\omega^2)$ &
$b_{125}$ & $(\omega,1,-\omega)$ &
$b_{126}$ & $(\omega,\omega,-1)$ &
$b_{127}$ & $(\omega^2,\omega,-\omega)$ &
$b_{128}$ & $(\omega^2,1,-\omega^2)$ &
$b_{129}$ & $(\omega^2,\omega^2,-1)$ &
$b_{131}$ & $(1,-1,1)$ &
$b_{132}$ & $(1,-\omega,\omega^2)$ &
$b_{133}$ & $(1,-\omega^2,\omega)$ &
$b_{134}$ & $(\omega,-\omega^2,\omega^2)$ &
$b_{135}$ & $(\omega,-1,\omega)$ &
$b_{136}$ & $(\omega,-\omega,1)$ &
$b_{137}$ & $(\omega^2,-\omega,\omega)$ &
$b_{138}$ & $(\omega^2,-1,\omega^2)$ &
$b_{139}$ & $(\omega^2,-\omega^2,1)$ &
$b_{231}$ & $(-1,1,1)$ &
$b_{232}$ & $(-1,\omega,\omega^2)$ &
$b_{233}$ & $(-1,\omega^2,\omega)$ &
$b_{234}$ & $(-\omega,\omega^2,\omega^2)$ &
$b_{235}$ & $(-\omega,1,\omega)$ &
$b_{236}$ & $(-\omega,\omega,1)$ &
$b_{237}$ & $(-\omega^2,\omega,\omega)$ &
$b_{238}$ & $(-\omega^2,1,\omega^2)$ &
$b_{239}$ & $(-\omega^2,\omega^2,1)$ &
$e_{11}$ & $(1,2,1)$ &
$e_{12}$ & $(\omega^2,2,\omega)$ &
$e_{13}$ & $(\omega,2,\omega^2)$ &
$e_{14}$ & $(\omega,2\omega^2,\omega^2)$ &
$e_{15}$ & $(1,2\omega^2,1)$ &
$e_{16}$ & $(\omega^2,2\omega^2,\omega)$ &
$e_{17}$ & $(\omega^2,2\omega,\omega)$ &
$e_{18}$ & $(1,2\omega,1)$ &
$e_{19}$ & $(\omega,2\omega,\omega^2)$ &
$e_{21}$ & $(1,1,2)$ &
$e_{22}$ & $(\omega,\omega^2,2)$ &
$e_{23}$ & $(\omega^2,\omega,2)$ &
$e_{24}$ & $(\omega,\omega^2,2\omega^2)$ &
$e_{25}$ & $(\omega^2,\omega,2\omega^2)$ &
$e_{26}$ & $(1,1,2\omega^2)$ &
$e_{27}$ & $(\omega^2,\omega,2\omega)$ &
$e_{28}$ & $(\omega,\omega^2,2\omega)$ &
$e_{29}$ & $(1,1,2\omega)$ &
$e_{31}$ & $(2,1,1)$ &
$e_{32}$ & $(2,\omega,\omega^2)$ &
$e_{33}$ & $(2,\omega^2,\omega)$ &
$e_{34}$ & $(2\omega^2,1,1)$ &
$e_{35}$ & $(2\omega^2,\omega,\omega^2)$ &
$e_{36}$ & $(2\omega^2,\omega^2,\omega)$ &
$e_{37}$ & $(2\omega,1,1)$ &
$e_{38}$ & $(2\omega,\omega^2,\omega)$ &
$e_{39}$ & $(2\omega,\omega,\omega^2)$ &
$b_{1121}$ & $(2,-1,1)$ &
$b_{1122}$ & $(2,-\omega,\omega^2)$ &
$b_{1123}$ & $(2,-\omega^2,\omega)$ &
$b_{1124}$ & $(2,-\omega,\omega)$ &
$b_{1125}$ & $(2,-\omega^2,1)$ &
$b_{1126}$ & $(2,-1,\omega^2)$ &
$b_{1127}$ & $(2,-\omega^2,\omega^2)$ &
$b_{1128}$ & $(2,-\omega,1)$ &
$b_{1129}$ & $(2,-1,\omega)$ &
$b_{2121}$ & $(-1,2,1)$ &
$b_{2122}$ & $(-1,2\omega,\omega^2)$ &
$b_{2123}$ & $(-1,2\omega^2,\omega)$ &
$b_{2124}$ & $(-1,2\omega,\omega)$ &
$b_{2125}$ & $(-1,2\omega^2,1)$ &
$b_{2126}$ & $(-1,2,\omega^2)$ &
$b_{2127}$ & $(-1,2\omega^2,\omega^2)$ &
$b_{2128}$ & $(-1,2\omega,1)$ &
$b_{2129}$ & $(-1,2,\omega)$ &
$b_{1131}$ & $(2,1,-1)$ &
$b_{1132}$ & $(2,\omega,-\omega^2)$ &
$b_{1133}$ & $(2,\omega^2,-\omega)$ &
$b_{1134}$ & $(2,\omega,-\omega)$ &
$b_{1135}$ & $(2,\omega^2,-1)$ &
$b_{1136}$ & $(2,1,-\omega^2)$ &
$b_{1137}$ & $(2,\omega^2,-\omega^2)$ &
$b_{1138}$ & $(2,\omega,-1)$ &
$b_{1139}$ & $(2,1,-\omega)$ &
$b_{3131}$ & $(-1,1,2)$ &
$b_{3132}$ & $(-1,\omega,2\omega^2)$ &
$b_{3133}$ & $(-1,\omega^2,2\omega)$ &
$b_{3134}$ & $(-1,\omega,2\omega)$ &
$b_{3135}$ & $(-1,\omega^2,2)$ &
$b_{3136}$ & $(-1,1,2\omega^2)$ &
$b_{3137}$ & $(-1,\omega^2,2\omega^2)$ &
$b_{3138}$ & $(-1,\omega,2)$ &
$b_{3139}$ & $(-1,1,2\omega)$ &
$b_{2231}$ & $(1,2,-1)$ &
$b_{2232}$ & $(1,2\omega,-\omega^2)$ &
$b_{2233}$ & $(1,2\omega^2,-\omega)$ &
$b_{2234}$ & $(1,2\omega,-\omega)$ &
$b_{2235}$ & $(1,2\omega^2,-1)$ &
$b_{2236}$ & $(1,2,-\omega^2)$ &
$b_{2237}$ & $(1,2\omega^2,-\omega^2)$ &
$b_{2238}$ & $(1,2\omega,-1)$ &
$b_{2239}$ & $(1,2,-\omega)$ &
$b_{3231}$ & $(1,-1,2)$ &
$b_{3232}$ & $(1,-\omega,2\omega^2)$ &
$b_{3233}$ & $(1,-\omega^2,2\omega)$ &
$b_{3234}$ & $(1,-\omega,2\omega)$ &
$b_{3235}$ & $(1,-\omega^2,2)$ &
$b_{3236}$ & $(1,-1,2\omega^2)$ &
$b_{3237}$ & $(1,-\omega^2,2\omega^2)$ &
$b_{3238}$ & $(1,-\omega,2)$ &
$b_{3239}$ & $(1,-1,2\omega)$ &";

(* ========================================================== *)
(* 2. ROBUST PARSING *)
(* ========================================================== *)

(* Split by lines using StringSplit and newline character *)
rawLines = StringSplit[latexData, "\n"];
(* Filter for lines containing data *)
dataLines = Select[rawLines, StringContainsQ[#, "&"] &];

parseData[line_] := Module[{parts, labelRaw, vectorRaw, vecStr, vecVal},
   parts = StringSplit[line, "&"];

   (* Extract Label: Remove $ and spaces *)
   labelRaw = StringTrim[StringReplace[parts[[1]], "$" -> ""]];

   (* Extract Vector: Remove $( ) and spaces *)
   vectorRaw = StringTrim[parts[[2]]];
   vecStr = StringReplace[vectorRaw, {
       "$" -> "", "(" -> "{", ")" -> "}",
       "\\omega" -> "w", (* convert LaTeX omega to symbol w *)
       " " -> ""         (* remove all spaces *)
   }];

   (* Convert string to expression *)
   vecVal = ToExpression[vecStr];

   {labelRaw, vecVal}
];

parsed = parseData /@ dataLines;

(* Separate Labels and Vectors *)
labels = parsed[[All, 1]];
vectors = parsed[[All, 2]];

(* Canonicalize: Normalize first non-zero entry to 1 *)
canonicalize[v_] := Module[{s = Simplify[v]},
   If[PossibleZeroQ[Norm[s]], s,
     With[{first = FirstCase[s, x_ /; !PossibleZeroQ[x]]},
       Simplify[s / first]
     ]
   ]
];

rays = canonicalize /@ vectors;
NumRays = Length[rays];
Print["Parsed Rays: ", NumRays]; (* Must be 165 *)

(* ========================================================== *)
(* 3. GRAPH & CONTEXTS *)
(* ========================================================== *)

(* Orthogonality: u . v* = 0 *)
adjMatrix = Table[
   If[i != j && PossibleZeroQ[Simplify[rays[[i]] . Conjugate[rays[[j]]]]], 1, 0],
   {i, NumRays}, {j, NumRays}
];
orthoGraph = AdjacencyGraph[adjMatrix];

(* Find Contexts: All Cliques of size 3 *)
cliques = FindClique[orthoGraph, {3}, All];
NumContexts = Length[cliques];
Print["Contexts Found: ", NumContexts]; (* Must be 130 *)

(* ========================================================== *)
(* 4. OPTIMIZATION *)
(* ========================================================== *)

(* Objective: Maximize satisfied contexts *)
objective = ConstantArray[0, NumRays];
(* Weight objective by context participation *)
Do[Do[objective[[id]]++, {id, c}], {c, cliques}];

(* Constraints: For every edge, x_i + x_j <= 1 *)
edges = EdgeList[orthoGraph];
m = Table[
    vec = ConstantArray[0, NumRays];
    vec[[First[e]]] = 1;
    vec[[Last[e]]] = 1;
    vec,
    {e, edges}
];
b = Table[{1, -1}, {Length[edges]}]; (* <= 1 *)

(* Minimize -Objective to Maximize *)
solution = LinearProgramming[
   -objective,
   m,
   b,
   Table[{0, 1}, {NumRays}],
   Integers
];

MaxSatisfied = Total[solution * objective];
Deficit = NumContexts - MaxSatisfied;

(* ========================================================== *)
(* 5. REPORT ALL VALUES *)
(* ========================================================== *)

Print["\n=== RESULTS ==="];
Print["Total Contexts: ", NumContexts];
Print["Max Satisfied: ", MaxSatisfied];
Print["Deficit: ", Deficit];

Print["\n=== BROKEN CONTEXTS (Sum = 0) ==="];
Do[
  ids = cliques[[c]];
  s = Total[solution[[ids]]];
  If[s == 0,
    Print["Context ", c, ": {", labels[[ids[[1]]]], ", ", labels[[ids[[2]]]], ", ", labels[[ids[[3]]]], "}"]
  ];
, {c, NumContexts}];

Print["\n=== FULL VALUATION (All Rays) ==="];
Print["Index \t Label \t\t Value"];
Do[
  (* Print formatted string with tabs *)
  lbl = labels[[i]];
  val = solution[[i]];
  (* Pad label for alignment *)
  Print[i, "\t ", lbl,If[StringLength[lbl]<7,"\t\t","\t"], val];
, {i, NumRays}];




##################################################################################################


(* ================================================================== *)
(*                     KOCHEN-SPECKER DEFICIT PROOF                   *)
(* ================================================================== *)
(* This script uses Integer Linear Programming (Exact Branch & Bound) *)
(* to prove the minimum number of broken contexts.                   *)
(* ================================================================== *)

(* 1. DATA INPUT ---------------------------------------------------- *)
w = Exp[2 Pi I / 3]; (* Exact symbolic complex number *)

latexData = "
$a_{11}$ & $(1,0,0)$ &
$a_{21}$ & $(0,1,0)$ &
$a_{31}$ & $(0,0,1)$ &
$u_{1}$ & $(1,1,1)$ &
$u_{2}$ & $(1,\\omega,\\omega^2)$ &
$u_{3}$ & $(1,\\omega^2,\\omega)$ &
$u_{4}$ & $(1,\\omega,\\omega)$ &
$u_{5}$ & $(1,\\omega^2,1)$ &
$u_{6}$ & $(1,1,\\omega^2)$ &
$u_{7}$ & $(1,\\omega^2,\\omega^2)$ &
$u_{8}$ & $(1,\\omega,1)$ &
$u_{9}$ & $(1,1,\\omega)$ &
$b_{11}$ & $(0,1,1)$ &
$b_{12}$ & $(0,\\omega,\\omega^2)$ &
$b_{13}$ & $(0,\\omega^2,\\omega)$ &
$b_{21}$ & $(1,0,1)$ &
$b_{22}$ & $(1,0,\\omega^2)$ &
$b_{23}$ & $(1,0,\\omega)$ &
$b_{31}$ & $(1,1,0)$ &
$b_{32}$ & $(1,\\omega,0)$ &
$b_{33}$ & $(1,\\omega^2,0)$ &
$c_{11}$ & $(0,1,-1)$ &
$c_{12}$ & $(0,\\omega,-\\omega^2)$ &
$c_{13}$ & $(0,\\omega^2,-\\omega)$ &
$c_{21}$ & $(-1,0,1)$ &
$c_{22}$ & $(-\\omega,0,1)$ &
$c_{23}$ & $(-\\omega^2,0,1)$ &
$c_{31}$ & $(1,-1,0)$ &
$c_{32}$ & $(\\omega^2,-1,0)$ &
$c_{33}$ & $(\\omega,-1,0)$ &
$d_{11}$ & $(-2,1,1)$ &
$d_{12}$ & $(-2,\\omega,\\omega^2)$ &
$d_{13}$ & $(-2,\\omega^2,\\omega)$ &
$d_{14}$ & $(-2,\\omega,\\omega)$ &
$d_{15}$ & $(-2,\\omega^2,1)$ &
$d_{16}$ & $(-2,1,\\omega^2)$ &
$d_{17}$ & $(-2,\\omega^2,\\omega^2)$ &
$d_{18}$ & $(-2,\\omega,1)$ &
$d_{19}$ & $(-2,1,\\omega)$ &
$d_{21}$ & $(1,-2,1)$ &
$d_{22}$ & $(\\omega^2,-2,\\omega)$ &
$d_{23}$ & $(\\omega,-2,\\omega^2)$ &
$d_{24}$ & $(\\omega^2,-2,1)$ &
$d_{25}$ & $(\\omega,-2,\\omega)$ &
$d_{26}$ & $(1,-2,\\omega^2)$ &
$d_{27}$ & $(\\omega,-2,1)$ &
$d_{28}$ & $(\\omega^2,-2,\\omega^2)$ &
$d_{29}$ & $(1,-2,\\omega)$ &
$d_{31}$ & $(1,1,-2)$ &
$d_{32}$ & $(\\omega,\\omega^2,-2)$ &
$d_{33}$ & $(\\omega^2,\\omega,-2)$ &
$d_{34}$ & $(\\omega^2,1,-2)$ &
$d_{35}$ & $(1,\\omega^2,-2)$ &
$d_{36}$ & $(\\omega,\\omega,-2)$ &
$d_{37}$ & $(\\omega,1,-2)$ &
$d_{38}$ & $(1,\\omega,-2)$ &
$d_{39}$ & $(\\omega^2,\\omega^2,-2)$ &
$b_{121}$ & $(1,1,-1)$ &
$b_{122}$ & $(1,\\omega,-\\omega^2)$ &
$b_{123}$ & $(1,\\omega^2,-\\omega)$ &
$b_{124}$ & $(\\omega,\\omega^2,-\\omega^2)$ &
$b_{125}$ & $(\\omega,1,-\\omega)$ &
$b_{126}$ & $(\\omega,\\omega,-1)$ &
$b_{127}$ & $(\\omega^2,\\omega,-\\omega)$ &
$b_{128}$ & $(\\omega^2,1,-\\omega^2)$ &
$b_{129}$ & $(\\omega^2,\\omega^2,-1)$ &
$b_{131}$ & $(1,-1,1)$ &
$b_{132}$ & $(1,-\\omega,\\omega^2)$ &
$b_{133}$ & $(1,-\\omega^2,\\omega)$ &
$b_{134}$ & $(\\omega,-\\omega^2,\\omega^2)$ &
$b_{135}$ & $(\\omega,-1,\\omega)$ &
$b_{136}$ & $(\\omega,-\\omega,1)$ &
$b_{137}$ & $(\\omega^2,-\\omega,\\omega)$ &
$b_{138}$ & $(\\omega^2,-1,\\omega^2)$ &
$b_{139}$ & $(\\omega^2,-\\omega^2,1)$ &
$b_{231}$ & $(-1,1,1)$ &
$b_{232}$ & $(-1,\\omega,\\omega^2)$ &
$b_{233}$ & $(-1,\\omega^2,\\omega)$ &
$b_{234}$ & $(-\\omega,\\omega^2,\\omega^2)$ &
$b_{235}$ & $(-\\omega,1,\\omega)$ &
$b_{236}$ & $(-\\omega,\\omega,1)$ &
$b_{237}$ & $(-\\omega^2,\\omega,\\omega)$ &
$b_{238}$ & $(-\\omega^2,1,\\omega^2)$ &
$b_{239}$ & $(-\\omega^2,\\omega^2,1)$ &
$e_{11}$ & $(1,2,1)$ &
$e_{12}$ & $(\\omega^2,2,\\omega)$ &
$e_{13}$ & $(\\omega,2,\\omega^2)$ &
$e_{14}$ & $(\\omega,2\\omega^2,\\omega^2)$ &
$e_{15}$ & $(1,2\\omega^2,1)$ &
$e_{16}$ & $(\\omega^2,2\\omega^2,\\omega)$ &
$e_{17}$ & $(\\omega^2,2\\omega,\\omega)$ &
$e_{18}$ & $(1,2\\omega,1)$ &
$e_{19}$ & $(\\omega,2\\omega,\\omega^2)$ &
$e_{21}$ & $(1,1,2)$ &
$e_{22}$ & $(\\omega,\\omega^2,2)$ &
$e_{23}$ & $(\\omega^2,\\omega,2)$ &
$e_{24}$ & $(\\omega,\\omega^2,2\\omega^2)$ &
$e_{25}$ & $(\\omega^2,\\omega,2\\omega^2)$ &
$e_{26}$ & $(1,1,2\\omega^2)$ &
$e_{27}$ & $(\\omega^2,\\omega,2\\omega)$ &
$e_{28}$ & $(\\omega,\\omega^2,2\\omega)$ &
$e_{29}$ & $(1,1,2\\omega)$ &
$e_{31}$ & $(2,1,1)$ &
$e_{32}$ & $(2,\\omega,\\omega^2)$ &
$e_{33}$ & $(2,\\omega^2,\\omega)$ &
$e_{34}$ & $(2\\omega^2,1,1)$ &
$e_{35}$ & $(2\\omega^2,\\omega,\\omega^2)$ &
$e_{36}$ & $(2\\omega^2,\\omega^2,\\omega)$ &
$e_{37}$ & $(2\\omega,1,1)$ &
$e_{38}$ & $(2\\omega,\\omega^2,\\omega)$ &
$e_{39}$ & $(2\\omega,\\omega,\\omega^2)$ &
$b_{1121}$ & $(2,-1,1)$ &
$b_{1122}$ & $(2,-\\omega,\\omega^2)$ &
$b_{1123}$ & $(2,-\\omega^2,\\omega)$ &
$b_{1124}$ & $(2,-\\omega,\\omega)$ &
$b_{1125}$ & $(2,-\\omega^2,1)$ &
$b_{1126}$ & $(2,-1,\\omega^2)$ &
$b_{1127}$ & $(2,-\\omega^2,\\omega^2)$ &
$b_{1128}$ & $(2,-\\omega,1)$ &
$b_{1129}$ & $(2,-1,\\omega)$ &
$b_{2121}$ & $(-1,2,1)$ &
$b_{2122}$ & $(-1,2\\omega,\\omega^2)$ &
$b_{2123}$ & $(-1,2\\omega^2,\\omega)$ &
$b_{2124}$ & $(-1,2\\omega,\\omega)$ &
$b_{2125}$ & $(-1,2\\omega^2,1)$ &
$b_{2126}$ & $(-1,2,\\omega^2)$ &
$b_{2127}$ & $(-1,2\\omega^2,\\omega^2)$ &
$b_{2128}$ & $(-1,2\\omega,1)$ &
$b_{2129}$ & $(-1,2,\\omega)$ &
$b_{1131}$ & $(2,1,-1)$ &
$b_{1132}$ & $(2,\\omega,-\\omega^2)$ &
$b_{1133}$ & $(2,\\omega^2,-\\omega)$ &
$b_{1134}$ & $(2,\\omega,-\\omega)$ &
$b_{1135}$ & $(2,\\omega^2,-1)$ &
$b_{1136}$ & $(2,1,-\\omega^2)$ &
$b_{1137}$ & $(2,\\omega^2,-\\omega^2)$ &
$b_{1138}$ & $(2,\\omega,-1)$ &
$b_{1139}$ & $(2,1,-\\omega)$ &
$b_{3131}$ & $(-1,1,2)$ &
$b_{3132}$ & $(-1,\\omega,2\\omega^2)$ &
$b_{3133}$ & $(-1,\\omega^2,2\\omega)$ &
$b_{3134}$ & $(-1,\\omega,2\\omega)$ &
$b_{3135}$ & $(-1,\\omega^2,2)$ &
$b_{3136}$ & $(-1,1,2\\omega^2)$ &
$b_{3137}$ & $(-1,\\omega^2,2\\omega^2)$ &
$b_{3138}$ & $(-1,\\omega,2)$ &
$b_{3139}$ & $(-1,1,2\\omega)$ &
$b_{2231}$ & $(1,2,-1)$ &
$b_{2232}$ & $(1,2\\omega,-\\omega^2)$ &
$b_{2233}$ & $(1,2\\omega^2,-\\omega)$ &
$b_{2234}$ & $(1,2\\omega,-\\omega)$ &
$b_{2235}$ & $(1,2\\omega^2,-1)$ &
$b_{2236}$ & $(1,2,-\\omega^2)$ &
$b_{2237}$ & $(1,2\\omega^2,-\\omega^2)$ &
$b_{2238}$ & $(1,2\\omega,-1)$ &
$b_{2239}$ & $(1,2,-\\omega)$ &
$b_{3231}$ & $(1,-1,2)$ &
$b_{3232}$ & $(1,-\\omega,2\\omega^2)$ &
$b_{3233}$ & $(1,-\\omega^2,2\\omega)$ &
$b_{3234}$ & $(1,-\\omega,2\\omega)$ &
$b_{3235}$ & $(1,-\\omega^2,2)$ &
$b_{3236}$ & $(1,-1,2\\omega^2)$ &
$b_{3237}$ & $(1,-\\omega^2,2\\omega^2)$ &
$b_{3238}$ & $(1,-\\omega,2)$ &
$b_{3239}$ & $(1,-1,2\\omega)$ &";

(* 2. PARSING ------------------------------------------------------- *)
rawLines = StringSplit[latexData, "\n"];
dataLines = Select[rawLines, StringContainsQ[#, "&"] &];

parseData[line_] := Module[{parts, labelRaw, vectorRaw, vecStr, vecVal},
   parts = StringSplit[line, "&"];
   labelRaw = StringTrim[StringReplace[parts[[1]], "$" -> ""]];
   vectorRaw = StringTrim[parts[[2]]];
   vecStr = StringReplace[vectorRaw, {
       "$" -> "", "(" -> "{", ")" -> "}",
       "\\omega" -> "w", " " -> ""
   }];
   vecVal = ToExpression[vecStr];
   {labelRaw, vecVal}
];

parsed = parseData /@ dataLines;
labels = parsed[[All, 1]];
vectors = parsed[[All, 2]];

(* Canonicalize vectors to handle phase scaling *)
canonicalize[v_] := Module[{s = Simplify[v]},
   If[PossibleZeroQ[Norm[s]], s,
     With[{first = FirstCase[s, x_ /; !PossibleZeroQ[x]]},
       Simplify[s / first]
     ]
   ]
];

rays = canonicalize /@ vectors;
NumRays = Length[rays];
Print["Parsed Rays: ", NumRays];

(* 3. GRAPH CONSTRUCTION -------------------------------------------- *)
(* Orthogonality defined by vanishing complex inner product *)
adjMatrix = Table[
   If[i != j && PossibleZeroQ[Simplify[rays[[i]] . Conjugate[rays[[j]]]]], 1, 0],
   {i, NumRays}, {j, NumRays}
];
orthoGraph = AdjacencyGraph[adjMatrix];

(* Identify all 3-element contexts *)
cliques = FindClique[orthoGraph, {3}, All];
NumContexts = Length[cliques];
Print["Original Contexts Found: ", NumContexts];

(* 4. EXACT OPTIMIZATION -------------------------------------------- *)
(* Objective: Maximize the number of satisfied contexts *)
(* Weight = number of contexts a ray appears in (just part of expansion) *)
(* Correct Objective: Sum_{c in cliques} (x_c1 + x_c2 + x_c3) *)
objective = ConstantArray[0, NumRays];
Do[Do[objective[[id]]++, {id, c}], {c, cliques}];

(* Constraints: Sum of orthogonal pairs <= 1 *)
edges = EdgeList[orthoGraph];
m = Table[
    vec = ConstantArray[0, NumRays];
    vec[[First[e]]] = 1;
    vec[[Last[e]]] = 1;
    vec,
    {e, edges}
];
b = Table[{1, -1}, {Length[edges]}]; (* <= 1 *)

(* Solve ILP *)
solution = LinearProgramming[
   -objective,
   m,
   b,
   Table[{0, 1}, {NumRays}],
   Integers
];

MaxSatisfied = Total[solution * objective];
Deficit = NumContexts - MaxSatisfied;

(* 5. OUTPUT -------------------------------------------------------- *)
Print["\n=== PROOF RESULTS ==="];
Print["Total Contexts:      ", NumContexts];
Print["Satisfied Contexts:  ", MaxSatisfied];
Print["Minimum Deficit:     ", Deficit];

If[Deficit == 1,
   Print["\n[!] Result: The system is CRITICAL (Deficit = 1)."],
   Print["\n[!] Result: The system is ROBUST (Deficit > 1)."]
];

Print["\n=== BROKEN CONTEXTS (These sum to 0) ==="];
Do[
  ids = cliques[[c]];
  s = Total[solution[[ids]]];
  If[s == 0,
    Print["Context ", c, ": {", labels[[ids[[1]]]], ", ", labels[[ids[[2]]]], ", ", labels[[ids[[3]]]], "}"]
  ];
, {c, NumContexts}];

Print["\n=== FULL RAY VALUATION ==="];
Print["Index \t Label \t\t Value"];
Do[
  lbl = labels[[i]];
  val = solution[[i]];
  pad = If[StringLength[lbl] < 7, "\t\t", "\t"];
  Print[i, "\t ", lbl, pad, val];
, {i, NumRays}];




~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~



Response to the First Referee Report

We thank the referee for their constructive criticism and for identifying specific areas where the presentation, notation, and pedagogical structure of the manuscript could be improved. We have revised the manuscript extensively to address every point raised in the report. Below is a point-by-point description of the changes.

1. Equation (7) and missing phase dependence
The referee noted that the phase $\theta_k$ was absent from Eq. (7) (in the previous version) and requested an explicit gauge choice or reintroduction of the phase.

Response: We have clarified the text immediately following Eq. (7) (now Eq. 8/9 in the revised text). We added an explicit explanation regarding the gauge freedom: "Note that changing $\theta_k$ shifts both forbidden values... reflecting the overall phase (gauge) freedom in the choice of ray representatives." This clarifies that while the specific forbidden angles shift with $\theta_k$, the condition for finding a valid $\theta_\ell$ remains structurally the same.

2. Undefined notation $S^1$
The symbol $S^1$ was previously used without definition.

Response: In Section II.C, we have added the phrase "...where $S^1$ denotes the unit circle" at the first occurrence of the symbol.

3. Meaning of $S^1 \setminus F_m$
The referee pointed out that this set notation required explanation for broader accessibility.

Response: In Section II.C, we have inserted the explanatory clause: "...that is, from the set of admissible phase values excluding the finite forbidden set $F_m$."

4. Wording above Eq. (9) ("Induction in m...")
The phrasing regarding the inductive proof was flagged as terse.

Response: We have replaced the sentence with the exact formulation suggested by the referee. The text in Section II.C now reads: "Proceeding by induction on $m$, we can successively choose the phases $\theta_m$ so that no unwanted orthogonality is introduced..."

5. Abrupt beginning of Section III.A
The referee observed that Section III.A began with definitions without linking back to the general construction in Section II.

Response: We have rewritten the beginning of Section III completely. A new introductory paragraph has been added: "In the previous section we showed in general that any finite family of rays... We now specialise this construction to the concrete Kochen--Specker configuration...". This provides the necessary pedagogical bridge between the abstract existence proof and the specific example.

6. Last paragraph of Section III.A
It was noted that the conclusions regarding the realification mapping were too brief.

Response: We have significantly expanded the final paragraph of Section III.A. We now explicitly discuss the non-uniqueness of the $\mathbb{R}^6$ representation (permutational equivalence) and clarify that the table follows a "canonical gauge." This better explains the conceptual meaning of the mapping used in the subsequent table.

7. Section III.B and the figure
The referee noted that the figure (referencing the orthogonality graph) was mentioned only implicitly.

Response: In Section III.B, we have added explicit text introducing the visualization: "The orthogonality graph of these rays---which visualises the logical structure of the proof---is depicted in Fig. 2 of Ref. [11]...".

8. Redundancy of Eq. (14)
The referee suggested that the equation simply displaying the vector components might be redundant.

Response: We have streamlined the text around the definition of the real image to ensure it serves a clear definition purpose for the table that follows, ensuring it is not merely repetitive but defines the notation used in the table headers.

9. Purpose and scope of Section IV (and the choice of $K=1009$)
The referee found the transition to the specific numerical example (and the unexplained choice of $K=1009$) abrupt and unclear regarding whether it claimed new theoretical results or served as an illustration.

Response: We have clarified the nature of this calculation (which appears at the end of Section III in the revised structure). We explicitly state: "For concreteness, in Table I we provide..." regarding the ray list. Furthermore, regarding the phase denominator $K$, we added the explanation: "...where $K=1009$ stands for some nonunique large integer (we choose a large prime number)... We verified the existence of such phases numerically...". This clarifies that $K=1009$ is an arbitrary choice made for the sake of providing a concrete, verifiable example, rather than a unique theoretical constant.

Additional Changes:
While not explicitly requested, we have also updated the Introduction to include a broader range of references (e.g., Renou et al., Weilenmann et al.) to better contextualize the work within the recent literature on the logical inequivalence of real and complex quantum theories.

We believe these revisions significantly improve the readability and pedagogical value of the paper, addressing all concerns raised in the report.

__________________________________________________________________________

Response to the Second Referee

We are deeply grateful to the Second Referee for an exceptionally thorough, constructive, and insightful report. The Referee provided a clear roadmap for reframing the paper to better align with the current literature on real vs. complex quantum mechanics, specifically regarding the classification of "divides" (system-dependent, basis-independent, etc.) and the interpretation of our results not merely as a witness of inequivalence, but as a demonstration that orthogonality relations alone are insufficient to distinguish the theories.

We have implemented major revisions throughout the manuscript to address every point raised. Below is a detailed point-by-point response.

1. Motivation and Literature References (Introduction)

Referee Critique: The Referee criticized the citation of a Quanta Magazine article as a primary reference, noting it misrepresented the scientific debate (e.g., the status of Renou et al.). The Referee also noted that citing McKague et al. as "evidence" of inequivalence was misleading, as that paper actually proves simulation (equivalence). The Referee provided two lists of suggested references to correct this.

Response: We fully agree. We have removed the citation to Quanta Magazine and the misleading citation context for McKague et al. We have completely rewritten the first three paragraphs of the Introduction to incorporate the suggested references and the nuanced view requested by the Referee.

Changes:
   We now cite the original scientific works suggested: Renou et al. (Nature 2021), Weilenmann et al. (arXiv:2502.20102), Hoffreumon & Woods, Hita et al., Ying et al., Hardy & Wootters, Stueckelberg, Bednorz & Batle, Aleksandrova et al., Wootters, McKague et al., and Erba & Perinotti.
   We have reorganized the discussion to distinguish between:
    1.  The fact that real formulations are possible under certain assumptions (citing Stueckelberg, McKague).
    2.  The fact that real theory is operationally sufficient for many tasks (citing Wootters, Aleksandrova).
    3.  The fact that under specific structural assumptions (locality, tensor products), real theory is falsifiable (citing Renou, Weilenmann, etc.).

2. Structuring the Argument (Introduction)

Referee Critique: The Referee pointed out that the Introduction was confusing regarding what the "argument" addresses, blending different types of distinctions. The Referee suggested distinguishing between "Assumptions," "Operational Sufficiency," and "Pragmatic Approaches."

Response: We have adopted this structure explicitly.

Changes: The Introduction now reads (paraphrased): "It is therefore useful to distinguish three viewpoints: (i) whether quantum theory can be formulated over the reals depends on assumptions... (ii) for a large class of tasks... real quantum theory is sufficient; (iii) there are pragmatic, representation-focused approaches... Our work falls into this third category."

3. Connection of MUBs and References

Referee Critique: The sentence about MUBs was disconnected from the preceding text, and claims about the existence of MUBs in $\mathbb{C}^3$ vs $\mathbb{R}^3$ lacked references.

Response: We have connected the sentences and added standard references for MUBs (e.g., Durt et al., McNulty et al.).

Changes: The text now flows directly from the discussion of the Yu-Oh-Cabello configuration to the MUB properties that define it, with citations backing the claim that $\mathbb{R}^3$ cannot support two mutually unbiased bases.

4. Framing of Results: "System-Dependent" Divide

Referee Critique: The Referee noted that Result 1 (impossibility in $\mathbb{R}^3$) is not a novel fundamental result but a known consequence of fixing dimensions. The Referee suggested determining whether the result is "System-dependent" (fixed dimension) and "Basis-independent."

Response: This was a very helpful classification. We have adopted this terminology to precisely scope our contribution.

Changes: In the Introduction and Discussion, we now state: "Our argument is, in this sense, system-dependent but basis-independent: it singles out a specific three-dimensional configuration... yet the statement does not depend on any preferred basis."

5. Re-interpreting the Main Result: Orthogonality is Insufficient

Referee Critique: The Referee disagreed with our claim that the embedding is a "witness of inequivalence." Instead, the Referee argued the stronger and more correct interpretation is that orthogonality relations alone cannot indicate a divide between real and complex theory, because any complex graph can be embedded in a real space (as we showed).

Response: We have fundamentally shifted the narrative of the paper to align with this interpretation. We no longer claim the embedding itself witnesses inequivalence; rather, we contrast the logical inequivalence (KS uncolourability) in $\mathbb{C}^3$ with the admissibility of the same orthogonality graph in $\mathbb{R}^6$.

Changes:
   Abstract: Now emphasizes that the embedding yields a faithful representation but "admits two-valued states even though its realisation with maximal contexts in $\mathbb{C}^3$ is Kochen--Specker uncolourable."
   Discussion: We added a new conclusion: "This highlights a nuanced picture... our phase-adjusted realification shows that orthogonality relations alone do not separate real from complex quantum theory, since any finite orthogonality hypergraph... admits a faithful orthogonal representation in a suitable real Hilbert space."

6. Technical Corrections

Referee Critique:
(a) Mention "abelian gauge freedom" regarding phases.
(b) Fix syntax in the sentence "Since the real part..."
(c) Fix notation inconsistency ($R$ vs $w$).
(d) Use the term "valuation."

Response:
(a) Section II: Added: "In the physics literature this invariance under multiplication by a global phase... is often referred to as an (abelian) gauge freedom."
(b) Section II: Fixed the sentence structure to: "Note that the real part of the complex inner product is exactly the real dot product..."
(c) Section III: We standardized the notation to $R_k$ for the real vectors throughout the text and table.
(d) Section IV: Added: "...impossibility of assigning a two-valued state (also called a valuation)..."

Summary
We believe the manuscript now tells a much clearer and physically grounded story: that while specific logical structures (like KS configurations) are dimension-dependent and separate real vs. complex theory when contexts are fixed as maximal, the orthogonality relations themselves carry no such signature because they can always be faithfully embedded in higher-dimensional real spaces. We thank the Referee again for guiding us toward this stronger framing.


We have also changed the title to "Faithful real embedding of a three-dimensional complex Kochen-Specker configuration".
