The Mathlib Handbook

The volumes of the handbook are not written yet. This site shows the map of Mathlib that they will follow, at Mathlib 4472534b60.

The areas / V22. Affine, Euclidean and convex geometry

Mathlib.LinearAlgebra.AffineSpace.Dimension

31 declarations. Mathlib docs · Source

(Finite) Dimension of an affine subspace

This file defines the dimension of an affine subspace to be ⊥ for the empty subspace, and otherwise equal to the Module.rank of the direction of the subspace. The finite dimension is similarly defined using Module.finrank.

Main definitions

  • AffineSubspace.dim: Dimension expressed as WithBot Cardinal
  • AffineSubspace.finDim: Dimension expressed as WithBot ℕ with a junk value of 0 for infinite dimensional spaces.

def AffineSubspace.dim E3 #

{R : Type u} →
  {V : Type v} →
    {A : Type a} →
      [inst : AddCommGroup V] →
        [inst_1 : AddTorsor V A] → [inst_2 : Ring R] → [inst_3 : Module R V] → AffineSubspace R A → WithBot Cardinal.{v}

The dimension of s is equal to ⊥ if s = ⊥, and otherwise it is equal to the dimension of s interpreted as a linear space.

def AffineSubspace.finDim E3 #

{R : Type u} →
  {V : Type v} →
    {A : Type a} →
      [inst : AddCommGroup V] →
        [inst_1 : AddTorsor V A] → [inst_2 : Ring R] → [inst_3 : Module R V] → AffineSubspace R A → WithBot ℕ

The dimension of s is equal to ⊥ if s = ⊥, and otherwise it is equal to the finite dimension of s interpreted as a linear space. Note that this inherits Module.finranks junk value: AffineSubspace.finDim s = 0 for infinite dimensional subspaces.

theorem AffineSubspace.dim_bot E0 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V], ⊥.dim = ⊥

theorem AffineSubspace.finDim_bot E0 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V], ⊥.finDim = ⊥

theorem AffineSubspace.dim_singleton E0 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] [Nontrivial R] (x : A), {x}.dim = 0

theorem AffineSubspace.finDim_singleton E0 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] [Nontrivial R] (x : A), {x}.finDim = 0

theorem AffineSubspace.dim_eq_bot_iff E0 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] {s : AffineSubspace R A}, s.dim = ⊥ ↔ s = ⊥

theorem AffineSubspace.finDim_eq_bot_iff E0 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] {s : AffineSubspace R A}, s.finDim = ⊥ ↔ s = ⊥

theorem AffineSubspace.dim_ne_bot_iff E0 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] {s : AffineSubspace R A}, s.dim ≠ ⊥ ↔ (↑s).Nonempty

theorem AffineSubspace.finDim_ne_bot_iff E0 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] {s : AffineSubspace R A}, s.finDim ≠ ⊥ ↔ (↑s).Nonempty

theorem AffineSubspace.dim_eq_rank E1 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] {s : AffineSubspace R A}, s ≠ ⊥ → s.dim = ↑(Module.rank R ↥s.direction)

theorem AffineSubspace.finDim_eq_finrank E1 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] {s : AffineSubspace R A}, s ≠ ⊥ → s.finDim = ↑(Module.finrank R ↥s.direction)

theorem AffineSubspace.dim_toAffineSubspace E0 #

∀ {R : Type u} {V : Type v} [inst : AddCommGroup V] [inst_1 : Ring R] [inst_2 : Module R V] (s : Submodule R V),
  (↑s).dim = ↑(Module.rank R ↥s)

theorem AffineSubspace.finDim_toAffineSubspace E0 #

∀ {R : Type u} {V : Type v} [inst : AddCommGroup V] [inst_1 : Ring R] [inst_2 : Module R V] (s : Submodule R V),
  (↑s).finDim = ↑(Module.finrank R ↥s)

theorem AffineSubspace.finDim_eq_finrank_of_not_finite E0 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] {s : AffineSubspace R A} [Module.Free R ↥s.direction] [StrongRankCondition R],
  ¬Module.Finite R ↥s.direction → s.finDim = 0

theorem AffineSubspace.dim_lt_aleph0 E0 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] [StrongRankCondition R] (s : AffineSubspace R A) [Module.Finite R ↥s.direction],
  s.dim < ↑Cardinal.aleph0

theorem AffineSubspace.finite_iff_dim_lt_aleph0 E1 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] [StrongRankCondition R] (s : AffineSubspace R A) [Module.Free R ↥s.direction],
  Module.Finite R ↥s.direction ↔ s.dim < ↑Cardinal.aleph0

theorem AffineSubspace.finite_of_finDim_ne_zero E1 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] [StrongRankCondition R] (s : AffineSubspace R A) [Module.Free R ↥s.direction],
  s.finDim ≠ 0 → Module.Finite R ↥s.direction

theorem AffineSubspace.finDim_eq_map_dim_toNat E1 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] {s : AffineSubspace R A}, s.finDim = WithBot.map (⇑Cardinal.toNat) s.dim

theorem AffineSubspace.dim_eq_finDim_unbot E1 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] {s : AffineSubspace R A} (hs : s ≠ ⊥) [StrongRankCondition R] [Module.Finite R ↥s.direction],
  s.dim = ↑(s.finDim.unbot ⋯)

theorem AffineSubspace.dim_mono E1 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] {s t : AffineSubspace R A}, s ≤ t → s.dim ≤ t.dim

theorem AffineSubspace.finDim_mono E1 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] {s t : AffineSubspace R A} [StrongRankCondition R] [Module.Finite R ↥t.direction],
  s ≤ t → s.finDim ≤ t.finDim

theorem AffineSubspace.lift_dim_map_le E1 #

∀ {R : Type u} {V : Type v} {V' : Type v'} {A : Type a} {A' : Type a'} [inst : AddCommGroup V] [inst_1 : AddTorsor V A]
  [inst_2 : AddCommGroup V'] [inst_3 : AddTorsor V' A'] [inst_4 : Ring R] [inst_5 : Module R V] [inst_6 : Module R V']
  (f : A →ᵃ[R] A') (s : AffineSubspace R A),
  WithBot.map Cardinal.lift.{v, v'} (AffineSubspace.map f s).dim ≤ WithBot.map Cardinal.lift.{v', v} s.dim

theorem AffineSubspace.dim_map_le E1 #

∀ {R : Type u} {V : Type v} {A A₁ : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : AddTorsor V A₁]
  [inst_3 : Ring R] [inst_4 : Module R V] (f : A →ᵃ[R] A₁) (s : AffineSubspace R A),
  (AffineSubspace.map f s).dim ≤ s.dim

theorem AffineSubspace.finDim_map_le_finDim E1 #

∀ {R : Type u} {V : Type v} {V' : Type v'} {A : Type a} {A' : Type a'} [inst : AddCommGroup V] [inst_1 : AddTorsor V A]
  [inst_2 : AddCommGroup V'] [inst_3 : AddTorsor V' A'] [inst_4 : Ring R] [inst_5 : Module R V] [inst_6 : Module R V']
  [StrongRankCondition R] (f : A →ᵃ[R] A') (s : AffineSubspace R A) [Module.Finite R ↥s.direction],
  (AffineSubspace.map f s).finDim ≤ s.finDim

theorem AffineSubspace.lift_dim_map_of_injective E1 #

∀ {R : Type u} {V : Type v} {V' : Type v'} {A : Type a} {A' : Type a'} [inst : AddCommGroup V] [inst_1 : AddTorsor V A]
  [inst_2 : AddCommGroup V'] [inst_3 : AddTorsor V' A'] [inst_4 : Ring R] [inst_5 : Module R V] [inst_6 : Module R V']
  {f : A →ᵃ[R] A'},
  Function.Injective ⇑f →
    ∀ (s : AffineSubspace R A),
      WithBot.map Cardinal.lift.{v, v'} (AffineSubspace.map f s).dim = WithBot.map Cardinal.lift.{v', v} s.dim

theorem AffineSubspace.dim_map_of_injective E1 #

∀ {R : Type u} {V : Type v} {A A₁ : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : AddTorsor V A₁]
  [inst_3 : Ring R] [inst_4 : Module R V] {f : A →ᵃ[R] A₁},
  Function.Injective ⇑f → ∀ (s : AffineSubspace R A), (AffineSubspace.map f s).dim = s.dim

theorem AffineSubspace.finDim_map_of_injective E1 #

∀ {R : Type u} {V : Type v} {V' : Type v'} {A : Type a} {A' : Type a'} [inst : AddCommGroup V] [inst_1 : AddTorsor V A]
  [inst_2 : AddCommGroup V'] [inst_3 : AddTorsor V' A'] [inst_4 : Ring R] [inst_5 : Module R V] [inst_6 : Module R V']
  {f : A →ᵃ[R] A'}, Function.Injective ⇑f → ∀ (s : AffineSubspace R A), (AffineSubspace.map f s).finDim = s.finDim

theorem AffineSubspace.dim_le_zero_iff_subsingleton E0 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] {s : AffineSubspace R A} [IsDomain R] [Module.IsTorsionFree R ↥s.direction],
  s.dim ≤ 0 ↔ (↑s).Subsingleton

theorem AffineSubspace.finDim_le_zero_iff_subsingleton E0 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : Ring R]
  [inst_3 : Module R V] {s : AffineSubspace R A} [StrongRankCondition R] [IsDomain R]
  [Module.IsTorsionFree R ↥s.direction] [Module.Finite R ↥s.direction], s.finDim ≤ 0 ↔ (↑s).Subsingleton

theorem AffineSubspace.finDim_strictMono E1 #

∀ {R : Type u} {V : Type v} {A : Type a} [inst : AddCommGroup V] [inst_1 : AddTorsor V A] [inst_2 : DivisionRing R]
  [inst_3 : Module R V] {s t : AffineSubspace R A} [Module.Finite R ↥t.direction], s < t → s.finDim < t.finDim