Introduction
The theorem of OpenAI
On 25 October 2026 OpenAI released a preprint [27 ] with a deterministic algorithm that, for every fixed k ≥ 2 k \ge2 k ≥ 2 , counts the satisfying assignments of a k k k -CNF formula with n n n variables and m m m clauses in time
( n + m ) O k ( 1 ) 2 O k ( n log log n / log n ) (1) (n+m)^{O_k(1)}2^{O_k(n\log\log n/\sqrt{\log n})} \tag*{(1)} ( n + m ) O k ( 1 ) 2 O k ( n l o g l o g n / l o g n ) (1)
and polynomial space. Since 2 O ( n log log n / log n ) = 2 o ( n ) 2^{O(n\log\log n/\sqrt{\log n})}=2^{o(n)} 2 O ( n l o g l o g n / l o g n ) = 2 o ( n ) , the exponential time hypothesis of Impagliazzo and Paturi [20 ] , which asserted that 3-SAT needs time 2 Ω ( n ) 2^{\Omega(n)} 2 Ω ( n ) , is false, and with it the strong hypothesis [21 ] , the counting hypothesis #ETH [14 ] , and the gap and nondeterministic variants. The algorithm is algebraic. It writes the count as a sum over the Boolean cube of a product of local polynomials, replaces every variable occurrence by a linear form in a parameter T T T chosen so that at each of Q Q Q sample points the factors separate into r r r groups after a short list of integer measurements of the assignment has been fixed, recovers the Taylor coefficients of the resulting univariate polynomial at the sample points from Boolean substitutions, and interpolates back to T = 0 T=0 T = 0 . The present paper owes its existence to that preprint, and every step of the algorithm that is used below is OpenAI’s.1
What this paper adds
The counting routine of [27 ] is stated there for factors with rational coefficients, with the remark that it works over any commutative Q \mathbb{Q} Q -algebra. We take that remark seriously and run the algorithm over truncated polynomial rings Q [ W ] / ( W N ) \mathbb{Q}[W]/(W^N) Q [ W ] / ( W N ) . A factor may then be W w ( x ) W^{w(x)} W w ( x ) for an integer weight function w w w of a few variables, and the sum over the cube becomes a generating polynomial: its coefficient of W j Wj W j counts the assignments of total weight j j j . One number has turned into a profile, and the profile contains an optimum. The cost of the change is nil in the exponent, and polynomial in N N N elsewhere.
The technical statement is Theorem 5.3 : for fixed k k k and c c c , a system of at most c n cn c n factors, each depending on at most k k k of the n n n Boolean variables and taking values in a commutative Q \mathbb{Q} Q -algebra A A A , is summed over { 0 , 1 } n \{0,1\}^{n} { 0 , 1 } n in
2 O k , c ( ρ ( n ) ) poly ( n ) operations in A , ρ ( n ) = n ( log log n ) 2 log n . (2) 2^{O_{k,c}(\rho(n))}\operatorname{poly}(n)\ \text{operations in }A,\qquad\rho(n)=\frac{n(\log\log n)^2}{\sqrt{\log n}}. \tag*{(2)} 2 O k , c ( ρ ( n )) poly ( n ) operations in A , ρ ( n ) = log n n ( log log n ) 2 . (2)
The exponent is the one OpenAI obtain in their § 3 –6 before the refinement that removes one logarithmic factor; we do not reproduce that refinement, because none of the consequences below needs it.
From Theorem 5.3 we deduce, with complete proofs:
(i) for every fixed k k k and c c c , the profile of a constraint satisfaction instance with n n n Boolean variables and at most c n cn c n constraints of arity at most k k k , that is the number of assignments satisfying exactly j j j constraints for every j j j , in time 2 O k , c ( ρ ( n ) ) 2^{O_{k,c}(\rho(n))} 2 O k , c ( ρ ( n )) (Theorem 6.1 ); in particular the exact optimum of Max-k k k -SAT and of Max-Cut on sparse instances, together with the number of optimal solutions (Corollaries 6.2 and 6.4);
(ii) the independence polynomial of every graph on n n n vertices, hence its independence number, clique number, vertex cover number and the number of maximum independent sets, in time 2 O ( n ( log log n ) 2 / ( log n ) 1 / 4 ) 2^{O(n(\log\log n)^2/(\log n)^{1/4})} 2 O ( n ( l o g l o g n ) 2 / ( l o g n ) 1/4 ) (Theorem 6.7 ); the proof combines Theorem 5.3 with a branching rule on vertices of large degree whose cost we bound explicitly; the same branching carries any fixed number of vertex weights at once, which solves the knapsack problem with an arbitrary conflict graph and polynomially bounded weights, and its multidimensional form, exactly (Theorem 6.10 , Corollary 6.11);
(iii) Vertex Cover with parameter k k k in time 2 O ( k ( log log k ) 2 / ( log k ) 1 / 4 ) + poly ( n ) 2^{O(k(\log\log k)^2/(\log k)^{1/4})}+\operatorname{poly}(n) 2 O ( k ( l o g l o g k ) 2 / ( l o g k ) 1/4 ) + poly ( n ) , that is 2 o ( k ) 2^{o(k)} 2 o ( k ) up to a polynomial, through the kernel of Nemhauser and Trotter (Theorem 6.13 ); the lower bound 2 Ω ( k ) 2^{\Omega(k)} 2 Ω ( k ) , which was a standard consequence of the exponential time hypothesis [9 Theorem 14.6] , therefore fails;
(iv) for every fixed Δ \Delta Δ , the density of states of the Ising model with integer couplings and fields, and of the q q q -state Potts model, on graphs of maximum degree Δ \Delta Δ with n n n vertices, in time O Δ , q ( ρ ( n ) ) O_{\Delta,q}(\rho(n)) O Δ , q ( ρ ( n )) (Theorem 6.18 ); every partition function and every ground state follows;
(v) the minimum dominating set and the matching polynomial of a bounded-degree graph, the permanent of a sparse integer matrix, and the minimum hitting set and the maximum split of a sparse set system with sets of bounded size, in time 2 O ( ρ ( n ) ) 2^{O(\rho(n))} 2 O ( ρ ( n )) (Theorems 6.20 and 6.21 );
(vi) for fixed domain size and arity, every sparse constraint system over a finite domain, hence every partition function Z A ( G ) Z_A(G) Z A ( G ) of a fixed symmetric rational matrix A A A and the number of homomorphisms into a fixed graph, on bounded-degree graphs, in time 2 O ( ρ ( n ) ) 2^{O(\rho(n))} 2 O ( ρ ( n )) (Theorem 6.15 , Corollary 6.16);
(vii) the satisfying assignments of a sparse k k k -CNF formula of each Hamming weight, and those whose weight lies in a prescribed residue class, in time 2 O ( ρ ( n ) ) 2^{O(\rho(n))} 2 O ( ρ ( n )) (Corollary 6.3, Proposition 6.23);
(viii) further families worked out in § 7 : several linear statistics of the solutions of a sparse constraint system at once, with equations and congruences imposed (Theorem 7.1 ); Max-k k k -Lin modulo p p p , Max-q q q -Cut and balanced q q q -partitions (Corollary 7.4); on bounded-degree graphs, f f f -factors, even and odd subgraphs, orientations with prescribed indegrees, proper edge colourings and nowhere-zero flows by weight (Theorem 7.5), and the Tutte polynomial on every hyperbola ( x − 1 ) ( y − 1 ) = q (x-1)(y-1)=q ( x − 1 ) ( y − 1 ) = q with q q q a positive integer, which contains
the chromatic and flow polynomials at q q q and the q q q -state Potts model (Theorem 7.10 ); the weight enumerator, the minimum distance and maximum-likelihood decoding of a binary code with sparse parity checks (Theorem 7.12 ); matchings, transversals and colourings of bounded-degree hypergraphs (Theorem 7.14 ); the weighted output profile of a linear-size circuit of bounded fan-in (Theorem 7.15 ); and the optimum and the number of optimal solutions of a 0-1 or bounded integer program with O ( n ) O(n) O ( n ) rows, each involving a bounded number of variables with coefficients of any size, and a fixed number of further dense rows with polynomially bounded coefficients, which contains exact cover with bounded element frequency and the partially ordered knapsack problem (Theorem 7.17 , Corollary 7.18), all in time 2 O ( ρ ( n ) ) 2^{O(\rho(n))} 2 O ( ρ ( n )) ;
(ix) the same for systems whose density grows with n n n : with parameters that follow the ratio c c c of factors to variables, the exponent is O ( n g ( θ ) ) O(n g(\theta)) O ( n g ( θ )) with θ = c k log log n / log n \theta= c_k\sqrt{\log\log n}/\log n θ = c k log log n / log n and g ( x ) = x log 3 / 2 ( 1 / x ) g(x) = x\log^{3/2}(1/x) g ( x ) = x log 3/2 ( 1/ x ) (Theorems 7.19 and 7.20 ), so that the maximum cut, the maximum bisection and the Ising and Potts ground states of a graph of average degree d ( n ) d(n) d ( n ) , the exact optimum of Max-k k k -SAT with d ( n ) n d(n)n d ( n ) n clauses and that of an integer program with d ( n ) n d(n)n d ( n ) n sparse rows are found in time 2 o ( n ) 2^{o(n)} 2 o ( n ) whenever d ( n ) = o ( log n / log log n ) d(n) = o(\sqrt{\log n/\log\log n}) d ( n ) = o ( log n / log log n ) (Corollaries 7.21 and 7.26 ); and, through the complement, the cut profile of every graph whose complement has that many edges, a class that contains graphs with Θ ( n 2 ) \Theta(n^2) Θ ( n 2 ) edges (Corollary 7.22), and more generally the cut profile of every graph that differs in that many pairs from a blow-up of a graph on o ( n / log n ) o(n/\log n) o ( n / log n ) vertices, or from a weighted graph whose weights are a quadratic form in s s s vertex weights with s log ( n Ω ) = o ( n ) s\log(n\Omega) = o(n) s log ( n Ω ) = o ( n ) (Theorem 7.23 and Corollary 7.24); a count shows that these classes contain almost no graphs (Remark 7.25);
(x) k k k -SAT lies in the class SE of problems solvable in time 2 ε n 2^{\varepsilon n} 2 ε n poly for every ε > 0 \varepsilon> 0 ε > 0 , by the sparsification lemma of Impagliazzo, Paturi and Zane [21 ] , and therefore every problem of the class SNP of Papadimitriou and Yannakakis [29 ] lies in SE (Theorem 8.4 ).
Items (i)–(ix) concern problems for which no 2 o ( n ) 2^{o(n)} 2 o ( n ) algorithm was known and for which such an algorithm was excluded under the exponential time hypothesis by standard reductions. The best exact algorithms for the maximum independent set run in time 2 0.1996 n 2^{0.1996n} 2 0.1996 n [XN17], for Max-Cut in time 2 ω n / 3 2^{\omega n/3} 2 ω n /3 where ω \omega ω is the exponent of matrix multiplication [35 ] , and for the permanent and the perfect matchings of sparse graphs in time 2 n − Ω ( n / Δ ) 2^{n-\Omega(n/\Delta)} 2 n − Ω ( n /Δ ) [12 ] ; each of these bounds is exceeded here asymptotically.
What this paper does not claim
The algorithm counts sums of products of local factors over a cube of dimension n n n and its running time is subexponential in n n n . Two features limit its reach, and they are stated here so that no reader expects more. First, the exponent is o ( n ) o(n) o ( n ) and not n o ( 1 ) n^{o(1)} n o ( 1 ) . A polynomial-time reduction from an NP-complete problem to 3-SAT multiplies the number of variables by a polynomial, so the algorithm says nothing about P versus NP, and nothing here bears on that question. Second, the number of factors and the total degree of their product must be O ( n ) O(n) O ( n ) , or o ( n log n / log log n ) o(n\sqrt{\log n}/\log\log n) o ( n log n / log log n ) after Theorem 7.20 , after a branching step that fixes O ( n / log n ) O(n/\log n) O ( n / log n ) variables; Remark 7.27 shows that the runtime itself cannot go beyond total degree of order n log n n\log n n log n . Max-Cut on general graphs with Θ ( n 2 ) \Theta(n^2) Θ ( n 2 ) edges, the chromatic and Tutte polynomials as polynomials in q q q (as opposed to their values at a fixed positive integer q q q , which Theorem 7.10 does give on bounded-degree graphs), Orthogonal Vectors, 3SUM and All-Pairs Shortest Paths need either Θ ( n 2 ) \Theta(n^2) Θ ( n 2 ) constraints or reductions that multiply the variable count, and they are untouched. The paper contains no partial result on any of these problems.
Organisation
Section 2 fixes notation and the model of computation over an algebra. Sections 3 and 4 reproduce the summation routine and the construction of the replacement forms. Section 5 proves Theorem 5.3 , including the branching on frequent variables and the bit-complexity bound over Q [ W ] / ( W N ) \mathbb{Q}[W]/(W^N) Q [ W ] / ( W N ) . Section 6 proves items (i)–(vii), Section 7 proves items (viii) and (ix), Section 8 proves item (x), and Section 9 records what the method does not give. Appendix A describes exact-arithmetic checks of the extended algorithm on small instances and of the finite inequalities behind Section 7.9; no statement of the paper depends on them. The author’s earlier work on algorithmic structures in geometric and topological settings [4 , 5 , 6 ] is unrelated in method but shares the aim of making a computation explicit enough to be verified line by line.
A word on the constants. The parameters of Lemma 4.7 become admissible only when log n \sqrt{\log n} log n exceeds a large multiple of ( log log n ) 2 (\log\log n)^2 ( log log n ) 2 , that is for n n n beyond any practical size; the same is true of OpenAI’s algorithm, and Figure 1 shows where the three costs of the routine settle; Theorem 7.19 asks for log n ≥ 2 30 log log n \log n \ge2^{30}\log\log n log n ≥ 2 30 log log n at the least. The theorems are statements about asymptotic complexity, and the paper does not present them as anything else.
Figure 1. The sum of the three costs of (32) per variable, with the parameters (53) for β = 2 \beta= 2 β = 2 , as a function of λ = ⌈ log n ⌉ \lambda= \lceil\log n \rceil λ = ⌈ log n ⌉ and of the degree ratio κ \kappa κ , drawn where the hypotheses r ≥ 2 r \ge2 r ≥ 2 and 6 R ≤ Q 6R \le Q 6 R ≤ Q of Lemma 4.7 hold. The surface falls like ν 2 / λ \nu^2/\sqrt{\lambda} ν 2 / λ in λ \lambda λ and grows linearly in κ \kappa κ .
Preliminaries
Notation
For an integer Q ≥ 1 Q \ge1 Q ≥ 1 we write [ Q ] = { 1 , … , Q } [Q] = \{1,\ldots,Q\} [ Q ] = { 1 , … , Q } . Boolean assignments are vectors x ∈ { 0 , 1 } n x \in\{0,1\}^n x ∈ { 0 , 1 } n , also read as vectors in Q n \mathbb{Q}^n Q n . For S ⊆ [ n ] S \subseteq[n] S ⊆ [ n ] , x ∣ S x|_S x ∣ S is the restriction and, for ξ ∈ Q S \xi\in\mathbb{Q}^S ξ ∈ Q S , ξ ~ ∈ Q n \widetilde{\xi} \in\mathbb{Q}^n ξ ∈ Q n is the extension of ξ \xi ξ by zero. The unit vector at v v v is e v e_v e v , and 1 U \mathbf{1}_U 1 U is the indicator vector of U ⊆ [ n ] U \subseteq[n] U ⊆ [ n ] . Logarithms are to base 2 unless written ln \ln ln . For n ≥ 20 n \ge20 n ≥ 20 put
λ = ⌈ log n ⌉ , ν = ⌈ log λ ⌉ , (3) \lambda= \lceil\log n\rceil,\qquad\nu= \lceil\log\lambda\rceil, \tag*{(3)} λ = ⌈ log n ⌉ , ν = ⌈ log λ ⌉ , (3)
so that λ = Θ ( log n ) \lambda= \Theta(\log n) λ = Θ ( log n ) and ν = Θ ( log log n ) \nu= \Theta(\log\log n) ν = Θ ( log log n ) .
Algebras and factors
Throughout, A \mathcal{A} A is a commutative Q \mathbb{Q} Q -algebra with identity. The two cases of interest are A = Q \mathcal{A} = \mathbb{Q} A = Q and the truncated polynomial ring
A N = Q [ W ] / ( W N ) , N ≥ 1 , (4) \mathcal{A}_N = \mathbb{Q}[W]/(W^N),\qquad N \ge1, \tag*{(4)} A N = Q [ W ] / ( W N ) , N ≥ 1 , (4)
whose elements are polynomials of degree less than N N N with rational coefficients, added coefficientwise and multiplied with the terms of degree at least N N N discarded. An addition in A N \mathcal{A}_N A N costs N N N rational additions and a multiplication costs at most N 2 N^2 N 2 rational multiplications and additions. More generally, for integers N 1 , … , N s ≥ 1 N_1,\ldots,N_s \ge1 N 1 , … , N s ≥ 1 we use
A N 1 , … , N s = Q [ W 1 , … , W s ] / ( W 1 N 1 , … , W s N s ) , (5) \mathcal{A}_{N_1,\ldots,N_s} = \mathbb{Q}[W_1,\ldots,W_s]/(W_1^{N_1},\ldots,W_s^{N_s}), \tag*{(5)} A N 1 , … , N s = Q [ W 1 , … , W s ] / ( W 1 N 1 , … , W s N s ) , (5)
a Q \mathbb{Q} Q -vector space of dimension N = N 1 ⋯ N s N = N_1\cdots N_s N = N 1 ⋯ N s with the monomials W 1 j 1 ⋯ W s j s W_1^{j_1}\cdots W_s^{j_s} W 1 j 1 ⋯ W s j s , 0 ≤ j i < N i 0 \le j_i < N_i 0 ≤ j i < N i , as a basis; its arithmetic costs the same as that of A N \mathcal{A}_N A N with this N N N . Both are commutative Q \mathbb{Q} Q -algebras, and so is the group algebra Q [ W ] / ( W m − 1 ) \mathbb{Q}[W]/(W^m-1) Q [ W ] / ( W m − 1 ) of the cyclic group of order m m m , which appears in Section 6.
A factor system on n n n variables is a finite index set F \mathcal{F} F together with, for each f ∈ F f \in\mathcal{F} f ∈ F , a scope I f ⊆ [ n ] I_f \subseteq[n] I f ⊆ [ n ] and a polynomial Φ f ∈ A [ Y v : v ∈ I f ] \Phi_f \in\mathcal{A}[Y_v:v \in I_f] Φ f ∈ A [ Y v : v ∈ I f ] . We write
Z = ∑ x ∈ { 0 , 1 } n ∏ f ∈ F Φ f ( ( x v ) v ∈ I f ) ∈ A (6) Z = \sum_{x \in\{0,1\}^n}\prod_{f \in\mathcal{F}}\Phi_f\bigl((x_v)_{v \in I_f}\bigr) \in\mathcal{A} \tag*{(6)} Z = x ∈ { 0 , 1 } n ∑ f ∈ F ∏ Φ f ( ( x v ) v ∈ I f ) ∈ A (6)
for its sum over the cube, and
M = ∑ f ∈ F ∣ I f ∣ , w = max f ∣ I f ∣ , b = max v ∈ [ n ] # { f : v ∈ I f } , d = ∑ f ∈ F deg Φ f (7) M = \sum_{f \in\mathcal{F}} |I_f|,\qquad w = \max_f |I_f|,\qquad b = \max_{v \in[n]} \#\{f:v \in I_f\},\qquad d = \sum_{f \in\mathcal{F}}\deg\Phi_f \tag*{(7)} M = f ∈ F ∑ ∣ I f ∣ , w = f max ∣ I f ∣ , b = v ∈ [ n ] max # { f : v ∈ I f } , d = f ∈ F ∑ deg Φ f (7)
for the number of incidences, the largest scope, the largest number of factors containing one variable, and the total degree. A function ϕ : { 0 , 1 } I → A \phi:\{0,1\}^I \to\mathcal{A} ϕ : { 0 , 1 } I → A on at most k k k Boolean inputs is represented by its multilinear extension
Φ ( Y ) = ∑ U ⊆ I ϕ ( 1 U ) ∏ v ∈ U Y v ∏ v ∈ I ∖ U ( 1 − Y v ) . (8) \Phi(Y)=\sum_{U\subseteq I}\phi(\mathbf{1}_U)\prod_{v\in U}Y_v\prod_{v\in I\setminus U}(1-Y_v). \tag*{(8)} Φ ( Y ) = U ⊆ I ∑ ϕ ( 1 U ) v ∈ U ∏ Y v v ∈ I ∖ U ∏ ( 1 − Y v ) . (8)
a polynomial of degree at most ∣ I ∣ ≤ k |I| \le k ∣ I ∣ ≤ k that agrees with ϕ \phi ϕ on { 0 , 1 } I \{0,1\}^{I} { 0 , 1 } I . Every factor below is of this kind, so deg Φ f ≤ ∣ I f ∣ \deg\Phi_f \le|I_f| deg Φ f ≤ ∣ I f ∣ and d ≤ M d \le M d ≤ M .
Weights
Let ω f : { 0 , 1 } I f → { 0 , 1 , … } \omega_f:\{0,1\}^{I_f}\to\{0,1,\ldots\} ω f : { 0 , 1 } I f → { 0 , 1 , … } be integer-valued and let N N N exceed ∑ f max ω f \sum_f\max\omega_f ∑ f max ω f . With A = A N \mathcal{A}=\mathcal{A}_N A = A N and Φ f \Phi_f Φ f the multilinear extension of W ω f W^{\omega_f} W ω f , the sum (6) is
Z = ∑ x ∈ { 0 , 1 } n W ∑ f ω f ( x ∣ I f ) = ∑ j ≥ 0 # { x : ∑ f ω f ( x ∣ I f ) = j } W j , (9) Z=\sum_{x\in\{0,1\}^n}W^{\sum_f\omega_f(x|_{I_f})}=\sum_{j\ge0}\#\left\{x:\sum_f\omega_f(x|_{I_f})=j\right\}W^j, \tag*{(9)} Z = x ∈ { 0 , 1 } n ∑ W ∑ f ω f ( x ∣ I f ) = j ≥ 0 ∑ # ⎩ ⎨ ⎧ x : f ∑ ω f ( x ∣ I f ) = j ⎭ ⎬ ⎫ W j , (9)
and no term is lost to the truncation. We call the right-hand side the profile of the weight system. The largest j j j with a nonzero coefficient is the maximum of the total weight, the smallest is the minimum, and the coefficients count the assignments attaining each value.
Model of computation
Running times count bit operations on a deterministic random-access machine. Elements of Q \mathbb{Q} Q are stored as pairs of integers in lowest terms. When a bound is stated as a number of operations in A \mathcal{A} A , each operation is an addition, a multiplication, or a multiplication by a rational scalar, and the bound on bit operations follows once the bit lengths of the operands are bounded. For A = A N \mathcal{A}=\mathcal{A}_N A = A N this is done in Lemma 5.5. The space bound “polynomial” means a polynomial in n n n , ∣ F ∣ |\mathcal{F}| ∣ F ∣ , N N N and the bit lengths of the input.
Two classical tools
We use Hoeffding’s inequality for a binomial variable [18 ] : if W ∼ Bin ( Q , p ) W\sim\operatorname{Bin}(Q,p) W ∼ Bin ( Q , p ) and s > 0 s>0 s > 0 then
Pr [ ∣ W − Q p ∣ ≥ s ] ≤ 2 e − 2 s 2 / Q . (10) \Pr[|W-Qp|\ge s]\le2e^{-2s^2/Q}. \tag*{(10)} Pr [ ∣ W − Qp ∣ ≥ s ] ≤ 2 e − 2 s 2 / Q . (10)
We use Hermite interpolation in the following form. Let m = Q J m=QJ m = Q J and let H ∈ A [ T ] H\in\mathcal{A}[T] H ∈ A [ T ] have degree less than m m m . The m m m quantities [ z j ] H ( t + z ) [z^j]H(t+z) [ z j ] H ( t + z ) for t ∈ [ Q ] t\in[Q] t ∈ [ Q ] and 0 ≤ j < J 0\le j<J 0 ≤ j < J are rational linear combinations of the coefficients of H H H , through the m × m m\times m m × m matrix with entries ( i j ) t i − j \binom{i}{j}t^{i-j} ( j i ) t i − j (zero when i < j i<j i < j ) indexed by ( t , j ) (t,j) ( t , j ) and i i i . This matrix is invertible over Q \mathbb{Q} Q : a polynomial of degree less than Q J QJ Q J whose first J J J Taylor coefficients vanish at each of Q Q Q distinct points is divisible by ∏ t ( T − t ) J \prod_t(T-t)^J ∏ t ( T − t ) J , hence zero. Since the entries are rationals of O ( Q J log ( Q J ) ) O(QJ\log(QJ)) O ( Q J log ( Q J )) bits, Gaussian elimination recovers the coefficients of H H H with O ( ( Q J ) 3 ) O((QJ)^3) O (( Q J ) 3 ) operations in A \mathcal{A} A and rational numbers of poly ( Q J ) \operatorname{poly}(QJ) poly ( Q J ) bits.
The summation routine
This section and the next reproduce the algorithm of OpenAI [27 Sections 3–4] for a factor system with values in a commutative Q \mathbb{Q} Q -algebra A \mathcal{A} A . The algorithm is theirs; the statements are repeated with proofs so that the paper is self-contained.
Replacement forms and the polynomial H H H
Give each incidence ( f , v ) (f,v) ( f , v ) , f ∈ F f\in\mathcal{F} f ∈ F , v ∈ I f v\in I_f v ∈ I f , its own indeterminate Y f , v Y_{f,v} Y f , v , and suppose
deg { Y f , v } ∏ v ∈ I f Φ f ( ( Y f , v ) v ∈ I f ) ≤ d . (11) \deg_{\{Y_{f,v}\}}\prod_{v\in I_f}\Phi_f((Y_{f,v})_{v\in I_f})\le d. \tag*{(11)} deg { Y f , v } v ∈ I f ∏ Φ f (( Y f , v ) v ∈ I f ) ≤ d . (11)
With d d d as in (7) this holds. Choose for every incidence a row P ⃗ f , v ( T ) ∈ Q [ T ] 1 × n \vec{P}_{f,v}(T)\in\mathbb{Q}[T]^{1\times n} P f , v ( T ) ∈ Q [ T ] 1 × n with P ⃗ f , v ( 0 ) = e v \vec{P}_{f,v}(0)=e_v P f , v ( 0 ) = e v and deg P ⃗ f , v ≤ R \deg\vec{P}_{f,v}\le R deg P f , v ≤ R , and define
H ( T ) = ∑ x ∈ { 0 , 1 } n ∏ f ∈ F Φ f ( ( ⟨ P ⃗ f , v ( T ) , x ⟩ ) v ∈ I f ) ∈ A [ T ] . (12) H(T)=\sum_{x\in\{0,1\}^n}\prod_{f\in\mathcal{F}}\Phi_f\left((\langle\vec{P}_{f,v}(T),x\rangle)_{v\in I_f}\right)\in\mathcal{A}[T]. \tag*{(12)} H ( T ) = x ∈ { 0 , 1 } n ∑ f ∈ F ∏ Φ f ( (⟨ P f , v ( T ) , x ⟩ ) v ∈ I f ) ∈ A [ T ] . (12)
At T = 0 T=0 T = 0 every input is restored, so H ( 0 ) = Z H(0)=Z H ( 0 ) = Z , and each input has degree at most R R R in T T T , so
deg T H ≤ d H : = d R . (13) \deg_T H\le d_H:=dR. \tag*{(13)} deg T H ≤ d H := d R . (13)
The algorithm computes H H H at T = 0 T=0 T = 0 from information at the points T = 1 , … , Q T=1,\ldots,Q T = 1 , … , Q .
The design
Definition 3.1 (Design). Let r ≥ 2 r \ge2 r ≥ 2 , D ≥ 1 D \ge1 D ≥ 1 and 1 ≤ R < Q 1 \le R < Q 1 ≤ R < Q be integers and 0 < τ ≤ 1 / 2 0 < \tau\le1/2 0 < τ ≤ 1/2 . A design for the scopes ( I f ) f ∈ F (I_f)_{f \in\mathcal{F}} ( I f ) f ∈ F consists of the following data.2
(D1) For each t ∈ [ Q ] t \in[Q] t ∈ [ Q ] a partition [ n ] = S t , 1 ⊔ ⋯ ⊔ S t , r [n] = S_{t,1} \sqcup\cdots\sqcup S_{t,r} [ n ] = S t , 1 ⊔ ⋯ ⊔ S t , r , parts possibly empty, with ∣ S t , g ∣ ≤ 2 n / r |S_{t,g}| \le2n/r ∣ S t , g ∣ ≤ 2 n / r .
(D2) For each f ∈ F f \in\mathcal{F} f ∈ F a sequence σ f ∈ [ r ] Q \sigma_f \in[r]^Q σ f ∈ [ r ] Q ; the value σ f ( t ) \sigma_f(t) σ f ( t ) is the group of f f f at the point t t t .
(D3) For each t ∈ [ Q ] t \in[Q] t ∈ [ Q ] and g ∈ [ r ] g \in[r] g ∈ [ r ] an integer matrix C t , g ∈ Z c t , g × S t , g C_{t,g} \in\mathbb{Z}^{c_{t,g} \times S_{t,g}} C t , g ∈ Z c t , g × S t , g whose rows have sum of absolute values at most D D D , with ∑ g = 1 r c t , g ≤ 2 τ n \sum_{g=1}^{r} c_{t,g} \le2\tau n ∑ g = 1 r c t , g ≤ 2 τ n . The entries of C t , g x ∣ S t , g C_{t,g}x|_{S_{t,g}} C t , g x ∣ S t , g are the measurements of x x x on the group g g g at t t t .
(D4) For each incidence ( f , v ) (f,v) ( f , v ) a row P ⃗ f , v ( T ) ∈ Q [ T ] 1 × n \vec{P}_{f,v}(T) \in\mathbb{Q}[T]^{1 \times n} P f , v ( T ) ∈ Q [ T ] 1 × n with P ⃗ f , v ( 0 ) = e v \vec{P}_{f,v}(0) = \mathbf{e}_v P f , v ( 0 ) = e v and deg P ⃗ f , v ≤ R \deg\vec{P}_{f,v} \le R deg P f , v ≤ R , such that for all t ∈ [ Q ] t \in[Q] t ∈ [ Q ] , g ≠ σ f ( t ) g \ne\sigma_f(t) g = σ f ( t ) and ξ ∈ Q S t , g \xi\in\mathbb{Q}^{S_{t,g}} ξ ∈ Q S t , g ,
C t , g ξ = 0 ⟹ ⟨ P ⃗ f , v ( t ) , ξ ~ ⟩ = 0. (14) C_{t,g}\xi= 0 \mathrel{\Longrightarrow} \langle\vec{P}_{f,v}(t),\widetilde{\xi}\rangle= 0. \tag*{(14)} C t , g ξ = 0 ⟹ ⟨ P f , v ( t ) , ξ ⟩ = 0. (14) (D5) With d d e n = ( R − 1 ) ! Q ! d_{\mathrm{den}} = (R-1)!Q! d den = ( R − 1 )! Q ! , every coefficient of d d e n P ⃗ f , v d_{\mathrm{den}}\vec{P}_{f,v} d den P f , v is an integer of O ( Q log Q + log D ) O(Q \log Q + \log D) O ( Q log Q + log D ) bits.
The kernel condition (14) has the following meaning. Fix t t t , f f f and v ∈ I f v \in I_f v ∈ I f , put g = σ f ( t ) g = \sigma_f(t) g = σ f ( t ) and write x h = x ∣ S t , h x_h = x|_{S_{t,h}} x h = x ∣ S t , h . If x , x ′ ∈ Q n x,x' \in\mathbb{Q}^n x , x ′ ∈ Q n agree outside S t , h S_{t,h} S t , h for some h ≠ g h \ne g h = g and C t , h x h ′ = C t , h x h C_{t,h}x'_h = C_{t,h}x_h C t , h x h ′ = C t , h x h , then x h ′ − x h ∈ ker C t , h x'_h - x_h \in\ker C_{t,h} x h ′ − x h ∈ ker C t , h and (14) gives ⟨ P ⃗ f , v ( t ) , x ′ ⟩ = ⟨ P ⃗ f , v ( t ) , x ⟩ \langle\vec{P}_{f,v}(t),x'\rangle= \langle\vec{P}_{f,v}(t),x\rangle ⟨ P f , v ( t ) , x ′ ⟩ = ⟨ P f , v ( t ) , x ⟩ . Applied one group at a time this shows that the tuple ( ⟨ P ⃗ f , v ( t ) , x ⟩ ) v ∈ I f (\langle\vec{P}_{f,v}(t),x\rangle)_{v \in I_f} (⟨ P f , v ( t ) , x ⟩ ) v ∈ I f is determined by x g x_g x g together with the measurements ( C t , h x h ) h ≠ g (C_{t,h}x_h)_{h \ne g} ( C t , h x h ) h = g . Once all measurements are fixed, the factor f f f at the point t t t is a function of x g x_g x g alone. The bound on the row sums in (D3) ensures that a measurement of a Boolean vector lies in [ − D , D ] ∩ Z [-D,D] \cap\mathbb{Z} [ − D , D ] ∩ Z ; a rank bound alone would not control the number of possible measurement values, as the single row ( 1 , 2 , 4 , … , 2 n − 1 ) (1,2,4,\ldots,2^{n-1}) ( 1 , 2 , 4 , … , 2 n − 1 ) shows.
Separating the sum by fixing the measurements
Lemma 3.2 (Separation). Let [ n ] = S 1 ⊔ ⋯ ⊔ S r [n] = S_1 \sqcup\cdots\sqcup S_r [ n ] = S 1 ⊔ ⋯ ⊔ S r be a partition, parts possibly empty, and for each g ∈ [ r ] g \in[r] g ∈ [ r ] let C g C_g C g be an integer matrix with c g c_g c g rows and columns indexed by S g S_g S g , each row with sum of absolute values at most D D D ; put c = ∑ g c g c = \sum_g c_g c = ∑ g c g . Let A g : Q n → A A_g : \mathbb{Q}^n \to\mathcal{A} A g : Q n → A satisfy
A g ( x + ξ ~ ) = A g ( x ) ( x ∈ Q n , ξ ∈ ker C h , h ≠ g ) . (15) A_g(x+\widetilde{\xi}) = A_g(x) \qquad(x \in\mathbb{Q}^n,\ \xi\in\ker C_h,\ h \ne g). \tag*{(15)} A g ( x + ξ ) = A g ( x ) ( x ∈ Q n , ξ ∈ ker C h , h = g ) . (15) For every E ⊆ [ n ] E \subseteq[n] E ⊆ [ n ] the sum
Z E = ∑ x ∈ { 0 , 1 } n x i = 1 ( i ∈ E ) ∏ g = 1 r A g ( x ) Z_E = \sum_{\substack{x \in\{0,1\}^n\\ x_i=1\ (i \in E)}} \prod_{g=1}^{r} A_g(x) Z E = x ∈ { 0 , 1 } n x i = 1 ( i ∈ E ) ∑ g = 1 ∏ r A g ( x ) can be computed by examining at most 2 ( 2 D + 1 ) c ∑ g = 1 r 2 ∣ S g ∣ 2(2D+1)^c \sum_{g=1}^{r}2^{|S_g|} 2 ( 2 D + 1 ) c ∑ g = 1 r 2 ∣ S g ∣ Boolean vectors, with at most one evaluation of some A g A_g A g , O ( 1 ) O(1) O ( 1 ) operations in A \mathcal{A} A and poly ( n , r , c , log ( D + 2 ) ) \operatorname{poly}(n,r,c,\log(D+2)) poly ( n , r , c , log ( D + 2 )) bit operations per vector, and with poly ( n , r , c , log ( D + 2 ) ) \operatorname{poly}(n,r,c,\log(D+2)) poly ( n , r , c , log ( D + 2 )) bits of storage beyond the evaluators’ own and O ( 1 ) O(1) O ( 1 ) elements of A \mathcal{A} A .3
Proof. For y g ∈ Z c g y_g \in\mathbb{Z}^{c_g} y g ∈ Z c g let X g ( y g ) = { u ∈ { 0 , 1 } S g : C g u = y g } X_g(y_g) = \{u \in\{0,1\}^{S_g} : C_g u = y_g\} X g ( y g ) = { u ∈ { 0 , 1 } S g : C g u = y g } and let Y = ∏ g { − D , … , D } c g \mathcal{Y} = \prod_g \{-D,\ldots,D\}^{c_g} Y = ∏ g { − D , … , D } c g , a set of ( 2 D + 1 ) c (2D+1)^c ( 2 D + 1 ) c tuples that contains the measurement tuple of every Boolean assignment. Fix y ⃗ = ( y 1 , … , y r ) ∈ Y \vec{y} = (y_1,\ldots,y_r) \in\mathcal{Y} y = ( y 1 , … , y r ) ∈ Y with every X g ( y g ) X_g(y_g) X g ( y g ) nonempty, choose representatives x ˉ g ∈ X g ( y g ) \bar{x}_g \in X_g(y_g) x ˉ g ∈ X g ( y g ) , and put X g , E ( y g ) = { u ∈ X g ( y g ) : u i = 1 ( i ∈ E ∩ S g ) } X_{g,E}(y_g)=\{u\in X_g(y_g):u_i=1\ (i\in E\cap S_g)\} X g , E ( y g ) = { u ∈ X g ( y g ) : u i = 1 ( i ∈ E ∩ S g )} . If x h ∈ X h ( y h ) x_h\in X_h(y_h) x h ∈ X h ( y h ) for every h h h , then x h − x ˉ h ∈ ker C h x_h-\bar{x}_h\in\ker C_h x h − x ˉ h ∈ ker C h , and (15) applied for each h ≠ g h\ne g h = g in turn gives
A g ( ∑ h x ~ h ) = A g ( x ~ g + ∑ h ≠ g x ˉ ~ h ) . A_g\left(\sum_h\widetilde{x}_h\right)=A_g\left(\widetilde{x}_g+\sum_{h\ne g}\widetilde{\bar{x}}_h\right). A g ( h ∑ x h ) = A g x g + h = g ∑ x ˉ h .
The assignments with measurement tuple y ⃗ \vec{y} y and x i = 1 x_i=1 x i = 1 for i ∈ E i\in E i ∈ E are exactly the products ∏ g X g , E ( y g ) \prod_g X_{g,E}(y_g) ∏ g X g , E ( y g ) , so by distributivity they contribute ∏ g Σ g ( y ⃗ ) \prod_g\Sigma_g(\vec{y}) ∏ g Σ g ( y ) to Z E Z_E Z E , where
Σ g ( y ⃗ ) = ∑ x g ∈ X g , E ( y g ) A g ( x ~ g + ∑ h ≠ g x ˉ ~ h ) . (16) \Sigma_g(\vec{y})=\sum_{x_g\in X_{g,E}(y_g)}A_g\left(\widetilde{x}_g+\sum_{h\ne g}\widetilde{\bar{x}}_h\right). \tag*{(16)} Σ g ( y ) = x g ∈ X g , E ( y g ) ∑ A g x g + h = g ∑ x ˉ h . (16)
an empty sum being zero. Every assignment has exactly one measurement tuple, hence
Z E = ∑ y ⃗ ∈ Y ∏ g = 1 r Σ g ( y ⃗ ) . (17) Z_E=\sum_{\vec{y}\in\mathcal{Y}}\prod_{g=1}^{r}\Sigma_g(\vec{y}). \tag*{(17)} Z E = y ∈ Y ∑ g = 1 ∏ r Σ g ( y ) . (17)
where a product is zero when some X g ( y g ) X_g(y_g) X g ( y g ) is empty. The representatives need not satisfy the conditions indexed by E E E .
The algorithm runs through y ⃗ ∈ Y \vec{y}\in\mathcal{Y} y ∈ Y with an accumulator Z ← 0 Z\leftarrow0 Z ← 0 . For each y ⃗ \vec{y} y a first scan of each { 0 , 1 } S g \{0,1\}^{S_g} { 0 , 1 } S g finds a representative x ˉ g \bar{x}_g x ˉ g , or shows that X g ( y g ) X_g(y_g) X g ( y g ) is empty, in which case the tuple is skipped. Otherwise it sets p ← 1 p\leftarrow1 p ← 1 , and for each g g g computes Σ g ( y ⃗ ) \Sigma_g(\vec{y}) Σ g ( y ) by a second scan of { 0 , 1 } S g \{0,1\}^{S_g} { 0 , 1 } S g , adding A g ( u ~ + ∑ h ≠ g x ~ h ) A_g(\widetilde{u}+\sum_{h\ne g}\widetilde{x}_h) A g ( u + ∑ h = g x h ) to a running sum s s s for each u u u with C g u = y g C_gu=y_g C g u = y g and u i = 1 u_i=1 u i = 1 on E ∩ S g E\cap S_g E ∩ S g , then sets p ← p s p\leftarrow ps p ← p s ; finally Z ← Z + p Z\leftarrow Z+p Z ← Z + p . By (17) the final value is Z E Z_E Z E . The two scans examine at most 2 ∑ g 2 ∣ S g ∣ 2\sum_g2^{|S_g|} 2 ∑ g 2 ∣ S g ∣ vectors per tuple. Checking the measurements of a vector costs poly ( n , r , c , log ( D + 2 ) ) \operatorname{poly}(n,r,c,\log(D+2)) poly ( n , r , c , log ( D + 2 )) bit operations, since each row sum has O ( log ( D + 2 ) ) O(\log(D+2)) O ( log ( D + 2 )) bits, and the retained state is y ⃗ \vec{y} y , the representatives, the current g g g and u u u , and s , p , Z ∈ A s,p,Z\in\mathcal{A} s , p , Z ∈ A . □
To evaluate H ( t ) H(t) H ( t ) for a fixed t ∈ [ Q ] t\in[Q] t ∈ [ Q ] , group the transformed factors by σ f ( t ) \sigma_f(t) σ f ( t ) ,
A g ( x ) = ∏ f : σ f ( t ) = g Φ f ( ( ⟨ P ⃗ f , v ( t ) , x ⟩ ) v ∈ I f ) , A_g(x)=\prod_{f:\sigma_f(t)=g}\Phi_f\left((\langle\vec{P}_{f,v}(t),x\rangle)_{v\in I_f}\right), A g ( x ) = f : σ f ( t ) = g ∏ Φ f ( (⟨ P f , v ( t ) , x ⟩ ) v ∈ I f ) ,
and apply the lemma with the partition ( S t , g ) g (S_{t,g})_g ( S t , g ) g , the matrices C t , g C_{t,g} C t , g and E = ∅ E=\varnothing E = ∅ ; the kernel condition (14) is the invariance (15) . The two exponential costs are the number of measurement tuples and the number of assignments in one group.
Taylor coefficients from Boolean substitutions
The Q Q Q values H ( 1 ) , … , H ( Q ) H(1),\ldots,H(Q) H ( 1 ) , … , H ( Q ) do not determine H H H when d H ≥ Q d_H\ge Q d H ≥ Q . Put
q = ⌊ d H / Q ⌋ , J = q + 1 , (18) q=\lfloor d_H/Q\rfloor,\qquad J=q+1, \tag*{(18)} q = ⌊ d H / Q ⌋ , J = q + 1 , (18)
so that Q J > d H QJ>d_H Q J > d H . It suffices to compute the truncated Taylor expansions
H t ( z ) = ∑ j = 0 J − 1 [ z j ] H ( t + z ) z j ( t ∈ [ Q ] ) , (19) H_t(z)=\sum_{j=0}^{J-1}[z^j]H(t+z)z^j\qquad(t\in[Q]), \tag*{(19)} H t ( z ) = j = 0 ∑ J − 1 [ z j ] H ( t + z ) z j ( t ∈ [ Q ]) , (19)
since Hermite interpolation (Section 2) recovers H H H , and hence Z = H ( 0 ) Z=H(0) Z = H ( 0 ) , from these Q J QJ Q J coefficients by rational linear combinations.
Fix t t t . The rows at t + z t+z t + z need not respect the design at t t t . Write Δ P ⃗ f , v ( z ) = P ⃗ f , v ( t + z ) − P ⃗ f , v ( t ) \Delta\vec{P}_{f,v}(z)=\vec{P}_{f,v}(t+z)-\vec{P}_{f,v}(t) Δ P f , v ( z ) = P f , v ( t + z ) − P f , v ( t ) ; every entry is divisible by z z z . For a fixed x ∈ Q n x\in\mathbb{Q}^n x ∈ Q n introduce indeterminates X ⃗ = ( X 1 , … , X n ) \vec{X}=(X_1,\ldots,X_n) X = ( X 1 , … , X n ) and replace each input by ⟨ P ⃗ f , v ( t ) , x ⟩ + ⟨ Δ P ⃗ f , v ( z ) , X ⃗ ⟩ \langle\vec{P}_{f,v}(t),x\rangle+\langle\Delta\vec{P}_{f,v}(z),\vec{X}\rangle ⟨ P f , v ( t ) , x ⟩ + ⟨ Δ P f , v ( z ) , X ⟩ . Let
G x ( X ⃗ , z ) = ∏ f ∈ F Φ f ( ( ⟨ P ⃗ f , v ( t ) , x ⟩ + ⟨ Δ P ⃗ f , v ( z ) , X ⃗ ⟩ ) v ∈ I f ) . (20) G_x(\vec{X},z)=\prod_{f\in\mathcal{F}}\Phi_f\left((\langle\vec{P}_{f,v}(t),x\rangle+\langle\Delta\vec{P}_{f,v}(z),\vec{X}\rangle)_{v\in I_f}\right). \tag*{(20)} G x ( X , z ) = f ∈ F ∏ Φ f ( (⟨ P f , v ( t ) , x ⟩ + ⟨ Δ P f , v ( z ) , X ⟩ ) v ∈ I f ) . (20)
Setting X ⃗ = x \vec{X}=x X = x and summing over x ∈ { 0 , 1 } n x \in\{0,1\}^{n} x ∈ { 0 , 1 } n gives H ( t + z ) H(t+z) H ( t + z ) . Holding X ⃗ \vec{X} X fixed instead makes every correction independent of x x x , so the design at t t t still separates the factors; and every occurrence of X ⃗ \vec{X} X carries a factor z z z , so
deg X ⃗ ( [ z j ] G x ( X ⃗ , z ) ) ≤ j . (21) \deg_{\vec{X}}\left([z^{j}]G_{x}(\vec{X},z)\right)\leq j. \tag*{(21)} deg X ( [ z j ] G x ( X , z ) ) ≤ j . (21)
Lemma 3.3 (Boolean substitution). Let q ≥ 0 q\geq0 q ≥ 0 and let A A A be a commutative ring with identity. For each x ∈ { 0 , 1 } n x\in\{0,1\}^{n} x ∈ { 0 , 1 } n let p x ∈ A [ X 1 , … , X n ] p_x\in A[X_1,\ldots,X_n] p x ∈ A [ X 1 , … , X n ] have degree at most q q q . Then
∑ x ∈ { 0 , 1 } n p x ( x ) = ∑ E ⊆ [ n ] ∣ E ∣ ≤ q ( − 1 ) ∣ E ∣ − ∣ U ∣ ∑ x ∈ { 0 , 1 } n x i = 1 ( i ∈ E ) p x ( 1 U ) . (22) \sum_{x\in\{0,1\}^{n}}p_x(x)=\sum_{\substack{E\subseteq[n]\\|E|\leq q}}(-1)^{|E|-|U|}\sum_{\substack{x\in\{0,1\}^{n}\\x_i=1\ (i\in E)}}p_x(\mathbf{1}_U). \tag*{(22)} x ∈ { 0 , 1 } n ∑ p x ( x ) = E ⊆ [ n ] ∣ E ∣ ≤ q ∑ ( − 1 ) ∣ E ∣ − ∣ U ∣ x ∈ { 0 , 1 } n x i = 1 ( i ∈ E ) ∑ p x ( 1 U ) . (22)
Proof. Fix x x x and replace each positive power of X i X_i X i in p x p_x p x by X i X_i X i . Boolean evaluations are unchanged and the degree does not increase, so the result is a multilinear polynomial p ~ x = ∑ E c x , E ∏ i ∈ E X i \widetilde{p}_x=\sum_E c_{x,E}\prod_{i\in E}X_i p x = ∑ E c x , E ∏ i ∈ E X i of degree at most q q q . Evaluating at the indicator vectors and inverting on the Boolean lattice gives c x , E = ∑ U ⊆ E ( − 1 ) ∣ E ∣ − ∣ U ∣ p x ( 1 U ) c_{x,E}=\sum_{U\subseteq E}(-1)^{|E|-|U|}p_x(\mathbf{1}_U) c x , E = ∑ U ⊆ E ( − 1 ) ∣ E ∣ − ∣ U ∣ p x ( 1 U ) , and c x , E = 0 c_{x,E}=0 c x , E = 0 when ∣ E ∣ > q |E|>q ∣ E ∣ > q . Setting X ⃗ = x \vec{X}=x X = x and summing over x x x , the monomial ∏ i ∈ E x i \prod_{i\in E}x_i ∏ i ∈ E x i selects exactly the assignments with x i = 1 x_i=1 x i = 1 for i ∈ E i\in E i ∈ E .
Apply the lemma to [ z j ] G x [z^j]G_x [ z j ] G x for each j < J j<J j < J ; by (21) the degree bound q q q holds for all of them, so all coefficients use the same pairs U ⊆ E U\subseteq E U ⊆ E , ∣ E ∣ ≤ q |E|\leq q ∣ E ∣ ≤ q , and may be computed together in the ring
R = A [ z ] / ( z J ) . (23) R=A[z]/(z^J). \tag*{(23)} R = A [ z ] / ( z J ) . (23)
For a fixed pair ( E , U ) (E,U) ( E , U ) let Φ f , U ( x ; z ) \Phi_{f,U}(x;z) Φ f , U ( x ; z ) be the factor f f f in (20) after X ⃗ = 1 U \vec{X}=\mathbf{1}_U X = 1 U , and group by assigned groups,
A g , U ( x ; z ) = ∏ f : σ f ( t ) = g Φ f , U ( x ; z ) ∈ R . (24) A_{g,U}(x;z)=\prod_{f:\sigma_f(t)=g}\Phi_{f,U}(x;z)\in R. \tag*{(24)} A g , U ( x ; z ) = f : σ f ( t ) = g ∏ Φ f , U ( x ; z ) ∈ R . (24)
Their product over g g g is G x ( 1 U , z ) G_x(\mathbf{1}_U,z) G x ( 1 U , z ) . For h ≠ g h\ne g h = g , changing x x x by an element of ker C t , h \ker C_{t,h} ker C t , h changes neither the original inputs of the factors in A g , U A_{g,U} A g , U nor their fixed corrections, so Lemma 3.2 applies in R R R and computes ∑ x : x i = 1 ( i ∈ E ) G x ( 1 U , z ) \sum_{x:x_i=1\ (i\in E)}G_x(\mathbf{1}_U,z) ∑ x : x i = 1 ( i ∈ E ) G x ( 1 U , z ) by examining at most
2 r ( 2 D + 1 ) 2 τ n 2 2 n / r (25) 2r(2D+1)^{2\tau n}2^{2n/r} \tag*{(25)} 2 r ( 2 D + 1 ) 2 τ n 2 2 n / r (25)
Boolean vectors. Summing over the pairs with the signs of (22) ,
H ( t + z ) ≡ ∑ E ⊆ [ n ] ∣ E ∣ ≤ q ∑ U ⊆ E ( − 1 ) ∣ E ∣ − ∣ U ∣ ∑ x ∈ { 0 , 1 } n x i = 1 ( i ∈ E ) G x ( 1 U , z ) ( m o d z J ) , (26) H(t+z)\equiv\sum_{\substack{E\subseteq[n]\\|E|\leq q}}\sum_{U\subseteq E}(-1)^{|E|-|U|}\sum_{\substack{x\in\{0,1\}^{n}\\x_i=1\ (i\in E)}}G_x(\mathbf{1}_U,z)\pmod{z^J}, \tag*{(26)} H ( t + z ) ≡ E ⊆ [ n ] ∣ E ∣ ≤ q ∑ U ⊆ E ∑ ( − 1 ) ∣ E ∣ − ∣ U ∣ x ∈ { 0 , 1 } n x i = 1 ( i ∈ E ) ∑ G x ( 1 U , z ) ( mod z J ) , (26)
which is H t ( z ) H_t(z) H t ( z ) . The algorithm never stores a polynomial in the n n n indeterminates: it substitutes X ⃗ = 1 U \vec{X}=\mathbf{1}_U X = 1 U first and keeps only J J J coefficients in A A A .
The three exponential costs
For each t t t , the number of pairs U ⊆ E ⊆ [ n ] U\subseteq E\subseteq[n] U ⊆ E ⊆ [ n ] with ∣ E ∣ ≤ q |E|\leq q ∣ E ∣ ≤ q is
C q = ∑ s = 0 min ( q , n ) 2 s ( n s ) , (27) C_q=\sum_{s=0}^{\min(q,n)}2^s\binom{n}{s}, \tag*{(27)} C q = s = 0 ∑ m i n ( q , n ) 2 s ( s n ) , (27)
and for every 0 < η ≤ 1 0<\eta\leq1 0 < η ≤ 1 ,
η q C q ≤ ∑ s = 0 n ( 2 η ) s ( n s ) = ( 1 + 2 η ) n . (28) \eta^q C_q\leq\sum_{s=0}^{n}(2\eta)^s\binom{n}{s}=(1+2\eta)^n. \tag*{(28)} η q C q ≤ s = 0 ∑ n ( 2 η ) s ( s n ) = ( 1 + 2 η ) n . (28)
because η q ≤ η s \eta^q \le\eta^s η q ≤ η s for every retained s ≤ q s \le q s ≤ q . The choice of η \eta η that minimises the right-hand side gives the bound that will be used when the ratio q / n q/n q / n is allowed to vary with n n n . Write H ( u ) = − u log u − ( 1 − u ) log ( 1 − u ) H(u)=-u\log u-(1-u)\log(1-u) H ( u ) = − u log u − ( 1 − u ) log ( 1 − u ) for the binary entropy, with H ( 0 ) = 0 H(0)=0 H ( 0 ) = 0 .
Lemma 3.4 (Entropy bound). For integers 0 ≤ q ≤ n / 2 0 \le q \le n/2 0 ≤ q ≤ n /2 ,
log C q ≤ q + n H ( q / n ) ≤ q log 2 e n q , (29) \log C_q \le q+nH(q/n)\le q\log\frac{2en}{q}, \tag*{(29)} log C q ≤ q + n H ( q / n ) ≤ q log q 2 e n , (29) the last expression read as 0 when q = 0 q=0 q = 0 .
Proof. For q = 0 q=0 q = 0 both sides vanish. For q ≥ 1 q\ge1 q ≥ 1 take η = q / ( 2 ( n − q ) ) \eta=q/(2(n-q)) η = q / ( 2 ( n − q )) , which lies in ( 0 , 1 ] (0,1] ( 0 , 1 ] since q ≤ n / 2 q\le n/2 q ≤ n /2 . Then 1 + 2 η = n / ( n − q ) 1+2\eta=n/(n-q) 1 + 2 η = n / ( n − q ) , and (28) gives
C q ≤ η − q ( n n − q ) n = 2 q n n q q ( n − q ) n − q . C_q\le\eta^{-q}\left(\frac{n}{n-q}\right)^n=\frac{2^q n^n}{q^q(n-q)^{n-q}}. C q ≤ η − q ( n − q n ) n = q q ( n − q ) n − q 2 q n n . whose logarithm is q + n log n − q log q − ( n − q ) log ( n − q ) = q + n H ( q / n ) q+n\log n-q\log q-(n-q)\log(n-q)=q+nH(q/n) q + n log n − q log q − ( n − q ) log ( n − q ) = q + n H ( q / n ) . For the second inequality, − ( 1 − u ) ln ( 1 − u ) ≤ u -(1-u)\ln(1-u)\le u − ( 1 − u ) ln ( 1 − u ) ≤ u for 0 ≤ u < 1 0\le u<1 0 ≤ u < 1 , because the derivative of u + ( 1 − u ) ln ( 1 − u ) u+(1-u)\ln(1-u) u + ( 1 − u ) ln ( 1 − u ) is − ln ( 1 − u ) ≥ 0 -\ln(1-u)\ge0 − ln ( 1 − u ) ≥ 0 ; hence H ( u ) ≤ u log ( e / u ) H(u)\le u\log(e/u) H ( u ) ≤ u log ( e / u ) , and with u = q / n u=q/n u = q / n this gives q + n H ( q / n ) ≤ q + q log ( e n / q ) q+nH(q/n)\le q+q\log(en/q) q + n H ( q / n ) ≤ q + q log ( e n / q ) . □
Proposition 3.5 (Summation routine). Let A A A be a commutative Q \mathbb{Q} Q -algebra, let the factor system satisfy (11) , and let a design as in Definition 3.1 be given. With q q q and J J J as in (18) , the routine above computes Z Z Z by examining at most
2 Q r C q ( 2 D + 1 ) 2 τ n 2 2 n / r (30) 2QrC_q(2D+1)^{2\tau n}2^{2n/r} \tag*{(30)} 2 Q r C q ( 2 D + 1 ) 2 τ n 2 2 n / r (30) Boolean vectors; for each vector it evaluates at most ∣ F ∣ |\mathcal{F}| ∣ F ∣ factors in A [ z ] / ( z J ) A[z]/(z^J) A [ z ] / ( z J ) . The remaining operations per vector and the final interpolation are polynomially many operations in A A A and over Q \mathbb{Q} Q in n n n , ∣ F ∣ |\mathcal{F}| ∣ F ∣ , D D D , Q Q Q , R R R , J J J , r r r and M M M . Apart from the factor evaluators’ own storage the routine keeps polynomially many elements of A A A , rationals and index bits.5
Proof. There are Q Q Q points, C q C_q C q pairs per point, and at most (25) vectors per pair. Each group product uses at most ∣ F ∣ |\mathcal{F}| ∣ F ∣ factor evaluations, and addition and multiplication in A [ z ] / ( z J ) A[z]/(z^J) A [ z ] / ( z J ) cost O ( J 2 ) O(J^2) O ( J 2 ) operations in A A A . Correctness is (26) together with Hermite interpolation. The points, pairs, measurement tuples and local assignments are processed sequentially with their current indices and accumulators, which with the Q J QJ Q J interpolation data gives the storage bound. □
When d ≤ κ n d\le\kappa n d ≤ κn we have q ≤ κ n R / Q q\le\kappa nR/Q q ≤ κn R / Q , and (28) with η = R / Q \eta=R/Q η = R / Q gives
log C q ≤ q log Q R + n log ( 1 + 2 R Q ) ≤ κ n R Q log Q R + 2 n R Q ⋅ 1 ln 2 . (31) \log C_q\le q\log\frac{Q}{R}+n\log\left(1+\frac{2R}{Q}\right)\le\kappa n\frac{R}{Q}\log\frac{Q}{R}+\frac{2nR}{Q}\cdot\frac{1}{\ln2}. \tag*{(31)} log C q ≤ q log R Q + n log ( 1 + Q 2 R ) ≤ κn Q R log R Q + Q 2 n R ⋅ ln 2 1 . (31)
If factor evaluation and coefficient arithmetic cost polynomially many bit operations, the running time is a polynomial factor times
2 O ( n [ ( κ + 1 ) R Q log 2 Q R + τ log ( 2 D + 1 ) + 1 r ] ) . (32) 2^{O\left(n\left[(\kappa+1)\frac{R}{Q}\log\frac{2Q}{R}+\tau\log(2D+1)+\frac{1}{r}\right]\right)}. \tag*{(32)} 2 O ( n [ ( κ + 1 ) Q R l o g R 2 Q + τ l o g ( 2 D + 1 ) + r 1 ] ) . (32)
The three summands are the costs of recovering the Taylor coefficients, of enumerating the measurement values, and of enumerating the assignments of one group. Section 4 constructs a design for which all three are O ( ν 2 / λ ) O(\nu^2/\sqrt{\lambda}) O ( ν 2 / λ ) up to constants depending on κ \kappa κ and on the logarithmic exponent bounding b b b and w w w .
Constructing the design
The routine needs one row P ⃗ f , v ( T ) \vec{P}_{f,v}(T) P f , v ( T ) per incidence. This section constructs the rows and the matrices C t , g C_{t,g} C t , g , the partitions S t , g S_{t,g} S t , g and the group sequences σ f \sigma_f σ f of Definition 3.1 from the scopes alone, following [27 Section 4] . The difficulty is to keep deg P ⃗ f , v ≤ R \deg\vec{P}_{f,v} \le R deg P f , v ≤ R with R R R much smaller than Q Q Q : the degree of H H H grows linearly in R R R , and a small R / Q R/Q R / Q reduces the number of Taylor coefficients needed at each point. Rows chosen independently at the Q Q Q points and interpolated would in general have degree Q Q Q . The construction instead produces, on a complete array of auxiliary coordinates, rows whose values at all points are controlled together, and then places each incidence in a copy of that array.
Incidences and auxiliary coordinates
Write I = { ( f , v ) : f ∈ F , v ∈ I f } \mathcal{I} = \{(f,v) : f \in\mathcal{F},\ v \in I_f\} I = {( f , v ) : f ∈ F , v ∈ I f } , so M = ∣ I ∣ M = |\mathcal{I}| M = ∣ I ∣ , and let w w w and b b b be as in (7) . A factor with empty scope is a constant and is assigned to group one at every point. If necessary adjoin a constant-one factor with scope { v } \{v\} { v } for every v ∈ [ n ] v \in[n] v ∈ [ n ] ; this changes neither the product nor the sum, and raises b b b by at most one. With b b b the bound after this step we assume
n ≥ 1 , b , w ≥ 1 , n ≤ M ≤ b n . (33) n \ge1,\qquad b,w \ge1,\qquad n \le M \le bn. \tag*{(33)} n ≥ 1 , b , w ≥ 1 , n ≤ M ≤ bn . (33)
Throughout, r ≥ 2 r \ge2 r ≥ 2 and 1 ≤ R < Q 1 \le R < Q 1 ≤ R < Q are integers and 0 < τ ≤ 1 / 2 0 < \tau\le1/2 0 < τ ≤ 1/2 .
At each point t t t the variable x v x_v x v belongs to one group while a factor containing it may be assigned to another. We shall choose
a v ∈ [ r ] Q ( v ∈ [ n ] ) , δ f ∈ [ r ] Q ( f ∈ F ) , a_v \in[r]^Q\quad(v \in[n]),\qquad\delta_f \in[r]^Q\quad(f \in\mathcal{F}), a v ∈ [ r ] Q ( v ∈ [ n ]) , δ f ∈ [ r ] Q ( f ∈ F ) ,
where a v ( t ) a_v(t) a v ( t ) is the group of x v x_v x v and δ f ( t ) \delta_f(t) δ f ( t ) the group of f f f at the point t t t , and the incidence ( f , v ) (f,v) ( f , v ) will receive the label ( a v , δ f ) (a_v,\delta_f) ( a v , δ f ) . Before choosing them, take all possible labels,
B = ( [ r ] Q ) 2 , u = ( a u , δ u ) , D = ∣ B ∣ = r 2 Q . (34) \mathcal{B} = ([r]^Q)^2,\qquad u=(a_u,\delta_u),\qquad D=|\mathcal{B}|=r^{2Q}. \tag*{(34)} B = ([ r ] Q ) 2 , u = ( a u , δ u ) , D = ∣ B ∣ = r 2 Q . (34)
An auxiliary vector ζ ∈ Q B \zeta\in\mathbb{Q}^{\mathcal{B}} ζ ∈ Q B has one coordinate per label. For t ∈ [ Q ] t \in[Q] t ∈ [ Q ] and g ∈ [ r ] g \in[r] g ∈ [ r ] put
S t , g B = { u ∈ B : a u ( t ) = g } , (35) S^{{\mathcal{B}}}_{t,g}=\{u\in\mathcal{B}:a_u(t)=g\}, \tag*{(35)} S t , g B = { u ∈ B : a u ( t ) = g } , (35)
which for fixed t t t partition B \mathcal{B} B into r r r sets of size D / r D/r D / r . We seek, for each u ∈ B u \in\mathcal{B} u ∈ B , a row P ⃗ u ( T ) ∈ Q [ T ] 1 × B \vec{P}_u(T) \in\mathbb{Q}[T]^{1\times\mathcal{B}} P u ( T ) ∈ Q [ T ] 1 × B of degree at most R − 1 R-1 R − 1 with P ⃗ u ( 0 ) = e u \vec{P}_u(0)=e_u P u ( 0 ) = e u such that the value ⟨ P ⃗ u ( t ) , ζ ⟩ \langle\vec{P}_u(t),\zeta\rangle ⟨ P u ( t ) , ζ ⟩ is determined by ζ ∣ S t , δ u ( t ) B \zeta|_{S^{\mathcal{B}}_{t,\delta_u(t)}} ζ ∣ S t , δ u ( t ) B together with C B ζ C^{\mathcal{B}}\zeta C B ζ , where C B C^{\mathcal{B}} C B is one integer matrix with entries in { 0 , 1 , − 1 } \{0,1,-1\} { 0 , 1 , − 1 } and few rows, the same for all u u u and t t t .
The matrix M0 and the measurements CB
We seek M 0 ∈ Q B × B M_0\in\mathbb{Q}^{\mathcal{B}\times\mathcal{B}} M 0 ∈ Q B × B that fixes ker C B \ker C^{\mathcal{B}} ker C B and satisfies
M 0 [ u , y ] ≠ 0 ⟹ # { s ∈ [ Q ] : a y ( s ) ≠ δ u ( s ) } ≤ R − 1. (36) M_0[u,y]\ne0\Longrightarrow\#\{s\in[Q]:a_y(s)\ne\delta_u(s)\}\le R-1. \tag*{(36)} M 0 [ u , y ] = 0 ⟹ # { s ∈ [ Q ] : a y ( s ) = δ u ( s )} ≤ R − 1. (36)
The identity
ζ u = ( ( I − M 0 ) ζ ) u + ∑ y ∈ B M 0 [ u , y ] ζ y (37) \zeta_u=((I-M_0)\zeta)_u+\sum_{y\in\mathcal{B}}M_0[u,y]\zeta_y \tag*{(37)} ζ u = (( I − M 0 ) ζ ) u + y ∈ B ∑ M 0 [ u , y ] ζ y (37)
explains both requirements: the first term is determined by C B ζ C^{\mathcal{B}}\zeta C B ζ and will be left independent of T T T , and each term of the sum will be multiplied by a polynomial equal to one at zero and vanishing at every t t t with a y ( t ) ≠ δ u ( t ) a_y(t)\ne\delta_u(t) a y ( t ) = δ u ( t ) , which (36) allows with degree at most $R-1.
For s ∈ [ Q ] s\in[Q] s ∈ [ Q ] let ϑ s : B → B \vartheta_s:\mathcal{B}\to\mathcal{B} ϑ s : B → B exchange the entries a u ( s ) a_u(s) a u ( s ) and δ u ( s ) \delta_u(s) δ u ( s ) and leave the rest unchanged, and let Π s \Pi_s Π s be its permutation matrix, ( Π s ζ ) u = ζ ϑ s ( u ) (\Pi_s\zeta)_u=\zeta_{\vartheta_s(u)} ( Π s ζ ) u = ζ ϑ s ( u ) . The Π s \Pi_s Π s commute and Π s 2 = I \Pi_s^2=I Π s 2 = I . Put
V 0 = ∏ s = 1 Q Π s , W 0 = 1 2 ∑ s = 1 Q ( I − Π s ) . (38) V_0=\prod_{s=1}^{Q}\Pi_s,\qquad W_0=\frac{1}{2}\sum_{s=1}^{Q}(I-\Pi_s). \tag*{(38)} V 0 = s = 1 ∏ Q Π s , W 0 = 2 1 s = 1 ∑ Q ( I − Π s ) . (38)
V 0 V_0 V 0 exchanges the two full sequences, so V 0 [ u , y ] ≠ 0 V_0[u,y]\ne0 V 0 [ u , y ] = 0 forces a y = δ u a_y=\delta_u a y = δ u . On a common eigenvector ψ \psi ψ of the Π s \Pi_s Π s with Π s ψ = − ψ \Pi_s\psi=-\psi Π s ψ = − ψ for exactly j j j indices s s s ,
W 0 ψ = j ψ , V 0 ψ = ( − 1 ) j ψ , V 0 p ( W 0 ) ψ = ( − 1 ) j p ( j ) ψ (39) W_0\psi=j\psi,\qquad V_0\psi=(-1)^j\psi,\qquad V_0p(W_0)\psi=(-1)^jp(j)\psi \tag*{(39)} W 0 ψ = j ψ , V 0 ψ = ( − 1 ) j ψ , V 0 p ( W 0 ) ψ = ( − 1 ) j p ( j ) ψ (39)
for every polynomial p p p ; so V 0 p ( W 0 ) V_0p(W_0) V 0 p ( W 0 ) fixes ψ \psi ψ whenever p ( j ) = ( − 1 ) j p(j)=(-1)^j p ( j ) = ( − 1 ) j . For an interval J = { A 0 , … , A 0 + R − 1 } ⊆ { 0 , … , Q } \mathcal{J}=\{A_0,\ldots,A_0+R-1\}\subseteq\{0,\ldots,Q\} J = { A 0 , … , A 0 + R − 1 } ⊆ { 0 , … , Q } the polynomial
f J ( z ) = ( − 1 ) A 0 ∑ j = 0 R − 1 ( − 2 ) j ( z − A 0 j ) , ( z − A 0 j ) = 1 j ! ∏ a = 0 j − 1 ( z − A 0 − a ) , (40) f_{\mathcal{J}}(z)=(-1)^{A_0}\sum_{j=0}^{R-1}(-2)^j\binom{z-A_0}{j},\qquad\binom{z-A_0}{j}=\frac{1}{j!}\prod_{a=0}^{j-1}(z-A_0-a), \tag*{(40)} f J ( z ) = ( − 1 ) A 0 j = 0 ∑ R − 1 ( − 2 ) j ( j z − A 0 ) , ( j z − A 0 ) = j ! 1 a = 0 ∏ j − 1 ( z − A 0 − a ) , (40)
has degree at most R − 1 R-1 R − 1 and satisfies f J ( A 0 + i ) = ( − 1 ) A 0 ( 1 − 2 ) i = ( − 1 ) A 0 + i f_{\mathcal{J}}(A_0+i)=(-1)^{A_0}(1-2)^i=(-1)^{A_0+i} f J ( A 0 + i ) = ( − 1 ) A 0 ( 1 − 2 ) i = ( − 1 ) A 0 + i for 0 ≤ i < R 0\le i<R 0 ≤ i < R by the binomial theorem. Set
M 0 = V 0 f J ( W 0 ) . (41) M_0=V_0f_{\mathcal{J}}(W_0). \tag*{(41)} M 0 = V 0 f J ( W 0 ) . (41)
Lemma 4.1. There is a matrix C B ∈ { 0 , 1 , − 1 } c B × B C^{\mathcal{B}}\in\{0,1,-1\}^{c^{\mathcal{B}}\times\mathcal{B}} C B ∈ { 0 , 1 , − 1 } c B × B with c B ≤ D Pr [ W ∉ J ] c^{\mathcal{B}}\le D\Pr[W\notin\mathcal{J}] c B ≤ D Pr [ W ∈ / J ] , where W ∼ Bin ( Q , r − 1 2 r ) W\sim\operatorname{Bin}(Q,\frac{r-1}{2r}) W ∼ Bin ( Q , 2 r r − 1 ) , such that M 0 ξ = ξ M_0\xi=\xi M 0 ξ = ξ for every ξ ∈ ker C B \xi\in\ker C^{\mathcal{B}} ξ ∈ ker C B .6
Proof. For ( α , β ) ∈ [ r ] 2 (\alpha,\beta)\in[r]^2 ( α , β ) ∈ [ r ] 2 let e α β e_{\alpha\beta} e α β be the indicator function of that ordered pair. Exchanging the two entries of a pair has the orthogonal eigenbasis
e α α ( α ∈ [ r ] ) , e α β + e β α , e α β − e β α ( 1 ≤ α < β ≤ r ) , e_{\alpha\alpha}\;(\alpha\in[r]),\qquad e_{\alpha\beta}+e_{\beta\alpha},\qquad e_{\alpha\beta}-e_{\beta\alpha}\quad(1\le\alpha<\beta\le r), e α α ( α ∈ [ r ]) , e α β + e β α , e α β − e β α ( 1 ≤ α < β ≤ r ) ,
with eigenvalue + 1 +1 + 1 for the first two kinds and − 1 -1 − 1 for the third; there are r ( r + 1 ) / 2 r(r+1)/2 r ( r + 1 ) /2 vectors with eigenvalue $+1 and r ( r − 1 ) / 2 r(r-1)/2 r ( r − 1 ) /2 with $-1. For each s ∈ [ Q ] s\in[Q] s ∈ [ Q ] choose one of these r 2 r^2 r 2 functions, ψ s : [ r ] 2 → { 0 , 1 , − 1 } \psi_s:[r]^2\to\{0,1,-1\} ψ s : [ r ] 2 → { 0 , 1 , − 1 } , and put ψ ( u ) = ∏ s ψ s ( a u ( s ) , δ u ( s ) ) \psi(u)=\prod_s\psi_s(a_{u(s)},\delta_{u(s)}) ψ ( u ) = ∏ s ψ s ( a u ( s ) , δ u ( s ) ) . The D = r 2 Q D=r^{2Q} D = r 2 Q choices give nonzero pairwise orthogonal vectors, since their inner products factor over s s s , so they form a basis of Q B \mathbb{Q}^{\mathcal{B}} Q B with entries in { 0 , 1 , − 1 } \{0,1,-1\} { 0 , 1 , − 1 } . If exactly j j j of the chosen ψ s \psi_s ψ s have eigenvalue − 1 -1 − 1 , then W 0 ψ = j ψ W_0\psi=j\psi W 0 ψ = j ψ and V 0 ψ = ( − 1 ) j ψ V_0\psi=(-1)^j\psi V 0 ψ = ( − 1 ) j ψ by (39) , so M 0 M_0 M 0 fixes ψ \psi ψ whenever j ∈ J j\in\mathcal{J} j ∈ J . Let the rows of C B C^{\mathcal{B}} C B be the transposes of the basis vectors with j ∉ J j\notin\mathcal{J} j ∈ / J . A fraction ( r − 1 ) / ( 2 r ) (r-1)/(2r) ( r − 1 ) / ( 2 r ) of the choices at each position has eigenvalue − 1 -1 − 1 , independently over the positions, so the fraction of basis vectors retained is Pr [ W ∉ J ] \Pr[W\notin\mathcal{J}] Pr [ W ∈ / J ] . If C B ξ = 0 C^{\mathcal{B}}\xi=0 C B ξ = 0 then ξ \xi ξ is orthogonal to the retained vectors, hence a combination of the others, all of which M 0 M_0 M 0 fixes. □ \square □
For ϵ > 0 \epsilon>0 ϵ > 0 the condition
Pr [ Bin ( Q , r − 1 2 r ) ∉ J ] ≤ ϵ (42) \Pr\left[\operatorname{Bin}\left(Q,\frac{r-1}{2r}\right)\notin\mathcal{J}\right]\le\epsilon \tag*{(42)} Pr [ Bin ( Q , 2 r r − 1 ) ∈ / J ] ≤ ϵ (42)
gives c B ≤ ϵ D c^{\mathcal{B}}\le\epsilon D c B ≤ ϵD ; we shall use ϵ = τ / ( r b ) \epsilon=\tau/(rb) ϵ = τ / ( r b ) .
Lemma 4.2. If M 0 [ u , y ] ≠ 0 M_0[u,y]\ne0 M 0 [ u , y ] = 0 then # { s ∈ [ Q ] : a y ( s ) ≠ δ u ( s ) } ≤ R − 1 \#\{s\in[Q]:a_y(s)\ne\delta_u(s)\}\le R-1 # { s ∈ [ Q ] : a y ( s ) = δ u ( s )} ≤ R − 1 .7
Proof. Expand f J ( W 0 ) f_{\mathcal{J}}(W_0) f J ( W 0 ) in the commuting matrices Π s \Pi_s Π s . Since deg f J ≤ R − 1 \deg f_{\mathcal{J}}\le R-1 deg f J ≤ R − 1 and Π s 2 = I \Pi_s^2=I Π s 2 = I , each monomial is a scalar multiple of ∏ s ∈ K Π s \prod_{s\in K}\Pi_s ∏ s ∈ K Π s for some K ⊆ [ Q ] K\subseteq[Q] K ⊆ [ Q ] with ∣ K ∣ ≤ R − 1 |K|\le R-1 ∣ K ∣ ≤ R − 1 , and V 0 ∏ s ∈ K Π s = ∏ s ∉ K Π s V_0\prod_{s\in K}\Pi_s=\prod_{s\notin K}\Pi_s V 0 ∏ s ∈ K Π s = ∏ s ∈ / K Π s . A nonzero ( u , y ) (u,y) ( u , y ) entry of this permutation matrix requires a y ( s ) = δ u ( s ) a_y(s)=\delta_u(s) a y ( s ) = δ u ( s ) for every s ∉ K s\notin K s ∈ / K , leaving at most R − 1 R-1 R − 1 positions where they may differ. If more than R − 1 R-1 R − 1 positions disagree, every summand has zero ( u , y ) (u,y) ( u , y ) entry. □ \square □
The auxiliary rows
For M 0 [ u , y ] ≠ 0 M_0[u,y] \ne0 M 0 [ u , y ] = 0 put
E u , y = { s ∈ [ Q ] : a y ( s ) ≠ δ u ( s ) } , φ u , y ( T ) = ∏ s ∈ E u , y ( 1 − T s ) , (43) E_{u,y} = \{s \in[Q] : a_y(s) \ne\delta_u(s)\}, \qquad\varphi_{u,y}(T) = \prod_{s \in E_{u,y}} \left(1 - \frac{T}{s}\right), \tag*{(43)} E u , y = { s ∈ [ Q ] : a y ( s ) = δ u ( s )} , φ u , y ( T ) = s ∈ E u , y ∏ ( 1 − s T ) , (43)
the empty product being one; then deg φ u , y ≤ R − 1 \deg\varphi_{u,y} \le R - 1 deg φ u , y ≤ R − 1 , φ u , y ( 0 ) = 1 \varphi_{u,y}(0) = 1 φ u , y ( 0 ) = 1 , and φ u , y ( t ) = 0 \varphi_{u,y}(t) = 0 φ u , y ( t ) = 0 whenever a y ( t ) ≠ δ u ( t ) a_y(t) \ne\delta_u(t) a y ( t ) = δ u ( t ) . Define
P ⃗ u ( T ) = e ⃗ u T ( I − M 0 ) + ∑ y ∈ B M 0 [ u , y ] ≠ 0 M 0 [ u , y ] φ u , y ( T ) e ⃗ y T . (44) \vec{P}_u(T) = \vec{e}_u^{\mathsf{T}}(I-M_0) + \sum_{\substack{y \in\mathcal{B} \\ M_0[u,y] \ne0}} M_0[u,y]\varphi_{u,y}(T)\vec{e}_y^{\mathsf{T}}. \tag*{(44)} P u ( T ) = e u T ( I − M 0 ) + y ∈ B M 0 [ u , y ] = 0 ∑ M 0 [ u , y ] φ u , y ( T ) e y T . (44)
Lemma 4.3. The rows (44) have degree at most R − 1 R-1 R − 1 and P ⃗ u ( 0 ) = e ⃗ u T \vec{P}_u(0)=\vec{e}_u^{\mathsf{T}} P u ( 0 ) = e u T . For t ∈ [ Q ] t \in[Q] t ∈ [ Q ] and g ∈ [ r ] g \in[r] g ∈ [ r ] let C t , g B C^B_{t,g} C t , g B be the restriction of C B C^B C B to the columns S t , g B S^B_{t,g} S t , g B . For every u u u , t t t and g ≠ δ u ( t ) g \ne\delta_u(t) g = δ u ( t ) , and every ξ ∈ Q S t , g B \xi\in\mathbb{Q}^{S^B_{t,g}} ξ ∈ Q S t , g B ,
C t , g B ξ = 0 ⟹ ⟨ P ⃗ u ( t ) , ξ ~ ⟩ = 0. C^B_{t,g}\xi= 0 \implies\langle\vec{P}_u(t), \tilde{\xi}\rangle= 0. C t , g B ξ = 0 ⟹ ⟨ P u ( t ) , ξ ~ ⟩ = 0. More generally, ⟨ P ⃗ u ( t ) , ζ ⟩ \langle\vec{P}_u(t),\zeta\rangle ⟨ P u ( t ) , ζ ⟩ is determined by ζ ∣ S t , δ u ( t ) B \zeta|_{S^B_{t,\delta_u(t)}} ζ ∣ S t , δ u ( t ) B and C B ζ C^B\zeta C B ζ .
Proof. The degree bound is that of the φ u , y \varphi_{u,y} φ u , y , and P ⃗ u ( 0 ) = e ⃗ u T ( I − M 0 ) + e ⃗ u T M 0 = e ⃗ u T \vec{P}_u(0)=\vec{e}_u^{\mathsf{T}}(I-M_0)+\vec{e}_u^{\mathsf{T}}M_0=\vec{e}_u^{\mathsf{T}} P u ( 0 ) = e u T ( I − M 0 ) + e u T M 0 = e u T . Applying (44) to ζ \zeta ζ ,
⟨ P ⃗ u ( T ) , ζ ⟩ = ( ( I − M 0 ) ζ ) u + ∑ M 0 [ u , y ] ≠ 0 M 0 [ u , y ] φ u , y ( T ) ζ y . (45) \langle\vec{P}_u(T),\zeta\rangle= ((I-M_0)\zeta)_u + \sum_{M_0[u,y]\ne0} M_0[u,y]\varphi_{u,y}(T)\zeta_y. \tag*{(45)} ⟨ P u ( T ) , ζ ⟩ = (( I − M 0 ) ζ ) u + M 0 [ u , y ] = 0 ∑ M 0 [ u , y ] φ u , y ( T ) ζ y . (45)
At T = t T=t T = t every summand with a y ( t ) ≠ δ u ( t ) a_y(t)\ne\delta_u(t) a y ( t ) = δ u ( t ) vanishes, so the remaining summands involve only y ∈ S t , δ u ( t ) B y\in S^B_{t,\delta_u(t)} y ∈ S t , δ u ( t ) B ; if ξ ~ \tilde{\xi} ξ ~ is supported on S t , g B S^B_{t,g} S t , g B with g ≠ δ u ( t ) g\ne\delta_u(t) g = δ u ( t ) they are zero on ξ ~ \tilde{\xi} ξ ~ . The hypothesis C t , g B ξ = 0 C^B_{t,g}\xi=0 C t , g B ξ = 0 gives C B ξ ~ = 0 C^B\tilde{\xi}=0 C B ξ ~ = 0 , so ( I − M 0 ) ξ ~ = 0 (I-M_0)\tilde{\xi}=0 ( I − M 0 ) ξ ~ = 0 by Lemma 4.1 . For the last assertion, two vectors with the same value of C B ζ C^B\zeta C B ζ differ by an element of ker C B \ker C^B ker C B , so ( I − M 0 ) ζ (I-M_0)\zeta ( I − M 0 ) ζ is determined by C B ζ C^B\zeta C B ζ , and the other terms at T = t T=t T = t use only ζ ∣ S t , δ u ( t ) B \zeta|_{S^B_{t,\delta_u(t)}} ζ ∣ S t , δ u ( t ) B .
Fixing t t t and writing ζ g = ζ ∣ S t , g B \zeta_g=\zeta|_{S^B_{t,g}} ζ g = ζ ∣ S t , g B we have C B ζ = ∑ g C t , g B ζ g C^B\zeta=\sum_g C^B_{t,g}\zeta_g C B ζ = ∑ g C t , g B ζ g , so fixing each of the r r r vectors C t , g B ζ g C^B_{t,g}\zeta_g C t , g B ζ g fixes C B ζ C^B\zeta C B ζ while imposing separate conditions on the r r r auxiliary groups; then ⟨ P ⃗ u ( t ) , ζ ⟩ \langle\vec{P}_u(t),\zeta\rangle ⟨ P u ( t ) , ζ ⟩ depends on ζ ∣ S t , δ u ( t ) B \zeta|_{S^B_{t,\delta_u(t)}} ζ ∣ S t , δ u ( t ) B alone.
Choosing the groups
We now choose ( a v ) v (a_v)_v ( a v ) v and ( δ f ) f (\delta_f)_f ( δ f ) f and set u f , v = ( a v , δ f ) u_{f,v}=(a_v,\delta_f) u f , v = ( a v , δ f ) for ( f , v ) ∈ I (f,v)\in\mathcal{I} ( f , v ) ∈ I . A label u u u occurring c u c_u c u times needs c u c_u c u positions in distinct copies of the auxiliary array, so the number of copies is
h = max u ∈ B c u , c u = # { ( f , v ) ∈ I : u f , v = u } , (46) h=\max_{u\in\mathcal{B}} c_u,\qquad c_u=\#\{(f,v)\in\mathcal{I}:u_{f,v}=u\}, \tag*{(46)} h = u ∈ B max c u , c u = # {( f , v ) ∈ I : u f , v = u } , (46)
and the actual variable groups { v : a v ( t ) = g } \{v:a_v(t)=g\} { v : a v ( t ) = g } must be small.
Lemma 4.4. Assume (33) , let D = r 2 Q D=r^{2Q} D = r 2 Q and suppose
2 ( b + w ) D 2 ≤ M , 2 Q r 2 ≤ n . (47) 2(b+w)D^2\le M,\qquad2Qr^2\le n. \tag*{(47)} 2 ( b + w ) D 2 ≤ M , 2 Q r 2 ≤ n . (47) One can choose a v , δ f ∈ [ r ] Q a_v,\delta_f\in[r]^Q a v , δ f ∈ [ r ] Q deterministically, with δ f ≡ 1 \delta_f\equiv1 δ f ≡ 1 for factors of empty scope, such that
max u ∈ B # { ( f , v ) ∈ I : ( a v , δ f ) = u } ≤ 2 M D , # { v : a v ( t ) = g } ≤ 2 n r ( t ∈ [ Q ] , g ∈ [ r ] ) , \max_{u\in\mathcal{B}}\#\{(f,v)\in\mathcal{I}:(a_v,\delta_f)=u\}\le\frac{2M}{D},\qquad\#\{v:a_v(t)=g\}\le\frac{2n}{r}\quad(t\in[Q],\ g\in[r]), u ∈ B max # {( f , v ) ∈ I : ( a v , δ f ) = u } ≤ D 2 M , # { v : a v ( t ) = g } ≤ r 2 n ( t ∈ [ Q ] , g ∈ [ r ]) , in poly ( n , M , ∣ F ∣ , D , Q , r , b , w ) \operatorname{poly}(n,M,|\mathcal{F}|,D,Q,r,b,w) poly ( n , M , ∣ F ∣ , D , Q , r , b , w ) bit operations. 8
Proof. First let all a v a_v a v , and all δ f \delta_f δ f with nonempty I f I_f I f , be independent and uniform on [ r ] Q [r]^{Q} [ r ] Q ; then each label u f , v u_{f,v} u f , v is uniform on B \mathcal{B} B . Put n t , g = # { v : a v ( t ) = g } n_{t,g}=\#\{v:a_v(t)=g\} n t , g = # { v : a v ( t ) = g } and
Φ = ∑ u ∈ B ( c u − M D ) 2 , Ξ = ∑ t = 1 Q ∑ g = 1 r ( n t , g − n r ) 2 . \Phi=\sum_{u\in\mathcal{B}}\left(c_u-\frac{M}{D}\right)^2,\qquad\Xi=\sum_{t=1}^{Q}\sum_{g=1}^{r}\left(n_{t,g}-\frac{n}{r}\right)^2. Φ = u ∈ B ∑ ( c u − D M ) 2 , Ξ = t = 1 ∑ Q g = 1 ∑ r ( n t , g − r n ) 2 .
Expanding the squares,
Φ = ∑ ( f , v ) , ( f ′ , v ′ ) ∈ I 1 { ( a v , δ f ) = ( a v ′ , δ f ′ ) } − M 2 D , Ξ = ∑ t = 1 Q ∑ v , v ′ ∈ [ n ] 1 { a v ( t ) = a v ′ ( t ) } − Q n 2 r . \Phi=\sum_{(f,v),(f',v')\in\mathcal{I}}\mathbf{1}\{(a_v,\delta_f)=(a_{v'},\delta_{f'})\}-\frac{M^2}{D},\qquad\Xi=\sum_{t=1}^{Q}\sum_{v,v'\in[n]}\mathbf{1}\{a_v(t)=a_{v'}(t)\}-\frac{Qn^2}{r}. Φ = ( f , v ) , ( f ′ , v ′ ) ∈ I ∑ 1 {( a v , δ f ) = ( a v ′ , δ f ′ )} − D M 2 , Ξ = t = 1 ∑ Q v , v ′ ∈ [ n ] ∑ 1 { a v ( t ) = a v ′ ( t )} − r Q n 2 .
Two labels are independent unless they share a factor or a variable, and each ( f , v ) (f,v) ( f , v ) shares one with at most b + w b+w b + w incidences including itself. Independent pairs are equal with probability 1 / D 1/D 1/ D , the others with probability at most one, so E Φ ≤ M ( b + w ) \mathbb{E}\Phi\le M(b+w) E Φ ≤ M ( b + w ) . For v ≠ v ′ v\ne v' v = v ′ the values a v ( t ) , a v ′ ( t ) a_v(t),a_{v'}(t) a v ( t ) , a v ′ ( t ) are independent and uniform, so E Ξ = Q n ( 1 − 1 / r ) ≤ Q n \mathbb{E}\Xi=Qn(1-1/r)\le Qn E Ξ = Q n ( 1 − 1/ r ) ≤ Q n .
To fix the choices deterministically, fix the a v a_v a v and the δ f \delta_f δ f with nonempty scope one at a time, each time choosing a value that does not increase the conditional expectation of Φ / ( M ( b + w ) ) + Ξ / ( Q n ) \Phi/(M(b+w))+\Xi/(Qn) Φ/ ( M ( b + w )) + Ξ/ ( Q n ) ; such a value exists because the current expectation is the average over the possible values of the next choice. The final value is at most two, and both summands are nonnegative, so
c u ≤ M D + 2 M ( b + w ) , n t , g ≤ n r + 2 Q n . c_u\le\frac{M}{D}+\sqrt{2M(b+w)},\qquad n_{t,g}\le\frac{n}{r}+\sqrt{2Qn}. c u ≤ D M + 2 M ( b + w ) , n t , g ≤ r n + 2 Q n .
The inequalities (47) bound the square roots by M / D M/D M / D and n / r n/r n / r .
For the cost, put K = r Q K=r^Q K = r Q , so D = K 2 D=K^2 D = K 2 . Each indicator in Φ \Phi Φ depends on at most four of the choices a v , δ f , a v ′ , δ f ′ a_v,\delta_f,a_{v'},\delta_{f'} a v , δ f , a v ′ , δ f ′ , and each indicator in Ξ \Xi Ξ on at most two. After any partial fixing, the conditional probability of an indicator is computed by enumerating at most K 4 = D 2 K^4=D^2 K 4 = D 2 values of the unfixed choices it involves, and has denominator dividing K 4 K^4 K 4 . Summing the M 2 + Q n 2 M^2+Qn^2 M 2 + Q n 2 indicators gives both expectations, with all rationals of O ( log ( 2 D ) + log ( 2 M ) + log ( 2 n ) + log ( 2 Q ) + log ( 2 + b + w ) ) O(\log(2D)+\log(2M)+\log(2n)+\log(2Q)+\log(2+b+w)) O ( log ( 2 D ) + log ( 2 M ) + log ( 2 n ) + log ( 2 Q ) + log ( 2 + b + w )) bits. There are at most n + ∣ F ∣ n+|\mathcal{F}| n + ∣ F ∣ choices to fix, each with K K K candidates.
Placing copies of the variables
Assume (47) and apply Lemma 4.4. Index h h h copies of the auxiliary array by [ h ] × B [h]\times\mathcal{B} [ h ] × B , and assign to each ( f , v ) ∈ I (f,v)\in\mathcal{I} ( f , v ) ∈ I a copy c ( f , v ) ∈ [ h ] c(f,v)\in[h] c ( f , v ) ∈ [ h ] so that the positions ( c ( f , v ) , u f , v ) (c(f,v),u_{f,v}) ( c ( f , v ) , u f , v ) are distinct; this is possible since no label occurs more than h h h times, and
h D ≤ 2 M ≤ 2 b n . (48) hD\le2M\le2bn. \tag*{(48)} h D ≤ 2 M ≤ 2 bn . (48)
Define ι : Q n → Q [ h ] × B \iota:\mathbb{Q}^{n}\to\mathbb{Q}^{[h]\times\mathcal{B}} ι : Q n → Q [ h ] × B by ( ι x ) c , u = x v (\iota x)_{c,u}=x_v ( ι x ) c , u = x v if ( c , u ) = ( c ( f , v ) , u f , v ) (c,u)=(c(f,v),u_{f,v}) ( c , u ) = ( c ( f , v ) , u f , v ) for some ( f , v ) ∈ I (f,v)\in\mathcal{I} ( f , v ) ∈ I , and 0 0 0 otherwise; the occupied positions are distinct, so this is well defined. Several positions may contain the same x v x_v x v , and unused positions are zero. Let π c : Q [ h ] × B → Q B \pi_c:\mathbb{Q}^{[h]\times\mathcal{B}}\to\mathbb{Q}^{\mathcal{B}} π c : Q [ h ] × B → Q B be the projection onto the copy c c c . Put
P ⃗ f , v ( T ) = P ⃗ u f , v ( T ) π c ( f , v ) ι , S t , g = { v : a v ( t ) = g } , σ f ( t ) = δ f ( t ) . (49) \vec{P}_{f,v}(T)=\vec{P}_{u_{f,v}}(T)\,\pi_{c(f,v)}\,\iota,\qquad S_{t,g}=\{v:a_v(t)=g\},\qquad\sigma_f(t)=\delta_f(t). \tag*{(49)} P f , v ( T ) = P u f , v ( T ) π c ( f , v ) ι , S t , g = { v : a v ( t ) = g } , σ f ( t ) = δ f ( t ) . (49)
At T = 0 T=0 T = 0 the row P ⃗ f , v \vec{P}_{f,v} P f , v extracts the content of position ( c ( f , v ) , u f , v ) (c(f,v),u_{f,v}) ( c ( f , v ) , u f , v ) , which is x v x_v x v ; so P ⃗ f , v ( 0 ) = e v T \vec{P}_{f,v}(0)=e_v^{\mathsf T} P f , v ( 0 ) = e v T , and its degree is at most R − 1 R-1 R − 1 . Lemma 4.4 gives ∣ S t , g ∣ ≤ 2 n / r |S_{t,g}|\le2n/r ∣ S t , g ∣ ≤ 2 n / r . Define
C ~ = diag ( C B , … , C B ) ( h copies ) , C ^ = C ~ U , C t , g = C ^ ∣ S t , g . (50) \widetilde{C}=\operatorname{diag}(C^{\mathcal{B}},\ldots,C^{\mathcal{B}})\quad(h\text{ copies}),\qquad\widehat{C}=\widetilde{C}_{\mathcal{U}},\qquad C_{t,g}=\widehat{C}|_{S_{t,g}}. \tag*{(50)} C = diag ( C B , … , C B ) ( h copies ) , C = C U , C t , g = C ∣ S t , g . (50)
the restriction keeping the columns in S t , g S_{t,g} S t , g and all rows. Thus C ^ x \widehat{C}x C x records the auxiliary measurements in every copy after the copies have been filled from x x x . Each row of C ^ \widehat{C} C has at most D D D nonzero entries, all ± 1 \pm1 ± 1 ; multiplication by ι \iota ι adds entries lying in a common column and discards unused positions, so every row of C t , g C_{t,g} C t , g has sum of absolute values at most D D D , and its value on a Boolean vector lies in [ − D , D ] ∩ Z [-D,D]\cap\mathbb{Z} [ − D , D ] ∩ Z . If (42) holds, each C t , g C_{t,g} C t , g has h c B hc^{\mathcal{B}} h c B rows, and
∑ g = 1 r c t , g = r h c B ≤ r h e D ≤ 2 r e M ≤ 2 r e b n , (51) \sum_{g=1}^{r} c_{t,g}=rhc^{\mathcal{B}}\le rheD\le2reM\le2rebn, \tag*{(51)} g = 1 ∑ r c t , g = r h c B ≤ r h eD ≤ 2 r e M ≤ 2 r e bn , (51)
which with ϵ = τ / ( r b ) \epsilon=\tau/(rb) ϵ = τ / ( r b ) is at most 2 τ n 2\tau n 2 τ n .
For the kernel condition fix t t t , g ≠ σ f ( t ) g\ne\sigma_f(t) g = σ f ( t ) and ( f , v ) (f,v) ( f , v ) , and let ξ ∈ Q S t , g \xi\in\mathbb{Q}^{S_{t,g}} ξ ∈ Q S t , g with C t , g ξ = 0 C_{t,g}\xi=0 C t , g ξ = 0 . Then C ~ ξ ~ = 0 \widetilde{C}\widetilde{\xi}=0 C ξ = 0 , so C B π c ξ ~ = 0 C^{\mathcal{B}}\pi_c\widetilde{\xi}=0 C B π c ξ = 0 for every copy c c c . Every nonzero coordinate of π c ξ ~ \pi_c\widetilde{\xi} π c ξ contains a variable v ′ v' v ′ with a v ′ ( t ) = g a_{v'}(t)=g a v ′ ( t ) = g , whose label has first sequence a v ′ a_{v'} a v ′ , so this vector is supported on S t , g B S^\mathcal{B}_{t,g} S t , g B . Lemma 4.3 in the copy c ( f , v ) c(f,v) c ( f , v ) , where δ u f , v ( t ) = δ f ( t ) = σ f ( t ) ≠ g \delta_{u_{f,v}}(t)=\delta_f(t)=\sigma_f(t)\ne g δ u f , v ( t ) = δ f ( t ) = σ f ( t ) = g , gives ⟨ P ⃗ f , v ( t ) , ξ ~ ⟩ = ⟨ P ⃗ u f , v ( t ) , π c ( f , v ) ξ ~ ⟩ = 0 \langle\vec{P}_{f,v}(t),\widetilde{\xi}\rangle=\langle\vec{P}_{u_{f,v}}(t),\pi_{c(f,v)}\widetilde{\xi}\rangle=0 ⟨ P f , v ( t ) , ξ ⟩ = ⟨ P u f , v ( t ) , π c ( f , v ) ξ ⟩ = 0 , which is (14) . All inputs of a factor use the group δ f ( t ) \delta_f(t) δ f ( t ) , and the sum still ranges over exactly the n n n Boolean variables.
Coefficient bounds
Lemma 4.5. Let d d e n = ( R − 1 ) ! Q ! d_{\mathrm{den}}=(R-1)!Q! d den = ( R − 1 )! Q ! . Then d d e n P ⃗ u ( T ) ∈ Z [ T ] 1 × B d_{\mathrm{den}}\vec{P}_u(T)\in\mathbb{Z}[T]^{1\times B} d den P u ( T ) ∈ Z [ T ] 1 × B for every u u u , and the sum of the absolute values of all coefficients of d d e n P ⃗ u ( T ) d_{\mathrm{den}}\vec{P}_u(T) d den P u ( T ) is 2 O ( Q log Q ) 2^{O(Q\log Q)} 2 O ( Q l o g Q ) . The same holds for d d e n P ⃗ f , v ( T ) d_{\mathrm{den}}\vec{P}_{f,v}(T) d den P f , v ( T ) . The matrices M 0 M_0 M 0 , C B C^{\mathcal{B}} C B and the rows can be constructed in poly ( D , Q , r ) \operatorname{poly}(D,Q,r) poly ( D , Q , r ) bit operations.10
Proof. For 0 ≤ j < R 0\le j<R 0 ≤ j < R the j j j th summand of f J ( W 0 ) f_J(W_0) f J ( W 0 ) is
( − 1 ) A 0 ( − 2 ) j ( W 0 − A 0 I j ) = ( − 1 ) A 0 + j j ! ∏ a = 0 j − 1 ( 2 W 0 − 2 ( A 0 + a ) I ) , (-1)^{A_0}(-2)^j\binom{W_0-A_0I}{j}
=\frac{(-1)^{A_0+j}}{j!}\prod_{a=0}^{j-1}(2W_0-2(A_0+a)I), ( − 1 ) A 0 ( − 2 ) j ( j W 0 − A 0 I ) = j ! ( − 1 ) A 0 + j a = 0 ∏ j − 1 ( 2 W 0 − 2 ( A 0 + a ) I ) ,
and each factor on the right is an integer matrix because 2 W 0 = Q I − ∑ s Π s 2W_0=QI-\sum_s\Pi_s 2 W 0 = Q I − ∑ s Π s . Since j ! j! j ! divides ( R − 1 ) ! (R-1)! ( R − 1 )! and V 0 V_0 V 0 is a permutation matrix, ( R − 1 ) ! M 0 (R-1)!M_0 ( R − 1 )! M 0 is integral. The denominators of φ u , y \varphi_{u,y} φ u , y divide ∏ s ∈ E u , y s \prod_{s\in E_{u,y}}s ∏ s ∈ E u , y s , which divides Q ! Q! Q ! . This proves the common denominator. With ∥ A ∥ ∞ = max i ∑ j ∣ A [ i , j ] ∣ \lVert A\rVert_\infty=\max_i\sum_j|A[i,j]| ∥ A ∥ ∞ = max i ∑ j ∣ A [ i , j ] ∣ and ∥ ∑ j a j T j ∥ 1 = ∑ j ∣ a j ∣ \lVert\sum_j a_jT^j\rVert_1=\sum_j|a_j| ∥ ∑ j a j T j ∥ 1 = ∑ j ∣ a j ∣ , we have ∥ W 0 ∥ ∞ ≤ Q \lVert W_0\rVert_\infty\le Q ∥ W 0 ∥ ∞ ≤ Q and 0 ≤ A 0 + a ≤ Q 0\le A_0+a\le Q 0 ≤ A 0 + a ≤ Q , so each factor 2 W 0 − 2 ( A 0 + a ) I 2W_0-2(A_0+a)I 2 W 0 − 2 ( A 0 + a ) I has norm at most 4 Q 4Q 4 Q , whence
∥ M 0 ∥ ∞ ≤ R ( 4 Q ) R − 1 , ∥ φ u , y ∥ 1 ≤ ∏ s ∈ E u , y ( 1 + 1 s ) ≤ 2 Q . \lVert M_0\rVert_\infty\le R(4Q)^{R-1},\qquad
\lVert\varphi_{u,y}\rVert_1\le\prod_{s\in E_{u,y}}\left(1+\frac{1}{s}\right)\le2^Q. ∥ M 0 ∥ ∞ ≤ R ( 4 Q ) R − 1 , ∥ φ u , y ∥ 1 ≤ s ∈ E u , y ∏ ( 1 + s 1 ) ≤ 2 Q .
The sum of absolute values of the coefficients in the row d d e n P ⃗ u d_{\mathrm{den}}\vec{P}_u d den P u is at most d d e n ( 1 + ( 1 + 2 Q ) R ( 4 Q ) R − 1 ) d_{\mathrm{den}}(1+(1+2^Q)R(4Q)^{R-1}) d den ( 1 + ( 1 + 2 Q ) R ( 4 Q ) R − 1 ) , whose logarithm is O ( Q log Q ) O(Q\log Q) O ( Q log Q ) since R < Q R<Q R < Q . Passing to P ⃗ f , v \vec{P}_{f,v} P f , v by (49) adds coefficients in common columns and discards others, so the bound persists. Enumerating the eigenbasis, forming f J ( W 0 ) f_J(W_0) f J ( W 0 ) and the φ u , y \varphi_{u,y} φ u , y takes poly ( D , Q , r ) \operatorname{poly}(D,Q,r) poly ( D , Q , r ) arithmetic operations on rationals of O ( Q log Q ) O(Q\log Q) O ( Q log Q ) bits. □
Lemma 4.6 (The completed design). Let n , b , w ≥ 1 n,b,w\ge1 n , b , w ≥ 1 and let ( I f ) f ∈ F (I_f)_{f\in\mathcal{F}} ( I f ) f ∈ F be subsets of [ n ] [n] [ n ] of size at most w w w with each v v v in at most b b b of them, M = ∑ f ∣ I f ∣ M=\sum_{f}|I_f| M = ∑ f ∣ I f ∣ and n ≤ M ≤ b n n\le M\le bn n ≤ M ≤ bn . Let r ≥ 2 r\ge2 r ≥ 2 , 1 ≤ R < Q 1\le R<Q 1 ≤ R < Q , 0 < τ ≤ 1 / 2 0<\tau\le1/2 0 < τ ≤ 1/2 and D = r 2 Q D=r^{2Q} D = r 2 Q satisfy (47) , and let an interval J = { A 0 , … , A 0 + R − 1 } ⊆ { 0 , … , Q } J=\{A_0,\ldots,A_0+R-1\}\subseteq\{0,\ldots,Q\} J = { A 0 , … , A 0 + R − 1 } ⊆ { 0 , … , Q } satisfy
Pr [ Bin ( Q , r − 1 2 r ) ∉ J ] ≤ τ r b . (52) \Pr\left[\operatorname{Bin}\left(Q,\frac{r-1}{2r}\right)\notin J\right]\le\frac{\tau}{rb}. \tag*{(52)} Pr [ Bin ( Q , 2 r r − 1 ) ∈ / J ] ≤ r b τ . (52) Then all the data of Definition 3.1 can be constructed deterministically with a number of bit operations polynomial in n n n , M M M , ∣ F ∣ |\mathcal{F}| ∣ F ∣ , D D D , Q Q Q , r r r , b b b and w w w .11
Proof. Lemma 4.1 gives C B \mathcal{C}^{\mathcal{B}} C B with c B ≤ τ D / ( r b ) c_{\mathcal{B}} \le\tau D/(rb) c B ≤ τ D / ( r b ) ; Lemmas 4.2 and 4.3 give the auxiliary rows; Lemma 4.4 gives the groups with h D ≤ 2 M h_D \le2M h D ≤ 2 M and ∣ S t , g ∣ ≤ 2 n / r |S_{t,g}| \le2n/r ∣ S t , g ∣ ≤ 2 n / r . The maps (49) and (50) give rows with P ⃗ f , v ( 0 ) = e v T \vec{P}_{f,v}(0) = \mathbf{e}_v^{\mathsf{T}} P f , v ( 0 ) = e v T , degree at most R − 1 ≤ R R-1 \le R R − 1 ≤ R , and the kernel condition; every row of C t , g C_{t,g} C t , g has absolute row sum at most D D D , and (51) gives ∑ g c t , g ≤ 2 τ n \sum_g c_{t,g} \le2\tau n ∑ g c t , g ≤ 2 τ n . Lemma 4.5 gives (D5). □
Choosing the parameters
The exponent of the routine depends on the three quantities of (32) . The following choice bounds all three when b b b and w w w are bounded by a fixed power of log n \log n log n .
Lemma 4.7 (Parameters). Fix an integer β ≥ 1 \beta\ge1 β ≥ 1 . Let n ≥ 20 n \ge20 n ≥ 20 , λ = ⌈ log n ⌉ \lambda= \lceil\log n \rceil λ = ⌈ log n ⌉ , ν = ⌈ log λ ⌉ \nu= \lceil\log\lambda\rceil ν = ⌈ log λ ⌉ , and suppose b , w ≤ λ β b,w \le\lambda^\beta b , w ≤ λ β and n ≤ M ≤ b n n \le M \le bn n ≤ M ≤ bn . For all sufficiently large n n n the parameters
r = ⌈ λ ν 2 ⌉ , Q = ⌈ λ 128 ν ⌉ , R = ( β + 3 ) ⌈ λ ⌉ , τ = 1 r λ , ϵ = 1 b r 2 λ , D = r 2 Q , (53) r = \left\lceil\frac{\sqrt{\lambda}}{\nu^2} \right\rceil,\qquad Q = \left\lceil\frac{\lambda}{128\nu} \right\rceil,\qquad R = (\beta+3)\lceil\sqrt{\lambda}\rceil,\qquad\tau= \frac{1}{r\lambda},\qquad\epsilon= \frac{1}{br^2\lambda},\qquad D = r^{2Q}, \tag*{(53)} r = ⌈ ν 2 λ ⌉ , Q = ⌈ 128 ν λ ⌉ , R = ( β + 3 ) ⌈ λ ⌉ , τ = r λ 1 , ϵ = b r 2 λ 1 , D = r 2 Q , (53) with the interval J J J specified in the proof, satisfy the hypotheses of Lemma 4.6; moreover R ≥ 32 R \ge32 R ≥ 32 , 6 R ≤ Q 6R \le Q 6 R ≤ Q , D ≤ 2 λ / 128 D \le2^{\lambda/128} D ≤ 2 λ /128 , and
R Q log 2 Q R + τ log ( 2 D + 1 ) + 1 r = O β ( ν 2 λ ) . (54) \frac{R}{Q}\log\frac{2Q}{R}+\tau\log(2D+1)+\frac{1}{r}=O_\beta\left(\frac{\nu^2}{\sqrt{\lambda}}\right). \tag*{(54)} Q R log R 2 Q + τ log ( 2 D + 1 ) + r 1 = O β ( λ ν 2 ) . (54)
Given n n n , M M M , b b b , w w w the parameters can be computed and the hypotheses checked in poly β ( log n ) \operatorname{poly}_{\beta}(\log n) poly β ( log n ) bit operations, and for fixed β \beta β only finitely many n n n fail the checks.12
Proof. For large n n n , r = Θ ( λ / ν 2 ) r = \Theta(\sqrt{\lambda}/\nu^2) r = Θ ( λ / ν 2 ) , Q = Θ ( λ / ν ) Q = \Theta(\lambda/\nu) Q = Θ ( λ / ν ) and R = Θ β ( λ ) R = \Theta_{\beta}(\sqrt{\lambda}) R = Θ β ( λ ) ; so eventually r ≥ 2 r \ge2 r ≥ 2 , R ≥ 32 R \ge32 R ≥ 32 and 6 R ≤ Q 6R \le Q 6 R ≤ Q . Since log r ≤ ν / 2 \log r \le\nu/2 log r ≤ ν /2 , log D = 2 Q log r ≤ λ / 128 \log D = 2Q\log r \le\lambda/128 log D = 2 Q log r ≤ λ /128 . The balance inequalities (47) hold for large n n n : 2 ( b + w ) D 2 ≤ 4 λ / 2 λ / 64 ≤ n ≤ M 2(b+w)D^2 \le4\lambda/2^{\lambda/64} \le n \le M 2 ( b + w ) D 2 ≤ 4 λ / 2 λ /64 ≤ n ≤ M and 2 Q r 2 ≤ n 2Qr^2 \le n 2 Q r 2 ≤ n , because Q Q Q , r r r are bounded by fixed powers of λ \lambda λ while n > 2 λ − 1 n > 2^{\lambda-1} n > 2 λ − 1 . Put
μ = Q ( r − 1 ) 2 r , A 0 = ⌈ μ − R − 1 2 ⌉ , J = { A 0 , … , A 0 + R − 1 } . \mu= \frac{Q(r-1)}{2r}, \qquad A_0 = \left\lceil\mu- \frac{R-1}{2} \right\rceil, \qquad\mathcal{J} = \{A_0,\ldots,A_0+R-1\}. μ = 2 r Q ( r − 1 ) , A 0 = ⌈ μ − 2 R − 1 ⌉ , J = { A 0 , … , A 0 + R − 1 } .
Then Q / 4 ≤ μ ≤ Q / 2 Q/4 \le\mu\le Q/2 Q /4 ≤ μ ≤ Q /2 , and since R ≤ Q / 6 R \le Q/6 R ≤ Q /6 the interval lies in { 0 , … , Q } \{0,\ldots,Q\} { 0 , … , Q } ; its centre is within one of μ \mu μ , and R ≥ 32 R \ge32 R ≥ 32 makes it contain every integer within R / 4 R/4 R /4 of μ \mu μ . For W ∼ Bin ( Q , ( r − 1 ) / ( 2 r ) ) W \sim\operatorname{Bin}(Q,(r-1)/(2r)) W ∼ Bin ( Q , ( r − 1 ) / ( 2 r )) , Hoeffding’s inequality (10) with s = R / 4 s = R/4 s = R /4 gives
Pr [ W ∉ J ] ≤ 2 e − R 2 / ( 8 Q ) ≤ 2 e − 16 ( β + 3 ) 2 ν ≤ 2 − ( β + 2 ) ν ≤ λ − ( β + 2 ) ≤ 1 b r 2 λ . \Pr[W \notin\mathcal{J}] \le2e^{-R^2/(8Q)} \le2e^{-16(\beta+3)^2\nu} \le2^{-(\beta+2)\nu} \le\lambda^{-(\beta+2)} \le\frac{1}{br^2\lambda}. Pr [ W ∈ / J ] ≤ 2 e − R 2 / ( 8 Q ) ≤ 2 e − 16 ( β + 3 ) 2 ν ≤ 2 − ( β + 2 ) ν ≤ λ − ( β + 2 ) ≤ b r 2 λ 1 .
using R 2 / ( 8 Q ) ≥ ( β + 3 ) 2 λ ⋅ 128 ν / ( 8 λ ) = 16 ( β + 3 ) 2 ν R^2/(8Q) \ge(\beta+3)^2\lambda\cdot128\nu/(8\lambda) = 16(\beta+3)^2\nu R 2 / ( 8 Q ) ≥ ( β + 3 ) 2 λ ⋅ 128 ν / ( 8 λ ) = 16 ( β + 3 ) 2 ν , b ≤ λ β b \le\lambda^\beta b ≤ λ β and r 2 ≤ λ r^2 \le\lambda r 2 ≤ λ . This is (52) with ϵ = τ / ( r b ) \epsilon= \tau/(rb) ϵ = τ / ( r b ) , and 0 < τ ≤ 1 / 2 0 < \tau\le1/2 0 < τ ≤ 1/2 once r ≥ 2 r \ge2 r ≥ 2 . Finally R / Q = O β ( ν / λ ) R/Q = O_{\beta}(\nu/\sqrt{\lambda}) R / Q = O β ( ν / λ ) , log ( 2 Q / R ) = O ( ν ) \log(2Q/R) = O(\nu) log ( 2 Q / R ) = O ( ν ) and τ log ( 2 D + 1 ) = O ( 1 / r ) \tau\log(2D+1) = O(1/r) τ log ( 2 D + 1 ) = O ( 1/ r ) , while 1 / r = O ( ν 2 / λ ) 1/r = O(\nu^2/\sqrt{\lambda}) 1/ r = O ( ν 2 / λ ) , which proves (54) .
For the computation, λ \lambda λ is the least integer with n ≤ 2 λ n \le2^\lambda n ≤ 2 λ and ν \nu ν the least with λ ≤ 2 ν \lambda\le2^\nu λ ≤ 2 ν ; r r r is the largest integer with r 2 2 ν / 4 ≤ λ r^2 2^{\nu/4} \le\lambda r 2 2 ν /4 ≤ λ , Q Q Q is an integer division, and ⌈ λ ⌉ \lceil\sqrt{\lambda}\rceil ⌈ λ ⌉ comes from an integer square root. The algorithm reports failure if r < 2 r < 2 r < 2 or Q ≤ R Q \le R Q ≤ R ; otherwise it forms τ \tau τ , ϵ \epsilon ϵ , D D D and the endpoints of J \mathcal{J} J in rational arithmetic and checks J ⊆ { 0 , … , Q } \mathcal{J} \subseteq\{0,\ldots,Q\} J ⊆ { 0 , … , Q } , (47) , R ≥ 32 R \ge32 R ≥ 32 , 6 R ≤ Q 6R \le Q 6 R ≤ Q , and (52) , whose left side has denominator ( 2 r ) Q (2r)^Q ( 2 r ) Q and is an exact rational computation. All of this takes poly β ( log n ) \operatorname{poly}_{\beta}(\log n) poly β ( log n ) bit operations, and the estimates above show that every check passes for large n n n .
Weighted counting in subexponential time
Bounded occurrences
We first state the outcome of § 3 and § 4 for a factor system in which every variable occurs in few factors.
Theorem 5.1 (Bounded occurrences). Fix an integer β ≥ 1 \beta\ge1 β ≥ 1 . There are n 0 = n 0 ( β ) n_0 = n_0(\beta) n 0 = n 0 ( β ) and an absolute constant C 0 C_0 C 0 with the following property. Let A A A be a commutative Q \mathbb{Q} Q -algebra, let n ≥ n 0 n \ge n_0 n ≥ n 0 , and let a factor system on n n n variables have largest scope w w w , largest occurrence number b b b and total degree d d d with
w ≤ λ β , b ≤ λ β , d ≤ κ n w \le\lambda^\beta, \qquad b \le\lambda^\beta, \qquad d \le\kappa n w ≤ λ β , b ≤ λ β , d ≤ κn for some κ ≥ 1 \kappa\ge1 κ ≥ 1 . Then Z Z Z in (6) can be computed deterministically with at most
∣ F ∣ poly ( n ) 2 C 0 ( κ + 1 ) ( β + 3 ) n ν 2 / λ (55) |\mathcal{F}|\,\operatorname{poly}(n)\,2^{C_0(\kappa+1)(\beta+3)n\nu^2/\sqrt{\lambda}} \tag*{(55)} ∣ F ∣ poly ( n ) 2 C 0 ( κ + 1 ) ( β + 3 ) n ν 2 / λ (55) operations in A A A , evaluations of factors at inputs in Q [ z ] / ( z J ) \mathbb{Q}[z]/(z^J) Q [ z ] / ( z J ) with J ≤ κ n J \le\kappa n J ≤ κn , and bit operations on rational numbers, using polynomially many elements of A A A and polynomially many bits of storage in addition to the factors’ own.
Proof. Adjoin the constant-one factors of Section 4 so that (33) holds; b b b grows by at most one and d d d is unchanged, and we may take n 0 n_0 n 0 so large that λ β + 1 ≤ λ β + 1 \lambda^\beta+1 \le\lambda^{\beta+1} λ β + 1 ≤ λ β + 1 is not needed: replace β \beta β by β + 1 \beta+1 β + 1 in Lemma 4.7 if b b b was exactly λ β \lambda^\beta λ β , which changes only the constants. Choose the parameters (53) by Lemma 4.7, which for n ≥ n 0 ( β ) n \ge n_0(\beta) n ≥ n 0 ( β ) satisfy the hypotheses of Lemma 4.6; construct the design in polynomial time by that lemma; and run the routine of Proposition 3.5. The degree bound (11) holds with d ≤ κ n d \le\kappa n d ≤ κn , so d H ≤ κ n R d_H \le\kappa nR d H ≤ κn R , q ≤ κ n R / Q q \le\kappa nR/Q q ≤ κn R / Q and J ≤ q + 1 ≤ κ n J \le q+1 \le\kappa n J ≤ q + 1 ≤ κn because R < Q R<Q R < Q . By (31) ,
log C q ≤ κ n R Q log Q R + 3 n R Q ≤ ( κ + 1 ) n R Q log 2 Q R ⋅ 3. \log C_q \le\kappa n \frac{R}{Q}\log\frac{Q}{R}+\frac{3nR}{Q}\le(\kappa+1)n\frac{R}{Q}\log\frac{2Q}{R}\cdot3. log C q ≤ κn Q R log R Q + Q 3 n R ≤ ( κ + 1 ) n Q R log R 2 Q ⋅ 3.
With the parameters (53) and n n n large, R / Q ≤ 300 ( β + 3 ) ν / λ R/Q \le300(\beta+3)\nu/\sqrt{\lambda} R / Q ≤ 300 ( β + 3 ) ν / λ and log ( 2 Q / R ) ≤ ν \log(2Q/R)\le\nu log ( 2 Q / R ) ≤ ν , while τ log ( 2 D + 1 ) ≤ 1 / r \tau\log(2D+1)\le1/r τ log ( 2 D + 1 ) ≤ 1/ r and 1 / r ≤ 2 ν 2 / λ 1/r\le2\nu^2/\sqrt{\lambda} 1/ r ≤ 2 ν 2 / λ . Hence the logarithm of the vector count (30) is at most
log ( 2 Q r ) + 900 ( κ + 1 ) ( β + 3 ) n ν 2 λ + 4 n ν 2 λ ≤ log ( 2 Q r ) + C 0 ( κ + 1 ) ( β + 3 ) n ν 2 λ \log(2Qr)+900(\kappa+1)(\beta+3)\frac{n\nu^2}{\sqrt{\lambda}}+\frac{4n\nu^2}{\sqrt{\lambda}}\le\log(2Qr)+C_0(\kappa+1)(\beta+3)\frac{n\nu^2}{\sqrt{\lambda}} log ( 2 Q r ) + 900 ( κ + 1 ) ( β + 3 ) λ n ν 2 + λ 4 n ν 2 ≤ log ( 2 Q r ) + C 0 ( κ + 1 ) ( β + 3 ) λ n ν 2
with C 0 = 904 C_0=904 C 0 = 904 , and each vector costs at most ∣ F ∣ |\mathcal{F}| ∣ F ∣ factor evaluations and polynomially many further operations. The storage bound is that of Proposition 3.5 . □
Branching on frequent variables
A sparse system may still contain variables occurring in many factors. Fixing them removes the obstacle at a cost that is negligible against (55) .
Lemma 5.2 (Frequent variables). Let a factor system on n ≥ 20 n\ge20 n ≥ 20 variables have ∣ F ∣ ≤ c n |\mathcal{F}|\le cn ∣ F ∣ ≤ c n factors, each of scope at most k k k , and let V h i = { v ∈ [ n ] : # { f : v ∈ I f } > c k λ } V_{\mathrm{hi}}=\{v\in[n]:\#\{f:v\in I_f\}>ck\lambda\} V hi = { v ∈ [ n ] : # { f : v ∈ I f } > c k λ } . Then ∣ V h i ∣ < n / λ |V_{\mathrm{hi}}|<n/\lambda ∣ V hi ∣ < n / λ . For every assignment y ∈ { 0 , 1 } V h i y\in\{0,1\}^{V_{\mathrm{hi}}} y ∈ { 0 , 1 } V hi the system obtained by substituting x v = y v x_v=y_v x v = y v for v ∈ V h i v\in V_{\mathrm{hi}} v ∈ V hi is a factor system on the n ′ = n − ∣ V h i ∣ n'=n-|V_{\mathrm{hi}}| n ′ = n − ∣ V hi ∣ remaining variables, with at most c n cn c n factors, scopes at most k k k , occurrence numbers at most c k λ ck\lambda c k λ and total degree at most d d d , and
Z = ∑ y ∈ { 0 , 1 } V h i Z y , (56) Z=\sum_{y\in\{0,1\}^{V_{\mathrm{hi}}}} Z_y, \tag*{(56)} Z = y ∈ { 0 , 1 } V hi ∑ Z y , (56) where Z y Z_y Z y is the sum (6) of the substituted system.
Proof. The incidences number M ≤ k ∣ F ∣ ≤ c k n M\le k|\mathcal{F}|\le ckn M ≤ k ∣ F ∣ ≤ c k n , so fewer than c k n / ( c k λ ) = n / λ ckn/(ck\lambda)=n/\lambda c k n / ( c k λ ) = n / λ variables occur more than c k λ ck\lambda c k λ times. Substituting values for the variables in V h i V_{\mathrm{hi}} V hi restricts each Φ f \Phi_f Φ f to a polynomial in the remaining variables of its scope, of no larger degree; the scopes shrink and the occurrence numbers of the remaining variables are unchanged, hence at most c k λ ck\lambda c k λ . Splitting the sum over { 0 , 1 } n \{0,1\}^n { 0 , 1 } n according to x ∣ V h i x|_{V_{\mathrm{hi}}} x ∣ V hi gives (56) . □
The weighted counting theorem
Theorem 5.3 (Weighted counting). Fix integers k ≥ 1 k\ge1 k ≥ 1 and c ≥ 1 c\ge1 c ≥ 1 . There is a deterministic algorithm that, given a factor system on n ≥ 20 n\ge20 n ≥ 20 variables with at most c n cn c n factors, each of scope at most k k k and with values in a commutative Q \mathbb{Q} Q -algebra A A A , computes
Z = ∑ x ∈ { 0 , 1 } n ∏ f ∈ F Φ f ( ( x v ) v ∈ I f ) Z=\sum_{x\in\{0,1\}^n}\prod_{f\in\mathcal{F}}\Phi_f((x_v)_{v\in I_f}) Z = x ∈ { 0 , 1 } n ∑ f ∈ F ∏ Φ f (( x v ) v ∈ I f ) with
poly ( n ) 2 O k , c ( ρ ( n ) ) , ρ ( n ) = n ( log log n ) 2 log n , (57) \operatorname{poly}(n)2^{O_{k,c}(\rho(n))},\qquad\rho(n)=\frac{n(\log\log n)^2}{\sqrt{\log n}}, \tag*{(57)} poly ( n ) 2 O k , c ( ρ ( n )) , ρ ( n ) = log n n ( log log n ) 2 , (57) operations in A A A and evaluations of the factors at inputs in Q [ z ] / ( z J ) \mathbb{Q}[z]/(z^J) Q [ z ] / ( z J ) , J ≤ c k n J\le ckn J ≤ c k n , together with polynomially many bit operations on rationals, and polynomially many elements of A A A and bits of storage. The implied constant depends only on k k k and c c c .
Proof. Let n 0 = n 0 ( 2 ) n_0=n_0(2) n 0 = n 0 ( 2 ) be the threshold of Theorem 5.1 with β = 2 \beta=2 β = 2 , enlarged so that c k λ ≤ ( λ − 1 ) 2 ck\lambda\le(\lambda-1)^2 c k λ ≤ ( λ − 1 ) 2 and k ≤ ( λ − 1 ) 2 k\le(\lambda-1)^2 k ≤ ( λ − 1 ) 2 for n ≥ n 0 n\ge n_0 n ≥ n 0 . If n < 2 n 0 n<2n_0 n < 2 n 0 , enumerate the cube directly: 2 n ≤ 2 2 n 0 2^n\le2^{2n_0} 2 n ≤ 2 2 n 0 is a constant depending on k , c k,c k , c . Otherwise n ≥ 2 n 0 n\ge2n_0 n ≥ 2 n 0 ; apply Lemma 5.2 . For each of the fewer than 2 n / λ 2^{n/\lambda} 2 n / λ assignments y y y , the substituted system has n ′ ≥ n − n / λ ≥ n / 2 ≥ n 0 n'\ge n-n/\lambda\ge n/2\ge n_0 n ′ ≥ n − n / λ ≥ n /2 ≥ n 0 variables, scopes at most k ≤ λ ′ 2 k\le\lambda'^2 k ≤ λ ′2 , occurrences at most c k λ ≤ λ ′ 2 ck\lambda\le\lambda'^2 c k λ ≤ λ ′2 , where λ ′ = ⌈ log n ′ ⌉ ≥ λ − 1 \lambda'=\lceil\log n'\rceil\ge\lambda-1 λ ′ = ⌈ log n ′ ⌉ ≥ λ − 1 , and
total degree d ≤ k c n ≤ 2 c k n ′ d \le kcn \le2ck\,n' d ≤ k c n ≤ 2 c k n ′ . Theorem 5.1 with β = 2 \beta=2 β = 2 and κ = 2 c k \kappa=2ck κ = 2 c k computes Z y Z_y Z y with ∣ F ∣ poly ( n ) 2 5 C 0 ( 2 c k + 1 ) n ′ ν ′ 2 / λ ′ |\mathcal{F}|\,\operatorname{poly}(n)2^{5C_0(2ck+1)n'\nu'^{2}/\sqrt{\lambda'}} ∣ F ∣ poly ( n ) 2 5 C 0 ( 2 c k + 1 ) n ′ ν ′ 2 / λ ′ operations, and n ′ ν ′ 2 / λ ′ ≤ 2 n ν 2 / λ n'\nu'^{2}/\sqrt{\lambda'} \le2n\nu^{2}/\sqrt{\lambda} n ′ ν ′ 2 / λ ′ ≤ 2 n ν 2 / λ for large n n n . Summing the Z y Z_y Z y costs one operation each. The total is
2 n / λ ⋅ c n poly ( n ) 2 10 C 0 ( 2 c k + 1 ) n ν 2 / λ = poly ( n ) 2 O k , c ( n ν 2 / λ ) , 2^{n/\lambda}\cdot cn\,\operatorname{poly}(n)\,2^{10C_0(2ck+1)n\nu^{2}/\sqrt{\lambda}}=\operatorname{poly}(n)\,2^{O_{k,c}(n\nu^{2}/\sqrt{\lambda})}, 2 n / λ ⋅ c n poly ( n ) 2 10 C 0 ( 2 c k + 1 ) n ν 2 / λ = poly ( n ) 2 O k , c ( n ν 2 / λ ) ,
since n / λ ≤ n ν 2 / λ n/\lambda\le n\nu^{2}/\sqrt{\lambda} n / λ ≤ n ν 2 / λ , and n ν 2 / λ = Θ ( ρ ( n ) ) n\nu^{2}/\sqrt{\lambda}=\Theta(\rho(n)) n ν 2 / λ = Θ ( ρ ( n )) . The space bound follows from Theorem 5.1 because the branches are processed one after the other.
Remark 5.4. For A = Q \mathcal{A}=\mathbb{Q} A = Q and Φ f \Phi_f Φ f the satisfaction indicator of a clause, Z Z Z is the number of satisfying assignments and the theorem is the sparse case of OpenAI's Theorem 1.1, with the exponent ρ ( n ) \rho(n) ρ ( n ) of their Proposition 6.4 in place of n log log n / log n n\log\log n/\sqrt{\log n} n log log n / log n . The dense case, and the better exponent, use their Sections 5, 6 and Appendices A and B, which are not reproduced here; the dense case is recovered in § 8 from the published sparsification lemma, with a weaker time bound.
Bit complexity over truncated polynomial rings
Lemma 5.5 (Bit complexity). In the situation of Theorem 5.1 , of Theorem 7.19 or of Theorem 5.3 , with ∣ F ∣ |\mathcal{F}| ∣ F ∣ factors of scope at most k k k and total degree d d d , let A \mathcal{A} A be one of the algebras A N = Q [ W ] / ( W N ) \mathcal{A}_N=\mathbb{Q}[W]/(W^N) A N = Q [ W ] / ( W N ) , A N 1 , … , N s \mathcal{A}_{N_1,\ldots,N_s} A N 1 , … , N s of dimension N = N 1 ⋯ N s N=N_1\cdots N_s N = N 1 ⋯ N s , or Q [ W ] / ( W N − 1 ) \mathbb{Q}[W]/(W^N-1) Q [ W ] / ( W N − 1 ) , and suppose every coefficient of every Φ f \Phi_f Φ f , as a polynomial in the Y v Y_v Y v with coefficients in A \mathcal{A} A , is a polynomial in the generators with integer coefficients of absolute value at most 2 L 2^L 2 L . Then every rational number that the algorithm forms has numerator and denominator of poly ( n , ∣ F ∣ , k , N , L ) \operatorname{poly}(n,|\mathcal{F}|,k,N,L) poly ( n , ∣ F ∣ , k , N , L ) bits; hence the operation counts of those theorems turn into bounds on bit operations after multiplication by a polynomial in n n n , ∣ F ∣ |\mathcal{F}| ∣ F ∣ , k k k , N N N and L L L , and the space stays polynomial.
Proof. All numbers arise in the following places. (a) The rows: by (D5), d d e n P ⃗ f , v d_{\mathrm{den}}\vec{P}_{f,v} d den P f , v has integer coefficients of O ( Q log Q + log D ) = O ( λ ) O(Q\log Q+\log D)=O(\lambda) O ( Q log Q + log D ) = O ( λ ) bits, and the values ⟨ P ⃗ f , v ( t ) , x ⟩ \langle\vec{P}_{f,v}(t),x\rangle ⟨ P f , v ( t ) , x ⟩ for Boolean x x x and the coefficients of ⟨ Δ P ⃗ f , v ( z ) , 1 U ⟩ \langle\Delta\vec{P}_{f,v}(z),1_U\rangle ⟨ Δ P f , v ( z ) , 1 U ⟩ are sums of at most n n n such coefficients times powers t i ≤ Q R t^i\le Q^R t i ≤ Q R , hence rationals with denominator d d e n d_{\mathrm{den}} d den and numerators of O ( λ + R log Q + log n ) = O ( λ ) O(\lambda+R\log Q+\log n)=O(\lambda) O ( λ + R log Q + log n ) = O ( λ ) bits. (b) A factor evaluation: Φ f \Phi_f Φ f has degree at most k k k , so its value at inputs in Q [ z ] / ( z J ) \mathbb{Q}[z]/(z^{J}) Q [ z ] / ( z J ) with the bounds of (a) is an element of A [ z ] / ( z J ) \mathcal{A}[z]/(z^{J}) A [ z ] / ( z J ) with denominator d d e n k d_{\mathrm{den}}^k d den k and numerators of O ( L + k λ + k log J ) O(L+k\lambda+k\log J) O ( L + k λ + k log J ) bits. (c) A group product is a product of at most ∣ F ∣ |\mathcal{F}| ∣ F ∣ factor values in A [ z ] / ( z J ) \mathcal{A}[z]/(z^{J}) A [ z ] / ( z J ) ; the number of monomials contributing to one coefficient is at most ( N J ) ∣ F ∣ (NJ)^{|\mathcal{F}|} ( N J ) ∣ F ∣ , so the product has denominator d d e n k ∣ F ∣ d_{\mathrm{den}}^{k|\mathcal{F}|} d den k ∣ F ∣ and numerators of O ( ∣ F ∣ ( L + k λ + k log ( N J ) ) ) O(|\mathcal{F}|(L+k\lambda+k\log(NJ))) O ( ∣ F ∣ ( L + k λ + k log ( N J ))) bits. (d) The sums (16) , (17) and (26) add at most 2 n ⋅ 3 n ⋅ ( 2 D + 1 ) 2 n 2^n\cdot3^n\cdot(2D+1)^{2^n} 2 n ⋅ 3 n ⋅ ( 2 D + 1 ) 2 n terms with a common denominator, adding O ( n + n log ( 2 D + 1 ) ) = O ( n λ ) O(n+n\log(2D+1))=O(n\lambda) O ( n + n log ( 2 D + 1 )) = O ( nλ ) bits to the numerators. (e) Hermite interpolation solves a Q J × Q J QJ\times QJ Q J × Q J rational system with entries of O ( Q J log ( Q J ) ) O(QJ\log(QJ)) O ( Q J log ( Q J )) bits and right-hand sides as in (d); by Cramer's rule the solution has denominator and numerators of poly ( Q J ) ⋅ O ( n λ + ∣ F ∣ ( L + k λ + k log ( N J ) ) ) \operatorname{poly}(QJ)\cdot O(n\lambda+|\mathcal{F}|(L+k\lambda+k\log(NJ))) poly ( Q J ) ⋅ O ( nλ + ∣ F ∣ ( L + k λ + k log ( N J ))) bits. Since Q , λ = O ( log n ) Q,\lambda=O(\log n) Q , λ = O ( log n ) and J ≤ d + 1 ≤ k ∣ F ∣ + 1 J\le d+1\le k|\mathcal{F}|+1 J ≤ d + 1 ≤ k ∣ F ∣ + 1 , all bit lengths are poly ( n , ∣ F ∣ , k , N , L ) \operatorname{poly}(n,|\mathcal{F}|,k,N,L) poly ( n , ∣ F ∣ , k , N , L ) , and each operation in A \mathcal{A} A costs O ( N 2 ) O(N^2) O ( N 2 ) operations on such rationals. The count of monomials in (c) used only that a product of two elements of A \mathcal{A} A is a basis element or zero, which holds in all three algebras. The case A = Q \mathcal{A}=\mathbb{Q} A = Q is N = 1 N=1 N = 1 .
Profiles, optima and polynomials This section draws the consequences of Theorem 5.3 and of Theorem 5.1 . The pattern is the same each time: a combinatorial quantity is written as the sum (6) of a factor system over a cube, the algebra is chosen so that the sum records what one wants to know, and the two theorems are applied. The only place where something has to be added to the summation routine
is the independence polynomial of a graph without any bound on the degrees, in § 6.2 , where a branching rule reduces the general graph to graphs of small degree; the cost of the rule is bounded by an explicit induction.
Profiles of sparse constraint systems
A constraint system on n n n Boolean variables consists of constraints C 1 , … , C m C_1,\ldots,C_m C 1 , … , C m , where C f : { 0 , 1 } I f → { 0 , 1 } C_f:\{0,1\}^{I_f}\to\{0,1\} C f : { 0 , 1 } I f → { 0 , 1 } is given by its truth table on a scope I f ⊆ [ n ] I_f\subseteq[n] I f ⊆ [ n ] , together with nonnegative integer weights ω 1 , … , ω m \omega_1,\ldots,\omega_m ω 1 , … , ω m . For an assignment x x x write
sat ω ( x ) = ∑ f : C f ( x ∣ I f ) = 1 ω f \operatorname{sat}_{\omega}(x)=\sum_{f:C_f(x|_{I_f})=1}\omega_f sat ω ( x ) = f : C f ( x ∣ I f ) = 1 ∑ ω f
for the weight of the constraints it satisfies. The profile of the system is the sequence
p j = # { x ∈ { 0 , 1 } n : sat ω ( x ) = j } , 0 ≤ j ≤ Ω t o t = ∑ f ω f . (58) p_j=\#\{x\in\{0,1\}^n:\operatorname{sat}_{\omega}(x)=j\},\qquad0\leq j\leq\Omega_{\mathrm{tot}}=\sum_f\omega_f. \tag*{(58)} p j = # { x ∈ { 0 , 1 } n : sat ω ( x ) = j } , 0 ≤ j ≤ Ω tot = f ∑ ω f . (58)
Theorem 6.1 (Profiles). Fix integers k ≥ 1 k\geq1 k ≥ 1 and c ≥ 1 c\geq1 c ≥ 1 . There is a deterministic algorithm that, given a constraint system on n ≥ 20 n\geq20 n ≥ 20 variables with m ≤ c n m\leq cn m ≤ c n constraints of scope at most k k k and weights ω f ≤ Ω \omega_f\leq\Omega ω f ≤ Ω , computes the whole profile (58) in time poly ( n , Ω ) 2 O k , c ( ρ ( n ) ) \operatorname{poly}(n,\Omega)2^{O_{k,c}(\rho(n))} poly ( n , Ω ) 2 O k , c ( ρ ( n )) and polynomial space.
Proof. Let N = 1 + Ω t o t ≤ 1 + c n Ω N=1+\Omega_{\mathrm{tot}}\leq1+cn\Omega N = 1 + Ω tot ≤ 1 + c n Ω and A = A N \mathcal{A}=\mathcal{A}_N A = A N . For each f f f let Φ f \Phi_f Φ f be the multilinear extension (8) of the function ϕ f ( x ) = W ω f C f ( x ) \phi_f(x)=W^{\omega_f}C_f(x) ϕ f ( x ) = W ω f C f ( x ) on { 0 , 1 } I f \{0,1\}^{I_f} { 0 , 1 } I f ; its coefficients are the polynomials ∑ U ⊆ S ( − 1 ) ∣ S ∣ − ∣ U ∣ ϕ f ( 1 U ) \sum_{U\subseteq S}(-1)^{|S|-|U|}\phi_f(1_U) ∑ U ⊆ S ( − 1 ) ∣ S ∣ − ∣ U ∣ ϕ f ( 1 U ) , each a sum of at most 2 k 2^k 2 k monomials ± W j \pm W^j ± W j , so they are polynomials in W W W with integer coefficients of absolute value at most 2 k 2^k 2 k . The system ( Φ f ) (\Phi_f) ( Φ f ) is a factor system with at most c n cn c n factors of scope at most k k k , and by (9) , since ∑ f ω f C f ( x ) = sat ω ( x ) ≤ Ω t o t < N \sum_f\omega_f C_f(x)=\operatorname{sat}_{\omega}(x)\leq\Omega_{\mathrm{tot}}<N ∑ f ω f C f ( x ) = sat ω ( x ) ≤ Ω tot < N ,
Z = ∑ x ∏ f W ω f C f ( x ∣ I f ) = ∑ j p j W j Z=\sum_x\prod_f W^{\omega_fC_f(x|_{I_f})}=\sum_jp_jW^j Z = x ∑ f ∏ W ω f C f ( x ∣ I f ) = j ∑ p j W j
with no term lost to the truncation. Theorem 5.3 computes Z Z Z with poly ( n ) 2 O k , c ( ρ ( n ) ) \operatorname{poly}(n)2^{O_{k,c}(\rho(n))} poly ( n ) 2 O k , c ( ρ ( n )) operations in A N \mathcal{A}_N A N and factor evaluations, and Lemma 5.5 with L = k L=k L = k bounds the bit lengths by poly ( n , N ) \operatorname{poly}(n,N) poly ( n , N ) , so the bit cost is poly ( n , Ω ) 2 O k , c ( ρ ( n ) ) \operatorname{poly}(n,\Omega)2^{O_{k,c}(\rho(n))} poly ( n , Ω ) 2 O k , c ( ρ ( n )) . The coefficients p j p_j p j are read off from Z Z Z . □
The profile contains, besides the optimum, every quantity that depends only on the distribution of the objective over the cube.
Corollary 6.2 (Max-k k k -SAT). Fix k , c ≥ 1 k,c\geq1 k , c ≥ 1 . Given a k k k -CNF formula with n n n variables and m ≤ c n m\leq cn m ≤ c n clauses with integer weights in [ 0 , Ω ] [0,\Omega] [ 0 , Ω ] , the following are computed deterministically in time poly ( n , Ω ) 2 O k , c ( ρ ( n ) ) \operatorname{poly}(n,\Omega)2^{O_{k,c}(\rho(n))} poly ( n , Ω ) 2 O k , c ( ρ ( n )) : the maximum weight of simultaneously satisfiable clauses, the number of assignments attaining it, the minimum such weight, and for every j j j the number of assignments satisfying clauses of total weight exactly j j j . In particular Max-k k k -SAT, Min-k k k -SAT and weighted Max-k k k -SAT with polynomially bounded weights are solved exactly in time 2 o ( n ) 2^{o(n)} 2 o ( n ) on instances with O ( n ) O(n) O ( n ) clauses, and the number of optimal assignments is counted.
Proof. A clause is a constraint whose truth table is the disjunction of its literals. Apply Theorem 6.1 ; the maximum is the largest j j j with p j > 0 p_j>0 p j > 0 , the minimum the smallest, and p j p_j p j is the required count. □
The Hamming weight of an assignment is itself a sum of local weights, one per variable, so the profile may be taken with respect to it.
Corollary 6.3 (Satisfying assignments of each weight). *Fix k , c ≥ 1 k,c\geq1 k , c ≥ 1 . Given a k k k -CNF formula with n n n variables and m ≤ c n m\leq cn m ≤ c n clauses, the numbers
s i = # { x : x satisfies the formula and has exactly i ones } , 0 ≤ i ≤ n , s_i=\#\{x:x\text{ satisfies the formula and has exactly }i\text{ ones}\},\qquad0\leq i\leq n, s i = # { x : x satisfies the formula and has exactly i ones } , 0 ≤ i ≤ n ,
are computed deterministically in time poly ( n ) 2 O k , c ( ρ ( n ) ) \operatorname{poly}(n)2^{O_{k,c}(\rho(n))} poly ( n ) 2 O k , c ( ρ ( n )) . Hence the satisfying assignment with the fewest, or the most, ones is found and counted within the same time.
Proof. Take A = A n + 1 \mathcal{A}=\mathcal{A}_{n+1} A = A n + 1 . For each clause f f f let Φ f \Phi_f Φ f be the multilinear extension of its satisfaction indicator, with coefficients in { 0 , ± 1 } ⊆ Q \{0,\pm1\}\subseteq\mathbb{Q} { 0 , ± 1 } ⊆ Q , and for each variable v v v add the factor Φ v = 1 + ( W − 1 ) Y v \Phi_v=1+(W-1)Y_v Φ v = 1 + ( W − 1 ) Y v of scope { v } \{v\} { v } , the multilinear extension of W x v W^{x_v} W x v . The system has at most ( c + 1 ) n (c+1)n ( c + 1 ) n factors of scope at most k k k , and its sum is Z = ∑ x [ x satisfies the formula ] W ∣ x ∣ = ∑ i s i W i Z=\sum_{x}[x\text{ satisfies the formula}]W^{|x|}=\sum_i s_iW^i Z = ∑ x [ x satisfies the formula ] W ∣ x ∣ = ∑ i s i W i , where ∣ x ∣ |x| ∣ x ∣ is the number of ones. Theorem 5.3 and Lemma 5.5 with N = n + 1 N=n+1 N = n + 1 , L = 1 L=1 L = 1 give the time bound. A satisfying assignment of a prescribed weight i i i with s i > 0 s_i>0 s i > 0 is then found by the usual self-reduction: fix the first variable to 0 and to 1, recompute the profiles of the two restricted formulas, which are again sparse k k k -CNF formulas, keep a value for which the coefficient of W i W^i W i or W i − 1 W^{i-1} W i − 1 is positive, and continue; this multiplies the time by at most 2 n 2n 2 n .
The next corollary uses an algebra in two variables, one recording the cut and one the size of a side.
Corollary 6.4 (Max-Cut and bisections). Fix c ≥ 1 c\geq1 c ≥ 1 . Given a graph G G G with n n n vertices and m ≤ c n m\leq cn m ≤ c n edges with integer weights in [ 0 , Ω ] [0,\Omega] [ 0 , Ω ] , the numbers
q i , j = # { S ⊆ V ( G ) : ∣ S ∣ = i , the edges between S and V ∖ S have total weight j } q_{i,j}=\#\{S\subseteq V(G): |S|=i,\ \text{the edges between }S\text{ and }V\setminus S\text{ have total weight }j\} q i , j = # { S ⊆ V ( G ) : ∣ S ∣ = i , the edges between S and V ∖ S have total weight j } are computed for all i i i and j j j in deterministic time poly ( n , Ω ) 2 O c ( ρ ( n ) ) \operatorname{poly}(n,\Omega)2^{O_c(\rho(n))} poly ( n , Ω ) 2 O c ( ρ ( n )) . In particular the maximum cut, the maximum and the minimum bisection, with the number of optimal solutions of each, are computed exactly in time 2 o ( n ) 2^{o(n)} 2 o ( n ) on graphs with O ( n ) O(n) O ( n ) edges.
Proof. Let N 1 = 1 + ∑ e ω e ≤ 1 + c n Ω N_1=1+\sum_e\omega_e\leq1+cn\Omega N 1 = 1 + ∑ e ω e ≤ 1 + c n Ω and N 2 = n + 1 N_2=n+1 N 2 = n + 1 , and let A = A N 1 , N 2 = Q [ W , U ] / ( W N 1 , U N 2 ) \mathcal{A}=\mathcal{A}_{N_1,N_2}=\mathbb{Q}[W,U]/(W^{N_1},U^{N_2}) A = A N 1 , N 2 = Q [ W , U ] / ( W N 1 , U N 2 ) . Encode S S S by x ∈ { 0 , 1 } n x\in\{0,1\}^n x ∈ { 0 , 1 } n . For an edge e = { u , v } e=\{u,v\} e = { u , v } take the multilinear extension of W ω e [ x u ≠ x v ] W^{\omega_e[x_u\neq x_v]} W ω e [ x u = x v ] , which is 1 + ( W ω e − 1 ) ( Y u + Y v − 2 Y u Y v ) 1+(W^{\omega_e}-1)(Y_u+Y_v-2Y_uY_v) 1 + ( W ω e − 1 ) ( Y u + Y v − 2 Y u Y v ) , and for each vertex v v v the factor 1 + ( U − 1 ) Y v 1+(U-1)Y_v 1 + ( U − 1 ) Y v . There are at most ( c + 1 ) n (c+1)n ( c + 1 ) n factors of scope at most 2, with coefficients that are polynomials in W W W and U U U with integer coefficients of absolute value at most 2. The sum is Z = ∑ x W cut ( x ) U ∣ x ∣ = ∑ i , j q i , j W j U i Z=\sum_xW^{\operatorname{cut}(x)}U^{|x|}=\sum_{i,j}q_{i,j}W^jU^i Z = ∑ x W cut ( x ) U ∣ x ∣ = ∑ i , j q i , j W j U i , and no term is truncated. Theorem 5.3 and Lemma 5.5 with N = N 1 N 2 N=N_1N_2 N = N 1 N 2 and L = 1 L=1 L = 1 give the bound. The maximum cut is the largest j j j with ∑ i q i , j > 0 \sum_iq_{i,j}>0 ∑ i q i , j > 0 , the maximum bisection the largest j j j with q ⌊ n / 2 ⌋ , j > 0 q_{\lfloor n/2\rfloor,j}>0 q ⌊ n /2 ⌋ , j > 0 , the minimum bisection the smallest such j j j , and the counts are the coefficients.
Remark 6.5. The best exact algorithm for Max-Cut on general graphs runs in time 2 ω n / 3 ≤ 2 0.792 n 2^{\omega n/3}\leq2^{0.792n} 2 ω n /3 ≤ 2 0.792 n [35 ] , and the exact algorithms for sparse Max-Cut run in time 2 Θ ( m ) 2^{\Theta(m)} 2 Θ ( m ) [31 ] ; on graphs with m = O ( n ) m=O(n) m = O ( n ) edges both are exponential in n n n . The proof of OpenAI’s Corollary 1.2 contains a circuit encoding that, combined with their Theorem 1.1, also yields the exact optimum of a sparse Max-k k k -SAT or Max-Cut instance in time 2 o ( n ) 2^{o(n)} 2 o ( n ) , by a binary search over the threshold; that route handles the unweighted objective. The algebra A N \mathcal{A}_N A N handles integer weights up to Ω \Omega Ω at a cost polynomial in Ω \Omega Ω , which a circuit encoding cannot do without introducing Θ ( n log Ω ) \Theta(n\log\Omega) Θ ( n log Ω ) auxiliary variables.
The independence polynomial of every graph
Let G G G be a graph with vertex set V V V , ∣ V ∣ = n |V|=n ∣ V ∣ = n , and let ω : V → { 0 , 1 , … } \omega:V\to\{0,1,\ldots\} ω : V → { 0 , 1 , … } be integer vertex weights. The weighted independence polynomial is
I ω ( G ; W ) = ∑ S ⊆ V independent W ω ( S ) , ω ( S ) = ∑ v ∈ S ω v (59) I_\omega(G;W)=\sum_{\substack{S\subseteq V\\\text{independent}}}W^{\omega(S)},\qquad\omega(S)=\sum_{v\in S}\omega_v \tag*{(59)} I ω ( G ; W ) = S ⊆ V independent ∑ W ω ( S ) , ω ( S ) = v ∈ S ∑ ω v (59)
and I ( G ; W ) = I 1 ( G ; W ) I(G;W)=I_1(G;W) I ( G ; W ) = I 1 ( G ; W ) is the independence polynomial. For a vertex v v v write N [ v ] N[v] N [ v ] for its closed neighbourhood and G − X G-X G − X for the graph induced on V ∖ X V\setminus X V ∖ X . Every independent set either avoids v v v or contains v v v and avoids N [ v ] N[v] N [ v ] , so
I ω ( G ; W ) = I ω ( G − v ; W ) + W ω v I ω ( G − N [ v ] ; W ) . (60) I_\omega(G;W)=I_\omega(G-v;W)+W^{\omega_v}I_\omega(G-N[v];W). \tag*{(60)} I ω ( G ; W ) = I ω ( G − v ; W ) + W ω v I ω ( G − N [ v ] ; W ) . (60)
Figure 2. The array q i , j q_{i,j} q i , j of Corollary 6.4 for a graph with 14 vertices and 21 edges, a Hamilton cycle with seven chords, computed directly from the 2 14 2^{14} 2 14 subsets; the height is log 10 ( 1 + q i , j ) \log_{10}(1+q_{i,j}) log 10 ( 1 + q i , j ) . The algorithm returns the whole array as one element of Q [ W , U ] / ( W 22 , U 15 ) \mathbb{Q}[W,U]/(W^{22},U^{15}) Q [ W , U ] / ( W 22 , U 15 ) ; its maximum cut and its maximum bisection are both 18.
Lemma 6.6 (Forcing branching). Let b ≥ 2 b \ge2 b ≥ 2 be an integer and G G G a weighted graph with n n n vertices. There is a binary tree, computable in time poly ( n ) \operatorname{poly}(n) poly ( n ) per node, whose leaves ℓ \ell ℓ carry induced subgraphs H ℓ H_{\ell} H ℓ of G G G of maximum degree at most b b b and integers s ℓ ≥ 0 s_{\ell} \ge0 s ℓ ≥ 0 such that
I ω ( G ; W ) = ∑ ℓ W s ℓ I ω ( H ℓ ; W ) , (61) I_{\omega}(G;W)=\sum_{\ell}W^{s_{\ell}}I_{\omega}(H_{\ell};W), \tag*{(61)} I ω ( G ; W ) = ℓ ∑ W s ℓ I ω ( H ℓ ; W ) , (61) and the number of leaves is at most
( 1 + 2 ln ( b + 2 ) b + 1 ) n . (62) \left(1+\frac{2\ln(b+2)}{b+1}\right)^n. \tag*{(62)} ( 1 + b + 1 2 ln ( b + 2 ) ) n . (62)
Proof. Build the tree from the root ( G , 0 ) (G,0) ( G , 0 ) . At a node ( H , s ) (H,s) ( H , s ) in which some vertex v v v has degree greater than b b b in H H H , attach the two children ( H − v , s ) (H-v,s) ( H − v , s ) and ( H − N H [ v ] , s + ω v ) (H-N_H[v],s+\omega_v) ( H − N H [ v ] , s + ω v ) ; by (60) the sum ∑ W s I ω ( H ; W ) \sum W^s I_{\omega}(H;W) ∑ W s I ω ( H ; W ) over the nodes of any antichain that cuts every root-to-leaf path is the same, and it equals I ω ( G ; W ) I_{\omega}(G;W) I ω ( G ; W ) at the root. A node in which every vertex has degree at most b b b is a leaf. This gives (61) , and each node is processed in polynomial time.
Let L ( n ) L(n) L ( n ) be the largest number of leaves of such a tree over all weighted graphs with at most n n n vertices, so that L L L is nondecreasing and L ( n ) = 1 L(n)=1 L ( n ) = 1 for n ≤ b + 1 n\le b+1 n ≤ b + 1 , because a graph with at most b + 1 b+1 b + 1 vertices has maximum degree at most b b b . If v v v has degree at least b + 1 b+1 b + 1 then H − v H-v H − v has $n-1 vertices and H − N H [ v ] H-N_H[v] H − N H [ v ] at most n − b − 2 n-b-2 n − b − 2 , so
Figure 3. The two costs of the proof of Theorem 6.7 per vertex, in log 10 \log_{10} log 10 , with the constant C 0 C_0 C 0 omitted: the leaf count 2 ln ( b + 2 ) / ( b + 1 ) 2\ln(b+2)/(b+1) 2 ln ( b + 2 ) / ( b + 1 ) of Lemma 6.6 and the leaf cost ( b + 2 ) ν 2 / λ (b+2)\nu^2/\sqrt{\lambda} ( b + 2 ) ν 2 / λ of Theorem 5.1 , as a function of the degree threshold b b b and of λ \lambda λ ; the curve marks the choice b = ⌊ λ 1 / 4 ⌋ b=\lfloor\lambda^{1/4}\rfloor b = ⌊ λ 1/4 ⌋ of the proof.
L ( n ) ≤ L ( n − 1 ) + L ( n − b − 2 ) ( n ≥ b + 2 ) , L(n)\le L(n-1)+L(n-b-2)\qquad(n\ge b+2), L ( n ) ≤ L ( n − 1 ) + L ( n − b − 2 ) ( n ≥ b + 2 ) ,
with L ( j ) = 1 L(j)=1 L ( j ) = 1 for j ≤ b + 1 j\le b+1 j ≤ b + 1 , including j ≤ 0 j\le0 j ≤ 0 . Put ε = 2 ln ( b + 2 ) / ( b + 1 ) \varepsilon=2\ln(b+2)/(b+1) ε = 2 ln ( b + 2 ) / ( b + 1 ) . We claim L ( n ) ≤ ( 1 + ε ) n L(n)\le(1+\varepsilon)^n L ( n ) ≤ ( 1 + ε ) n for all n ≥ 0 n\ge0 n ≥ 0 . This holds for n ≤ b + 1 n\le b+1 n ≤ b + 1 . For n ≥ b + 2 n\ge b+2 n ≥ b + 2 , by induction,
L ( n ) ≤ ( 1 + ε ) n − 1 + ( 1 + ε ) n − b − 2 = ( 1 + ε ) n − b − 2 ( ( 1 + ε ) b + 1 + 1 ) , L(n)\le(1+\varepsilon)^{n-1}+(1+\varepsilon)^{n-b-2}=(1+\varepsilon)^{n-b-2}\bigl((1+\varepsilon)^{b+1}+1\bigr), L ( n ) ≤ ( 1 + ε ) n − 1 + ( 1 + ε ) n − b − 2 = ( 1 + ε ) n − b − 2 ( ( 1 + ε ) b + 1 + 1 ) ,
and the right side is at most ( 1 + ε ) n (1+\varepsilon)^n ( 1 + ε ) n exactly when ε ( 1 + ε ) b + 1 ≥ 1 \varepsilon(1+\varepsilon)^{b+1}\ge1 ε ( 1 + ε ) b + 1 ≥ 1 . Now b ≥ 2 b\ge2 b ≥ 2 gives 2 ln ( b + 2 ) ≤ b + 1 2\ln(b+2)\le b+1 2 ln ( b + 2 ) ≤ b + 1 , since this holds at b = 2 b=2 b = 2 (2 ln 4 < 3 2\ln4<3 2 ln 4 < 3 ) and the difference b + 1 − 2 ln ( b + 2 ) b+1-2\ln(b+2) b + 1 − 2 ln ( b + 2 ) increases with b b b ; so ε ≤ 1 \varepsilon\le1 ε ≤ 1 , and for 0 ≤ ε ≤ 1 0\le\varepsilon\le1 0 ≤ ε ≤ 1 one has ln ( 1 + ε ) ≥ ε − ε 2 / 2 ≥ ε / 2 \ln(1+\varepsilon)\ge\varepsilon-\varepsilon^2/2\ge\varepsilon/2 ln ( 1 + ε ) ≥ ε − ε 2 /2 ≥ ε /2 . Therefore
( 1 + ε ) b + 1 ≥ e ( b + 1 ) ε / 2 = e ln ( b + 2 ) = b + 2 , ε ( 1 + ε ) b + 1 ≥ 2 ln ( b + 2 ) b + 1 ( b + 2 ) ≥ 2 ln 4 > 1. (1+\varepsilon)^{b+1}\ge e^{(b+1)\varepsilon/2}=e^{\ln(b+2)}=b+2,\qquad\varepsilon(1+\varepsilon)^{b+1}\ge\frac{2\ln(b+2)}{b+1}(b+2)\ge2\ln4>1. ( 1 + ε ) b + 1 ≥ e ( b + 1 ) ε /2 = e l n ( b + 2 ) = b + 2 , ε ( 1 + ε ) b + 1 ≥ b + 1 2 ln ( b + 2 ) ( b + 2 ) ≥ 2 ln 4 > 1.
This proves the claim, and (62) follows. □
Theorem 6.7 (Independence polynomial). There is a deterministic algorithm that, given a graph G G G with n n n vertices and integer vertex weights in [ 0 , Ω ] [0,\Omega] [ 0 , Ω ] , computes the weighted independence
polynomial I ω ( G ; W ) I_\omega(G; W) I ω ( G ; W ) in time
poly ( n , Ω ) 2 O ( n ( log log n ) 2 / ( log n ) 1 / 4 ) \operatorname{poly}(n,\Omega)\,2^{O(n(\log\log n)^2/(\log n)^{1/4})} poly ( n , Ω ) 2 O ( n ( l o g l o g n ) 2 / ( l o g n ) 1/4 )
and polynomial space. No condition is placed on the graph.
Proof. Let n 0 = n 0 ( 1 ) n_0=n_0(1) n 0 = n 0 ( 1 ) be the threshold of Theorem 5.1 with β = 1 \beta=1 β = 1 and let n 1 ≥ n 0 2 n_1\ge n_0^2 n 1 ≥ n 0 2 be so large that for n ≥ n 1 n\ge n_1 n ≥ n 1 the following hold, with λ = ⌈ log n ⌉ \lambda=\lceil\log n\rceil λ = ⌈ log n ⌉ and b = ⌊ λ 1 / 4 ⌋ b=\lfloor\lambda^{1/4}\rfloor b = ⌊ λ 1/4 ⌋ : b ≥ 2 b\ge2 b ≥ 2 , λ 1 / 4 + 1 ≤ λ / 2 − 1 \lambda^{1/4}+1\le\lambda/2-1 λ 1/4 + 1 ≤ λ /2 − 1 , and λ / 2 − 1 ≥ λ / 3 \lambda/2-1\ge\lambda/3 λ /2 − 1 ≥ λ /3 . For n < n 1 n<n_1 n < n 1 compute I ω ( G ; W ) I_\omega(G;W) I ω ( G ; W ) by listing the 2 n < 2 n 1 2^n<2^{n_1} 2 n < 2 n 1 subsets, a constant. For n ≥ n 1 n\ge n_1 n ≥ n 1 apply Lemma 6.6 with this b b b and compute I ω ( H ℓ ; W ) I_\omega(H_\ell;W) I ω ( H ℓ ; W ) at each leaf as follows.
If H = H ℓ H=H_\ell H = H ℓ has n H < n n_H<\sqrt n n H < n vertices, list its subsets; this costs 2 n poly ( n , Ω ) 2^{\sqrt n}\operatorname{poly}(n,\Omega) 2 n poly ( n , Ω ) . Otherwise n H ≥ n n_H\ge\sqrt n n H ≥ n , so λ H = ⌈ log n H ⌉ ≥ λ / 2 − 1 ≥ λ / 3 \lambda_H=\lceil\log n_H\rceil\ge\lambda/2-1\ge\lambda/3 λ H = ⌈ log n H ⌉ ≥ λ /2 − 1 ≥ λ /3 and n H ≥ n 0 n_H\ge n_0 n H ≥ n 0 . Take A = A N A=A_N A = A N with N = 1 + ∑ v ω v ≤ 1 + n Ω N=1+\sum_v\omega_v\le1+n\Omega N = 1 + ∑ v ω v ≤ 1 + n Ω , and the factor system on the n H n_H n H variables x v x_v x v , v ∈ V ( H ) v\in V(H) v ∈ V ( H ) , with the factor 1 − Y u Y v 1-Y_uY_v 1 − Y u Y v for each edge u v uv uv of H H H and the factor 1 + ( W ω v − 1 ) Y v 1+(W^{\omega_v}-1)Y_v 1 + ( W ω v − 1 ) Y v for each vertex v v v . The edge factor is the multilinear extension of the indicator that u u u and v v v are not both chosen, and the vertex factor that of W ω v x v W^{\omega_vx_v} W ω v x v , so the sum (6) is I ω ( H ; W ) I_\omega(H;W) I ω ( H ; W ) , with no term truncated. Each variable occurs in at most deg H ( v ) + 1 ≤ b + 1 ≤ λ 1 / 4 + 1 ≤ λ H \deg_H(v)+1\le b+1\le\lambda^{1/4}+1\le\lambda_H deg H ( v ) + 1 ≤ b + 1 ≤ λ 1/4 + 1 ≤ λ H factors, the scopes are at most 2 ≤ λ H 2\le\lambda_H 2 ≤ λ H , and the total degree is d = 2 ∣ E ( H ) ∣ + n H ≤ ( b + 1 ) n H d=2|E(H)|+n_H\le(b+1)n_H d = 2∣ E ( H ) ∣ + n H ≤ ( b + 1 ) n H . Theorem 5.1 with β = 1 \beta=1 β = 1 and κ = b + 1 \kappa=b+1 κ = b + 1 applies and computes I ω ( H ; W ) I_\omega(H;W) I ω ( H ; W ) with
∣ F ∣ poly ( n H ) 2 4 C 0 ( b + 2 ) n H ν H 2 / λ H ≤ poly ( n ) 2 4 C 0 ( λ 1 / 4 + 2 ) n ν 2 3 / λ = 2 O ( n ν 2 / λ 1 / 4 ) |\mathcal F|\operatorname{poly}(n_H)\,2^{4C_0(b+2)n_H\nu_H^2/\sqrt{\lambda_H}}
\le\operatorname{poly}(n)\,2^{4C_0(\lambda^{1/4}+2)n\nu^2\sqrt{3}/\lambda}
=2^{O(n\nu^2/\lambda^{1/4})} ∣ F ∣ poly ( n H ) 2 4 C 0 ( b + 2 ) n H ν H 2 / λ H ≤ poly ( n ) 2 4 C 0 ( λ 1/4 + 2 ) n ν 2 3 / λ = 2 O ( n ν 2 / λ 1/4 )
operations in A N A_N A N , using ν H ≤ ν \nu_H\le\nu ν H ≤ ν and λ H ≥ λ / 3 \lambda_H\ge\lambda/3 λ H ≥ λ /3 ; Lemma 5.5 with ∣ F ∣ ≤ ( b + 1 ) n |\mathcal F|\le(b+1)n ∣ F ∣ ≤ ( b + 1 ) n , k = 2 k=2 k = 2 , L = 1 L=1 L = 1 turns this into poly ( n , Ω ) 2 O ( n ν 2 / λ 1 / 4 ) \operatorname{poly}(n,\Omega)2^{O(n\nu^2/\lambda^{1/4})} poly ( n , Ω ) 2 O ( n ν 2 / λ 1/4 ) bit operations.
By (62) the tree has at most ( 1 + ϵ ) n ≤ e ϵ n (1+\epsilon)^n\le e^{\epsilon n} ( 1 + ϵ ) n ≤ e ϵ n leaves with ϵ = 2 ln ( b + 2 ) / ( b + 1 ) ≤ 4 ln λ / λ 1 / 4 = O ( ν / λ 1 / 4 ) \epsilon=2\ln(b+2)/(b+1)\le4\ln\lambda/\lambda^{1/4}=O(\nu/\lambda^{1/4}) ϵ = 2 ln ( b + 2 ) / ( b + 1 ) ≤ 4 ln λ / λ 1/4 = O ( ν / λ 1/4 ) , hence at most 2 O ( n ν / λ 1 / 4 ) 2^{O(n\nu/\lambda^{1/4})} 2 O ( n ν / λ 1/4 ) leaves and fewer internal nodes, each processed in polynomial time, and the leaf polynomials are combined by (61) with one multiplication by a power of W W W and one addition in A N A_N A N per leaf. The tree is traversed depth first, so only one root-to-leaf path of length at most n n n is stored at a time, and the space is polynomial. The total time is
2 O ( n ν / λ 1 / 4 ) ⋅ ( 2 n + 2 O ( n ν 2 / λ 1 / 4 ) ) poly ( n , Ω ) = poly ( n , Ω ) 2 O ( n ν 2 / λ 1 / 4 ) , 2^{O(n\nu/\lambda^{1/4})}\cdot(2^{\sqrt n}+2^{O(n\nu^2/\lambda^{1/4})})\operatorname{poly}(n,\Omega)
=\operatorname{poly}(n,\Omega)\,2^{O(n\nu^2/\lambda^{1/4})}, 2 O ( n ν / λ 1/4 ) ⋅ ( 2 n + 2 O ( n ν 2 / λ 1/4 ) ) poly ( n , Ω ) = poly ( n , Ω ) 2 O ( n ν 2 / λ 1/4 ) ,
and n ν 2 / λ 1 / 4 = Θ ( n ( log log n ) 2 / ( log n ) 1 / 4 ) n\nu^2/\lambda^{1/4}=\Theta(n(\log\log n)^2/(\log n)^{1/4}) n ν 2 / λ 1/4 = Θ ( n ( log log n ) 2 / ( log n ) 1/4 ) . □
Corollary 6.8. Each of the following is computed deterministically, for every graph G G G on n n n vertices, in time 2 O ( n ( log log n ) 2 / ( log n ) 1 / 4 ) 2^{O(n(\log\log n)^2/(\log n)^{1/4})} 2 O ( n ( l o g l o g n ) 2 / ( l o g n ) 1/4 ) : the independence number α ( G ) \alpha(G) α ( G ) and the number of maximum independent sets; the number of independent sets of each size, hence the partition function of the hard-core model at every activity; the clique number ω ( G ) \omega(G) ω ( G ) and the number of maximum cliques; the vertex cover number τ ( G ) \tau(G) τ ( G ) and the number of minimum vertex covers; and, for integer weights in [ 0 , Ω ] [0,\Omega] [ 0 , Ω ] , the maximum weight of an independent set and the number of independent sets of that weight, with a factor poly ( Ω ) \operatorname{poly}(\Omega) poly ( Ω ) in the time.
Proof. α ( G ) \alpha(G) α ( G ) is the degree of I ( G ; W ) I(G;W) I ( G ; W ) , its leading coefficient counts the maximum independent sets, and the coefficient of W i W^i W i counts the independent sets of size i i i ; the hard-core partition function at activity z z z is I ( G ; z ) I(G;z) I ( G ; z ) . The cliques of G G G are the independent sets of the complement, to which Theorem 6.7 applies without restriction. The vertex covers are the complements of the independent sets, so τ ( G ) = n − α ( G ) \tau(G)=n-\alpha(G) τ ( G ) = n − α ( G ) and the minimum vertex covers are counted by the same leading coefficient. The weighted statements read the degree and the leading coefficient of I ω ( G ; W ) I_\omega(G;W) I ω ( G ; W ) . □
Remark 6.9. The fastest published exact algorithm for the maximum independent set runs in time 2 0.1996 n 2^{0.1996n} 2 0.1996 n [XN17], and 2 Ω ( n ) 2^{\Omega(n)} 2 Ω ( n ) was a known consequence of the exponential time hypothesis. OpenAI’s Corollary 1.3 gives the number of independent sets of every graph in time 2 O ( n ) 2^{O(n)} 2 O ( n ) through their Theorem 1.1 in its general form, which handles formulas with Θ ( n 2 ) \Theta(n^2) Θ ( n 2 ) clauses; that form, combined with a linear-size threshold circuit for the number of chosen vertices, also gives α ( G ) \alpha(G) α ( G ) with the exponent n log log n / log n n\log\log n/\sqrt{\log n} n log log n / log n . The route of Theorem 6.7 is different: it uses only the sparse routine reproduced in § 3 and § 4 , reaches every graph through the branching of Lemma 6.6 , and returns the whole weighted polynomial. Its exponent is larger, by the factor ( log n ) 1 / 4 log log n (\log n)^{1/4}\log\log n ( log n ) 1/4 log log n , which is the price of the branching.
The branching of Lemma 6.6 records the weight of the chosen vertices only through the monomial W ω v \mathbf{W}^{\omega_v} W ω v that multiplies the second child, and its proof uses nothing else about that monomial. Several weights can therefore be carried at once, with one generator for each, and a budget can be placed on each of them. No restriction is placed on the graph.
Theorem 6.10 (Independent sets under budgets). Fix s ≥ 0 s \ge0 s ≥ 0 . There is a deterministic algorithm that, given a graph G G G with n n n vertices and weight vectors ω ( 0 ) , … , ω ( s ) ∈ { 0 , 1 , … , Ω } V \omega^{(0)},\ldots,\omega^{(s)} \in\{0,1,\ldots,\Omega\}^{V} ω ( 0 ) , … , ω ( s ) ∈ { 0 , 1 , … , Ω } V , computes the numbers
a ( j 0 , … , j s ) = # { S ⊆ V independent : ω ( i ) ( S ) = j i ( 0 ≤ i ≤ s ) } a(j_0,\ldots,j_s)=\#\{S\subseteq V\text{ independent}:\omega^{(i)}(S)=j_i\ (0\le i\le s)\} a ( j 0 , … , j s ) = # { S ⊆ V independent : ω ( i ) ( S ) = j i ( 0 ≤ i ≤ s )} for all tuples ( j 0 , … , j s ) (j_0,\ldots,j_s) ( j 0 , … , j s ) in time
poly ( n , ( 1 + n Ω ) s + 1 ) 2 O ( n ( log log n ) 2 / ( log n ) 1 / 4 ) \operatorname{poly}(n,(1+n\Omega)^{s+1})\,2^{O(n(\log\log n)^2/(\log n)^{1/4})} poly ( n , ( 1 + n Ω ) s + 1 ) 2 O ( n ( l o g l o g n ) 2 / ( l o g n ) 1/4 ) and polynomial space, the implied constant depending only on s s s .
Proof. Put N i = 1 + ∑ v ω v ( i ) ≤ 1 + n Ω N_i=1+\sum_v\omega_v^{(i)}\le1+n\Omega N i = 1 + ∑ v ω v ( i ) ≤ 1 + n Ω and A = A N 0 , … , N s \mathcal{A}=\mathcal{A}_{N_0,\ldots,N_s} A = A N 0 , … , N s , of dimension N = N 0 ⋯ N s ≤ ( 1 + n Ω ) s + 1 N=N_0\cdots N_s\le(1+n\Omega)^{s+1} N = N 0 ⋯ N s ≤ ( 1 + n Ω ) s + 1 , and for a vertex v v v write
W v = ∏ i = 0 s W i ω v ( i ) , \mathbf{W}^{v}=\prod_{i=0}^{s}W_i^{\omega_v^{(i)}}, W v = i = 0 ∏ s W i ω v ( i ) ,
a basis monomial of A \mathcal{A} A since ω v ( i ) < N i \omega_v^{(i)}<N_i ω v ( i ) < N i . The polynomial
I ( G ) = ∑ S independent v ∈ S ∏ W v = ∑ ( j 0 , … , j s ) a ( j 0 , … , j s ) W 0 j 0 ⋯ W s j s I(G)=\sum_{\substack{S\text{ independent}\\v\in S}}\prod\mathbf{W}^{v}
=\sum_{(j_0,\ldots,j_s)}a(j_0,\ldots,j_s)W_0^{j_0}\cdots W_s^{j_s} I ( G ) = S independent v ∈ S ∑ ∏ W v = ( j 0 , … , j s ) ∑ a ( j 0 , … , j s ) W 0 j 0 ⋯ W s j s
loses no term to the truncation, because ω ( i ) ( S ) < N i \omega^{(i)}(S)<N_i ω ( i ) ( S ) < N i for every S S S . It satisfies I ( G ) = I ( G − v ) + W v I ( G − N [ v ] ) I(G)=I(G-v)+\mathbf{W}^{v}I(G-N[v]) I ( G ) = I ( G − v ) + W v I ( G − N [ v ]) for every vertex v v v , by the argument for (60) . The construction of the tree in Lemma 6.6 uses only this recursion, with the second child carrying the product of the monomials W v \mathbf{W}^{v} W v of the vertices fixed to 1 on the way, and the bound (62) on the number of leaves uses only the numbers of vertices removed. So the lemma holds verbatim for I ( G ) I(G) I ( G ) , with leaf terms m ℓ I ( H ℓ ) m_\ell I(H_\ell) m ℓ I ( H ℓ ) in which m ℓ m_\ell m ℓ is a monomial.
At a leaf H = H ℓ H=H_\ell H = H ℓ with n H ≥ n n_H\ge\sqrt n n H ≥ n vertices take, as in the proof of Theorem 6.7 , the factor 1 − Y u Y v 1-Y_uY_v 1 − Y u Y v for each edge u v uv uv of H H H and the factor 1 + ( W v − 1 ) Y v 1+(\mathbf{W}^{v}-1)Y_v 1 + ( W v − 1 ) Y v for each vertex v v v , the multilinear extension of
∏ i W i ω v ( i ) x v . \prod_i W_i^{\omega_v^{(i)}x_v}. i ∏ W i ω v ( i ) x v .
The sum (6) of this system is I ( H ) I(H) I ( H ) . The occurrence numbers, the scopes and the total degree are those of the proof of Theorem 6.7 , since only the coefficient of Y v Y_v Y v in the vertex factors has changed, and that coefficient is a polynomial in the generators with integer coefficients of absolute value at most 1. Theorem 5.1 with β = 1 \beta=1 β = 1 and κ = b + 1 \kappa=b+1 κ = b + 1 gives poly ( n ) 2 O ( n ν 2 / λ 1 / 4 ) \operatorname{poly}(n)2^{O(n\nu^2/\lambda^{1/4})} poly ( n ) 2 O ( n ν 2 / λ 1/4 ) operations in A \mathcal{A} A , and Lemma 5.5 with L = 1 L=1 L = 1 turns them into poly ( n , N ) 2 O ( n ν 2 / λ 1 / 4 ) \operatorname{poly}(n,N)2^{O(n\nu^2/\lambda^{1/4})} poly ( n , N ) 2 O ( n ν 2 / λ 1/4 ) bit operations. Leaves with fewer than n \sqrt n n vertices are summed directly, each of the at most 2 n 2^{\sqrt n} 2 n subsets costing poly ( n , N ) \operatorname{poly}(n,N) poly ( n , N ) . The count of leaves, the depth-first traversal and the final estimate are those of the proof of Theorem 6.7 , with poly ( n , Ω ) \operatorname{poly}(n,\Omega) poly ( n , Ω ) replaced by poly ( n , N ) \operatorname{poly}(n,N) poly ( n , N ) .
The knapsack problem with a conflict graph [28 ] asks for a set of items of largest value whose total weight is within a capacity and which contains no two items joined by an edge of a given graph. It contains the maximum independent set, and with several capacities it contains the multidimensional knapsack problem.
Corollary 6.11 (Knapsack with an arbitrary conflict graph). Fix s ≥ 1 s \ge1 s ≥ 1 . Given a graph G G G on n n n vertices, values ω v ( 0 ) \omega^{(0)}_v ω v ( 0 ) and weights ω v ( 1 ) , … , ω v ( s ) \omega^{(1)}_v,\ldots,\omega^{(s)}_v ω v ( 1 ) , … , ω v ( s ) in [ 0 , Ω ] [0,\Omega] [ 0 , Ω ] , and capacities B 1 , … , B s B_1,\ldots,B_s B 1 , … , B s , the largest value ω ( 0 ) ( S ) \omega^{(0)}(S) ω ( 0 ) ( S ) of an independent set S S S of G G G with ω ( i ) ( S ) ≤ B i \omega^{(i)}(S) \le B_i ω ( i ) ( S ) ≤ B i for 1 ≤ i ≤ s 1 \le i \le s 1 ≤ i ≤ s , and the number of independent sets attaining it, are computed deterministically in time poly ( n , Ω s + 1 ) 2 O ( n ( log log n ) 2 / ( log n ) 1 / 4 ) \operatorname{poly}(n,\Omega^{s+1}) 2^{O(n(\log\log n)^2/(\log n)^{1/4})} poly ( n , Ω s + 1 ) 2 O ( n ( l o g l o g n ) 2 / ( l o g n ) 1/4 ) . The same holds with any of the inequalities replaced by equalities or by lower bounds, and with independent sets replaced by cliques.
Proof. By Theorem 6.10 compute all a ( j 0 , … , j s ) a(j_0,\ldots,j_s) a ( j 0 , … , j s ) . The optimum is the largest j 0 j_0 j 0 for which ∑ a ( j 0 , j 1 , … , j s ) > 0 \sum a(j_0,j_1,\ldots,j_s)>0 ∑ a ( j 0 , j 1 , … , j s ) > 0 , the sum taken over the tuples with j i ≤ B i j_i \le B_i j i ≤ B i for 1 ≤ i ≤ s 1 \le i \le s 1 ≤ i ≤ s , and that sum is the number of optimal sets; it has at most ( 1 + n Ω ) s (1+n\Omega)^s ( 1 + n Ω ) s terms. Other relations between j i j_i j i and B i B_i B i change only the range of the sum. Cliques of G G G are the independent sets of its complement. □
Vertex Cover in time 2 o ( k ) 2^{o(k)} 2 o ( k )
The parameterised Vertex Cover problem asks, for a graph G G G with n n n vertices and an integer k k k , whether G G G has a vertex cover with at most k k k vertices. We use the kernel of Chen, Kanj and Jia [11 ] , which rests on the theorem of Nemhauser and Trotter [26 ] on the half-integral relaxation of the problem.
Theorem 6.12 (Nemhauser and Trotter; Chen, Kanj and Jia). There is a polynomial-time algorithm that, given a graph G G G and an integer k ≥ 0 k \ge0 k ≥ 0 , either reports correctly that G G G has no vertex cover with at most k k k vertices, or returns an induced subgraph G ′ G' G ′ of G G G with at most 2 k 2k 2 k vertices and an integer k ′ ≤ k k' \le k k ′ ≤ k such that G G G has a vertex cover with at most k k k vertices if and only if G ′ G' G ′ has one with at most k ′ k' k ′ vertices. 13
Theorem 6.13 (Vertex Cover). Parameterised Vertex Cover is decided deterministically in time
2 O ( k ( log log k ) 2 / ( log k ) 1 / 4 ) + poly ( n ) , 2^{O(k(\log\log k)^2/(\log k)^{1/4})}+\operatorname{poly}(n), 2 O ( k ( l o g l o g k ) 2 / ( l o g k ) 1/4 ) + poly ( n ) , and the number of vertex covers of G ′ G' G ′ of each size is obtained within the same time.
Proof. Run the algorithm of Theorem 6.12. If it reports that no cover of size k k k exists, answer no. Otherwise it returns G ′ G' G ′ on n ′ ≤ 2 k n' \le2k n ′ ≤ 2 k vertices and k ′ k' k ′ . Apply Theorem 6.7 to G ′ G' G ′ with unit weights and read τ ( G ′ ) = n ′ − α ( G ′ ) \tau(G')=n'-\alpha(G') τ ( G ′ ) = n ′ − α ( G ′ ) by Corollary 6.8; answer yes if and only if τ ( G ′ ) ≤ k ′ \tau(G') \le k' τ ( G ′ ) ≤ k ′ . The time of the second step is 2 O ( n ′ ( log log n ′ ) 2 / ( log n ′ ) 1 / 4 ) 2^{O(n'(\log\log n')^2/(\log n')^{1/4})} 2 O ( n ′ ( l o g l o g n ′ ) 2 / ( l o g n ′ ) 1/4 ) with n ′ ≤ 2 k n' \le2k n ′ ≤ 2 k , which is 2 O ( k ( log log k ) 2 / ( log k ) 1 / 4 ) 2^{O(k(\log\log k)^2/(\log k)^{1/4})} 2 O ( k ( l o g l o g k ) 2 / ( l o g k ) 1/4 ) , and the first step is polynomial in n n n . □
Remark 6.14. Under the exponential time hypothesis, Vertex Cover has no algorithm with running time 2 o ( k ) poly ( n ) 2^{o(k)}\operatorname{poly}(n) 2 o ( k ) poly ( n ) [9 Theorem 14.6] ; the hypothesis being false, the bound of Theorem 6.13 is the first of this shape. The same kernel argument applies to every parameterised problem with a kernel of O ( k ) O(k) O ( k ) vertices whose solution is read from an independence polynomial, but we state no further instance.
Finite domains, homomorphisms and graphical models
Variables with more than two values are encoded by blocks of Boolean variables, one block per variable, and the blocks are kept on the unit vectors by one factor each. The construction is used for Potts systems below; we record it in general, since it turns every sparse constraint system over a fixed finite domain into one over { 0 , 1 } \{0,1\} { 0 , 1 } .
Theorem 6.15 (Finite domains). *Fix integers D ≥ 2 D \ge2 D ≥ 2 , k ≥ 1 k \ge1 k ≥ 1 and c ≥ 1 c \ge1 c ≥ 1 . Let n ≥ 20 n \ge20 n ≥ 20 variables take values in [ D ] [D] [ D ] , and let F \mathcal{F} F be a set of at most c n cn c n factors, each a function ϕ f : [ D ] I f → A \phi_f : [D]^{I_f} \to\mathcal{A} ϕ f : [ D ] I f → A with
∣ I f ∣ ≤ k |I_f| \le k ∣ I f ∣ ≤ k , given by its table of D ∣ I f ∣ D^{|I_f|} D ∣ I f ∣ values, where A \mathcal{A} A is Q \mathbb{Q} Q or one of the algebras of Lemma 5.5 of dimension N N N and the table entries are polynomials in the generators with integer coefficients of at most L L L bits. Then
Z = ∑ σ ∈ [ D ] n ∏ f ∈ F ϕ f ( σ ∣ I f ) Z=\sum_{\sigma\in[D]^n}\prod_{f\in\mathcal{F}}\phi_f(\sigma|_{I_f}) Z = σ ∈ [ D ] n ∑ f ∈ F ∏ ϕ f ( σ ∣ I f )
is computed deterministically in time poly ( n , N , L ) 2 O D , k , c ( ρ ( n ) ) \operatorname{poly}(n,N,L)2^{O_{D,k,c}(\rho(n))} poly ( n , N , L ) 2 O D , k , c ( ρ ( n )) and polynomial space.
Proof. Introduce the D n Dn D n Boolean variables x v , a = [ σ v = a ] x_{v,a}=[\sigma_v=a] x v , a = [ σ v = a ] . For each v v v let χ v \chi_v χ v be the indicator on { 0 , 1 } D \{0,1\}^D { 0 , 1 } D that exactly one of x v , 1 , … , x v , D x_{v,1},\ldots,x_{v,D} x v , 1 , … , x v , D equals 1 1 1 , and for each f f f let ϕ ~ f \widetilde{\phi}_f ϕ f be the function on { 0 , 1 } D ∣ I f ∣ \{0,1\}^{D|I_f|} { 0 , 1 } D ∣ I f ∣ that equals ϕ f ( σ ∣ I f ) \phi_f(\sigma|_{I_f}) ϕ f ( σ ∣ I f ) when every block of its input is a unit vector, encoding σ ∣ I f \sigma|_{I_f} σ ∣ I f , and 0 0 0 otherwise. Take as factors the multilinear extensions of the n n n functions χ v \chi_v χ v , of scope D D D , and of the at most c n cn c n functions ϕ ~ f \widetilde{\phi}_f ϕ f , of scope at most k D kD k D . The product of the χ v \chi_v χ v vanishes unless x x x encodes some σ ∈ [ D ] n \sigma\in[D]^n σ ∈ [ D ] n , and then the product of all factors is ∏ f ϕ f ( σ ∣ I f ) \prod_f\phi_f(\sigma|_{I_f}) ∏ f ϕ f ( σ ∣ I f ) ; so the sum (6) of this system is Z Z Z . The system has n ′ = D n n'=Dn n ′ = D n variables, at most ( c + 1 ) n ≤ ( c + 1 ) n ′ (c+1)n\le(c+1)n' ( c + 1 ) n ≤ ( c + 1 ) n ′ factors of scope at most k D kD k D , and coefficients of at most L + k D L+kD L + k D bits, since a coefficient of a multilinear extension is a signed sum of at most 2 k D 2^{kD} 2 k D table entries. Theorem 5.3 with the constants k D kD k D and c + 1 c+1 c + 1 and Lemma 5.5 give time poly ( n , N , L ) 2 O D , k , c ( ρ ( D n ) ) \operatorname{poly}(n,N,L)2^{O_{D,k,c}(\rho(Dn))} poly ( n , N , L ) 2 O D , k , c ( ρ ( D n )) , and ρ ( D n ) ≤ 4 D ρ ( n ) \rho(Dn)\le4D\rho(n) ρ ( D n ) ≤ 4 D ρ ( n ) for n ≥ D n\ge D n ≥ D . □
Corollary 6.16 (Homomorphisms and partition functions). Fix Δ ≥ 1 \Delta\ge1 Δ ≥ 1 and q ≥ 1 q\ge1 q ≥ 1 . Let A \mathcal{A} A be a symmetric q × q q\times q q × q matrix and β \beta β a vector of length q q q , both with rational entries of at most L L L bits. For a graph G G G with n n n vertices and maximum degree Δ \Delta Δ , the partition function
Z A , β ( G ) = ∑ σ : V ( G ) → [ q ] ∏ u v ∈ E ( G ) A σ u σ v ∏ v ∈ V ( G ) β σ v Z_{\mathcal{A},\beta}(G)=\sum_{\sigma:V(G)\to[q]}\prod_{uv\in E(G)}A_{\sigma_u\sigma_v}\prod_{v\in V(G)}\beta_{\sigma_v} Z A , β ( G ) = σ : V ( G ) → [ q ] ∑ uv ∈ E ( G ) ∏ A σ u σ v v ∈ V ( G ) ∏ β σ v is computed deterministically in time poly ( n , L ) 2 O Δ , q ( ρ ( n ) ) \operatorname{poly}(n,L)2^{O_{\Delta,q}(\rho(n))} poly ( n , L ) 2 O Δ , q ( ρ ( n )) . In particular the number of homomorphisms from G G G to a fixed graph H H H on q q q vertices, with loops allowed, is computed within that time, and so is the number of proper q q q -colourings of G G G .
Proof. Apply Theorem 6.15 with D = q D=q D = q , A = Q \mathcal{A}=\mathbb{Q} A = Q , a factor of scope { u , v } \{u,v\} { u , v } with table A a b A_{ab} A ab for each edge and a factor of scope { v } \{v\} { v } with table β a \beta_a β a for each vertex: at most Δ n / 2 + n \Delta n/2+n Δ n /2 + n factors of scope at most 2 2 2 . Homomorphisms to H H H are counted by the adjacency matrix of H H H and β = 1 \beta=1 β = 1 ; proper colourings by H = K q H=K_q H = K q . □
Remark 6.17. Dyer and Greenhill [13 ] and Bulatov and Grohe [3 ] showed that Z A ( G ) Z_A(G) Z A ( G ) is #P-hard for every symmetric nonnegative A A A outside an explicit family of matrices of rank at most two in each block; on bounded-degree graphs every such partition function is now computed exactly in time 2 o ( n ) 2^{o(n)} 2 o ( n ) . The same holds for the partition function of any discrete graphical model whose factors involve a bounded number of variables of bounded domain and whose factor count is linear: Theorem 6.15 computes it, and the marginal probability that a variable takes a value is the quotient of two such sums, the numerator with one indicator factor added.
Spin systems on bounded-degree graphs
Let G G G be a graph with n n n vertices and maximum degree Δ \Delta Δ . An Ising system on G G G is given by integer couplings J u v J_{uv} J uv on the edges and integer fields h v h_v h v on the vertices; a configuration is σ ∈ { − 1 , 1 } V \sigma\in\{-1,1\}^V σ ∈ { − 1 , 1 } V and its energy is
E ( σ ) = − ∑ u v ∈ E ( G ) J u v σ u σ v − ∑ v h v σ v . (63) E(\sigma)=-\sum_{uv\in E(G)}J_{uv}\sigma_u\sigma_v-\sum_v h_v\sigma_v. \tag*{(63)} E ( σ ) = − uv ∈ E ( G ) ∑ J uv σ u σ v − v ∑ h v σ v . (63)
The density of states is the function g ( E ) = # { σ : E ( σ ) = E } g(E)=\#\{\sigma:E(\sigma)=E\} g ( E ) = # { σ : E ( σ ) = E } , and the partition function at inverse temperature β \beta β is Z ( β ) = ∑ σ e − β E ( σ ) = ∑ E g ( E ) e − β E \mathcal{Z}(\beta)=\sum_\sigma e^{-\beta E(\sigma)}=\sum_E g(E)e^{-\beta E} Z ( β ) = ∑ σ e − β E ( σ ) = ∑ E g ( E ) e − β E . Put E max = ∑ u v ∣ J u v ∣ + ∑ v ∣ h v ∣ E_{\max}=\sum_{uv}|J_{uv}|+\sum_v|h_v| E m a x = ∑ uv ∣ J uv ∣ + ∑ v ∣ h v ∣ , so that ∣ E ( σ ) ∣ ≤ E max |E(\sigma)|\le E_{\max} ∣ E ( σ ) ∣ ≤ E m a x .
Theorem 6.18 (Ising and Potts density of states). Fix Δ ≥ 1 \Delta\ge1 Δ ≥ 1 and q ≥ 2 q\ge2 q ≥ 2 .
(i) The density of states of an Ising system on a graph of maximum degree Δ \Delta Δ with n n n vertices is computed deterministically in time poly ( n , E max ) 2 O Δ ( ρ ( n ) ) \operatorname{poly}(n,E_{\max})2^{O_{\Delta}(\rho(n))} poly ( n , E m a x ) 2 O Δ ( ρ ( n )) .
(ii) For the q q q -state Potts system with energy E ( σ ) = − ∑ u v J u v [ σ u = σ v ] − ∑ v h v ( σ v ) E(\sigma)=-\sum_{uv}J_{uv}[\sigma_u=\sigma_v]-\sum_v h_v(\sigma_v) E ( σ ) = − ∑ uv J uv [ σ u = σ v ] − ∑ v h v ( σ v ) , σ ∈ [ q ] V \sigma\in[q]^V σ ∈ [ q ] V , with integer couplings and integer fields h v : [ q ] → Z h_v:[q]\to\mathbb{Z} h v : [ q ] → Z , the density of states is computed in time poly ( n , E max ) 2 O Δ , q ( ρ ( n ) ) \operatorname{poly}(n,E_{\max})2^{O_{\Delta,q}(\rho(n))} poly ( n , E m a x ) 2 O Δ , q ( ρ ( n )) , where now E max = ∑ ∣ J u v ∣ + ∑ v max s ∣ h v ( s ) ∣ E_{\max}=\sum|J_{uv}|+\sum_v\max_s|h_v(s)| E m a x = ∑ ∣ J uv ∣ + ∑ v max s ∣ h v ( s ) ∣ .
In both cases the ground-state energy and its degeneracy, and the partition function at every inverse temperature as the finite sum ∑ E g ( E ) e − β E \sum_E g(E)e^{-\beta E} ∑ E g ( E ) e − β E , follow at once.
Proof. (i) Encode σ v = ( − 1 ) x v \sigma_v=(-1)^{x_v} σ v = ( − 1 ) x v with x ∈ { 0 , 1 } n x\in\{0,1\}^n x ∈ { 0 , 1 } n . The shifted energy E ( σ ) + E max E(\sigma)+E_{\max} E ( σ ) + E m a x is an integer in [ 0 , 2 E max ] [0,2E_{\max}] [ 0 , 2 E m a x ] and is the sum of the local terms ∣ J u v ∣ − J u v σ u σ v ∈ { 0 , 2 ∣ J u v ∣ } |J_{uv}|-J_{uv}\sigma_u\sigma_v\in\{0,2|J_{uv}|\} ∣ J uv ∣ − J uv σ u σ v ∈ { 0 , 2∣ J uv ∣ } over the edges and ∣ h v ∣ − h v σ v ∈ { 0 , 2 ∣ h v ∣ } |h_v|-h_v\sigma_v\in\{0,2|h_v|\} ∣ h v ∣ − h v σ v ∈ { 0 , 2∣ h v ∣ } over the vertices, each nonnegative. Take A = A N \mathcal{A}=\mathcal{A}_N A = A N with N = 2 E max + 1 N=2E_{\max}+1 N = 2 E m a x + 1 and the factor system consisting of the multilinear extension of W ∣ J u v ∣ − J u v σ u σ v W^{|J_{uv}|-J_{uv}\sigma_u\sigma_v} W ∣ J uv ∣ − J uv σ u σ v on the scope { u , v } \{u,v\} { u , v } for each edge and of W ∣ h v ∣ − h v σ v W^{|h_v|-h_v\sigma_v} W ∣ h v ∣ − h v σ v on { v } \{v\} { v } for each vertex. There are at most Δ n / 2 + n \Delta n/2+n Δ n /2 + n factors of scope at most 2, with coefficients that are polynomials in W W W with integer coefficients of absolute value at most 4, and the sum is ∑ σ W E ( σ ) + E max = ∑ E g ( E ) W E + E max \sum_\sigma W^{E(\sigma)+E_{\max}}=\sum_E g(E)W^{E+E_{\max}} ∑ σ W E ( σ ) + E m a x = ∑ E g ( E ) W E + E m a x . Theorem 5.3 with k = 2 k=2 k = 2 , c = Δ / 2 + 1 c=\Delta/2+1 c = Δ/2 + 1 and Lemma 5.5 with L = 2 L=2 L = 2 give the bound.
(ii) This is an instance of Theorem 6.15 ; we write out the encoding. Encode σ v ∈ [ q ] \sigma_v\in[q] σ v ∈ [ q ] by the q q q Boolean variables x v , s = [ σ v = s ] x_{v,s}=[\sigma_v=s] x v , s = [ σ v = s ] , so that there are q n qn q n variables, and let ϕ v ( x v , 1 , … , x v , q ) \phi_v(x_{v,1},\ldots,x_{v,q}) ϕ v ( x v , 1 , … , x v , q ) be the indicator that exactly one of them is 1, multiplied by W max t ∣ h v ( t ) ∣ − h v ( s ) W^{\max_t|h_v(t)|-h_v(s)} W m a x t ∣ h v ( t ) ∣ − h v ( s ) for that s s s ; this is a function on { 0 , 1 } q \{0,1\}^q { 0 , 1 } q with values in { 0 } ∪ { W j : 0 ≤ j ≤ 2 max t ∣ h v ( t ) ∣ } \{0\}\cup\{W^j:0\le j\le2\max_t|h_v(t)|\} { 0 } ∪ { W j : 0 ≤ j ≤ 2 max t ∣ h v ( t ) ∣ } . For an edge u v uv uv let ϕ u v \phi_{uv} ϕ uv be the function on { 0 , 1 } 2 q \{0,1\}^{2q} { 0 , 1 } 2 q that equals W ∣ J u v ∣ − J u v W^{|J_{uv}|-J_{uv}} W ∣ J uv ∣ − J uv when the two blocks are equal unit vectors, W ∣ J u v ∣ W^{|J_{uv}|} W ∣ J uv ∣ when they are distinct unit vectors, and 1 otherwise. Take A = A N \mathcal{A}=\mathcal{A}_N A = A N with N = 2 E max + 1 N=2E_{\max}+1 N = 2 E m a x + 1 and the multilinear extensions of these functions as factors: n n n of scope q q q and at most Δ n / 2 \Delta n/2 Δ n /2 of scope 2 q 2q 2 q , with coefficients of absolute value at most 2 2 q 2^{2q} 2 2 q . The product of the vertex factors vanishes unless every block is a unit vector, in which case x x x encodes a configuration σ \sigma σ and the product of all factors is W E ( σ ) + E max W^{E(\sigma)+E_{\max}} W E ( σ ) + E m a x . So the sum is ∑ E g ( E ) W E + E max \sum_Eg(E)W^{E+E_{\max}} ∑ E g ( E ) W E + E m a x . Theorem 5.3 on n ′ = q n n'=qn n ′ = q n variables with k = 2 q k=2q k = 2 q , c = Δ / 2 + 1 c=\Delta/2+1 c = Δ/2 + 1 and Lemma 5.5 with L = 2 q L=2q L = 2 q give time poly ( n , E max ) 2 O Δ , q ( ρ ( q n ) ) \operatorname{poly}(n,E_{\max})2^{O_{\Delta,q}(\rho(qn))} poly ( n , E m a x ) 2 O Δ , q ( ρ ( q n )) , and ρ ( q n ) ≤ q n ( log log n + 1 ) 2 / log n ≤ 4 q ρ ( n ) \rho(qn)\le qn(\log\log n+1)^2/\sqrt{\log n}\le4q\rho(n) ρ ( q n ) ≤ q n ( log log n + 1 ) 2 / log n ≤ 4 q ρ ( n ) for n ≥ q n\ge q n ≥ q . □
Remark 6.19. The ground state of an Ising spin glass with couplings in { − 1 , 0 , 1 } \{-1,0,1\} { − 1 , 0 , 1 } on a planar graph with a field, or on a cubic lattice, is NP-hard to find [2 ] , and its density of states is #P-hard to compute, while the partition function of the ferromagnetic model admits a polynomial-time randomised approximation [23 ] ; for bounded-degree graphs Theorem 6.18 computes both in time 2 o ( n ) 2^{o(n)} 2 o ( n ) whenever the couplings are polynomially bounded. The q q q -colourings of a graph are the ground states of the antiferromagnetic Potts system with all J u v = − 1 J_{uv}=-1 J uv = − 1 and no field, at energy E = 0 E=0 E = 0 ; their number for every graph is already in OpenAI’s Corollary 1.3, and (ii) adds the whole density of states on bounded-degree graphs.
Bounded-degree graphs and sparse set systems
Theorem 6.20. Fix Δ ≥ 1 \Delta\ge1 Δ ≥ 1 , k ≥ 1 k\ge1 k ≥ 1 and c ≥ 1 c\ge1 c ≥ 1 . Each of the following is computed deterministically in time poly ( n , Ω ) 2 O Δ , k , c ( ρ ( n ) ) \operatorname{poly}(n,\Omega)2^{O_{\Delta,k,c}(\rho(n))} poly ( n , Ω ) 2 O Δ , k , c ( ρ ( n )) .
(i) For a graph with n n n vertices and maximum degree Δ \Delta Δ , with integer vertex weights in [ 0 , Ω ] [0,\Omega] [ 0 , Ω ] : the number of dominating sets of each weight, hence the minimum weight of a dominating set and the number of minimum dominating sets.
(ii) For a graph with n n n vertices and maximum degree Δ \Delta Δ , with integer edge weights in [ 0 , Ω ] [0,\Omega] [ 0 , Ω ] : the number of matchings of each weight, hence the matching polynomial, the maximum weight of a matching, the number of maximum matchings and the number of perfect matchings.
(iii) For a set system of m ≤ c n m\le cn m ≤ c n sets of size at most k k k on n n n elements with integer element weights in [ 0 , Ω ] [0,\Omega] [ 0 , Ω ] : the number of hitting sets of each weight, hence the minimum hitting set; and the number of 2-colourings of the elements under which exactly j j j sets are not monochromatic, for every j j j , hence the maximum number of sets split by a 2-colouring.
Proof. (i) Variables x v = [ v ∈ S ] x_v=[v\in S] x v = [ v ∈ S ] . For each vertex v v v take the multilinear extension of the function on the scope N [ v ] N[v] N [ v ] that equals W w v x v W^{w_vx_v} W w v x v if some x u x_u x u , u ∈ N [ v ] u\in N[v] u ∈ N [ v ] , is 1 and 0 otherwise; it vanishes unless S S S dominates v v v . There are n n n factors of scope at most Δ + 1 \Delta+1 Δ + 1 , the sum is ∑ S dominating W w ( S ) \sum_{S\text{ dominating}}W^{w(S)} ∑ S dominating W w ( S ) , and Theorem 5.3 with k = Δ + 1 k=\Delta+1 k = Δ + 1 , c = 1 c=1 c = 1 , N = 1 + n Ω N=1+n\Omega N = 1 + n Ω , L = Δ + 1 L=\Delta+1 L = Δ + 1 applies.
(ii) Discard isolated vertices, so that n ≤ 2 m n\le2m n ≤ 2 m where m ≤ Δ n / 2 m\le\Delta n/2 m ≤ Δ n /2 is the number of edges. Variables y e = [ e ∈ M ] y_e=[e\in M] y e = [ e ∈ M ] , one per edge. For each vertex v v v take the multilinear extension of the indicator, on the scope of the edges at v v v , that at most one of them is chosen; for each edge the factor 1 + ( W w e − 1 ) Y e 1+(W^{w_e}-1)Y_e 1 + ( W w e − 1 ) Y e . There are n + m ≤ 3 m n+m\le3m n + m ≤ 3 m factors of scope at most Δ \Delta Δ on m m m variables, the sum is ∑ M matching W w ( M ) \sum_{M\text{ matching}}W^{w(M)} ∑ M matching W w ( M ) , and Theorem 5.3 on m m m variables with k = Δ k=\Delta k = Δ , c = 3 c=3 c = 3 applies; ρ ( m ) ≤ ρ ( Δ n / 2 ) = O Δ ( ρ ( n ) ) \rho(m)\le\rho(\Delta n/2)=O_\Delta(\rho(n)) ρ ( m ) ≤ ρ ( Δ n /2 ) = O Δ ( ρ ( n )) . The coefficient of W n / 2 W^{n/2} W n /2 for unit weights counts the perfect matchings.
(iii) Variables x v = [ v ∈ S ] x_v=[v\in S] x v = [ v ∈ S ] . For the hitting sets, take for each set A A A the multilinear extension of the indicator that some x v x_v x v , v ∈ A v\in A v ∈ A , is 1, and for each element the factor 1 + ( W w v − 1 ) Y v 1+(W^{w_v}-1)Y_v 1 + ( W w v − 1 ) Y v : at most ( c + 1 ) n (c+1)n ( c + 1 ) n factors of scope at most k k k . For the splittings, take for each set A A A the multilinear extension of W [ x ∣ A is not constant ] W^{[x|_A\text{ is not constant}]} W [ x ∣ A is not constant ] , m ≤ c n m\le cn m ≤ c n factors of scope at most k k k , with N = m + 1 N=m+1 N = m + 1 . In both cases Theorem 5.3 and Lemma 5.5 with L = k L=k L = k give the bound. □
The permanent of a sparse matrix is a weighted count of perfect matchings in which the weights multiply rather than add; it needs no truncated algebra at all.
Theorem 6.21 (Sparse permanents). Fix Δ ≥ 1 \Delta\ge1 Δ ≥ 1 . The permanent of an n × n n\times n n × n integer matrix with at most Δ \Delta Δ nonzero entries in every row and every column, with entries of absolute value at most 2 L 2^L 2 L , is computed deterministically in time poly ( n , L ) 2 O Δ ( ρ ( n ) ) \operatorname{poly}(n,L)2^{O_\Delta(\rho(n))} poly ( n , L ) 2 O Δ ( ρ ( n )) .
Proof. Let B B B be the bipartite graph on the rows and columns with an edge e = ( i , j ) e=(i,j) e = ( i , j ) for each nonzero entry a i j a_{ij} a ij ; it has n ′ ≤ Δ n n'\le\Delta n n ′ ≤ Δ n edges, and per ( A ) = ∑ M ∏ e ∈ M a e \operatorname{per}(A)=\sum_M\prod_{e\in M}a_e per ( A ) = ∑ M ∏ e ∈ M a e over the perfect matchings M M M of B B B . If some row or column has no entry the permanent is 0; otherwise n ′ ≥ n n'\ge n n ′ ≥ n . Take A = Q A=\mathbb{Q} A = Q , one variable y e y_e y e per edge, for each of the 2 n 2n 2 n vertices the multilinear extension of the indicator that exactly one incident edge is chosen, of scope at most Δ \Delta Δ , and for each edge the factor 1 + ( a e − 1 ) Y e 1+(a_e-1)Y_e 1 + ( a e − 1 ) Y e . There are 2 n + n ′ ≤ 3 n ′ 2n+n'\le3n' 2 n + n ′ ≤ 3 n ′ factors on n ′ n' n ′ variables, every coefficient is an integer of at most L + 1 L+1 L + 1 bits, and the sum (6) is per ( A ) \operatorname{per}(A) per ( A ) . Theorem 5.3 with k = Δ k=\Delta k = Δ , c = 3 c=3 c = 3 and Lemma 5.5 with N = 1 N=1 N = 1 give the bound, and ρ ( n ′ ) = O Δ ( ρ ( n ) ) \rho(n')=O_\Delta(\rho(n)) ρ ( n ′ ) = O Δ ( ρ ( n )) . □
Remark 6.22. The permanent of a 0-1 matrix is #P-complete [33 ] , and for sparse matrices the best bound known was 2 n − Ω ( n / Δ ) 2^{n-\Omega(n/\Delta)} 2 n − Ω ( n /Δ ) [12 ] . OpenAI’s Corollary 1.3 counts the perfect matchings of every graph in time 2 o ( ν + e ) 2^{o(\nu+e)} 2 o ( ν + e ) by their general theorem; Theorem 6.21 is the sparse weighted version, with the weights absorbed into the factors over Q \mathbb{Q} Q .
One global side constraint
The factors of a factor system are local, but the algebra may carry one global statistic for free. Corollary 6.3 used this for the Hamming weight. The group algebra of a cyclic group records a residue.
Proposition 6.23 (Counting under a congruence). Fix k , c ≥ 1 k,c\ge1 k , c ≥ 1 . Given a k k k -CNF formula with n n n variables and m ≤ c n m\le cn m ≤ c n clauses, integer weights w v ∈ [ 0 , Ω ] w_v\in[0,\Omega] w v ∈ [ 0 , Ω ] on the variables and a modulus M ≥ 1 M\ge1 M ≥ 1 , the numbers
r j = # { x : x satisfies the formula and ∑ v w v x v ≡ j ( m o d M ) } , 0 ≤ j < M , r_j=\#\left\{x:x\text{ satisfies the formula and }\sum_v w_vx_v\equiv j\pmod M\right\},\qquad0\le j<M, r j = # { x : x satisfies the formula and v ∑ w v x v ≡ j ( mod M ) } , 0 ≤ j < M ,
are computed deterministically in time poly ( n , M , log Ω ) 2 O k , c ( ρ ( n ) ) \operatorname{poly}(n,M,\log\Omega)2^{O_{k,c}(\rho(n))} poly ( n , M , log Ω ) 2 O k , c ( ρ ( n )) . Proof. Take A = Q [ W ] / ( W M − 1 ) \mathcal{A}=\mathbb{Q}[W]/(W^M-1) A = Q [ W ] / ( W M − 1 ) , the clause indicators as factors, and for each variable the factor 1 + ( W ω v m o d M − 1 ) Y v 1+(W^{\omega_v \bmod M}-1)Y_v 1 + ( W ω v mod M − 1 ) Y v . The sum is ∑ x satisfies W ∑ v ω v x v m o d M = ∑ j r j W j \sum_{x\text{ satisfies}} W^{\sum_v\omega_vx_v\bmod M}=\sum_j r_jW^j ∑ x satisfies W ∑ v ω v x v mod M = ∑ j r j W j , since W M = 1 W^M=1 W M = 1 . Theorem 5.3 and Lemma 5.5 with N = M N=M N = M , L = 1 L=1 L = 1 give the bound; the reduction of the exponents modulo M M M costs O ( log Ω ) O(\log\Omega) O ( log Ω ) bits per variable. □
Taken together, Corollary 6.3 and Proposition 6.23 count the solutions of a sparse k k k -CNF formula subject to one linear equation ∑ v ω v x v = s \sum_v\omega_vx_v=s ∑ v ω v x v = s or one linear congruence over the integers, constraints that no bounded number of local factors can express.
Further worked applications
The applications of Section 6 used one Boolean variable per vertex or per clause variable, one algebra generator, and constraints of the simplest kind. This section works out eight further families in which one of these three choices is made differently: several generators record several linear statistics at once; the variables range over a finite domain and the objective is a cut into several classes; the variables sit on the edges of a bounded-degree graph and the constraints at the vertices; the algebra is Q \mathbb{Q} Q but the factor is the Fortuin–Kasteleyn weight of an edge, which reaches the Tutte polynomial on a hyperbola; the constraints are the parity checks of a linear code; the constraints are the incidences of a hypergraph; the constraints are the gates of a circuit; and the constraints are the rows of an integer program, linear inequalities with coefficients of arbitrary size. In each case the proof consists of naming the variables, the factors and the algebra, checking the three hypotheses of Theorem 5.3 or Theorem 6.15 , and reading the answer off the resulting element of the algebra. We use throughout that ρ \rho ρ is increasing on [ 20 , ∞ ) [20,\infty) [ 20 , ∞ ) ,14 so that ρ ( m ) ≤ ρ ( C n ) ≤ 4 C ρ ( n ) \rho(m)\leq\rho(Cn)\leq4C\rho(n) ρ ( m ) ≤ ρ ( C n ) ≤ 4 C ρ ( n ) whenever 20 ≤ m ≤ C n 20\leq m\leq Cn 20 ≤ m ≤ C n and n ≥ C n\geq C n ≥ C , as in the proof of Theorem 6.15 .
Several linear side constraints
Corollary 6.3 and Proposition 6.23 recorded one linear statistic of the assignment in the exponent of the single generator W W W . With the algebra A N 1 , … , N s \mathcal{A}_{N_1,\ldots,N_s} A N 1 , … , N s of (5) one records s s s of them at once, and a fixed number of linear equations or congruences may be imposed on the solutions of a sparse constraint system.
Theorem 7.1 (Linear statistics). Fix integers k , c , s ≥ 1 k,c,s\geq1 k , c , s ≥ 1 . Let ( Φ f ) f ∈ F (\Phi_f)_{f\in\mathcal{F}} ( Φ f ) f ∈ F be a factor system on n ≥ 20 n\geq20 n ≥ 20 Boolean variables with at most c n cn c n factors of scope at most k k k , with values in A N 0 \mathcal{A}_{N_0} A N 0 for some N 0 ≥ 1 N_0\geq1 N 0 ≥ 1 and coefficients that are polynomials in W 0 W_0 W 0 with integer coefficients of at most L L L bits, and let ω ( 1 ) , … , ω ( s ) ∈ { 0 , 1 , … , Ω } n \boldsymbol{\omega}^{(1)},\ldots,\boldsymbol{\omega}^{(s)}\in\{0,1,\ldots,\Omega\}^n ω ( 1 ) , … , ω ( s ) ∈ { 0 , 1 , … , Ω } n be weight vectors.
(i) The elements
r ( j 1 , … , j s ) = ∑ x ∈ { 0 , 1 } n : ∑ v ω v ( i ) x v = j i ( 1 ≤ i ≤ s ) ∏ f ∈ F Φ f ( x ) ∈ A N 0 r(j_1,\ldots,j_s)=\sum_{x\in\{0,1\}^n:\,\sum_v\omega_v^{(i)}x_v=j_i\ (1\leq i\leq s)}\prod_{f\in\mathcal{F}}\Phi_f(x)\in\mathcal{A}_{N_0} r ( j 1 , … , j s ) = x ∈ { 0 , 1 } n : ∑ v ω v ( i ) x v = j i ( 1 ≤ i ≤ s ) ∑ f ∈ F ∏ Φ f ( x ) ∈ A N 0 are computed, for all ( j 1 , … , j s ) (j_1,\ldots,j_s) ( j 1 , … , j s ) at once, in time poly ( n , L , N 0 , ( 1 + n Ω ) s ) 2 O k , c ( ρ ( n ) ) \operatorname{poly}(n,L,N_0,(1+n\Omega)^s)2^{O_{k,c}(\rho(n))} poly ( n , L , N 0 , ( 1 + n Ω ) s ) 2 O k , c ( ρ ( n )) .
(ii) For moduli M 1 , … , M s ≥ 1 M_1,\ldots,M_s\geq1 M 1 , … , M s ≥ 1 the same holds for the sums over the x x x with ∑ v ω v ( i ) x v ≡ j i ( m o d M i ) \sum_v\omega_v^{(i)}x_v\equiv j_i\pmod{M_i} ∑ v ω v ( i ) x v ≡ j i ( mod M i ) for all i i i , in time poly ( n , L , N 0 , M 1 ⋯ M s , log Ω ) 2 O k , c ( ρ ( n ) ) \operatorname{poly}(n,L,N_0,M_1\cdots M_s,\log\Omega)2^{O_{k,c}(\rho(n))} poly ( n , L , N 0 , M 1 ⋯ M s , log Ω ) 2 O k , c ( ρ ( n )) ; equations and congruences may be mixed.
Proof. (i) Put N i = 1 + ∑ v ω v ( i ) ≤ 1 + n Ω N_i=1+\sum_v\omega_v^{(i)}\leq1+n\Omega N i = 1 + ∑ v ω v ( i ) ≤ 1 + n Ω for 1 ≤ i ≤ s 1\leq i\leq s 1 ≤ i ≤ s and A = A N 0 , N 1 , … , N s \mathcal{A}=\mathcal{A}_{N_0,N_1,\ldots,N_s} A = A N 0 , N 1 , … , N s , of dimension N = N 0 N 1 ⋯ N s N=N_0N_1\cdots N_s N = N 0 N 1 ⋯ N s . Keep the given factors, now read in A \mathcal{A} A , and add for each variable v v v the factor
Ψ v = 1 + ( ∏ i = 1 s W i ω v ( i ) − 1 ) Y v . \Psi_v=1+\left(\prod_{i=1}^{s}W_i^{\omega_v^{(i)}}-1\right)Y_v. Ψ v = 1 + ( i = 1 ∏ s W i ω v ( i ) − 1 ) Y v .
the multilinear extension of ∏ i W i ω v ( i ) x v \prod_i W_i^{\omega_v^{(i)}x_v} ∏ i W i ω v ( i ) x v on the scope { v } \{v\} { v } , of degree one in Y v Y_v Y v and with coefficients that are polynomials in the generators with integer coefficients of absolute value at most 1. The new system has at most ( c + 1 ) n (c+1)n ( c + 1 ) n factors of scope at most k k k , and its sum is
∑ x ∏ f Φ f ( x ) ∏ i = 1 s ∏ v W i ω v ( i ) x v = ∑ ( j 1 , … , j s ) r ( j 1 , … , j s ) W 1 j 1 ⋯ W s j s . \sum_x\prod_f\Phi_f(x)\prod_{i=1}^s\prod_v W_i^{\omega_v^{(i)}x_v}
=\sum_{(j_1,\ldots,j_s)}r(j_1,\ldots,j_s)W_1^{j_1}\cdots W_s^{j_s}. x ∑ f ∏ Φ f ( x ) i = 1 ∏ s v ∏ W i ω v ( i ) x v = ( j 1 , … , j s ) ∑ r ( j 1 , … , j s ) W 1 j 1 ⋯ W s j s .
with nothing lost to the truncation because every exponent of W i W_i W i is less than N i N_i N i . Theorem 5.3 computes the sum with poly ( n ) 2 O k , c ( ρ ( n ) ) \operatorname{poly}(n)2^{O_{k,c}(\rho(n))} poly ( n ) 2 O k , c ( ρ ( n )) operations in A \mathcal{A} A , and Lemma 5.5 , with ∣ F ∣ ≤ ( c + 1 ) n |\mathcal{F}|\le(c+1)n ∣ F ∣ ≤ ( c + 1 ) n and the bound max ( L , 1 ) \max(L,1) max ( L , 1 ) on the coefficient bits, turns this into poly ( n , L , N ) 2 O k , c ( ρ ( n ) ) \operatorname{poly}(n,L,N)2^{O_{k,c}(\rho(n))} poly ( n , L , N ) 2 O k , c ( ρ ( n )) bit operations. (ii) Replace W i N i = 0 W_i^{N_i}=0 W i N i = 0 by W i M i = 1 W_i^{M_i}=1 W i M i = 1 , that is take A = A N 0 ⊗ Q [ W 1 , … , W s ] / ( W 1 M 1 − 1 , … , W s M s − 1 ) \mathcal{A}=\mathcal{A}_{N_0}\otimes\mathbb{Q}[W_1,\ldots,W_s]/(W_1^{M_1}-1,\ldots,W_s^{M_s}-1) A = A N 0 ⊗ Q [ W 1 , … , W s ] / ( W 1 M 1 − 1 , … , W s M s − 1 ) , with the exponents ω v ( i ) \omega_v^{(i)} ω v ( i ) reduced modulo M i M_i M i at a cost of O ( log Ω ) O(\log\Omega) O ( log Ω ) bits each; the sum is then ∑ j r ( j ) W j \sum_j r(j)W^j ∑ j r ( j ) W j with j j j running over the residues. The proof of Lemma 5.5 used of the algebra only that the product of two basis monomials is a basis monomial or zero, which holds here, so the bit bound follows with N = N 0 M 1 ⋯ M s N=N_0M_1\cdots M_s N = N 0 M 1 ⋯ M s . A mixture of equations and congruences uses W i N i = 0 W_i^{N_i}=0 W i N i = 0 for the former and W i M i = 1 W_i^{M_i}=1 W i M i = 1 for the latter.
Corollary 7.2. Fix k , c , s ≥ 1 k,c,s\ge1 k , c , s ≥ 1 and Δ ≥ 1 \Delta\ge1 Δ ≥ 1 . Each of the following is computed deterministically in time poly ( n , Ω ) 2 O ( ρ ( n ) ) \operatorname{poly}(n,\Omega)2^{O(\rho(n))} poly ( n , Ω ) 2 O ( ρ ( n )) , the implied constant depending on k , c , s k,c,s k , c , s or Δ , s \Delta,s Δ , s .
For a k k k -CNF formula with n n n variables and at most c n cn c n clauses and weight vectors ω ( 1 ) , … , ω ( s ) ∈ [ 0 , Ω ] n \omega^{(1)},\ldots,\omega^{(s)}\in[0,\Omega]^n ω ( 1 ) , … , ω ( s ) ∈ [ 0 , Ω ] n : the number of satisfying assignments x x x with ∑ v ω v ( i ) x v = j i \sum_v\omega_v^{(i)}x_v=j_i ∑ v ω v ( i ) x v = j i for all i i i , for every tuple ( j 1 , … , j s ) (j_1,\ldots,j_s) ( j 1 , … , j s ) ; in particular whether a satisfying assignment of prescribed weights exists.
For a constraint system as in Theorem 6.1 : the number of assignments that satisfy constraints of total weight exactly j j j and have Hamming weight exactly i i i , for all ( i , j ) (i,j) ( i , j ) .
For a graph of maximum degree Δ \Delta Δ with vertex weights ω ( 1 ) , ω ( 2 ) ∈ [ 0 , Ω ] V \omega^{(1)},\omega^{(2)}\in[0,\Omega]^V ω ( 1 ) , ω ( 2 ) ∈ [ 0 , Ω ] V and a budget B B B : the maximum of ω ( 1 ) ( S ) \omega^{(1)}(S) ω ( 1 ) ( S ) over the independent sets S S S with ω ( 2 ) ( S ) ≤ B \omega^{(2)}(S)\le B ω ( 2 ) ( S ) ≤ B , and the number of independent sets attaining it.
Proof. (a) is Theorem 7.1 (i) with the clause indicators as factors and N 0 = 1 N_0=1 N 0 = 1 . (b) is the theorem with the factors of the proof of Theorem 6.1 , which take values in A N 0 \mathcal{A}_{N_0} A N 0 with N 0 = 1 + ∑ f ω f N_0=1+\sum_f\omega_f N 0 = 1 + ∑ f ω f and have coefficients of at most k k k bits, and the single weight vector ω ( 1 ) = ( 1 , … , 1 ) \omega^{(1)}=(1,\ldots,1) ω ( 1 ) = ( 1 , … , 1 ) . (c) is the theorem with the edge factors 1 − Y u Y v 1-Y_uY_v 1 − Y u Y v of the proof of Theorem 6.7 , at most Δ n / 2 \Delta n/2 Δ n /2 factors of scope 2, N 0 = 1 N_0=1 N 0 = 1 , and the two weight vectors: the maximum is the largest j 1 j_1 j 1 with ∑ j 2 ≤ B r ( j 1 , j 2 ) > 0 \sum_{j_2\le B}r(j_1,j_2)>0 ∑ j 2 ≤ B r ( j 1 , j 2 ) > 0 and the count is that sum.
Finite domains: cuts into several classes
Theorem 6.1 dealt with Boolean variables. Over a finite domain the same profile is obtained from Theorem 6.15 , and the extra generators of Theorem 7.1 record the sizes of the classes of a partition.
Theorem 7.3 (Profiles over a finite domain). Fix D ≥ 2 D\ge2 D ≥ 2 and k , c ≥ 1 k,c\ge1 k , c ≥ 1 . Given n ≥ 20 n\ge20 n ≥ 20 variables with values in [ D ] [D] [ D ] and m ≤ c n m\le cn m ≤ c n constraints C f : [ D ] I f → { 0 , 1 } C_f:[D]^{I_f}\to\{0,1\} C f : [ D ] I f → { 0 , 1 } with ∣ I f ∣ ≤ k |I_f|\le k ∣ I f ∣ ≤ k , given by their tables, with integer weights ω f ∈ [ 0 , Ω ] \omega_f\in[0,\Omega] ω f ∈ [ 0 , Ω ] , the numbers
p j = # { σ ∈ [ D ] n : ∑ f ω f C f ( σ ∣ I f ) = j } , 0 ≤ j ≤ ∑ f ω f , p_j=\#\left\{\sigma\in[D]^n:\sum_f\omega_f C_f(\sigma|_{I_f})=j\right\},\qquad0\le j\le\sum_f\omega_f, p j = # ⎩ ⎨ ⎧ σ ∈ [ D ] n : f ∑ ω f C f ( σ ∣ I f ) = j ⎭ ⎬ ⎫ , 0 ≤ j ≤ f ∑ ω f , are computed deterministically in time poly ( n , Ω ) 2 O D , k , c ( ρ ( n ) ) \operatorname{poly}(n,\Omega)2^{O_{D,k,c}(\rho(n))} poly ( n , Ω ) 2 O D , k , c ( ρ ( n )) .
Proof. Apply Theorem 6.15 with A = A N \mathcal{A}=\mathcal{A}_N A = A N , N = 1 + ∑ f ω f ≤ 1 + c n Ω N=1+\sum_f\omega_f\le1+cn\Omega N = 1 + ∑ f ω f ≤ 1 + c n Ω , and the tables ϕ f ( σ ) = W ω f C f ( σ ) \phi_f(\sigma)=W^{\omega_f C_f(\sigma)} ϕ f ( σ ) = W ω f C f ( σ ) , whose entries are monomials with coefficient 1 1 1 , so L = 1 L=1 L = 1 . The sum is ∑ σ W ∑ f ω f C f ( σ ∣ I f ) = ∑ j p j W j \sum_\sigma W^{\sum_f\omega_f C_f(\sigma|_{I_f})}=\sum_j p_jW^j ∑ σ W ∑ f ω f C f ( σ ∣ I f ) = ∑ j p j W j , with no term truncated. □ \square □
Corollary 7.4 (Max-k k k -Lin, Max-q q q -Cut and balanced partitions). Fix p , q , k , c ≥ 2 p,q,k,c\ge2 p , q , k , c ≥ 2 . The following are computed deterministically in time poly ( n , Ω ) 2 O ( ρ ( n ) ) \operatorname{poly}(n,\Omega)2^{O(\rho(n))} poly ( n , Ω ) 2 O ( ρ ( n )) , the implied constant depending on the fixed parameters.
For a system of m ≤ c n m\le cn m ≤ c n linear equations over Z / p Z \mathbb{Z}/p\mathbb{Z} Z / p Z in n n n unknowns, each equation involving at most k k k unknowns, with weights ω f ∈ [ 0 , Ω ] \omega_f\in[0,\Omega] ω f ∈ [ 0 , Ω ] : the number of assignments satisfying equations of total weight exactly j j j , for every j j j ; hence the maximum satisfiable weight and the number of optimal assignments.
For a graph G G G with n n n vertices and m ≤ c n m\le cn m ≤ c n edges with weights ω e ∈ [ 0 , Ω ] \omega_e\in[0,\Omega] ω e ∈ [ 0 , Ω ] : the number of maps σ : V → [ q ] \sigma:V\to[q] σ : V → [ q ] for which the edges u v uv uv with σ u ≠ σ v \sigma_u\ne\sigma_v σ u = σ v have total weight exactly j j j , for every j j j ; hence the maximum q q q -cut, and the minimum, which is the least weight of edges left monochromatic by a q q q -colouring, with the number of optimal maps.
In the situation of (ii), the number of maps σ \sigma σ with ∣ σ − 1 ( a ) ∣ = i a |\sigma^{-1}(a)|=i_a ∣ σ − 1 ( a ) ∣ = i a for a < q a<q a < q and cut weight j j j , for all ( i 1 , … , i q − 1 , j ) (i_1,\ldots,i_{q-1},j) ( i 1 , … , i q − 1 , j ) ; hence the maximum and the minimum q q q -cut over the partitions with prescribed class sizes, in particular over the balanced ones with every class of size ⌊ n / q ⌋ \lfloor n/q\rfloor ⌊ n / q ⌋ or ⌈ n / q ⌉ \lceil n/q\rceil ⌈ n / q ⌉ , and the number of optimal partitions.
Proof. (i) is Theorem 7.3 with D = p D=p D = p and the equations as constraints. (ii) is the theorem with D = q D=q D = q and the constraint C e ( a , b ) = [ a ≠ b ] C_e(a,b)=[a\ne b] C e ( a , b ) = [ a = b ] of weight ω e \omega_e ω e on the scope { u , v } \{u,v\} { u , v } of each edge. For (iii) apply Theorem 6.15 with D = q D=q D = q and A = A N 0 , n + 1 , … , n + 1 \mathcal{A}=\mathcal{A}_{N_0,n+1,\ldots,n+1} A = A N 0 , n + 1 , … , n + 1 , with q − 1 q-1 q − 1 copies of n + 1 n+1 n + 1 and N 0 = 1 + ∑ e ω e N_0=1+\sum_e\omega_e N 0 = 1 + ∑ e ω e , of dimension N = N 0 ( n + 1 ) q − 1 N=N_0(n+1)^{q-1} N = N 0 ( n + 1 ) q − 1 , which is polynomial in n n n and Ω \Omega Ω for fixed q q q . Take for each edge the table W ω e [ a ≠ b ] W^{\omega_e[a\ne b]} W ω e [ a = b ] and for each vertex the table U a U_a U a for a < q a<q a < q and 1 1 1 for a = q a=q a = q ; all entries are monomials, L = 1 L=1 L = 1 , and there are at most ( c + 1 ) n (c+1)n ( c + 1 ) n factors of scope at most 2 2 2 . The sum is ∑ σ W ω c u t ( σ ) ∏ a < q U a ∣ σ − 1 ( a ) ∣ \sum_\sigma W^{\omega_{\mathrm{cut}}(\sigma)}\prod_{a<q}U_a^{|\sigma^{-1}(a)|} ∑ σ W ω cut ( σ ) ∏ a < q U a ∣ σ − 1 ( a ) ∣ and nothing is truncated, since ∣ σ − 1 ( a ) ∣ ≤ n |\sigma^{-1}(a)|\le n ∣ σ − 1 ( a ) ∣ ≤ n . The balanced optimum is read off from the coefficients with every i a i_a i a , and n − ∑ a < q i a n-\sum_{a<q}i_a n − ∑ a < q i a , in { ⌊ n / q ⌋ , ⌈ n / q ⌉ } \{\lfloor n/q\rfloor,\lceil n/q\rceil\} {⌊ n / q ⌋ , ⌈ n / q ⌉} . □ \square □
Edge variables on bounded-degree graphs
In Theorem 6.20(ii) the variables sat on the edges of a graph and the constraints at its vertices. On a graph of maximum degree Δ \Delta Δ every constraint of that shape has scope at most Δ \Delta Δ , so every counting problem whose feasibility is a condition at each vertex on its incident edges is within reach. We collect the classical ones.
Theorem 7.5 (Vertex conditions on edge variables). Fix Δ ≥ 1 \Delta\ge1 Δ ≥ 1 and q ≥ 2 q\ge2 q ≥ 2 . Let G G G be a graph with n n n vertices, m m m edges and maximum degree Δ \Delta Δ . Each of the following is computed deterministically in time poly ( n , Ω ) 2 O Δ , q ( ρ ( n ) ) \operatorname{poly}(n,\Omega)2^{O_{\Delta,q}(\rho(n))} poly ( n , Ω ) 2 O Δ , q ( ρ ( n )) .
For sets F v ⊆ { 0 , 1 , … , Δ } F_v\subseteq\{0,1,\ldots,\Delta\} F v ⊆ { 0 , 1 , … , Δ } , v ∈ V v\in V v ∈ V , and integer edge weights ω e ∈ [ 0 , Ω ] \omega_e\in[0,\Omega] ω e ∈ [ 0 , Ω ] : the number of spanning subgraphs H H H of G G G with deg H ( v ) ∈ F v \deg_H(v)\in F_v deg H ( v ) ∈ F v for every v v v and ω ( E ( H ) ) = j \omega(E(H))=j ω ( E ( H )) = j , for every j j j . In particular the number of f f f -factors for any f : V → { 0 , … , Δ } f:V\to\{0,\ldots,\Delta\} f : V → { 0 , … , Δ } , of k k k -regular spanning subgraphs for any k k k , of 2 2 2 -factors, and of spanning subgraphs with all degrees even or all degrees odd, each by weight, and the maximum weight of each.
For a function d : V → { 0 , … , Δ } d:V\to\{0,\ldots,\Delta\} d : V → { 0 , … , Δ } : the number of orientations of G G G in which every vertex v v v has indegree d ( v ) d(v) d ( v ) ; for d = deg / 2 d=\deg/2 d = deg /2 this is the number of Eulerian orientations.
The number of proper edge colourings of G G G with q q q colours, and more generally the number of maps E → [ q ] E\to[q] E → [ q ] that satisfy at every vertex v v v a prescribed condition, given by a table on [ q ] deg v [q]^{\deg v} [ q ] d e g v , on the colours of the edges at v v v .
For a fixed orientation of G G G : the number of nowhere-zero Z / q Z \mathbb{Z}/q\mathbb{Z} Z / q Z -flows, that is of maps y : E → { 1 , … , q − 1 } y:E\to\{1,\ldots,q-1\} y : E → { 1 , … , q − 1 } with ∑ e into v y e ≡ ∑ e out of v y e ( m o d q ) \sum_{e\text{ into }v}y_e\equiv\sum_{e\text{ out of }v}y_e\pmod q ∑ e into v y e ≡ ∑ e out of v y e ( mod q ) at every vertex; and the
number of Z / q Z \mathbb{Z}/q\mathbb{Z} Z / q Z -flows with values in a prescribed subset of Z / q Z \mathbb{Z}/q\mathbb{Z} Z / q Z and prescribed residues b v b_v b v at the vertices.
Proof. An isolated vertex contributes the factor [ 0 ∈ F v ] [0 \in F_v] [ 0 ∈ F v ] in (i), the factor [ d ( v ) = 0 ] [d(v)=0] [ d ( v ) = 0 ] in (ii), the factor 1 1 1 in (iii) and the factor [ b v = 0 ] [b_v=0] [ b v = 0 ] in (iv); so we may delete the isolated vertices, after which n ≤ 2 m n \le2m n ≤ 2 m and m ≤ Δ n / 2 m \le\Delta n/2 m ≤ Δ n /2 . If m < 20 m<20 m < 20 the count is obtained by listing the at most 2 19 2^{19} 2 19 or q 19 q^{19} q 19 assignments. Otherwise the variables are indexed by the edges, and ρ ( m ) ≤ ρ ( Δ n / 2 ) = O Δ ( ρ ( n ) ) \rho(m) \le\rho(\Delta n/2)=O_\Delta(\rho(n)) ρ ( m ) ≤ ρ ( Δ n /2 ) = O Δ ( ρ ( n )) .
(i) Boolean variables y e = [ e ∈ E ( H ) ] y_e=[e\in E(H)] y e = [ e ∈ E ( H )] . For each vertex v v v take the multilinear extension of the indicator, on the scope E ( v ) E(v) E ( v ) of the edges at v v v , that ∑ e ∈ E ( v ) y e ∈ F v \sum_{e\in E(v)} y_e \in F_v ∑ e ∈ E ( v ) y e ∈ F v ; its coefficients are integers of absolute value at most 2 Δ 2^\Delta 2 Δ . For each edge take 1 + ( W ω e − 1 ) Y e 1+(W^{\omega_e}-1)Y_e 1 + ( W ω e − 1 ) Y e . There are n + m ≤ 3 m n+m \le3m n + m ≤ 3 m factors of scope at most Δ \Delta Δ on m m m variables, and the sum is ∑ H [ deg H ( v ) ∈ F v ∀ v ] W ω ( E ( H ) ) \sum_H[\deg_H(v)\in F_v\ \forall v]W^{\omega(E(H))} ∑ H [ deg H ( v ) ∈ F v ∀ v ] W ω ( E ( H )) in A N \mathcal{A}_N A N , N = 1 + ∑ e ω e N=1+\sum_e\omega_e N = 1 + ∑ e ω e , with nothing truncated. Theorem 5.3 with k = Δ k=\Delta k = Δ , c = 3 c=3 c = 3 and Lemma 5.5 with L = Δ L=\Delta L = Δ give the bound. The special cases are F v = { f ( v ) } F_v=\{f(v)\} F v = { f ( v )} , F v = { k } F_v=\{k\} F v = { k } , F v = { 2 } F_v=\{2\} F v = { 2 } , and F v F_v F v the even or the odd numbers up to Δ \Delta Δ .
(ii) Fix a labelling of the vertices and let y e = 1 y_e=1 y e = 1 when e e e is oriented towards its endpoint of larger label. The indegree of v v v is ∑ e ∈ E ( v ) [ e is oriented into v ] \sum_{e\in E(v)}[e\text{ is oriented into }v] ∑ e ∈ E ( v ) [ e is oriented into v ] , a function of y ∣ E ( v ) y|_{E(v)} y ∣ E ( v ) . Take A = Q \mathcal{A}=\mathbb{Q} A = Q and for each vertex the multilinear extension of the indicator that this function equals d ( v ) d(v) d ( v ) ; the sum of the n ≤ 2 m n\le2m n ≤ 2 m factors of scope at most Δ \Delta Δ is the number of orientations with the prescribed indegrees.
(iii) Apply Theorem 6.15 on the m m m variables y e ∈ [ q ] y_e\in[q] y e ∈ [ q ] with the n ≤ 2 m n\le2m n ≤ 2 m factors given by the tables at the vertices, of scope at most Δ \Delta Δ and entries 0 0 0 or 1 1 1 ; for proper colourings the table at v v v is the indicator that the colours of the edges at v v v are distinct.
(iv) Apply Theorem 6.15 with D = q − 1 D=q-1 D = q − 1 for the nowhere-zero flows, the variable y e ∈ [ q − 1 ] y_e\in[q-1] y e ∈ [ q − 1 ] being the flow value, or D = ∣ S ∣ D=|S| D = ∣ S ∣ for values in a subset S S S , and at each vertex the table of the condition ∑ i n y e − ∑ o u t y e ≡ b v ( m o d q ) \sum_{\mathrm{in}}y_e-\sum_{\mathrm{out}}y_e\equiv b_v\pmod q ∑ in y e − ∑ out y e ≡ b v ( mod q ) on [ D ] deg v [D]^{\deg v} [ D ] d e g v .
Corollary 7.6 (Hafnians). Fix Δ ≥ 1 \Delta\ge1 Δ ≥ 1 . The hafnian haf ( A ) = ∑ M ∏ { i , j } ∈ M a i j \operatorname{haf}(A)=\sum_M\prod_{\{i,j\}\in M}a_{ij} haf ( A ) = ∑ M ∏ { i , j } ∈ M a ij of a symmetric 2 n × 2 n 2n\times2n 2 n × 2 n integer matrix A A A with at most Δ \Delta Δ nonzero entries in every row, the sum running over the perfect matchings M M M of the complete graph on [ 2 n ] [2n] [ 2 n ] , with entries of absolute value at most L L L , is computed deterministically in time poly ( n , L ) 2 O Δ ( ρ ( n ) ) \operatorname{poly}(n,L)2^{O_\Delta(\rho(n))} poly ( n , L ) 2 O Δ ( ρ ( n )) .
Proof. Only matchings inside the support graph G G G of A A A , of maximum degree Δ \Delta Δ , contribute. Take A = Q \mathcal{A}=\mathbb{Q} A = Q , one Boolean variable per edge of G, for each vertex the multilinear extension of the indicator that exactly one incident edge is chosen, and for each edge the factor $1+(a_e-1)Y_e; the sum is haf ( A ) \operatorname{haf}(A) haf ( A ) , and the proof of Theorem 6.21 applies word for word.
Remark 7.7. Counting Eulerian orientations is #P-complete [25 ] , deciding whether a 3-regular graph has a proper 3-edge-colouring is NP-complete [19 ] , and the number of nowhere-zero Z / q Z \mathbb{Z}/q\mathbb{Z} Z / q Z -flows is the flow polynomial F ( G ; q ) F(G;q) F ( G ; q ) of Tutte [32 ] , whose evaluation at every fixed integer q ≥ 3 q\ge3 q ≥ 3 is #P-hard [24 ] . On graphs of bounded degree each of them is now computed in time 2 o ( n ) 2^{o(n)} 2 o ( n ) . The flow polynomial is reached by a second route in the next subsection.
The Tutte polynomial on the hyperbolas ( x − 1 ) ( y − 1 ) = q (x-1)(y-1)=q ( x − 1 ) ( y − 1 ) = q
Let G = ( V , E ) G=(V,E) G = ( V , E ) be a graph, loops and multiple edges allowed, and for A ⊆ E A\subseteq E A ⊆ E let c ( A ) c(A) c ( A ) be the number of connected components of the spanning subgraph ( V , A ) (V,A) ( V , A ) . The Tutte polynomial is
T ( G ; x , y ) = ∑ A ⊆ E ( x − 1 ) c ( A ) − c ( E ) ( y − 1 ) c ( A ) + ∣ A ∣ − ∣ V ∣ . (64) T(G;x,y)=\sum_{A\subseteq E}(x-1)^{c(A)-c(E)}(y-1)^{c(A)+|A|-|V|}. \tag*{(64)} T ( G ; x , y ) = A ⊆ E ∑ ( x − 1 ) c ( A ) − c ( E ) ( y − 1 ) c ( A ) + ∣ A ∣ − ∣ V ∣ . (64)
and the random-cluster, or multivariate Potts, partition function of Fortuin and Kasteleyn [15 ] is
Z ( G ; q , v ) = ∑ A ⊆ E q c ( A ) v ∣ A ∣ . (65) Z(G;q,v)=\sum_{A\subseteq E}q^{c(A)}v^{|A|}. \tag*{(65)} Z ( G ; q , v ) = A ⊆ E ∑ q c ( A ) v ∣ A ∣ . (65)
Both are polynomials in their arguments, and a comparison of exponents gives, for x ≠ 1 x\ne1 x = 1 , y ≠ 1 y\ne1 y = 1 ,
T ( G ; x , y ) = ( x − 1 ) − c ( E ) ( y − 1 ) − ∣ V ∣ Z ( G ; ( x − 1 ) ( y − 1 ) , y − 1 ) , (66) T(G;x,y)=(x-1)^{-c(E)}(y-1)^{-|V|}Z\bigl(G;(x-1)(y-1),y-1\bigr), \tag*{(66)} T ( G ; x , y ) = ( x − 1 ) − c ( E ) ( y − 1 ) − ∣ V ∣ Z ( G ; ( x − 1 ) ( y − 1 ) , y − 1 ) , (66)
since ( x − 1 ) c ( A ) ( y − 1 ) c ( A ) ( y − 1 ) ∣ A ∣ (x-1)^{c(A)}(y-1)^{c(A)}(y-1)^{|A|} ( x − 1 ) c ( A ) ( y − 1 ) c ( A ) ( y − 1 ) ∣ A ∣ divided by ( x − 1 ) c ( E ) ( y − 1 ) ∣ V ∣ (x-1)^{c(E)}(y-1)^{|V|} ( x − 1 ) c ( E ) ( y − 1 ) ∣ V ∣ is the summand of (64) . Thus the Tutte polynomial on the hyperbola H q = { ( x , y ) : ( x − 1 ) ( y − 1 ) = q } H_q=\{(x,y):(x-1)(y-1)=q\} H q = {( x , y ) : ( x − 1 ) ( y − 1 ) = q } is the function v ↦ Z ( G ; q , v ) v\mapsto Z(G;q,v) v ↦ Z ( G ; q , v ) up to the explicit prefactor, and for a positive integer q q q that function is a sum over colourings [15 , 30 ] .
Lemma 7.8 (Fortuin–Kasteleyn). For every integer q ≥ 1 q\ge1 q ≥ 1 and every v v v ,
Z ( G ; q , v ) = ∑ σ : V → [ q ] ∏ u v ∈ E ( 1 + v [ σ u = σ v ] ) . Z(G;q,v)=\sum_{\sigma:V\to[q]}\prod_{uv\in E}(1+v[\sigma_u=\sigma_v]). Z ( G ; q , v ) = σ : V → [ q ] ∑ uv ∈ E ∏ ( 1 + v [ σ u = σ v ]) .
Proof. Expand the product: it is ∑ A ⊆ E v ∣ A ∣ ∏ u v ∈ A [ σ u = σ v ] \sum_{A\subseteq E}v^{|A|}\prod_{uv\in A}[\sigma_u=\sigma_v] ∑ A ⊆ E v ∣ A ∣ ∏ uv ∈ A [ σ u = σ v ] . For fixed A A A the product is 1 1 1 exactly when σ \sigma σ is constant on each component of ( V , A ) (V,A) ( V , A ) , and there are q c ( A ) q^{c(A)} q c ( A ) such σ \sigma σ . Summing over σ \sigma σ first gives (65) . □
Lemma 7.9 (Flows). Fix an orientation of G G G and an integer q ≥ 2 q\ge2 q ≥ 2 . For A ⊆ E A\subseteq E A ⊆ E the number of Z / q Z \mathbb{Z}/q\mathbb{Z} Z / q Z -flows on ( V , A ) (V,A) ( V , A ) , that is of maps y : A → Z / q Z y:A\to\mathbb{Z}/q\mathbb{Z} y : A → Z / q Z with ∑ e ∈ A i n t o v y e = ∑ e ∈ A o u t o f v y e \sum_{e\in A\ \mathrm{into}\ v}y_e=\sum_{e\in A\ \mathrm{out\ of}\ v}y_e ∑ e ∈ A into v y e = ∑ e ∈ A out of v y e at every vertex, is q ∣ A ∣ − ∣ V ∣ + c ( A ) q^{|A|-|V|+c(A)} q ∣ A ∣ − ∣ V ∣ + c ( A ) . Consequently the number F ( G ; q ) F(G;q) F ( G ; q ) of nowhere-zero Z / q Z \mathbb{Z}/q\mathbb{Z} Z / q Z -flows on G G G satisfies
F ( G ; q ) = ∑ A ⊆ E ( − 1 ) ∣ E ∖ A ∣ q ∣ A ∣ − ∣ V ∣ + c ( A ) = ( − 1 ) ∣ E ∣ q − ∣ V ∣ Z ( G ; q , − q ) . (67) F(G;q)=\sum_{A\subseteq E}(-1)^{|E\setminus A|}q^{|A|-|V|+c(A)}=(-1)^{|E|}q^{-|V|}Z(G;q,-q). \tag*{(67)} F ( G ; q ) = A ⊆ E ∑ ( − 1 ) ∣ E ∖ A ∣ q ∣ A ∣ − ∣ V ∣ + c ( A ) = ( − 1 ) ∣ E ∣ q − ∣ V ∣ Z ( G ; q , − q ) . (67)
Proof. Let ∂ : ( Z / q Z ) A → ( Z / q Z ) V \partial:(\mathbb{Z}/q\mathbb{Z})^A\to(\mathbb{Z}/q\mathbb{Z})^V ∂ : ( Z / q Z ) A → ( Z / q Z ) V send y y y to the vector of net inflows ( ∂ y ) v = ∑ e i n t o v y e − ∑ e o u t o f v y e (\partial y)_v=\sum_{e\ \mathrm{into}\ v}y_e-\sum_{e\ \mathrm{out\ of}\ v}y_e ( ∂ y ) v = ∑ e into v y e − ∑ e out of v y e . The flows on ( V , A ) (V,A) ( V , A ) form ker ∂ \ker\partial ker ∂ . Each edge contributes + y e +y_e + y e at one endpoint and − y e -y_e − y e at the other, both in the same component of ( V , A ) (V,A) ( V , A ) , so the image of ∂ \partial ∂ lies in the group B B B of vectors whose sum over each component is zero, of order q ∣ V ∣ − c ( A ) q^{|V|-c(A)} q ∣ V ∣ − c ( A ) . Conversely every b ∈ B b\in B b ∈ B is attained: choose a spanning forest T T T of ( V , A ) (V,A) ( V , A ) and proceed by induction on ∣ V ∣ |V| ∣ V ∣ ; if ∣ V ∣ = 1 |V|=1 ∣ V ∣ = 1 then b = 0 b=0 b = 0 and y = 0 y=0 y = 0 serves; otherwise pick a leaf w w w of T T T with pendant edge e e e to w ′ w' w ′ , or an isolated vertex w w w of T T T , for which b w = 0 b_w=0 b w = 0 . In the first case set y e = ± b w y_e=\pm b_w y e = ± b w according to the orientation of e e e , so that ( ∂ y ) w = b w (\partial y)_w=b_w ( ∂ y ) w = b w , delete w w w , replace b w ′ b_{w'} b w ′ by b w ′ + b w b_{w'}+b_w b w ′ + b w , which keeps the component sums zero, and apply the induction to ( V ∖ w , A ∖ e ) (V\setminus w,A\setminus e) ( V ∖ w , A ∖ e ) ; in the second case delete w w w . Hence ∣ ker ∂ ∣ = q ∣ A ∣ / q ∣ V ∣ − c ( A ) |\ker\partial|=q^{|A|}/q^{|V|-c(A)} ∣ ker ∂ ∣ = q ∣ A ∣ / q ∣ V ∣ − c ( A ) .
For (67) , the flows on ( V , E ) (V,E) ( V , E ) that vanish on a set S ⊆ E S\subseteq E S ⊆ E correspond to the flows on ( V , E ∖ S ) (V,E\setminus S) ( V , E ∖ S ) . By inclusion and exclusion over the set of edges at which a flow vanishes,
F ( G ; q ) = ∑ S ⊆ E ( − 1 ) ∣ S ∣ q ∣ E ∖ S ∣ − ∣ V ∣ + c ( E ∖ S ) , F(G;q)=\sum_{S\subseteq E}(-1)^{|S|}q^{|E\setminus S|-|V|+c(E\setminus S)}, F ( G ; q ) = S ⊆ E ∑ ( − 1 ) ∣ S ∣ q ∣ E ∖ S ∣ − ∣ V ∣ + c ( E ∖ S ) ,
which is the first expression with A = E ∖ S A=E\setminus S A = E ∖ S ; and
( − 1 ) ∣ E ∣ q − ∣ V ∣ Z ( G ; q , − q ) = ∑ A ( − 1 ) ∣ E ∣ − ∣ A ∣ q ∣ A ∣ + c ( A ) − ∣ V ∣ (-1)^{|E|}q^{-|V|}Z(G;q,-q)=\sum_A(-1)^{|E|-|A|}q^{|A|+c(A)-|V|} ( − 1 ) ∣ E ∣ q − ∣ V ∣ Z ( G ; q , − q ) = A ∑ ( − 1 ) ∣ E ∣ − ∣ A ∣ q ∣ A ∣ + c ( A ) − ∣ V ∣
is the same sum. □
Theorem 7.10 (Tutte polynomial on bounded-degree graphs). Fix Δ ≥ 1 \Delta\ge1 Δ ≥ 1 and an integer q ≥ 1 q\ge1 q ≥ 1 . Let G G G be a graph with n n n vertices and maximum degree Δ \Delta Δ , and let v = a / b v=a/b v = a / b be a rational number with ∣ a ∣ , ∣ b ∣ ≤ 2 L |a|,|b|\le2^L ∣ a ∣ , ∣ b ∣ ≤ 2 L . Then Z ( G ; q , v ) Z(G;q,v) Z ( G ; q , v ) is computed deterministically in time poly ( n , L ) 2 O Δ , q ( ρ ( n ) ) \operatorname{poly}(n,L)2^{O_{\Delta,q}(\rho(n))} poly ( n , L ) 2 O Δ , q ( ρ ( n )) . Consequently T ( G ; x , y ) T(G;x,y) T ( G ; x , y ) is computed in that time at every rational point ( x , y ) (x,y) ( x , y ) with ( x − 1 ) ( y − 1 ) = q (x-1)(y-1)=q ( x − 1 ) ( y − 1 ) = q and y ≠ 1 y\ne1 y = 1 , and in particular
the chromatic polynomial P ( G ; q ) = Z ( G ; q , − 1 ) P(G;q)=Z(G;q,-1) P ( G ; q ) = Z ( G ; q , − 1 ) , the number of proper q q q -colourings;
the flow polynomial F ( G ; q ) = ( − 1 ) ∣ E ∣ q − ∣ V ∣ Z ( G ; q , − q ) F(G;q)=(-1)^{|E|}q^{-|V|}Z(G;q,-q) F ( G ; q ) = ( − 1 ) ∣ E ∣ q − ∣ V ∣ Z ( G ; q , − q ) , the number of nowhere-zero Z / q Z \mathbb{Z}/q\mathbb{Z} Z / q Z -flows;
Figure 4. The random-cluster partition function Z ( G ; q , v ) Z(G;q,v) Z ( G ; q , v ) of the Petersen graph over the ( q , v ) (q,v) ( q , v ) -plane, as sign ( Z ) log 10 ( 1 + ∣ Z ∣ ) \operatorname{sign}(Z)\log_{10}(1+|Z|) sign ( Z ) log 10 ( 1 + ∣ Z ∣ ) , computed from the 2 15 2^{15} 2 15 edge subsets. Theorem 7.10 evaluates it along the lines q = 1 , 2 , 3 , … q=1,2,3,\ldots q = 1 , 2 , 3 , … drawn on the surface, which are the hyperbolas H q H_q H q of the Tutte plane; the marked points are the proper q q q -colourings ( v = − 1 ) (v=-1) ( v = − 1 ) and the nowhere-zero flows ( v = − q ) (v=-q) ( v = − q ) .
(iii) the partition function of the q q q -state Potts model with coupling J J J at inverse temperature β \beta β , ∑ σ exp ( β J ∑ u v [ σ u = σ v ] ) = Z ( G ; q , e β J − 1 ) \sum_{\sigma}\exp(\beta J\sum_{uv}[\sigma_u=\sigma_v])=Z(G;q,e^{\beta J}-1) ∑ σ exp ( β J ∑ uv [ σ u = σ v ]) = Z ( G ; q , e β J − 1 ) , whenever e β J e^{\beta J} e β J is rational, and more generally with any rational edge-dependent couplings v e v_e v e in place of v v v .
Proof. By Lemma 7.8, b m Z ( G ; q , v ) = ∑ σ : V → [ q ] ∏ u v ∈ E ( b + a [ σ u = σ v ] ) b^mZ(G;q,v)=\sum_{\sigma:V\to[q]}\prod_{uv\in E}(b+a[\sigma_u=\sigma_v]) b m Z ( G ; q , v ) = ∑ σ : V → [ q ] ∏ uv ∈ E ( b + a [ σ u = σ v ]) , where m ≤ Δ n / 2 m\leq\Delta n/2 m ≤ Δ n /2 is the number of edges. This is the sum of Theorem 6.15 with D = q D=q D = q , A = Q \mathcal{A}=\mathbb{Q} A = Q , one factor of scope { u , v } \{u,v\} { u , v } per edge with the table ( s , t ) ↦ b + a [ s = t ] (s,t)\mapsto b+a[s=t] ( s , t ) ↦ b + a [ s = t ] , whose entries are integers of at most L + 1 L+1 L + 1 bits, and no vertex factors; a loop at u u u contributes the constant factor a + b a+b a + b . Theorem 6.15 with k = 2 k=2 k = 2 and c = Δ / 2 + 1 c=\Delta/2+1 c = Δ/2 + 1 gives b m Z ( G ; q , v ) b^mZ(G;q,v) b m Z ( G ; q , v ) in the stated time, and the division by b m b^m b m is polynomial. For T ( G ; x , y ) T(G;x,y) T ( G ; x , y ) use (7.3), with c ( E ) c(E) c ( E ) found by a graph search. For edge-dependent v e = a e / b e v_e=a_e/b_e v e = a e / b e the table of the edge e e e is b e + a e [ s = t ] b_e+a_e[s=t] b e + a e [ s = t ] and the sum is ∏ e b e \prod_e b_e ∏ e b e times ∑ σ ∏ e ( 1 + v e [ σ u = σ v ] ) \sum_\sigma\prod_e(1+v_e[\sigma_u=\sigma_v]) ∑ σ ∏ e ( 1 + v e [ σ u = σ v ]) . Item (i) is Lemma 7.8 with v = − 1 v=-1 v = − 1 , since 1 − [ σ u = σ v ] 1-[\sigma_u=\sigma_v] 1 − [ σ u = σ v ] is the indicator of a proper edge; item (ii) is Lemma 7.9; item (iii) is Lemma 7.8 with 1 + v = e β J 1+v=e^{\beta J} 1 + v = e β J , the factor e β J [ σ u = σ v ] e^{\beta J[\sigma_u=\sigma_v]} e β J [ σ u = σ v ] being 1 + v [ σ u = σ v ] 1+v[\sigma_u=\sigma_v] 1 + v [ σ u = σ v ] .
Remark 7.11. Evaluating the Tutte polynomial is #P-hard at every point of the plane except on the hyperbola H 1 H_1 H 1 and at eight special points [24 ] ; the points of H q H_q H q for positive integers $q include the chromatic and flow polynomials at q q q , the Ising model (q = 2 q = 2 q = 2 ) and the Potts models. On bounded-degree graphs Theorem 7.10 evaluates all of them in time 2 o ( n ) 2^{o(n)} 2 o ( n ) . The theorem does not evaluate T T T off these hyperbolas: the number of acyclic orientations T ( G ; 2 , 0 ) T(G;2,0) T ( G ; 2 , 0 ) , which lies on H − 1 H_{-1} H − 1 , the number of forests T ( G ; 2 , 1 ) T(G;2,1) T ( G ; 2 , 1 ) on H 0 H_0 H 0 , and the reliability polynomial on H 1 H_1 H 1 , trivial, are not covered, and neither is the chromatic polynomial as a polynomial in q q q , which would need the values at n + 1 n+1 n + 1 integers q q q while the constant in the exponent grows with q q q .
Linear codes with sparse parity checks
A binary linear code of length n n n given by a parity-check matrix H ∈ F 2 m × n H \in\mathbb{F}_2^{m \times n} H ∈ F 2 m × n is C = { x ∈ F 2 n : H x = 0 } C = \{x \in\mathbb{F}_2^n : Hx = 0\} C = { x ∈ F 2 n : H x = 0 } . Its weight enumerator is the sequence A i = # { x ∈ C : wt ( x ) = i } A_i = \#\{x \in C : \operatorname{wt}(x) = i\} A i = # { x ∈ C : wt ( x ) = i } , 0 ≤ i ≤ n 0 \le i \le n 0 ≤ i ≤ n , where wt \operatorname{wt} wt is the Hamming weight, and its minimum distance is d ( C ) = min { i ≥ 1 : A i > 0 } d(C) = \min\{i \ge1 : A_i > 0\} d ( C ) = min { i ≥ 1 : A i > 0 } . For a received word y ∈ F 2 n y \in\mathbb{F}_2^n y ∈ F 2 n the distance distribution of y y y is A i ( y ) = # { x ∈ C : wt ( x + y ) = i } A_i(y) = \#\{x \in C : \operatorname{wt}(x+y) = i\} A i ( y ) = # { x ∈ C : wt ( x + y ) = i } , the weight enumerator of the coset y + C y+C y + C ; a codeword at distance min { i : A i ( y ) > 0 } \min\{i : A_i(y) > 0\} min { i : A i ( y ) > 0 } from y y y is a maximum-likelihood decoding of y y y on the binary symmetric channel. The codes whose parity-check matrix has rows of bounded weight are the low-density parity-check codes of Gallager [16 ] .
Theorem 7.12 (Sparse parity checks). Fix k , c ≥ 1 k, c \ge1 k , c ≥ 1 . Let C ⊆ F 2 n C \subseteq\mathbb{F}_2^n C ⊆ F 2 n be given by a parity-check matrix with m ≤ c n m \le cn m ≤ c n rows, each of weight at most k k k .
(i) The weight enumerator ( A i ) 0 ≤ i ≤ n (A_i)_{0 \le i \le n} ( A i ) 0 ≤ i ≤ n , and hence d ( C ) d(C) d ( C ) and the number of minimum-weight codewords, are computed deterministically in time poly ( n ) 2 O k , c ( ρ ( n ) ) \operatorname{poly}(n)2^{O_{k,c}(\rho(n))} poly ( n ) 2 O k , c ( ρ ( n )) .
(ii) For every y ∈ F 2 n y \in\mathbb{F}_2^n y ∈ F 2 n the distance distribution ( A i ( y ) ) i (A_i(y))_i ( A i ( y ) ) i is computed in the same time, and a codeword nearest to y y y is found in 2 n + 1 2n+1 2 n + 1 times that time.
(iii) For a code over a finite field F Q \mathbb{F}_Q F Q , or over any alphabet of fixed size Q Q Q with the checks given as tables on [ Q ] k [Q]^k [ Q ] k , given by m ≤ c n m \le cn m ≤ c n checks each involving at most k k k coordinates, the Hamming weight enumerator and the distance distribution of every received word are computed in time poly ( n ) 2 O Q , k , c ( ρ ( n ) ) \operatorname{poly}(n)2^{O_{Q,k,c}(\rho(n))} poly ( n ) 2 O Q , k , c ( ρ ( n )) ; so is the complete weight enumerator, the number of codewords with i s i_s i s coordinates equal to s s s for each symbol s s s , in time poly ( n Q ) 2 O Q , k , c ( ρ ( n ) ) \operatorname{poly}(n^Q)2^{O_{Q,k,c}(\rho(n))} poly ( n Q ) 2 O Q , k , c ( ρ ( n )) .
Proof. (i) Boolean variables x 1 , … , x n x_1,\ldots,x_n x 1 , … , x n and A = A n + 1 \mathcal{A}=\mathcal{A}_{n+1} A = A n + 1 . For each row h h h of H H H take the multilinear extension of the indicator, on the scope supp ( h ) \operatorname{supp}(h) supp ( h ) of size at most k k k , that ∑ v ∈ supp ( h ) x v \sum_{v \in\operatorname{supp}(h)} x_v ∑ v ∈ supp ( h ) x v is even; its coefficients are integers of absolute value at most 2 k 2^k 2 k . For each coordinate take 1 + ( W − 1 ) Y v 1+(W-1)Y_v 1 + ( W − 1 ) Y v . There are at most ( c + 1 ) n (c+1)n ( c + 1 ) n factors of scope at most k k k , and the sum is ∑ x ∈ C W wt ( x ) = ∑ i A i W i \sum_{x \in C} W^{\operatorname{wt}(x)}=\sum_i A_iW^i ∑ x ∈ C W wt ( x ) = ∑ i A i W i , with no truncation. Theorem 5.3 and Lemma 5.5 with N = n + 1 N=n+1 N = n + 1 , L = k L=k L = k give the time; d ( C ) d(C) d ( C ) and A d A_d A d are read off.
(ii) Replace the coordinate factor by the multilinear extension of W [ x v ≠ y v ] W^{[x_v \ne y_v]} W [ x v = y v ] , which is 1 + ( W − 1 ) Y v 1+(W-1)Y_v 1 + ( W − 1 ) Y v if y v = 0 y_v=0 y v = 0 and W + ( 1 − W ) Y v W+(1-W)Y_v W + ( 1 − W ) Y v if y v = 1 y_v=1 y v = 1 ; the sum is ∑ x ∈ C W wt ( x + y ) = ∑ i A i ( y ) W i \sum_{x \in C}W^{\operatorname{wt}(x+y)}=\sum_i A_i(y)W^i ∑ x ∈ C W wt ( x + y ) = ∑ i A i ( y ) W i . For the nearest codeword let i 0 = min { i : A i ( y ) > 0 } i_0=\min\{i:A_i(y)>0\} i 0 = min { i : A i ( y ) > 0 } and fix the coordinates one at a time: fixing x 1 = ϵ x_1=\epsilon x 1 = ϵ replaces every row containing coordinate 1 by the indicator that the remaining coordinates have parity ϵ h 1 \epsilon h_1 ϵ h 1 , a factor of smaller scope, and leaves the system sparse; compute the two distance distributions, keep a value ϵ \epsilon ϵ for which the coefficient of W i 0 W^{i_0} W i 0 is positive, and continue with the next coordinate. After n n n steps the assignment is a codeword at distance i 0 i_0 i 0 from y y y , and 2 n + 1 2n+1 2 n + 1 distributions have been computed.
(iii) Apply Theorem 6.15 with D = Q D=Q D = Q : the variables take values in the alphabet, each check is a table on at most k k k coordinates, and the coordinate factor has the table s ↦ W [ s ≠ 0 ] s \mapsto W^{[s \ne0]} s ↦ W [ s = 0 ] , or s ↦ W [ s ≠ y v ] s \mapsto W^{[s \ne y_v]} s ↦ W [ s = y v ] for the distance to y y y , in A n + 1 \mathcal{A}_{n+1} A n + 1 ; for the complete weight enumerator the table is s ↦ W s s \mapsto W_s s ↦ W s in A n + 1 , … , n + 1 \mathcal{A}_{n+1,\ldots,n+1} A n + 1 , … , n + 1 with one generator per symbol, of dimension ( n + 1 ) Q (n+1)Q ( n + 1 ) Q . □ \square □
Remark 7.13. Computing the minimum distance of a binary linear code is NP-hard [34 ] , and so is maximum-likelihood decoding [8 ] ; both are posed with the code given by a generator or a parity-check matrix of unrestricted density. For the low-density codes of Gallager, with m ≤ n m \le n m ≤ n rows of bounded weight, Theorem 7.12 gives the exact minimum distance, the complete weight enumerator and exact maximum-likelihood decoding of every received word in deterministic time 2 o ( n ) 2^{o(n)} 2 o ( n ) , where the previously known exact methods are exponential in the dimension or the redundancy of the code. No bound on the column weights is needed, by Lemma 5.2 .
Bounded-degree hypergraphs
A hypergraph H = ( V , E ) \mathcal{H}=(V,\mathcal{E}) H = ( V , E ) has vertex set V V V , ∣ V ∣ = n |V|=n ∣ V ∣ = n , and a multiset E \mathcal{E} E of edges e ⊆ V e \subseteq V e ⊆ V . A matching is a set of pairwise disjoint edges, a perfect matching or exact cover is a matching whose union is V V V , a transversal is a set of vertices meeting every edge, an independent set is a set of vertices containing no edge, and a strong independent set is a set of vertices no two of which lie in a common edge. A q q q -colouring of V V V is proper if no edge of size at least two is monochromatic.
Theorem 7.14 (Hypergraphs). Fix k k k , Δ \Delta Δ , c ≥ 1 c \ge1 c ≥ 1 and q ≥ 2 q \ge2 q ≥ 2 , and let H \mathcal{H} H have n n n vertices and edges of size at most k k k .
(i) If every vertex lies in at most Δ \Delta Δ edges and the edges have integer weights in [ 0 , Ω ] [0,\Omega] [ 0 , Ω ] : the number of matchings of each weight and the number of exact covers of each weight, hence the maximum weight of a packing and the number of exact covers, in time poly ( n , Ω ) 2 O k , Δ ( ρ ( n ) ) \operatorname{poly}(n,\Omega)2^{O_{k,\Delta}(\rho(n))} poly ( n , Ω ) 2 O k , Δ ( ρ ( n )) .
(ii) If ∣ E ∣ ≤ c n |\mathcal{E}| \le cn ∣ E ∣ ≤ c n and the vertices have integer weights in [ 0 , Ω ] [0,\Omega] [ 0 , Ω ] : the number of transversals, of independent sets and of strong independent sets of each weight, in time poly ( n , Ω ) 2 O k , c ( ρ ( n ) ) \operatorname{poly}(n,\Omega)2^{O_{k,c}(\rho(n))} poly ( n , Ω ) 2 O k , c ( ρ ( n )) .
(iii) If ∣ E ∣ ≤ c n |\mathcal{E}| \le cn ∣ E ∣ ≤ c n : the number of proper q q q -colourings, and the number of q q q -colourings with exactly j j j monochromatic edges for every j j j , in time poly ( n ) 2 O q , k , c ( ρ ( n ) ) \operatorname{poly}(n)2^{O_{q,k,c}(\rho(n))} poly ( n ) 2 O q , k , c ( ρ ( n )) .
Proof. (i) A vertex in no edge lies in no exact cover and in every matching trivially; delete such vertices, so that n ≤ k ∣ E ∣ n \le k|\mathcal{E}| n ≤ k ∣ E ∣ , and if ∣ E ∣ < 20 |\mathcal{E}| < 20 ∣ E ∣ < 20 list the subsets. Boolean variables y e y_e y e , e ∈ E e \in\mathcal{E} e ∈ E ; for each vertex v v v the multilinear extension on the scope { e : v ∈ e } \{e:v \in e\} { e : v ∈ e } , of size at most Δ \Delta Δ , of the indicator that at most one (for matchings) or exactly one (for exact covers) incident edge is chosen; for each edge 1 + ( W ω e − 1 ) Y e 1+(W^{\omega_e}-1)Y_e 1 + ( W ω e − 1 ) Y e . There are n + ∣ E ∣ ≤ ( k + 1 ) ∣ E ∣ n+|\mathcal{E}| \le(k+1)|\mathcal{E}| n + ∣ E ∣ ≤ ( k + 1 ) ∣ E ∣ factors of scope at most Δ \Delta Δ , the sum is ∑ M W ω ( M ) \sum_M W^{\omega(M)} ∑ M W ω ( M ) over the matchings, or over the exact covers, in A N \mathcal{A}_N A N with N = 1 + ∑ e ω e N=1+\sum_e\omega_e N = 1 + ∑ e ω e , and Theorem 5.3 on ∣ E ∣ ≤ Δ n |\mathcal{E}| \le\Delta n ∣ E ∣ ≤ Δ n variables with the constants Δ \Delta Δ and k + 1 k+1 k + 1 , with Lemma 5.5 , L = Δ L=\Delta L = Δ , gives the bound; ρ ( ∣ E ∣ ) = O Δ ( ρ ( n ) ) \rho(|\mathcal{E}|)=O_\Delta(\rho(n)) ρ ( ∣ E ∣ ) = O Δ ( ρ ( n )) .
(ii) Boolean variables x v x_v x v ; for each edge e e e the multilinear extension, on the scope e e e , of the indicator that some x v x_v x v , v ∈ e v \in e v ∈ e , is 1 1 1 (transversals), that not all are 1 1 1 (independent sets), or that at most one is 1 1 1 (strong independent sets); for each vertex x v 1 ( W ω v − 1 ) x_v^{\phantom{1}}(W^{\omega_v}-1) x v 1 ( W ω v − 1 ) . At most ( c + 1 ) n (c+1)n ( c + 1 ) n factors of scope at most k k k ; Theorem 5.3 and Lemma 5.5 with L = k L=k L = k .
(iii) Theorem 7.3 with D = q D=q D = q and, for each edge of size at least two, the constraint that it is monochromatic, of weight 1 1 1 : the coefficient p j p_j p j counts the colourings with j j j monochromatic edges and p 0 p_0 p 0 the proper ones. □ \square □
Circuits of linear size
A Boolean circuit with n n n inputs is a sequence of gates g 1 , … , g s g_1,\ldots,g_s g 1 , … , g s , each computing a function of at most k k k earlier gates or inputs given by its truth table, with t t t of the gates designated as outputs. Its size is s s s .
Theorem 7.15 (Linear-size circuits of bounded fan-in). Fix k k k , c ≥ 1 c \ge1 c ≥ 1 . Let C C C be a circuit with n ≥ 20 n \ge20 n ≥ 20 inputs, s ≤ c n s \le cn s ≤ c n gates of fan-in at most k k k , and outputs o 1 , … , o t o_1,\ldots,o_t o 1 , … , o t with integer weights ω 1 , … , ω t ∈ [ 0 , Ω ] \omega_1,\ldots,\omega_t \in[0,\Omega] ω 1 , … , ω t ∈ [ 0 , Ω ] . The numbers
N i , j = # { x ∈ { 0 , 1 } n : wt ( x ) = i , ∑ l = 1 t ω l o l ( x ) = j } N_{i,j}=\#\left\{x\in\{0,1\}^{n}:\operatorname{wt}(x)=i,\ \sum_{l=1}^{t}\omega_l o_l(x)=j\right\} N i , j = # { x ∈ { 0 , 1 } n : wt ( x ) = i , l = 1 ∑ t ω l o l ( x ) = j }
are computed deterministically, for all ( i , j ) (i,j) ( i , j ) , in time poly ( n , Ω ) 2 O k , c ( ρ ( n ) ) \operatorname{poly}(n,\Omega)2^{O_{k,c}(\rho(n))} poly ( n , Ω ) 2 O k , c ( ρ ( n )) . In particular the number of inputs accepted by a single-output circuit, and the maximum over the inputs of a weighted sum of its output bits with the number of inputs attaining it, are computed in that time.
Proof. Take the n + s n+s n + s Boolean variables x 1 , … , x n , g 1 , … , g s x_1,\ldots,x_n,g_1,\ldots,g_s x 1 , … , x n , g 1 , … , g s and A = A n + 1 , 1 + ∑ l ω l \mathcal{A}=\mathcal{A}_{n+1,1}+\sum_l \omega_l A = A n + 1 , 1 + ∑ l ω l with generators U U U and W W W . For each gate g g g take the multilinear extension, on the scope consisting of g g g and its at most k k k arguments, of the indicator that g g g equals the value of its function at the arguments; for each input 1 + ( U − 1 ) Y x v 1+(U-1)Y_{x_v} 1 + ( U − 1 ) Y x v ; for each output o l o_l o l the factor 1 + ( W ω l − 1 ) Y o l 1+(W^{\omega_l}-1)Y_{o_l} 1 + ( W ω l − 1 ) Y o l . There are s + n + t ≤ ( 2 c + 1 ) n ≤ ( 2 c + 1 ) ( n + s ) s+n+t\le(2c+1)n\le(2c+1)(n+s) s + n + t ≤ ( 2 c + 1 ) n ≤ ( 2 c + 1 ) ( n + s ) factors of scope at most k + 1 k+1 k + 1 , with coefficients of absolute value at most 2 k + 1 2^{k+1} 2 k + 1 . For each input x x x exactly one assignment of the gate variables makes every gate factor 1 1 1 , the one in which each g g g carries its value at x x x , and every other assignment makes some gate factor 0 0 0 ; so the sum over the cube is ∑ x U wt ( x ) W ∑ l ω l o l ( x ) = ∑ i , j N i , j U i W j \sum_x U^{\operatorname{wt}(x)}W^{\sum_l\omega_l o_l(x)}=\sum_{i,j}N_{i,j}U^iW^j ∑ x U wt ( x ) W ∑ l ω l o l ( x ) = ∑ i , j N i , j U i W j with nothing truncated. Theorem 5.3 on n + s ≤ ( c + 1 ) n n+s\le(c+1)n n + s ≤ ( c + 1 ) n variables with the constants k + 1 k+1 k + 1 and 2 c + 1 2c+1 2 c + 1 , and Lemma 5.5 with L = k + 1 L=k+1 L = k + 1 , give the time, since ρ ( n + s ) ≤ ρ ( ( c + 1 ) n ) = O c ( ρ ( n ) ) \rho(n+s)\le\rho((c+1)n)=O_c(\rho(n)) ρ ( n + s ) ≤ ρ (( c + 1 ) n ) = O c ( ρ ( n )) .
Remark 7.16. The count of the accepted inputs of a circuit with s s s gates is, through the Tseitin encoding used in the proof, the count of the satisfying assignments of a ( k + 1 ) (k+1) ( k + 1 ) -CNF formula with n + s n+s n + s variables, so for every s s s it is contained in Theorem 1.1 with the exponent o ( n + s ) o(n+s) o ( n + s ) ; their Corollary 1.4 draws a circuit lower bound from exactly this fact. Theorem 7.15 adds the Hamming weight of the input and the weighted output profile for the sparse case, which turns any objective computable by a linear-size circuit of bounded fan-in on n n n Boolean variables into one that is maximised exactly in time 2 o ( n ) 2^{o(n)} 2 o ( n ) , together with the number of maximisers. Theorems 6.1 , 7.5 and 7.12 are instances, since their constraints are computed by such circuits; the direct encodings given there avoid the gate variables and have smaller constants.
Integer programs with sparse rows
A 0-1 integer program asks for a vector x ∈ { 0 , 1 } n x\in\{0,1\}^n x ∈ { 0 , 1 } n satisfying a system of linear inequalities and maximising a linear objective. Its rows need not be clauses, cuts or parity checks: a row is an arbitrary linear form with integer coefficients, compared with an integer by ≤ \le ≤ , = = = or ≥ \ge ≥ . When every row involves at most k k k variables and there are O ( n ) O(n) O ( n ) of them, each row is a local constraint, and Theorem 7.1 adds a fixed number of dense rows and the objective as linear statistics.
Theorem 7.17 (Sparse integer programs). Fix integers k , c ≥ 1 k,c\ge1 k , c ≥ 1 and s ≥ 0 s\ge0 s ≥ 0 . Consider n ≥ 20 n\ge20 n ≥ 20 variables, m ≤ c n m\le cn m ≤ c n sparse rows
∑ v ∈ I f a f , v x v ⋈ f b f , ∣ I f ∣ ≤ k , ⋈ f ∈ { ≤ , = , ≥ } , a f , v , b f ∈ Z , \sum_{v\in I_f}a_{f,v}x_v\mathrel{\bowtie_f}b_f,\qquad|I_f|\le k,\qquad\bowtie_f\in\{\le,=,\ge\},\qquad a_{f,v},b_f\in\mathbb{Z}, v ∈ I f ∑ a f , v x v ⋈ f b f , ∣ I f ∣ ≤ k , ⋈ f ∈ { ≤ , = , ≥ } , a f , v , b f ∈ Z , with coefficients of arbitrary size, a cost vector γ \gamma γ and dense rows α ( 1 ) , … , α ( s ) ∈ { − Ω , … , Ω } n \alpha^{(1)},\ldots,\alpha^{(s)}\in\{-\Omega,\ldots,\Omega\}^n α ( 1 ) , … , α ( s ) ∈ { − Ω , … , Ω } n , Ω ≥ 1 \Omega\ge1 Ω ≥ 1 , and let P ⊆ { 0 , 1 } n P\subseteq\{0,1\}^n P ⊆ { 0 , 1 } n be the set of vectors satisfying the sparse rows.
(i) The numbers
p ( j 0 , … , j s ) = # { x ∈ P : γ ⋅ x = j 0 , α ( i ) ⋅ x = j i ( 1 ≤ i ≤ s ) } p(j_0,\ldots,j_s)=\#\{x\in P:\gamma\cdot x=j_0,\ \alpha^{(i)}\cdot x=j_i\ (1\le i\le s)\} p ( j 0 , … , j s ) = # { x ∈ P : γ ⋅ x = j 0 , α ( i ) ⋅ x = j i ( 1 ≤ i ≤ s )} are computed for all tuples in time poly ( ℓ , ( 1 + 2 n Ω ) s + 2 ) 2 O k , c , s ( ρ ( n ) ) \operatorname{poly}(\ell,(1+2n\Omega)^{s+2})2^{O_{k,c,s}(\rho(n))} poly ( ℓ , ( 1 + 2 n Ω ) s + 2 ) 2 O k , c , s ( ρ ( n )) , where ℓ \ell ℓ is the bit length of the input. Hence the largest and the smallest value of γ ⋅ x \gamma\cdot x γ ⋅ x over the x ∈ P x\in P x ∈ P with α ( i ) ⋅ x ⋈ i β i \alpha^{(i)}\cdot x\bowtie_i\beta_i α ( i ) ⋅ x ⋈ i β i for prescribed relations ⋈ i \bowtie_i ⋈ i and integers β i \beta_i β i , and the number of vectors attaining each, are computed within the same time.
(ii) For a fixed D ≥ 1 D\ge1 D ≥ 1 the same holds for vectors x ∈ { 0 , 1 , … , D } n x\in\{0,1,\ldots,D\}^n x ∈ { 0 , 1 , … , D } n , with time poly ( ℓ , ( 1 + 4 D n Ω ) s + 2 ) 2 O D , k , c , s ( ρ ( n ) ) \operatorname{poly}(\ell,(1+4Dn\Omega)^{s+2})2^{O_{D,k,c,s}(\rho(n))} poly ( ℓ , ( 1 + 4 D n Ω ) s + 2 ) 2 O D , k , c , s ( ρ ( n )) .
Proof. (i) For each sparse row let ϕ f : { 0 , 1 } I f → { 0 , 1 } \phi_f:\{0,1\}^{I_f}\to\{0,1\} ϕ f : { 0 , 1 } I f → { 0 , 1 } be the indicator that the row holds, and let Φ f \Phi_f Φ f be its multilinear extension (8) . The table of ϕ f \phi_f ϕ f has at most 2 k 2^k 2 k entries, each found by
one evaluation of the row, at a cost of poly(ℓ \ell ℓ ) bit operations; the coefficients of Φ f \Phi_f Φ f are integers of absolute value at most 2 k 2^k 2 k . So ( Φ f ) (\Phi_f) ( Φ f ) is a factor system with at most c n cn c n factors of scope at most k k k and values in Q \mathbb{Q} Q , and its product at x ∈ { 0 , 1 } n x \in\{0,1\}^n x ∈ { 0 , 1 } n is the indicator of P P P . To bring the statistics to nonnegative weights, put ω v ( 0 ) = γ v + Ω \omega_v^{(0)}=\gamma_v+\Omega ω v ( 0 ) = γ v + Ω , ω v ( i ) = α v ( i ) + Ω \omega_v^{(i)}=\alpha_v^{(i)}+\Omega ω v ( i ) = α v ( i ) + Ω for 1 ≤ i ≤ s 1\leq i\leq s 1 ≤ i ≤ s , and ω v ( s + 1 ) = 1 \omega_v^{(s+1)}=1 ω v ( s + 1 ) = 1 , all in [ 0 , 2 Ω ] [0,2\Omega] [ 0 , 2Ω ] . For every x x x ,
γ ⋅ x = ω ( 0 ) ⋅ x − Ω ∣ x ∣ , α ( i ) ⋅ x = ω ( i ) ⋅ x − Ω ∣ x ∣ , ∣ x ∣ = ω ( s + 1 ) ⋅ x . \gamma\cdot x=\omega^{(0)}\cdot x-\Omega|x|,\qquad\alpha^{(i)}\cdot x=\omega^{(i)}\cdot x-\Omega|x|,\qquad|x|=\omega^{(s+1)}\cdot x. γ ⋅ x = ω ( 0 ) ⋅ x − Ω∣ x ∣ , α ( i ) ⋅ x = ω ( i ) ⋅ x − Ω∣ x ∣ , ∣ x ∣ = ω ( s + 1 ) ⋅ x .
Theorem 7.1 (i) with N 0 = 1 N_0=1 N 0 = 1 , the s + 2 s+2 s + 2 weight vectors ω ( 0 ) , … , ω ( s + 1 ) \omega^{(0)},\ldots,\omega^{(s+1)} ω ( 0 ) , … , ω ( s + 1 ) and the weight bound 2 Ω 2\Omega 2Ω computes the numbers r ( j 0 ′ , … , j s + 1 ′ ) r(j'_0,\ldots,j'_{s+1}) r ( j 0 ′ , … , j s + 1 ′ ) of x ∈ P x\in P x ∈ P with ω ( i ) ⋅ x = j i ′ \omega^{(i)}\cdot x=j'_i ω ( i ) ⋅ x = j i ′ for all i i i , in time poly ( n , ( 1 + 2 n Ω ) s + 2 ) 2 O k , c , s ( ρ ( n ) ) \operatorname{poly}(n,(1+2n\Omega)^{s+2})2^{O_{k,c,s}(\rho(n))} poly ( n , ( 1 + 2 n Ω ) s + 2 ) 2 O k , c , s ( ρ ( n )) , to which the cost c n 2 k poly ( ℓ ) cn2^k\operatorname{poly}(\ell) c n 2 k poly ( ℓ ) of the tables is added. Then
p ( j 0 , … , j s ) = ∑ t = 0 n r ( j 0 + Ω t , j 1 + Ω t , … , j s + Ω t , t ) , p(j_0,\ldots,j_s)=\sum_{t=0}^{n}r(j_0+\Omega t,j_1+\Omega t,\ldots,j_s+\Omega t,t), p ( j 0 , … , j s ) = t = 0 ∑ n r ( j 0 + Ω t , j 1 + Ω t , … , j s + Ω t , t ) ,
because a vector with ∣ x ∣ = t |x|=t ∣ x ∣ = t has ω ( i ) ⋅ x = α ( i ) ⋅ x + Ω t \omega^{(i)}\cdot x=\alpha^{(i)}\cdot x+\Omega t ω ( i ) ⋅ x = α ( i ) ⋅ x + Ω t . The optimum over the x ∈ P x\in P x ∈ P with α ( i ) ⋅ x ⊴ i β i \alpha^{(i)}\cdot x\mathrel{\trianglelefteq_i}\beta_i α ( i ) ⋅ x ⊴ i β i is the largest, or smallest, j 0 j_0 j 0 for which ∑ p ( j 0 , j 1 , … , j s ) > 0 \sum p(j_0,j_1,\ldots,j_s)>0 ∑ p ( j 0 , j 1 , … , j s ) > 0 , the sum taken over the tuples with j i ⊴ i β i j_i\mathrel{\trianglelefteq_i}\beta_i j i ⊴ i β i , and that sum counts the optimal vectors.
(ii) Let T = ⌈ log 2 ( D + 1 ) ⌉ T=\lceil\log_2(D+1)\rceil T = ⌈ log 2 ( D + 1 )⌉ and replace each x v x_v x v by T T T Boolean variables x v , 0 , … , x v , T − 1 x_{v,0},\ldots,x_{v,T-1} x v , 0 , … , x v , T − 1 with
x v = ∑ t 2 t x v , t . x_v=\sum_t 2^t x_{v,t}. x v = t ∑ 2 t x v , t .
A sparse row becomes a sparse row in the new variables, with the coefficients 2 t a f , v 2^t a_{f,v} 2 t a f , v and at most k T kT k T variables; add for each v v v the row ∑ t 2 t x v , t ≤ D \sum_t2^t x_{v,t}\leq D ∑ t 2 t x v , t ≤ D , which involves T T T variables. The cost and the dense rows become vectors with entries 2 t γ v 2^t\gamma_v 2 t γ v and 2 t α v ( i ) 2^t\alpha_v^{(i)} 2 t α v ( i ) , of absolute value at most 2 T Ω ≤ 2 ( D + 1 ) Ω ≤ 4 D Ω 2^T\Omega\leq2(D+1)\Omega\leq4D\Omega 2 T Ω ≤ 2 ( D + 1 ) Ω ≤ 4 D Ω . The new program has n ′ = T n n'=Tn n ′ = T n variables and at most ( c + 1 ) n ≤ ( c + 1 ) n ′ (c+1)n\leq(c+1)n' ( c + 1 ) n ≤ ( c + 1 ) n ′ sparse rows of at most k T kT k T variables, and its feasible vectors correspond bijectively to the vectors of { 0 , … , D } n \{0,\ldots,D\}^n { 0 , … , D } n satisfying the original sparse rows, with the same values of γ ⋅ x \gamma\cdot x γ ⋅ x and α ( i ) ⋅ x \alpha^{(i)}\cdot x α ( i ) ⋅ x . Part (i) applies, with ρ ( T n ) ≤ 4 T ρ ( n ) \rho(Tn)\leq4T\rho(n) ρ ( T n ) ≤ 4 T ρ ( n ) for n ≥ T n\geq T n ≥ T . □
The theorem places no bound on the coefficients of the sparse rows, only on their number of variables; the polynomial bound Ω \Omega Ω is needed only for the objective and the dense rows, which enter through the exponents of the generators. Three classical problems that are NP-hard in the strong sense fall under it.
Corollary 7.18. Fix k , c , s ≥ 1 k,c,s\geq1 k , c , s ≥ 1 . Each of the following is computed deterministically in time poly ( ℓ , Ω s + 2 ) 2 O ( ρ ( n ) ) \operatorname{poly}(\ell,\Omega^{s+2})2^{O(\rho(n))} poly ( ℓ , Ω s + 2 ) 2 O ( ρ ( n )) , where ℓ \ell ℓ is the length of the input, together with the number of optimal solutions, the implied constant depending on k , c , s k,c,s k , c , s .
(a) For n n n sets over a universe of at most c n cn c n elements, each element lying in at most k k k of the sets, with costs in [ 0 , Ω ] [0,\Omega] [ 0 , Ω ] : the least cost of an exact cover, of a set cover and the largest cost of a set packing. Exact cover by 3-sets is NP-complete already when every element lies in exactly three sets [17 ] .
(b) For n n n items with values and s s s weight vectors in [ 0 , Ω ] [0,\Omega] [ 0 , Ω ] , capacities B 1 , … , B s B_1,\ldots,B_s B 1 , … , B s and a partial order given by at most c n cn c n relations u ≺ v u\prec v u ≺ v : the largest value of a set of items within the capacities that contains, with each item, every item below it. For s = 1 s=1 s = 1 this is the partially ordered knapsack problem, which is NP-complete in the strong sense [22 ] .
(c) For a system of at most c n cn c n linear equations ∑ v ∈ I f a f , v x v = b f \sum_{v\in I_f}a_{f,v}x_v=b_f ∑ v ∈ I f a f , v x v = b f with integer coefficients, ∣ I f ∣ ≤ k |I_f|\leq k ∣ I f ∣ ≤ k , and a cost vector in [ − Ω , Ω ] n [-\Omega,\Omega]^n [ − Ω , Ω ] n : the number of its 0-1 solutions of each cost, and the least and largest cost; in particular the number of solutions of a 1-in-k k k -SAT instance with at most c n cn c n clauses, and its solutions with the fewest true variables.
Proof. (a) Take a variable for each set and, for each element, the row ∑ S ∋ e x S = 1 \sum_{S\ni e}x_S=1 ∑ S ∋ e x S = 1 , ≥ 1 \geq1 ≥ 1 or ≤ 1 \leq1 ≤ 1 ; each row involves at most k k k variables, and there are at most c n cn c n rows. The cost is γ \gamma γ , with $s=0.
(b) Take a variable for each item, the row x v − x u ≤ 0 x_v-x_u\leq0 x v − x u ≤ 0 , which says that x v = 1 x_v=1 x v = 1 forces $x_u=1, for each relation u ≺ v u \prec v u ≺ v , and the weight vectors as dense rows with β i = B i \beta_i = B_i β i = B i and ◃ i \triangleleft_i ◃ i the relation ≤ \leq ≤ ; the downward closure of the chosen set under the given relations is equivalent to its closure under the order they generate. (c) The equations are the sparse rows; for 1-in-k k k -SAT a clause on the literals ℓ 1 , … , ℓ k \ell_1,\ldots,\ell_k ℓ 1 , … , ℓ k is the equation ∑ i ℓ i = 1 \sum_i \ell_i = 1 ∑ i ℓ i = 1 , where a negated literal 1 − x v 1-x_v 1 − x v moves the constant 1 to the right side. All three are Theorem 7.17 (i). □ \square □
Growing density
Every statement so far fixes the ratio c c c of factors to variables. The parameters of Lemma 4.7 do not depend on the degree ratio κ \kappa κ , and the exponent of Theorem 5.1 is linear in it. When κ \kappa κ grows with n n n it pays to let the parameters follow it: fewer groups, and so a smaller Q / R Q/R Q / R in the Taylor count, in exchange for a larger share of the cost spent on one group. With the entropy bound of Lemma 3.4 in place of (31) , this extends the subexponential regime to every ratio κ = o ( log n / log log n ) \kappa=o\left(\sqrt{\log n/\log\log n}\right) κ = o ( log n / log log n ) .
Throughout, λ = ⌈ log n ⌉ \lambda=\lceil\log n\rceil λ = ⌈ log n ⌉ , ν = ⌈ log λ ⌉ \nu=\lceil\log\lambda\rceil ν = ⌈ log λ ⌉ , and
g ( x ) = x ( log ( 1 / x ) ) 3 / 2 , ( 0 < x < 1 ) , g(x)=x\left(\log(1/x)\right)^{3/2}, \qquad(0<x<1), g ( x ) = x ( log ( 1/ x ) ) 3/2 , ( 0 < x < 1 ) ,
which is increasing on ( 0 , 2 − 3 ] (0,2^{-3}] ( 0 , 2 − 3 ] and tends to 0 with x x x .
Theorem 7.19 (Bounded occurrences at a growing degree ratio). There is an absolute constant λ 0 \lambda_0 λ 0 with the following property. Let A \mathcal{A} A be a commutative Q \mathbb{Q} Q -algebra, and let a factor system on n n n variables with λ ≥ λ 0 \lambda\geq\lambda_0 λ ≥ λ 0 have largest scope w ≤ λ 2 w\leq\lambda^2 w ≤ λ 2 , largest occurrence number b ≤ λ 2 − 1 b\leq\lambda^2-1 b ≤ λ 2 − 1 and total degree d ≤ a n d\leq an d ≤ an , where a ≥ 1 a\geq1 a ≥ 1 is a real number with
θ : = a ν / λ ≤ 2 − 15 . \theta:=a\sqrt{\nu/\lambda}\leq2^{-15}. θ := a ν / λ ≤ 2 − 15 . Then Z Z Z in (6) is computed deterministically with at most
∣ F ∣ poly ( n ) 2 790 n g ( θ ) (68) |\mathcal{F}|\,\operatorname{poly}(n)\,2^{790n g(\theta)} \tag*{(68)} ∣ F ∣ poly ( n ) 2 790 n g ( θ ) (68) operations in A \mathcal{A} A , evaluations of factors at inputs in Q [ z ] / ( z J ) \mathbb{Q}[z]/(z^J) Q [ z ] / ( z J ) with J ≤ n J\leq n J ≤ n , and bit operations on rational numbers, using polynomially many elements of A \mathcal{A} A and polynomially many bits of storage in addition to the factors’ own. The polynomial is absolute.
Proof. Adjoin the constant-one factors of Section 4, so that (33) holds with b ≤ λ 2 b\leq\lambda^2 b ≤ λ 2 and d d d unchanged. Replacing a a a by max ( 1 , d / n ) \max(1,d/n) max ( 1 , d / n ) , which is rational, computed from the input and not larger than a a a , decreases θ \theta θ and, as g g g is increasing, the bound (68) ; so we may assume a = max ( 1 , d / n ) a=\max(1,d/n) a = max ( 1 , d / n ) . Put L = log ( 1 / θ ) ≥ 15 L=\log(1/\theta)\geq15 L = log ( 1/ θ ) ≥ 15 and choose
t = ⌊ L ⌋ , r = 2 t , Q = ⌊ λ 128 t ⌋ , R = 32 + ⌈ 16 Q ν ⌉ , τ = 1 r λ , D = r 2 Q . t=\lfloor L\rfloor,\qquad r=2^t,\qquad Q=\left\lfloor\frac{\lambda}{128t}\right\rfloor,\qquad R=32+\left\lceil16\sqrt{Q\nu}\right\rceil,\qquad\tau=\frac{1}{r\lambda},\qquad D=r^{2Q}. t = ⌊ L ⌋ , r = 2 t , Q = ⌊ 128 t λ ⌋ , R = 32 + ⌈ 16 Q ν ⌉ , τ = r λ 1 , D = r 2 Q .
Thus t t t is the largest integer with 4 t a 2 ν ≤ λ 4^t a^2\nu\leq\lambda 4 t a 2 ν ≤ λ , and 1 / ( 2 θ ) < r ≤ 1 / θ 1/(2\theta)<r\leq1/\theta 1/ ( 2 θ ) < r ≤ 1/ θ . Since a ≥ 1 a\geq1 a ≥ 1 and λ ≤ 2 ν \lambda\leq2^\nu λ ≤ 2 ν , L ≤ 1 2 log ( λ / ν ) ≤ ν / 2 L\leq\frac12\log(\lambda/\nu)\leq\nu/2 L ≤ 2 1 log ( λ / ν ) ≤ ν /2 , so t ≤ ν / 2 t\leq\nu/2 t ≤ ν /2 and r 2 ≤ 2 ν ≤ 2 λ r^2\leq2^\nu\leq2\lambda r 2 ≤ 2 ν ≤ 2 λ .
We check the hypotheses of Lemma 4.6. First, λ ≥ 256 t \lambda\geq256t λ ≥ 256 t , so Q ≥ λ / ( 256 t ) Q\geq\lambda/(256t) Q ≥ λ / ( 256 t ) , and log D = 2 Q t ≤ λ / 64 \log D=2Qt\leq\lambda/64 log D = 2 Qt ≤ λ /64 . Since Q ν ≥ 1 Q\nu\geq1 Q ν ≥ 1 , R ≤ 33 + 16 Q ν ≤ 49 Q ν R\leq33+16\sqrt{Q\nu}\leq49\sqrt{Q\nu} R ≤ 33 + 16 Q ν ≤ 49 Q ν , hence
R Q ≤ 49 ν Q ≤ 784 t ν λ ≤ 784 ν 2 λ , (69) \frac{R}{Q}\leq49\sqrt{\frac{\nu}{Q}}\leq784\sqrt{\frac{t\nu}{\lambda}}\leq784\frac{\nu}{\sqrt{2\lambda}}, \tag*{(69)} Q R ≤ 49 Q ν ≤ 784 λ t ν ≤ 784 2 λ ν , (69)
which is at most 1 / 6 1/6 1/6 once λ ≥ ( 6 ⋅ 784 ) 2 ν 2 / 2 \lambda\geq(6\cdot784)^2\nu^2/2 λ ≥ ( 6 ⋅ 784 ) 2 ν 2 /2 ; so R ≥ 32 R\geq32 R ≥ 32 , 6 R ≤ Q 6R\leq Q 6 R ≤ Q and R < Q R<Q R < Q for λ ≥ λ 0 \lambda\geq\lambda_0 λ ≥ λ 0 . The balance conditions (47) hold: 2 ( b + w ) D 2 ≤ 4 λ 2 2 λ / 32 ≤ 2 λ − 1 < n ≤ M 2(b+w)D^2\leq4\lambda^2 2^{\lambda/32}\leq2^{\lambda-1}<n\leq M 2 ( b + w ) D 2 ≤ 4 λ 2 2 λ /32 ≤ 2 λ − 1 < n ≤ M and 2 Q r 2 ≤ ( λ / 64 t ) ⋅ 2 λ < n 2Qr^2\leq(\lambda/64t)\cdot2\lambda<n 2 Q r 2 ≤ ( λ /64 t ) ⋅ 2 λ < n for λ ≥ λ 0 \lambda\geq\lambda_0 λ ≥ λ 0 . For the interval take μ = Q ( r − 1 ) / ( 2 r ) \mu=Q(r-1)/(2r) μ = Q ( r − 1 ) / ( 2 r ) , A 0 = ⌊ μ − ( R − 1 ) / 2 ⌋ A_0=\lfloor\mu-(R-1)/2\rfloor A 0 = ⌊ μ − ( R − 1 ) /2 ⌋ and J = { A 0 , … , A 0 + R − 1 } \mathcal{J}=\{A_0,\ldots,A_0+R-1\} J = { A 0 , … , A 0 + R − 1 } as in the proof of Lemma 4.7 ; since R ≤ Q / 6 R\leq Q/6 R ≤ Q /6 it lies in { 0 , … , Q } \{0,\ldots,Q\} { 0 , … , Q } , and since R ≥ 32 R \ge32 R ≥ 32 it contains every integer within R / 4 R/4 R /4 of μ \mu μ . Hoeffding’s inequality (10) with s = R / 4 s = R/4 s = R /4 and R 2 ≥ 256 Q ν R^2 \ge256Q\nu R 2 ≥ 256 Q ν gives
Pr [ Bin ( Q , r − 1 2 r ) ∉ J ] ≤ 2 e − R 2 / ( 8 Q ) ≤ 2 e − 32 ν ≤ 2 − 4 ν ≤ 1 r 2 b λ = τ r b , \Pr\left[\operatorname{Bin}\left(Q,\frac{r-1}{2r}\right)\notin J\right]\le2e^{-R^2/(8Q)}\le2e^{-32\nu}\le2^{-4\nu}\le\frac{1}{r^2b\lambda}=\frac{\tau}{rb}, Pr [ Bin ( Q , 2 r r − 1 ) ∈ / J ] ≤ 2 e − R 2 / ( 8 Q ) ≤ 2 e − 32 ν ≤ 2 − 4 ν ≤ r 2 bλ 1 = r b τ ,
because r 2 ≤ 2 ν r^2 \le2^\nu r 2 ≤ 2 ν , b ≤ λ 2 ≤ 2 2 ν b \le\lambda^2 \le2^{2\nu} b ≤ λ 2 ≤ 2 2 ν and λ ≤ 2 ν \lambda\le2^\nu λ ≤ 2 ν . This is (52) , and 0 < τ ≤ 1 / 2 0 < \tau\le1/2 0 < τ ≤ 1/2 . Lemma 4.6 constructs the design in polynomial time.
Now the costs of Proposition 3.5. By (11) with d ≤ a n d \le an d ≤ an , q = ⌊ d R / Q ⌋ ≤ χ n q = \lfloor dR/Q\rfloor\le\chi n q = ⌊ d R / Q ⌋ ≤ χ n with χ = a R / Q \chi= aR/Q χ = a R / Q . Since ν / λ = θ / a ≤ θ \sqrt{\nu/\lambda} = \theta/a \le\theta ν / λ = θ / a ≤ θ and t ≤ L t \le L t ≤ L , (69) gives
χ ≤ 784 a t ν λ ≤ 784 θ L = : χ ˉ , \chi\le784a\sqrt{\frac{t\nu}{\lambda}}\le784\theta\sqrt{L}=:\bar{\chi}, χ ≤ 784 a λ t ν ≤ 784 θ L =: χ ˉ ,
and χ ˉ ≤ 784 ⋅ 2 − 15 15 < 1 10 \bar{\chi} \le784\cdot2^{-15}\sqrt{15}<\frac{1}{10} χ ˉ ≤ 784 ⋅ 2 − 15 15 < 10 1 because x log ( 1 / x ) x\sqrt{\log(1/x)} x log ( 1/ x ) increases on ( 0 , 2 − 15 ] (0,2^{-15}] ( 0 , 2 − 15 ] . In particular q ≤ n / 2 q \le n/2 q ≤ n /2 and J = q + 1 ≤ n J=q+1\le n J = q + 1 ≤ n . Lemma 3.4 and the monotonicity of x log ( 2 e n / x ) x\log(2en/x) x log ( 2 e n / x ) in x ≤ n x\le n x ≤ n give
log C q ≤ χ ˉ n log 2 e χ ˉ = 784 θ L n ( L + log 2 e 784 L ) ≤ 784 n θ L 3 / 2 = 784 n g ( θ ) . \log C_q\le\bar{\chi}n\log\frac{2e}{\bar{\chi}}=784\theta\sqrt{L}n\left(L+\log\frac{2e}{784\sqrt{L}}\right)\le784n\theta L^{3/2}=784ng(\theta). log C q ≤ χ ˉ n log χ ˉ 2 e = 784 θ L n ( L + log 784 L 2 e ) ≤ 784 n θ L 3/2 = 784 n g ( θ ) .
The measurement count contributes 2 τ n log ( 2 D + 1 ) ≤ 2 n r ( λ 4 + 2 ) ≤ n r 2\tau n\log(2D+1)\le\frac{2n}{r}\left(\frac{\lambda}{4}+2\right)\le\frac{n}{r} 2 τ n log ( 2 D + 1 ) ≤ r 2 n ( 4 λ + 2 ) ≤ r n and one group 2 n r \frac{2n}{r} r 2 n , together 3 n r < 6 n θ ≤ 6 n g ( θ ) \frac{3n}{r}<6n\theta\le6ng(\theta) r 3 n < 6 n θ ≤ 6 n g ( θ ) . The logarithm of (30) is therefore at most log ( 2 Q r ) + 790 n g ( θ ) \log(2Qr)+790ng(\theta) log ( 2 Q r ) + 790 n g ( θ ) .
Each vector costs at most ∣ F ∣ |\mathcal{F}| ∣ F ∣ factor evaluations and a number of further operations polynomial in n n n , ∣ F ∣ |\mathcal{F}| ∣ F ∣ , D D D , Q Q Q , R R R , J J J , r r r and M ≤ λ 2 n M\le\lambda^2n M ≤ λ 2 n , all of which are bounded by powers of n n n and ∣ F ∣ |\mathcal{F}| ∣ F ∣ since D ≤ 2 λ / 64 ≤ 2 n 1 / 64 D\le2^{\lambda/64}\le2^{n^{1/64}} D ≤ 2 λ /64 ≤ 2 n 1/64 . The storage bound is that of Proposition 3.5.
The parameters are computed from n n n and d d d with integer square roots and exact rational comparisons, in poly ( log n , log d ) \operatorname{poly}(\log n,\log d) poly ( log n , log d ) bit operations, and the conditions of Lemma 4.6 are checked exactly as in the proof of Lemma 4.7; the estimates above show that every check passes. □
For a fixed ratio a a a one has θ = a ν / λ \theta=a\sqrt{\nu/\lambda} θ = a ν / λ and log ( 1 / θ ) ≤ ν / 2 \log(1/\theta)\le\nu/2 log ( 1/ θ ) ≤ ν /2 , so g ( θ ) ≤ a ν 2 / ( 2 2 λ ) g(\theta)\le a\nu^2/(2\sqrt{2\lambda}) g ( θ ) ≤ a ν 2 / ( 2 2 λ ) , and (68) is the bound of Theorem 5.1 with β = 2 \beta=2 β = 2 up to the constant. The gain is in the dependence on a a a : the exponent of Theorem 5.1 is a n ν 2 / λ an\nu^2/\sqrt{\lambda} an ν 2 / λ , which is o ( n ) o(n) o ( n ) only for a = o ( λ / ν 2 ) a=o(\sqrt{\lambda}/\nu^2) a = o ( λ / ν 2 ) , while n g ( θ ) ng(\theta) n g ( θ ) is o ( n ) o(n) o ( n ) for every a = o ( λ / ν ) a=o(\sqrt{\lambda}/\nu) a = o ( λ / ν ) . Two changes produce the gain. The entropy bound (29) charges the Taylor count log C q ≈ q log ( n / q ) \log C_q\approx q\log(n/q) log C q ≈ q log ( n / q ) , whereas (31) charges q log ( Q / R ) q\log(Q/R) q log ( Q / R ) , larger by the factor log ( Q / R ) / log ( Q / ( a R ) ) \log(Q/R)/\log(Q/(aR)) log ( Q / R ) / log ( Q / ( a R )) , which grows with a a a . And the number of groups r = 2 ⌊ log ( 1 / θ ) ⌋ r=2^{\lfloor\log(1/\theta)\rfloor} r = 2 ⌊ l o g ( 1/ θ )⌋ shrinks as a a a grows, which makes Q Q Q larger and R / Q R/Q R / Q smaller at the price of the cost 3 n / r 3n/r 3 n / r of the groups, balanced against the Taylor count.
Theorem 7.20 (Growing density). There are absolute constants n 1 n_1 n 1 and θ 1 > 0 \theta_1>0 θ 1 > 0 with the following property. Let n ≥ n 1 n\ge n_1 n ≥ n 1 , let k ≥ 1 k\ge1 k ≥ 1 be an integer and c ≥ 1 c\ge1 c ≥ 1 a real number with
θ n : = c k log log n log n ≤ θ 1 , \theta_n:=ck\sqrt{\frac{\log\log n}{\log n}}\le\theta_1, θ n := c k log n log log n ≤ θ 1 , and let a factor system on n n n variables have at most c n cn c n factors, each of scope at most k k k , with values in a commutative Q \mathbb{Q} Q -algebra A A A . Then Z Z Z in (6) is computed deterministically with at most
poly ( n ) 2 4800 n g ( θ n ) ≤ poly ( n ) 2 1700 c k ρ ( n ) \operatorname{poly}(n)2^{4800n g(\theta_n)}\le\operatorname{poly}(n)2^{1700ck\rho(n)} poly ( n ) 2 4800 n g ( θ n ) ≤ poly ( n ) 2 1700 c k ρ ( n ) operations in A A A , evaluations of the factors at inputs in Q [ z ] / ( z J ) \mathbb{Q}[z]/(z^J) Q [ z ] / ( z J ) , J ≤ n J\le n J ≤ n , and bit operations on rationals, in polynomial space; the polynomial is absolute. In particular the bound is 2 o ( n ) 2^{o(n)} 2 o ( n ) whenever c k = o ( log n / log log n ) ck=o\left(\sqrt{\log n/\log\log n}\right) c k = o ( log n / log log n ) . If the coefficients of the factors are polynomials in the generators of A = A N A=A_N A = A N or A N 1 , … , N s A_{N_1,\ldots,N_s} A N 1 , … , N s with integer coefficients of at most L L L bits, the bound holds for bit operations after multiplication by a polynomial in n n n , N N N and L L L .
Proof. Put θ 1 = 2 − 18 \theta_1=2^{-18} θ 1 = 2 − 18 and ε n = log log n / log n \varepsilon_n=\sqrt{\log\log n/\log n} ε n = log log n / log n , so that θ n = c k ε n ≥ ε n \theta_n=ck\varepsilon_n\ge\varepsilon_n θ n = c k ε n ≥ ε n . Let n 1 n_1 n 1 be so large that for n ≥ n 1 n\ge n_1 n ≥ n 1 one has λ − 1 ≥ λ 0 \lambda-1\ge\lambda_0 λ − 1 ≥ λ 0 , the absolute constant of Theorem 7.19 , and θ 1 log n / log log n ≤ λ / 2 \theta_1\sqrt{\log n/\log\log n}\le\lambda/2 θ 1 log n / log log n ≤ λ /2 , so that c k ≤ λ / 2 ck\le\lambda/2 c k ≤ λ /2 . Apply Lemma 5.2 : fewer than 2 n / λ 2^{n/\lambda} 2 n / λ assignments y y y , each leaving a system on n ′ ≥ n − n / λ ≥ n / 2 n'\ge n-n/\lambda\ge n/2 n ′ ≥ n − n / λ ≥ n /2 variables with λ ′ = ⌈ log n ′ ⌉ ∈ { λ − 1 , λ } \lambda'=\lceil\log n'\rceil\in\{\lambda-1,\lambda\} λ ′ = ⌈ log n ′ ⌉ ∈ { λ − 1 , λ } , ν ′ ≤ ν \nu'\le\nu ν ′ ≤ ν , scopes at most k ≤ λ 2 k\le\lambda^2 k ≤ λ 2 , occurrence numbers at most c k λ ≤ λ 2 / 2 ≤ λ ′ 2 − 1 ck\lambda\le\lambda^2/2\le\lambda'^2-1 c k λ ≤ λ 2 /2 ≤ λ ′2 − 1 , and total degree at most k c n ≤ 2 c k n ′ kcn\le2ckn' k c n ≤ 2 c k n ′ . Theorem 7.19 applies with a = 2 c k a=2ck a = 2 c k and
θ ′ = 2 c k ν ′ / λ ′ ≤ 2 c k 2 ν / λ ≤ 6 c k ε n = 6 θ n ≤ 2 − 15 , \theta'=2ck\sqrt{\nu'/\lambda'}\le2ck\sqrt{2\nu/\lambda}\le6ck\varepsilon_n=6\theta_n\le2^{-15}, θ ′ = 2 c k ν ′ / λ ′ ≤ 2 c k 2 ν / λ ≤ 6 c k ε n = 6 θ n ≤ 2 − 15 ,
where ν ≤ log log n + 2 ≤ 3 log log n \nu\le\log\log n+2\le3\log\log n ν ≤ log log n + 2 ≤ 3 log log n and λ ≥ log n \lambda\ge\log n λ ≥ log n were used for n ≥ 20 n\ge20 n ≥ 20 . As g g g is increasing on ( 0 , 2 − 3 ] (0,2^{-3}] ( 0 , 2 − 3 ] , g ( θ ′ ) ≤ g ( 6 θ n ) ≤ 6 θ n log 3 / 2 ( 1 / θ n ) = 6 g ( θ n ) g(\theta')\le g(6\theta_n)\le6\theta_n\log^{3/2}(1/\theta_n)=6g(\theta_n) g ( θ ′ ) ≤ g ( 6 θ n ) ≤ 6 θ n log 3/2 ( 1/ θ n ) = 6 g ( θ n ) . Each Z y Z_y Z y costs at most c n poly ( n ) 2 4740 n g ( θ n ) cn\operatorname{poly}(n)2^{4740ng(\theta_n)} c n poly ( n ) 2 4740 n g ( θ n ) operations, and c n ≤ n 2 cn\le n^2 c n ≤ n 2 . The branching adds the factor 2 n / λ ≤ 2 n ε n ≤ 2 n g ( θ n ) 2^{n/\lambda}\le2^{n\varepsilon_n}\le2^{ng(\theta_n)} 2 n / λ ≤ 2 n ε n ≤ 2 n g ( θ n ) , since 1 / λ ≤ 1 / log n ≤ ε n ≤ θ n 1/\lambda\le1/\log n\le\varepsilon_n\le\theta_n 1/ λ ≤ 1/ log n ≤ ε n ≤ θ n and log ( 1 / θ n ) ≥ 18 \log(1/\theta_n)\ge18 log ( 1/ θ n ) ≥ 18 . The total is at most poly ( n ) 2 4741 n g ( θ n ) \operatorname{poly}(n)2^{4741ng(\theta_n)} poly ( n ) 2 4741 n g ( θ n ) , which gives the first bound. For the second, log ( 1 / θ n ) ≤ log ( 1 / ε n ) ≤ 1 2 log log n \log(1/\theta_n)\le\log(1/\varepsilon_n)\le\frac12\log\log n log ( 1/ θ n ) ≤ log ( 1/ ε n ) ≤ 2 1 log log n , so g ( θ n ) ≤ c k ε n ( log log n ) 3 / 2 / 2 3 / 2 = c k ρ ( n ) / ( 2 3 / 2 n ) g(\theta_n)\le ck\varepsilon_n(\log\log n)^{3/2}/2^{3/2}=ck\rho(n)/(2^{3/2}n) g ( θ n ) ≤ c k ε n ( log log n ) 3/2 / 2 3/2 = c k ρ ( n ) / ( 2 3/2 n ) , and 4800 / 2 3 / 2 < 1700 4800/2^{3/2}<1700 4800/ 2 3/2 < 1700 . If c k = o ( log n / log log n ) ck=o(\sqrt{\log n/\log\log n}) c k = o ( log n / log log n ) then θ n → 0 \theta_n\to0 θ n → 0 and g ( θ n ) → 0 g(\theta_n)\to0 g ( θ n ) → 0 . The space bound and J ≤ n ′ ≤ n J\le n'\le n J ≤ n ′ ≤ n come from Theorem 7.19 , and the bit complexity is Lemma 5.5 : its proof uses of the parameters only Q , λ = O ( log n ) Q,\lambda=O(\log n) Q , λ = O ( log n ) , R < Q R<Q R < Q and D ≤ 2 λ D\le2^\lambda D ≤ 2 λ , which hold here, and its polynomial depends on ∣ F ∣ ≤ n 2 |\mathcal{F}|\le n^2 ∣ F ∣ ≤ n 2 and k ≤ λ 2 k\le\lambda^2 k ≤ λ 2 only through powers of n n n . □
The corollaries of Sections 6 and § 7 that are proved by one application of Theorem 5.3 to a factor system whose number of factors is bounded by the number of constraints or edges of the input, and whose scopes are bounded, therefore extend to inputs of growing density. For a function d ( n ) ≥ 1 d(n)\ge1 d ( n ) ≥ 1 write
δ n = d ( n ) log log n log n . \delta_n=d(n)\sqrt{\frac{\log\log n}{\log n}}. δ n = d ( n ) log n log log n .
the condition δ n → 0 \delta_n\to0 δ n → 0 means d ( n ) = o ( log n / log log n ) d(n)=o(\sqrt{\log n/\log\log n}) d ( n ) = o ( log n / log log n ) . We record the two for which the question of the dense case was raised in the introduction.
Corollary 7.21 (Cuts and spin systems at growing average degree). Let d = d ( n ) ≥ 1 d=d(n)\ge1 d = d ( n ) ≥ 1 satisfy δ n → 0 \delta_n\to0 δ n → 0 , and let G G G be a graph with n n n vertices and at most d ( n ) n d(n)n d ( n ) n edges.
(i) The cut profile ( # { S ⊆ V : ∣ S ∣ = i , e ( S , V ∖ S ) = j } ) i , j (\#\{S\subseteq V:|S|=i,\ e(S,V\setminus S)=j\})_{i,j} ( # { S ⊆ V : ∣ S ∣ = i , e ( S , V ∖ S ) = j } ) i , j , in particular the maximum cut, the maximum bisection and their numbers of optimal solutions, is computed in time poly ( n ) 2 20000 n g ( δ n ) = 2 o ( n ) \operatorname{poly}(n)2^{20000ng(\delta_n)}=2^{o(n)} poly ( n ) 2 20000 n g ( δ n ) = 2 o ( n ) .
(ii) The density of states of an Ising system on G G G with integer couplings and fields, and that of the q q q -state Potts system on G G G for fixed q q q , are computed in time poly ( n , E max ) 2 O q ( n g ( δ n ) ) = poly ( E max ) 2 o ( n ) \operatorname{poly}(n,E_{\max})2^{O_q(ng(\delta_n))}=\operatorname{poly}(E_{\max})2^{o(n)} poly ( n , E m a x ) 2 O q ( n g ( δ n )) = poly ( E m a x ) 2 o ( n ) .
In particular the maximum cut and the ground-state energy of an Ising system on a graph of average degree d ( n ) d(n) d ( n ) are found in time 2 o ( n ) 2^{o(n)} 2 o ( n ) whenever d ( n ) = o ( log n / log log n ) d(n)=o(\sqrt{\log n/\log\log n}) d ( n ) = o ( log n / log log n ) .
Proof. (i) The factor system of Corollary 6.4 has one factor of scope 2 per edge and one of scope 1 per vertex, with values in A n + 1 , m + 1 \mathcal{A}_{n+1,m+1} A n + 1 , m + 1 and coefficients of absolute value at most 2; so it has at most ( d ( n ) + 1 ) n ≤ 2 d ( n ) n (d(n)+1)n\le2d(n)n ( d ( n ) + 1 ) n ≤ 2 d ( n ) n factors of scope at most 2. Theorem 7.20 with k = 2 k=2 k = 2 and c = 2 d ( n ) c=2d(n) c = 2 d ( n ) applies once 4 δ n ≤ θ 1 4\delta_n\le\theta_1 4 δ n ≤ θ 1 , and gives poly ( n ) 2 4800 n g ( 4 δ n ) \operatorname{poly}(n)2^{4800ng(4\delta_n)} poly ( n ) 2 4800 n g ( 4 δ n ) operations; g ( 4 δ n ) ≤ 4 g ( δ n ) g(4\delta_n)\le4g(\delta_n) g ( 4 δ n ) ≤ 4 g ( δ n ) , and Lemma 5.5 with N = ( n + 1 ) ( m + 1 ) ≤ n 3 N=(n+1)(m+1)\le n^3 N = ( n + 1 ) ( m + 1 ) ≤ n 3 and L = 1 L=1 L = 1 turns the count into the time bound. The optimum and its multiplicity are read off the profile as in Corollary 6.4. (ii) The factor system in the proof of Theorem 6.18 (i) has one factor of scope 2 per edge and one of scope 1 per vertex, with values in A N \mathcal{A}_N A N , N = 2 E max + 1 N=2E_{\max}+1 N = 2 E m a x + 1 , and coefficients of O ( log E max ) O(\log E_{\max}) O ( log E m a x ) bits; it has at most 2 d ( n ) n 2d(n)n 2 d ( n ) n factors, and Theorem 7.20 with k = 2 k=2 k = 2 , c = 2 d ( n ) c=2d(n) c = 2 d ( n ) and Lemma 5.5 give the bound as in (i). The factor system in the proof of Theorem 6.18 (ii) lives on n ′ = q n n'=qn n ′ = q n variables and has n n n factors of scope q q q and at most d ( n ) n d(n)n d ( n ) n of scope 2 q 2q 2 q , with coefficients of O ( q + log E max ) O(q+\log E_{\max}) O ( q + log E m a x ) bits; so it has at most ( d ( n ) + 1 ) n ≤ ( d ( n ) + 1 ) n ′ (d(n)+1)n\le(d(n)+1)n' ( d ( n ) + 1 ) n ≤ ( d ( n ) + 1 ) n ′ factors of scope at most 2 q 2q 2 q . Theorem 7.20 on n ′ n' n ′ variables with k = 2 q k=2q k = 2 q and c = d ( n ) + 1 c=d(n)+1 c = d ( n ) + 1 has θ n ′ ′ ≤ 4 q d ( n ) log log n ′ / log n ′ ≤ 4 q δ n \theta_{n'}'\le4qd(n)\sqrt{\log\log n'/\log n'}\le4q\delta_n θ n ′ ′ ≤ 4 q d ( n ) log log n ′ / log n ′ ≤ 4 q δ n for large n n n , because log log x / log x \log\log x/\log x log log x / log x decreases for x ≥ 16 x\ge16 x ≥ 16 ; it gives poly ( n ) 24800 q n g ( 4 q δ n ) \operatorname{poly}(n)^{24800qn g(4q\delta_n)} poly ( n ) 24800 q n g ( 4 q δ n ) operations, and g ( 4 q δ n ) ≤ 4 q g ( δ n ) g(4q\delta_n)\le4qg(\delta_n) g ( 4 q δ n ) ≤ 4 q g ( δ n ) . Lemma 5.5 turns the counts into time bounds, and the ground-state energy and the partition functions follow as in Theorem 6.18 . □ \square □
At d ( n ) = log n / ( log log n ) 3 d(n)=\sqrt{\log n}/(\log\log n)^3 d ( n ) = log n / ( log log n ) 3 , for instance, δ n = ( log log n ) − 5 / 2 \delta_n=(\log\log n)^{-5/2} δ n = ( log log n ) − 5/2 and the exponent in (i) is O ( n / ( log log n ) 2 ) O(n/(\log\log n)^2) O ( n / ( log log n ) 2 ) .
The cut function of a graph and that of its complement determine each other, so the corollary also reaches graphs with Θ ( n 2 ) \Theta(n^2) Θ ( n 2 ) edges whose complement is sparse.
Corollary 7.22 (Graphs with sparse complements). Let d = d ( n ) ≥ 1 d=d(n)\ge1 d = d ( n ) ≥ 1 satisfy δ n → 0 \delta_n\to0 δ n → 0 and let Ω 0 ≥ 1 \Omega_0\ge1 Ω 0 ≥ 1 be an integer. Let H H H be a graph on a vertex set V V V of size n n n with at most d ( n ) n d(n)n d ( n ) n edges, and let ω \omega ω be a weighting of the pairs of distinct vertices with ω u v = Ω 0 \omega_{uv}=\Omega_0 ω uv = Ω 0 for u v ∉ E ( H ) uv\notin E(H) uv ∈ / E ( H ) and ω u v ∈ { 0 , 1 , … , Ω 0 } \omega_{uv}\in\{0,1,\ldots,\Omega_0\} ω uv ∈ { 0 , 1 , … , Ω 0 } for u v ∈ E ( H ) uv\in E(H) uv ∈ E ( H ) . Then the numbers
p i , j : = # { S ⊆ V : ∣ S ∣ = i , ∑ u ∈ S , v ∉ S ω u v = j } p_{i,j}:=\#\left\{S\subseteq V: |S|=i,\ \sum_{\substack{u\in S,v\notin S}}\omega_{uv}=j\right\} p i , j := # ⎩ ⎨ ⎧ S ⊆ V : ∣ S ∣ = i , u ∈ S , v ∈ / S ∑ ω uv = j ⎭ ⎬ ⎫ are computed for all i , j i,j i , j in time poly ( n , Ω 0 ) 2 O ( n g ( δ n ) ) = poly ( Ω 0 ) 2 o ( n ) \operatorname{poly}(n,\Omega_0)2^{O(n g(\delta_n))}=\operatorname{poly}(\Omega_0)2^{o(n)} poly ( n , Ω 0 ) 2 O ( n g ( δ n )) = poly ( Ω 0 ) 2 o ( n ) . In particular, for every graph G G G on n n n vertices whose complement has at most d ( n ) n d(n)n d ( n ) n edges, the cut profile of G G G , the maximum cut, the maximum and the minimum bisection, and the numbers of optimal solutions, are computed in time 2 o ( n ) 2^{o(n)} 2 o ( n ) .
Proof. Put η u v = Ω 0 − ω u v ∈ { 0 , … , Ω 0 } \eta_{uv}=\Omega_0-\omega_{uv}\in\{0,\ldots,\Omega_0\} η uv = Ω 0 − ω uv ∈ { 0 , … , Ω 0 } for u v ∈ E ( H ) . E v e r y p a i r uv\in E(H). Every pair uv ∈ E ( H ) . E v er y p ai r {u,v}$ with u ∈ S u\in S u ∈ S and v ∉ S v\notin S v ∈ / S carries the weight Ω 0 \Omega_0 Ω 0 , less η u v \eta_{uv} η uv when it is an edge of H H H , and there are ∣ S ∣ ( n − ∣ S ∣ ) |S|(n-|S|) ∣ S ∣ ( n − ∣ S ∣ ) such pairs; hence
∑ u ∈ S , v ∉ S ω u v = Ω 0 ∣ S ∣ ( n − ∣ S ∣ ) − cut η ( S ) , (70) \sum_{\substack{u\in S,v\notin S}}\omega_{uv}=\Omega_0|S|(n-|S|)-\operatorname{cut}_{\eta}(S), \tag*{(70)} u ∈ S , v ∈ / S ∑ ω uv = Ω 0 ∣ S ∣ ( n − ∣ S ∣ ) − cut η ( S ) , (70)
where cut η ( S ) \operatorname{cut}_{\eta}(S) cut η ( S ) is the total η \eta η -weight of the edges of H H H between S S S and $V\setminus S. Corollary 6.4, with Theorem 7.20 in place of Theorem 5.3 as in the proof of Corollary 7.21 (i), computes the numbers q i , j q_{i,j} q i , j of sets S S S of size i i i with cut η ( S ) = j \operatorname{cut}_{\eta}(S)=j cut η ( S ) = j in the stated time; the algebra is A n + 1 , Ω 0 m + 1 A_{n+1,\Omega_0m+1} A n + 1 , Ω 0 m + 1 with m = ∣ E ( H ) ∣ m=|E(H)| m = ∣ E ( H ) ∣ , of dimension polynomial in n n n and Ω 0 \Omega_0 Ω 0 . By (70) , p i , j = q i , Ω 0 i ( n − i ) − j p_{i,j}=q_{i,\Omega_0i(n-i)-j} p i , j = q i , Ω 0 i ( n − i ) − j , read as $0$ when the index is negative or exceeds Ω 0 m \Omega_0m Ω 0 m . For a graph G G G take H H H its complement, Ω 0 = 1 \Omega_0=1 Ω 0 = 1 and ω = 0 \omega=0 ω = 0 on E ( H ) E(H) E ( H ) ; then ω \omega ω is the indicator of E ( G ) E(G) E ( G ) , and the maximum cut and the bisections are read off the numbers p i , j p_{i,j} p i , j . □ \square □
Corollary 7.22 rests on the fact that the cut of the complete graph depends on ∣ S ∣ |S| ∣ S ∣ alone. More generally, the cut of a graph whose adjacency is a fixed quadratic expression in a few vertex weights depends only on the values of those weights on S S S , and these values are linear statistics in the sense of Theorem 7.1 . A sparse perturbation of such a graph is then within reach.
Theorem 7.23 (Sparse perturbations of graphs of bounded rank). Let d = d ( n ) ≥ 1 d=d(n)\ge1 d = d ( n ) ≥ 1 satisfy δ n → 0 \delta_n\to0 δ n → 0 , and let s ≥ 1 s\ge1 s ≥ 1 and Ω ≥ 1 \Omega\ge1 Ω ≥ 1 be integers. Let V V V be a set of size n n n , let w 1 , … , w s : V → { 0 , 1 , … , Ω } w_1,\ldots,w_s:V\to\{0,1,\ldots,\Omega\} w 1 , … , w s : V → { 0 , 1 , … , Ω } and let C = ( c a b ) C=(c_{ab}) C = ( c ab ) be a symmetric s × s s\times s s × s integer matrix with entries in [ − Ω , Ω ] [-\Omega,\Omega] [ − Ω , Ω ] . Put
ω u v = ∑ a , b = 1 s c a b w a ( u ) w b ( v ) ( u ≠ v ) , \omega_{uv}=\sum_{a,b=1}^{s}c_{ab}w_a(u)w_b(v)\qquad(u\ne v), ω uv = a , b = 1 ∑ s c ab w a ( u ) w b ( v ) ( u = v ) ,
let H H H be a graph on V V V with at most d ( n ) n d(n)n d ( n ) n edges and let η : E ( H ) → { − Ω , … , Ω } \eta:E(H)\to\{-\Omega,\ldots,\Omega\} η : E ( H ) → { − Ω , … , Ω } , extended by 0 0 0 to the other pairs. For S ⊆ V S\subseteq V S ⊆ V let cut ( S ) = ∑ u ∈ S , v ∉ S ( ω u v + η u v ) \operatorname{cut}(S)=\sum_{u\in S,v\notin S}(\omega_{uv}+\eta_{uv}) cut ( S ) = ∑ u ∈ S , v ∈ / S ( ω uv + η uv ) . Then the numbers
p i , j = # { S ⊆ V : ∣ S ∣ = i , cut ( S ) = j } ( i ≥ 0 , j ∈ Z ) p_{i,j}=\#\{S\subseteq V:|S|=i,\operatorname{cut}(S)=j\}\qquad(i\geq0,\ j\in\mathbb{Z}) p i , j = # { S ⊆ V : ∣ S ∣ = i , cut ( S ) = j } ( i ≥ 0 , j ∈ Z )
are computed for all i , j i,j i , j in deterministic time
poly ( n , Ω , ( 1 + n Ω ) s ) 2 O ( n g ( δ n ) ) , \operatorname{poly}(n,\Omega,(1+n\Omega)^s)2^{O(n\,g(\delta_n))}, poly ( n , Ω , ( 1 + n Ω ) s ) 2 O ( n g ( δ n )) ,
which is 2 o ( n ) 2^{o(n)} 2 o ( n ) whenever s log ( n Ω ) = o ( n ) s\log(n\Omega)=o(n) s log ( n Ω ) = o ( n ) .
Proof. Encode S S S by its indicator x ∈ { 0 , 1 } V x\in\{0,1\}^V x ∈ { 0 , 1 } V , and put j a = ∑ v w a ( v ) x v j_a=\sum_v w_a(v)x_v j a = ∑ v w a ( v ) x v and Σ a = ∑ v w a ( v ) \Sigma_a=\sum_v w_a(v) Σ a = ∑ v w a ( v ) . Every ordered pair ( u , v ) (u,v) ( u , v ) with u ∈ S u\in S u ∈ S and v ∉ S v\notin S v ∈ / S has u ≠ v u\ne v u = v , so
∑ u ∈ S , v ∉ S ω u v = ∑ a , b c a b ( ∑ u ∈ S w a ( u ) ) ( ∑ v ∉ S w b ( v ) ) = ∑ a , b c a b j a ( Σ b − j b ) = : P ( j 1 , … , j s ) , (71) \sum_{u\in S,v\notin S}\omega_{uv}=\sum_{a,b}c_{ab}\left(\sum_{u\in S}w_a(u)\right)\left(\sum_{v\notin S}w_b(v)\right)=\sum_{a,b}c_{ab}j_a(\Sigma_b-j_b)=:P(j_1,\ldots,j_s), \tag*{(71)} u ∈ S , v ∈ / S ∑ ω uv = a , b ∑ c ab ( u ∈ S ∑ w a ( u ) ) v ∈ / S ∑ w b ( v ) = a , b ∑ c ab j a ( Σ b − j b ) =: P ( j 1 , … , j s ) , (71)
and cut ( S ) = P ( j 1 , … , j s ) + cut η + ( S ) − cut η − ( S ) \operatorname{cut}(S)=P(j_1,\ldots,j_s)+\operatorname{cut}_{\eta^+}(S)-\operatorname{cut}_{\eta^-}(S) cut ( S ) = P ( j 1 , … , j s ) + cut η + ( S ) − cut η − ( S ) , where η ± = max ( ± η , 0 ) \eta^\pm=\max(\pm\eta,0) η ± = max ( ± η , 0 ) and cut η ± ( S ) \operatorname{cut}_{\eta^\pm}(S) cut η ± ( S ) is the η ± \eta^\pm η ± -weight of the edges of H H H between S S S and V ∖ S V\setminus S V ∖ S . Let N ± = 1 + ∑ e η e ± ≤ 1 + d ( n ) n Ω N_\pm=1+\sum_e\eta_e^\pm\leq1+d(n)n\Omega N ± = 1 + ∑ e η e ± ≤ 1 + d ( n ) n Ω , N a = 1 + Σ a ≤ 1 + n Ω N_a=1+\Sigma_a\leq1+n\Omega N a = 1 + Σ a ≤ 1 + n Ω , and
A = Q [ W + , W − , U , T 1 , … , T s ] / ( W + N + , W − N − , U n + 1 , T 1 N 1 , … , T s N s ) , \mathcal{A}=\mathbb{Q}[W_+,W_-,U,T_1,\ldots,T_s]/(W_+^{N_+},W_-^{N_-},U^{n+1},T_1^{N_1},\ldots,T_s^{N_s}), A = Q [ W + , W − , U , T 1 , … , T s ] / ( W + N + , W − N − , U n + 1 , T 1 N 1 , … , T s N s ) ,
of dimension N ≤ ( 1 + d ( n ) n Ω ) 2 ( n + 1 ) ( 1 + n Ω ) s N\leq(1+d(n)n\Omega)^2(n+1)(1+n\Omega)^s N ≤ ( 1 + d ( n ) n Ω ) 2 ( n + 1 ) ( 1 + n Ω ) s . For an edge e = { u , v } e=\{u,v\} e = { u , v } of H H H take the factor 1 + ( W + η e + W − η e − − 1 ) ( Y u + Y v − 2 Y u Y v ) 1+(W_+^{\eta_e^+}W_-^{\eta_e^-}-1)(Y_u+Y_v-2Y_uY_v) 1 + ( W + η e + W − η e − − 1 ) ( Y u + Y v − 2 Y u Y v ) , the multilinear extension of W + η e + [ x u ≠ x v ] W − η e − [ x u ≠ x v ] W_+^{\eta_e^+[x_u\ne x_v]}W_-^{\eta_e^-[x_u\ne x_v]} W + η e + [ x u = x v ] W − η e − [ x u = x v ] , and for a vertex v v v the factor 1 + ( U T 1 w 1 ( v ) ⋯ T s w s ( v ) − 1 ) Y v 1+(UT_1^{w_1(v)}\cdots T_s^{w_s(v)}-1)Y_v 1 + ( U T 1 w 1 ( v ) ⋯ T s w s ( v ) − 1 ) Y v , of degree one in Y v Y_v Y v as in the proof of Theorem 7.1 . There are at most ( d ( n ) + 1 ) n ≤ 2 d ( n ) n (d(n)+1)n\leq2d(n)n ( d ( n ) + 1 ) n ≤ 2 d ( n ) n factors of scope at most 2 2 2 , with coefficients that are polynomials in the generators with integer coefficients of absolute value at most 2 2 2 , and their sum is
Z = ∑ x W + cut η + ( x ) W − cut η − ( x ) U ∣ x ∣ T 1 j 1 ⋯ T s j s = ∑ r ( h + , h − , i , j 1 , … , j s ) W + h + W − h − U i T 1 j 1 ⋯ T s j s , Z=\sum_xW_+^{\operatorname{cut}_{\eta^+}(x)}W_-^{\operatorname{cut}_{\eta^-}(x)}U^{|x|}T_1^{j_1}\cdots T_s^{j_s}=\sum r(h_+,h_-,i,j_1,\ldots,j_s)W_+^{h_+}W_-^{h_-}U^iT_1^{j_1}\cdots T_s^{j_s}, Z = x ∑ W + cut η + ( x ) W − cut η − ( x ) U ∣ x ∣ T 1 j 1 ⋯ T s j s = ∑ r ( h + , h − , i , j 1 , … , j s ) W + h + W − h − U i T 1 j 1 ⋯ T s j s ,
with no term truncated. Theorem 7.20 with c = 2 d ( n ) c=2d(n) c = 2 d ( n ) and k = 2 k=2 k = 2 applies once 4 δ n ≤ θ 1 4\delta_n\leq\theta_1 4 δ n ≤ θ 1 and computes Z Z Z with poly ( n ) n 4800 n g ( 4 δ n ) \operatorname{poly}(n)n^{4800}n\,g(4\delta_n) poly ( n ) n 4800 n g ( 4 δ n ) operations in A \mathcal{A} A , and g ( 4 δ n ) ≤ 4 g ( δ n ) g(4\delta_n)\leq4g(\delta_n) g ( 4 δ n ) ≤ 4 g ( δ n ) ; the bit bound of that theorem gives the stated time. Finally p i , j = ∑ r ( h + , h − , i , j 1 , … , j s ) p_{i,j}=\sum r(h_+,h_-,i,j_1,\ldots,j_s) p i , j = ∑ r ( h + , h − , i , j 1 , … , j s ) over the tuples with h + − h − + P ( j 1 , … , j s ) = j h_+-h_-+P(j_1,\ldots,j_s)=j h + − h − + P ( j 1 , … , j s ) = j , a sum over at most N N N coefficients.
Corollary 7.24 (Blow-ups with few changes). Let d = d ( n ) d=d(n) d = d ( n ) satisfy δ n → 0 \delta_n\to0 δ n → 0 and let s = s ( n ) = o ( n / log n ) s=s(n)=o(n/\log n) s = s ( n ) = o ( n / log n ) . Let F F F be a graph on { 1 , … , s } \{1,\ldots,s\} { 1 , … , s } , loops allowed, and let V = V 1 ∪ ⋯ ∪ V s V=V_1\cup\cdots\cup V_s V = V 1 ∪ ⋯ ∪ V s be a partition of a set of size n n n . The blow-up F [ V 1 , … , V s ] F[V_1,\ldots,V_s] F [ V 1 , … , V s ] joins u ∈ V a u\in V_a u ∈ V a and v ∈ V b v\in V_b v ∈ V b , u ≠ v u\ne v u = v , exactly when a b ∈ E ( F ) ab\in E(F) ab ∈ E ( F ) . For every graph G G G on V V V that differs from the blow-up in at most d ( n ) n d(n)n d ( n ) n pairs, the cut profile of G G G , its maximum cut, its maximum and minimum bisection, and the numbers of optimal solutions, are computed in time 2 o ( n ) 2^{o(n)} 2 o ( n ) . This holds in particular for every graph that differs in at most d ( n ) n d(n)n d ( n ) n pairs from a complete multipartite graph with o ( n / log n ) o(n/\log n) o ( n / log n ) parts.
Proof. Take Ω = 1 \Omega=1 Ω = 1 , w a w_a w a the indicator of V a V_a V a and c a b = 1 c_{ab}=1 c ab = 1 for a b ∈ E ( F ) ab\in E(F) ab ∈ E ( F ) and 0 0 0 otherwise; then ω u v \omega_{uv} ω uv is the adjacency of the blow-up, since exactly one of the sum is nonzero. Let H H H be the graph of the pairs where G G G and the blow-up differ, with η = + 1 \eta=+1 η = + 1 on the pairs that are edges of G G G only and η = − 1 \eta=-1 η = − 1 on the others; then ω + η \omega+\eta ω + η is the adjacency of G G G . Theorem 7.23 applies with s log ( n + 1 ) = o ( n ) s\log(n+1)=o(n) s log ( n + 1 ) = o ( n ) , and the optima are read off the numbers p i , j p_{i,j} p i , j as in Corollary 6.4.
Corollary 7.22 is the case s = 1 s=1 s = 1 , w 1 = 1 w_1=1 w 1 = 1 , c 11 = Ω 0 c_{11}=\Omega_0 c 11 = Ω 0 of the theorem. Without the perturbation the cut is the polynomial P P P of the linear statistics j a j_a j a , and its maximisation needs no part of the routine: the s s s -tuples ( j a ) (j_a) ( j a ) that occur are counted in time poly ( n Ω ) s \operatorname{poly}(n\Omega)^s poly ( n Ω ) s by dynamic programming over the vertices, and for a positive semidefinite objective of fixed rank Allemand, Fukuda,
Liebling and Steiner [1 ] solve unconstrained 0-1 quadratic optimisation in polynomial time. The perturbation η \eta η is what requires Theorem 7.20 : for s = 1 s=1 s = 1 and ω = 0 \omega=0 ω = 0 it is Max-Cut on a graph of average degree d ( n ) d(n) d ( n ) .
Remark 7.25. The graphs reached by Theorem 7.23 in time 2 o ( n ) 2^{o(n)} 2 o ( n ) form a vanishingly small part of all graphs. Fix ε > 0 \varepsilon>0 ε > 0 and parameters with s log ( n Ω ) ≤ ε n s\log(n\Omega)\le\varepsilon n s log ( n Ω ) ≤ ε n . A graph G G G covered by the theorem is determined by w 1 , … , w s w_1,\ldots,w_s w 1 , … , w s , C C C , the edge set of H H H and the restriction of the adjacency of G G G to E ( H ) E(H) E ( H ) , since η \eta η is then the difference of that restriction and ω \omega ω . There are at most
( Ω + 1 ) n s ( 2 Ω + 1 ) s 2 n 2 d ( n ) n 2 d ( n ) n (\Omega+1)^{ns}(2\Omega+1)^{s^2}n^{2d(n)n}2^{d(n)n} ( Ω + 1 ) n s ( 2Ω + 1 ) s 2 n 2 d ( n ) n 2 d ( n ) n
such choices. Because s ≤ n s\le n s ≤ n , both n s log ( Ω + 1 ) ns\log(\Omega+1) n s log ( Ω + 1 ) and s 2 log ( 2 Ω + 1 ) s^2\log(2\Omega+1) s 2 log ( 2Ω + 1 ) are at most 2 n s log ( n Ω ) < 2 ε n 2 2ns\log(n\Omega)<2\varepsilon n^2 2 n s log ( n Ω ) < 2 ε n 2 , and d ( n ) n ( 2 log n + 1 ) = o ( n 2 ) d(n)n(2\log n+1)=o(n^2) d ( n ) n ( 2 log n + 1 ) = o ( n 2 ) , so the count is at most 2 5 ε n 2 2^{5\varepsilon n^2} 2 5 ε n 2 for n n n large, while there are 2 n ( n − 1 ) / 2 2^{n(n-1)/2} 2 n ( n − 1 ) /2 graphs on V V V . As ε \varepsilon ε is arbitrary, the proportion of graphs on V V V covered by the theorem with parameters for which its bound is 2 o ( n ) 2^{o(n)} 2 o ( n ) tends to 0 0 0 , and the random graph G ( n , 1 2 ) G(n,\frac{1}{2}) G ( n , 2 1 ) is covered with probability tending to 0 0 0 . The exact maximum cut of every graph in time 2 o ( n ) 2^{o(n)} 2 o ( n ) is therefore not a consequence of the theorem, and it is not proved in this paper.
The bookkeeping of Corollary 7.22 applies as well to the profiles of Theorem 6.1 and to the programs of Theorem 7.17 .
Corollary 7.26 (Max-k k k -SAT and integer programs at growing density). Let d = d ( n ) ≥ 1 d=d(n)\ge1 d = d ( n ) ≥ 1 satisfy δ n → 0 \delta_n\to0 δ n → 0 , and fix k ≥ 1 k\ge1 k ≥ 1 and s ≥ 0 s\ge0 s ≥ 0 .
(i) For a k k k -CNF formula with n n n variables and at most d ( n ) n d(n)n d ( n ) n clauses with integer weights in [ 0 , Ω ] [0,\Omega] [ 0 , Ω ] , the profile (58) , and with it the maximum satisfiable weight and the number of assignments attaining it, is computed in time poly ( n , Ω ) 2 O k ( n g ( δ n ) ) = poly ( Ω ) 2 o ( n ) \operatorname{poly}(n,\Omega)2^{O_k(n g(\delta_n))}=\operatorname{poly}(\Omega)2^{o(n)} poly ( n , Ω ) 2 O k ( n g ( δ n )) = poly ( Ω ) 2 o ( n ) .
(ii) For a program as in Theorem 7.17 with at most d ( n ) n d(n)n d ( n ) n sparse rows, each involving at most k k k variables, the numbers p ( j 0 , … , j s ) p(j_0,\ldots,j_s) p ( j 0 , … , j s ) of Theorem 7.17 (i) are computed in time poly ℓ ( ( 1 + 2 n Ω ) s + 2 ) 2 O k ( n g ( δ n ) ) \operatorname{poly}_{\ell}((1+2n\Omega)^{s+2})2^{O_k(n g(\delta_n))} poly ℓ (( 1 + 2 n Ω ) s + 2 ) 2 O k ( n g ( δ n )) .
Proof. (i) The factor system of the proof of Theorem 6.1 has at most d ( n ) n d(n)n d ( n ) n factors of scope at most k k k , with values in A N \mathcal{A}_N A N , N = 1 + ∑ f ω f ≤ 1 + d ( n ) n Ω N=1+\sum_f\omega_f\le1+d(n)n\Omega N = 1 + ∑ f ω f ≤ 1 + d ( n ) n Ω , and coefficients of at most k k k bits. Theorem 7.20 with c = d ( n ) c=d(n) c = d ( n ) applies once k δ n ≤ θ 1 k\delta_n\le\theta_1 k δ n ≤ θ 1 and gives poly ( n ) 2 4800 n g ( k δ n ) \operatorname{poly}(n)2^{4800n g(k\delta_n)} poly ( n ) 2 4800 n g ( k δ n ) operations, with g ( k δ n ) ≤ k g ( δ n ) g(k\delta_n)\le k g(\delta_n) g ( k δ n ) ≤ k g ( δ n ) ; Lemma 5.5 gives the time bound. (ii) The factor system of the proof of Theorem 7.17 , through that of Theorem 7.1 , consists of the at most d ( n ) n d(n)n d ( n ) n indicator factors of the sparse rows and the n n n factors Ψ v \Psi_v Ψ v of scope 1 1 1 , at most 2 d ( n ) n 2d(n)n 2 d ( n ) n factors of scope at most k k k , with values in an algebra of dimension at most ( 1 + 2 n Ω ) s + 2 (1+2n\Omega)^{s+2} ( 1 + 2 n Ω ) s + 2 and coefficients of at most k + 1 k+1 k + 1 bits. Theorem 7.20 with c = 2 d ( n ) c=2d(n) c = 2 d ( n ) and Lemma 5.5 compute its sum, and the numbers p ( j 0 , … , j s ) p(j_0,\ldots,j_s) p ( j 0 , … , j s ) are read off as in the proof of Theorem 7.17 . □ \square □
Remark 7.27. The regime of Theorem 7.20 ends at c k ck c k of order log n / log log n \sqrt{\log n}/\log\log n log n / log log n . Below that order the exponent is o ( n ) o(n) o ( n ) ; at that order θ n \theta_n θ n is bounded away from 0 0 0 and (68) is no better than enumeration. The routine of Proposition 3.5 cannot reach quadratic density with any design at all. The balance condition (47) and M ≤ b n M\le bn M ≤ bn give D 2 ≤ M / ( 2 ( b + w ) ) > n / 2 D^2\le M/(2(b+w))>n/2 D 2 ≤ M / ( 2 ( b + w )) > n /2 , and D = r 2 Q ≥ 2 2 Q D=r^{2Q}\ge2^{2Q} D = r 2 Q ≥ 2 2 Q , so every admissible design has Q < 1 4 log n Q<\frac14\log n Q < 4 1 log n . Consequently q = d R / Q ≥ d R / log n q=dR/Q\ge dR/\log n q = d R / Q ≥ d R / log n , and q ≥ n q\ge n q ≥ n as soon as the total degree satisfies d ≥ 1 4 ( n + 1 ) log n d\ge\frac14(n+1)\log n d ≥ 4 1 ( n + 1 ) log n ; then C q = ∑ s = 0 n 2 s ( n ) = 3 n C_q=\sum_{s=0}^n2^{s(n)}=3^n C q = ∑ s = 0 n 2 s ( n ) = 3 n , and the Taylor count (27) alone is exponential. For the cut factors 1 + ( W − 1 ) ( Y u + Y v − 2 Y u Y v ) 1+(W-1)(Y_u+Y_v-2Y_uY_v) 1 + ( W − 1 ) ( Y u + Y v − 2 Y u Y v ) of a graph with m m m edges the product over the edges has degree exactly 2 m 2m 2 m in the incidence indeterminates, its top coefficient being ( − 2 ) m ( W − 1 ) m ≠ 0 (-2)^m(W-1)^m\ne0 ( − 2 ) m ( W − 1 ) m = 0 in A m + 1 \mathcal{A}_{m+1} A m + 1 , so the degree bound (11) cannot be lowered and a graph with m ≥ 1 8 ( n + 1 ) log n m\ge\frac18(n+1)\log n m ≥ 8 1 ( n + 1 ) log n edges already gives q ≥ n q\ge n q ≥ n . Branching on h h h vertices costs 2 h 2^h 2 h and removes at most h n hn hn edges, so for a graph with Θ ( n 2 ) \Theta(n^2) Θ ( n 2 ) edges any subexponential branching leaves Θ ( n 2 ) \Theta(n^2) Θ ( n 2 ) edges. This is a limitation of the routine, not a lower bound for Max-Cut. The theorem is nonetheless a bound of the form 2 o ( n ) 2^{o(n)} 2 o ( n ) for the exact maximum cut on graphs whose average degree tends to infinity, and Corollary 7.22 and Theorem 7.23 give one for classes of graphs with Θ ( n 2 ) \Theta(n^2) Θ ( n 2 ) edges, though not for almost every graph (Remark 7.25); the algorithm of Williams [35 ] runs in time 2 ω n / 3 2^{\omega n/3} 2 ω n /3 on every graph, and under the exponential time hypothesis no bound 2 o ( n ) 2^{o(n)} 2 o ( n ) was possible even at bounded degree.
Dense formulas and the class SNP
Subexponential time and sparsification
Following Impagliazzo, Paturi and Zane [21 ] , a decision problem is considered together with a complexity parameter μ ( x ) ≥ 1 \mu(x) \ge1 μ ( x ) ≥ 1 , a polynomial-time computable integer function of the instance x x x ; for a formula it is the number of variables, for a graph the number of vertices. The class SE consists of the parameterised problems that admit, for every ε > 0 \varepsilon> 0 ε > 0 , a deterministic algorithm running in time 2 ε μ ( x ) poly ( ∣ x ∣ ) 2^{\varepsilon\mu(x)}\operatorname{poly}(|x|) 2 ε μ ( x ) poly ( ∣ x ∣ ) on every instance x x x . The exponential time hypothesis is the statement that 3-SAT, with the number of variables as parameter, is not in SE.
We use the sparsification lemma in the following form.
Theorem 8.1 (Sparsification lemma, [21 ] ). For every integer k ≥ 2 k \ge2 k ≥ 2 and every ε > 0 \varepsilon> 0 ε > 0 there is a constant C = C ( k , ε ) C = C(k,\varepsilon) C = C ( k , ε ) and a deterministic algorithm that, given a k k k -CNF formula φ \varphi φ with n n n variables and m m m clauses, outputs in time 2 ε n poly ( n + m ) 2^{\varepsilon n}\operatorname{poly}(n+m) 2 ε n poly ( n + m ) a list of at most 2 ε n 2^{\varepsilon n} 2 ε n k k k -CNF formulas φ 1 , … , φ t \varphi_1,\ldots,\varphi_t φ 1 , … , φ t on the same n n n variables, each with at most C n Cn C n clauses, such that an assignment satisfies φ \varphi φ if and only if it satisfies at least one φ i \varphi_i φ i . Quantitative forms of the dependence of C C C on k k k and ε \varepsilon ε are given in [10 ] .
Theorem 8.2 (k k k -SAT is in SE). For every k ≥ 2 k \ge2 k ≥ 2 , k k k -SAT with the number of variables as parameter lies in SE. Explicitly, for every ε > 0 \varepsilon> 0 ε > 0 there is n ε n_\varepsilon n ε such that the satisfiability of a k k k -CNF formula with n ≥ n ε n \ge n_\varepsilon n ≥ n ε variables and m m m clauses is decided deterministically in time 2 ε n poly ( n + m ) 2^{\varepsilon n}\operatorname{poly}(n+m) 2 ε n poly ( n + m ) .
Proof. Given ε \varepsilon ε , apply Theorem 8.1 with ε / 2 \varepsilon/2 ε /2 and C = C ( k , ε / 2 ) C = C(k,\varepsilon/2) C = C ( k , ε /2 ) . For each φ i \varphi_i φ i of the list, apply Theorem 5.3 with A = Q \mathcal{A} = \mathbb{Q} A = Q , c = C c = C c = C and the satisfaction indicators of the clauses as factors: it returns the number of satisfying assignments of φ i \varphi_i φ i in time poly ( n ) 2 O k , C ( ρ ( n ) ) \operatorname{poly}(n)2^{O_{k,C}(\rho(n))} poly ( n ) 2 O k , C ( ρ ( n )) . Since ρ ( n ) = o ( n ) \rho(n) = o(n) ρ ( n ) = o ( n ) , there is n ε n_\varepsilon n ε with poly ( n ) 2 O k , C ( ρ ( n ) ) ≤ 2 ε n / 2 \operatorname{poly}(n)2^{O_{k,C}(\rho(n))} \le2^{\varepsilon n/2} poly ( n ) 2 O k , C ( ρ ( n )) ≤ 2 ε n /2 for n ≥ n ε n \ge n_\varepsilon n ≥ n ε . The formula φ \varphi φ is satisfiable if and only if one of the counts is positive, and the total time is 2 ε n / 2 2 ε n / 2 poly ( n + m ) 2^{\varepsilon n/2}2^{\varepsilon n/2}\operatorname{poly}(n+m) 2 ε n /2 2 ε n /2 poly ( n + m ) . □
Remark 8.3. The decision of a dense formula through sparsification and the sparse routine loses the exact count, because the lists of satisfying assignments of the φ i \varphi_i φ i overlap. OpenAI obtain the exact count of every k k k -CNF, with the exponent n log log n / log n n\log\log n/\sqrt{\log n} n log log n / log n , through the counting-preserving sparsification of Dell, Husfeldt, Marx, Taslaman and Wåhlén [14 Appendix A] and their Sections 5 and 6; that is their Theorem 1.1, and it is not reproduced here. Theorem 8.2 is the statement needed below.
Strict NP
Papadimitriou and Yannakakis [29 ] define the class SNP of properties of finite relational structures expressible by a sentence
∃ S 1 ⋯ ∃ S t ∀ y 1 ⋯ ∀ y r ψ ( y 1 , … , y r ; S 1 , … , S t ; G 1 , … , G s ) , (72) \exists S_1 \cdots\exists S_t\ \forall y_1 \cdots\forall y_r\ \psi(y_1,\ldots,y_r; S_1,\ldots,S_t; G_1,\ldots,G_s), \tag*{(72)} ∃ S 1 ⋯ ∃ S t ∀ y 1 ⋯ ∀ y r ψ ( y 1 , … , y r ; S 1 , … , S t ; G 1 , … , G s ) , (72)
where the G j G_j G j are the input relations on a universe U U U of size n n n , the S i S_i S i are relation variables of arities a i a_i a i , the y j y_j y j range over U U U , and ψ \psi ψ is quantifier-free, built from atoms S i ( y ˉ ) S_i(\bar y) S i ( y ˉ ) , G j ( y ˉ ) G_j(\bar y) G j ( y ˉ ) and equalities between the y j y_j y j by Boolean connectives. The problem associated with (72) asks whether a given structure satisfies the sentence. Following [21 ] we take as complexity parameter the number
μ = ∑ i = 1 t n a i (73) \mu= \sum_{i=1}^{t} n^{a_i} \tag*{(73)} μ = i = 1 ∑ t n a i (73)
of Boolean choices in the second-order variables, which is t n tn t n when every S i S_i S i is unary. For k k k -SAT with the clauses given as relations, for q q q -colourability, for independent set, clique and vertex cover with a threshold, and for k k k -set cover, all arities are one and μ \mu μ is a constant multiple of n n n , so that membership in SE with respect to μ \mu μ is membership with respect to the natural parameter.
Theorem 8.4 (SNP ⊆ \subseteq ⊆ SE). Every problem in SNP, with the parameter (73) , lies in SE.
Proof. Fix the sentence (72) and let k ≥ 2 k \ge2 k ≥ 2 be the number of atoms S i ( y ˉ ) S_i(\bar{y}) S i ( y ˉ ) occurring in ψ \psi ψ , counted with their tuples of variables, or 2 if that number is smaller. Given the structure, introduce a Boolean variable z i , u ˉ z_{i,\bar{u}} z i , u ˉ for every i ≤ t i \le t i ≤ t and every u ˉ ∈ U a i \bar{u} \in U^{a_i} u ˉ ∈ U a i ; there are μ \mu μ of them. For each v ˉ ∈ U r \bar{v} \in U^r v ˉ ∈ U r the formula ψ ( v ˉ ; S ; G ) \psi(\bar{v}; S; G) ψ ( v ˉ ; S ; G ) becomes, after the input atoms and equalities are evaluated to constants and each atom S i ( w ˉ ) S_i(\bar{w}) S i ( w ˉ ) with w ˉ \bar{w} w ˉ a tuple of entries of v ˉ \bar{v} v ˉ is replaced by z i , w ˉ z_{i,\bar{w}} z i , w ˉ , a Boolean formula ψ v ˉ \psi_{\bar{v}} ψ v ˉ in at most k k k of the variables z z z . Write ψ v ˉ \psi_{\bar{v}} ψ v ˉ as a conjunction of at most 2 k 2^k 2 k clauses of width at most k k k by listing the falsifying assignments of its at most k k k variables. The conjunction Φ \Phi Φ of all ψ v ˉ \psi_{\bar{v}} ψ v ˉ over v ˉ ∈ U r \bar{v} \in U^r v ˉ ∈ U r is a k k k -CNF with μ \mu μ variables and at most 2 k n r 2^k n^r 2 k n r clauses, computable in polynomial time, and the structure satisfies (72) exactly when Φ \Phi Φ is satisfiable: a choice of relations S i S_i S i is the same thing as an assignment of the z z z , and ∀ y ˉ ψ \forall\bar{y}\,\psi ∀ y ˉ ψ holds exactly when every ψ v ˉ \psi_{\bar{v}} ψ v ˉ is true. Theorem 8.2 decides Φ \Phi Φ in time 2 ε μ poly ( μ + 2 k n r ) = 2 ε μ poly ( n ) 2^{\varepsilon\mu}\operatorname{poly}(\mu+ 2^k n^r) = 2^{\varepsilon\mu}\operatorname{poly}(n) 2 ε μ poly ( μ + 2 k n r ) = 2 ε μ poly ( n ) for every ε > 0 \varepsilon> 0 ε > 0 once μ ≥ n ε \mu\ge n_\varepsilon μ ≥ n ε , and the finitely many structures with μ < n ε \mu< n_\varepsilon μ < n ε are decided in constant time. □
Corollary 8.5. For every ε > 0 \varepsilon> 0 ε > 0 and every fixed k , q ≥ 2 k,q \ge2 k , q ≥ 2 , the satisfiability of a k k k -CNF formula with n n n variables and any number of clauses, and the q q q -colourability of a graph with n n n vertices, are decided deterministically in time 2 ε n poly 2^{\varepsilon n}\operatorname{poly} 2 ε n poly . More generally, every property expressed by a sentence (72) whose second-order variables are all unary is decided in time 2 ε t n poly ( n ) 2^{\varepsilon tn}\operatorname{poly}(n) 2 εt n poly ( n ) for every ε > 0 \varepsilon> 0 ε > 0 .
Proof. Both are in SNP with unary second-order variables [29 , 21 ] . For k k k -SAT take the variables as the universe and, for each of the 2 k 2^k 2 k sign patterns σ ∈ { 0 , 1 } k \sigma\in\{0,1\}^k σ ∈ { 0 , 1 } k , a k k k -ary input relation G σ G_\sigma G σ containing the tuples of variables of the clauses with that pattern; the sentence is ∃ T ∀ y 1 ⋯ y k ⋀ σ ( G σ ( y ˉ ) → ⋁ i ( T ( y i ) ↔ σ i = 1 ) ) \exists T \ \forall y_1 \cdots y_k \ \bigwedge_\sigma(G_\sigma(\bar{y}) \to\bigvee_i(T(y_i) \leftrightarrow\sigma_i = 1)) ∃ T ∀ y 1 ⋯ y k ⋀ σ ( G σ ( y ˉ ) → ⋁ i ( T ( y i ) ↔ σ i = 1 )) , with T T T the set of true variables, and μ = n \mu= n μ = n . For q q q -colourability take the vertices as the universe, the edge relation E E E , and ∃ C 1 ⋯ ∃ C q ∀ x ∀ y ( ( ⋁ i C i ( x ) ) ∧ ( E ( x , y ) → ⋀ i ¬ ( C i ( x ) ∧ C i ( y ) ) ) ) \exists C_1 \cdots\exists C_q \ \forall x \ \forall y \ ((\bigvee_i C_i(x)) \land(E(x,y) \to\bigwedge_{i} \neg(C_i(x) \land C_i(y)))) ∃ C 1 ⋯ ∃ C q ∀ x ∀ y (( ⋁ i C i ( x )) ∧ ( E ( x , y ) → ⋀ i ¬ ( C i ( x ) ∧ C i ( y )))) , with μ = q n \mu= qn μ = q n . The general statement is Theorem 8.4 with μ = t n \mu= tn μ = t n . □
Independent set, clique and vertex cover with a given threshold are not expressed by (72) without an auxiliary ordering, and we do not pursue that encoding: Corollary 6.8 already decides them for every graph with the explicit exponent n ( log log n ) 2 / ( log n ) 1 / 4 n(\log\log n)^2/(\log n)^{1/4} n ( log log n ) 2 / ( log n ) 1/4 , which is sharper than membership in SE.
What the method does not give
The summation routine needs three things of a factor system: scopes of size n O ( 1 ) n^{O(1)} n O ( 1 ) , occurrence numbers of size n O ( 1 ) n^{O(1)} n O ( 1 ) after the branching of Lemma 5.2, and total degree O ( n ) O(n) O ( n ) . The following problems fail one of them, and this paper proves nothing about them.
(a) Dense objectives. Max-Cut on a graph with Θ ( n 2 ) \Theta(n^2) Θ ( n 2 ) edges has total degree Θ ( n 2 ) \Theta(n^2) Θ ( n 2 ) and Θ ( n ) \Theta(n) Θ ( n ) occurrences per variable; branching on frequent variables fixes Θ ( n ) \Theta(n) Θ ( n ) of them. Theorem 7.20 reaches average degree o ( log n / log log n ) o(\sqrt{\log n/\log\log n}) o ( log n / log log n ) , and by Remark 7.27 no design for the routine reaches total degree 1 4 ( n + 1 ) log n \frac{1}{4}(n+1)\log n 4 1 ( n + 1 ) log n . Theorem 7.23 and Corollary 7.24 cover the dense graphs that differ in o ( n log n / log log n ) o\left(n\sqrt{\log n/\log\log n}\right) o ( n log n / log log n ) pairs from a graph whose adjacency is a quadratic form in o ( n / log n ) o(n/\log n) o ( n / log n ) vertex weights, a blow-up of a graph on o ( n / log n ) o(n/\log n) o ( n / log n ) vertices for instance; by Remark 7.25 these are almost no graphs, and G ( n , 1 2 ) G(n,\frac{1}{2}) G ( n , 2 1 ) is not among them. The chromatic and Tutte polynomials as polynomials in q q q need connectivity, which is not a bounded sum of local factors; Theorem 7.10 gives their values at each fixed positive integer q q q on bounded-degree graphs, and nothing off the hyperbolas H q H_q H q . § 6.2 shows that the independence polynomial escapes the density limit because a vertex of large degree forces many others; no such forcing is available for a cut.
(b) Problems in P with quadratic conjectured complexity. The lower bounds for Orthogonal Vectors, 3SUM, All-Pairs Shortest Paths and their relatives that were derived from the strong exponential time hypothesis lose their foundation, as OpenAI note; but the reductions that gave them run from CNF-SAT on n n n variables to instances of size 2 n 1 / 2 2^{n^{1/2}} 2 n 1/2 , and an algorithm with exponent o ( n ) o(n) o ( n ) for the former gives nothing below N 2 − o ( 1 ) N^{2-o(1)} N 2 − o ( 1 ) for the latter.
(c) P versus NP. A polynomial-time reduction from an arbitrary problem in NP to 3-SAT produces formulas with n C n^C n C variables for some C > 1 C>1 C > 1 , and 2 o ( n C ) 2^{o(n^C)} 2 o ( n C ) is not polynomial. Nothing in this paper bears on the question.
Each of the results of Sections 6, 7 and 8 has been stated with the exact hypothesis under which it is proved. The constants in the exponents are explicit through Lemma 4.7 , Theorem 5.1 and Theorem 7.19 , and the dependence on the weight bound Ω \Omega Ω is polynomial in every statement.
Appendix A. An exact-arithmetic check
No statement of the paper depends on a computation. The program described here was written to confirm, on instances small enough to be summed directly, that the algebraic identities of Sections 3 and 4 hold verbatim over a truncated polynomial ring, and it is supplied with the archive [7 ] .
The program builds a design with the parameters r = 2 r=2 r = 2 , Q = 3 Q=3 Q = 3 , R = 2 R=2 R = 2 , A 0 = 0 A_0=0 A 0 = 0 , far below the asymptotic regime of Lemma 4.7 , which is permissible because the identity H ( 0 ) = Z H(0)=Z H ( 0 ) = Z of Proposition 3.5 needs only the five conditions of Definition 3.1 and not the size bounds. The auxiliary set has D = r 2 Q = 64 D=r^{2Q}=64 D = r 2 Q = 64 elements; the measurement tuples are drawn from { 0 , … , R − 1 } τ n \{0,\ldots,R-1\}^{\tau n} { 0 , … , R − 1 } τ n with τ n = 2 \tau n=2 τ n = 2 ; the labels of Lemma 4.4 are chosen at random from a fixed seed and the conditions (4.15) and (3.4) are asserted, as is the fixed-point property of M 0 M_0 M 0 and the normalisation P u ( 0 ) = e u P_u(0)=e_u P u ( 0 ) = e u of Lemma 4.3 . Every number is a rational in lowest terms, every element of A N \mathcal{A}_N A N a list of N N N rationals, and every element of A N [ z ] / ( z J ) \mathcal{A}_N[z]/(z^J) A N [ z ] / ( z J ) a list of J J J such lists; the Hermite system is solved by exact Gaussian elimination.
Seven sums were computed on n = 6 n=6 n = 6 variables and compared with the direct sum over the 64 assignments: the number of satisfying assignments of a random 2-CNF with seven clauses over A = □ ∣ Q A=\square\!\!{\vphantom{\big|}\smash{\mathbb{Q}}} A = □ Q ; the Max-2-SAT profile of the same formula over Q [ W ] / ( W 8 ) \mathbb{Q}[W]/(W^8) Q [ W ] / ( W 8 ) , which came out as 4 W 3 + 8 W 4 + 28 W 5 + 16 W 6 + 8 W 7 4W^3+8W^4+28W^5+16W^6+8W^7 4 W 3 + 8 W 4 + 28 W 5 + 16 W 6 + 8 W 7 ; the independence polynomial 1 + 6 W + 8 W 2 + 2 W 3 1+6W+8W^2+2W^3 1 + 6 W + 8 W 2 + 2 W 3 of the hexagon with one chord, over Q [ W ] / ( W 7 ) \mathbb{Q}[W]/(W^7) Q [ W ] / ( W 7 ) , from the factor system of Theorem 6.7 ; the cut profile 2 + 12 W 2 + 18 W 3 + 18 W 4 + 12 W 5 + 2 W 7 2+12W^2+18W^3+18W^4+12W^5+2W^7 2 + 12 W 2 + 18 W 3 + 18 W 4 + 12 W 5 + 2 W 7 of the same graph, from the factor system of Corollary 6.4 with U = 1 U=1 U = 1 ; the weight enumerator 1 + 4 W 3 + 3 W 4 1+4W^3+3W^4 1 + 4 W 3 + 3 W 4 of the binary code of length 6 with the parity checks { 1 , 2 , 3 } \{1,2,3\} { 1 , 2 , 3 } , { 3 , 4 , 5 } \{3,4,5\} { 3 , 4 , 5 } , { 5 , 6 , 1 } \{5,6,1\} { 5 , 6 , 1 } , from the factor system of Theorem 7.12 ; the number 2 of nowhere-zero Z 3 Z_3 Z 3 -flows of K 2 , 3 K_{2,3} K 2 , 3 , from the factor system of Theorem 7.5(iv) over Q \mathbb{Q} Q , which agrees with Theorem 7.9 since the flow polynomial of K 2 , 3 K_{2,3} K 2 , 3 is ( q − 1 ) ( q − 2 ) (q-1)(q-2) ( q − 1 ) ( q − 2 ) ; and the objective profile 2 W + W 2 + 4 W 3 + 3 W 4 + 2 W 5 + 3 W 6 + W 8 2W+W^2+4W^3+3W^4+2W^5+3W^6+W^8 2 W + W 2 + 4 W 3 + 3 W 4 + 2 W 5 + 3 W 6 + W 8 of the 0-1 program with the rows 2 x 1 − x 2 + 3 x 3 ≤ 3 2x_1-x_2+3x_3\le3 2 x 1 − x 2 + 3 x 3 ≤ 3 , x 3 + x 4 + x 5 = 1 x_3+x_4+x_5=1 x 3 + x 4 + x 5 = 1 , x 1 + x 5 − x 6 ≥ 0 x_1+x_5-x_6\ge0 x 1 + x 5 − x 6 ≥ 0 and the cost vector ( 1 , 2 , 1 , 3 , 1 , 2 ) (1,2,1,3,1,2) ( 1 , 2 , 1 , 3 , 1 , 2 ) , from the factor system of Theorem 7.17 , over Q [ W ] / ( W 11 ) \mathbb{Q}[W]/(W^{11}) Q [ W ] / ( W 11 ) . All seven agreed with the direct sums.
The run took about twenty minutes in exact arithmetic, almost all of it in the sums (26) over the pairs ( E , U ) (E,U) ( E , U ) , whose number is the quantity C q C_q C q of (27) with q q q between 8 and 13.
A second program, also in exact integer and rational arithmetic and supplied with the archive, checks the finite statements behind § 7.9 : the inequality C q q q ( n − q ) n − q ≤ 2 q n n C_q q^q(n-q)^{n-q} \le2^q n^n C q q q ( n − q ) n − q ≤ 2 q n n of Lemma 3.4 for 1 ≤ n ≤ 200 1 \le n \le200 1 ≤ n ≤ 200 and 0 ≤ q ≤ n / 2 0 \le q \le n/2 0 ≤ q ≤ n /2 ; the identity (70) and the resulting transfer of cut profiles for every graph on at most six vertices, 33868 graphs, and for 200 weighted instances; the inequalities of the proof of Theorem 7.19 at 32 pairs ( λ , a ) (\lambda,a) ( λ , a ) with λ \lambda λ between 2 40 2^{40} 2 40 and 2 128 2^{128} 2 128 and θ ≤ 2 − 15 \theta\le2^{-15} θ ≤ 2 − 15 , where the asymptotic estimates are replaced by exact comparisons of integers; the degree 2 m 2m 2 m and the top coefficient ( − 2 ) m ( W − 1 ) m (-2)^m(W-1)^m ( − 2 ) m ( W − 1 ) m of Remark 7.27 for m ≤ 5 m \le5 m ≤ 5 ; the two values of the footnote to the proof of Theorem 7.1 ; and the identity (71) with the profile read off the generating function of Theorem 7.23 , on 300 random weighted instances, together with the representation of Corollary 7.24 for 200 perturbed blow-ups. All eight checks passed in a few seconds.
Declarations
Data and code availability
The sources of this paper and the exact-arithmetic program of Appendix A, with its recorded output, are available at https://github.com/creelie/eCon , release v1.4.0, archived at doi:10.5281/zenodo.23718560 .
Funding
No funding was received for conducting this study.
Declaration of competing interest
The author has no competing interests to declare that are relevant to the content of this article.
Declaration of generative AI and AI-assisted technologies in the manuscript preparation process
During the preparation of this work the author used Claude (Anthropic) to write and run the program of Appendix A and to draft text. After using this tool, the author reviewed and edited the content as needed and takes full responsibility for the content of the publication.
Formerly, Electro-Gravitational Space Propulsion Laboratory (EGSPL), Bhubaneswar, Odisha 751030, India
Formerly, University of Calcutta (Heramba Chandra College), 23/49 Gariahat Road, Golpark, Kolkata 700029, West Bengal, India
Email address: d.bhattacharjee@erl-forschung.de
Email address: itsdeep@live.com
Email address: eg spl@proton.me
URL: https://orcid.org/0000-0003-0466-750X