Affine independence #
This file defines affinely independent families of points.
Main definitions #
AffineIndependent
defines affinely independent families of points as those where no nontrivial weighted subtraction is0
. This is proved equivalent to two other formulations: linear independence of the results of subtracting a base point in the family from the other points in the family, or any equal affine combinations having the same weights. A bundled typeSimplex
is provided for finite affinely independent families of points, with an abbreviationTriangle
for the case of three points.
References #
- https://en.wikipedia.org/wiki/Affine_space
An indexed family is said to be affinely independent if no nontrivial weighted subtractions (where the sum of weights is 0) are 0.
Equations
- AffineIndependent k p = ∀ (s : Finset ι) (w : ι → k), (Finset.sum s fun (i : ι) => w i) = 0 → (Finset.weightedVSub s p) w = 0 → ∀ i ∈ s, w i = 0
Instances For
The definition of AffineIndependent
.
A family with at most one point is affinely independent.
A family indexed by a Fintype
is affinely independent if and
only if no nontrivial weighted subtractions over Finset.univ
(where
the sum of the weights is 0) are 0.
A family is affinely independent if and only if the differences from a base point in that family are linearly independent.
A set is affinely independent if and only if the differences from a base point in that set are linearly independent.
A set of nonzero vectors is linearly independent if and only if,
given a point p₁
, the vectors added to p₁
and p₁
itself are
affinely independent.
A family is affinely independent if and only if any affine
combinations (with sum of weights 1) that evaluate to the same point
have equal Set.indicator
.
A finite family is affinely independent if and only if any affine combinations (with sum of weights 1) that evaluate to the same point are equal.
If we single out one member of an affine-independent family of points and affinely transport all others along the line joining them to this member, the resulting new family of points is affine- independent.
This is the affine version of LinearIndependent.units_smul
.
An affinely independent family is injective, if the underlying ring is nontrivial.
If a family is affinely independent, so is any subfamily given by composition of an embedding into index type with the original family.
If a family is affinely independent, so is any subfamily indexed by a subtype of the index type.
If an indexed family of points is affinely independent, so is the corresponding set of points.
If a set of points is affinely independent, so is any subset.
If the range of an injective indexed family of points is affinely independent, so is that family.
If the image of a family of points in affine space under an affine transformation is affine- independent, then the original family of points is also affine-independent.
The image of a family of points in affine space, under an injective affine transformation, is affine-independent.
Injective affine maps preserve affine independence.
Affine equivalences preserve affine independence of families of points.
Affine equivalences preserve affine independence of subsets.
If a family is affinely independent, and the spans of points indexed by two subsets of the index type have a point in common, those subsets of the index type have an element in common, if the underlying ring is nontrivial.
If a family is affinely independent, the spans of points indexed by disjoint subsets of the index type are disjoint, if the underlying ring is nontrivial.
If a family is affinely independent, a point in the family is in the span of some of the points given by a subset of the index type if and only if that point's index is in the subset, if the underlying ring is nontrivial.
If a family is affinely independent, a point in the family is not in the affine span of the other points, if the underlying ring is nontrivial.
Viewing a module as an affine space modelled on itself, we can characterise affine independence in terms of linear combinations.
Given an affinely independent family of points, a weighted subtraction lies in the
vectorSpan
of two points given as affine combinations if and only if it is a weighted
subtraction with weights a multiple of the difference between the weights of the two points.
Given an affinely independent family of points, an affine combination lies in the span of two points given as affine combinations if and only if it is an affine combination with weights those of one point plus a multiple of the difference between the weights of the two points.
An affinely independent set of points can be extended to such a set that spans the whole space.
Two different points are affinely independent.
If all but one point of a family are affinely independent, and that point does not lie in the affine span of that family, the family is affinely independent.
If distinct points p₁
and p₂
lie in s
but p₃
does not, the three points are affinely
independent.
If distinct points p₁
and p₃
lie in s
but p₂
does not, the three points are affinely
independent.
If distinct points p₂
and p₃
lie in s
but p₁
does not, the three points are affinely
independent.
Given an affinely independent family of points, suppose that an affine combination lies in the span of two points given as affine combinations, and suppose that, for two indices, the coefficients in the first point in the span are zero and those in the second point in the span have the same sign. Then the coefficients in the combination lying in the span have the same sign.
Given an affinely independent family of points, suppose that an affine combination lies in
the span of one point of that family and a combination of another two points of that family given
by lineMap
with coefficient between 0 and 1. Then the coefficients of those two points in the
combination lying in the span have the same sign.
A Simplex k P n
is a collection of n + 1
affinely
independent points.
- independent : AffineIndependent k self.points
Instances For
A Triangle k P
is a collection of three affinely independent points.
Equations
- Affine.Triangle k P = Affine.Simplex k P 2
Instances For
Construct a 0-simplex from a point.
Equations
- Affine.Simplex.mkOfPoint k p = let_fun this := Affine.Simplex.mkOfPoint.proof_1; { points := fun (x : Fin (0 + 1)) => p, independent := ⋯ }
Instances For
The point in a simplex constructed with mkOfPoint
.
Equations
- Affine.Simplex.instInhabitedSimplexOfNatNatInstOfNatNat k = { default := Affine.Simplex.mkOfPoint k default }
Equations
- ⋯ = ⋯
Two simplices are equal if they have the same points.
Two simplices are equal if and only if they have the same points.
A face of a simplex is a simplex with the given subset of points.
Equations
- Affine.Simplex.face s h = { points := s.points ∘ ⇑(Finset.orderEmbOfFin fs h), independent := ⋯ }
Instances For
The points of a face of a simplex are given by mono_of_fin
.
The points of a face of a simplex are given by mono_of_fin
.
A single-point face equals the 0-simplex constructed with
mkOfPoint
.
The set of points of a face.
Remap a simplex along an Equiv
of index types.
Equations
- Affine.Simplex.reindex s e = { points := s.points ∘ ⇑e.symm, independent := ⋯ }
Instances For
Reindexing by Equiv.refl
yields the original simplex.
Reindexing by the composition of two equivalences is the same as reindexing twice.
Reindexing by an equivalence and its inverse yields the original simplex.
Reindexing by the inverse of an equivalence and that equivalence yields the original simplex.
Reindexing a simplex produces one with the same set of points.
The centroid of a face of a simplex as the centroid of a subset of the points.
Over a characteristic-zero division ring, the centroids given by two subsets of the points of a simplex are equal if and only if those faces are given by the same subset of points.
Over a characteristic-zero division ring, the centroids of two faces of a simplex are equal if and only if those faces are given by the same subset of points.
Two simplices with the same points have the same centroid.