Segments and rays #
In this file, we define the class of segments, rays, and their coercions, as well as basic properties. A more precise plan in terms of sections is as follows:
- (1) (definition) We define the corresponding classes: rays, segments, and nondegenerate segments.
- (2) (make) We define the make functions of rays, segments, and nondegenerate segments.
- (3) (coercion) We define the coercions among rays, segments, and nondegenerate segments, as well as coercions to directions, or projective directions.
- (4) (coercion-compatibility) We discuss compatibility of coercion functions.
- (5) (lieson-compatibility) We discuss compatibility regarding points lying on or in the interior of segments or rays.
- (6) (reverse) We introduce the concept of reversing a segment and reversing a ray.
- (7) (extension) We define the extension ray of a nondegenerate segment.
- (8) (length) We define the length function of a segment.
- (9) (midpoint) We define the function that gives the midpoint of a segment.
- (10) (archimedean) We discuss the Archimedean property of a segment.
Important definitions #
- Class
Ray
: A \emph{ray} consists of the pair of its source point $P$ and its direction. - Class
Seg
: A \emph{segment} consists of a pair of points: the source and the target. (We allow the source and the target to be the same.) - Subclass
SegND
: A \emph{nondegenerate segment} is a segment whose source and target are not equal. - Definition
Seg.length
: The function that gives the length of a given segment. - Definition
Ray.reverse
: Given a ray, this function returns the ray with the same source but with reversed direction. - Definition
Seg.reverse
: Given a segment, this function swapped its source and target point. - Definition
SegND.reverse
: Given a nondegenerate segment, this function swapped its source and target point. - Definition
SegND.extension
: Given a nondegenerate segment, this function returns the extension ray of the segment. - Definition
Seg.midpoint
: This function returns the hmidpoint of a segment.
List of notations #
SEG A B
: notation for the segment with source $A$ and target $B$.SEG_nd A B
: notation for the segment with source $A$ and target $B$, where $h$ is a proof of that $A \neq B$.RAY A B h
: notation for the ray with source $A$ in the direction of $B$, where $h$ is a proof of that $A \neq B$.
List of main theorems #
Implementation notes #
Further works #
(1) Definition #
A \emph{ray} consists of a pair of a point $P$ and a direction; it is the ray that starts at the point and extends in the given direction.
- source : P
returns the source of the ray.
- toDir : EuclidGeom.Dir
returns the direction of the ray.
Instances For
Alias of EuclidGeom.Ray.mk
.
Equations
Instances For
A \emph{Segment} consists of a pair of points: the source and the target; it is the segment from the source to the target. (We allow the source and the target to be the same.)
- source : P
returns the source of the segment.
- target : P
returns the target of the segment.
Instances For
Given a segment $AB$, this function returns whether the segment $AB$ is nondegenerate, i.e. whether $A \neq B$.
Equations
- EuclidGeom.Seg.IsND seg = (seg.target ≠ seg.source)
Instances For
A \emph{nondegenerate segment} is a segment $AB$ that is nondegenerate, i.e. $A \neq B$.
Equations
- EuclidGeom.SegND P = { seg : EuclidGeom.Seg P // EuclidGeom.Seg.IsND seg }
Instances For
(2) Make #
Given two points $A$ and $B$, this returns the segment with source $A$ and target $B$. It is an abbreviation of $\verb|Seg.mk|$.
Equations
- EuclidGeom.termSEG = Lean.ParserDescr.node `EuclidGeom.termSEG 1024 (Lean.ParserDescr.symbol "SEG")
Instances For
Given two distinct points $A$ and $B$, this function returns a nondegenerate segment with source $A$ and target $B$. We use $\verb|SEG_nd|$ to abbreviate $\verb|SegND.mk|$.
Equations
- SEG_nd A B h = { val := { source := A, target := B }, property := h }
Instances For
Given two distinct points $A$ and $B$, this function returns a nondegenerate segment with source $A$ and target $B$. We use $\verb|SEG_nd|$ to abbreviate $\verb|SegND.mk|$.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Delaborator for SegND.mk
Equations
- One or more equations did not get rendered due to their size.
Instances For
Given two distinct points $A$ and $B$, this function returns the ray starting from $A$ in the direction of $B$. By definition, the direction of the ray is given by the normalization of the vector from $A$ to $B$, using $\verb|toDir|$ function. We use $\verb|RAY|$ to abbreviate $\verb|Ray.mk_pt_pt|$.
Equations
- RAY A B h = { source := A, toDir := { val := EuclidGeom.Vec.mkPtPt A B, property := (_ : B -ᵥ A ≠ 0) }.toDir }
Instances For
Given two distinct points $A$ and $B$, this function returns the ray starting from $A$ in the direction of $B$. By definition, the direction of the ray is given by the normalization of the vector from $A$ to $B$, using $\verb|toDir|$ function. We use $\verb|RAY|$ to abbreviate $\verb|Ray.mk_pt_pt|$.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Delaborator for Ray.mk_pt_pt
Equations
- One or more equations did not get rendered due to their size.
Instances For
(3) Coersion #
Given a ray, this function returns its projective direction; it is the projective direction of the direction of the ray.
Equations
- ray.toProj = ray.toDir.toProj
Instances For
Given a point $X$ and a ray $ray$, this function returns whether $X$ lies on $ray$; here saying that $X$ lies on $ray$ means that the vector from the start point of the ray to $X$ is some nonnegative multiple of the direction vector of the ray.
Equations
- EuclidGeom.Ray.IsOn X ray = ∃ (t : ℝ), 0 ≤ t ∧ EuclidGeom.Vec.mkPtPt ray.source X = t • ray.toDir.unitVec
Instances For
Given a point $X$ and a ray, this function returns whether the point lies in the interior of the ray; here saying that a point lies in the interior of a ray means that it lies on the ray and is not equal to the source of the ray.
- isOn : EuclidGeom.Ray.IsOn X ray
- ne_source : X ≠ ray.source
Instances For
Alias of EuclidGeom.Ray.IsInt.ne_source
.
Instances For
Given a ray, its carrier is the set of points that lie on the ray.
Equations
- EuclidGeom.Ray.carrier ray = {X : P | EuclidGeom.Ray.IsOn X ray}
Instances For
Given a ray, its interior is the set of points that lie in the interior of the ray.
Equations
- EuclidGeom.Ray.interior ray = {X : P | EuclidGeom.Ray.IsInt X ray}
Instances For
This is to register that a ray is an instance of a class of objects that we may speak of both carrier and interior (and that the interior is a subset of the carrier).
Equations
- EuclidGeom.Ray.instIntFigRay = EuclidGeom.IntFig.mk (_ : ∀ (x : EuclidGeom.Ray P) (x_1 : P), EuclidGeom.Ray.IsInt x_1 x → EuclidGeom.Ray.IsOn x_1 x)
Given a segment, this function returns the vector associated to the segment, that is, the vector from the source of the segment to the target of the segment.
Equations
- seg.toVec = EuclidGeom.Vec.mkPtPt seg.source seg.target
Instances For
Given a point $X$ and a segment $seg$, this function returns whether $X$ lies on $seg$; here saying that $X$ lies on $seg$ means that the vector from the source of $seg$ to $X$ is a real multiple $t$ of the vector of $seg$ with $0 \leq t \leq 1$.
Equations
- EuclidGeom.Seg.IsOn X seg = ∃ (t : ℝ), 0 ≤ t ∧ t ≤ 1 ∧ EuclidGeom.Vec.mkPtPt seg.source X = t • EuclidGeom.Vec.mkPtPt seg.source seg.target
Instances For
Given a point $X$ and a segment $seg$, this function returns whether $X$ lies in the interior of $seg$; here saying that $X$ lies in the interior of $seg$ means $X$ lies on $seg$ and is different from the source and the target of $seg$.
- isOn : EuclidGeom.Seg.IsOn X seg
- ne_source : X ≠ seg.source
- ne_target : X ≠ seg.target
Instances For
Alias of EuclidGeom.Seg.IsInt.ne_source
.
Instances For
Alias of EuclidGeom.Seg.IsInt.ne_target
.
Instances For
Given a segment, this function returns the set of points that lie on the segment.
Equations
- EuclidGeom.Seg.carrier seg = {X : P | EuclidGeom.Seg.IsOn X seg}
Instances For
Given a segment, this function returns the set of points that lie in the interior of the segment.
Equations
- EuclidGeom.Seg.interior seg = {X : P | EuclidGeom.Seg.IsInt X seg}
Instances For
Instance $\verb|IntFig Seg|$ : This is to register that a segment is an instance of a class of objects that we may speak of both carrier and interior (and that the interior is a subset of the carrier).
Equations
- EuclidGeom.Seg.instIntFigSeg = EuclidGeom.IntFig.mk (_ : ∀ (x : EuclidGeom.Seg P), ∀ x_1 ∈ EuclidGeom.Interior.interior x, EuclidGeom.Seg.IsOn x_1 x)
One may naturally coerce a nondegenerate segment into a segment.
Equations
- EuclidGeom.SegND.instCoeSegNDSeg = { coe := fun (x : EuclidGeom.SegND P) => ↑x }
Given a nondegenerate segment, this function returns the source of the segment.
Equations
- seg_nd.source = (↑seg_nd).source
Instances For
Given a nondegenerate segment, this function returns the target of the segment.
Equations
- seg_nd.target = (↑seg_nd).target
Instances For
Given a nondegenerate segment $AB$, this function returns the nondegenerate vector $\overrightarrow{AB}$.
Equations
- seg_nd.toVecND = { val := EuclidGeom.Vec.mkPtPt seg_nd.source seg_nd.target, property := (_ : EuclidGeom.Vec.mkPtPt seg_nd.source seg_nd.target ≠ 0) }
Instances For
Given a nondegenerate segment $AB$, this function returns the direction associated to the segment, defined by normalizing the nondegenerate vector $\overrightarrow{AB}$.
Equations
- seg_nd.toDir = seg_nd.toVecND.toDir
Instances For
Given a nondegenerate segment $AB$, this function returns the ray $AB$, whose source is $A$ in the direction of $B$.
Equations
- seg_nd.toRay = { source := (↑seg_nd).source, toDir := seg_nd.toDir }
Instances For
Given a nondegenerate segment $AB$, this function returns the projective direction of $AB$, defined as the projective direction of the nondegenerate vector $\overrightarrow{AB}$.
Equations
- seg_nd.toProj = seg_nd.toVecND.toProj
Instances For
Given a point $A$ and a nondegenerate segment $seg_nd$, this function returns whether $A$ lies on $seg_nd$, namely, whether it lies on the corresponding segment.
Equations
- EuclidGeom.SegND.IsOn X seg_nd = EuclidGeom.Seg.IsOn X ↑seg_nd
Instances For
Given a point $A$ and a nondegenerate segment $seg_nd$, this function returns whether $A$ lies in the interior of $seg_nd$, namely, whether it lies in the interior of the corresponding segment.
Equations
- EuclidGeom.SegND.IsInt X seg_nd = EuclidGeom.Seg.IsInt X ↑seg_nd
Instances For
Given a nondegenerate segment, this function returns the set of points that lie on the segment.
Equations
- EuclidGeom.SegND.carrier seg_nd = {X : P | EuclidGeom.SegND.IsOn X seg_nd}
Instances For
Given a nondegenerate segment, this function returns the set of points that lie in the interior of the segment.
Equations
- EuclidGeom.SegND.interior seg_nd = {X : P | EuclidGeom.Seg.IsInt X ↑seg_nd}
Instances For
This is to register that a nondegenerate segment is an instance of a class of objects that we may speak of both carrier and interior (and that the interior is a subset of the carrier).
Equations
- EuclidGeom.SegND.instIntFigSegND = EuclidGeom.IntFig.mk (_ : ∀ (x : EuclidGeom.SegND P), ∀ x_1 ∈ EuclidGeom.Interior.interior x, EuclidGeom.Seg.IsOn x_1 ↑x)
(4) Coersion compatiblity #
Given a nondegenerate segment, the direction of to the ray associated to the segment is the same as the direction of the segment.
Given a nondegenerate segment, the projective direction of the ray associated to the segment is the same as the projective direction of the segment.
Given two points $A$ and $B$, the vector associated to the segment $AB$ is same as vector $\overrightarrow{AB}$.
Given a segment $AB$, $A$ is same as $B$ if and only if vector $\overrightarrow{AB}$ is zero.
Given two distinct points $A$ and $B$, the direction of ray $AB$ is same as the negative direction of ray $BA$
Given two distinct points $A$ and $B$, the projective direction of ray $AB$ is same as that of ray $BA$.
Given two distinct points $A$ and $B$, the ray associated to the segment $AB$ is same as ray $AB$.
Given a segment $AB$, $AB$ is nondegenerate if and only if vector $\overrightarrow{AB}$ is nonzero.
If $ray_1$ and $ray_2$ are two rays with the same projective direction, then the direction vector of $ray_2$ is a real multiple of the direction vector of $ray_1$.
(5) Lieson compatibility #
Given a nondegenerate segment, a point lies on the nondegenerate segment if and only if it lies on the corresponding segment (without knowing the nondegenate condition).
Given a nondegenerate segment, a point lies in the interior of the nondegenerate segment if and only if it lies in the interior of the corresponding segment (without knowing the nondegenate condition).
Given a ray, a point $X$ lies on the ray if and only if the vector from the source of the ray to $X$ is a nonnegative multiple of the direction of ray.
Given a ray, a point $X$ lies in the interior of the ray if and only if the vector from the source of the ray to $X$ is a positive multiple of the direction of ray.
For a nondegenerate segment $AB$, a point $X$ lies on $AB$ if and only if there exist a real number $t$ satisfying that $0 \leq t \leq 1$ and that the vector $\overrightarrow{AX}$ is same as $t \cdot \overrightarrow{AB}$.
For a nondegenerate segment $AB$, a point $X$ lies in the interior of $AB$ if and only if there exist a real number $t$ satisfying that $0 < t < 1$ and that the vector $\overrightarrow{AX}$ is same as $t \cdot \overrightarrow{AB}$.
For a nondegenerate segment $AB$, if a point $X$ lies on the interior of $AB$ then $X$ not equal to $A$.
For a nondegenerate segment $AB$, if a point $X$ lies on the interior of $AB$ then $X$ not equal to $B$.
For a segment $AB$, if there exists an interior point $X$, then it is nondegenerate.
For a segment $AB$, a point $X$ lies in the interior of $AB$ if and only if $AB$ is nondegenerate, and there exist a real number $t$ satisfying that $0 < t < 1$ and that the vector $\overrightarrow{AX}$ is same as $t \cdot \overrightarrow{AB}$.
Given a segment $AB$, the source $A$ of the segment lies on the segment.
Given a segment $AB$, the target $B$ lies on the segment $AB$.
Given a segment $AB$, the source $A$ does not belong to the interior of $AB$.
Given a segment $AB$, the target $B$ does not belong to the interior of $AB$.
For a segment $AB$, every point of the interior of $AB$ lies on the segment $AB$.
Given a nondegenerate segment $AB$, the source $A$ of the segment lies on the segment.
Given a nondegenerate segment $AB$, the target $B$ lies on the segment $AB$.
Given a nondegenerate segment $AB$, the source $A$ does not belong to the interior of $AB$.
Given a nondegenerate segment $AB$, the target $B$ does not belong to the interior of $AB$.
For a nondegenerate segment $AB$, every point of the interior of $AB$ lies on the segment $AB$.
Given a ray, the source of the ray lies on the ray.
Given a ray, the source of the ray does not lie in the interior of the ray.
For a ray, every point of the interior of the ray lies on the ray.
Given a ray, a point lies in the interior of the ray if and only if it lies on the ray and is different from the source of ray.
For a nondegenerate segment $AB$, every point of the segment $AB$ lies on the ray associated to $AB$.
For a nondegenerate segment $seg_nd$, every point of the interior of the $seg_nd$ lies in the interior of the ray associated to the $seg_nd$.
Given a nondegenerate segment $seg_nd$, the target of $seg_nd$ lies on the interior of the ray associated to $seg_nd$
Given two distinct points $A$ and $B$, $B$ lies on the ray $AB$.
Given two distinct points $A$ and $B$, $B$ lies in the interior of the ray $AB$.
Given a point $A$ on a ray, the direction of the ray is the same as the direction from the source of the ray to $A$.
Given a point $A$ on the interior of a ray, the ray starting at the source of the ray in the direction of $A$ is the same as the original ray.
Given a point $A$ on the interior of a ray, the ray associated to the segment from the source of the ray to $A$ is the same as the original ray.
Given a point $A$ on the interior of a ray, the vector from the source of the ray to $A$ is equal to the distance of the source and $A$ times the direction vector of the original ray.
Given two segments $seg_1$ and $seg_2$, if the source and the target of the $seg_1$ both lie on $seg_2$, then every point of $seg_1$ lies on $seg_2$.
Given two segments $seg_1$ and $seg_2$, if the source and the target of $seg_1$ both lie in the interior of $seg_2$, and if $A$ is a point on $seg_1$, then $A$ lies in the interior of $seg_2$.
Given two segments $seg_1$ and $seg_2$, if the source and the target of $seg_1$ both lie on $seg_2$, and if $A$ is a point in the interior of $seg_1$, then $A$ lies in the interior of $seg_2$.
Given a segment and a ray, if the source and the target of the segment both lie on the ray, and if $A$ is a point on the segment, then $A$ lies on the ray.
Given a segment and a ray, if the source and the target of the segment both lie in the interior of the ray, and if $A$ is a point on the segment, then $A$ lies in the interior of the ray.
Given a segment and a ray, if the source and the target of the segment both lie on the ray, and if $A$ is a point in the interior of the segment, then $A$ lies in the interior of the ray.
Given two rays $ray_1$ and $ray_2$ with same direction, if the source of $ray_1$ lies on $ray_2$, and if $A$ is a point on $ray_1$, then $A$ lies on $ray_2$.
Given two rays $ray_1$ and $ray_2$ with same direction, if the source of $ray_1$ lies in the interior of $ray_2$, and if $A$ is a point on $ray_1$, then $A$ lies in the interior of $ray_2$.
Given a nondegenerate segment $Segnd$ and a point $A$ lies in the interior of it. Then the direction of the nondegenerate segment from the source of $Segnd$ to $A$ equals the direction of $Segnd$.
(6) Reverse #
Given a ray, this function returns the ray with the same source but with reversed direction.
Instances For
Given a segment $AB$, this function returns its reverse, i.e. the segment $BA$.
Equations
- seg.reverse = { source := seg.target, target := seg.source }
Instances For
The reverse of segment $AB$ is the segment $BA$.
If a segment is nondegenerate, so is its reverse segment.
Given a nondegenerate segment $AB$, this function returns the reversed nondegenerate segment $BA$.
Equations
- EuclidGeom.SegND.reverse seg_nd = { val := (↑seg_nd).reverse, property := (_ : EuclidGeom.Seg.IsND (↑seg_nd).reverse) }
Instances For
The reverse of a nondegenerate segment $AB$ is the nondegenerate segment $BA$.
Given a nondegenerate segment, first viewing it as a segment and then reversing it is the same as first reversing it and then viewing it as a segment.
Given a ray, the source of the reversed ray is the source of the ray.
Reversing a ray twice gives back to the original ray.
Reversing a segment twice gives back to the original segment.
Reversing a nondegenerate segment twice gives back to the original nondegenerate segment.
Given a ray, the direction of the reversed ray is the negative of the direction of the ray.
Given a ray, the direction vector of the reversed ray is the negative of the direction vector of the ray.
Given a ray, the direction vector of the reversed ray is the negative of the direction vector of the ray.
Given a ray, the projective direction of the reversed ray is the same as that of the ray.
Given a segment, the vector associated to the reversed segment is the negative of the vector associated to the segment.
Given a nondegenerate segment, the nondegenerate vector associated to the reversed nondegenerate segment is the negative of the nondegenerate vector associated to the nondegenerate segment.
Given a nondegenerate segment, the direction of the reversed nondegenerate segment is the negative direction of the nondegenerate segment.
Given a nondegenerate segment, the projective direction of the reversed nondegenerate segment is the same projective direction of the nondegenerate segment.
The source of a ray lies on the reverse of the ray.
The source of a segment lies on the reverse of the segment.
The target of a segment lies on the reverse of the segment.
The source of a nondegenerate segment lies on the reverse of the segment.
The target of a nondegenerate segment lies on the reverse of the segment.
Given a ray, a point $X$ lies on the ray or its reverse if and only if $X$ lies on the reverse ray or the reverse of reverse ray.
If a point lies on a segment, then it lies on the reversed segment.
A point lies on the reverse of a segment if and only if it lies on the segment.
A point lies in the interior of the reverse of a segment if and only if it lies in the interior of the segment.
Given a nondegenerate segment, a point lies on the reverse of the segment if and only if it lies on the segment.
Given a nondegenerate segment, a point lies in the interior of the reverse of the segment if and only if it lies in the interior of the segment.
Given a ray, a point $A$ lies on the reverse of the ray if and only if there exists a nonpositive real number $t$ such that the vector from the source of the ray to $A$ is $t$ times the direction vector of the ray.
A point $A$ lies on the lines determined by a ray $ray$ (i.e. lies on the ray or its reverse) if and only if the vector from the source of ray to $A$ is a real multiple of the direction vector of $ray$.
A point is equal to the source of a ray if and only if it lies on the ray and it lies on the reverse of the ray.
If a point lies in the interior of the reverse of a ray, then it does not lie on the ray.
If a point lies on of the reverse of a ray, then it does not lie in the interior of the ray.
A point lies on a nondegenerate segment $AB$ if and only if it lies on the ray $AB$ and on the reverse ray $BA$.
Let $ray$ be a ray, and let $A$ be a point on $ray$, and $B$ a point on the reverse of $ray$. Then $A$ lies on the ray starting at $B$ in the same direction of $\ray$.
Given two rays $ray_1$ and $ray_2$ in same direction, the source of $ray_1$ lies on $ray_2$ if and only if the source of $ray_2$ lies on the reverse of $ray_1$.
Given two rays $ray_1$ and $ray_2$ in same direction, the source of $ray_1$ lies in the interior of $ray_2$ if and only if the source of $ray_2$ lies in the interior of the reverse of $ray_1$.
Given two rays $ray_1$ and $ray_2$ in the opposite direction, the source of $ray_1$ lies on $ray_2$ if and only if the source of $ray_2$ lies on $ray_1$.
Given two rays $ray_1$ and $ray_2$ in the opposite direction, the source of $ray_1$ lies in the interior of $ray_2$ if and only if the source of $ray_2$ lies in the interior of $ray_1$.
Given two rays $ray_1$ and $ray_2$ in the opposite direction, the source of $ray_1$ lies on the reverse of $ray_2$ if and only if the source of $ray_2$ lies on the reverse of $ray_1$.
Given two rays $ray_1$ and $ray_2$ in the opposite direction, the source of $ray_1$ lies in the interior of the reverse of $ray_2$ if and only if the source of $ray_2$ lies in the interior of the reverse of $ray_1$.
Given a ray, a point $A$ lies on the ray or its reverse ray if and only if there exists a real number $t$ such that the vector from the source of the ray to $A$ is $t$ times the direction of the ray.
Given two distinct points $A$ and $B$ and a ray, if both $A$ and $B$ lies on the ray or its reversed ray, then the projective direction of the ray is the same as the projective direction of the ray $AB$.
Given a nondegenerate segment $Segnd$ and a point $A$ lies in the interior of it. Then the direction of the nondegenerate segment from $A$ to the target of $Segnd$ equals the direction of $Segnd$.
Given a nondegenerate segment $Segnd$ and a point $A$ lies in the interior of it. Then the direction of the nondegenerate vector from $A$ to the source of $Segnd$ equals the opposite direction of the nondegenerate vector from $A$ to the target of $Segnd$.
Given a nondegenerate segment $Segnd$ and a point $A$ lies in the interior of it. Then the direction of the nondegenerate vector from the source of $Segnd$ to $A$ equals the opposite direction of the nondegenerate vector from the target of $Segnd$ to $A$.
(7) Extension #
Define the extension ray of a nondegenerate segment to be the ray whose origin is the target of the segment whose direction is the same as that of the segment.
Equations
- EuclidGeom.SegND.extension seg_nd = { source := seg_nd.target, toDir := seg_nd.toDir }
Instances For
The extension of a nondegenerate segment is the same as first reverse the segment, then take the ray associated to the segment, and finally reverse the ray.
The extension of the reverse of a nondegenerate segment is the same as the reverse of the ray associated to the segment.
The direction of the extension ray of a nondegenerate segment is the same as the direction of the segment.
The projective direction of the extension ray of a nondegenerate segment is the same as the projective direction of the segment.
Given a nondegenerate segment, a point is equal to its target if and only if it lies on the segment and its extension ray.
Given a nondegenerate segment $AB$, if a point $X$ belongs to the interior of the extension ray of $AB$, then $B$ lies in the interior of $AX$.
If a point lies on the ray associated to a segment, then either it lies on the segment or it lies on the extension ray of the segment.
If a point lies on the extension ray associated to a nondegenerate segment, then it lies on the interior of the ray associated to the segment
Equations
- EuclidGeom.Ray.extpoint l t = t • l.toDir.unitVec +ᵥ l.source
Instances For
(8) Length #
This function gives the length of a given segment, which is the distance between the source and target of the segment.
Instances For
The length of segment $AB$ is the same as the distance form $A$ to $B$.
The length of a given segment is the same as the norm of the vector associated to the segment.
This function defines the length of a nondegenerate segment, which is just the length of the segment.
Equations
- EuclidGeom.SegND.length seg_nd = (↑seg_nd).length
Instances For
Every segment has nonnegative length.
A segment has positive length if and only if it is nondegenerate.
The length of a given segment is nonzero if and only if the segment is nondegenerate.
A nondegenerate segment has strictly positive length.
Given a segment, the square of its length is equal to the the inner product of the associated vector with itself.
The length of a segment is zero if and only if it is degenerate, i.e. it has same source and target.
Reversing a segment does not change its length.
Reversing a segment does not change its length.
The length of segment $AB$ is the same as the length of segment $BA$.
Given a segment and a point that lies on the segment, the additional point will separate the segment into two segments, whose lengths add up to the length of the original segment.
(9) Midpoint #
Given a segment $AB$, this function returns the midpoint of $AB$, defined as moving from $A$ by the vector $\overrightarrow{AB}/2$.
Instances For
Equations
- EuclidGeom.SegND.midpoint seg_nd = (↑seg_nd).midpoint
Instances For
Given a segment $AB$, the vector from the midpoint of $AB$ to $B$ is half of the vector from $A$ to $B$
Given a segment $AB$, the vector from $A$ to the midpoint of $AB$ is same as the vector from the midpoint of $AB$ to $B$
Given a segment $AB$ and its midpoint P, the vector from $A$ to $P$ is same as the vector from $P$ to $B$
Given a segment $AB$ and a point P, if vector $\overrightarrow{AP}$ is half of vector $\overrightarrow{AB}$, P is the midpoint of $AB$.
Given a segment $AB$ and a point P, if vector $\overrightarrow{PB}$ is half of vector $\overrightarrow{AB}$, P is the midpoint of $AB$.
Given a segment $AB$ and a point P, if vector $\overrightarrow{AP}$ is same as vector $\overrightarrow{PB}$, P is the midpoint of $AB$.
The midpoint of a segment lies on the segment.
The midpoint of a segment lies on the segment.
The midpoint of a nondegenerate segment lies in the interior of the segment.
The midpoint of a nondegenerate segment is not equal to the source of the segment.
The midpoint of a nondegenerate segment is not equal to the target of the segment.
The midpoint of a nondegenerate segment lies in the interior of the segment.
A point $X$ on a given segment $AB$ is the midpoint if and only if the vector $\overrightarrow{AX}$ is the same as the vector $\overrightarrow{XB}$.
The midpoint of a segment has same distance to the source and to the target of the segment.
The midpoint of a segment has same distance to the source and to the target of the segment.
The midpoint of a segment has same distance to the source and to the target of the segment.
A point $X$ is the midpoint of a segment $AB$ if and only if $X$ lies on $AB$ and $X$ has equal distance to $A$ and $B$.
(10) Existence theorem #
Given a segment $AB$, the midpoint of $A$ and $B + \overrightarrow{AB}$ is B.
This theorem should be replaced! B is midpt of A and B + VEC A B, midpt liesint a seg_nd
Given a nondegenerate segment $AB$, B lies in the interior of the segment of $A(B + \overrightarrow{AB})$.
Archimedean property I : given a directed segment AB (with A ≠ B), then there exists a point P such that B lies on the directed segment AP and P ≠ B.
Archimedean property II: On an nontrivial directed segment, one can always find a point in its interior. This will be moved to later disccusion about midpoint of a segment, as the midpoint is a point in the interior of a nontrivial segment
If a segment contains an interior point, then it is nondegenerate
A segment is nondegenerate if and only if it contains an interior point.
If a segment is nondegenerate, it contains an interior point.
A segment contains an interior point if and only if its length is positive.
A ray contains two distinct points.