Theorem: Submodule.eq_top_of_finrank_eq
File: Mathlib/LinearAlgebra/FiniteDimensional.lean

tactic: haveI : IsNoetherian K V := iff_fg.2 inferInstance
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
⊢ S = ⊤
state_after: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this : IsNoetherian K V
⊢ S = ⊤

tactic: set bS := Basis.ofVectorSpace K S with bS_eq
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this : IsNoetherian K V
⊢ S = ⊤
state_after: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
⊢ S = ⊤

tactic: have : LinearIndependent K ((↑) : ((↑) '' Basis.ofVectorSpaceIndex K S : Set V) → V) :=
  LinearIndependent.image_subtype (f := Submodule.subtype S)
    (by simpa [bS] using bS.linearIndependent) (by simp)
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
⊢ S = ⊤
state_after: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
⊢ S = ⊤

tactic: set b := Basis.extend this with b_eq
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
⊢ S = ⊤
state_after: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this.extend ⋯)) K V := Basis.extend this
b_eq : b = Basis.extend this
⊢ S = ⊤

tactic: letI i1 : Fintype (this.extend _) :=
  (LinearIndependent.set_finite_of_isNoetherian (by simpa [b] using b.linearIndependent)).fintype
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this.extend ⋯)) K V := Basis.extend this
b_eq : b = Basis.extend this
⊢ S = ⊤
state_after: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this.extend ⋯)) K V := Basis.extend this
b_eq : b = Basis.extend this
i1 : Fintype ↑(this.extend ⋯) := ⋯.fintype
⊢ S = ⊤

tactic: letI i2 : Fintype (((↑) : S → V) '' Basis.ofVectorSpaceIndex K S) :=
  (LinearIndependent.set_finite_of_isNoetherian this).fintype
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this.extend ⋯)) K V := Basis.extend this
b_eq : b = Basis.extend this
i1 : Fintype ↑(this.extend ⋯) := ⋯.fintype
⊢ S = ⊤
state_after: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this.extend ⋯)) K V := Basis.extend this
b_eq : b = Basis.extend this
i1 : Fintype ↑(this.extend ⋯) := ⋯.fintype
i2 : Fintype ↑(Subtype.val '' Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
⊢ S = ⊤

tactic: letI i3 : Fintype (Basis.ofVectorSpaceIndex K S) :=
  (LinearIndependent.set_finite_of_isNoetherian
    (by simpa [bS] using bS.linearIndependent)).fintype
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this.extend ⋯)) K V := Basis.extend this
b_eq : b = Basis.extend this
i1 : Fintype ↑(this.extend ⋯) := ⋯.fintype
i2 : Fintype ↑(Subtype.val '' Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
⊢ S = ⊤
state_after: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this.extend ⋯)) K V := Basis.extend this
b_eq : b = Basis.extend this
i1 : Fintype ↑(this.extend ⋯) := ⋯.fintype
i2 : Fintype ↑(Subtype.val '' Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
i3 : Fintype ↑(Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
⊢ S = ⊤

tactic: have : (↑) '' Basis.ofVectorSpaceIndex K S = this.extend (Set.subset_univ _) :=
  Set.eq_of_subset_of_card_le (this.subset_extend _)
    (by
      rw [Set.card_image_of_injective _ Subtype.coe_injective, ← finrank_eq_card_basis bS, ←
          finrank_eq_card_basis b, h])
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this.extend ⋯)) K V := Basis.extend this
b_eq : b = Basis.extend this
i1 : Fintype ↑(this.extend ⋯) := ⋯.fintype
i2 : Fintype ↑(Subtype.val '' Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
i3 : Fintype ↑(Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
⊢ S = ⊤
state_after: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝¹ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this✝ : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this✝.extend ⋯)) K V := Basis.extend this✝
b_eq : b = Basis.extend this✝
i1 : Fintype ↑(this✝.extend ⋯) := ⋯.fintype
i2 : Fintype ↑(Subtype.val '' Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
i3 : Fintype ↑(Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
this : Subtype.val '' Basis.ofVectorSpaceIndex K ↥S = this✝.extend ⋯
⊢ S = ⊤

tactic: rw [← b.span_eq, b_eq, Basis.coe_extend, Subtype.range_coe, ← this, ← Submodule.coeSubtype,
  span_image]
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝¹ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this✝ : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this✝.extend ⋯)) K V := Basis.extend this✝
b_eq : b = Basis.extend this✝
i1 : Fintype ↑(this✝.extend ⋯) := ⋯.fintype
i2 : Fintype ↑(Subtype.val '' Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
i3 : Fintype ↑(Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
this : Subtype.val '' Basis.ofVectorSpaceIndex K ↥S = this✝.extend ⋯
⊢ S = ⊤
state_after: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝¹ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this✝ : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this✝.extend ⋯)) K V := Basis.extend this✝
b_eq : b = Basis.extend this✝
i1 : Fintype ↑(this✝.extend ⋯) := ⋯.fintype
i2 : Fintype ↑(Subtype.val '' Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
i3 : Fintype ↑(Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
this : Subtype.val '' Basis.ofVectorSpaceIndex K ↥S = this✝.extend ⋯
⊢ S = Submodule.map S.subtype (span K (Basis.ofVectorSpaceIndex K ↥S))

tactic: have := bS.span_eq
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝¹ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this✝ : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this✝.extend ⋯)) K V := Basis.extend this✝
b_eq : b = Basis.extend this✝
i1 : Fintype ↑(this✝.extend ⋯) := ⋯.fintype
i2 : Fintype ↑(Subtype.val '' Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
i3 : Fintype ↑(Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
this : Subtype.val '' Basis.ofVectorSpaceIndex K ↥S = this✝.extend ⋯
⊢ S = Submodule.map S.subtype (span K (Basis.ofVectorSpaceIndex K ↥S))
state_after: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝² : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this✝¹ : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this✝¹.extend ⋯)) K V := Basis.extend this✝¹
b_eq : b = Basis.extend this✝¹
i1 : Fintype ↑(this✝¹.extend ⋯) := ⋯.fintype
i2 : Fintype ↑(Subtype.val '' Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
i3 : Fintype ↑(Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
this✝ : Subtype.val '' Basis.ofVectorSpaceIndex K ↥S = this✝¹.extend ⋯
this : span K (Set.range ⇑bS) = ⊤
⊢ S = Submodule.map S.subtype (span K (Basis.ofVectorSpaceIndex K ↥S))

tactic: rw [bS_eq, Basis.coe_ofVectorSpace, Subtype.range_coe] at this
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝² : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this✝¹ : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this✝¹.extend ⋯)) K V := Basis.extend this✝¹
b_eq : b = Basis.extend this✝¹
i1 : Fintype ↑(this✝¹.extend ⋯) := ⋯.fintype
i2 : Fintype ↑(Subtype.val '' Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
i3 : Fintype ↑(Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
this✝ : Subtype.val '' Basis.ofVectorSpaceIndex K ↥S = this✝¹.extend ⋯
this : span K (Set.range ⇑bS) = ⊤
⊢ S = Submodule.map S.subtype (span K (Basis.ofVectorSpaceIndex K ↥S))
state_after: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝² : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this✝¹ : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this✝¹.extend ⋯)) K V := Basis.extend this✝¹
b_eq : b = Basis.extend this✝¹
i1 : Fintype ↑(this✝¹.extend ⋯) := ⋯.fintype
i2 : Fintype ↑(Subtype.val '' Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
i3 : Fintype ↑(Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
this✝ : Subtype.val '' Basis.ofVectorSpaceIndex K ↥S = this✝¹.extend ⋯
this : span K (Basis.ofVectorSpaceIndex K ↥S) = ⊤
⊢ S = Submodule.map S.subtype (span K (Basis.ofVectorSpaceIndex K ↥S))

tactic: rw [this, Submodule.map_top (Submodule.subtype S), range_subtype]
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝² : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this✝¹ : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this✝¹.extend ⋯)) K V := Basis.extend this✝¹
b_eq : b = Basis.extend this✝¹
i1 : Fintype ↑(this✝¹.extend ⋯) := ⋯.fintype
i2 : Fintype ↑(Subtype.val '' Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
i3 : Fintype ↑(Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
this✝ : Subtype.val '' Basis.ofVectorSpaceIndex K ↥S = this✝¹.extend ⋯
this : span K (Basis.ofVectorSpaceIndex K ↥S) = ⊤
⊢ S = Submodule.map S.subtype (span K (Basis.ofVectorSpaceIndex K ↥S))
state_after: no goals

tactic: simpa [bS] using bS.linearIndependent
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
⊢ LinearIndependent K fun (x : ↑(Basis.ofVectorSpaceIndex K ↥S)) => ↑x
state_after: no goals

tactic: simp
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
⊢ Disjoint (span K (Basis.ofVectorSpaceIndex K ↥S)) (LinearMap.ker S.subtype)
state_after: no goals

tactic: simpa [b] using b.linearIndependent
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this.extend ⋯)) K V := Basis.extend this
b_eq : b = Basis.extend this
⊢ LinearIndependent (ι := { x // x ∈ this.extend ?m.85395 }) ?m.85547 Subtype.val
state_after: no goals

tactic: simpa [bS] using bS.linearIndependent
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this.extend ⋯)) K V := Basis.extend this
b_eq : b = Basis.extend this
i1 : Fintype ↑(this.extend ⋯) := ⋯.fintype
i2 : Fintype ↑(Subtype.val '' Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
⊢ LinearIndependent (ι := { x // x ∈ Basis.ofVectorSpaceIndex K ↥S }) ?m.91170 Subtype.val
state_after: no goals

tactic: rw [Set.card_image_of_injective _ Subtype.coe_injective, ← finrank_eq_card_basis bS, ←
    finrank_eq_card_basis b, h]
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
S : Submodule K V
h : finrank K ↥S = finrank K V
this✝ : IsNoetherian K V
bS : Basis (↑(Basis.ofVectorSpaceIndex K ↥S)) K ↥S := Basis.ofVectorSpace K ↥S
bS_eq : bS = Basis.ofVectorSpace K ↥S
this : LinearIndependent (ι := { x // x ∈ Subtype.val '' Basis.ofVectorSpaceIndex K ↥S }) K Subtype.val
b : Basis (↑(this.extend ⋯)) K V := Basis.extend this
b_eq : b = Basis.extend this
i1 : Fintype ↑(this.extend ⋯) := ⋯.fintype
i2 : Fintype ↑(Subtype.val '' Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
i3 : Fintype ↑(Basis.ofVectorSpaceIndex K ↥S) := ⋯.fintype
⊢ Fintype.card ↑(this.extend ⋯) ≤ Fintype.card ↑(Subtype.val '' Basis.ofVectorSpaceIndex K ↥S)
state_after: no goals