Papers
Topics
Authors
Recent
Search
2000 character limit reached

Double Port Graphs in Quantum-Classical Computation

Updated 5 July 2026
  • Double port graphs are an extension of port graphs featuring dual wiring systems for quantum and classical flows, ensuring acyclicity via totalisation.
  • They form a strict double category with horizontal and vertical compositions that capture adaptive computational processes.
  • Their semantic mapping to adaptive instruments unifies various computational models and supports contextuality analysis in quantum-classical settings.

Searching arXiv for the cited papers and closely related background to ground the article. Double port graphs are a double-categorical generalization of port graphs introduced to represent adaptive quantum computation with explicit separation between quantum and classical information flow. In this framework, a diagram has a shared vertex set equipped with two port-graph structures: a horizontal one, intended for quantum wires, and a vertical one, intended for classical wires. The defining condition is that the totalisation obtained by combining both directions is acyclic, so the combined quantum-classical dependency structure respects causal order. This formalism was developed as part of a unified account of circuit, measurement-based, magic-state, and measurement-based Pauli computation models, together with a semantics in terms of adaptive instruments and a contextuality analysis via simplicial instruments (Okay et al., 29 Oct 2025). A distinct graph-theoretic notion, the class of doubled graphs arising from double-split graphs in perfect graph theory, is unrelated except for the lexical similarity of the word “double” (Alexeev et al., 2010).

1. Definition and formal construction

The starting point is the ordinary notion of a port graph. An (m,n)(m,n)-pre-port graph Γ\Gamma consists of a finite set of vertices XX, linearly ordered input and output port sets at each vertex, and a bijection

ι:m⨿OI⨿n,\iota : \underline{m} \amalg O \longrightarrow I \amalg \underline{n},

where O=xXout(x)O=\coprod_{x\in X}\mathrm{out}(x) and I=xXin(x)I=\coprod_{x\in X}\mathrm{in}(x). The associated internal flow graph has vertices X⨿n⨿mX\amalg \underline{n}\amalg \underline{m} and edges m⨿O\underline{m}\amalg O, with sources and targets determined by the local ports and the wiring bijection. A port graph is then a pre-port graph whose internal flow graph is acyclic (Okay et al., 29 Oct 2025).

A 2-fold port graph consists of a pair (Γv,Γh)(\Gamma_v,\Gamma_h) of port graphs with the same vertex set XX. The interpretation given in the source is geometric and computational: Γ\Gamma0 is the horizontal structure, drawn with solid wires and intended to represent quantum flow, while Γ\Gamma1 is the vertical structure, drawn with dashed wires and intended to represent classical flow (Okay et al., 29 Oct 2025).

The passage from a 2-fold port graph to a double port graph is governed by totalisation. For each vertex Γ\Gamma2, one forms

Γ\Gamma3

using ordinal sum on finite linearly ordered sets. The two wiring bijections are then merged into a single bijection defining an Γ\Gamma4-pre-port graph Γ\Gamma5. A double port graph is precisely a 2-fold port graph whose totalisation is an acyclic port graph (Okay et al., 29 Oct 2025).

This condition is the central structural constraint. It means that although quantum and classical dependencies are represented in different directions, no directed cycle may arise when the two are viewed together. The source states that this is the formal encoding of causal or temporal order for adaptive computations: one obtains a partial order of boxes compatible with both quantum and classical dependencies (Okay et al., 29 Oct 2025).

2. Double-category structure

Double port graphs form a strict double category Γ\Gamma6 with a single object Γ\Gamma7, horizontal and vertical 1-cells both given by Γ\Gamma8, and 2-cells given by isomorphism classes of double port graphs of the appropriate boundary type (Okay et al., 29 Oct 2025). The boundary counts record, respectively, the numbers of horizontal and vertical wires entering and leaving the square.

Two compositions are defined. Horizontal composition composes quantum wires: Γ\Gamma9 where the horizontal part is composed by port-graph concatenation and the vertical part is juxtaposed by disjoint union. Vertical composition composes classical wires: XX0 so now the vertical part is concatenated and the horizontal part is juxtaposed (Okay et al., 29 Oct 2025).

These operations are associative and unital up to isomorphism at the port-graph level, and the authors summarize the resulting structure as a strict double category. The unit is the empty-vertex port graph with matching boundary, and the double port graph condition is preserved under both compositions (Okay et al., 29 Oct 2025).

Conceptually, XX1 is a purely combinatorial double category of wiring diagrams with two distinct directions of composition. The horizontal direction records one mode of process connectivity and the vertical direction records another, with the intended reading in the computational applications being quantum versus classical flow (Okay et al., 29 Oct 2025).

3. Labels, syntax, and pasting

To attach computational meaning to vertices, the theory introduces port labels. A set XX2 of labels is equipped with four arity functions

XX3

assigning to each label its numbers of horizontal inputs, horizontal outputs, vertical inputs, and vertical outputs. An XX4-labeled double port graph is a double port graph together with a labeling XX5 such that the number of ports at each vertex matches the specified arities (Okay et al., 29 Oct 2025).

For every label set XX6, one obtains a double category XX7 whose 2-cells are isomorphism classes of XX8-labeled double port graphs. A morphism of label sets XX9 respecting the four arity maps induces a double functor

ι:m⨿OI⨿n,\iota : \underline{m} \amalg O \longrightarrow I \amalg \underline{n},0

by relabeling vertices. The paper packages this as a functor

ι:m⨿OI⨿n,\iota : \underline{m} \amalg O \longrightarrow I \amalg \underline{n},1

from port label sets to double categories (Okay et al., 29 Oct 2025).

A central operation is pasting. If a double port graph has vertices labeled by squares of another double category ι:m⨿OI⨿n,\iota : \underline{m} \amalg O \longrightarrow I \amalg \underline{n},2, each such label can be expanded into a representative labeled double port graph and inserted at the corresponding vertex. The resulting object is again a double port graph, and this construction yields a double functor

ι:m⨿OI⨿n,\iota : \underline{m} \amalg O \longrightarrow I \amalg \underline{n},3

Combined with a labeling ι:m⨿OI⨿n,\iota : \underline{m} \amalg O \longrightarrow I \amalg \underline{n},4, this gives a composite double functor ι:m⨿OI⨿n,\iota : \underline{m} \amalg O \longrightarrow I \amalg \underline{n},5 that implements expansion of high-level gadgets into lower-level primitives (Okay et al., 29 Oct 2025).

This pasting mechanism is the formal basis for translations between computational models. The source explicitly states that it is used for translation of circuit gates into MBQC patterns, translation of circuit gates into magic-state gadgets, and translation from MBPC to QCM (Okay et al., 29 Oct 2025). A plausible implication is that the formalism is designed not merely to draw computations, but to support compositional compilation.

4. Semantics via adaptive instruments

The semantic target for double port graphs is a double category of adaptive instruments. For finite-dimensional Hilbert spaces ι:m⨿OI⨿n,\iota : \underline{m} \amalg O \longrightarrow I \amalg \underline{n},6, ι:m⨿OI⨿n,\iota : \underline{m} \amalg O \longrightarrow I \amalg \underline{n},7 denotes completely positive linear maps ι:m⨿OI⨿n,\iota : \underline{m} \amalg O \longrightarrow I \amalg \underline{n},8. An instrument with outcome set ι:m⨿OI⨿n,\iota : \underline{m} \amalg O \longrightarrow I \amalg \underline{n},9 is a function O=xXout(x)O=\coprod_{x\in X}\mathrm{out}(x)0 such that O=xXout(x)O=\coprod_{x\in X}\mathrm{out}(x)1 is a channel. The adaptive version used in the paper is a square

O=xXout(x)O=\coprod_{x\in X}\mathrm{out}(x)2

such that for each O=xXout(x)O=\coprod_{x\in X}\mathrm{out}(x)3,

O=xXout(x)O=\coprod_{x\in X}\mathrm{out}(x)4

is a channel (Okay et al., 29 Oct 2025).

The associated double category O=xXout(x)O=\coprod_{x\in X}\mathrm{out}(x)5 has a single object O=xXout(x)O=\coprod_{x\in X}\mathrm{out}(x)6, vertical 1-cells given by Hilbert spaces, horizontal 1-cells given by sets, and 2-cells given by adaptive instruments. Horizontal composition is sequential composition of channels,

O=xXout(x)O=\coprod_{x\in X}\mathrm{out}(x)7

while vertical composition is parallel tensor composition followed by summation over shared classical outcomes,

O=xXout(x)O=\coprod_{x\in X}\mathrm{out}(x)8

(Okay et al., 29 Oct 2025).

For qubit systems and Boolean classical spaces, the paper restricts to the full sub-double-category O=xXout(x)O=\coprod_{x\in X}\mathrm{out}(x)9, whose squares have qubit Hilbert spaces I=xXin(x)I=\coprod_{x\in X}\mathrm{in}(x)0 and classical spaces I=xXin(x)I=\coprod_{x\in X}\mathrm{in}(x)1. In this setting,

I=xXin(x)I=\coprod_{x\in X}\mathrm{in}(x)2

so the horizontal category recovers qubit channels and the vertical category recovers the Kleisli category on Boolean spaces (Okay et al., 29 Oct 2025).

Semantics is then assigned by mapping labels to squares of I=xXin(x)I=\coprod_{x\in X}\mathrm{in}(x)3 and evaluating labeled double port graphs by pasting. The paper gives double functors

I=xXin(x)I=\coprod_{x\in X}\mathrm{in}(x)4

for several label sets I=xXin(x)I=\coprod_{x\in X}\mathrm{in}(x)5, including Boolean computation, circuit computation, MBQC, magic-state computation, and MBPC (Okay et al., 29 Oct 2025). Under these functors, a double port graph is interpreted as an adaptive instrument, i.e. as a concrete quantum-classical process.

5. Quantum and classical flow in adaptive computation

The principal conceptual contribution of double port graphs is the explicit geometric separation of quantum and classical flow. The horizontal direction is identified with quantum flow, represented by solid wires and composed as quantum channels. The vertical direction is identified with classical flow, represented by dashed wires and composed as stochastic maps encoded via the distribution monad (Okay et al., 29 Oct 2025).

This differs from standard string-diagrammatic approaches in categorical quantum mechanics, where both quantum and classical information typically inhabit a single diagrammatic dimension and classicality is handled by additional algebraic structure. Here the distinction is built directly into the two-dimensional shape of the diagram (Okay et al., 29 Oct 2025).

A basic box in the formalism has left and right solid boundaries for quantum input and output, and top and bottom dashed boundaries for classical input and output. Formally it is a square in I=xXin(x)I=\coprod_{x\in X}\mathrm{in}(x)6 representing an adaptive instrument I=xXin(x)I=\coprod_{x\in X}\mathrm{in}(x)7 (Okay et al., 29 Oct 2025). Adaptivity is expressed by dashed wires connecting the output of one box to the input of another, so that a classical outcome controls a later quantum operation or measurement basis.

The acyclicity of the totalisation forbids feedback loops that would violate causal order. The source emphasizes that one cannot use the outputs of a box to control a box earlier in the quantum flow, or earlier through some classical path (Okay et al., 29 Oct 2025). This makes double port graphs especially suited to measurement-based and adaptive architectures, in which classical side-processing and quantum evolution interleave.

6. Representation of computational models

The formalism is used to define several syntactic double categories corresponding to standard computational models. Specific label sets are introduced for Boolean circuits I=xXin(x)I=\coprod_{x\in X}\mathrm{in}(x)8, quantum circuits I=xXin(x)I=\coprod_{x\in X}\mathrm{in}(x)9, MBQC X⨿n⨿mX\amalg \underline{n}\amalg \underline{m}0, magic-state computation X⨿n⨿mX\amalg \underline{n}\amalg \underline{m}1, and MBPC X⨿n⨿mX\amalg \underline{n}\amalg \underline{m}2, leading to double categories such as X⨿n⨿mX\amalg \underline{n}\amalg \underline{m}3, X⨿n⨿mX\amalg \underline{n}\amalg \underline{m}4, X⨿n⨿mX\amalg \underline{n}\amalg \underline{m}5, and X⨿n⨿mX\amalg \underline{n}\amalg \underline{m}6 (Okay et al., 29 Oct 2025).

For Boolean computation, the vertical direction suffices. The Boolean label set contains X⨿n⨿mX\amalg \underline{n}\amalg \underline{m}7-state, delete, xor, or, and copy, and its interpretation has trivial quantum part and purely classical stochastic semantics. When restricted to X⨿n⨿mX\amalg \underline{n}\amalg \underline{m}8, the image is exactly the category X⨿n⨿mX\amalg \underline{n}\amalg \underline{m}9 of affine Boolean maps over m⨿O\underline{m}\amalg O0 (Okay et al., 29 Oct 2025).

For quantum circuits, the label set m⨿O\underline{m}\amalg O1 contains m⨿O\underline{m}\amalg O2, m⨿O\underline{m}\amalg O3, m⨿O\underline{m}\amalg O4, m⨿O\underline{m}\amalg O5, and m⨿O\underline{m}\amalg O6. The associated semantics functor

m⨿O\underline{m}\amalg O7

interprets these as the corresponding preparations, unitaries, entangling gates, and measurements. The horizontal monoidal category of the image is the subcategory of m⨿O\underline{m}\amalg O8 whose morphisms are unitaries generated by these gates, and by Solovay–Kitaev this is dense in all unitaries m⨿O\underline{m}\amalg O9 on qubit Hilbert spaces (Okay et al., 29 Oct 2025). The vertical monoidal category is (Γv,Γh)(\Gamma_v,\Gamma_h)0, reversible classical computation with probabilistic interpretation (Okay et al., 29 Oct 2025).

For MBQC and magic-state models, analogous label sets and semantics are provided. The paper states that (Γv,Γh)(\Gamma_v,\Gamma_h)1 includes (Γv,Γh)(\Gamma_v,\Gamma_h)2, (Γv,Γh)(\Gamma_v,\Gamma_h)3-corrections (Γv,Γh)(\Gamma_v,\Gamma_h)4, and angle measurements (Γv,Γh)(\Gamma_v,\Gamma_h)5, while (Γv,Γh)(\Gamma_v,\Gamma_h)6 includes magic state preparation (Γv,Γh)(\Gamma_v,\Gamma_h)7, entangling (Γv,Γh)(\Gamma_v,\Gamma_h)8, corrections (Γv,Γh)(\Gamma_v,\Gamma_h)9, non-destructive measurement XX0, and trace (Okay et al., 29 Oct 2025). These models appear as double subcategories XX1.

A key feature is functorial model conversion. The paper exhibits double functors such as

XX2

with commuting semantics

XX3

(Okay et al., 29 Oct 2025). Thus conversion between syntactic models preserves the global adaptive instrument.

7. Contextuality, simplicial instruments, and computational power

The framework extends beyond syntax and ordinary semantics to a contextuality theory for adaptive computation. The paper upgrades instruments from sets to simplicial sets by defining a simplicial instrument as a simplicial map

XX4

where XX5 is first defined on sets by sending XX6 to the set of instruments XX7, and then extended levelwise to simplicial sets (Okay et al., 29 Oct 2025). This yields another one-object double category XX8, whose horizontal category is again XX9 and whose vertical category is the Kleisli category Γ\Gamma00 of simplicial distributions (Okay et al., 29 Oct 2025).

A simplicial distribution is a Kleisli arrow Γ\Gamma01. It is non-contextual if it lies in the image of the convex map

Γ\Gamma02

and strongly contextual if its support is empty in the sense stated in the source (Okay et al., 29 Oct 2025). The non-contextual fraction and contextual fraction are defined by

Γ\Gamma03

(Okay et al., 29 Oct 2025).

The relevant adaptive scenarios are encoded using Bell instruments and simplicial sets built from joins of Γ\Gamma04. For an Γ\Gamma05-qubit Bell instrument Γ\Gamma06 and a state Γ\Gamma07, one obtains a simplicial distribution

Γ\Gamma08

via the Born rule (Okay et al., 29 Oct 2025). This provides a bridge from double-port-graph-based computation to contextuality measures.

The main computational result gives a quantitative bound. For a Boolean function Γ\Gamma09, an Γ\Gamma10-qubit state Γ\Gamma11, an Γ\Gamma12-Bell instrument Γ\Gamma13, and an affine Boolean post-processing map Γ\Gamma14, the average success probability satisfies

Γ\Gamma15

where Γ\Gamma16 is the distance from Γ\Gamma17 to the affine Boolean functions (Okay et al., 29 Oct 2025). The paper states the corollaries explicitly: if the underlying simplicial distribution is non-contextual, then deterministic computation forces Γ\Gamma18 to be affine; if Γ\Gamma19 is non-affine and the computation is perfect, then the simplicial distribution must be strongly contextual (Okay et al., 29 Oct 2025).

Within this analysis, double port graphs serve as the syntactic description of adaptive MBPC protocols whose semantic interpretation yields the instruments entering the contextuality theorem. This suggests that their role is not limited to diagrammatic convenience: they provide the combinatorial interface between model syntax, operational semantics, and resource-theoretic constraints.

8. Relation to graph theory and terminological disambiguation

The term “double port graph” should be distinguished sharply from graph-theoretic notions involving double-split or doubled graphs. In perfect graph theory, a double-split graph is a graph whose vertex set is partitioned into matched and antimatched parts satisfying an alignment condition, and a doubled graph is an induced subgraph of a double-split graph (Alexeev et al., 2010). That theory culminates in a forbidden induced subgraph characterization with 44 minimal obstructions for doubled graphs (Alexeev et al., 2010).

Despite superficial lexical overlap, the two subjects differ in ontology, motivation, and formalism. The graph-theoretic doubled graphs of perfect graph theory are finite simple graphs studied through induced subgraphs, complements, and obstruction sets (Alexeev et al., 2010). By contrast, double port graphs are 2-fold port graphs with total acyclicity, organized as 2-cells of a strict double category and used to model adaptive quantum-classical computation (Okay et al., 29 Oct 2025).

This distinction matters because both theories use the word “double” structurally, but only the latter uses ports, directional wiring, double-categorical composition, and semantics in adaptive instruments. A plausible implication is that the phrase “double port graph” is best reserved for the categorical-computational notion, while “doubled graph” should be retained for the induced-subgraph closure of double-split graphs in perfect graph theory.

Definition Search Book Streamline Icon: https://streamlinehq.com
References (2)

Topic to Video (Beta)

No one has generated a video about this topic yet.

Whiteboard

No one has generated a whiteboard explanation for this topic yet.

Follow Topic

Get notified by email when new papers are published related to Double Port Graphs.