The Jordan curve theorem for polygons #
Statements of the separation properties of polygonal simple closed curves in the plane, following Moise, Geometric Topology in Dimensions 2 and 3, Ch. 2 ("Separation properties of polygons in R²"). Only the polygonal case is stated: this is what the triangulation theorem consumes (via the combinatorial Schoenflies theorem, Moise Thm. 5.3). The full Jordan curve theorem (Moise Ch. 4) is not on the triangulation route's critical path.
PolygonalCircle is the honest object: cyclically indexed vertices joined by genuine segments,
with adjacent segments meeting exactly at their shared vertex and non-adjacent segments disjoint.
A junk witness cannot satisfy these fields: they force the carrier to be a topological circle.
A polygonal simple closed curve in the plane: at least three vertices, cyclically indexed, with consecutive vertices distinct, adjacent edges meeting exactly in their shared vertex, and non-adjacent edges disjoint.
- n : ℕ
The number of vertices (and edges).
A polygon has at least three vertices.
The cyclically indexed vertices.
Consecutive vertices are distinct, so every edge is a genuine segment.
- consecutive_inter (i : ZMod self.n) : segment ℝ (self.vertex i) (self.vertex (i + 1)) ∩ segment ℝ (self.vertex (i + 1)) (self.vertex (i + 2)) = {self.vertex (i + 1)}
Adjacent edges meet exactly in their shared vertex.
- nonadjacent_disjoint (i j : ZMod self.n) : i ≠ j → i ≠ j + 1 → j ≠ i + 1 → segment ℝ (self.vertex i) (self.vertex (i + 1)) ∩ segment ℝ (self.vertex j) (self.vertex (j + 1)) = ∅
Non-adjacent edges are disjoint.
Instances For
The edge from vertex i to vertex i + 1.
Instances For
Two edge indices are nonadjacent when the corresponding edges share no endpoint.
Instances For
The carrier of the polygon: the union of its edges.
Equations
- J.carrier = ⋃ (i : ZMod J.n), J.edgeSegment i
Instances For
The carrier of a polygon is compact.
Transport a polygon through a function which is injective on its carrier and straight on each edge. No extension to an ambient homeomorphism is needed.
Equations
Instances For
Transport a polygon through a homeomorphism which is straight on each polygon edge.
Equations
Instances For
There is a uniform positive lower bound on distances between nonadjacent polygon edges.
Nonadjacent edges have disjoint tubes of one uniform positive radius.
A vertex lies on exactly its outgoing and incoming polygon edges.
The vertices of a simple polygon are pairwise distinct.
There is a uniform positive lower bound between every vertex and every edge not incident to that vertex.
A single feature radius simultaneously controls edge lengths, nonadjacent-edge separation, and vertex-to-nonincident-edge separation.
Inside the vertex-to-nonincident-edge separation radius, every point of the carrier lies on one of the two edges incident to the vertex.
A ball inside the feature radius sees exactly the two polygon edges incident to its center vertex. This is the local isolation input for the vertex sectors of Moise's strip.
The local angular model at a polygon vertex #
The open radial sector of radius r swept counterclockwise from direction a to direction
b. It is parametrized by an open rectangle, avoiding the center and both boundary rays.
Equations
Instances For
An open angular sector of positive radius and nonzero angle is path connected.
Every point in an open angular sector lies in the punctured open disk of the stated radius.
The unit direction of a nonzero complex vector.
Equations
Instances For
Polar reconstruction from norm and unit direction.
The open radial ray in direction a, truncated at radius r.
Equations
Instances For
The two angular sectors and their two boundary rays partition the punctured disk.
The standard linear isometry from the project's Euclidean plane to the complex plane.
Equations
Instances For
Equality of complex unit directions reflects equality of normalized plane vectors.
Two nonzero vectors with the same normalized direction have a common nonzero initial point on their segments from the origin.
The ray from vertex i toward the next vertex.
Instances For
The ray from vertex i toward the preceding vertex.
Instances For
The two unit directions cut out by the incident edges at a polygon vertex are distinct.
An interior point of an angular sector does not have either boundary direction.
A small positive rotation from the initial boundary direction lies in the angular sector.
A small negative rotation from the terminal boundary direction lies in the angular sector.
The outgoing complex direction at a polygon vertex.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The complex direction from a polygon vertex toward its predecessor.
Equations
- One or more equations did not get rendered due to their size.
Instances For
At the terminal endpoint of an edge, its incoming ray points opposite to its oriented outgoing direction.
One of the two open sectors in the vertex ball, transported back from the complex plane.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The other open sector in the vertex ball.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The outgoing edge ray is in the closure of each local side sector.
The incoming edge ray is in the closure of each local side sector.
Either transported angular sector lies in its vertex ball and avoids the polygon, provided the ball sees only the two incident edges.
A short radial ray in the direction of u transports into the segment from p to
p + u.
The punctured vertex ball is exactly the union of its two angular sectors.
Rectangular coordinates along an edge #
Length of edge i.
Equations
- J.edgeLength i = ‖J.outgoingVector i‖
Instances For
Complex coordinates centered at the initial vertex and divided by the oriented unit edge
direction. The edge itself is the real interval from 0 to edgeLength.
Equations
Instances For
Inverse edge coordinates.
Equations
Instances For
An open rectangular tube around the central part of edge i.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The positive-imaginary half of the edge tube.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The negative-imaginary half of the edge tube.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The central edge axis is approached from the positive side rectangle.
The central edge axis is approached from the negative side rectangle.
Removing the polygon from a central edge tube leaves exactly its positive and negative rectangular halves.
Distinct polygon edges can meet only at an endpoint of the first edge.
The union of all polygon edges other than edge i.
Equations
- J.otherEdges i = ⋃ (j : ZMod J.n), ⋃ (_ : j ≠ i), J.edgeSegment j
Instances For
Near a relative-interior point of a polygon edge, the carrier consists only of that edge.
If a straight subsegment of the polygon carrier passes through a polygon vertex, its two local sides occupy the two incident polygon edges.
An edge meeting the relative interior of a straight subsegment of the carrier overlaps that subsegment in at least two points.
In normalized ear coordinates, every polygon edge meeting the open base lies on the horizontal base line.
The closed central subsegment obtained by trimming 2 * trim from both endpoint coordinates.
Equations
- J.edgeCore i trim = (fun (s : ℝ) => J.edgeCoordinateInv i ↑s) '' Set.Icc (2 * trim) (J.edgeLength i - 2 * trim)
Instances For
Inverse edge coordinates preserve distances.
After fixing a longitudinal trim, one can choose a uniform thinner transverse width so that every central edge tube meets the polygon only in its own edge.
Points on an edge have a real edge coordinate between zero and the edge length.
The explicit open strip made from vertex balls and the isolated central edge tubes.
Equations
Instances For
Vertex balls cover the endpoint portions of every edge and the central tube covers the remainder.
Quantitative scales for the explicit polygon strip.
Instances For
The forward vertex sectors and positive edge rectangles.
Equations
- J.stripForwardPieces S = (⋃ (i : ZMod J.n), J.vertexForwardSector i (3 * S.trim)) ∪ ⋃ (i : ZMod J.n), J.edgePositiveSide i S.trim S.width
Instances For
The backward vertex sectors and negative edge rectangles.
Equations
- J.stripBackwardPieces S = (⋃ (i : ZMod J.n), J.vertexBackwardSector i (3 * S.trim)) ∪ ⋃ (i : ZMod J.n), J.edgeNegativeSide i S.trim S.width
Instances For
The punctured explicit strip is exactly the union of all its local forward and backward pieces.
A single sufficiently small positive angle gives overlap points for both sides of an edge at both endpoint vertex sectors.
The two side rectangles at the initial endpoint of an edge overlap the corresponding vertex sectors.
Coordinates measured from an edge's terminal endpoint run in the opposite direction.
The two side rectangles at the terminal endpoint of an edge overlap the corresponding vertex sectors.
A graph-connected union of path-connected sets is path-connected. This is the path analogue
of IsConnected.iUnion_of_reflTransGen.
Every point of the polygon is approached from both of the explicit strip bands.
A genuine segment in the plane has empty planar interior.
A finite polygonal carrier has empty interior in the plane.
The carrier of a polygon is connected: it is a cyclic union of connected segments, with each segment meeting the next one at their common vertex.
Every point off the polygon can be joined by a single polygon-avoiding segment to any open neighborhood of the polygon. This is the "reach the strip" part of Moise Ch. 2, Thm. 1, Lemma 1.
The crossing index (Moise Ch. 2, proof of Thm. 1, Lemma 2) #
The parity of the number of polygon edges crossed by the leftward horizontal ray from a point. We use the half-open edge convention (an edge is crossed when the point's height lies in the half-open interval between the endpoint heights): this replaces Moise's "slightly perturbed line" device, needs no general-position choice of axes, and makes the index everywhere defined. Horizontal edges are never crossed.
The x-coordinate at height y of the line through v and w (meaningful when the heights
of v and w differ, which the crossing condition guarantees at use sites).
Equations
Instances For
The leftward horizontal ray from P crosses edge i, with the half-open height
convention.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The Moise index of a point: the parity of the number of edges crossed by its leftward horizontal ray.
Instances For
There are points off the polygon with index zero.
The handshake lemma for the local-constancy casework #
Near a point P off the polygon, the only edges whose crossing status is not locally constant
are those with exactly one endpoint at the height of P, that endpoint lying strictly to the
left of P: rising edges switch on and falling edges switch off as the query point's height
crosses P's. The index is therefore locally constant provided the number of such edges is
even, which is a double-counting argument: every vertex has two incident edges, a horizontal
partner of a left vertex is itself a left vertex (otherwise the horizontal edge would contain
P), and so the non-horizontal incident edges of the left vertices pair up.
A point at the height of a horizontal segment, with abscissa between the endpoints, lies on the segment.
The vertices at the height of P, strictly to its left.
Equations
Instances For
Edges with one endpoint at the height of P and left of P, the other endpoint strictly
above.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Edges with one endpoint at the height of P and left of P, the other endpoint strictly
below.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The horizontal partner of a left vertex is a left vertex: otherwise the horizontal edge
between them would contain P.
The handshake lemma: the flipping edges (up-left plus down-left) are even in number.
Per-edge behavior of the crossing status near a point off the polygon #
The crossing abscissa depends continuously on the query point.
A point whose height lies in an edge's band and whose abscissa is the crossing abscissa lies on that edge.
Carrier-level form of mem_edgeSegment_of_crossing.
On a nonhorizontal edge, the crossing formula recovers the abscissa of every point of the edge.
At a height different from both endpoint heights, a point of an edge lies strictly between those heights.
Two edges containing the same point away from all vertices are the same edge.
A polygon has a nonhorizontal edge. Otherwise, at a leftmost vertex the two incident horizontal edges overlap in more than their common endpoint.
Horizontal edges are never crossed.
Near a point off the polygon, each edge's crossing status is: switched by the query height for the flipping edges, constant otherwise.
Sub-boundary (Moise Ch. 2, Thm. 1, Lemma 2, local constancy of the index).
Off the polygon the crossing index is locally constant. The proof is elementary casework: for
Q near P, the crossing status of each edge is unchanged unless the ray endpoint passes a
vertex height, and at a vertex height the half-open convention makes the count change by 0 or
2 (the two edges at that vertex are both gained or both lost when they point to the same side,
and exchanged when they point to opposite sides).
Sub-boundary (Moise Ch. 2, Thm. 1, Lemma 2, existence of an inside point).
Some point off the polygon has index one: take a height that is no vertex height but is attained
by the polygon, let P₁ be the leftmost polygon point at that height, and move slightly right of
P₁. (Moise's construction; requires knowing the polygon is not contained in a single
horizontal line, which follows from the embedding fields.)
The part of the polygon complement having crossing index k. Only k = 0, 1 are
nonempty.
Equations
Instances For
Every index region is open, since the carrier is closed and the index is locally constant on its complement.
The index-zero region is unbounded: it contains points arbitrarily high above the polygon.
The polygon is the frontier of its full complement.
Every polygon point is approached by at least one of the two index sides. The remaining two-sided frontier step is to show that it is approached by both.
The crossing index is constant on every preconnected subset of the polygon complement.
A path in the polygon complement has constant crossing index.
A path in a neighborhood of the polygon complement whose initial point has index k stays
in the index-k part of that neighborhood.
The precise output needed from Moise's informal strip construction. The two gates are not labelled as inside and outside: every strip-complement point merely has to be path-joinable to one of them. The crossing index subsequently proves that the gates lie on different sides, so this interface also covers Moise's a priori "Möbius strip" possibility.
The open strip neighborhood.
- gateA : Plane
Two candidate path-component representatives.
- gateB : Plane
The
gateBdeclaration. - reaches {P : Plane} : P ∈ self.strip \ J.carrier → JoinedIn (self.strip \ J.carrier) self.gateA P ∨ JoinedIn (self.strip \ J.carrier) self.gateB P
Every point of the punctured strip reaches one of the two gates.
- gateA_approaches : J.carrier ⊆ closure {P : Plane | P ∈ self.strip \ J.carrier ∧ JoinedIn (self.strip \ J.carrier) self.gateA P}
Both gate components accumulate on every point of the core polygon.
Instances For
The explicit polygon strip provides the two-gate local separation data used by the crossing index argument.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The path component represented by the first gate, written as an ambient set.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The path component represented by the second gate, written as an ambient set.
Equations
- One or more equations did not get rendered due to their size.
Instances For
If gate A has index k, every carrier point belongs to the frontier of the index-k
region.
If gate B has index k, every carrier point belongs to the frontier of the index-k
region.
Every nonempty index region meets every open neighborhood of the polygon. A point is joined
to the neighborhood by the visibility segment from exists_segment_to_open_neighborhood, and
the index is constant on that segment.
The crossing index rules out the a priori possibility that the punctured strip has only one path component.
Every point of the polygon is approached from the index-zero gate component.
Every point of the polygon is approached from the index-one gate component.
The two index sides of a two-gate strip are path connected. This is the formal form of the last sentence in Moise Ch. 2, Thm. 1, Lemma 1: the index forces the two gates to represent the two different strip components.
If one index side is preconnected inside an open strip neighborhood of the polygon, then the
whole index side is preconnected. The proof joins arbitrary points to the strip using
exists_segment_to_open_neighborhood.
The index-one region is bounded. Outside a ball containing the polygon, every point lies on a large connected circle with a point above the polygon, where the index is zero.
Moise Ch. 2, Thm. 1, Lemma 2: the complement of a polygon is disconnected. Proved from the index machinery: the index-0 and index-1 loci are relatively open (local constancy), cover the complement (the index is a parity), and are both nonempty.
Once the explicit two-gate strip has been constructed, all global parts of polygonal Jordan follow from the crossing index and the visibility-to-strip lemma.
Jordan curve theorem for polygons (Moise Ch. 2, Thms. 1, 5, 6).
The complement of a polygon has exactly two connected components: a bounded interior and an unbounded exterior, both open, and the polygon is the frontier of each.
Must-fail check: the statement forces interior ∪ exterior = carrierᶜ with both sides connected
and the frontiers equal to the carrier, so it cannot be satisfied by choosing junk open sets.
The interior region of a polygon (the bounded complementary component).
Equations
- J.interiorRegion = ⋯.choose
Instances For
The exterior region of a polygon (the unbounded complementary component).
Equations
- J.exteriorRegion = ⋯.choose
Instances For
The closed region bounded by a polygon: the closure of its interior region.