Approximating the chromatic polynomial is as hard as computing it exactly

We show that for any non-real algebraic number $q$ such that $|q-1|>1$ or $\Re(q)>\frac{3}{2}$ it is \textsc{\#P}-hard to compute a multiplicative (resp. additive) approximation to the absolute value (resp. argument) of the chromatic polynomial evaluated at $q$ on planar graphs. This implies \textsc{\#P}-hardness for all non-real algebraic $q$ on the family of all graphs. We moreover prove several hardness results for $q$ such that $|q-1|\leq 1$. Our hardness results are obtained by showing that a polynomial time algorithm for approximately computing the chromatic polynomial of a planar graph at non-real algebraic $q$ (satisfying some properties) leads to a polynomial time algorithm for \emph{exactly} computing it, which is known to be hard by a result of Vertigan. Many of our results extend in fact to the more general partition function of the random cluster model, a well known reparametrization of the Tutte polynomial.


Introduction
The study of (approximately) computing the chromatic polynomial, or in fact the more general Tutte polynomial 1 was initiated by Jaeger et al. (1990) over thirty years ago.Among other things they proved that evaluating the chromatic polynomial of a graph at any algebraic number q exactly is #P-hard except for q = 0, 1, 2. This was extended by Vertigan (2005) who showed that the same is true when restricted to planar graphs.The next step was taken by Goldberg & Jerrum (2008) who proved that it is NP-hard to approximate the chromatic polynomial at real values q > 2 (as part of a much larger result concerning inapproximability of the Tutte polynomial).As far as we know the complexity of approximating the chromatic polynomial at real q on planar graphs is open.See Goldberg & Jerrum (2012) for hardness result for evaluations of the Tutte polynomial on planar graphs 'close' to the chromatic polynomial.
Partly motivated by applications to quantum computing, Goldberg & Guo (2017) proved the first inapproximability results for certain non-real evaluations of the Tutte polynomial, showing #Phardness of approximating and not just NP-hardness.These results were recently extended in Galanis et al. (2022b) to a much larger family of evaluations and planar graphs.
So far, as far as we know, no inapproximability results were known for the chromatic polynomial at non-real values of q.For several graph polynomials, such as the independence polynomial and the partition function of the Ising model, recent developments in the study of approximate counting has indicated that approximating evaluations of these polynomials is computationally hard in the vicinity of the zeros of these polynomials Bezáková et al. (2020); Buys (2021); Buys et al. (2022); Chio et al. (2019); Galanis et al. (2022a); Peters & Regts (2019, 2020).Motivated by this connection and Sokal's famous result Sokal (2004) saying that the zeros of of the chromatic polynomial are dense in the complex plane, one might be tempted to conjecture that approximating the chromatic polynomial at non-real numbers should be hard.Our main result indeed confirms this.
1.1.Main results.Before we state our main result we first formally state the computational problems we are interested in and give the definition of the chromatic polynomial.
We denote the chromatic polynomial of a graph G = (V, E) by Z(G; q); it is defined as where k(A) denotes the number of components of the graph (V, A).For a positive integer q, Z(G; q) equal the number of proper qcolorings of G.
We will consider two types of approximation problems, one for the norm of Z(G; q) and one for its argument, for each algebraic number q separately.For a nonzero complex number ξ we will consider the argument arg(ξ) as an element of R/(2πZ) measuring the angle with the positive real axis.For a ∈ R/(2πZ) we denote |a| := min a ′ ∈a |a ′ |.
Let ξ be a complex number and η > 0. We call a number r ∈ Q an η-abs-approximation of ξ if ξ ̸ = 0 implies e −η ≤ r/ |ξ| ≤ e η .We call a number r ∈ Q an η-arg-approximation of ξ if ξ ̸ = 0 implies that |r − arg(ξ)| ≤ η.Note that in both cases an approximation of 0 could be anything.In Section 2.3 below we will indicate how we will represent algebraic numbers.Throughout graphs may have multiple edges between any pair of vertices and loops, unless stated otherwise.Consider for an algebraic number q the following computational problems.
Name: q-Planar-Abs-Chromatic Input: A planar graph G. Output: An 0.25-abs-approximation of Z(G; q).Name: q-Planar-Arg-Chromatic Input: A planar graph G. Output: An 0.25-arg-approximation of Z(G; q).We define the problems q-Abs-Chromatic,q-Arg-Chromatic in the same way except that the input for both problems may now be any graph.We note that these problems do not change in complexity when restricting to simple graphs, since the chromatic polynomial of a graph with a loop is constantly equal to 0 and the chromatic polynomial of a graph with no loops is equal to the chromatic polynomial of its underlying simple graph.
Note that by planar duality, this result also applies to the flow polynomial.
As an immediate consequence of Theorem 1.1, we obtain hardness for approximately computing the chromatic polynomial on the entire complex plane except the real line for the family of all graphs: Corollary 1.2.For each non-real algebraic number q ∈ C, the problems q-Abs-Chromatic and q-Arg-Chromatic are #Phard.
Proof.This follows the same argument as Sokal's density result Sokal (2004).We reduce the problems to their planar counterpart.Given a planar graph G. Clearly, we may assume that |q − 1| ≤ 1. Create a new graph Ĝ by adding three new vertices pairwise connected by an edge and connect each of these three vertices to all original vertices of G.It is well known and easy to see that Z( Ĝ; q) = q(q − 1)(q − 2)Z(G; q − 3).Denote q ′ = q − 3 and note that |q ′ − 1| = |(q − 1) − 3| > 1.So a polynomial time algorithm that solves the problem q-Abs-Chromatic (resp.q-Arg-Chromatic) can be used to solve q ′ -Planar-Abs-Chromatic (resp.q ′ -Planar-Arg-Chromatic) in polynomial time.Since the latter two problems are #P-hard by Theorem 1.1, the same holds for the former two.□ While the main focus of this paper is on the chromatic polynomial, we also derive results for the more general partition function of the random cluster model Z(G; q, y) := A⊆E (y − 1) |A| q k(A) , and the associated problems of approximating the value for fixed q, y on input of a planar graph G.In Theorem 3.12 we find a sufficient condition such that these problems are #P-hard, and in Corollary 3.13 we record some explicit ranges for q, y where the problems are #P-hard, which includes the result of Theorem 1.1.Figure 1.1 shows a region of q-values for which we could verify the condition in Theorem 3.12 with a computer.
As is well known, Z(G; q, y) is essentially equal to the Tutte polynomial T (G; x, y) for q = (x − 1)(y − 1).See e.g.Ellis-Monaghan & Moffatt (2022); Sokal (2005) for background.Thus Theorem 3.12 immediately gives us several inapproximability results for the Tutte polynomial on planar graphs.However, the cases x = 1 or y = 1, corresponding to q = 0, are not covered by our approach.(The case x = 1 corresponds to the all terminal reliability polynomial.)We comment on how our approach could be used to show to hardness of approximation for these cases in Section 6.
1.2.Proof outline.We sketch a proof outline here (only for the chromatic polynomial), leaving most of the technical details and definitions to later sections.Our proof goes along similar lines as other inapproximability results for non-real parameters obtained recently Bezáková et al. (2020); Buys et al. (2022); Galanis et al. (2022a,b); Goldberg & Guo (2017), but it also differs from these at certain steps.For example, in the previous works just mentioned the problem of approximate evaluation is reduced from exact evaluation of the polynomial/partition function at different parameters (often real) causing extra work to be done.One of our novel contributions is that we reduce exact evaluation at q (which by Vertigan ( 2005) is #P-hard) to approximate evaluation at the same parameter, yielding a very clean reduction.Our approach for this is quite robust and could be applied to other partition functions/graph Figure 1.1:The red-shaded region represents values of q for which the problems q-Planar-Abs-Chromatic and q-Planar-Arg-Chromatic are #P-hard.This is a pixel-picture with a 1001 × 1001 resolution.The region depicted in the figure ranges from −i to 2 + i.
polynomials.We say a bit more about this below.First we describe our approach.
The goal is to show that for a given algebraic number q, assuming the existence of a polynomial time algorithm for q-Planar-Abs-Chromatic or q-Planar-Arg-Chromatic, we can design a polynomial time algorithm to compute the evaluation of the chromatic polynomial at q exactly.This is essentially done in two steps.
The first step is to replace an edge e of a given graph G by another graph H (with two marked vertices) also called a gadget.The chromatic polynomial of the resulting graph G ′ is then, up to some easily computable factor (if the graph H is series-parallel for example), given by Z(G; q) + y H Z(G/e; q), where is y H the effective edge interaction of H (to be defined in the next section).If one can determine the value y * such that Z(G; q)+ y * Z(G/e; q) = 0, then this means that one can determine the ratio r = Z(G;q) Z(G/e;q) , assuming Z(G/e; q) ̸ = 0.A potential problem is when both Z(G/e; q) and Z(G\e; q) are equal to zero.Below we indicate how to overcome this difficulty.
In case q is real the value of y * can be approximated very accurately by means of a binary search procedure due to Goldberg & Jerrum (2014).Then, using that y * is an algebraic number of polynomial size, this implies one can in fact determine y * exactly in polynomial time.The binary search is done by applying the assumed polynomial time algorithm that approximately computes the absolute value or argument of Z(G ′ ; q) and using the output of this algorithm for various values of y to steer the binary search.We extend and simplify this binary search strategy to a procedure we call 'box shrinking', see Theorem 3.4 below, so that it applies to non-real q.Moreover, we modify it in way so that it allows us to determine if Z(G/e; q) is equal to 0 or not, provided not both Z(G/e; q) and Z(G \ e, q) are zero.Having this extra information allows us then to compute Z(G; q) exactly, writing it as a telescoping product.See Theorem 3.2 below for the details.
The box shrinking procedure requires us to be able to generate graphs H such that their effective edge interactions approximate any given y 0 ∈ Q[i] with very high precision fast.This brings us to the second step.As in Galanis et al. (2022b), we use seriesparallel graphs to achieve this.The approach to do this is partly based on Bezáková et al. (2020) and inspired by Bencs et al. (2023);de Boer et al. (2021).See Theorem 3.6 below for the precise statement of what we obtain.
The novel parts of our approach, the box shrinking procedure, Theorem 3.4, and Theorem 3.2, are quite robust and can for example be applied to the independence polynomial.Doing so, one reduces the problem of exactly evaluating the independence polynomial at some non-real fugacity parameter, which is #P-hard by Kowalczyk & Cai (2016), to approximately evaluating it.This would shorten and simplify the reduction used in Bezáková et al. (2020), where a reduction from evaluating the polynomial at 1 is used.
Organization In the next section we collect some definitions and results around series-parallel graphs and some notions regarding the representation of algebraic numbers.Then in Section 3 we state our two main technical contributions and combine these to give a proof of Theorem 1.1.Section 4 and Section 5 contain our proofs of these two contributions.Finally in Section 6 we conclude with some questions and problems left open by our work.

Preliminaries
In this section we set up some notation and introduce some basic notions that we will use.

Series-parallel graphs.
As mentioned in the introduction we will be using series-parallel graphs as gadgets.We introduce these here closely following Bencs et al. (2023) and thereby Royle & Sokal (2015) in their use of notation.
Let G 1 and G 2 be two graphs with designated start-and endpoints s 1 , t 1 , and s 2 , t 2 respectively, referred to as two-terminal graphs.The parallel composition of G 1 and G 2 is the graph G 1 ∥ G 2 with designated start-and endpoints s, t obtained from the disjoint union of G 1 and G 2 by identifying s 1 and s 2 into a single vertex s and by identifying t 1 and t 2 into a single vertex t.The series composition of G 1 and G 2 is the graph G 1 ▷◁ G 2 with designated start-and endpoints s, t obtained from the disjoint union of G 1 and G 2 by identifying t 1 and s 2 into a single vertex and by renaming s 1 to s and t 2 to t.Note that the order matters here.A two-terminal graph G is called series-parallel if it can be obtained from a single edge using series and parallel compositions.Note that series-parallel graphs are automatically connected.
From now on we will implicitly assume the presence of the startand endpoints when referring to a two-terminal graph G.We denote by G SP the collection of all series-parallel graphs.
2.2.Effective edge interactions.An important ingredient in our proof will be the notion of effective edge interaction.It requires a few preliminary definitions to define it.We extend these definitions from Bencs et al. (2023) to the partition function of the random cluster model.
Recall that for a positive integer q, any y ∈ C and a graph G = (V, E) we have Z(G; q, y) = ϕ:V →{1,...,q} uv∈E (1 + (y − 1)δ ϕ(u),ϕ(v) ), where δ i,j denotes the Kronecker delta.For a positive integer q and a two-terminal graph G, we can thus write, (2.1) Z(G; q, y) = Z same (G; q, y) + Z dif (G; q, y), where Z same (G; q, y) collects those contributions where s, t receive the same color and where Z dif (G; q, y) collects those contribution where s, t receive different colors.Since Z same (G; q, y) is equal to Z(G ′ ; q, y) where G ′ is obtained from G by identifying the vertices s and t, both these terms are polynomials in q and y.Therefore (2.1) also holds for any q ∈ C.
For fixed y ∈ C the effective edge interaction is defined as (2.2) y G (q, y) := (q − 1) Z same (G; q, y) Z dif (G; q, y) , which we view as a rational function in q and hence it takes values in the Riemann sphere C ∪ {∞}.(It might be slightly confusing that both the function and one of its inputs are called y.This is because y G will play a role similar as y.The name effective edge interaction stems from the fact that replacing all edges of a graph H with a 2-terminal graph G with effective edge interaction y G yielding the graph H(G) has the property that Z(H; q, y G ) = Z(H(G); q, y) up to a simple factor depending only on G.) We note that in case G contains an edge between s and t, the rational function q → y G (q, 0) is constantly equal to 0. If q, y are clear from the context we may occasionally just write y G for the effective edge interaction.
For any q ̸ = 0 define the following Möbius transformation f q (z) := 1 + q z − 1 and note that f q is defined on the Riemann sphere and is an involution, i.e. f q (f q (z)) = z for all z ∈ C ∪ {∞}, as follows by a direct calculation.Following Bencs et al. (2023), for a two-terminal graph G with effective edge interaction y G , we call f q (y G ) a virtual interaction.
The next lemmas are Lemma 1 and 3 from Bencs et al. (2023) and capture the behavior of the effective edge interactions under series and parallel compositions.Even though they were only stated for the chromatic polynomial in Bencs et al. (2023), their proof automatically extends to the more general setting of the partition function of the random cluster model.
An algebraic number a is by definition a complex number that is the zero of some polynomial with integer coefficients.The minimal polynomial of a is the unique polynomial p ∈ Z[x] of smallest degree such that p(a) = 0, whose coefficients have no common prime factors, and whose leading coefficient is positive when a ̸ = 0. Following Galanis et al. (2022a,b) we represent an algebraic number a by its minimal polynomial together with an open rectangle in the complex plane (defined by two rational intervals parallel to the real and imaginary axis respectively) such that a is the only zero of the polynomial in that rectangle.There is some ambiguity here, as many rectangles will do the job.However one can check whether two representations represent the same number, by checking if the polynomials are equal and checking if the two rectangles intersect and by counting the number of zeros in the intersection (using for example the algorithm of Wilf (1978)).When referring to an algebraic number we thus implicitly assume we have its minimal polynomial and a rectangle as above.The size of an algebraic number will thus be the number of bits needed to represent the minimal polynomial and the rectangle.
It is described in Strzeboński (1997) how to execute all basic operations, i.e., addition, subtraction, multiplication and inversion in terms of this representation.It can be seen that these operations can be executed in polynomial time in the representation sizes by combining a result from Mahler (1964), lower bounding the distance between roots of a polynomial, a result on using resultants to find polynomials with a prescribed zero Loos (1983), the famous factoring algorithm of Lenstra et al. (1982), a result of Mignotte (1974) bounding the coefficients of factors of polynomials, and an algorithm of Wilf (1978) finding the number of zeros of a polynomial in a rectangle.It follows that we can compare and compute absolute values of algebraic numbers and test whether two algebraic numbers are equal in polynomial time in their representation size.

Proof of the main results
In this section we state our main technical contributions, which we will prove in the subsequent sections.These results allow us to prove our main results at the end of this section.Let us first define for algebraic numbers q, y ∈ C the more general computational problems (q, y)-Planar-Abs-RC and (q, y)-Planar-Arg-RC, which on input of a planar graph G ask for an 0.25abs-approximation resp.an 0.25-arg-approximation to Z(G; q, y).The problems q-Planar-Abs-Chromatic and q-Planar-Arg-Chromatic are the particular cases (q, 0)-Planar-Abs-RC and (q, 0)-Planar-Arg-RC.
3.1.Telescoping.For a graph G and an edge e of G we denote by G \ e the graph obtained from e by removing the edge e and by G/e the graph obtained from G by contracting the edge e Recall that we allow multiple edges between two vertices and loops.We note here that the family of planar graphs is closed under deletion and contraction of edges.We recall the well known deletion contraction recurrence for a graph G and an edge e of G (contrary to the Tutte polynomial, this recurrence also holds when e is a bridge or a loop): (3.1) Z(G; q, y) = Z(G \ e; q, y) + (y − 1)Z(G/e; q, y).
If one can determine for any graph G and an edge e ∈ E(G) one of the ratios Z(G;q,y) Z(G/e;q,y) , or Z(G;q,y) Z(G\e;q,y) exactly, then one can compute Z(G; q, y) exactly by writing it as a telescoping product.A potential catch is that both Z(G; q, y) and Z(G/e; q, y) (and hence Z(G \ e; q, y) by (3.1)) could equal zero.Under suitable assumptions, our next result is able to deal with this issue.In what follows we denote for a graph H by size(H) the sum of the number of vertices of H and the number of edges of H. Theorem 3.2.Let q, y be fixed algebraic numbers, with q ̸ = 0. Suppose that we have access to an algorithm that on input of a planar graph G and an edge e ∈ E(G) outputs an algebraic number r and a number b ∈ {0, 1} in polynomial time in size(G) such that (1) If Z(G/e; q, y) ̸ = 0, then b = 1 and r = Z(G;q,y) Z(G/e;q,y) ; (2) if Z(G/e; q, y) = 0 and Z(G \ e; q, y) ̸ = 0, then b = 0 and r = 1; (3) if both Z(G/e; q, y) and Z(G \ e; q, y) are zero, then the algorithm may output any algebraic number r and bit b.Then there is an algorithm to compute Z(G; q, y) in polynomial time in size(G).
Proof.We construct a sequence of planar graphs G 0 , . . ., G m , where G m is a graph with no edges, as follows.We let G 0 = G.Now for i ≥ 0, we apply the assumed algorithm to the graph G i and an edge e i of G i .Assume the algorithm outputs the pair (r i , b i ).
Let n denote the number of vertices of G m .The output of our algorithm will be the number q n m−1 i=0 r i .Since m is at most the number of edges of G and since size(G i ) ≤ size(G 0 ) for each i, this clearly takes polynomial time in size(G) to compute.
What remains to show is that To prove (3.3), let us first assume that Z(G 0 ; q, y) = 0. Then we do not know whether or not we can trust the output of the algorithm, as possibly both Z(G/e 0 ; q, y) and Z(G \ e 0 ; q, y) could be zero.However, there is a smallest index i such that Z(G i ; q, y) ̸ = 0 (since Z(G m ; q, y) = q n ̸ = 0).In this case we know that Z(G i−1 ; q, y) = 0 and hence b i−1 = 1, G i = G i−1 /e i and thus r i−1 = 0 as well.Therefore (3.3) holds in this case.
Let us next assume that Z(G 0 ; q, y) ̸ = 0.In that case one of the two values Z(G/e 0 ; q, y), Z(G \ e 0 ; q, y) must be non-zero by (3.1).This means we are in case (1) or (2) and hence if b = 1, G 1 = G 0 /e 0 , and it holds that Z(G 1 ; q, y) ̸ = 0 while if b = 0, G 1 = G 0 \ e 0 , and it holds that Z(G 1 ; q, y) ̸ = 0.By induction it follows that for all i, Z(G i , q, y) ̸ = 0 and thus r i ̸ = 0 for all i.Next observe that This finishes the proof.□ This result and its proof are fairly general and do not really rely on specific properties of the partition function of the random cluster model, but could equally well be applied to other polynomials and partition functions that satisfy some recurrence relation such as the independence polynomial for example.

Implementing gadgets.
In the previous subsection we indicated that if one can test whether Z(G/e; q, y) is zero or not and compute the ratios Z(G;q,y) Z(G/e;q,y) exactly this gives rise to an algorithm to exactly compute Z(G; q, y).
The idea from Goldberg & Jerrum (2014) for real valued parameters is to use approximations to ŷZ(G/e; q, y) + Z(G; q, y) to steer a binary search procedure to obtain a very precise approximation to the value y * which satisfies y * Z(G/e; q, y) + Z(G; q, y) = 0, or in other words the ratio − Z(G;q,y) Z(G/e;q,y) .The following result describes the outcome of our box shrinking procedure, which extends this binary search procedure to complex parameters and moreover simplifies it.(It may be helpful to think of A = Z(G/e; q, y) and B = Z(G; q, y) in the statement of the theorem below.) For r > 0 and Theorem 3.4.Let A, B be complex numbers and let C > 0 be a rational number such that |A| and |B| are both at most C, and both are either 0 or at least 1/C.Assume one of the following: • there exists a poly(size(y 0 , ε))-time algorithm to compute on input of y 0 ∈ Q[i] and a rational number ε > 0 an 0.25abs-approximation of Aŷ + B for some algebraic number ŷ ∈ B(y 0 , ε), or, • there exists a poly(size(y 0 , ε))-time algorithm to compute on input of y 0 ∈ Q[i] and a rational number ε > 0 an 0.25arg-approximation of Aŷ + B for some algebraic number ŷ ∈ B(y 0 , ε).Then there exists an algorithm that on input of a rational δ > 0 and C > 0 as above that outputs "A = 0" when A = 0 and B ̸ = 0, and that outputs "A ̸ = 0" and a number y ∈ Q[i] such that −B/A ∈ B ∞ (y, δ/2) when A ̸ = 0.When A = B = 0 it is allowed to output anything.The running time is poly(size(C, δ)).
We will prove Theorem 3.4 in Section 5. To utilize it we must be able to generate for any given value y 0 a number ŷ that approximates y 0 with arbitrary precision in a way that we can approximate the norm or argument of ŷZ(G/e; q, y) + Z(G; q, y) efficiently.The idea, going back to Goldberg & Guo (2017), is to use certain seriesparallel gadgets for this task.
For fixed values of q, y, we call a series-parallel graph H a seriesparallel gadget for (q, y) if Z dif (H; q, y) ̸ = 0. Let G be a graph with a designated edge e = {u, v}, and let H be a series-parallel gadget for (q, y).Then we construct the graph G ′ obtained from G and H by removing the edge e from G and identifying the start vertex of H with u and the terminal vertex with v.Note that by flipping u and v this may result in a different graph.We call any such graph an implementation of H in G on e. See Figure 3.1 for an illustration.
The next result says that with access to an algorithm that efficiently solves (q, y)-Planar-Arg-RC or (q, y)-Planar-Abs-RC, we can efficiently approximate ŷZ(G/e; q, y) + Z(G; q, y) for any value ŷ + y that is the effective edge interaction of a seriesparallel gadget.
Proof.We will see G as a two-terminal graph, with the endpoints of e being the terminals.In this case by definition, we have that Let G ′ denote an implementation of H in G on e and observe that G ′ is planar.We compute using Lemma 2.3, Z(G ′ ; q, y) = 1 q Z same (G \ e; q, y)Z same (H; q, y) q(q−1) (q − 1) Z same (H;q,y) Z dif (H;q,y) Z(G/e; q, y) + Z(G; q, y) − yZ(G/e; q, y) = Z dif (H;q,y) q(q−1) ((y H (q, y) − y)Z(G/e; q, y) + Z(G; q, y)) .
As H is a gadget we know that Z dif (H; q, y) ̸ = 0, and we have its exact value as input of the algorithm.
We then use the assumed algorithm to compute an 0.25-absapproximation of Z(G ′ ; q, y).Multiplying the output by q(q−1) Z dif (H;q,y) produces an 0.25-abs-approximation of (y H (q, y) − y)Z(G/e; q, y) + Z(G; q, y).
Similarly, if we use the assumed algorithm to compute an 0.25arg-approximation of Z(G ′ ; q, y) and add arg q(q−1) Z dif (H;q,y) to the output, we obtain an 0.25-arg-approximation of (y H (q, y) − y)Z(G/e; q, y) + Z(G; q, y) in poly(size(G, H))-time. □ In order to obtain a desired algorithm for Theorem 3.4 using Lemma 3.5 we need to be able to quickly approximate any desired value y 0 with effective edge interactions of gadgets.This final ingredient is Theorem 3.6, which will be proved in Section 4.
To do this precisely, we limit ourselves to a slightly smaller family of series-parallel graphs.Define H * q,y to be the family of all series-parallel graphs H that satisfy y H (q, y) ̸ ∈ {1, ∞} and Z dif (H; q, y) ̸ = 0.
Theorem 3.6.Let (q, y) ∈ C 2 \ R 2 be algebraic numbers such that q ̸ ∈ {0, 1}.Assume there exists G ∈ H * q,y for which y G (q, y) or f q (y G (q, y)) is finite and has absolute value strictly bigger than 1.There exists an algorithm that for every y 0 ∈ Q[i] and rational ε > 0 outputs a series-parallel graph H ∈ H * q,y such that y H (q, y) ∈ B(y 0 , ε), and outputs the number Z dif (H; q, y).Both the running time of the algorithm and the size of the graph are poly(size(ε, y 0 )).
3.3.Proof of Theorem 1.1.In this section we combine all ingredients mentioned above to provide a proof of Theorem 1.1 To utilize these ingredients, we need to introduce some concepts regarding algebraic numbers.We closely follow Galanis et al. (2022b) in doing so.
We will introduce these concepts for polynomials with integer coefficients, and then automatically obtain definitions for algebraic numbers by applying the definition to their minimal polynomial.In particular, we can talk about the degree d(α) of an algebraic number α.We further define several variants of the height of a polynomial p ∈ Z[x]: the usual height H(p) is the largest absolute value among the coefficients, and the length L(p) is the sum of the absolute value of the coefficients (similarly we define these notions for multi-variable polynomials).If we let d be the degree of p, let a d be the leading coefficient of p and let α i be the roots of p, From the definitions we can deduce for any algebraic number α that d(1/α) = d(α), h(1/α) = h(α), and for every rational function The next lemma records some more intricate results about these heights, and gives some bounds for algebraic numbers of bounded height.Note in particular that item (b) yields the special case h(α 1 α 2 ) ≤ h(α 1 ) + h(α 2 ) for any algebraic numbers α 1 , α 2 .Lemma 3.7.(a) For any non-zero algebraic number α we have (b) Let p ∈ Z[x 1 , . . ., x t ] be a polynomial, α 1 , . . ., α t algebraic numbers, and define the algebraic number β = p(α 1 , . . ., α t ).
Write d i (p) for the degree of p as polynomial in x i , then Proof.All parts can be found in Waldschmidt (2013): parts (a) and (b) are respectively in Section 3.5.1 and Lemma 3.7; part (c) is in Lemma 3.11 for the special case that p is irreducible, but the proof works for any polynomial p. □ Corollary 3.8.Let q, y be algebraic numbers and let G be a graph with n vertices and m edges.Write d, h q , h y for respectively d(q) • d(y), h(q), h(y).
Proof.Let G = (V, E) be our graph, then let us recall the definition Z(G; q, y) = A⊆E q k(A) (y − 1) |A| .From this we see that Z(G; q, y) is a polynomial of degree n in q and degree m in y −1.In the variables q and y − 1, we also see that the sum of the absolute value of the coefficients is 2 m .Note that part (b) of the previous lemma gives h(y − 1) ≤ h(y) + log(2), and applying it again to Z gives h(Z(G; q, y)) ≤ m log(2) + nh q + m(h y + log(2)).Further d(Z(G; q, y)) ≤ d.Then by part (a) when Z(G; q, y) ̸ = 0, we see that log(|Z(G; q, y)|) ≤ (nh q + mh y + 2m log(2))d, proving part (a).
For part (b) we first look at the absolute logarithmic height of the ratio.We have h Z(G; q, y) Z(G/e; q, y) ≤ h(Z(G; q, y)) + h(Z(G/e; q, y)) Again the ratio has degree at most d, so part (c) of the previous lemma gives log H Z(G; q, y) Z(G/e; q, y) ≤ h Z(G; q, y) Z(G/e; q, y) The following result follows from a slight modification of a result of Kannan et al. (1988).
There exists an algorithm that on input d, H and α outputs a polynomial p such that if there exists an algebraic number α of degree at most d, height at most H such that log(|α − α|) ≤ −(d 2 + 5d + 2d log(H)), then p is the minimal polynomial of α.The running time is bounded by poly(d, log(H), size(α)).
Proof.We first describe the algorithm and then prove its correctness.
We first assume |α| ≤ 1.We will apply Algorithm 1.16 from Kannan et al. (1988).If the algorithm terminates within d steps and outputs a polynomial p, we output p.If after d steps the algorithm does not return anything we output 0. If |α| ≥ 1 we replace α by 1/α and we refer to the proof (Kannan et al. 1988, Theorem 1.19) how to modify the output of Algorithm 1.16 in this case.
To prove correctness, we may assume |α| ≤ 1 and we may further assume there exist an algebraic number α of degree at most d and height at most H such that Otherwise there is nothing to prove.We next note that as d ≥ 2 we have therefore there exists a non-negative integer s ≥ 2 such that (3.11) If |α| ≤ 1 the conclusion follows immediately from the correctness of (Kannan et al. 1988, Algorithm 1.16).Unfortunately we do not have this information, but we will argue that even in the case |α| > 1 the algorithm is still correct.We will show that by assuming that a bound of 1 + 1/(2d) on |α| is sufficient.By (3.10) and (3.11) this bound is clearly satisfied and it implies that for any k = 1, . . ., d, |α| k ≤ 2. With this bound on |α| (Kannan et al. 1988, Proposition 1.6) remains true if we multiply the right-hand side by 1/2.By our slightly stronger lower bound on s we see that also the conclusion of (Kannan et al. 1988, Lemma 1.9) is also valid for this bound on |α|.Finally as in (Kannan et al. 1988, Explanation 1.17) the conditions of (Kannan et al. 1988, Theorem 1.15) are still met for this bound on |α|.Therefore the output of (Kannan et al. 1988, Algorithm 1.16) is indeed the minimal polynomial of α, as desired The running time bound follows from (the proof of) Theorem 1.19 from Kannan et al. (1988) where we note that Kannan et al. (1988) in fact does not require the input of the number α, but only a certain number of bits of it and therefore the size of α does not appear in the running time of the statement of the theorem.To avoid dealing with how to feed α to the algorithm we just allow the algorithm to 'read' it completely.□ Now we are ready to prove the following result, from which we will derive Theorem 1.1 after giving the proof.For the theorem let us recall that H * q,y is the family of all series-parallel graphs H that satisfy Z dif (H; q, y) ̸ = 0 and y H (q, y) ̸ ∈ {1, ∞}.
Proof.We will assume there exists a polynomial-time algorithm for either the problem (q, y)-Planar-Abs-RC or (q, y)-Planar-Arg-RC, and then we will find a poly(size(G))-time algorithm to compute Z(G; q, y) exactly for planar graphs G. Since the latter problem is #P-hard by Vertigan ( 2005), apart from several exceptional values, this implies that (q, y)-Planar-Abs-RC and (q, y)-Planar-Arg-RC are #P-hard as well.The exceptional values are y = 1, q = 0, 1, 2, (q, y) = (3, e ± 2πi 3 ) and (q, y) = (4, −1).We explicitly excluded most of them in the statement, while for y = 1 the family H * q,y is empty, and for (q, y) = (3, e ± 2πi 3 ) we can show that y G (q, y) is contained in {e 2πi 3 , e − 2πi 3 } for any G ∈ H * q,y (see the proof of Corollary 3.13 below).The proof essentially consists of linking together Theorem 3.6, Lemma 3.5, Theorem 3.4, Corollary 3.8, Proposition 3.9 and Theorem 3.2, roughly in that same order.
To keep track of the running times of all the separate algorithms we describe and analyze the resulting algorithm in one go and prove its correctness afterwards.
The assumption in the theorem means that we can apply Theorem 3.6 to find a gadget F with effective edge interaction y F close to y 0 + y for any y 0 (note that size(y 0 + y) = O(size(y 0 ))).We use F and Z dif (F ; q, y) in Lemma 3.5 to approximate (y F − y)Z(G/e; q, y) + Z(G; q, y).Combined we obtain an algorithm that on input of y 0 ∈ Q[i], rational ε > 0, planar graph G and an edge e, will compute an 0.25-abs-approximation (resp.0.25arg-approximation) to ŷZ(G/e; q, y)+Z(G; q, y) for some algebraic number ŷ ∈ B(y 0 , ε), in poly(size(G, y 0 , ε))-time.
As in Corollary 3.8, we write h q , h y for the absolute logarithmic height of q and y, and d = d(q)d(y).We now want to apply Theorem 3.4 with A = Z(G/e; q, y) and B = Z(G; q, y).To do so we must find an common upper bound for them.Note that by Corollary 3.8, we have that | log(|A|)| and | log(|B|)| are both bounded by (nh q + mh y + 2m log(2))d, where n resp.m denote the number of vertices resp.edges of G. Now taking C such that log(C) = (nh q + mh y + 2m log(2))d we satisfy the assumption of Theorem 3.4.We thus have that C = O(size(G)) (since q, y and hence h q , h y , d are considered to be constant).
We now turn this algorithm into an algorithm as required in Theorem 3.2.In case we get "A = 0", we output the pair (0, 1).In case we get "A ̸ = 0", we run the algorithm of Proposition 3.9 on input of d, H and −y and let p be the output of this algorithm.We output the pair (1, (p, B ∞ (−y, δ/2))).The running time is poly(size(G)), using that h q , h y , d are constants and the size of y is poly(size(G)).This implies that the overall running time is poly(size(G)), as desired.
We next turn to proving correctness of our algorithm.What remains is to show that the algorithm as required in Theorem 3.2 is correct.If both Z(G/e; q, y) and Z(G \ e; q, y) are 0, there is nothing to prove.So let us first assume that Z(G/e; q, y) = 0 and Z(G \ e; q, y) ̸ = 0. Then by correctness of Theorem 3.4 we know that our algorithm gives the desired output, namely the pair (0, 1).Similarly, if Z(G/e; q, y) ̸ = 0, then by Corollary 3.8(b) we know that y * = −Z(G; q, y)/Z(G/e; q, y) is an algebraic number of degree at most d and height at most H and by correctness of Theorem 3.4 it is contained in B ∞ (y, δ/2)).Therefore, by our choice of δ, Proposition 3.9 implies that p is indeed the minimal polynomial of −y * in this case.By a result of Mahler (1964), the absolute value of the logarithm of the distance between any two distinct zeros of p is upper bounded by Therefore the rational rectangle B ∞ (−y, δ/2) together with p is a representation of the algebraic number −y * , and so the output of our algorithm is as desired.This finishes the proof.□ In the following corollary, we indicate several regions of q, yparameters for which Theorem 3.12 applies.Part (a) includes the (complex-valued) ferromagnetic Potts model.Theorem 1.1 is included in part (b).Note that part (b) also contains Theorem 1.5 in Galanis et al. (2022b), our methods merely give a different proof.Note however that part (b) is not tight, as Figure 1.1 shows a larger region of q-values where both problems are #P-hard.Corollary 3.13.Let (q, y) ∈ C 2 \ R 2 be algebraic numbers, such that q ̸ ∈ {0, 1, 2}.The problems (q, y)-Planar-Abs-RC and (q, y)-Planar-Arg-RC are #P-hard in both of the following cases: (a) |y| > 1; (b) |1 − q| > 1 or ℜ(q) > 3/2, except when y = 1 or (q, y) = (3, e ± 2πi 3 ).
Proof.For part (a), we simply have to note that K 2 ∈ H * q,y and y K 2 (q, y) = y, so the graph K 2 satisfies the requirement of Theorem 3.12.
For part (b), the assumption yields that either f q (0) = 1 − q or f q (f q (0) 2 ) = q−1 q−2 will have absolute value strictly bigger than 1.This means that if we find a y G or a f q (y G ) close to these values, we can apply Theorem 3.12.
In what follows we implicitly use Lemma 2.4 and Proposition 4.1 to see that certain numbers are the virtual or effective edge interaction of some series-parallel graph in H * q,y .We assume y ̸ = 1, which ensures that the family H * q,y is non-empty.If there now exists a graph G in this family with |y G | > 1, we are done.However, if |y G | < 1, its powers converge to 0. This means that for N large enough, one of f q (y N G ) and f q (f q (y N G ) 2 ) will have absolute value strictly bigger than 1, and both are the (virtual) interaction of a series-parallel graph in H * q,y .So we are left with the case that |y G | = 1 for all G ∈ H * q,y .Applying the same argument to f q (y G ), we may even assume that |f q (y G )| = 1 for all G ∈ H * q,y .Geometrically, the equations |z| = 1 and |f q (z)| = 1 give a circle and a line in the complex plane, so there can be at most two common solutions z.This means that the sets {y G (q, y) | G ∈ H * q,y } and {f q (y G (q, y)) | G ∈ H * q,y } both contain at most two elements.From Lemma 2.4 and Proposition 4.1 below it follows that both sets are closed under taking products, as long as the product is not 1.Therefore the only options for both sets are {−1} and {e 2πi 3 , e − 2πi 3 }, corresponding to (q, y) ∈ {(4, −1), (3, e 2πi 3 ), (3, e − 2πi 3 )}.All these options are excluded, so we conclude that this special case cannot occur.□

Constructing series-parallel gadgets
In this section we will prove Theorem 3.6.

4.1.
A family of potential gadgets.We start by exhibiting a family of series-parallel graphs that can serve as gadgets.Let (q, y) ∈ C 2 and recall that we denote by H * q,y the family of all series-parallel graphs H that satisfy Z dif (H; q, y) ̸ = 0 and y H (q, y) ̸ ∈ {1, ∞}.Note that if y = 1, the family H * q,y is always empty; while for y ̸ = 1 and q ̸ ∈ {0, 1}, the edge K 2 is contained in H * q,y .The next result says that this family is more or less closed under taking parallel and series composition.
The proof for H = H 1 ▷◁ H 2 is similar, we first recall from Lemma 2.3: Z(H; q, y) = 1 q • Z(H 1 ; q, y) • Z(H 2 ; q, y), Z same (H; q, y) = 1 q • Z same (H 1 ; q, y) • Z same (H 2 ; q, y) Suppose that Z dif (H; q, y) = 0.This implies that Z same (H; q, y) = 0, since y H ̸ = ∞.Therefore Z(H; q, y) = 0, and it follows without loss of generality that Z(H 2 ; q, y) = 0.So Z same (H 2 ; q, y) = −Z dif (H 2 ; q, y), and they are non-zero by assumption.Plugging this into the second equation, together with Z same (H; q, y) = 0, yields (q − 1)Z same (H 1 ; q, y) = Z dif (H 1 ; q, y).We also assumed that Z dif (H 1 ; q, y) ̸ = 0, leading to y H 1 (q, y) = 1, which is a contradiction.Therefore we can again conclude that H ∈ H * q,y .□ 4.2.Values of q, y with dense set of interactions.In this subsection we determine for which values of q, y the effective edge interactions of members of H * q,y are dense in the complex plane.The next subsection deals with making this algorithmic yielding a proof of Theorem 3.6.
The following lemma will turn out to be useful to get density results.We say that a set Proof.For any z ∈ C we can write z = ra + sb + tc with r, s, t ≥ 0. We can even assume that one of r, s, t is zero, say t = 0. Now we round r, s to the nearest integers R, S. Then Ra + Sb ∈ aN + bN and Recall the definition f q (z) = 1 + q z−1 .Also when G is a twoterminal graph, we call f q (y G (q, y)) its virtual interaction.
Proposition 4.3.Let (q, y) ∈ C 2 \ R 2 , such that q ̸ ∈ {0, 1}.Assume there exists a series-parallel graph G ∈ H * q,y such that y G (q, y) or f q (y G (q, y)) is finite and has absolute value strictly bigger than 1, then the set {y H (q, y) | H ∈ H * q,y } is dense in C.
Proof.We start by showing that we may assume that In what follows we implicitly use Lemma 2.4 and Proposition 4.1 to conclude that certain numbers are the virtual or effective edge interaction of some seriesparallel graph in H * q,y .

First assume that |y
2y+q−2 is also non-real (note that y ̸ = 1 because H * q,y is non-empty).This means that f q (f q (y) 2 )ξ n is non-real and converges to infinity as n → ∞.In either case we find a non-real term in the sequence with absolute value bigger than 1, which is the effective edge interaction of a graph in H * q,y .The precise graphs is a parallel composition of sufficiently many copies of G, together with either one edge or one path of length 2.
For the second case, assume that |y G | > 1 and y G is not real.Then powers of y G converge to ∞ and moreover the arguments (modulo 2π) of these powers take on at least 3 values.If the number of these values is unbounded, it is clear that for some n, f q (y n G ) is non real and |f q (y n G )| > 1.Otherwise, if these values take on precisely k ≥ 3 values, the values y n G converge towards ∞ on the k rays from 0 through e 2πj/k , j = 0, . . ., k − 1.The images of these rays under f q are circular arcs from f q (∞) = 1 to f q (0) = 1 − q making pairwise angles of 2π/k at 1. Since k ≥ 3, at least one of these arcs contains a open segment starting at 1 that does not intersect the closed unit disk.Any element from this segment has absolute value bigger than 1, thus there exists a series-parallel graph G ′ ∈ H * q,y such that |f q (y G ′ )| > 1, that is the parallel composition of sufficiently many copies of G.
Let τ be a non-real element of {f q (y), f q (y 2 )} = {1 + q y−1 , 1 + q (y−1)(y+1) }.Then τ • ξ n is not real, converges to infinity, and all are virtual interactions of graphs in H * q,y corresponding to series composition of copies of G with either an edge or a digon (two parallel edges).Therefore we will find one of absolute value more than 1, as desired.
From now on we thus assume that we have G ∈ H * q,y such that f q (y G ) is not real and |f q (y G )| > 1.Consider next the Möbius transformation Note that z = 1 is a fixed point of g and that g ′ (1) = 1/f q (y G ).So by assumption |g ′ (1)| < 1.Now consider the sequence defined by y 1 = y G and y i+1 = g(y i ), which converges to 1.The only reason that this could not be true is if y G would be equal to the other (repelling) fixed point of g.The other fixed point of g is given by 1 We next claim that taking finite products of terms in this sequence, produces a dense subset of C. Indeed, note that log(y i+1 ) log as i → ∞.Since the number 1/f q (y G ) is non-real, at some point the difference between the arguments of the log(y i ) lie in a small interval around arg(1/f q (y G )), which is nonzero mod π.In particular, this means that for any k the argument of the sequence (log(y i )) i≥k cannot be contained in a half plane.Then for every ε > 0, we can find three terms in the sequence that satisfy the requirements of Lemma 4.2.This lemma then implies that products of the values y i are dense in C.These products correspond exactly to parallel compositions of series connections of G by Lemma 2.4.By omitting any effective edge interactions equal to 1 possibly obtained by taking products of the y i we still obtain density and since the corresponding 2-terminal graphs are contained in H * q,y , this finishes the proof.□ 4.3.Implementing a dense set fast.In the previous subsection we saw for which values of q, y we can obtain density.We will This ensures that for any u ∈ U , the map z → g(z)u is a contraction on U .
Restricting to effective edge interactions y H (q, y) contained in U for H ∈ H * q,y , we see that by Proposition 4.3 the open sets g(U )y H cover the compact set U .By the proof of Proposition 4.3 we can select a finite set {y i | i ∈ I} in finite time such that ∪ i∈I g(U )y i already covers U .Now the Φ i are defined to be the maps z → g(z)y i .Let us fix for each i ∈ I a series-parallel graph H i ∈ H * q,y whose effective edge interaction is equal to y i .Using Lemma 2.3, we also compute Z same (H i ; q, y) and Z dif (H i ; q, y).
We now give a proof of Theorem 3.6.
Proof (Proof of Theorem 3.6).We first consider the case where y 0 ∈ U .We take as starting point y 1 = 1 in U and run the algorithm of Lemma 4.5.This yields in poly(size(y Otherwise we replace the sequence by i j+1 , . . ., i k with j the largest index for which Φ From the sequence i 1 , . . ., i k we can determine a sequence of series-parallel graphs G 1 , . . ., G k .The sequence starts with G 1 = H i 1 , which has effective edge interaction Φ i 1 (1) = y i .Recall that every map Φ i is of the form z → y i g(z), which by Lemma 2.4 corresponds to a series composition with G, and a parallel composition with a graph in {H i | i ∈ I}.So we let G j = (G j−1 ▷◁ G) ∥ H i j , then H := G k has effective edge interaction ŷ.Since G and H i only depend on q, y they have constant size, and therefore the size of H is O(log(ε −1 )).
Using Lemma 2.3 we inductively compute Z same and Z dif of G j in poly(k)-time, so we can output Z dif (H; q, y) along with H.
By construction ŷ ∈ B(y 0 , ε), so to prove correctness of the algorithm in this case it suffices to show that H is indeed a gadget, that is, Z dif (H; q, y) ̸ = 0. To do so we will inductively show that G j ∈ H * q,y using Proposition 4.1 and thereby in particular that Z dif (G j ; q, y) ̸ = 0. Note that G 1 = H i 1 ∈ H * q,y by assumption.Continuing inductively, if G j−1 ∈ H * q,q , then the series composition of G j−1 with G is in H * q,y since its effective edge interaction is not equal to 1 as g(z) = 1 if and only if z = 1.Its effective edge interaction is contained in U and therefore not equal to ∞.Next taking the parallel composition with H i j results in the seriesparallel graph G j contained in H * q,y , as its effective edge interaction is contained in U and therefore not equal to ∞; it is not equal to 1 by construction.Now we turn to the second case where y 0 ̸ ∈ U and y 0 ̸ = 0.The algorithm first determines a positive integer n such that y 0 = u n 0 for some u 0 ∈ U .Then it runs the algorithm for the first part on input of u 0 and error parameter to obtain a series-parallel graph H ′ ∈ H * q,y with effective edge interaction û ∈ B(u 0 , δ).We then output the series-parallel graph H obtained as the n-fold parallel composition of H ′ with itself, which has effective edge interaction ûn , and we output Z dif (H; q, y) computed using Lemma 2.3.Clearly H ∈ H * q,y .To prove that the algorithm is also correct in this case, first note The output of first procedure, û, satisfies This means that with our choice of δ we have The computation of û has a running time of poly(size(u 0 , δ)), which by construction is poly(size(y 0 , ε)).The series-parallel graph H corresponding to ûn is the parallel composition of n copies of the graph corresponding to û.The number of edges in the gadget is thus O(n log(δ −1 )) = poly(size(ε, y 0 )).In the next two lemmas we record important observations about this procedure.The first says we have a good understanding of the midpoint and radius of the resulting box, and the second says we are guaranteed to retain the zero y * in our box.Proof.We prove the cases S = S abs and S = S arg separately.
Case 1[S = S abs ] In this case we write f for fabs .Suppose that y * ̸ ∈ S(B ∞ (m, D)), we will reach a contradiction and thereby prove the lemma.We may assume wlog that f (ŷ 1 ) ≤ f (ŷ 2 ), but that y * is in the strip of width 1 4 D at the right side of the box.Note that ŷ1 and ŷ2 are certainly not equal to y * .
Then we see that Including the uncertainty in ŷi versus y i yields that Putting this together yields which proves that f (ŷ 1 )/ f (ŷ 2 ) > 1.This contradicts f (ŷ 1 ) ≤ f (ŷ 2 ), completing the proof of Case 1.
Case 2 [S = S arg ] In this case we write f for farg .Suppose that y * ̸ ∈ S(B ∞ (m, D)), we will again reach a contradiction.This time we may assume that f (ŷ 1 ) − f (ŷ 2 ) is in the interval (0, π), but that y * is in the strip of width 1 4 D at the top of the box.We setup some notation and we can interpret this geometrically as the angle between the segments ŷ1 to y * and ŷ2 to y * , measured clockwise from ŷ2 to ŷ1 .
Theorem 3.4.Let A, B be complex numbers and let C > 0 be a rational number such that |A| and |B| are both at most C, and both are either 0 or at least 1/C.Assume one of the following: • there exists a poly(size(y 0 , ε))-time algorithm to compute on input of y 0 ∈ Q[i] and a rational number ε > 0 an 0.25abs-approximation of Aŷ + B for some algebraic number ŷ ∈ B(y 0 , ε), or, • there exists a poly(size(y 0 , ε))-time algorithm to compute on input of y 0 ∈ Q[i] and a rational number ε > 0 an 0.25arg-approximation of Aŷ + B for some algebraic number ŷ ∈ B(y 0 , ε).Then there exists an algorithm that on input of a rational δ > 0 and C > 0 as above that outputs "A = 0" when A = 0 and B ̸ = 0, and that outputs "A ̸ = 0" and a number y ∈ Q[i] such that 96.04D 2 .We can bound d 2 i by using Pythagoras, to see that This means that α ∈ ( 1 2 π, 3 2 π), and f (ŷ 2 ) − f (ŷ 1 ) is in the interval ( 1 3 π, 5 3 π), since 2 • 0.25 < π/6.Then the algorithm indeed outputs "A ̸ = 0".
When A ̸ = 0, we also see that y * ∈ B ∞ (0, D) by our choice of D. By Lemma 5.3 we then know that y * ∈ B ∞ (m n , D n ).Because D n = (7/8) n D ≤ δ/2, this box is small enough.We thus conclude that our algorithm is correct and move on to the analysis of the running time.
The running time of the algorithm is dominated by the applications of the box shrinking.First of all we note that n = O(log(C/δ)).The smallest ε that we encounter is 0.05δ.By Lemma 5.2 and induction, it follows that after k steps, the diagonal of the current box, D k , is of the form (7/8) k D and its center, m k , is of the form 0 plus a rational multiple (of size O(k)) of D and hence is itself rational.The values of y i that we encounter are of the form m k ± 5 4 D k and m k ± 5 4 D k i. Therefore the y i that are used as input for the assumed algorithm have their sizes bounded by O(log(D)) + O(n) = O(log(C/δ)).Hence we obtain a running time of O log(C/δ) poly(log(C/δ)) = poly(log(C/δ)).□

Concluding remarks
Planar graphs: inside the disk |q − 1| < 1 An interesting question left open by our results is whether approximately computing the chromatic polynomial of planar graphs is #P-hard for all non-real algebraic q.We refer to Figure 1.1 for a figure displaying the region for which we can prove hardness with the aid of a computer; here we use the computer to try and verify the condition in Theorem 3.12.The family H * q,y , appearing in this condition, is now restricted to series-parallel graphs.We can allow this family to contain planar, two-terminal graphs where the terminal are on the same face.Looking at wheel graphs this can be seen to improve Figure 1.1, but is not yet enough to resolve the question completely.
Real evaluations of the chromatic polynomial for planar graphs The focus in the present paper has been on non-real evaluations.Using our techniques we can also obtain results for real evaluations of the chromatic polynomial.It suffices for q ∈ R to be able to get density on the real line with effective edge interactions of planar graphs (where, as above, the two terminals are on the same face).Having this, the machinery of the present paper can be adapted in a straightforward way to prove hardness of approximating the absolute value at q.To obtain density of the effective edge interactions at q it suffices to find an effective interaction that is finite and less than −1.When restricting to the family H * q,0 , this is possible if and only if q ∈ (32/27, 2) by Bencs et al. (2023).When we replace the family H * q,0 by the family of two-terminal planar graphs with the two terminals on the same face, one can get a negative effective interaction, thus density in R, for q inside the union of three intervals (2, 3) ∪ (3, t 1 ) ∪ (t 2 , 4), where t 1 ≈ 3.618032 and t 2 ≈ 3.618356 by results of Thomassen (1997) and Perrett & Thomassen (2018).Consequently, it is then #P-hard to approximate the absolute value of the chromatic polynomial for planar graphs for any algebraic q in any of these intervals.
Interestingly, there is the value τ + 2 ∈ (t 1 , t 2 ) (where τ is the golden ratio) at which the chromatic polynomial of any planar graphs is positive by a result of Tutte (1970), see also Perrett & Thomassen (2018).This suggests that the computational complexity of approximating the absolute value of the chromatic polynomial at τ + 2 is an intriguing problem. 2inally, we ask about the complexity of approximating the absolute value of the chromatic polynomial at large values of q on planar graphs (computing the sign is hard for general graphs Goldberg & Jerrum (2014)).Birkhoff & Lewis (1946) (see also Woodall ~gabriel/AGT/wp-content/uploads/2021/02/30_Gordon_Royle.pdf) it was announced that Gordon Royle and Melissa Lee proved that t 1 can be chosen to be τ + 2.
(1997)) showed that planar graphs have no chromatic roots larger than 5 indicating that the constructions that we employ in the present paper are not possible.This suggests that determining the complexity of approximating the chromatic polynomial for planar graphs in this regime is an interesting problem.
Almost bounded degree (planar) graphs Combining our techniques with some ingredients from Bencs et al. (2023) and some tools from complex dynamics we expect that for ∆ ≥ 3 and nonreal algebraic q such that 1 < |q − 1| < ∆ − 1, approximating the chromatic polynomial for planar graphs of maximum degree at most ∆ with one vertex of potentially unbounded degree is #Phard.We leave the details for follow up work3 .This relates to a result of Galanis et al. (2015), who showed that for even positive integer q, corresponding to proper q-colorings, proved that it is NP-hard to approximate the evaluation of the chromatic polynomial at q on all graphs of maximum degree ∆ when q < ∆.This should be contrasted with a result from Patel & Regts (2017) which shows that for all graphs of maximum degree at most ∆ and any q such that |q| > 6.91∆ there exists an efficient algorithm to approximate the chromatic polynomial.This algorithm is based on the Barvinok's interpolation method Barvinok (2016) and a zerofreeness result for the chromatic polynomial for bounded degree graphs Fernández & Procacci (2008); Jackson et al. (2013).The zero-free region can be extended to the family graphs of maximum degree at most ∆ where one vertex may have unbounded degree at the cost of replacing 6.91∆ by 7.97∆ + 1 using (Sokal 2001, Corollary 6.4).Using Sokal's representation of the chromatic polynomial of a graph with one vertex of potentially unbounded degree as an evaluation of the partition function of a (multivariate) random cluster model with external fields of a bounded degree graph Sokal (2001), the algorithm from Patel & Regts (2017) can be adapted to run in polynomial time for this class of graphs as well.
The reliability polynomial Recall that T (G; x, y) denotes the Tutte polynomial of a graph G.For a connected graph G and This is up to a transformation the reliability polynomial, i.e. (1 − p) |E| C(G; 1 1−p ) gives the probability that the graph G remains connected if edges are independently selected with probability p, and deleted with probability 1 − p (see e.g.Sokal (2005)).Clearly, the approach for proving density in the present paper does not apply directly.However, a variation of our methods can be applied in this setting.We will leave this for future work.
we define the Mahler measure M (p) := |a d | d i=1 max(1, |α i |) and finally the absolute logarithmic height h(p) := 1 d log(M (p)).Here and in what follows, log denotes the natural logarithm.