Theorem: Zlattice.rank
File: Mathlib/Algebra/Module/Zlattice/Basic.lean

tactic: have : Module.Finite ℤ L := module_finite K L
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
⊢ finrank ℤ ↥L = finrank K E
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this : Module.Finite ℤ ↥L
⊢ finrank ℤ ↥L = finrank K E

tactic: have : Module.Free ℤ L := module_free K L
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this : Module.Finite ℤ ↥L
⊢ finrank ℤ ↥L = finrank K E
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝ : Module.Finite ℤ ↥L
this : Module.Free ℤ ↥L
⊢ finrank ℤ ↥L = finrank K E

tactic: have : Module ℚ E := Module.compHom E (algebraMap ℚ K)
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝ : Module.Finite ℤ ↥L
this : Module.Free ℤ ↥L
⊢ finrank ℤ ↥L = finrank K E
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝¹ : Module.Finite ℤ ↥L
this✝ : Module.Free ℤ ↥L
this : Module ℚ E
⊢ finrank ℤ ↥L = finrank K E

tactic: let b₀ := Module.Free.chooseBasis ℤ L
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝¹ : Module.Finite ℤ ↥L
this✝ : Module.Free ℤ ↥L
this : Module ℚ E
⊢ finrank ℤ ↥L = finrank K E
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝¹ : Module.Finite ℤ ↥L
this✝ : Module.Free ℤ ↥L
this : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
⊢ finrank ℤ ↥L = finrank K E

tactic: let b := Subtype.val ∘ b₀
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝¹ : Module.Finite ℤ ↥L
this✝ : Module.Free ℤ ↥L
this : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
⊢ finrank ℤ ↥L = finrank K E
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝¹ : Module.Finite ℤ ↥L
this✝ : Module.Free ℤ ↥L
this : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
⊢ finrank ℤ ↥L = finrank K E

tactic: have : LinearIndependent ℤ b :=
  LinearIndependent.map' b₀.linearIndependent (L.toIntSubmodule.subtype) (ker_subtype _)
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝¹ : Module.Finite ℤ ↥L
this✝ : Module.Free ℤ ↥L
this : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
⊢ finrank ℤ ↥L = finrank K E
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
⊢ finrank ℤ ↥L = finrank K E

tactic: have h_spanE : span K (Set.range b) = ⊤ := by
  rw [← span_span_of_tower (R := ℤ), h_spanL]
  exact hs.span_top
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
⊢ finrank ℤ ↥L = finrank K E
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
⊢ finrank ℤ ↥L = finrank K E

tactic: rw [finrank_eq_card_chooseBasisIndex]
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
⊢ finrank ℤ ↥L = finrank K E
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
⊢ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = finrank K E

tactic: refine le_antisymm ?_ ?_
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
⊢ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = finrank K E
state_after: case refine_1
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
⊢ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) ≤ finrank K E

case refine_2
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
⊢ finrank K E ≤ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)

tactic: convert congrArg (map (Submodule.subtype (AddSubgroup.toIntSubmodule L))) b₀.span_eq
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
⊢ span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
state_after: case h.e'_2
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
⊢ span ℤ (Set.range b) = map (AddSubgroup.toIntSubmodule L).subtype (span ℤ (Set.range ⇑b₀))

case h.e'_3
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
⊢ AddSubgroup.toIntSubmodule L = map (AddSubgroup.toIntSubmodule L).subtype ⊤

tactic: rw [map_span, Set.range_comp]
state_before: case h.e'_2
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
⊢ span ℤ (Set.range b) = map (AddSubgroup.toIntSubmodule L).subtype (span ℤ (Set.range ⇑b₀))
state_after: case h.e'_2
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
⊢ span ℤ (Subtype.val '' Set.range ⇑b₀) = span ℤ (⇑(AddSubgroup.toIntSubmodule L).subtype '' Set.range ⇑b₀)

tactic: rfl
state_before: case h.e'_2
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
⊢ span ℤ (Subtype.val '' Set.range ⇑b₀) = span ℤ (⇑(AddSubgroup.toIntSubmodule L).subtype '' Set.range ⇑b₀)
state_after: no goals

tactic: exact (map_subtype_top _).symm
state_before: case h.e'_3
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
⊢ AddSubgroup.toIntSubmodule L = map (AddSubgroup.toIntSubmodule L).subtype ⊤
state_after: no goals

tactic: rw [← span_span_of_tower (R := ℤ), h_spanL]
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
⊢ span K (Set.range b) = ⊤
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
⊢ span K ↑(AddSubgroup.toIntSubmodule L) = ⊤

tactic: exact hs.span_top
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
⊢ span K ↑(AddSubgroup.toIntSubmodule L) = ⊤
state_after: no goals

tactic: rw [Set.toFinset_range, Finset.univ.card_image_of_injective]
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
⊢ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
⊢ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = Finset.univ.card

K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
⊢ Function.Injective b

tactic: rfl
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
⊢ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = Finset.univ.card
state_after: no goals

tactic: exact Subtype.coe_injective.comp (Basis.injective _)
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
⊢ Function.Injective b
state_after: no goals

tactic: obtain ⟨t, ⟨ht_inc, ⟨ht_span, ht_lin⟩⟩⟩ := exists_linearIndependent K (Set.range b)
state_before: case refine_1
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
⊢ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) ≤ finrank K E
state_after: case refine_1.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
⊢ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) ≤ finrank K E

tactic: let e : Basis t K E := Basis.mk ht_lin (by simp [ht_span, h_spanE])
state_before: case refine_1.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
⊢ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) ≤ finrank K E
state_after: case refine_1.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
⊢ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) ≤ finrank K E

tactic: have : Fintype t := Set.Finite.fintype ((Set.range b).toFinite.subset ht_inc)
state_before: case refine_1.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
⊢ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) ≤ finrank K E
state_after: case refine_1.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
⊢ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) ≤ finrank K E

tactic: have h : LinearIndependent ℤ (fun x : (Set.range b) => (x : E)) := by
  rwa [linearIndependent_subtype_range (Subtype.coe_injective.comp b₀.injective)]
state_before: case refine_1.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
⊢ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) ≤ finrank K E
state_after: case refine_1.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : LinearIndependent ℤ fun (x : ↑(Set.range b)) => ↑x
⊢ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) ≤ finrank K E

tactic: contrapose! h
state_before: case refine_1.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : LinearIndependent ℤ fun (x : ↑(Set.range b)) => ↑x
⊢ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) ≤ finrank K E
state_after: case refine_1.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
⊢ ¬LinearIndependent ℤ fun (x : ↑(Set.range b)) => ↑x

tactic: obtain ⟨v, hv⟩ : (Set.range b \ Set.range e).Nonempty := by
  rw [Basis.coe_mk, Subtype.range_coe_subtype, Set.setOf_mem_eq, ← Set.toFinset_nonempty]
  contrapose h
  rw [Finset.not_nonempty_iff_eq_empty, Set.toFinset_diff,
    Finset.sdiff_eq_empty_iff_subset] at h
  replace h := Finset.card_le_card h
  rwa [not_lt, h_card, ← topEquiv.finrank_eq, ← h_spanE, ← ht_span,
    finrank_span_set_eq_card ht_lin]
state_before: case refine_1.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
⊢ ¬LinearIndependent ℤ fun (x : ↑(Set.range b)) => ↑x
state_after: case refine_1.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
⊢ ¬LinearIndependent ℤ fun (x : ↑(Set.range b)) => ↑x

tactic: suffices ¬ LinearIndependent ℤ (fun x : ↥(insert v (Set.range e)) => (x : E)) by
  contrapose! this
  refine LinearIndependent.mono ?_ this
  exact Set.insert_subset (Set.mem_of_mem_diff hv) (by simp [e, ht_inc])
state_before: case refine_1.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
⊢ ¬LinearIndependent ℤ fun (x : ↑(Set.range b)) => ↑x
state_after: case refine_1.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
⊢ ¬LinearIndependent ℤ fun (x : ↑(insert v (Set.range ⇑e))) => ↑x

tactic: rw [LinearIndependent.iff_fractionRing ℤ ℚ,
  linearIndependent_insert (Set.not_mem_of_mem_diff hv),  not_and, not_not]
state_before: case refine_1.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
⊢ ¬LinearIndependent ℤ fun (x : ↑(insert v (Set.range ⇑e))) => ↑x
state_after: case refine_1.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
⊢ (LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b) → v ∈ span ℚ (Set.range ⇑e)

tactic: intro _
state_before: case refine_1.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
⊢ (LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b) → v ∈ span ℚ (Set.range ⇑e)
state_after: case refine_1.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
⊢ v ∈ span ℚ (Set.range ⇑e)

tactic: have h_finite : Set.Finite (Metric.closedBall 0 (∑ i, ‖e i‖) ∩ (L : Set E)) :=
  Metric.finite_isBounded_inter_isClosed Metric.isBounded_closedBall inferInstance
state_before: case refine_1.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
h_mapsto : Set.MapsTo (fun n => Zspan.fract e (n • v)) Set.univ (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L)
⊢ v ∈ span ℚ (Set.range ⇑e)
state_after: case refine_1.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
h_mapsto : Set.MapsTo (fun n => Zspan.fract e (n • v)) Set.univ (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L)
h_finite : (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L).Finite
⊢ v ∈ span ℚ (Set.range ⇑e)

tactic: obtain ⟨n, -, m, -, h_neq, h_eq⟩ := Set.Infinite.exists_ne_map_eq_of_mapsTo
  Set.infinite_univ h_mapsto h_finite
state_before: case refine_1.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
h_mapsto : Set.MapsTo (fun n => Zspan.fract e (n • v)) Set.univ (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L)
h_finite : (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L).Finite
⊢ v ∈ span ℚ (Set.range ⇑e)
state_after: case refine_1.intro.intro.intro.intro.intro.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
h_mapsto : Set.MapsTo (fun n => Zspan.fract e (n • v)) Set.univ (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L)
h_finite : (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L).Finite
n m : ℤ
h_neq : n ≠ m
h_eq : Zspan.fract e (n • v) = Zspan.fract e (m • v)
⊢ v ∈ span ℚ (Set.range ⇑e)

tactic: have h_nz : (-n + m : ℚ) ≠ 0 := by
  rwa [Ne, add_eq_zero_iff_eq_neg.not, neg_inj, Rat.coe_int_inj, ← Ne]
state_before: case refine_1.intro.intro.intro.intro.intro.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
h_mapsto : Set.MapsTo (fun n => Zspan.fract e (n • v)) Set.univ (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L)
h_finite : (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L).Finite
n m : ℤ
h_neq : n ≠ m
h_eq : Zspan.fract e (n • v) = Zspan.fract e (m • v)
⊢ v ∈ span ℚ (Set.range ⇑e)
state_after: case refine_1.intro.intro.intro.intro.intro.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
h_mapsto : Set.MapsTo (fun n => Zspan.fract e (n • v)) Set.univ (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L)
h_finite : (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L).Finite
n m : ℤ
h_neq : n ≠ m
h_eq : Zspan.fract e (n • v) = Zspan.fract e (m • v)
h_nz : -↑n + ↑m ≠ 0
⊢ v ∈ span ℚ (Set.range ⇑e)

tactic: apply (smul_mem_iff _ h_nz).mp
state_before: case refine_1.intro.intro.intro.intro.intro.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
h_mapsto : Set.MapsTo (fun n => Zspan.fract e (n • v)) Set.univ (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L)
h_finite : (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L).Finite
n m : ℤ
h_neq : n ≠ m
h_eq : Zspan.fract e (n • v) = Zspan.fract e (m • v)
h_nz : -↑n + ↑m ≠ 0
⊢ v ∈ span ℚ (Set.range ⇑e)
state_after: case refine_1.intro.intro.intro.intro.intro.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
h_mapsto : Set.MapsTo (fun n => Zspan.fract e (n • v)) Set.univ (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L)
h_finite : (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L).Finite
n m : ℤ
h_neq : n ≠ m
h_eq : Zspan.fract e (n • v) = Zspan.fract e (m • v)
h_nz : -↑n + ↑m ≠ 0
⊢ (-↑n + ↑m) • v ∈ span ℚ (Set.range ⇑e)

tactic: refine span_subset_span ℤ ℚ _ ?_
state_before: case refine_1.intro.intro.intro.intro.intro.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
h_mapsto : Set.MapsTo (fun n => Zspan.fract e (n • v)) Set.univ (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L)
h_finite : (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L).Finite
n m : ℤ
h_neq : n ≠ m
h_eq : Zspan.fract e (n • v) = Zspan.fract e (m • v)
h_nz : -↑n + ↑m ≠ 0
⊢ (-↑n + ↑m) • v ∈ span ℚ (Set.range ⇑e)
state_after: case refine_1.intro.intro.intro.intro.intro.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
h_mapsto : Set.MapsTo (fun n => Zspan.fract e (n • v)) Set.univ (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L)
h_finite : (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L).Finite
n m : ℤ
h_neq : n ≠ m
h_eq : Zspan.fract e (n • v) = Zspan.fract e (m • v)
h_nz : -↑n + ↑m ≠ 0
⊢ (-↑n + ↑m) • v ∈ ↑(span ℤ (Set.range ⇑e))

tactic: rwa [add_smul, neg_smul, SetLike.mem_coe, ← Zspan.fract_eq_fract, ← zsmul_eq_smul_cast ℚ,
  ← zsmul_eq_smul_cast ℚ]
state_before: case refine_1.intro.intro.intro.intro.intro.intro.intro.intro.intro
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
h_mapsto : Set.MapsTo (fun n => Zspan.fract e (n • v)) Set.univ (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L)
h_finite : (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L).Finite
n m : ℤ
h_neq : n ≠ m
h_eq : Zspan.fract e (n • v) = Zspan.fract e (m • v)
h_nz : -↑n + ↑m ≠ 0
⊢ (-↑n + ↑m) • v ∈ ↑(span ℤ (Set.range ⇑e))
state_after: no goals

tactic: simp [ht_span, h_spanE]
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
⊢ ⊤ ≤ span K (Set.range Subtype.val)
state_after: no goals

tactic: rwa [linearIndependent_subtype_range (Subtype.coe_injective.comp b₀.injective)]
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
⊢ LinearIndependent ℤ fun (x : ↑(Set.range b)) => ↑x
state_after: no goals

tactic: rw [Basis.coe_mk, Subtype.range_coe_subtype, Set.setOf_mem_eq, ← Set.toFinset_nonempty]
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
⊢ (Set.range b \ Set.range ⇑e).Nonempty
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
⊢ (Set.range b \ t).toFinset.Nonempty

tactic: contrapose h
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
⊢ (Set.range b \ t).toFinset.Nonempty
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : ¬(Set.range b \ t).toFinset.Nonempty
⊢ ¬finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)

tactic: rw [Finset.not_nonempty_iff_eq_empty, Set.toFinset_diff,
  Finset.sdiff_eq_empty_iff_subset] at h
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : ¬(Set.range b \ t).toFinset.Nonempty
⊢ ¬finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : (Set.range b).toFinset ⊆ t.toFinset
⊢ ¬finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)

tactic: replace h := Finset.card_le_card h
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : (Set.range b).toFinset ⊆ t.toFinset
⊢ ¬finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : (Set.range b).toFinset.card ≤ t.toFinset.card
⊢ ¬finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)

tactic: rwa [not_lt, h_card, ← topEquiv.finrank_eq, ← h_spanE, ← ht_span,
  finrank_span_set_eq_card ht_lin]
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : (Set.range b).toFinset.card ≤ t.toFinset.card
⊢ ¬finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
state_after: no goals

tactic: contrapose! this
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝⁴ : Module.Finite ℤ ↥L
this✝³ : Module.Free ℤ ↥L
this✝² : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝¹ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this✝ : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
this : ¬LinearIndependent ℤ fun (x : ↑(insert v (Set.range ⇑e))) => ↑x
⊢ ¬LinearIndependent ℤ fun (x : ↑(Set.range b)) => ↑x
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝⁴ : Module.Finite ℤ ↥L
this✝³ : Module.Free ℤ ↥L
this✝² : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝¹ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this✝ : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
this : LinearIndependent ℤ fun (x : ↑(Set.range b)) => ↑x
⊢ LinearIndependent ℤ fun (x : ↑(insert v (Set.range ⇑e))) => ↑x

tactic: refine LinearIndependent.mono ?_ this
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝⁴ : Module.Finite ℤ ↥L
this✝³ : Module.Free ℤ ↥L
this✝² : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝¹ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this✝ : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
this : LinearIndependent ℤ fun (x : ↑(Set.range b)) => ↑x
⊢ LinearIndependent ℤ fun (x : ↑(insert v (Set.range ⇑e))) => ↑x
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝⁴ : Module.Finite ℤ ↥L
this✝³ : Module.Free ℤ ↥L
this✝² : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝¹ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this✝ : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
this : LinearIndependent ℤ fun (x : ↑(Set.range b)) => ↑x
⊢ insert v (Set.range ⇑e) ⊆ Set.range b

tactic: exact Set.insert_subset (Set.mem_of_mem_diff hv) (by simp [e, ht_inc])
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝⁴ : Module.Finite ℤ ↥L
this✝³ : Module.Free ℤ ↥L
this✝² : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝¹ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this✝ : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
this : LinearIndependent ℤ fun (x : ↑(Set.range b)) => ↑x
⊢ insert v (Set.range ⇑e) ⊆ Set.range b
state_after: no goals

tactic: simp [e, ht_inc]
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝⁴ : Module.Finite ℤ ↥L
this✝³ : Module.Free ℤ ↥L
this✝² : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝¹ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this✝ : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
this : LinearIndependent ℤ fun (x : ↑(Set.range b)) => ↑x
⊢ Set.range ⇑e ⊆ Set.range b
state_after: no goals

tactic: rw [Set.mapsTo_inter, Set.mapsTo_univ_iff, Set.mapsTo_univ_iff]
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
⊢ Set.MapsTo (fun n => Zspan.fract e (n • v)) Set.univ (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L)
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
⊢ (∀ (x : ℤ), Zspan.fract e (x • v) ∈ Metric.closedBall 0 (∑ i : ↑t, ‖e i‖)) ∧ ∀ (x : ℤ), Zspan.fract e (x • v) ∈ ↑L

tactic: refine ⟨fun _ ↦ mem_closedBall_zero_iff.mpr (Zspan.norm_fract_le e _), fun _ => ?_⟩
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
⊢ (∀ (x : ℤ), Zspan.fract e (x • v) ∈ Metric.closedBall 0 (∑ i : ↑t, ‖e i‖)) ∧ ∀ (x : ℤ), Zspan.fract e (x • v) ∈ ↑L
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
x✝ : ℤ
⊢ Zspan.fract e (x✝ • v) ∈ ↑L

tactic: change _ ∈ AddSubgroup.toIntSubmodule L
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
x✝ : ℤ
⊢ Zspan.fract e (x✝ • v) ∈ ↑L
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
x✝ : ℤ
⊢ Zspan.fract e (x✝ • v) ∈ AddSubgroup.toIntSubmodule L

tactic: rw [← h_spanL]
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
x✝ : ℤ
⊢ Zspan.fract e (x✝ • v) ∈ AddSubgroup.toIntSubmodule L
state_after: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
x✝ : ℤ
⊢ Zspan.fract e (x✝ • v) ∈ span ℤ (Set.range b)

tactic: refine sub_mem ?_ ?_
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
x✝ : ℤ
⊢ Zspan.fract e (x✝ • v) ∈ span ℤ (Set.range b)
state_after: case refine_1
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
x✝ : ℤ
⊢ x✝ • v ∈ span ℤ (Set.range b)

case refine_2
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
x✝ : ℤ
⊢ ↑(Zspan.floor e (x✝ • v)) ∈ span ℤ (Set.range b)

tactic: exact zsmul_mem (subset_span (Set.diff_subset hv)) _
state_before: case refine_1
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
x✝ : ℤ
⊢ x✝ • v ∈ span ℤ (Set.range b)
state_after: no goals

tactic: exact span_mono (by simp [e, ht_inc]) (coe_mem _)
state_before: case refine_2
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
x✝ : ℤ
⊢ ↑(Zspan.floor e (x✝ • v)) ∈ span ℤ (Set.range b)
state_after: no goals

tactic: simp [e, ht_inc]
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
x✝ : ℤ
⊢ Set.range ⇑e ⊆ Set.range b
state_after: no goals

tactic: rwa [Ne, add_eq_zero_iff_eq_neg.not, neg_inj, Rat.coe_int_inj, ← Ne]
state_before: K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝³ : Module.Finite ℤ ↥L
this✝² : Module.Free ℤ ↥L
this✝¹ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this✝ : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
t : Set E
ht_inc : t ⊆ Set.range b
ht_span : span K t = span K (Set.range b)
ht_lin : LinearIndependent (ι := { x // x ∈ t }) K Subtype.val
e : Basis (↑t) K E := Basis.mk ht_lin ⋯
this : Fintype ↑t
h : finrank K E < Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
v : E
hv : v ∈ Set.range b \ Set.range ⇑e
a✝ : LinearIndependent ℚ fun (b : ↑(Set.range ⇑e)) => ↑b
h_mapsto : Set.MapsTo (fun n => Zspan.fract e (n • v)) Set.univ (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L)
h_finite : (Metric.closedBall 0 (∑ i : ↑t, ‖e i‖) ∩ ↑L).Finite
n m : ℤ
h_neq : n ≠ m
h_eq : Zspan.fract e (n • v) = Zspan.fract e (m • v)
⊢ -↑n + ↑m ≠ 0
state_after: no goals

tactic: rw [← topEquiv.finrank_eq, ← h_spanE]
state_before: case refine_2
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
⊢ finrank K E ≤ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
state_after: case refine_2
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
⊢ finrank K ↥(span K (Set.range b)) ≤ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)

tactic: convert finrank_span_le_card (R := K) (Set.range b)
state_before: case refine_2
K : Type u_1
inst✝⁷ : NormedLinearOrderedField K
inst✝⁶ : HasSolidNorm K
inst✝⁵ : FloorRing K
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace K E
inst✝² : FiniteDimensional K E
inst✝¹ : ProperSpace E
L : AddSubgroup E
inst✝ : DiscreteTopology ↥L
hs : IsZlattice K L
this✝² : Module.Finite ℤ ↥L
this✝¹ : Module.Free ℤ ↥L
this✝ : Module ℚ E
b₀ : Basis (Module.Free.ChooseBasisIndex ℤ ↥L) ℤ ↥L := Module.Free.chooseBasis ℤ ↥L
b : Module.Free.ChooseBasisIndex ℤ ↥L → E := Subtype.val ∘ ⇑b₀
this : LinearIndependent ℤ b
h_spanL : span ℤ (Set.range b) = AddSubgroup.toIntSubmodule L
h_spanE : span K (Set.range b) = ⊤
h_card : Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L) = (Set.range b).toFinset.card
⊢ finrank K ↥(span K (Set.range b)) ≤ Fintype.card (Module.Free.ChooseBasisIndex ℤ ↥L)
state_after: no goals