The areas / V07. Linear algebra
Mathlib.LinearAlgebra.FreeModule.PID
55 declarations. Mathlib docs · Source
Free modules over PID
A free R-module M is a module with a basis over R,
equivalently it is an R-module linearly equivalent to ι →₀ R for some ι.
This file proves a submodule of a free R-module of finite rank is also
a free R-module of finite rank, if R is a principal ideal domain (PID),
i.e. we have instances [IsDomain R] [IsPrincipalIdealRing R].
We express "free R-module of finite rank" as a module M which has a basis
b : ι → R, where ι is a Fintype.
We call the cardinality of ι the rank of M in this file;
it would be equal to finrank R M if R is a field and M is a vector space.
Main results
In this section, M is a free and finitely generated R-module, and
N is a submodule of M.
-
Submodule.inductionOnRank: ifPholds for⊥ : Submodule R Mand ifP Nfollows fromP N'for allN'that are of lower rank, thenPholds on all submodules -
Submodule.exists_basis_of_pid: ifRis a PID, thenN : Submodule R Mis free and finitely generated. This is the first part of the structure theorem for modules. -
Submodule.smithNormalForm: ifRis a PID, thenMhas a basisbMandNhas a basisbNsuch thatbN i = a i • bM i. Equivalently, a linear mapf : M →ₗ Mwithrange f = Ncan be written as a matrix in Smith normal form, a diagonal matrix with the coefficientsa ialong the diagonal.
Tags
free module, finitely generated module, rank, structure theorem
theorem Submodule.smithNormalFormCoeffs.congr_simp E1 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
[inst_3 : IsDomain R] [inst_4 : IsPrincipalIdealRing R] {N N_1 : Submodule R M} (e_N : N = N_1) [inst_5 : Finite ι]
(b b_1 : Module.Basis ι R M),
b = b_1 →
∀ (h : Module.finrank R ↥N = Module.finrank R M) (a a_1 : ι),
a = a_1 → Submodule.smithNormalFormCoeffs b h a = Submodule.smithNormalFormCoeffs b_1 ⋯ a_1
theorem Module.Basis.SmithNormalForm.mk.inj E1 #
∀ {R : Type u_2} {inst : CommRing R} {M : Type u_3} {inst_1 : AddCommGroup M} {inst_2 : Module R M} {N : Submodule R M}
{ι : Type u_4} {n : ℕ} {bM : Module.Basis ι R M} {bN : Module.Basis (Fin n) R ↥N} {f : Fin n ↪ ι} {a : Fin n → R}
{snf : ∀ (i : Fin n), ↑(bN i) = a i • bM (f i)} {bM_1 : Module.Basis ι R M} {bN_1 : Module.Basis (Fin n) R ↥N}
{f_1 : Fin n ↪ ι} {a_1 : Fin n → R} {snf_1 : ∀ (i : Fin n), ↑(bN_1 i) = a_1 i • bM_1 (f_1 i)},
{ bM := bM, bN := bN, f := f, a := a, snf := snf } = { bM := bM_1, bN := bN_1, f := f_1, a := a_1, snf := snf_1 } →
bM = bM_1 ∧ bN = bN_1 ∧ f = f_1 ∧ a = a_1
theorem Ideal.selfBasis.congr_simp E1 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] [inst_1 : IsDomain R] [inst_2 : IsPrincipalIdealRing R]
{S : Type u_4} [inst_3 : CommRing S] [inst_4 : IsDomain S] [inst_5 : Algebra R S] [inst_6 : Finite ι]
(b b_1 : Module.Basis ι R S),
b = b_1 → ∀ (I : Ideal S) (hI : I ≠ ⊥), Ideal.selfBasis b I hI = Ideal.selfBasis b_1 I hI
theorem Module.Basis.SmithNormalForm.mk.injEq E0 #
∀ {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M] {N : Submodule R M}
{ι : Type u_4} {n : ℕ} (bM : Module.Basis ι R M) (bN : Module.Basis (Fin n) R ↥N) (f : Fin n ↪ ι) (a : Fin n → R)
(snf : ∀ (i : Fin n), ↑(bN i) = a i • bM (f i)) (bM_1 : Module.Basis ι R M) (bN_1 : Module.Basis (Fin n) R ↥N)
(f_1 : Fin n ↪ ι) (a_1 : Fin n → R) (snf_1 : ∀ (i : Fin n), ↑(bN_1 i) = a_1 i • bM_1 (f_1 i)),
({ bM := bM, bN := bN, f := f, a := a, snf := snf } = { bM := bM_1, bN := bN_1, f := f_1, a := a_1, snf := snf_1 }) =
(bM = bM_1 ∧ bN = bN_1 ∧ f = f_1 ∧ a = a_1)
def Module.Basis.SmithNormalForm.ctorIdx E1 #
{R : Type u_2} →
{inst : CommRing R} →
{M : Type u_3} →
{inst_1 : AddCommGroup M} →
{inst_2 : Module R M} → {N : Submodule R M} → {ι : Type u_4} → {n : ℕ} → Module.Basis.SmithNormalForm N ι n → ℕ
theorem Submodule.smithNormalFormTopBasis.congr_simp E1 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
[inst_3 : IsDomain R] [inst_4 : IsPrincipalIdealRing R] {N N_1 : Submodule R M} (e_N : N = N_1) [inst_5 : Finite ι]
(b b_1 : Module.Basis ι R M),
b = b_1 →
∀ (h : Module.finrank R ↥N = Module.finrank R M),
Submodule.smithNormalFormTopBasis b h = Submodule.smithNormalFormTopBasis b_1 ⋯
theorem Submodule.smithNormalFormBotBasis.congr_simp E1 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
[inst_3 : IsDomain R] [inst_4 : IsPrincipalIdealRing R] {N : Submodule R M} [inst_5 : Finite ι]
(b b_1 : Module.Basis ι R M),
b = b_1 →
∀ (h : Module.finrank R ↥N = Module.finrank R M),
Submodule.smithNormalFormBotBasis b h = Submodule.smithNormalFormBotBasis b_1 h
theorem Ideal.ringBasis.congr_simp E1 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] [inst_1 : IsDomain R] [inst_2 : IsPrincipalIdealRing R]
{S : Type u_4} [inst_3 : CommRing S] [inst_4 : IsDomain S] [inst_5 : Algebra R S] [inst_6 : Finite ι]
(b b_1 : Module.Basis ι R S),
b = b_1 → ∀ (I I_1 : Ideal S) (e_I : I = I_1) (hI : I ≠ ⊥), Ideal.ringBasis b I hI = Ideal.ringBasis b_1 I_1 ⋯
theorem Submodule.comapSubtypeEquivOfLe.congr_simp E1 #
∀ {R : Type u_1} {M : Type u_4} [inst : Semiring R] [inst_1 : AddCommMonoid M] [inst_2 : Module R M]
{p q : Submodule R M} (hpq : p ≤ q), Submodule.comapSubtypeEquivOfLe hpq = Submodule.comapSubtypeEquivOfLe hpq
theorem Ideal.smithCoeffs.congr_simp E1 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] [inst_1 : IsDomain R] [inst_2 : IsPrincipalIdealRing R]
{S : Type u_4} [inst_3 : CommRing S] [inst_4 : IsDomain S] [inst_5 : Algebra R S] [inst_6 : Finite ι]
(b b_1 : Module.Basis ι R S),
b = b_1 →
∀ (I I_1 : Ideal S) (e_I : I = I_1) (hI : I ≠ ⊥) (a a_1 : ι),
a = a_1 → Ideal.smithCoeffs b I hI a = Ideal.smithCoeffs b_1 I_1 ⋯ a_1
theorem dvd_generator_iff E0 #
∀ {R : Type u_1} [inst : CommSemiring R] {I : Ideal R} [inst_1 : Submodule.IsPrincipal I] {x : R},
x ∈ I → (x ∣ Submodule.IsPrincipal.generator I ↔ I = Ideal.span {x})
theorem generator_maximal_submoduleImage_dvd E1 #
∀ {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
[inst_3 : IsPrincipalIdealRing R] {N O : Submodule R M} (hNO : N ≤ O) {ϕ : ↥O →ₗ[R] R},
(∀ (ψ : ↥O →ₗ[R] R), ¬ϕ.submoduleImage N < ψ.submoduleImage N) →
∀ (y : M) (yN : y ∈ N),
ϕ ⟨y, ⋯⟩ = Submodule.IsPrincipal.generator (ϕ.submoduleImage N) →
∀ (ψ : ↥O →ₗ[R] R), Submodule.IsPrincipal.generator (ϕ.submoduleImage N) ∣ ψ ⟨y, ⋯⟩
theorem Submodule.basis_of_pid_aux E0 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] [IsPrincipalIdealRing R] [IsDomain R] [Finite ι] {O : Type u_4}
[inst_4 : AddCommGroup O] [inst_5 : Module R O] (M N : Submodule R O) (b'M : Module.Basis ι R ↥M),
N ≠ ⊥ →
N ≤ M →
∃ y ∈ M,
∃ a,
a • y ∈ N ∧
∃ M' ≤ M,
∃ N' ≤ N,
N' ≤ M' ∧
(∀ (c : R), ∀ z ∈ M', c • y + z = 0 → c = 0) ∧
(∀ (c : R), ∀ z ∈ N', c • a • y + z = 0 → c = 0) ∧
∀ (n' : ℕ) (bN' : Module.Basis (Fin n') R ↥N'),
∃ bN,
∀ (m' : ℕ) (hn'm' : n' ≤ m') (bM' : Module.Basis (Fin m') R ↥M'),
∃ (hnm : n' + 1 ≤ m' + 1),
∃ bM,
∀ (as : Fin n' → R),
(∀ (i : Fin n'), ↑(bN' i) = as i • ↑(bM' (Fin.castLE hn'm' i))) →
∃ as', ∀ (i : Fin (n' + 1)), ↑(bN i) = as' i • ↑(bM (Fin.castLE hnm i))
The induction hypothesis of Submodule.basisOfPid and Submodule.smithNormalForm.
Basically, it says: let N ≤ M be a pair of submodules, then we can find a pair of
submodules N' ≤ M' of strictly smaller rank, whose basis we can extend to get a basis
of N and M. Moreover, if the basis for M' is up to scalars a basis for N',
then the basis we find for M is up to scalars a basis for N.
For basis_of_pid we only need the first half and can fix M = ⊤,
for smith_normal_form we need the full statement,
but must also feed in a basis for M using basis_of_pid to keep the induction going.
theorem Submodule.nonempty_basis_of_pid E1 #
∀ {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
[IsPrincipalIdealRing R] [IsDomain R] {ι : Type u_4} [Finite ι] (b : Module.Basis ι R M) (N : Submodule R M),
∃ n, Nonempty (Module.Basis (Fin n) R ↥N)
A submodule of a free R-module of finite rank is also a free R-module of finite rank,
if R is a principal ideal domain.
This is a lemma to make the induction a bit easier. To actually access the basis,
see Submodule.basisOfPid.
See also the stronger version Submodule.smithNormalForm.
def Submodule.basisOfPid E1 #
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] →
[inst_2 : Module R M] →
[IsPrincipalIdealRing R] →
[IsDomain R] →
{ι : Type u_4} →
[Finite ι] → Module.Basis ι R M → (N : Submodule R M) → (n : ℕ) × Module.Basis (Fin n) R ↥N
A submodule of a free R-module of finite rank is also a free R-module of finite rank,
if R is a principal ideal domain.
See also the stronger version Submodule.smithNormalForm.
theorem Submodule.basisOfPid_bot E1 #
∀ {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
[inst_3 : IsPrincipalIdealRing R] [inst_4 : IsDomain R] {ι : Type u_4} [inst_5 : Finite ι] (b : Module.Basis ι R M),
Submodule.basisOfPid b ⊥ = ⟨0, Module.Basis.empty ↥⊥⟩
def Submodule.basisOfPidOfLE E1 #
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] →
[inst_2 : Module R M] →
[IsPrincipalIdealRing R] →
[IsDomain R] →
{ι : Type u_4} →
[Finite ι] → {N O : Submodule R M} → N ≤ O → Module.Basis ι R ↥O → (n : ℕ) × Module.Basis (Fin n) R ↥N
A submodule inside a free R-submodule of finite rank is also a free R-module of finite rank,
if R is a principal ideal domain.
See also the stronger version Submodule.smithNormalFormOfLE.
def Submodule.basisOfPidOfLESpan E1 #
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] →
[inst_2 : Module R M] →
[IsPrincipalIdealRing R] →
[IsDomain R] →
{ι : Type u_4} →
[Finite ι] →
{b : ι → M} →
LinearIndependent R b →
{N : Submodule R M} → N ≤ Submodule.span R (Set.range b) → (n : ℕ) × Module.Basis (Fin n) R ↥N
A submodule inside the span of a linear independent family is a free R-module of finite rank,
if R is a principal ideal domain.
def Module.basisOfFiniteTypeTorsionFree E1 #
{ι : Type u_1} →
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] →
[inst_2 : Module R M] →
[IsPrincipalIdealRing R] →
[IsDomain R] →
[Fintype ι] →
{s : ι → M} →
Submodule.span R (Set.range s) = ⊤ → [Module.IsTorsionFree R M] → (n : ℕ) × Module.Basis (Fin n) R M
A finite type torsion free module over a PID admits a basis.
theorem Module.free_of_finite_type_torsion_free E1 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
[IsPrincipalIdealRing R] [IsDomain R] [Finite ι] {s : ι → M},
Submodule.span R (Set.range s) = ⊤ → ∀ [Module.IsTorsionFree R M], Module.Free R M
def Module.basisOfFiniteTypeTorsionFree' E1 #
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] →
[inst_2 : Module R M] →
[IsPrincipalIdealRing R] →
[IsDomain R] → [Module.Finite R M] → [Module.IsTorsionFree R M] → (n : ℕ) × Module.Basis (Fin n) R M
A finite type torsion free module over a PID admits a basis.
instance Module.free_of_finite_type_torsion_free' E0 #
∀ {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
[IsPrincipalIdealRing R] [IsDomain R] [Module.Finite R M] [Module.IsTorsionFree R M], Module.Free R M
instance instFreeSubtypeMemIdealOfFiniteOfIsTorsionFree E0 #
∀ {R : Type u_2} [inst : CommRing R] [IsPrincipalIdealRing R] [IsDomain R] {S : Type u_4} [inst_3 : CommRing S]
[inst_4 : Algebra R S] {I : Ideal S} [hI₁ : Module.Finite R ↥I] [hI₂ : Module.IsTorsionFree R ↥I], Module.Free R ↥I
theorem Module.free_iff_isTorsionFree E1 #
∀ {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
[IsPrincipalIdealRing R] [IsDomain R] [Module.Finite R M], Module.Free R M ↔ Module.IsTorsionFree R M
structure Module.Basis.SmithNormalForm E1 #
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] → [inst_2 : Module R M] → Submodule R M → Type u_4 → ℕ → Type (max (max u_2 u_3) u_4)
A Smith normal form basis for a submodule N of a module M consists of
bases for M and N such that the inclusion map N → M can be written as a
(rectangular) matrix with a along the diagonal: in Smith normal form.
ctor Module.Basis.SmithNormalForm.mk E0 #
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] →
[inst_2 : Module R M] →
{N : Submodule R M} →
{ι : Type u_4} →
{n : ℕ} →
(bM : Module.Basis ι R M) →
(bN : Module.Basis (Fin n) R ↥N) →
(f : Fin n ↪ ι) →
(a : Fin n → R) → (∀ (i : Fin n), ↑(bN i) = a i • bM (f i)) → Module.Basis.SmithNormalForm N ι n
abbrev Module.Basis.SmithNormalForm.bM E3 #
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] →
[inst_2 : Module R M] →
{N : Submodule R M} → {ι : Type u_4} → {n : ℕ} → Module.Basis.SmithNormalForm N ι n → Module.Basis ι R M
The basis of M.
abbrev Module.Basis.SmithNormalForm.bN E1 #
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] →
[inst_2 : Module R M] →
{N : Submodule R M} →
{ι : Type u_4} → {n : ℕ} → Module.Basis.SmithNormalForm N ι n → Module.Basis (Fin n) R ↥N
The basis of N.
abbrev Module.Basis.SmithNormalForm.f E1 #
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] →
[inst_2 : Module R M] →
{N : Submodule R M} → {ι : Type u_4} → {n : ℕ} → Module.Basis.SmithNormalForm N ι n → Fin n ↪ ι
The mapping between the vectors of the bases.
abbrev Module.Basis.SmithNormalForm.a E1 #
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] →
[inst_2 : Module R M] →
{N : Submodule R M} → {ι : Type u_4} → {n : ℕ} → Module.Basis.SmithNormalForm N ι n → Fin n → R
The (diagonal) entries of the matrix.
theorem Module.Basis.SmithNormalForm.snf E1 #
∀ {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M] {N : Submodule R M}
{ι : Type u_4} {n : ℕ} (self : Module.Basis.SmithNormalForm N ι n) (i : Fin n),
↑(self.bN i) = self.a i • self.bM (self.f i)
The SNF relation between the vectors of the bases.
theorem Module.Basis.SmithNormalForm.repr_eq_zero_of_notMem_range E1 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
{n : ℕ} {N : Submodule R M} (snf : Module.Basis.SmithNormalForm N ι n) (m : ↥N) {i : ι},
i ∉ Set.range ⇑snf.f → (snf.bM.repr ↑m) i = 0
theorem Module.Basis.SmithNormalForm.le_ker_coord_of_notMem_range E1 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
{n : ℕ} {N : Submodule R M} (snf : Module.Basis.SmithNormalForm N ι n) {i : ι},
i ∉ Set.range ⇑snf.f → N ≤ (snf.bM.coord i).ker
theorem Module.Basis.SmithNormalForm.repr_apply_embedding_eq_repr_smul E0 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
{n : ℕ} {N : Submodule R M} (snf : Module.Basis.SmithNormalForm N ι n) (m : ↥N) {i : Fin n},
(snf.bM.repr ↑m) (snf.f i) = (snf.bN.repr (snf.a i • m)) i
theorem Module.Basis.SmithNormalForm.repr_comp_embedding_eq_smul E0 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
{n : ℕ} {N : Submodule R M} (snf : Module.Basis.SmithNormalForm N ι n) (m : ↥N),
⇑(snf.bM.repr ↑m) ∘ ⇑snf.f = snf.a • ⇑(snf.bN.repr m)
theorem Module.Basis.SmithNormalForm.coord_apply_embedding_eq_smul_coord E0 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
{n : ℕ} {N : Submodule R M} (snf : Module.Basis.SmithNormalForm N ι n) {i : Fin n},
snf.bM.coord (snf.f i) ∘ₗ N.subtype = snf.a i • snf.bN.coord i
theorem Module.Basis.SmithNormalForm.toMatrix_restrict_eq_toMatrix E0 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
{n : ℕ} {N : Submodule R M} (snf : Module.Basis.SmithNormalForm N ι n) [inst_3 : Fintype ι] [inst_4 : DecidableEq ι]
(f : M →ₗ[R] M) (hf : ∀ (x : M), f x ∈ N) (hf' : optParam (∀ x ∈ N, f x ∈ N) ⋯) {i : Fin n},
(LinearMap.toMatrix snf.bN snf.bN) (f.restrict hf') i i = (LinearMap.toMatrix snf.bM snf.bM) f (snf.f i) (snf.f i)
Given a Smith-normal-form pair of bases for N ⊆ M, and a linear endomorphism f of M
that preserves N, the diagonal of the matrix of the restriction f to N does not depend on
which of the two bases for N is used.
theorem Submodule.exists_smith_normal_form_of_le E1 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
[IsDomain R] [IsPrincipalIdealRing R] [Finite ι] (b : Module.Basis ι R M) (N O : Submodule R M),
N ≤ O → ∃ n o, ∃ (hno : n ≤ o), ∃ bO bN a, ∀ (i : Fin n), ↑(bN i) = a i • ↑(bO (Fin.castLE hno i))
If M is finite free over a PID R, then any submodule N is free
and we can find a basis for M and N such that the inclusion map is a diagonal matrix
in Smith normal form.
See Submodule.smithNormalFormOfLE for a version of this theorem that returns
a Basis.SmithNormalForm.
This is a strengthening of Submodule.basisOfPidOfLE.
def Submodule.smithNormalFormOfLE E1 #
{ι : Type u_1} →
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] →
[inst_2 : Module R M] →
[IsDomain R] →
[IsPrincipalIdealRing R] →
[Finite ι] →
Module.Basis ι R M →
(N O : Submodule R M) →
N ≤ O → (o : ℕ) × (n : ℕ) × Module.Basis.SmithNormalForm (Submodule.comap O.subtype N) (Fin o) n
If M is finite free over a PID R, then any submodule N is free
and we can find a basis for M and N such that the inclusion map is a diagonal matrix
in Smith normal form.
See Submodule.exists_smith_normal_form_of_le for a version of this theorem that doesn't
need to map N into a submodule of O.
This is a strengthening of Submodule.basisOfPidOfLe.
def Submodule.smithNormalForm E3 #
{ι : Type u_1} →
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] →
[inst_2 : Module R M] →
[IsDomain R] →
[IsPrincipalIdealRing R] →
[Finite ι] → Module.Basis ι R M → (N : Submodule R M) → (n : ℕ) × Module.Basis.SmithNormalForm N ι n
If M is finite free over a PID R, then any submodule N is free
and we can find a basis for M and N such that the inclusion map is a diagonal matrix
in Smith normal form.
This is a strengthening of Submodule.basisOfPid.
See also Ideal.smithNormalForm, which moreover proves that the dimension of
an ideal is the same as the dimension of the whole ring.
def Submodule.smithNormalFormOfRankEq E1 #
{ι : Type u_1} →
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] →
[inst_2 : Module R M] →
[IsDomain R] →
[IsPrincipalIdealRing R] →
{N : Submodule R M} →
[inst_5 : Fintype ι] →
Module.Basis ι R M →
Module.finrank R ↥N = Module.finrank R M → Module.Basis.SmithNormalForm N ι (Fintype.card ι)
If M is finite free over a PID R, then for any submodule N of the same rank,
we can find basis for M and N with the same indexing such that the inclusion map
is a square diagonal matrix.
See Submodule.exists_smith_normal_form_of_rank_eq for a version that states the
existence of the basis.
theorem Submodule.exists_smith_normal_form_of_rank_eq E0 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
[IsDomain R] [IsPrincipalIdealRing R] {N : Submodule R M} [Finite ι] (b : Module.Basis ι R M),
Module.finrank R ↥N = Module.finrank R M → ∃ b' a ab', ∀ (i : ι), ↑(ab' i) = a i • b' i
If M is finite free over a PID R, then for any submodule N of the same rank,
we can find basis for M and N with the same indexing such that the inclusion map
is a square diagonal matrix.
See also Submodule.smithNormalFormOfRankEq for a version of this theorem that returns
a Basis.SmithNormalForm.
def Submodule.smithNormalFormTopBasis E1 #
{ι : Type u_1} →
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] →
[inst_2 : Module R M] →
[IsDomain R] →
[IsPrincipalIdealRing R] →
{N : Submodule R M} →
[Finite ι] → Module.Basis ι R M → Module.finrank R ↥N = Module.finrank R M → Module.Basis ι R M
If M is finite free over a PID R, then for any submodule N of the same rank,
we can find basis for M and N with the same indexing such that the inclusion map
is a square diagonal matrix; this is the basis for M. See:
Submodule.smithNormalFormBotBasisfor the basis onN,Submodule.smithNormalFormCoeffsfor the entries of the diagonal matrixSubmodule.smithNormalFormBotBasis_deffor the proof that the inclusion map forms a square diagonal matrix.
def Submodule.smithNormalFormBotBasis E1 #
{ι : Type u_1} →
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] →
[inst_2 : Module R M] →
[IsDomain R] →
[IsPrincipalIdealRing R] →
{N : Submodule R M} →
[Finite ι] → Module.Basis ι R M → Module.finrank R ↥N = Module.finrank R M → Module.Basis ι R ↥N
If M is finite free over a PID R, then for any submodule N of the same rank,
we can find basis for M and N with the same indexing such that the inclusion map
is a square diagonal matrix; this is the basis for N. See:
Submodule.smithNormalFormTopBasisfor the basis onM,Submodule.smithNormalFormCoeffsfor the entries of the diagonal matrixSubmodule.smithNormalFormBotBasis_deffor the proof that the inclusion map forms a square diagonal matrix.
def Submodule.smithNormalFormCoeffs E1 #
{ι : Type u_1} →
{R : Type u_2} →
[inst : CommRing R] →
{M : Type u_3} →
[inst_1 : AddCommGroup M] →
[inst_2 : Module R M] →
[IsDomain R] →
[IsPrincipalIdealRing R] →
{N : Submodule R M} → [Finite ι] → Module.Basis ι R M → Module.finrank R ↥N = Module.finrank R M → ι → R
If M is finite free over a PID R, then for any submodule N of the same rank,
we can find basis for M and N with the same indexing such that the inclusion map
is a square diagonal matrix; these are the entries of the diagonal matrix. See:
Submodule.smithNormalFormTopBasisfor the basis onM,Submodule.smithNormalFormBotBasisfor the basis onN,Submodule.smithNormalFormBotBasis_deffor the proof that the inclusion map forms a square diagonal matrix.
theorem Submodule.smithNormalFormBotBasis_def E0 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
[inst_3 : IsDomain R] [inst_4 : IsPrincipalIdealRing R] {N : Submodule R M} [inst_5 : Finite ι]
(b : Module.Basis ι R M) (h : Module.finrank R ↥N = Module.finrank R M) (i : ι),
↑((Submodule.smithNormalFormBotBasis b h) i) =
Submodule.smithNormalFormCoeffs b h i • (Submodule.smithNormalFormTopBasis b h) i
theorem Submodule.smithNormalFormCoeffs_ne_zero E0 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] {M : Type u_3} [inst_1 : AddCommGroup M] [inst_2 : Module R M]
[inst_3 : IsDomain R] [inst_4 : IsPrincipalIdealRing R] {N : Submodule R M} [inst_5 : Finite ι]
(b : Module.Basis ι R M) (h : Module.finrank R ↥N = Module.finrank R M) (i : ι),
Submodule.smithNormalFormCoeffs b h i ≠ 0
theorem Ideal.finrank_eq_finrank E1 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] [IsDomain R] [IsPrincipalIdealRing R] {S : Type u_4}
[inst_3 : CommRing S] [IsDomain S] [inst_5 : Algebra R S] [Finite ι] (b : Module.Basis ι R S) (I : Ideal S),
I ≠ ⊥ → Module.finrank R ↥(Submodule.restrictScalars R I) = Module.finrank R S
def Ideal.smithNormalForm E1 #
{ι : Type u_1} →
{R : Type u_2} →
[inst : CommRing R] →
[IsDomain R] →
[IsPrincipalIdealRing R] →
{S : Type u_4} →
[inst_3 : CommRing S] →
[IsDomain S] →
[inst_5 : Algebra R S] →
[inst_6 : Fintype ι] →
Module.Basis ι R S →
(I : Ideal S) →
I ≠ ⊥ → Module.Basis.SmithNormalForm (Submodule.restrictScalars R I) ι (Fintype.card ι)
If S a finite-dimensional ring extension of a PID R which is free as an R-module,
then any nonzero S-ideal I is free as an R-submodule of S, and we can
find a basis for S and I such that the inclusion map is a square diagonal
matrix.
See Ideal.exists_smith_normal_form for a version of this theorem that doesn't
need to map I into a submodule of R.
This is a strengthening of Submodule.basisOfPid.
theorem Ideal.exists_smith_normal_form E1 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] [IsDomain R] [IsPrincipalIdealRing R] {S : Type u_4}
[inst_3 : CommRing S] [IsDomain S] [inst_5 : Algebra R S] [Finite ι] (b : Module.Basis ι R S) (I : Ideal S),
I ≠ ⊥ → ∃ b' a ab', ∀ (i : ι), ↑(ab' i) = a i • b' i
If S a finite-dimensional ring extension of a PID R which is free as an R-module,
then any nonzero S-ideal I is free as an R-submodule of S, and we can
find a basis for S and I such that the inclusion map is a square diagonal
matrix.
See also Ideal.smithNormalForm for a version of this theorem that returns
a Basis.SmithNormalForm.
The definitions Ideal.ringBasis, Ideal.selfBasis, Ideal.smithCoeffs are (noncomputable)
choices of values for this existential quantifier.
def Ideal.ringBasis E1 #
{ι : Type u_1} →
{R : Type u_2} →
[inst : CommRing R] →
[IsDomain R] →
[IsPrincipalIdealRing R] →
{S : Type u_4} →
[inst_3 : CommRing S] →
[IsDomain S] →
[inst_5 : Algebra R S] → [Finite ι] → Module.Basis ι R S → (I : Ideal S) → I ≠ ⊥ → Module.Basis ι R S
If S a finite-dimensional ring extension of a PID R which is free as an R-module,
then any nonzero S-ideal I is free as an R-submodule of S, and we can
find a basis for S and I such that the inclusion map is a square diagonal
matrix; this is the basis for S. See
Ideal.selfBasisfor the basis onI,Ideal.smithCoeffsfor the entries of the diagonal matrixIdeal.selfBasis_deffor the proof that the inclusion map forms a square diagonal matrix.
def Ideal.selfBasis E1 #
{ι : Type u_1} →
{R : Type u_2} →
[inst : CommRing R] →
[IsDomain R] →
[IsPrincipalIdealRing R] →
{S : Type u_4} →
[inst_3 : CommRing S] →
[IsDomain S] →
[inst_5 : Algebra R S] → [Finite ι] → Module.Basis ι R S → (I : Ideal S) → I ≠ ⊥ → Module.Basis ι R ↥I
If S a finite-dimensional ring extension of a PID R which is free as an R-module,
then any nonzero S-ideal I is free as an R-submodule of S, and we can
find a basis for S and I such that the inclusion map is a square diagonal
matrix; this is the basis for I. See:
Ideal.ringBasisfor the basis onS,Ideal.smithCoeffsfor the entries of the diagonal matrixIdeal.selfBasis_deffor the proof that the inclusion map forms a square diagonal matrix.
def Ideal.smithCoeffs E1 #
{ι : Type u_1} →
{R : Type u_2} →
[inst : CommRing R] →
[IsDomain R] →
[IsPrincipalIdealRing R] →
{S : Type u_4} →
[inst_3 : CommRing S] →
[IsDomain S] → [inst_5 : Algebra R S] → [Finite ι] → Module.Basis ι R S → (I : Ideal S) → I ≠ ⊥ → ι → R
If S a finite-dimensional ring extension of a PID R which is free as an R-module,
then any nonzero S-ideal I is free as an R-submodule of S, and we can
find a basis for S and I such that the inclusion map is a square diagonal
matrix; these are the entries of the diagonal matrix. See :
Ideal.ringBasisfor the basis onS,Ideal.selfBasisfor the basis onI,Ideal.selfBasis_deffor the proof that the inclusion map forms a square diagonal matrix.
theorem Ideal.selfBasis_def E0 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] [inst_1 : IsDomain R] [inst_2 : IsPrincipalIdealRing R]
{S : Type u_4} [inst_3 : CommRing S] [inst_4 : IsDomain S] [inst_5 : Algebra R S] [inst_6 : Finite ι]
(b : Module.Basis ι R S) (I : Ideal S) (hI : I ≠ ⊥) (i : ι),
↑((Ideal.selfBasis b I hI) i) = Ideal.smithCoeffs b I hI i • (Ideal.ringBasis b I hI) i
If S a finite-dimensional ring extension of a PID R which is free as an R-module,
then any nonzero S-ideal I is free as an R-submodule of S, and we can
find a basis for S and I such that the inclusion map is a square diagonal
matrix.
theorem Ideal.smithCoeffs_ne_zero E0 #
∀ {ι : Type u_1} {R : Type u_2} [inst : CommRing R] [inst_1 : IsDomain R] [inst_2 : IsPrincipalIdealRing R]
{S : Type u_4} [inst_3 : CommRing S] [inst_4 : IsDomain S] [inst_5 : Algebra R S] [inst_6 : Finite ι]
(b : Module.Basis ι R S) (I : Ideal S) (hI : I ≠ ⊥) (i : ι), Ideal.smithCoeffs b I hI i ≠ 0