Bisector energy and few distinct distances

We introduce the bisector energy of an $n$-point set $P$ in $\mathbb{R}^2$, defined as the number of quadruples $(a,b,c,d)$ from $P$ such that $a$ and $b$ determine the same perpendicular bisector as $c$ and $d$. If no line or circle contains $M(n)$ points of $P$, then we prove that the bisector energy is $O(M(n)^{\frac{2}{5}}n^{\frac{12}{5}+\epsilon} + M(n)n^2).$. We also prove the lower bound $\Omega(M(n)n^2)$, which matches our upper bound when $M(n)$ is large. We use our upper bound on the bisector energy to obtain two rather different results: (i) If $P$ determines $O(n/\sqrt{\log n})$ distinct distances, then for any $0<\alpha\le 1/4$, either there exists a line or circle that contains $n^\alpha$ points of $P$, or there exist $\Omega(n^{8/5-12\alpha/5-\epsilon})$ distinct lines that contain $\Omega(\sqrt{\log n})$ points of $P$. This result provides new information on a conjecture of Erd\H{o}s regarding the structure of point sets with few distinct distances. (ii) If no line or circle contains $M(n)$ points of $P$, then the number of distinct perpendicular bisectors determined by $P$ is $\Omega(\min\{M(n)^{-2/5}n^{8/5-\epsilon}, M(n)^{-1} n^2\})$. This appears to be the first higher-dimensional example in a framework for studying the expansion properties of polynomials and rational functions over $\mathbb{R}$, initiated by Elekes and R\'onyai.


Introduction
Guth and Katz [11] proved that every set of n points in R 2 determines Ω(n/ log n) distinct distances. This almost completely settled a conjecture of Erdős [5], who observed that the √ n × √ n integer lattice determines Θ(n/ √ log n) distances, and conjectured that every set of n points determines at least this number of distances. Beyond the remaining √ log n gap, this leaves open the question of which point sets determine few distances. Erdős [7] asked whether every set that determines O(n/ √ log n) distances "has lattice structure". He then wrote: "The first step would be to decide if there always is a line which contains cn 1/2 of the points (and in fact n ε would already be interesting)." Embarrassingly, almost three decades later the bound n ε seems as distant as it ever was. The following bound is a consequence of an argument of Szemerédi, presented by Erdős [6]. Theorem 1.1 (Szemerédi). If a set P of n points in R 2 determines O(n/ √ log n) distances, then there exists a line containing Ω( √ log n) points of P.
Recently, it was noticed that this bound can be slightly improved to Ω(log n) points on a line (see [17]). Assuming that no line contains an asymptotically larger number of points, one can prove the existence of Ω(n/ log n) distinct lines that contain Ω(log n) points of P. By inspecting Szemerédi's proof, it is also apparent that these lines are perpendicular bisectors of pairs of points of P.
This problem was recently approached from the other direction in [13,14,18]. Combining the results of these three papers implies the following. If an n-point set P ⊂ R 2 determines o(n) distances, then no line contains Ω(n 43/52+ε ) points of P, no circle contains Ω(n 5/6 ) points, and no other constant-degree irreducible algebraic curve contains Ω(n 3/4 ) points.
In the current paper we study a different aspect of sets with few distinct distances. Our main tool is a bound on the bisector energy of the point set (see below for a formal definition). Using this tool, we prove that if a point set P determines O(n/ √ log n) distinct distances, then either there exists a line or a circle with many points of P, or the number of lines containing Ω( √ log n) must be significantly larger than implied by Theorem 1.1. As another application of bisector energy, we prove that if no line or circle contains many points of a point set P, then P determines a large number of distinct perpendicular bisectors. We will provide more background to both results after we have properly stated them.
In Section 3, we prove the following upper bound on this quantity. The bound of Theorem 2.1 is dominated by its first term when M (n) = O(n 2/3+ε ). We note that one important ingredient of our proof is the result of Guth and Katz [11]; without it, we would obtain a weaker (although nontrivial) bound on the bisector energy (see the remark at the end of Section 3.3).
In parallel to our work, Hanson, Iosevich, Lund, and Roche-Newton [12] derived a variant of Theorem 2.1 for the case of point sets in F 2 q . In Section 3.4, we derive a lower bound for the maximum bisector energy. It shows that Theorem 2.1 is tight when its second term dominates, i.e., when M (n) = Ω(n 2/3+ε ).
Theorem 2.2. For any n and M (n), there exists a set P of n points in R 2 such that no line or circle contains M (n) points of P, and E(P) = Ω (M (n)n 2 ).
We conjecture that E(P) = O(M (n)n 2 ) is true for all M (n).
Few distinct distances. Our first application of Theorem 2.1 is to deduce the following theorem. It follows from the slightly more general Theorem 4.1 that we prove in Section 4. Theorem 2.3. Let P ⊂ R 2 be a set of n points that spans O(n/ √ log n) distinct distances. Then for any 0 < α ≤ 1/4, at least one of the following holds. (i) There exists a line or a circle containing Ω(n α ) points of P.
If our conjecture that E(P) = O(M (n)n 2 ) were proved, alternative (ii) in the conclusion of Theorem 2.3 would improve to give Ω(n 2−3α log(n)) lines that each contain Ω( √ log n) points of P. We believe that Theorem 2.3 is a step towards Erdős's lattice conjecture. We mention several recent results and conjectures that together paint an interesting picture.
Green and Tao [10] proved that, given an n-point set in R 2 such that more than n 2 /6 − O(n) lines contain at least three of the points, most of the points must lie on a cubic curve (an algebraic curve of degree at most three). Elekes and Szabó [4] stated the stronger conjecture that if an n-point set determines Ω(n 2 ) collinear triples, then many of the points lie on a cubic curve; unfortunately, at this point it is not even known whether there must be a cubic that contains ten points of the set. Erdős and Purdy [8] conjectured that if n points determine Ω(n 2 ) collinear quadruples, then there must be five points on a line. If the point set is already known to lie on a low-degree algebraic curve, then both conjectures hold [4,16]. On the other hand, Solymosi and Stojaković [19] proved that for any constant k, there can be Ω(n 2−ε ) lines with exactly k points, but no line with k + 1 points.
The philosophy of these statements is that if there are many lines containing many points, then the points must lie on some low-degree algebraic curve. Our result shows that for an n-point set with few distinct distances, either there is a line or circle with very many points, or else there are many lines with many points. In particular, in the second case there would be many collinear triples (although not quite as many as Ω(n 2 )), and many lines with very many (more than a constant) points. This suggests that few distinct distances should imply some algebraic structure. Let us pose a specific question: Is there a 0 < β < 1 such that if n points determine Ω(n 1+β ) lines with Ω( √ log n) points, then many of the points must lie on a low-degree algebraic curve?
Distinct bisectors. Let B(P) be the set of those lines that are distinct perpendicular bisectors of P. Since any point of P determines n − 1 distinct bisectors with the other points of P, we have a trivial lower bound |B(P)| ≥ n − 1. If P is a set of equally spaced points on a circle, then |B(P)| = n. Similarly, if P is a set of n equally spaced points on a line, then |B(P)| = 2n − 3. As we now show, forbidding many points on a line or circle forces |B(P)| to be significantly larger.
Combining this with the bound of Theorem 2.1 immediately implies the theorem.
We are not aware of any previous results concerning the minimum number of distinct bisectors. Theorem 2.4 can be viewed as a new step in a series of results initiated by Elekes and Rónyai [2], studying the expansion properties of polynomials and rational functions over R. For instance, in [15] it is proved that a polynomial function F : R×R → R takes Ω(n 4/3 ) values on any set in R of size n, unless F (x, y) = G(H(x) + K(y)) or F (x, y) = G(H(x)K(y)) with polynomials G, H, K. Elekes and Szabó [3] derived the following higher-dimensional generalization (rephrased for our convenience, and omitting some details). If F : R D × R D → R D is a rational function that is not of a special form, and A, B ⊂ R D are two n-point sets such that no low-degree proper subvariety of R D contains many points of A or B, then F takes Ω(n 1+ε ) values on A × B. However, this last condition is hard to use, and no concrete case with D > 1 is known. Theorem 2.4 is such a concrete case, for the function B. If we view a line y = sx+t as a point (s, t) ∈ R 2 , then (see the proof of Lemma 3.1) is a rational function R 2 × R 2 → R 2 . Then Theorem 2.4 says that B takes many distinct values on any n-point set with few points on a line or circle. So we have replaced the broad condition of [3] that not too many points lie on a low-degree curve, with the very specific condition that not too many points lie on a line or circle. Moreover, the exponent in our lower bound is considerably better than that of [3].
An incidence bound. To prove Theorem 2.1, we use the incidence bound below. It is a refined version of a theorem from Fox et al. [9], with explicit dependence on the parameter t, which we allow to depend on m and n. We reproduce the proof in Section 5 to determine this dependence. Given a set P ⊂ R d of points and a set S ⊂ R d of varieties, the incidence graph is a bipartite graph with vertex sets P and S, such that (p, S) ∈ P × S is an edge in the graph if the point p is incident to the variety S. We write I(P, S) for the number of edges of this graph, or in other words, for the number of incidences between P and S. We denote the complete bipartite graph on s and t vertices by K s,t .
Theorem 2.5. Let S be a set of n constant-degree varieties and let P be a set of m points, both in R d , such that the incidence graph of P × S contains no copy of K s,t (where s is a constant, but t may depend on m, n). Moreover, let P ⊂ V , where V is an irreducible constant-degree variety of dimension e. Then

Proof of Theorem 2.1
In this section we prove Theorem 2.1 by relating the bisector energy to an incidence problem between points and algebraic surfaces in R 4 . In Section 3.1 we define the surfaces, in Section 3.2 we analyze their intersection properties, and in Section 3.3 we apply the incidence bound of Theorem 2.5 to prove Theorem 2.1. Finally, in Section 3.4 we derive Theorem 2.2, which provides a lower bound for Theorem 2.1.
Throughout this section we assume that we have rotated P so that no two points have the same xor y-coordinate; in particular, we assume that no perpendicular bisector is horizontal or vertical.

Bisector surfaces
Recall that in Theorem 2.1 we consider an n-point set P ⊂ R 2 . We define and similarly Recall also that for a pair (a, b) ∈ P 2 * , we denote by B(a, b) the perpendicular bisector of a and b. We define the bisector surface of a pair (a, c) ∈ P 2 * as and we set S = {S ac | (a, c) ∈ P 2 * }. The surface S ac is not an algebraic variety (so we are using the word "surface" loosely), but the lemma below shows that S ac is "close to" a variety S ac . That S ac is contained in a constant-degree variety of the same dimension is no surprise (one can take the Zariski closure), but we need to analyze this variety in detail to establish the exact relationship.
We will work mostly with the surface S ac in the rest of this proof, rather than with the variety S ac , because its definition is easier to handle. Then, when we apply our incidence bound, which holds only for varieties, we will switch to S ac . Fortunately, the lemma shows that this makes no difference in terms of the incidence graphs.
By definition B(a, b) passes through the midpoint ((a x + b x )/2, (a y + b y )/2) of a and b, as well as through the midpoint ((c x + d x )/2, (c y + d y )/2) of c and d. We thus have By replacing s with both of the other expressions in (1) and rearranging, we obtain From (1) and (2) Since any point (b, d) ∈ S ac satisfies these two equations, we have S ac ⊂ Z(f ac , g ac ) = S ac .
By reexamining the above analysis, we see that if a point (b, d) ∈ S ac ∩ P 2 * is not in S ac , we must have a y = b y or c y = d y , since then (1) is not well defined. By the assumption that no two points of P have the same y-coordinate, this implies a = b or c = d, so (a, b, c, d) ∈ P 4 * .
It remains to prove that S ac is a constant-degree two-dimensional variety. The constant degree is immediate from f ac and g ac being polynomials of degree at most three. As just observed, points in (b, d) ∈ S ac \S ac satisfy a y = b y or c y = d y . If We see that in each case we get two independent linear equations, which define a plane, so S ac \S ac is the union of three two-dimensional planes. Thus, it suffices to prove that S ac is two-dimensional. For this, we simply show that for any valid value of b there is at most one valid value of d. Let C ac ⊂ R 2 denote the circle that is centered at c and incident to a. It is impossible for b to lie on C ac , since this would imply that the bisector B(a, b) contains c, and thus that

Intersections of bisector surfaces
We denote by R ab the reflection of R 2 across the line B(a, b). Observe that if B(a, b) = B(c, d), then R ab = R cd , and this reflection maps both a to b and c to d; this in turn implies that |ac| = |bd|. That is, (b, d) ∈ S ac implies |ab| = |cd|. It follows that if |ac| = δ, then the open surface S ac is contained in the hypersurface We can thus partition S into classes corresponding to the distances δ that are determined by pairs of points of P. Each class consists of the surfaces S ac with |ac| = δ, all of which are fully contained in H δ .
We now study the intersection of the surfaces contained in a common hypersurface H δ . Lemma 3.2. Let (a, c) = (a , c ) and |ac| = |a c | = δ = 0. Then there exist two curves C 1 , C 2 ⊂ R 2 , which are either two concentric circles or two parallel lines, such that a, a ∈ C 1 , c, c ∈ C 2 , and S ac ∩ S a c is contained in the set Proof. We split the analysis into three cases:  Figure 1.
Case (i). Let o = B(a, a )∩B(c, c ). Then there exist two (not necessarily distinct) circles C 1 , C 2 around o such that a, a ∈ C 1 and c, c ∈ C 2 . If (b, d) ∈ S ac ∩ S a c , then the reflection R ab takes a to b and c to d, and similarly, R a b takes b to a and d to c . We set T = R a b • R ab , and notice that this is a rotation whose center o * is the intersection point of B(a, b) = B(c, d) and B(a , b) Case (ii). Let be the line B(a, a ) = B(c, c ). The line segment ac is a reflection across of the line segment a c . Thus, the intersection point o of the lines that contains these two segments is incident to . Let C 1 be the circle centered at o that contains a and a , and let C 2 be the circle centered at o that contains c and c . With this definition of o, C 1 , and C 2 , we can repeat the analysis of case (i), obtaining the same conclusion.
Case (iii). In this case B(a, a ) and B(c, c ) are parallel. The analysis of this case is similar to that in case (i), but with lines instead of circles.
Let C 1 be the line that is incident to a and a , and let C 2 be the line that is incident to c and c . If (b, d) ∈ S ac ∩ S a c , then, as before, R ab takes a to b and c to d, and R a b takes b to a and d to c . Since B(a , b) and B(a, b) are parallel, we have that T = R a b • R ab is a translation in the direction orthogonal to these two lines. This implies that b ∈ C 1 and d ∈ C 2 , which completes the analysis of this case.
In Section 3.3, we will apply the incidence bound of Theorem 2.5 to the point set P 2 * = {(b, d) ∈ P 2 | b = d} and the set of surfaces S. For this we need to show that the incidence graph contains no complete bipartite graph K 2,M ; that is, that for any two points of P 2 * (where P 2 * is considered as a point set in R 4 ) there is a bounded number of surfaces of S that contain both points. In the following lemma we prove the more general statement that the incidence graph contains no copy of K 2,M and no copy of K M,2 . Note that this is the only point in the proof of Theorem 2.1 where we use the condition that no M points are on a line or circle. Proof. Consider two distinct surfaces S ac , S a c ∈ S with |ac| = |a c | = δ. Lemma 3.2 implies that there exist two lines or circles C 1 , C 2 such that (b, d) ∈ S ac ∩ S a c only if b ∈ C 1 and d ∈ C 2 . Since no line or circle contains M points of P, we have |C 1 ∩ P 2 * | < M . Given b ∈ (C 1 ∩ P)\{a}, there is at most one d ∈ P such that B(a, b) = B(c, d), and thus at most one point (b, d) ∈ S ac . (Notice that no points of the form (a, d) ∈ P 2 * are in S ac .) Thus |(S ac ∩ S a c ) ∩ P 2 * | < M.
That is, the incidence graph contains no copy of K M,2 .
We now define "dual" surfaces and set S * = {S * bd | (b, d) ∈ P 2 * }. By a symmetric argument, we get Observe that (a, c) ∈ S * bd if and only if (b, d) ∈ S ac . Hence, having fewer than M points (a, c) ∈ (S * bd ∩ S * b d ) ∩ P 2 * is equivalent to having fewer than M surfaces S ac that are incident to both (b, d) and (b , d ). That is, the incidence graph contains no copy of K 2,M .

Applying the incidence bound
We set and note that |Q| + n 2 = E(P), where the term n 2 accounts for the quadruples of the form (a, b, a, b). As we saw in Section 3.2, every quadruple (a, b, c, d) ∈ Q satisfies |ac| = |bd|.
Let δ 1 , . . . , δ D denote the distinct distances that are determined by pairs of distinct points in P. We partition P 2 * into the disjoint subsets Π 1 , . . . , Π D , where We also partition S into disjoint subsets S 1 , . . . , S D , defined by Let m i be the number of (a, c) ∈ P 2 * such that |ac| = δ i . Note that |Π i | = |S i | = m i and m i = n(n − 1).
A quadruple (a, b, c, d) ∈ P 4 * is in Q if and only if the point (b, d) is incident to S ac . Moreover, there exists a unique 1 ≤ i ≤ D such that (b, d) ∈ Π i and S ac ∈ S i . Therefore, it suffices to study each Π i and S i separately. That is, we have We apply our incidence bound to S i , or rather, to the corresponding set of varieties S i = {S ac | S ac ∈ S i }. By Lemma 3.1, the incidence graph of Π i with S i is the same as with S i , hence also does not contain any copy of K 2,M by Corollary 3.3. Observe that Π i ⊂ H δ i . The hypersurface H δ i is irreducible, three-dimensional, and of a constant degree, since it is defined by the irreducible polynomial (x 1 − x 3 ) 2 + (x 2 − x 4 ) 2 − δ i . Thus we can apply Theorem 2.5 to each I(Π i , S i ), with m = n = m i , V = H δ i , d = 4, e = 3, s = 2, and t = M . This implies that Let J be the set of indices 1 ≤ j ≤ D for which the bound in (3)  . This implies that the number of m j for which m j ≥ x is O(n 3 log n/x 2 ). By using a dyadic decomposition, we obtain In conclusion, Remark about the incidence bound. Instead of partitioning the problem into D separate incidence problems, one can apply an incidence bound directly to the point set P 2 * and the surface set S. Roughly speaking, the best known bounds for incidences with two-dimensional surfaces in R 4 , whose incidence graph contains no K 2,M , are of the form |P 2 * | 2/3 |S| 2/3 . Relying on such an incidence bound (and not using the estimate from [11]) would yield a bound |Q| = O(M 1/3 n 8/3 + M n 2 ) = O(M 1/3 n 8/3 ), which is nontrivial but weaker than our bound.

A lower bound for E(P)
In this section we prove Theorem 2.2. In particular, for any n and M (n) ≥ 32, we show that there exists a set P of n points in R 2 such that any line or circle contains at most M (n) points of P, and E(P) = Ω (M (n)n 2 ). Note that we can suppose M (n) ≥ 32 without loss of generality since, if M (n) < 32, an arbitrary point set has E(P) = Ω (n 2 ) = Ω (M (n)n 2 ). For simplicity, we assume that M (n) is a multiple of 8, and that n is divisible by M (n). It is straightforward to extend the following construction to values that do not satisfy these conditions. Let C be an axis-parallel ellipse that is centered at the origin, has a major axis of length 2 that is parallel to the y-axis, and a minor axis of length 1 that is parallel to the x-axis. Let P + be an arbitrary set of 4n/M (n) points on C, each having a strictly positive x-coordinate. Let P − be the reflection of P + over the y-axis, and set P = P + ∪ P − . We denote by P j the translate of P by (4j, 0). Finally, we take P = P 0 ∪ P 1 ∪ · · · ∪ P M (n)/8−1 . An example is depicted in Figure 2.
Note that P lies on the union of M (n)/8 ellipses. Since a line can intersect an ellipse in at most two points, and a circle can intersect an ellipse in at most four points, we indeed have that a line or circle contains at most M (n) points of P.
It remains to prove that E(P) = Ω(M (n)n 2 ). For every integer M (n)/32 ≤ j ≤ M (n)/16, we denote by j the vertical line x = 4j. For every such j, there are Θ(n) points of P that are to the left j , and the reflection of each such point across j is another point of P. That is, for every M (n)/32 ≤ j ≤ M (n)/16, the line j is the perpendicular bisector of Θ(n) pairs of points of P. The assertion of the theorem follows, since there are Θ(M (n)) such lines, each contributing Θ(n 2 ) to E(P).

Proof of Theorem 2.3
In this section we prove that Theorem 2.3 follows from Theorem 2.1. In fact, we prove the following more general version of Theorem 2.3. Since Guth and Katz [11] proved that any n-point set spans Ω(n/ log n) distinct distances, the assumption that K = O(log n) is not a real restriction. The original formulation of Theorem 2.3 is immediately obtained by setting K(n) = √ log n and M (n) = n α .
Proof. For simplicity, we use the notation K = K(n) and M = M (n) throughout this proof. We assume that (i) does not hold, and prove that (ii) holds in this case.
Given a point set P ⊂ R 2 , we denote by B * (P) the multiset of bisectors that are spanned by ordered pairs of P 2 * . Recall that B(P) is the set of distinct lines of B * (P). For every line ∈ B(P), we denote by µ( ) its multiplicity in B * (P) (i.e., the number of times it occurs in the multiset), and set ρ( ) = | ∩ P|. We define I(P, B * (P)) = ∈B(P) µ( )ρ( ); that is, I(P, B * (P)) is the number incidences with respect to their multiplicities.
We derive a lower bound on I(P, B * (P)) by using an argument that is similar to the one in Szemerédi's proof of Theorem 1.1. Let T ⊂ P 3 be the set of triples (p, q, r) of distinct points of P such that |pq| = |pr|. Note that a triple (p, q, r) is in T if and only if p is incident to B(q, r). That is, Denote the distances that are determined by pairs of P 2 * as δ 1 , . . . , δ D . For every point p ∈ P and 1 ≤ i ≤ D, let ∆ i,p denote the number of points of P that have distance δ i from p. Let T p ⊂ T denote the set of triples of T in which the first element is p. Applying the Cauchy-Schwarz inequality yields This in turn implies We remark that by the Szemerédi-Trotter theorem [21], the number of incidences between n points and n 2 distinct lines is O (n 2 ). This does not contradict (4) since the lines in the multiset B * (P) need not be distinct. Theoretically, it might be that B * (P) consists of Θ(n) distinct lines, each with multiplicity Θ(n) and incident to Θ(K) points. However, our bound on the bisector energy excludes such cases.
Let c t be the constant implicit in the lower bound on |T |; we have |T | ≥ c t Kn 2 .
Since K = O(log(n)), it can be absorbed into the factor n ε in the final bound.
Remark. Notice that the proof of Theorem 4.1 also applies when M (n) = Ω(n 1/4 ). However, this would lead to a bound for the number of lines in (ii) that is weaker than the bound that is implied by Theorem 1.1.

Proof of Theorem 2.5
We now present the proof of the incidence bound that we use. As mentioned in the introduction, this proof is essentially from [9]; we reproduce it here to determine the dependence on the parameter t. We prove a more general version than we need, since it seems to come at no extra cost, and may be useful elsewhere.
Lemma 5.1 (Kővári-Sós-Turán). Let S be a set of n varieties and P a set of m points, both in R d , such that the incidence graph of P × S contains no K s,t (where s is constant but t may depend on m, n). Then I(P, S) = O(t 1/s mn (s−1)/s + n).
We amplify the weak bound of Lemma 5.1 by using polynomial partitioning. Given a polynomial f ∈ R[x 1 , . . . , x d ], we write Z(f ) = {p ∈ R d | f (p) = 0}. We say that f ∈ R[x 1 , . . . , x d ] is an r-partitioning polynomial for a finite set P ⊂ R d if no connected component of R d \Z(f ) contains more than |P|/r points of P (notice that there is no restriction on the number of points of P that are in Z(f )). Guth and Katz [11] introduced this notion and proved that for every P ⊂ R d and 1 ≤ r ≤ |P|, there exists an r-partitioning polynomial of degree O(r 1/d ). In [9], the following generalization was proved. We are now ready to prove our incidence bound. For the convenience of the reader, we first repeat the statement of the theorem.
Theorem 2.5. Let S be a set of n constant-degree varieties and let P be a set of m points, both in R d , such that the incidence graph of P × S contains no copy of K s,t (where s is a constant, but t may depend on m, n). Moreover, let P ⊂ V , where V is an irreducible constant-degree variety of dimension e. Then The base cases for the induction are simple. If m is sufficiently small, then (5) follows immediately by choosing sufficiently large values for α 1,e and α 2,e . Similarly, when e = 0, we again obtain (5) when α 1,e and α 2,e are sufficiently large (with respect to d and to the degree of V ). The constants d, e, D, s, 1/ε are given and thus fixed. The other constants are to be chosen, and the dependencies between them are where C C means that C is to be chosen sufficiently large compared to C; that is, C should be chosen before C .
By Lemma 5.1, there exists a constant C weak (depending on d, s) such that I(P, S) ≤ C weak mn 1−1/s t 1/s + n .
When m ≤ (n/t) 1/s , and α 2,e is sufficiently large, we have I(P, S) ≤ α 2,e n. Therefore, in the remainder of the proof we can assume that n < m s t, which implies n = n Partitioning. By Theorem 5.2, there exists an r-partitioning polynomial f with respect to V of degree at most C part · r 1/e , for a constant C part . Denote the cells of V \Z(f ) as Ω 1 , . . . , Ω N . Since we are working over the reals, there exists a constantdegree polynomial g such that Z(g) = V . Then, by [20, Theorem A.2], we have N ≤ C cells · deg(f ) dim V = C cells · r for some constant C cells depending on C part . We partition I(P, S) into the following three subsets: • I 1 consists of the incidences (p, S) ∈ P × S such that p ∈ V ∩ Z(f ), and some irreducible component of V ∩ Z(f ) contains p and is fully contained in S.
• I 2 consists of the incidences (p, S) ∈ P × S such that p ∈ V ∩ Z(f ), and every irreducible component of V ∩ Z(f ) that contains p is not contained in S.
• I 3 = I(P, S)\(I 1 ∪ I 2 ), the set of incidences (p, S) ∈ P × S such that p is not contained in V ∩ Z(f ).
Note that we indeed have I(P, S) = I 1 + I 2 + I 3 .
Bounding I 1 . The points of P ⊂ R d that participate in incidences of I 1 are all contained in the variety V 0 = V ∩ Z(f ). Set P 0 = P ∩ V 0 and m 0 = |P 0 |. Since V is an irreducible variety and V ⊂ Z(f ), V 0 is a variety of dimension at most e − 1 and of degree that depends on r. By [20,Lemma 4.3], the intersection V 0 is a union of C comps irreducible components, where C comps is a constant depending on r and d. 2 The degrees of these components also depend only on these values (for a proper definition of degrees and further discussion, e.g., see [9]). Consider an irreducible component W of V 0 . If W contains at most s − 1 points of P 0 , it yields at most (s − 1)n incidences. Otherwise, since the incidence graph contains no K s,t , there are at most t − 1 varieties of S that fully contain W , yielding at most (t − 1)m 0 incidences. By summing up, choosing sufficiently large α 1,e , α 2,e , and applying (6), we have  (6) to remove the term α 2,e−1 n, and by choosing α 1,e and α 2,e sufficiently large with respect to C comps , α 1,e−1 , α 2,e−1 , we obtain Bounding I 3 . For every 1 ≤ i ≤ N , we set P i = P ∩ Ω i and denote by S i the set of varieties of S that intersect the cell Ω i but do not contain it. We also set m i = |P i | and n i = |S i |. Since f is an r-partitioning polynomial, we have m i ≤ m/r, . We have N i=1 m i = m − m 0 . By [20,Theorem A.2], there exists a constant C inter such that the following holds for every S ∈ S. The subvariety S ∩ V of V , which must have dimension at most e−1, intersects at most C inter ·deg(f ) dim(S∩V ) = C inter ·r (e−1)/e cells. This implies that N i=1 n i ≤ C inter · r (e−1)/e · n.