On the Beer index of convexity and its variants

Let $S$ be a subset of $\mathbb{R}^d$ with finite positive Lebesgue measure. The Beer index of convexity $\operatorname{b}(S)$ of $S$ is the probability that two points of $S$ chosen uniformly independently at random see each other in $S$. The convexity ratio $\operatorname{c}(S)$ of $S$ is the Lebesgue measure of the largest convex subset of $S$ divided by the Lebesgue measure of $S$. We investigate the relationship between these two natural measures of convexity of $S$. We show that every set $S\subseteq\mathbb{R}^2$ with simply connected components satisfies $\operatorname{b}(S)\leq\alpha\operatorname{c}(S)$ for an absolute constant $\alpha$, provided $\operatorname{b}(S)$ is defined. This implies an affirmative answer to the conjecture of Cabello et al. asserting that this estimate holds for simple polygons. We also consider higher-order generalizations of $\operatorname{b}(S)$. For $1\leq k\leq d$, the $k$-index of convexity $\operatorname{b}_k(S)$ of $S\subseteq\mathbb{R}^d$ is the probability that the convex hull of a $(k+1)$-tuple of points chosen uniformly independently at random from $S$ is contained in $S$. We show that for every $d\geq 2$ there is a constant $\beta(d)>0$ such that every set $S\subseteq\mathbb{R}^d$ satisfies $\operatorname{b}_d(S)\leq\beta\operatorname{c}(S)$, provided $\operatorname{b}_d(S)$ exists. We provide an almost matching lower bound by showing that there is a constant $\gamma(d)>0$ such that for every $\varepsilon\in(0,1]$ there is a set $S\subseteq\mathbb{R}^d$ of Lebesgue measure one satisfying $\operatorname{c}(S)\leq\varepsilon$ and $\operatorname{b}_d(S)\geq\gamma\frac{\varepsilon}{\log_2{1/\varepsilon}}\geq\gamma\frac{\operatorname{c}(S)}{\log_2{1/\operatorname{c}(S)}}$.


Introduction
For positive integers k and d and a Lebesgue measurable set S ⊆ R d , we use λ k (S) to denote the k-dimensional Lebesgue measure of S. We omit the subscript k when it is clear from the context. We also write 'measure' instead of 'Lebesgue measure', as we do not use any other measure in the paper.
For a set S ⊆ R d , let smc(S) denote the supremum of the measures of convex subsets of S. Since all convex subsets of R d are measurable [11], the value of smc(S) is well defined. Moreover, Goodman's result [8] implies that the supremum is achieved on compact sets S, hence it can be replaced by maximum in this case. When S has finite positive measure, let c(S) be defined as smc(S)/λ d (S). We call the parameter c(S) the convexity ratio of S.
For two points A, B ∈ R d , let AB denote the closed line segment with endpoints A and B. Let S be a subset of R d . We say that points A, B ∈ S are visible one from the other or see each other in S if the line segment AB is contained in S. For a point A ∈ S, we use Vis(A, S) to denote the set of points that are visible from A in S. More generally, for a subset T of S, we use Vis(T, S) to denote the set of points that are visible in S from T . That is, Vis(T, S) is the set of points A ∈ S for which there is a point B ∈ T such that AB ⊆ S.
Let Seg(S) denote the set {(A, B) ∈ S × S : AB ⊆ S} ⊆ (R d ) 2 , which we call the segment set of S. For a set S ⊆ R d with finite positive measure and with measurable Seg(S), we define the parameter b(S) ∈ [0, 1] by b(S) := λ 2d (Seg(S)) λ d (S) 2 . If S is not measurable, or if its measure is not positive and finite, or if Seg(S) is not measurable, we leave b(S) undefined. Note that if b(S) is defined for a set S, then c(S) is defined as well. We call b(S) the Beer index of convexity (or just Beer index ) of S. It can be interpreted as the probability that two points A and B of S chosen uniformly independently at random see each other in S.
1.1. Previous results. The Beer index was introduced in the 1970s by Beer [1,2,3], who called it 'the index of convexity'. Beer was motivated by studying the continuity properties of λ(Vis(A, S)) as a function of A. For polygonal regions, an equivalent parameter was later independently defined by Stern [19], who called it 'the degree of convexity'. Stern was motivated by the problem of finding a computationally tractable way to quantify how close a given set is to being convex. He showed that the Beer index of a polygon P can be approximated by a Monte Carlo estimation. Later, Rote [16] showed that for a polygonal region P with n edges the Beer index can be evaluated in polynomial time as a sum of O(n 9 ) closed-form expressions.
Cabello et al. [6] have studied the relationship between the Beer index and the convexity ratio, and applied their results in the analysis of their near-linear-time approximation algorithm for finding the largest convex subset of a polygon. We describe some of their results in more detail in Subsection 1.3.
1.2. Terminology and notation. We assume familiarity with basic topological notions such as path-connectedness, simple connectedness, Jordan curve, etc. The reader can find these definitions, for example, in Prasolov's book [15].
Let ∂S, S • , and S denote the boundary, the interior, and the closure of a set S, respectively. For a point A ∈ R 2 and ε > 0, let N ε (A) denote the open disc centered at A with radius ε. For a set X ⊆ R 2 and ε > 0, let N ε (X) = A∈X N ε (A). A neighborhood of a point A ∈ R 2 or a set X ⊆ R 2 is a set of the form N ε (A) or N ε (X), respectively, for some ε > 0.
A closed interval with endpoints a and b is denoted by [a, b]. Intervals [a, b] with a > b are considered empty. For a point A ∈ R 2 , we use x(A) and y(A) to denote the x-coordinate and the y-coordinate of A, respectively.
A polygonal curve Γ in R d is a curve specified by a sequence (A 1 , . . . , A n ) of points of R d such that Γ consists of the line segments connecting the points A i and A i+1 for i = 1, . . . , n − 1. If A 1 = A n , then the polygonal curve Γ is closed. A polygonal curve that is not closed is called a polygonal line.
A set X ⊆ R 2 is polygonally connected, or p-connected for short, if any two points of X can be connected by a polygonal line in X, or equivalently, by a self-avoiding polygonal line in X. For a set X, the relation "A and B can be connected by a polygonal line in X" is an equivalence relation on X, and its equivalence classes are the p-components of X. A set S is p-componentwise simply connected if every p-component of S is simply connected.
A line segment in R d is a bounded convex subset of a line. A closed line segment includes both endpoints, while an open line segment excludes both endpoints. For two points A and B in R d , we use AB to denote the open line segment with endpoints A and B. A closed line segment with endpoints A and B is denoted by AB.
We say that a set S ⊆ R d is star-shaped if there is a point C ∈ S such that Vis(C, S) = S. That is, a star-shaped set S contains a point which sees the entire S. Similarly, we say that a set S is weakly star-shaped if S contains a line segment such that Vis( , S) = S.
It is more challenging to find an upper bound on b(S) in terms of c(S), possibly under additional assumptions on the set S. This is the general problem addressed in this paper.
As a motivating example, observe that a set S consisting of n disjoint convex components of the same size satisfies b(S) = c(S) = 1 n . It is easy to modify this example to obtain, for any ε > 0, a simple star-shaped polygon P with b(P ) 1 n − ε and c(P ) 1 n , see Figure 1. This shows that b(S) cannot be bounded from above by a sublinear function of c(S), even for simple polygons S.
For weakly star-shaped polygons, Cabello et al. [6] showed that the above example is essentially optimal, providing the following linear upper bound on b(S). For polygons that are not weakly star-shaped, Cabello et al. [6] gave a superlinear bound. Moreover, Cabello et al. [6] conjectured that even for a general simple polygon P , b(P ) can be bounded from above by a linear function of c(P ). The next theorem, which is the first main result of this paper, confirms this conjecture. Recall that b(S) is defined for a set S if and only if S has finite positive measure and Seg(S) is measurable. Recall also that a set is p-componentwise simply connected if its polygonally-connected components are simply connected. In particular, every simply connected set is p-componentwise simply connected.
It is clear that every simple polygon satisfies the assumptions of Theorem 1.3, hence we directly obtain the following, which confirms the conjecture of Cabello et al. [6]. The main restriction in Theorem 1.3 is the assumption that S is p-componentwise simply connected. This assumption cannot be omitted, as shown by the set S = [0, 1] 2 Q 2 , where it is easy to verify that c(S) = 0 and b(S) = 1. See Example 3.1 in Section 3.
Again, it is easy to verify that c(S ) = 0 and b(S ) = 1, although S is simply connected, even star-shaped.
Despite these examples, we will show that meaningful analogues of Theorem 1.3 for higher dimensions and for sets that are not p-componentwise simply connected are possible. The key is to use higher-order generalizations of the Beer index, which we introduce now.
For a set S ⊆ R d , we define the set Simp k (S) ⊆ (R d ) k+1 by where the operator Conv denotes the convex hull of a set of points. We call Simp k (S) the k-simplex set of S. Note that Simp 1 (S) = Seg(S).
For an integer k ∈ {1, 2, . . . , d} and a set S ⊆ R d with finite positive measure and with measurable Simp k (S), Note that b 1 (S) = b(S). We call b k (S) the k-index of convexity of S. We again leave b k (S) undefined if S or Simp k (S) is non-measurable, or if the measure of S is not finite and positive. We can view b k (S) as the probability that the convex hull of k + 1 points chosen from S uniformly independently at random is contained in S. For any We remark that the set S = [0, 1] d Q d satisfies c(S) = 0 and b 1 (S) = b 2 (S) = · · · = b d−1 (S) = 1 (see Example 3.1 in Section 3). Thus, for a general set S ⊆ R d , only the d-index of convexity can conceivably admit a nontrivial upper bound in terms of c(S). Our next result shows that such an upper bound on b d (S) exists and is linear in c(S).
We do not know if the linear upper bound in Theorem 1.5 is best possible. We can, however, construct examples showing that the bound is optimal up to a logarithmic factor. This is our last main result. Theorem 1.6. For every d 2, there is a constant γ = γ(d) > 0 such that for every ε ∈ (0, 1], there is a set S ⊆ R d satisfying c(S) ε and b d (S) γ ε log 2 1/ε , and in particular, we have b d (S) γ c(S) log 2 1/ c(S) .

Bounding the mutual visibility in the plane
The goal of this section is to prove Theorem 1.3. Since the proof is rather long and complicated, let us first present a high-level overview of its main ideas.
We first show that it is sufficient to prove the estimate from Theorem 1.3 for bounded open simply connected sets. This is formalized by the next lemma, whose proof is presented in Appendix A. Suppose now that S is a bounded open simply connected set. We seek a bound of the form b(S) = O(c(S)). This is equivalent to a bound of the form λ 4 (Seg(S)) = O(smc(S)λ 2 (S)). We therefore need a suitable upper bound on λ 4 (Seg(S)).
We first choose in S a diagonal (i.e., an inclusion-maximal line segment in S), and show that the set S is a union of two open simply connected sets S 1 and S 2 (Lemma 2.4). It is not hard to show that the segments in S that cross the diagonal contribute to λ 4 (Seg(S)) by at most O(smc(S)λ 2 (S)) (Lemma 2.8). Our main task is to bound the measure of Seg(S i ∪ ) for i = 1, 2. The two sets S i ∪ are what we call rooted sets. Informally, a rooted set is a union of a simply connected open set S and an open segment r ⊆ ∂S , called the root.
To bound λ 4 (Seg(R)) for a rooted set R with root r, we partition R into levels L 1 , L 2 , . . . , where L k contains the points of R that can be connected to r by a polygonal line with k segments, but not by a polygonal line with k − 1 segments. Each segment in R is contained in a union L i ∪ L i+1 for some i 1. Thus, a bound of the form λ 4 (Seg(L i ∪ L i+1 )) = O(smc(R)λ 2 (L i ∪ L i+1 )) implies the required bound for λ 4 (Seg(R)).
We will show that each p-component of L i ∪ L i+1 is a rooted set, with the extra property that all its points are reachable from its root by a polygonal line with at most two segments (Lemma 2.5). To handle such sets, we will generalize the techniques that Cabello et al. [6] have used to handle weakly star-shaped sets in their proof of Theorem 1.1. We will assign to every point A ∈ R a set T(A) of measure O(smc(R)), such that for every (A, B) ∈ Seg(R), we have either B ∈ T(A) or A ∈ T(B) (Lemma 2.7). From this, Theorem 1.3 will follow easily.
To proceed with the proof of Theorem Proof. Choose a pair of points (A, B) ∈ Seg(S). Since S is open and AB is compact, there is Proof. The statement is trivially true if and intersect or have the same supporting line, so suppose this is not the case. Let A, B ∈ and A , B ∈ be such that AA , BB ⊆ S. The points A, A , B , B form a (possibly self-intersecting) tetragon Q whose boundary is contained in S. Since S is simply connected, the interior of Q is contained in S. If Q is not self-intersecting, then clearly AB ⊆ Vis( , S). Otherwise, AA and BB have a point D in common, and every point C ∈ AB is visible in R from the point C ∈ A B such that D ∈ CC . This shows that Vis( , S) ∩ is a convex subset and hence a subsegment of . Now, we define rooted sets and their tree-structured decomposition, and we explain how they arise in the proof of Theorem 1.3.
A set S ⊆ R 2 is half-open if every point A ∈ S has a neighborhood N ε (A) that satisfies one of the following two conditions: The condition (1) holds for points A ∈ S • , while the condition (2) holds for points A ∈ ∂S. A set R ⊆ R 2 is a rooted set if the following conditions are satisfied: (1) R is bounded, (2) R is p-connected and simply connected,  A diagonal of a set S ⊆ R 2 is a line segment contained in S that is not a proper subset of any other line segment contained in S. Clearly, if S is open, then every diagonal of S is an open line segment. It is easy to see that the root of a rooted set is a diagonal. The following lemma allows us to use a diagonal to split a bounded open simply connected subset of R 2 into two rooted sets. It is intuitively clear, and its formal proof is deferred to Appendix B.

Lemma 2.4. Let
S be an open bounded simply connected subset of R 2 , and let be a diagonal of S. It follows that the set S has two p-components S 1 and S 2 . Moreover, S 1 ∪ and S 2 ∪ are rooted sets, and is their common root.
Let R be a rooted set. For a positive integer k, the kth level L k of R is the set of points of R that can be connected to the root of R by a polygonal line in R consisting of k segments but cannot be connected to the root of R by a polygonal line in R consisting of fewer than k segments. We consider a degenerate one-vertex polygonal line as consisting of one degenerate segment, so the root of R is part of L 1 . Thus L 1 = Vis(r, R), where r denotes the root of R. A k-body of R is a p-component of L k . A body of R is a k-body of R for some k. See Figure 2 for an example of a rooted set and its partitioning into levels and bodies.
We say that a rooted set P is attached to a set Q ⊆ R 2 P if the root of P is subset of the interior of P ∪ Q. The following lemma explains the structure of levels and bodies. Although it is intuitively clear, its formal proof requires quite a lot of work and is deferred to Appendix C. Lemma 2.5. Let R be a rooted set and (L k ) k 1 be its partition into levels. It follows that (1) R = k 1 L k ; consequently, R is the union of all its bodies; (2) every body P of R is a rooted set such that P = Vis(r, P ), where r denotes the root of P ; (3) L 1 is the unique 1-body of R, and the root of L 1 is the root of R; (4) every j-body P of R with j 2 is attached to a unique (j − 1)-body of R. Lemma 2.5 yields a tree structure on the bodies of R. The root of this tree is the unique 1-body L 1 of R, called the root body of R. For a k-body P of R with k 2, the parent of P in the tree is the unique (k − 1)-body of R that P is attached to, called the parent body of P . Lemma 2.6. Let R be a rooted set, (L k ) k 1 be the partition of R into levels, be a closed line segment in R, and k 1 be minimum such that ∩ L k = ∅. It follows that ⊆ L k ∪ L k+1 , ∩ L k is a subsegment of contained in a single k-body P of R, and ∩ L k+1 consists of at most two subsegments of each contained in a single (k + 1)-body whose parent body is P .
Proof. The definition of the levels directly yields ⊆ L k ∪ L k+1 . The segment splits into subsegments each contained in a single k-body or (k + 1)-body of R. By Lemma 2.5, the bodies of any two consecutive of these subsegments are in the parent-child relation of the body tree. This implies that ∩ L k lies within a single k-body P . By Lemma 2.3, ∩ L k is a subsegment of . Consequently, ∩ L k+1 consists of at most two subsegments.
In the setting of Lemma 2.6, we call the subsegment ∩ L k of the base segment of , and we call the body P that contains ∩ L k the base body of . See Figure 2 for an example.
The following lemma is the crucial part of the proof of Theorem 1.3.

Lemma 2.7.
If R is a rooted set, then every point A ∈ R can be assigned a measurable set T(A) ⊆ R 2 so that the following is satisfied: (1) λ 2 (T(A)) < 87 smc(R); (2) for every line segment BC in R, we have either B ∈ T(C) or C ∈ T(B); Proof. Let P be a body of R with the root r. First, we show that P is entirely contained in one closed half-plane defined by the supporting line of r. Let h − and h + be the two open half-planes defined by the supporting line of r. According to the definition of a rooted set, the sets {D ∈ r : ∃ε > 0 : } are open and partition the entire r, hence one of them must be empty. This implies that the segments connecting r to P r lie all in h − or all in h + . Since P = Vis(r, P ), we conclude that P ⊆ h − or P ⊆ h + . According to the above, we can rotate and translate the set R so that r lies on the x-axis and P lies in the half-plane {B ∈ R 2 : y(B) 0}. For a point A ∈ R, we use d(A, r) to denote the y-coordinate of A after such a rotation and translation of R. We use d(A) to denote d(A, r) where r is the root of the body of A. It follows that d(A) 0 for every A ∈ R.
Let γ ∈ (0, 1) be a fixed constant whose value will be specified at the end of the proof. For a point A ∈ R, we define the sets where r denotes the root of the base body of AB and A and B denote the endpoints of the base segment of AB such that |AA | < |AB |. These sets are pairwise disjoint, and For the rest of the proof, we fix a point A ∈ R. We show that the union is contained in a measurable set T(A) ⊆ R 2 with λ 2 (T(A)) < 87 smc(R) that is the union of three trapezoids. We let P be the body of A and r be the root of P . If P is a k-body with k 2, then we use r to denote the root of the parent body of P . such that A is the center of the larger base and H is the center of the smaller base. The homothety with center A and ratio γ −1 transforms T into the trapezoid T : Figure 3 for an illustration.
Let B be a point in V 1 (A). Using similar techniques to the ones used by Cabello et al. [6] in the proof of Theorem 1.1, we show that B ∈ T . Let A B be the base segment of AB such that |AA | < |AB |. Since B ∈ V 1 (A), we have |A B | γ|AB|, A ∈ Vis(r , R), and d(B, r ) d(A, r ), where r denotes the root of the base level of AB. Since A is visible from r in R, the base body of AB is the body of A and thus A = A and r = r . As we have observed, every point C ∈ {A} ∪ AB satisfies d(C, r) = d(C) 0.
Let ε > 0. There is a point E ∈ AB such that |B E| < ε. Since E lies on the base segment of AB, there is F ∈ r such that EF ⊆ R. It is possible to choose F so that AH and EF have The points A, E, F, H form a self-intersecting tetragon Q whose boundary is contained in R. Since R is simply connected, the interior of Q is contained in R and the triangles ACE and CF H have area at most smc(R).
The triangle ACE is partitioned into triangles ADE and CDE with areas .
. By the similarity of the triangles CF H and CDE, we have |F H| = |DE|d(C)/(d(E) − d(C)) and therefore Since the first upper bound on |DE| is increasing and the second is decreasing in d(C), the minimum of the two is maximized when they are equal, that is, when ). This and 0 d(E) d(A) imply E ∈ T . Since ε can be made arbitrarily small and T is compact, we have B ∈ T . Since |AB | γ|AB|, we conclude that B ∈ T . This completes the proof of Claim 1.
We assume the point A is not contained in the first level of R, as otherwise V 2 (A) is empty. Let p be the r -parallel line that contains the point A and let q be the supporting line of r. Let p + and q + denote the closed half-planes defined by p and q, respectively, such that r ⊆ p + and A / ∈ q + . Let O be the intersection point of p and q.
on the supporting line of r , and one lateral side on q. The homothety with center O and ratio γ −1 transforms T into the trapezoid T : Figure 3 for an illustration.
Let B be a point of V 2 (A). We use A B to denote the base segment of AB such that |AA | < |AB |. By the definition of V 2 (A), we have |A B | γ|AB|, A / ∈ Vis(r , R), and d(B, r ) d(A, r ), where r denotes the root of the base body of AB. By Lemma 2.6 and the fact that A / ∈ Vis(r , R), we have r = r . The bound d(A, r ) d(B, r ) thus implies A ∈ r ∩ p + and B ∈ q + . We have d(C, r ) = d(C) 0 for every C ∈ A B .

This can be rewritten as
Let (G n ) n∈N be a sequence of points from A B that converges to A . For every n ∈ N, there is a point H n ∈ r such that G n H n ⊆ R. Since r is compact, there is a subsequence of (H n ) n∈N that converges to a point H 0 ∈ r . We claim that H 0 ∈ q. Suppose otherwise, and let q = q be the supporting line of A H 0 . Let ε > 0 be small enough so that N ε (A ) ⊆ R. For n large enough, G n H n is contained in an arbitrarily small neighborhood of q . Consequently, for n large enough, the supporting line of G n H n intersects q at a point K n such that G n K n ⊆ N ε (A ), which implies K n ∈ r ∩ Vis(r , R), a contradiction.
The point E lies on A B and thus it is visible from a point F ∈ r . Again, we can choose F so that the line segments EF and GH have a point C in common where C = F, H. The points E, F, H, G form a self-intersecting tetragon Q whose boundary is in R. The interior of Q is contained in R, as R is simply connected. Therefore, the area of the triangles CEG and CF H is at most smc(R). The argument used in the proof of Claim 1 yields ). This and the fact that δ (and consequently |D D|) can be made arbitrarily small yield |D E| 2 smc(R) ). This and 0 d(E) d(A) imply E ∈ T . Since ε can be made arbitrarily small and T is compact, we have B ∈ T . Since |A B | γ|AB| γ|A B|, we conclude that B ∈ T . This completes the proof of Claim 2.
By Lemma 2.3, the points of r that are visible from A in R form a subsegment CD of r. The homothety with center A and ratio 2(1 − γ) −1 transforms the triagle T := ACD into the triangle T : Figure 5 for an illustration. We claim that The interior of T is contained in R, as all points of the open segment CD are visible from A in R. The area of T is at most smc(R), as its interior is a convex subset of R. Consequently, the area of T is at most (4(1 − γ) −2 − 1) smc(R). This completes the proof of Claim 3.
To put everything together, we set T(A) : Clearly, the set T(A) is measurable. Summing the three estimates on areas of the trapezoids, we obtain for every point A ∈ R. We choose γ ∈ (0, 1) so that the value of the coefficient is minimized. The following lemma is a slightly more general version of a result of Cabello et al. [6].
We clearly have λ 2 (S(A, )) = 0 for points A ∈ S Vis( , S). By Lemma 2.3, the set . Therefore, every point B ∈ S(A, ) is contained in a trapezoid of height |y(A)| with bases of length |CD| and 2|CD|. The area of this trapezoid is 3 2 |CD| · |y(A)| 3 smc(S). Hence we have λ 2 (S(A, )) 3 smc(S) for every point A ∈ S.
Proof of Theorem 1.3. In view of Lemma 2.1, we can assume without loss of generality that S is an open bounded simply connected set. Let be a diagonal of S. We can assume without loss of generality that lies on the x-axis. According to Lemma 2.4, the set S has exactly two p-components S 1 and S 2 , the sets S 1 ∪ and S 2 ∪ are rooted sets, and is their common root. By Lemma 2.7, It follows that the set S is measurable.

A set with large k-index of convexity and small convexity ratio
It remains to estimate b k (S). By Fubini's Theorem we have A countable union of affine subspaces of dimension less than d has d-dimensional measure zero and we already know that λ d (

General dimension
This section is devoted to the proofs of Theorem 1.5 and Theorem 1.6. In both proofs, we use the operator Aff to denote the affine hull of a set of points. First, we present the proof of Theorem 1.5.
Let T = (A 0 , A 1 , . . . , A d ) be a (d + 1)-tuple of distinct affinely independent points in R d . We say that a permutation B 0 , B 1 , . . . , B d of T is a regular permutation of T if the following two conditions hold: Obviously, T has at least two regular permutations due to the interchangeability of B 0 and B 1 . The regular permutation A i0 , A i1 , . . . , A i d with the lexicografically minimal vector with the following two properties: is the box containing all the points P ∈ R d such that the orthogonal projection of It is not hard to see that this gives us a proper definition of Box d (T − ) for every d-tuple T − of d distinct affinely independent points in R d .  We point out that T is considered to be affinely dependent in the above definitions of X and Y i also in the degenerate case when some point of S appears more than once in T . We have for every set T {A i } appearing in the definition of Y i . Therefore, by Fubini's Theorem, the set Y i is λ d(d+1) -measurable and, moreover, This completes the proof of Theorem 1.5. Now, we present the proof of Theorem 1.6. In the following, we make no serious effort to optimize the constants. As the first step towards the proof of Theorem 1.6, we show that if we remove an arbitrary n-tuple of points from the open d-dimensional box (0, 1) d , then the d-index of convexity of the resulting set is of order Ω( 1 n ).
and we let R := 2n i=1 R i . The sets R i are pairwise disjoint and it is not difficult to argue that these sets are measurable. If a (d + 1)-tuple (A 1 , . . . , A d+1 ) is contained in R i for some i ∈ {1, . . . , 2n}, then (A 1 , . . . , A d+1 ) is contained in Simp d (S), as P i (A 1 , . . . , A d−1 ) ∪ (Aff({A 1 , . . . , A d−1 }) ∩ S) is a convex subset of S. Therefore, to find a lower bound for b d (S) = λ d(d+1) (Simp d (S)), it suffices to find a lower bound for λ d(d+1) (R), because R is a subset of Simp d (S).
Applying Fubini's Theorem, we obtain where [φ] is the characteristic function of a logical expression φ, i.e., [φ] equals one if the condition φ holds and zero otherwise. For the measure of R we then derive Since the function x → x 2 is convex, we can apply Jensen's inequality and bound the last term from below by The next step in the proof of Theorem 1.6 is to find a convenient n-tuple N of points from (0, 1) d whose removal produces a set with sufficiently small convexity ratio. To are going to find N using a continuous version of the well-known Epsilon Net Theorem [9]. Before stating this result, we need some definitions.
Let X be a subset of R d and let U be a set system on X. We say that a set T ⊆ X is shattered by U if every subset of T can be obtained as the intersection of some U ∈ U with T . The Vapnik-Chervonenkis dimension (or VC-dimension) of U, denoted by dim(U), is the maximum n (or ∞ if no such maximum exists) for which some subset of X of cardinality n is shattered by U.
Let U be a system of measurable subsets of a set X ⊆ R d with λ d (X) = 1, and let ε ∈ (0, 1) be a real number. A set N ⊆ X is called an ε-net for (X, U) if N ∩ U = ∅ for every U ∈ U with λ d (U ) ε. . Let X be a subset of R d with λ d (X) = 1. Then for every system U of measurable subsets of X with dim(U) v, v 2, there is a 1 r -net for (X, U) of size at most 2vr log 2 r for r sufficiently large with respect to v.
To apply Theorem 4.4, the VC-dimension of the set system U has to be finite. However, it is known that the VC-dimension of all convex sets in R d is infinite (see e.g. [13, page 238]). Therefore, instead of considering convex sets directly, we approximate them by ellipsoids.
A d-dimensional ellipsoid in R d is an image of the closed d-dimensional unit ball under a nonsingular affine map. A convex body in R d is a compact convex subset of R d with non-empty interior. The following result, known as John's Lemma [10], shows that every convex body can be approximated by an inscribed ellipsoid.
In particular, we have λ d (K)/d d λ d (E).
As the last step before the proof of Theorem 1.6, we mention the following fact, which implies that the VC-dimension of the system E of d-dimensional ellipsoids in R d is at most Then dim(P d,t ) d+t d .
Proof of Theorem 1.6. Suppose we are given ε > 0 which is sufficiently small with respect to d. We show how to construct a set S ⊆ R d with λ d (S) = 1 satisfying c(S) ε and Without loss of generality we assume that ε = d d /r for some integer r 2d 2d .
Consider the open d-dimensional box (0, 1) d and the system E (0, 1) d of d-dimensional ellipsoids in (0, 1) d . Since the restriction of E to (0, 1) d does not increase the VC-dimension, Lemma 4.6 implies dim(E (0, 1) d ) d+2 d . If we set n := 2 d+2 d r log 2 r , then, by Theorem 4.4, there is a 1 r -net N for ((0, 1) d , E (0, 1) d ) of size n, having r sufficiently large with respect to d. Let S be the set (0, 1) d N . Clearly, we have λ d (S) = 1.
Suppose K is a convex subset of (0, 1) d with λ d (K) > ε. Since the measure of K is positive, we may assume that K is a convex body of measure at least ε. By Lemma 4.5, the convex body K contains a d-dimensional ellipsoid E with λ d (E) ε/d d = 1 r . Therefore E ∩ N = ∅. Since we have E ⊆ K and N ∩ S = ∅, we see that K is not a subset of S. In other words, we have c(S) ε.
By Lemma 4.3, we have b d (S) 1 2n . According to the choice of n and r, the term 1 2n is bounded from below by where the last inequality follows from the estimate 2d d 1/ε. This completes the proof of Theorem 1.6.
It is a natural question whether the bound for b d (S) in Theorem 1.6 can be improved to b d (S) = Ω(c(S)). In the plane, this is related to the famous problem of Danzer and Rogers (see [5,14] and Problem E14 in [7]) which asks whether for given ε > 0 there is a set N ⊆ (0, 1) 2 of size O( 1 ε ) with the property that every convex set of area ε within the unit square contains at least one point from N .
If this problem was to be answered affirmatively, then we could use such a set N to stab (0, 1) 2 in our proof of Theorem 1.6 which would yield the desired bound for b 2 (S). However it is generally believed that the answer is likely to be nonlinear in 1 ε .

Other variants and open problems
We have seen in Theorem 1.3 that a p-componentwise simply connected set S ⊆ R 2 whose b(S) is defined satisfies b(S) α c(S), for an absolute constant α 180. Equivalently, such a set S satisfies smc(S) b(S)λ 2 (S)/180.
By a result of Blaschke [4] (see also Sas [18]), every convex set K ⊆ R 2 contains a triangle of measure at least 3 √ 3 4π λ 2 (K). In view of this, Theorem 1.3 yields the following consequence. Corollary 5.1. There is a constant α > 0 such that every p-componentwise simply connected set S ⊆ R 2 whose b(S) is defined contains a triangle T ⊆ S of measure at least α b(S)λ 2 (S).
A similar argument works in higher dimensions as well. For every d 2, there is a constant β = β(d) such that every convex set K ⊆ R d contains a simplex of measure at least βλ d (K) (see e.g. Lassak [12]). Therefore, Theorem 1.5 can be rephrased in the following equivalent form. What can we say about sets S ⊆ R 2 that are not p-componentwise simply connected? First of all, we can consider a weaker form of simple connectivity: we call a set S p-componentwise simply ∆-connected if for every triangle T such that ∂T ⊆ S we have T ⊆ S. We conjecture that Theorem 1.3 can be extended to p-componentwise simply ∆-connected sets.

Conjecture 5.3.
There is an absolute constant α > 0 such that every p-componentwise simply ∆-connected set S ⊆ R 2 whose b(S) is defined satisfies b(S) α c(S).
What does the value of b(S) say about a planar set S that does not satisfy even a weak form of simple connectivity? As Example 3.1 shows, such a set may not contain any convex subset of positive measure, even when b(S) is equal to 1. However, we conjecture that a large b(S) implies the existence of a large convex set whose boundary belongs to S.

Conjecture 5.4.
For every ε > 0, there is a δ > 0 such that if S ⊆ R 2 is a set with b(S) ε, then there is a bounded convex set C ⊆ R 2 with λ(C) δλ(S) and ∂C ⊆ S. Theorem 1.3 shows that Conjecture 5.4 holds for p-componentwise simply connected sets, with δ being a constant multiple of ε. It is possible that even in the general setting of Conjecture 5.4, δ may be taken as a constant multiple of ε.
Motivated by Corollary 5.1, we propose a stronger version of Conjecture 5.4, where the convex set C is required to be a triangle.
Note that Conjecture 5.5 holds when restricted to p-componentwise simply connected sets, as implied by Corollary 5.1.
We may generalise Conjecture 5.5 to higher dimensions and to higher-order indices of convexity. To state the general conjecture, we introduce the following notation: for a set X ⊆ R d , let X k be the set of k-element subsets of X, and let the set Skel k (X) be defined by If X is the vertex set of a d-dimensional simplex T = Conv(X), then Skel k (X) is often called the k-dimensional skeleton of T . Our general conjecture states, roughly speaking, that sets with large k-index of convexity should contain the k-dimensional skeleton of a large simplex.
Here is the precise statement.
Conjecture 5.6. For every k, d ∈ N such that 1 k d and every ε > 0, there is a δ > 0 such that if S ⊆ R d is a set with b k (S) ε, then there is a simplex T with vertex set X such that λ d (T ) δλ d (S) and Skel k (X) ⊆ S.
Corollary 5.2 asserts that this conjecture holds in the special case of k = d, since Skel d (X) = Conv(X) = T . Corollary 5.1 shows that the conjecture holds for k = d = 1 if S is further assumed to be p-componentwise simply connected. In all these cases, δ can be taken as a constant multiple of ε, with the constant depending on k and d.
Finally, we may ask whether there is a way to generalize Theorem 1.3 to higher dimensions, by replacing simple connectivity with another topological property. Here is an example of one such possible generalization.
We can prove this conjecture in the special case when S is an appropriate cone of a subset R of R d−1 for which b d−1 (R) is defined. Here, a cone of R is the set {tA : t ∈ [0, 1], A ∈ R × {d}} in R d . It is not difficult to show that for d 2 and R ⊆ R d−1 taking a cone of R preserves c(R) and b k (R) for every k ∈ {1, . . . , d − 1}. The rest then follows from Theorem 1.5. Let AB be a segment contained in S, and let C be a point of AB. We say that C is an isolated boundary point of the segment AB, if C ∈ ∂S, but there is an ε > 0 such that no other point of AB ∩ N ε (C) belongs to ∂S.
We partition the set B into four parts as follows: We claim that each of these sets has measure zero. For B | , this is clear, since B | is a subset of showing that B is measurable. An analogous argument shows that B is measurable, and hence B • is measurable as well.
In the rest of the proof, we will use two basic facts of integral calculus, which we now state explicitly.
Fact 1 (see [17,Lemma 7.25 and Theorem 7.26]). Let X, Y ⊆ R d be two open sets, and let σ : X → Y be a bijection such that both σ and σ −1 are continuous and differentiable on X and Y , respectively. Then, for any X 0 ⊆ X, the set X 0 is measurable if and only if σ(X 0 ) is measurable, and moreover, λ(X 0 ) = 0 if and only if λ(σ(X 0 )) = 0.
Fact 2 (Fubini's Theorem, see [17,Theorem 8.12]). Let M ⊆ R k × R be a measurable set. For x ∈ R k , define M x := {y ∈ R : (x, y) ∈ M }. Then, for almost every x ∈ R k , the set M x is λ -measurable, and Let us prove that λ 4 (B ) = 0. The basic idea is as follows: suppose that we have fixed a non-vertical line L and a point B ∈ L. It can be easily seen that there are at most countably many points A ∈ L such that (A, B) ∈ B . Since a line L with a point B ∈ L can be determined by three parameters, we will see that B has λ 4 -measure zero.
Let us describe this reasoning more rigorously. Let L a,b denote the line {(x, y) ∈ R 2 : y = ax+ b}. Define a mapping σ : R 4 → R 2 × R 2 as follows: σ(a, b, x, x ) = (A, B), where A = (x, ax + b) and B = (x , ax + b). In other words, σ(a, b, x, x ) is the pair of points on the line L a,b whose horizontal coordinates are x and x , respectively. For every non-vertical segment AB, there is a unique quadruple (a, b, x, x ) with x = x , such that σ(a, b, x, x ) = (A, B). In particular, σ is a bijection from the set {(a, b, x, x ) ∈ R 4 : x = x } to the set {(A, B) ∈ R 2 × R 2 : A, B not on the same vertical line}.
For a fixed triple (a, b, x ) ∈ R 3 , let X a,b,x denote the set {x ∈ R : (a, b, x, x ) ∈ B }. We claim that X a,b,x is countable. To see this, choose a point x ∈ X a,b,x and define (A, B) := σ(a, b, x, x ). Since (A, B) ∈ B , we know that A is an isolated boundary point of AB, which implies that there is a closed interval β ⊆ R of positive length such that β ∩ X a,b,x = {x}. This implies that X a,b,x is countable, and therefore of measure zero.
Since B is measurable, we can apply Fubini's Theorem to get Therefore λ 4 ( B ) = 0 as claimed. A similar argument shows that λ 4 ( B ) = 0. It remains to deal with the set B • . We will use the following strategy: we will fix two parallel non-horizontal lines L 1 , L 2 , and study the segments orthogonal to these two lines, with one endpoint on L 1 and the other on L 2 . Roughly speaking, our goal is to show that for 'almost every' choice of L 1 and L 2 , there are 'almost no' segments of this form belonging to B • .
Let L a,b denote the (non-horizontal) line {(ay + b, y) : y ∈ R}. Let us say that a pair of distinct points (A, B) has type (a, b, c), if A ∈ L a,b , B ∈ L a,c , and the segment AB is orthogonal to L a,b (and therefore also to L a,c ). The value a is then called the slope of the type t = (a, b, c).
Note that every pair of distinct points (A, B) defining a non-vertical segment has a unique type (a, b, c), with b = c. Define a mapping τ : τ (a, b, c, y) is the pair of points (A, B) of type (a, b, c) such that A = (ay + b, y). Note that τ is a bijection from the set {(a, b, c, y) ∈ R 4 : b = c} to the set {(A, B) ∈ R 2 × R 2 : A, B not on the same vertical line}. We may easily verify that τ satisfies the assumptions of Fact 1.
By Fubini's Theorem, we have and Y t is measurable for all t ∈ R 3 up to a set of λ 3 -measure zero. An analogous formula holds for B • (α) and Y t (α) for any open interval α ⊆ [0, 1] with rational endpoints. Since there are only countably many such intervals, and a countable union of sets of measure zero has measure zero, we know that there is a set T 0 ⊆ R 3 of measure zero, such that for all t ∈ R 3 T 0 the set Y t is measurable, and moreover for any rational interval α the set Y t (α) is measurable as well.
Our goal is to show that there are at most countably many slopes a ∈ R for which there is a (b, c) ∈ R 2 such that λ 1 (Y (a,b,c) ) > 0. From ( * ) it will then follow that λ 4 (B • ) = 0. To achieve this goal, we will show that to any type t for which λ 1 (Y t ) > 0, we may assign a set R t ⊆ ∂S of positive λ 2 -measure (the region of t), so that if t and t have different slopes and if Figure 7. An illustration for the proof of Lemma A.2. Here the element y 1 of Y t is half-isolated while y 2 is not.
Y t and Y t both have positive measure, then R t and R t are disjoint. Since there cannot be uncountably many disjoint sets of positive measure, this will imply the result.
Let us fix a type t = (a, b, c) ∈ R 3 T 0 such that λ 1 (Y t ) > 0. Let us say that an element Clearly, Y t has at most countably many half-isolated elements. Define Figure 7 for an illustration. Choose y ∈ Y * t , and define (A y , B y ) := τ (a, b, c, y). We claim that A y B y ∩ S • is either empty or a single interval. Let us choose any two points C, D ∈ A y B y ∩ S • . We will show that the segment CD is inside S • . For ε > 0 small enough, the neighborhoods N ε (C) and N ε (D) are subsets of S. Since y is not half-isolated in Y t , we can find two segments P, Q ∈ B • of type t that intersect both N ε (C) and N ε (D), with A y B y being between P and Q. We can then find a closed polygonal curve Γ ⊆ P ∪ Q ∪ N ε (C) ∪ N ε (D) whose interior region contains CD. Since S is p-componentwise simply connected, we see that CD ⊆ S • . Therefore, A y B y ∩ S • is indeed an interval.
Since ∂S is a closed set, we know that for every y ∈ Y * t , the set A y B y ∩ ∂S is closed as well. Moreover, neither A y nor B y are isolated boundary points of A y B y , because then (A y , B y ) would belong to B or B . We conclude that A y B y ∩ ∂S is either equal to a single closed segment of positive length containing A y or B y , or it is equal to a disjoint union of two closed segments of positive length, one of which contains A y and the other contains B y .
For an integer n ∈ N, define two sets Y t (n) and Y t (n) by where we take the union over all rational intervals α intersecting (0, n −1 ). Moreover, we have . It follows that there is an n such that Y t (n) or Y t (n) has positive measure. Fix such an n and assume, without loss of generality, that λ 1 (Y t (n)) is positive. Define the region of t, denoted by R t , by The set R t is a bijective affine image of Y t (n) × (0, n −1 ), and in particular it is λ 2 -measurable with positive measure. Note that R t is a subset of ∂S.
Consider now two types t, t ∈ R 3 T 0 with distinct slopes, such that both Y t and Y t have positive measure. We will show that the regions R t and R t are disjoint.
For contradiction, suppose there is a point C ∈ R t ∩ R t . Let AB and A B be the segments containing C and having types t and t , respectively. Fix ε > 0 small enough, so that none of the four endpoints A, B, A , B lies in N ε (C). Since Y * t has no half-isolated points of Y t , we know that B • has segments of type t arbitrarily close to AB on both sides of AB, and similarly for segments of type t close to A B . We can therefore find four segments P, Q, P , Q ∈ B • {AB, A B } with these properties: • P and Q have type t, and P and Q have type t .
• AB is between P and Q (i.e., AB ⊆ Conv(P ∪ Q)) and A B is between P and Q .
• Both P and Q intersect both P and Q inside N ε (C).
We see that the four points where P ∪ Q intersects P ∪ Q form the vertex set of a parallelogram W whose interior contains the point C. Moreover, the boundary of W is a closed polygonal curve contained in S. Since S is p-componentwise simply connected, W is a subset of S and C belongs to S • . This is a contradiction, since all points of R t (and R t ) belong to ∂S.
We conclude that R t and R t are indeed disjoint. Since there cannot be uncountably many disjoint sets of positive measure in R 2 , there are at most countably many values a ∈ R for which there is a type t = (a, b, c) with λ 1 (Y t ) positive. Consequently, the right-hand side of ( * ) is zero, and so λ 4 (B • ) = 0, as claimed.
Proof of Lemma 2.1. Note that the inequality b(S) α c(S) is equivalent to λ 4 (Seg(S)) α smc(S)λ 2 (S). Call a set S bad if Seg(S) is measurable and b(S) > α c(S) or equivalently λ 4 (Seg(S)) > α smc(S)λ 2 (S). To prove the lemma, we suppose for the sake of contradiction that there exists a bad p-componentwise simply connected set S ⊆ R 2 of finite positive measure.
Note that S is p-componentwise simply connected. Since S is an open set, all its pcomponents are open as well. In particular, S has at most countably many p-components. Let C be the set of p-components of S . Each T ∈ C is a bounded open simply connected set, and therefore cannot be bad. Therefore, showing that S is not bad. This is a contradiction.  S with endpoints B and C. Let ∆ ⊆ S be the closed polygonal curve Γ ∪ BC. We can assume that the curve ∆ is simple using a local redrawing argument. See Figure 8.
The curve ∆ separates R 2 into two regions. The closure of the diagonal is a closed line segment that intersects ∆ in exactly one point. It follows that one endpoint of is in the interior region of ∆. Since the endpoints of do not belong to S, this contradicts the assumption that S is simply connected. Now, we show that the set S has at most two p-components. For a point D ∈ , let Choose another point E ∈ with a neighborhood N ε (E) ⊆ S. We claim that N ε (E) ∩ h − also belongs to S 1 . To see this, note that since DE is a compact subset of the open set S, it has a neighborhood N δ (DE) which is contained in S. Clearly, N δ (DE) ∩ h − is p-connected and therefore belongs to S 1 , hence N ε (E) ∩ h − belongs to S 1 as well. An analogous argument can be made for the half-plane h + and the p-component S 2 .
Since for every p-component S of S , there is a point A ∈ and a neighborhood N ε (A) ⊆ S such that N ε (A) ∩ S = ∅, we see that S 1 and S 2 are the only two p-components of S .
Proof of Lemma 2.4. By Lemma B.1, the set S has of exactly two p-components S 1 and S 2 . It remains to show that S 1 ∪ and S 2 ∪ are rooted sets. Since S 1 and S 2 are p-connected, S 1 ∪ and S 2 ∪ are p-connected as well. To show that S 1 ∪ and S 2 ∪ are simply connected, choose a Jordan curve Γ in, say, S 1 ∪ and let Z be the interior region of Γ. Suppose for contradiction that Z is not a subset of S 1 ∪ .
Since S is simply connected, Z is a subset of S. Therefore, there is a point A of S 2 in Z. Since both S 2 and Z are open, we can even assume that A does not belong to the supporting line of . Let AB be the minimal closed segment parallel to such that B ∈ Γ. Then B belongs to S 1 , A belongs to S 2 , and yet A and B are in the same p-component of S . This contradiction shows that S 1 ∪ and S 2 ∪ are simply connected.
As subsets of the bounded set S, the sets S 1 ∪ and S 2 ∪ are clearly bounded. Lemma B.1 and the fact that S i is open imply that the set S i ∪ is half-open and S i ∩ ∂S i = for i ∈ {1, 2}. Therefore, the sets S 1 ∪ and S 2 ∪ are rooted, and is their root.
Appendix C. Proof of Lemma 2.5 For this entire section, let R be a rooted set and (L k ) k 1 be the partition of R into levels. We will need several auxiliary results in order to prove Lemma 2.5.
For disjoint sets S, T ⊆ R 2 , we say that the set S is T -half-open if every point A ∈ S has a neighborhood N ε (A) that satisfies one of the following two conditions:  (2) for R being half-open. Since AB is compact, there is a finite set X ⊆ AB such that AB ⊆ C∈X N ε C /2 (C). Hence N ε (AB) ⊆ C∈X N ε C (C), where ε = min C∈X ε C /2. It follows that N ε (AB) ∩ ∂R is an open segment Q containing B but not A and splitting N ε (AB) into two subsets, one of which (including Q) is N ε (AB) ∩ R and the other (excluding Q) is N ε (AB) R. Let ε be the minimum of ε and the distance of A to the line containing Q. It follows that N ε (A) ⊆ N ε (AB) ∩ R. Therefore, for every A ∈ N ε (A), We say that a set P ⊆ R is R-convex when the following holds for any two points A, B ∈ P : if AB ⊆ R, then AB ⊆ P .
Proof. This follows directly from Lemma 2.3.
A branch of R is a p-component of k 2 L k .

Lemma C.3. Every branch of R is R-convex.
Proof. Let P be a branch of R, and let A, B ∈ P be such that AB ⊆ R. Since R is half-open, it follows that AB ⊆ R • . Suppose AB ⊆ P . It follows that AB ∩ L 1 = ∅. Since L 1 is (R 2 R)-half-open (Lemma C.1) and R-convex (Lemma C.2), we see that AB ∩ L 1 is an open segment A B for some A , B ∈ AB. It follows that A , B ∈ P .
There is a simple polygonal line in P connecting A with B , which together with A B forms a Jordan curve Γ in R. Now, let C ∈ A B . Since C ∈ L 1 , there is a point D on the root of R such that CD ⊆ R. Since A , B / ∈ L 1 , D does not lie on the supporting line of A B . Extend the segment DC beyond C until hitting ∂R at a point C . Here we have used the fact that R is bounded. Since R is simply connected, the entire interior region of Γ is contained in R, so the points D and C both lie in the exterior region of Γ. However, since Γ ∩ L 1 = A B , the line segment DC crosses Γ at exactly one point, which is C. This is a contradiction.
Lemma C.4. The set L 1 and every branch of R are p-connected and simply connected.
Proof. Let P be the set L 1 or a branch of R. It follows directly from the definitions of L 1 and a branch of R that P is p-connected. To see that P is simply connected, let Γ be a Jordan curve in P , A be a point in the interior region of Γ, and BC be an inclusion-maximal open line segment in the interior region of Γ such that A ∈ BC. It follows that B, C ∈ Γ and BC ⊆ R, as R is simply connected. Since B, C ∈ P and P is R-convex (Lemmas C.2 and C.3), we have A ∈ P .

Lemma C.5. Every branch of
Proof. Let P be a branch of R. It is enough to check the condition (2) for P being L 1 -half-open for points in ∂P ∩ P . Let A ∈ ∂P ∩ P . Since R is half-open, A has a neighborhood N ε (A) that satisfies the condition (1) or (2) for S being half-open. It cannot be (2), as then A would lie on the root of R and thus in L 1 . Hence N ε (A) ⊆ R.
Since L 1 is (R 2 R)-half-open (Lemma C.1) and R-convex (Lemma C.2) and A / ∈ L 1 , the set N ε (A) ∩ L 1 lies entirely in some open half-plane h whose boundary line passes through A. The set N ε (A) h is p-connected and contains A, so it lies entirely within P . The set N ε (A)∩h is disjoint from P . Indeed, if there was a point B ∈ N ε (A) ∩ h ∩ P , then by the R-convexity of P (Lemma C.3), the convex hull of N ε (A) h and B would lie entirely within P and would contain A in its interior, which would contradict the assumption that A ∈ ∂P . It follows that N ε (A) ∩ ∂P is an open segment that partitions N ε (A) into two half-discs, one of which We show that N ε (A) ∩ ∂P ⊆ ∂L 1 . Suppose to the contrary that there is a point A ∈ N ε (A) ∩ ∂P L 1 . It follows that A has a neighborhood N ε (A ) ⊆ N ε (A) L 1 . Since N ε (A ) is p-connected and contains a point of P , it lies entirely within P . This contradicts the assumption that A ∈ ∂P . Since The latter implies that A C ⊆ P , as A ∈ P . Hence C = A . This shows the whole triangle T spanned by N ε (A) ∩ ∂P and B excluding the open segment N ε (A) ∩ ∂P is contained in L 1 .
Since A lies in the interior of N ε (A) ∩ (P ∪ T ), it has a neighborhood N ε (A) that lies entirely within N ε (A) ∩ (P ∪ T ). This neighborhood witnesses the condition (2) for P being L 1 -half-open.
Lemma C.6. Let P be a branch of R. If A 0 , A 1 ∈ P ∩ ∂P , then A 0 A 1 ⊆ R.
Proof. Let A 0 , A 1 ∈ P ∩ ∂P . By Lemma C.5, P is L 1 -half-open, hence there are B 0 , B 1 ∈ L 1 such that A 0 B 0 {A 0 } ⊆ L 1 and A 1 B 1 {A 1 } ⊆ L 1 . There is a polygonal line Γ 1 in P connecting A 0 with A 1 , and a polygonal line Γ 2 in L 1 connecting B 0 with B 1 . These polygonal lines together with the line segments A 0 B 0 and A 1 B 1 form a closed polygonal curve Γ in R. We can assume without loss of generality that Γ is simple (see Figure 8) and that the x-coordinates of A 0 and A 1 are equal to 0. We also assume that no two vertices of Γ except A 0 and A 1 have the same x-coordinates.
Color the points of Γ so that those in L 1 are red and those in P are blue. For convenience, assume that A 0 and A 1 have both colors. Let Z denote the interior region delimited by Γ including Γ itself. Since R is simply connected, we see that Z is contained in R.
Let x 1 < · · · < x n be the x-coordinates of all vertices of Γ. Let [n] be the shorthand notation for the set of indices {1, . . . , n}. Since the x-coordinates of A 0 and A 1 are zero, there is j ∈ [n] such that x j = 0. For i ∈ [n], we let i := {x i } × R. Since the x-coordinates of the vertices of Γ {A 0 , A 1 } are distinct, there is at most one vertex of Γ on i for every i ∈ [n] {j}. For i ∈ [n], the intersection of Z with i is a family of closed line segments with endpoints from Γ ∩ i . Some of the segments can be trivial, which means that they consist of a single point, and some can contain a point of Γ in their interior.
For i ∈ [n] and a point A ∈ Γ ∩ i , we say that a point B is a left neighbor of A if B lies on Γ ∩ i−1 and AB ⊆ Γ. Similarly, B is a right neighbor of A if B ∈ Γ ∩ i+1 and AB ⊆ Γ. Note that every point A ∈ Γ ∩ i has exactly two neighbors and if A / ∈ {A 0 , A 1 }, then the neighbors of A have the same color as A. We distinguish two types of points of Γ ∩ i . We say that a point A ∈ Γ ∩ i is one-sided if it either has two right or two left neighbors. Otherwise, we Figure 9. Situation in the proof of Lemma C.6. Here A is a left neighbor of C and B is a left neighbor of D. The points B, C, and D are two-sided, the points A and E are one-sided.
say that A is two-sided. That is, A is two-sided if it has one left and one right neighbor. See Figure 9.
Note that every one-sided point is a vertex of Γ and that one-sided points from Γ ∩ i are exactly the points of Γ ∩ i that either form a trivial line segment or that are contained in the interior of some line segment of Z ∩ i . Consequently, every line segment in Z ∩ i contains at most one point of Γ in its interior.
For 2 i n and C, D ∈ i ∩ Γ, let CD be a line segment in Z ∩ i whose interior does not contain a point of Γ with a left neighbor. Let A and B be left neighbors of C and D, respectively, such that there is no left neighbor of C and D between A and B on i−1 . Since no point between A and B on i−1 can have a right neighbor, we have AB ⊆ Z ∩ i−1 and A, B, C, D are vertices of a trapezoid whose interior is contained in Z. An analogous statement holds for right neighbors of C and D provided that the interior of CD does not contain a point of Γ with a right neighbor.
Claim. Let i ∈ [n] {j}, and let C and D be points of Γ ∩ i satisfying CD ⊆ Z ∩ i . Then C and D have the same color.
First, we are going to prove the claim by induction on i for all i < j. The claim clearly holds for i = 1, as Z ∩ 1 contains only a single vertex of Γ. Fix i with 1 < i < j and suppose that the claim holds for i − 1. Let C, D ∈ Γ ∩ i be points satisfying CD ⊆ Z ∩ i . We show that C and D have the same color. Obviously, we may assume that the line segment CD is non-trivial. Assume first that the points C and D are two-sided.
Suppose the interior of CD does not contain a point of Γ with a left neighbor. Let A, B ∈ Γ ∩ i−1 be the left neighbors of C and D, respectively. Then AB ⊆ Z ∩ i−1 . Thus A and B have the same color by the induction hypothesis. Since C, D / ∈ {A 0 , A 1 }, the points A and C have the same color as well as B and D. This implies that C and D have the same color too. If there is a point E of Γ in the interior of CD, then it follows from R-convexity of P (Lemma C.3) and L 1 (Lemma C.2) that E has the same color as C and D.
Suppose the interior of CD contains (exactly) one point of Γ with a left neighbor. Let E ∈ Γ be such a point. We know that E has two left neighbors. The points C and E with their left neighbors A and B, where there is no left neighbor of E between A and B on i−1 , again form a trapezoid in Z such that AB ⊆ Z ∩ i−1 . From induction hypothesis A and B have the same color which implies that C and E have the same color as well. Similarly, D and E have the same color which implies that C and D have the same color as well.
The case where either C or D is one-sided is covered by the previous cases. The same inductive argument but in the reverse direction shows the claim for all i with j < i n. This finishes the proof of the claim. Now, consider the maximal line segment CD of Z ∩ j that contains A 0 . We may assume that either C and D are two-sided or C = D. We show that A 1 ∈ CD. Suppose for a contradiction that A 1 is not contained in CD. If CD is trivial, that is, C = D = A 0 , then A 0 is one-sided and its neighbors A and B have different colors, as Γ changes color in A 0 . This, however, is impossible according to the claim, since AB ⊆ Z ∩ i−1 or AB ⊆ Z ∩ i+1 . Therefore CD is non-trivial. First, we assume that A 0 is an endpoint of CD, say C = A 0 . Then A 0 is two-sided and we may assume that the left neighbor A of A 0 and the left neighbor B of D have different colors, as the other case is symmetric. If there is no point of Γ with a left neighbor in the interior of A 0 D, then AB ⊆ Z ∩ i−1 . This is impossible according to the claim. If there is a point E ∈ Γ with a left neighbor in the interior of A 0 D, then we can use a similar argument either for the line segment A 0 E or for ED, as the neighbors of E have the same color. The last case is when A 0 is an interior point of CD. Since the neighbors of C and D have the same color, we apply the claim to one of the line segments A 0 C, A 0 D, and CD and show, again, that none of the cases is possible. Altogether, we have derived a contradiction.
Therefore, A 0 and A 1 are contained in the same line segment of Z ∩ i . This completes the proof of Lemma C.6, as Z ⊆ R.
Lemma C.7. For every branch P of R, the set P ∩ ∂P is an open segment.
Proof. Let P be a branch of R. First, we show that the set P ∩ ∂P is convex. Let A 0 , A 1 ∈ P ∩ ∂P . By Lemma C.6, we have A 0 A 1 ⊆ R. It follows that A 0 A 1 is disjoint from the root of R and thus is contained in R • . By compactness, A 0 A 1 has a neighborhood N ε (A 0 A 1 ) contained in R • . Since P is L 1 -half-open by Lemma C.5, there are B 0 , B 1 ∈ N ε (A 0 A 1 ) ∩ L 1 such that A 0 B 0 {A 0 } ⊆ L 1 and A 1 B 1 {A 1 } ⊆ L 1 . For t ∈ [0, 1], let A t = (1 − t)A 0 + tA 1 and B t = (1 − t)B 0 + tB 1 . We have A t ∈ A 0 A 1 and B t ∈ B 0 B 1 , hence A t , B t ∈ N ε (A 0 A 1 ), for all t ∈ [0, 1]. Now, it follows from the R-convexity of P (Lemma C.3) and L 1 (Lemma C.2) that A t ∈ P and A t B t {A t } ⊆ L 1 , hence A t ∈ P ∩ ∂P , for all t ∈ [0, 1]. This shows that P ∩ ∂P is convex.
If P ∩ ∂P had three non-collinear points, then they would span a triangle with non-empty interior contained in P ∩ ∂P , which would be a contradiction. Since R is bounded, the set P ∩ ∂P is a line segment. That it is an open line segment follows directly from Lemma C.5.
Lemma C.8. Let j 2. Every p-component P of k j L k is a rooted set attached to L j−1 . Moreover, for k 1, the kth level of P is equal to L j−1+k ∩ P .
Proof. The proof proceeds by induction on j. For the base case, let P be a p-component of i 2 L i , that is, a branch of R. It follows from Lemmas C.4, C.5 and C.7 that P is a rooted set attached to L 1 . Let be the root of P . Let (L k ) k 1 be the partition of P into levels. We prove that L k ⊆ k+1 i=1 L i and L k+1 ∩ P ⊆ k i=1 L i for every k 1. Let A ∈ L k . It follows that there is a polygonal line Γ with k line segments connecting A to a point B ∈ . Moreover, since there is no shorter polygonal line connecting A to , the last line segment of Γ is not parallel to . Since P is L 1 -half-open (Lemma C.5), there is a neighborhood N ε (B) that is split by into two parts, one of which is a subset of L 1 . Let C be a point in N ε (B) ∩ L 1 such that BC is an extension of the last line segment of Γ. Since C ∈ L 1 , there is a point D on the root of R such that CD ⊆ L 1 . The polygonal line Γ extended by BC and CD forms a polygonal line with k + 1 line segments connecting A to the root of R. This shows that L k ⊆ k+1 i=1 L i . Now, let A ∈ L k+1 ∩ P . It follows that there is a polygonal line Γ with k + 1 line segments connecting A to the root of R. Since L 1 is an open subset of R (Lemma C.1) and P is a p-component of R L 1 , there is a point B ∈ Γ such that the part of Γ between A and B (inclusive) is contained in P and is maximal with this property. It follows that B ∈ . Since B / ∈ L 1 , the part of Γ between A and B consists of at most k segments. This shows that L k+1 ∩ P ⊆ k i=1 L i . We have thus proved that L k ⊆ k+1 i=1 L i and L k+1 ∩ P ⊆ k i=1 L i for every k 1. To conclude the proof of the base case, we note that a straightforward induction shows that L k = L k+1 ∩ P for every k 1.
For the induction step, let j 3, and let P be a p-component of i j L i . Let Q be the branch of R containing P . Let (L k ) k 1 be the partition of Q into levels. As we have proved for the base case, we have L k = L k+1 ∩ Q for every k 1. Hence P is a p-component of ( i j L i ) ∩ Q = i j−1 L i . By the induction hypothesis, P is a rooted set attached to L j−2 ⊆ L j−1 . Moreover, for k 1, the kth level of P is equal to L j−2+k ∩ P = L j−1+k . This completes the induction step and proves the lemma.
Proof of Lemma 2.5. The statement (1) is a direct consequence of the definition of a rooted set, specifically, of the condition that a rooted set is p-connected.
For the proof of the statement (2), let P be a j-body of R. If j = 1, then P = L 1 = Vis(r, R) = Vis(r, L 1 ), where r denotes the root of R, and by Lemmas C.1 and C.4, L 1 is rooted with the same root r. Now, suppose j 2. Let Q be the p-component of k j L k containing P . By Lemma C.8, Q is a rooted set and L j ∩ Q is the first level of Q. Since P ⊆ L j ∩ Q, the definition of the first level yields P = L j ∩ Q = Vis(r, Q) = Vis(r, P ), where r denotes the root of Q. By Lemma C.1, P is a rooted set with the same root r.
The statement (3) is a direct consequence of Lemma C.1 and the fact that L 1 is p-connected. Finally, for the proof of the statement (4), let P be a j-body of R with j 2. Let Q be the p-component of k j L k containing P . As we have proved above, Q is a rooted set and P is the first level of Q and shares the root with Q. Moreover, by Lemma C.8, Q (and hence P ) is attached to L j−1 . The definition of attachment implies that P is attached to a single p-component of L j−1 , that is, a single (j − 1)-body of R.