Bipartiteness as an existential second-order query #
The graph vocabulary describes arbitrary directed graphs, including loops. A bipartition assigns a Boolean color to each vertex, with different colors at the ends of every directed edge. Symmetry is not required; a loop prevents a coloring.
The sentence ∃X ∀x ∀y (E(x,y) → (X(x) ↔ ¬X(y))) defines this query.
This is the example in Senellart and Gnatenko (2026), Section 2.1,
https://arxiv.org/abs/2609.18261. We prove agreement with an ordinary Boolean
coloring, rather than defining the query as satisfaction of its witness.
No NP membership or hardness statement is claimed here.
checkBipartition executes the matrix on a supplied Boolean coloring and is
proved to accept exactly the colorings separating every directed edge.
The general binary certificate checker agrees with it when the certificate
lists the vertex colors, one bit per vertex.
There is an edge from x to y in a graph structure.
Equations
- Complexity.DescriptiveComplexity.GraphQuery.Edge A x y = A.rel 0 fun (i : Fin (Complexity.DescriptiveComplexity.Vocabulary.graph.relArity 0)) => if i = 0 then x else y
Instances For
A Boolean coloring separates the endpoints of every directed edge.
Equations
- Complexity.DescriptiveComplexity.GraphQuery.Bipartite A = ∃ (color : Fin A.card → Bool), ∀ (x y : Fin A.card), Complexity.DescriptiveComplexity.GraphQuery.Edge A x y → color x ≠ color y
Instances For
A graph without edges has a constant Boolean coloring.
A self-loop rules out a Boolean bipartition.
The open FO matrix: adjacent vertices disagree on the unary relation variable.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Guess one unary relation, then check every pair of vertices.
Equations
Instances For
This witness has one existential SO quantifier and an FO matrix.
Semantics of the open matrix, independent of the choice of variable environment.
The logical witness defines exactly the Boolean-coloring query.
Bipartiteness is existential second-order definable.
Check a supplied Boolean bipartition by evaluating the sentence's FO matrix.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The executable witness checker accepts exactly the proper Boolean colorings.
A graph is bipartite exactly when the executable checker accepts some coloring.
The binary certificate for bipartiteness is exactly one color bit per vertex.
The binary certificate checker characterizes the ordinary bipartite-graph language.
Relabeling vertices preserves bipartiteness.
Every query FO-reducible to bipartiteness has an existential SO witness.