Papers
Topics
Authors
Recent
2000 character limit reached

Twin-width: Graph Complexity Parameter

Updated 16 November 2025
  • Twin-width is defined through controlled vertex contractions on edge-colored trigraphs, quantifying graph complexity and generalizing classical width measures.
  • It underpins meta-theorems that guarantee fixed-parameter tractability for first-order logic model checking in various dense and sparse graph classes.
  • Twin-width extends to matrices, posets, and Cayley graphs, with ongoing research addressing efficient computation, approximation, and structural characterizations.

Twin-width is a structural graph parameter introduced by Bonnet, Kim, Thomassé, and Watrigant in 2020 as a means of quantifying graph complexity under the lens of controlled contraction sequences. Defined via edge-colored trigraphs and iterative contractions, twin-width generalizes and subsumes numerous classical width measures, underpinning robust algorithmic meta-theorems—notably fixed-parameter tractability for first-order logic model checking on classes of bounded twin-width when a certificate (contraction sequence) is provided. Since its inception, the theory of twin-width has developed rapidly, encompassing combinatorial, algorithmic, and model-theoretic perspectives, and extending to graphs, matrices, posets, group Cayley graphs, triangulations of manifolds, and random structures.

1. Formal Definition and Foundational Properties

For a finite simple graph G=(V,E)G=(V,E), the canonical approach to twin-width operates with trigraphs: for each contraction, a merged vertex may create new "red" edges when its incident black-edge neighborhoods disagree, tracking the non-homogeneity introduced by merges. Formally, a trigraph G=(V,B,R)G=(V,B,R) has disjoint sets of black edges BB and red edges RR. A contraction of two distinct vertices u,vu,v replaces them by ww; for every other vertex xx, the edge wxwx is black iff uxux and vxvx were both black, is absent if neither uxux nor vxvx was present, and is red otherwise.

A contraction sequence is a series of such trigraphs

Gn=GGn1G1=K1G_n=G \to G_{n-1} \to \cdots \to G_1=K_1

where each Gi1G_{i-1} is obtained from GiG_i by a contraction. The width of a sequence is the maximum red-degree, i.e., the largest number of red edges incident to any vertex in any intermediate trigraph. The twin-width of GG, denoted tww(G)\operatorname{tww}(G), is the minimum dd for which there exists a contraction sequence of width dd. Equivalent definitions exist via labeled adjacency matrices and merges of rows/columns or, for matrices in general, symmetric contraction sequences ensuring at most dd red entries per row or column at every step.

Fundamental properties include:

  • Bounded twin-width is preserved under induced subgraphs, FO interpretations, and transductions.
  • In numerous natural classes (cographs, trees, planar graphs, minor-closed classes, bounded clique-width/rank-width classes), twin-width is bounded by small explicit constants or functions of structural parameters.
  • For trees, tww(T)2\operatorname{tww}(T) \leq 2 and for cographs, tww(G)=0\operatorname{tww}(G)=0.

2. Algorithmic and Model-Theoretic Implications

A principal motivation for twin-width is its powerful algorithmic applications. The main meta-theorem states that, for any graph GG with twin-width dd and a given dd-contraction sequence, first-order logic (FO) model checking can be solved in time f(d,φ)V(G)f(d,|\varphi|)\cdot |V(G)| for any FO sentence φ\varphi (with ff super-exponential but independent of GG) (Bonnet et al., 2020). This result not only generalizes tractability for bounded tree-width and clique-width classes, but crucially applies to dense graph classes ruled out by those parameters (e.g., certain unit ball graphs, map graphs, proper minor-closed classes, posets of bounded width) (Bonnet et al., 2020, Balabán et al., 2021).

Extensions of this framework accommodate richer logics (FO with modular counting, i.e., FO+MOD), under which model checking remains FPT given a contraction sequence certifying bounded twin-width (Bonnet et al., 2022).

Further, twin-width is tightly linked via FO transduction to small permutation classes:

  • A hereditary class of graphs (or binary relational structures) has bounded twin-width if and only if it is an FO transduction of a proper permutation class (Bonnet et al., 2021).
  • All bounded twin-width classes are "small", i.e., the number of labeled nn-vertex graphs in the class grows at most exponentially in nn.

3. Structural Bounds, Relationships, and Separations

Upper and Lower Bounds

Twin-width admits general upper bounds in terms of n=V(G)n=|V(G)| and m=E(G)m=|E(G)|:

  • For all nn-vertex graphs: tww(G)<n+nlnn+n+2lnn2\operatorname{tww}(G) < \frac{n + \sqrt{n\ln n} + \sqrt{n} + 2\ln n}{2} (Ahn et al., 2021).
  • For mm-edge graphs: tww(G)<3m+O(m1/4lnm)\operatorname{tww}(G) < \sqrt{3m} + O(m^{1/4}\sqrt{\ln m}).

Dense constructions such as conference and Paley graphs yield optimal lower bounds: if GG is a conference graph of order nn, then tww(G)=n12\operatorname{tww}(G) = \frac{n-1}{2} (Ahn et al., 2021, Heinrich et al., 3 Apr 2025). For random graphs G(n,p)G(n,p) with pp constant in (0,1)(0,1), tww(G(n,p))\operatorname{tww}(G(n,p)) is sharply concentrated at 2p(1p)nΘ(nlnn)2p(1-p)n - \Theta(\sqrt{n\ln n}), with a phase transition in typical value at p0.4013p^*\approx 0.4013 (Ahn et al., 2022).

Relationship to Classical Width Parameters

Twin-width is generally incomparable with tree-width, clique-width, and rank-width but is always bounded above by a function of clique-width and rank-width, notably via Boolean-width (Bonnet et al., 2020, Bonnet et al., 2021). Strikingly, tww(G)\operatorname{tww}(G) can be exponential in tw(G)\operatorname{tw}(G); there exist graphs with treewidth tt and twin-width >2(1ε)t>2^{(1-\varepsilon)t} for any t1/εt\gg 1/\varepsilon (Bonnet et al., 2022). For strong tree-width stw(G)\operatorname{stw}(G), tww(G)2stw(G)\operatorname{tww}(G) \leq 2\operatorname{stw}(G) (Heinrich et al., 2023).

For decompositions:

  • In a block-cut tree, tww(G)\operatorname{tww}(G) is bounded by the maximum twin-width of the blocks plus 2.
  • For tree decompositions of adhesion kk and bag width ww, tww(G)32k1+max{wk1,0}\operatorname{tww}(G)\le 3\cdot 2^{k-1} + \max\{w-k-1, 0\} (Heinrich et al., 2023).

For posets of width dd, tww(P)9d\operatorname{tww}(P)\le 9d and this is tight up to a constant factor (Balabán et al., 2021).

Minor-Closed and Bounded-Genus Classes

Graphs embeddable on a surface of Euler genus gg have tww(G)1847g+O(1)\operatorname{tww}(G)\le 18\sqrt{47g}+O(1)—this is tight up to constants; for planar graphs, the sharp bound is 8 and there exist planar graphs with twin-width 7 (Hliněný et al., 2022, Kráľ et al., 2023). Every compact dd-dimensional smooth manifold admits a triangulation whose dual graph has twin-width dO(d)d^{O(d)}; in contrast, their dual graphs can have arbitrarily large treewidth when d3d\ge3 (Bonnet et al., 2024).

4. Twin-width in Sparse, Regular, and Random Graphs

Twin-width displays subtle behavior in bounded-degree and sparse graphs. Cubic and near-regular graphs can exhibit unbounded twin-width; yet no explicit cubic graph has been constructed with tww>4\operatorname{tww}>4, and the most "extremal" examples are highly asymmetric and of large girth (Heinrich et al., 3 Apr 2025). For dd-degenerate graphs, deterministic contraction sequences of width at most 2dn+2d\sqrt{2dn}+2d exist. Circulant graphs satisfy tww(G)3Δ(G)+1\operatorname{tww}(G)\le3\Delta(G)+1.

For random graphs G(n,p)G(n,p), sharp results include (Ahn et al., 2022, Ahn et al., 2021):

  • For p<p1/2p^* < p \leq 1/2, tww(G(n,p))=2p(1p)nΘ(nlnn)\operatorname{tww}(G(n,p)) = 2p(1-p)n - \Theta(\sqrt{n\ln n}).
  • For pn4/3p\ll n^{-4/3}, tww(G(n,p))=0\operatorname{tww}(G(n,p))=0; for n4/3pn7/6n^{-4/3}\ll p\ll n^{-7/6}, tww(G(n,p))=1\operatorname{tww}(G(n,p))=1; for n7/6pc/nn^{-7/6}\ll p\le c/n, tww(G(n,p))=2\operatorname{tww}(G(n,p))=2.
  • For (726lnn)/np1/2(726\ln n)/n \leq p\leq 1/2, tww(G(n,p))=Θ(np)\operatorname{tww}(G(n,p))=\Theta(n\sqrt{p}).

5. Algorithmic Aspects: Computation and Approximation

Exact and Approximate Algorithms

  • Determining the exact value of tww(G)\operatorname{tww}(G) is NP-complete for d4d\ge4 (Arhire et al., 9 Nov 2025).
  • UAIC_Twin_Width (Arhire et al., 9 Nov 2025) presents an exact dynamic programming algorithm and a complementary greedy+hill-climbing heuristic, ranking among top solvers in the PACE 2023 Challenge. Key engineering optimizations include twin detection, aggressive upper/lower bound pruning, state-sharing, and local search.
  • SAT-based encodings for twin-width via dd-elimination (contraction) sequences allow exact computations on graphs up to 70 vertices (Schidler et al., 2021). The approach encodes vertex ordering, contraction trees, and red-degree constraints into CNF, with typical resource requirements exponentially scaling in nn.

FPT Approximability Under Structural Parameters

Recent breakthroughs establish fixed-parameter approximability of twin-width parameterized by the feedback edge number kk and vertex integrity pp (Balabán et al., 2024):

  • For feedback edge number kk, tww(G)=Θ(k)\operatorname{tww}(G) = \Theta(\sqrt{k}), and a (tww(G)+1)(\operatorname{tww}(G)+1)-sequence can be computed in time 2O(k2logk)+nO(1)2^{O(k^2 \log k)}+ n^{O(1)}.
  • For vertex-integrity pp, a $2$-approximate contraction sequence can be found in 22O(p3)nO(1)2^{2^{O(p^3)}} n^{O(1)}, by reducing to a suitably compressed representative subgraph.

Earlier, it was proved that for Kt,tK_{t,t}-free graphs of twin-width at most 2, the tree-width is O(t20)O(t^{20}), and a polynomial-time recognition/approximation algorithm exists for twin-width 2 in sparse classes (Bergougnoux et al., 2023).

6. Extensions and Generalizations

Beyond Graphs: Matrices, Permutations, Posets, Cayley Graphs

  • Twin-width extends naturally to 0-1 matrices, with contraction sequences defined on rows and columns and a direct translation to contraction-based structural width (Bonnet et al., 2022). Bounded twin-width classes admit efficient algorithms for FO+MOD model checking and matrix multiplication.
  • For binary relational structures, bounded twin-width is equivalent to being an FO transduction of a proper permutation class (Bonnet et al., 2021).
  • For groups, bounded twin-width of Cayley graphs is a quasi-isometry invariant; abelian, solvable, hyperbolic, and polynomial-growth groups have finite twin-width, and there exist finitely generated groups of infinite twin-width through small-cancellation embeddings (Bonnet et al., 2022).

Variants: Oriented Twin-width, Spanning Twin-width, Partial Sequences

  • Oriented twin-width (counting red out-degrees) and spanning twin-width (minimizing over all spanning tree partial orders) yield parameters functionally equivalent or tightly related to classical width measures such as rank-width and tree-width (Bonnet et al., 2021).
  • Partial contraction sequences—where the contraction halts on a target class (e.g., bounded degree or expansion)—allow fine-grained algorithmic transfer to sparse-graph techniques and FPT model checking for certain FO fragments.

7. Open Problems and Current Frontiers

Key unresolved questions and conjectures include:

  • Constructing explicit small (e.g., cubic) graphs with large twin-width remains open; it is conjectured that for all nn-vertex graphs, tww(G)(n1)/2\operatorname{tww}(G) \leq (n-1)/2 with equality for conference graphs (Heinrich et al., 3 Apr 2025).
  • Determining asymptotic twin-width for random graphs in intermediate regimes (1/np(lnn)/n)(1/n \ll p \ll (\ln n)/n) (Ahn et al., 2022).
  • Obtaining singly-exponential FPT approximation algorithms for twin-width in terms of tree-width or minor-excluding parameters.
  • Structural characterization of bounded twin-width classes without explicit recourse to contraction sequences or grid minors remains elusive.
  • Investigating whether all bounded twin-width classes admit efficient FO interpretations into bounded-width posets (and vice versa), potentially closing the loop with Dilworth-type theorems (Balabán et al., 2021, Balabán et al., 2022).
  • Extending sharp algorithmic and structural results to further dense, geometric, or permutation-based graph classes.

Twin-width unifies and extends traditional structural graph width notions, providing a new paradigm for both graph theory and algorithm design, with continuing frontiers in combinatorial structure, logical and algorithmic meta-theorems, and computation.

Whiteboard

Topic to Video (Beta)

Follow Topic

Get notified by email when new papers are published related to Twin-width.

Don't miss out on important new AI/ML research

See which papers are being discussed right now on X, Reddit, and more:

“Emergent Mind helps me see which AI papers have caught fire online.”

Philip

Philip

Creator, AI Explained on YouTube