tasksource/leandojo huggingface dataset:
Theorem: OrderIso.map_tsub
File: Mathlib/Algebra/Order/Sub/Basic.lean

tactic: let e_add : M ≃+ N := { e with map_add' := h_add }
state_before: α : Type ?u.7326
β : Type ?u.7329
M : Type u_1
N : Type u_2
inst✝⁷ : Preorder M
inst✝⁶ : Add M
inst✝⁵ : Sub M
inst✝⁴ : OrderedSub M
inst✝³ : PartialOrder N
inst✝² : Add N
inst✝¹ : Sub N
inst✝ : OrderedSub N
e : M ≃o N
h_add : ∀ (a b : M), ↑e (a + b) = ↑e a + ↑e b
a b : M
⊢ ↑e (a - b) = ↑e a - ↑e b

tactic: refine' le_antisymm _ (e_add.toAddHom.le_map_tsub e.monotone a b)
state_before: α : Type ?u.7326
β : Type ?u.7329
M : Type u_1
N : Type u_2
inst✝⁷ : Preorder M
inst✝⁶ : Add M
inst✝⁵ : Sub M
inst✝⁴ : OrderedSub M
inst✝³ : PartialOrder N
inst✝² : Add N
inst✝¹ : Sub N
inst✝ : OrderedSub N
e : M ≃o N
h_add : ∀ (a b : M), ↑e (a + b) = ↑e a + ↑e b
a b : M
e_add : M ≃+ N := { toEquiv := e.toEquiv, map_add' := h_add }
⊢ ↑e (a - b) = ↑e a - ↑e b

tactic: suffices e (e.symm (e a) - e.symm (e b)) ≤ e (e.symm (e a - e b)) by simpa
state_before: α : Type ?u.7326
β : Type ?u.7329
M : Type u_1
N : Type u_2
inst✝⁷ : Preorder M
inst✝⁶ : Add M
inst✝⁵ : Sub M
inst✝⁴ : OrderedSub M
inst✝³ : PartialOrder N
inst✝² : Add N
inst✝¹ : Sub N
inst✝ : OrderedSub N
e : M ≃o N
h_add : ∀ (a b : M), ↑e (a + b) = ↑e a + ↑e b
a b : M
e_add : M ≃+ N := { toEquiv := e.toEquiv, map_add' := h_add }
⊢ ↑e (a - b) ≤ ↑e a - ↑e b

tactic: exact e.monotone (e_add.symm.toAddHom.le_map_tsub e.symm.monotone _ _)
state_before: α : Type ?u.7326
β : Type ?u.7329
M : Type u_1
N : Type u_2
inst✝⁷ : Preorder M
inst✝⁶ : Add M
inst✝⁵ : Sub M
inst✝⁴ : OrderedSub M
inst✝³ : PartialOrder N
inst✝² : Add N
inst✝¹ : Sub N
inst✝ : OrderedSub N
e : M ≃o N
h_add : ∀ (a b : M), ↑e (a + b) = ↑e a + ↑e b
a b : M
e_add : M ≃+ N := { toEquiv := e.toEquiv, map_add' := h_add }
⊢ ↑e (↑(symm e) (↑e a) - ↑(symm e) (↑e b)) ≤ ↑e (↑(symm e) (↑e a - ↑e b))

tactic: simpa
state_before: α : Type ?u.7326
β : Type ?u.7329
M : Type u_1
N : Type u_2
inst✝⁷ : Preorder M
inst✝⁶ : Add M
inst✝⁵ : Sub M
inst✝⁴ : OrderedSub M
inst✝³ : PartialOrder N
inst✝² : Add N
inst✝¹ : Sub N
inst✝ : OrderedSub N
e : M ≃o N
h_add : ∀ (a b : M), ↑e (a + b) = ↑e a + ↑e b
a b : M
e_add : M ≃+ N := { toEquiv := e.toEquiv, map_add' := h_add }
this : ↑e (↑(symm e) (↑e a) - ↑(symm e) (↑e b)) ≤ ↑e (↑(symm e) (↑e a - ↑e b))
⊢ ↑e (a - b) ≤ ↑e a - ↑e b
Theorem: FractionalIdeal.mem_spanSingleton
File: Mathlib/RingTheory/FractionalIdeal.lean

tactic: rw [spanSingleton]
state_before: R : Type u_2
inst✝⁶ : CommRing R
S : Submonoid R
P : Type u_1
inst✝⁵ : CommRing P
inst✝⁴ : Algebra R P
loc : IsLocalization S P
R₁ : Type ?u.1298308
inst✝³ : CommRing R₁
K : Type ?u.1298314
inst✝² : Field K
inst✝¹ : Algebra R₁ K
inst✝ : IsFractionRing R₁ K
x y : P
⊢ x ∈ spanSingleton S y ↔ ∃ z, z • y = x

tactic: exact Submodule.mem_span_singleton
state_before: R : Type u_2
inst✝⁶ : CommRing R
S : Submonoid R
P : Type u_1
inst✝⁵ : CommRing P
inst✝⁴ : Algebra R P
loc : IsLocalization S P
R₁ : Type ?u.1298308
inst✝³ : CommRing R₁
K : Type ?u.1298314
inst✝² : Field K
inst✝¹ : Algebra R₁ K
inst✝ : IsFractionRing R₁ K
x y : P
⊢ x ∈ { val := span R {y}, property := (_ : IsFractional S (span R {y})) } ↔ ∃ z, z • y = x
Theorem: Filter.zero_smul_filter
File: Mathlib/Order/Filter/Pointwise.lean

tactic: simp_rw [zero_smul, (hg.nonempty_of_mem hs).image_const]
state_before: F : Type ?u.443848
α : Type u_2
β : Type u_1
γ : Type ?u.443857
δ : Type ?u.443860
ε : Type ?u.443863
inst✝² : Zero α
inst✝¹ : Zero β
inst✝ : SMulWithZero α β
f : Filter α
g : Filter β
hg : NeBot g
s : Set β
hs : s ∈ g
⊢ (fun x x_1 => x • x_1) 0 '' s ∈ 0

tactic: exact zero_mem_zero
state_before: F : Type ?u.443848
α : Type u_2
β : Type u_1
γ : Type ?u.443857
δ : Type ?u.443860
ε : Type ?u.443863
inst✝² : Zero α
inst✝¹ : Zero β
inst✝ : SMulWithZero α β
f : Filter α
g : Filter β
hg : NeBot g
s : Set β
hs : s ∈ g
⊢ {0} ∈ 0
Theorem: Complex.conj_ofReal
File: Mathlib/Data/Complex/Basic.lean

tactic: simp [star]
state_before: r : ℝ
⊢ (↑(starRingEnd ℂ) ↑r).re = (↑r).re ∧ (↑(starRingEnd ℂ) ↑r).im = (↑r).im
Theorem: CategoryTheory.Preadditive.IsIso.comp_left_eq_zero
File: Mathlib/CategoryTheory/Preadditive/Basic.lean

tactic: rw [← IsIso.eq_inv_comp, Limits.comp_zero]
state_before: C : Type u
inst✝² : Category C
inst✝¹ : Preadditive C
P Q R : C
f f' : P ⟶ Q
g g' : Q ⟶ R
inst✝ : IsIso f
⊢ f ≫ g = 0 ↔ g = 0
Theorem: AddLECancellable.tsub_le_tsub_iff_left
File: Mathlib/Algebra/Order/Sub/Canonical.lean

tactic: refine' ⟨_, fun h => tsub_le_tsub_left h a⟩
state_before: α : Type u_1
inst✝² : CanonicallyOrderedAddMonoid α
inst✝¹ : Sub α
inst✝ : OrderedSub α
a b c d : α
ha : AddLECancellable a
hc : AddLECancellable c
h : c ≤ a
⊢ a - b ≤ a - c ↔ c ≤ b

tactic: rw [tsub_le_iff_left, ← hc.add_tsub_assoc_of_le h, hc.le_tsub_iff_right (h.trans le_add_self),
  add_comm b]
state_before: α : Type u_1
inst✝² : CanonicallyOrderedAddMonoid α
inst✝¹ : Sub α
inst✝ : OrderedSub α
a b c d : α
ha : AddLECancellable a
hc : AddLECancellable c
h : c ≤ a
⊢ a - b ≤ a - c → c ≤ b

tactic: apply ha
state_before: α : Type u_1
inst✝² : CanonicallyOrderedAddMonoid α
inst✝¹ : Sub α
inst✝ : OrderedSub α
a b c d : α
ha : AddLECancellable a
hc : AddLECancellable c
h : c ≤ a
⊢ a + c ≤ a + b → c ≤ b
Theorem: MvPFunctor.M.map_dest
File: Mathlib/Data/PFunctor/Multivariate/M.lean

tactic: rw [M.dest_map]
state_before: n : ℕ
P : MvPFunctor (n + 1)
α β : TypeVec n
g : α ::: M P α ⟹ β ::: M P β
x : M P α
h : ∀ (x : M P α), lastFun g x = dropFun g <$$> x
⊢ g <$$> dest P x = dest P (dropFun g <$$> x)

tactic: congr
state_before: n : ℕ
P : MvPFunctor (n + 1)
α β : TypeVec n
g : α ::: M P α ⟹ β ::: M P β
x : M P α
h : ∀ (x : M P α), lastFun g x = dropFun g <$$> x
⊢ g <$$> dest P x = (dropFun g ::: fun x => dropFun g <$$> x) <$$> dest P x

tactic: apply eq_of_drop_last_eq <;> simp
state_before: case e_a
n : ℕ
P : MvPFunctor (n + 1)
α β : TypeVec n
g : α ::: M P α ⟹ β ::: M P β
x : M P α
h : ∀ (x : M P α), lastFun g x = dropFun g <$$> x
⊢ g = (dropFun g ::: fun x => dropFun g <$$> x)

tactic: ext1
state_before: case e_a.h₁
n : ℕ
P : MvPFunctor (n + 1)
α β : TypeVec n
g : α ::: M P α ⟹ β ::: M P β
x : M P α
h : ∀ (x : M P α), lastFun g x = dropFun g <$$> x
⊢ lastFun g = fun x => dropFun g <$$> x

tactic: apply h
state_before: case e_a.h₁.h
n : ℕ
P : MvPFunctor (n + 1)
α β : TypeVec n
g : α ::: M P α ⟹ β ::: M P β
x : M P α
h : ∀ (x : M P α), lastFun g x = dropFun g <$$> x
x✝ : TypeVec.last (α ::: M P α)
⊢ lastFun g x✝ = dropFun g <$$> x✝
Theorem: Polynomial.coeff_sub_eq_left_of_lt
File: Mathlib/Data/Polynomial/Degree/Lemmas.lean

tactic: rw [← natDegree_neg] at dg
state_before: R : Type u
S : Type v
ι : Type w
a b : R
m n : ℕ
inst✝ : Ring R
p q : R[X]
dg : natDegree q < n
⊢ coeff (p - q) n = coeff p n

tactic: rw [sub_eq_add_neg, coeff_add_eq_left_of_lt dg]
state_before: R : Type u
S : Type v
ι : Type w
a b : R
m n : ℕ
inst✝ : Ring R
p q : R[X]
dg : natDegree (-q) < n
⊢ coeff (p - q) n = coeff p n
Theorem: Set.image_eq_iff_surjOn_mapsTo
File: Mathlib/Data/Set/Function.lean

tactic: refine' ⟨_, fun h => h.1.image_eq_of_mapsTo h.2⟩
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.48017
ι : Sort ?u.48020
π : α → Type ?u.48025
s s₁ s₂ : Set α
t t₁ t₂ : Set β
p : Set γ
f f₁ f₂ f₃ : α → β
g g₁ g₂ : β → γ
f' f₁' f₂' : β → α
g' : γ → β
a : α
b : β
⊢ f '' s = t ↔ SurjOn f s t ∧ MapsTo f s t

tactic: rintro rfl
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.48017
ι : Sort ?u.48020
π : α → Type ?u.48025
s s₁ s₂ : Set α
t t₁ t₂ : Set β
p : Set γ
f f₁ f₂ f₃ : α → β
g g₁ g₂ : β → γ
f' f₁' f₂' : β → α
g' : γ → β
a : α
b : β
⊢ f '' s = t → SurjOn f s t ∧ MapsTo f s t

tactic: exact ⟨s.surjOn_image f, s.mapsTo_image f⟩
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.48017
ι : Sort ?u.48020
π : α → Type ?u.48025
s s₁ s₂ : Set α
t₁ t₂ : Set β
p : Set γ
f f₁ f₂ f₃ : α → β
g g₁ g₂ : β → γ
f' f₁' f₂' : β → α
g' : γ → β
a : α
b : β
⊢ SurjOn f s (f '' s) ∧ MapsTo f s (f '' s)
Theorem: Submodule.mem_div_iff_smul_subset
File: Mathlib/Algebra/Algebra/Operations.lean

tactic: rw [← xy'_eq_y]
state_before: ι : Sort uι
R : Type u
inst✝² : CommSemiring R
A : Type v
inst✝¹ : CommSemiring A
inst✝ : Algebra R A
M N : Submodule R A
m n x : A
I J : Submodule R A
h : x ∈ I / J
y : A
x✝ : y ∈ x • ↑J
y' : A
hy' : y' ∈ ↑J
xy'_eq_y : (fun x_1 => x • x_1) y' = y
⊢ y ∈ ↑I

tactic: apply h
state_before: ι : Sort uι
R : Type u
inst✝² : CommSemiring R
A : Type v
inst✝¹ : CommSemiring A
inst✝ : Algebra R A
M N : Submodule R A
m n x : A
I J : Submodule R A
h : x ∈ I / J
y : A
x✝ : y ∈ x • ↑J
y' : A
hy' : y' ∈ ↑J
xy'_eq_y : (fun x_1 => x • x_1) y' = y
⊢ (fun x_1 => x • x_1) y' ∈ ↑I

tactic: assumption
state_before: case a
ι : Sort uι
R : Type u
inst✝² : CommSemiring R
A : Type v
inst✝¹ : CommSemiring A
inst✝ : Algebra R A
M N : Submodule R A
m n x : A
I J : Submodule R A
h : x ∈ I / J
y : A
x✝ : y ∈ x • ↑J
y' : A
hy' : y' ∈ ↑J
xy'_eq_y : (fun x_1 => x • x_1) y' = y
⊢ y' ∈ J
Theorem: PGame.fuzzy_congr
File: Mathlib/SetTheory/Game/PGame.lean

tactic: rw [lf_congr hx hy, lf_congr hy hx]
state_before: x₁ y₁ x₂ y₂ : PGame
hx : x₁ ≈ x₂
hy : y₁ ≈ y₂
⊢ x₁ ⧏ y₁ ∧ y₁ ⧏ x₁ ↔ x₂ ⧏ y₂ ∧ y₂ ⧏ x₂
Theorem: Ideal.mem_span_singleton_mul
File: Mathlib/RingTheory/Ideal/Operations.lean

tactic: simp only [mul_comm, mem_mul_span_singleton]
state_before: R : Type u
ι : Type ?u.228713
inst✝ : CommSemiring R
I✝ J K L : Ideal R
x y : R
I : Ideal R
⊢ x ∈ span {y} * I ↔ ∃ z, z ∈ I ∧ y * z = x
Theorem: Part.bind_some_right
File: Mathlib/Data/Part.lean

tactic: erw [bind_some_eq_map]
state_before: α : Type u_1
β : Type ?u.49896
γ : Type ?u.49899
x : Part α
⊢ Part.bind x some = x

tactic: simp [map_id']
state_before: α : Type u_1
β : Type ?u.49896
γ : Type ?u.49899
x : Part α
⊢ map (fun a => a) x = x
Theorem: Finset.prod_mulIndicator_eq_prod_filter
File: Mathlib/Algebra/IndicatorFunction.lean

tactic: refine' (Finset.prod_filter_mul_prod_filter_not s (fun i => g i ∈ t i) _).symm.trans _
state_before: α : Type u_2
β : Type ?u.106435
ι : Type u_1
M : Type u_3
N : Type ?u.106444
inst✝¹ : CommMonoid M
s : Finset ι
f : ι → α → M
t : ι → Set α
g : ι → α
inst✝ : DecidablePred fun i => g i ∈ t i
⊢ ∏ i in s, mulIndicator (t i) (f i) (g i) = ∏ i in Finset.filter (fun i => g i ∈ t i) s, f i (g i)

tactic: refine' Eq.trans _ (mul_one _)
state_before: α : Type u_2
β : Type ?u.106435
ι : Type u_1
M : Type u_3
N : Type ?u.106444
inst✝¹ : CommMonoid M
s : Finset ι
f : ι → α → M
t : ι → Set α
g : ι → α
inst✝ : DecidablePred fun i => g i ∈ t i
⊢ (∏ x in Finset.filter (fun i => g i ∈ t i) s, mulIndicator (t x) (f x) (g x)) *
      ∏ x in Finset.filter (fun x => ¬g x ∈ t x) s, mulIndicator (t x) (f x) (g x) =
    ∏ i in Finset.filter (fun i => g i ∈ t i) s, f i (g i)
Theorem: Metric.infDist_inter_closedBall_of_mem
File: Mathlib/Topology/MetricSpace/HausdorffDistance.lean

tactic: replace h : y ∈ s ∩ closedBall x (dist y x) := ⟨h, mem_closedBall.2 le_rfl⟩
state_before: ι : Sort ?u.67810
α : Type u
β : Type v
inst✝¹ : PseudoMetricSpace α
inst✝ : PseudoMetricSpace β
s t u : Set α
x y : α
Φ : α → β
h : y ∈ s
⊢ infDist x (s ∩ closedBall x (dist y x)) = infDist x s

tactic: refine le_antisymm ?_ (infDist_le_infDist_of_subset (inter_subset_left _ _) ⟨y, h⟩)
state_before: ι : Sort ?u.67810
α : Type u
β : Type v
inst✝¹ : PseudoMetricSpace α
inst✝ : PseudoMetricSpace β
s t u : Set α
x y : α
Φ : α → β
h : y ∈ s ∩ closedBall x (dist y x)
⊢ infDist x (s ∩ closedBall x (dist y x)) = infDist x s

tactic: refine' not_lt.1 fun hlt => _
state_before: ι : Sort ?u.67810
α : Type u
β : Type v
inst✝¹ : PseudoMetricSpace α
inst✝ : PseudoMetricSpace β
s t u : Set α
x y : α
Φ : α → β
h : y ∈ s ∩ closedBall x (dist y x)
⊢ infDist x (s ∩ closedBall x (dist y x)) ≤ infDist x s

tactic: rcases (infDist_lt_iff ⟨y, h.1⟩).mp hlt with ⟨z, hzs, hz⟩
state_before: ι : Sort ?u.67810
α : Type u
β : Type v
inst✝¹ : PseudoMetricSpace α
inst✝ : PseudoMetricSpace β
s t u : Set α
x y : α
Φ : α → β
h : y ∈ s ∩ closedBall x (dist y x)
hlt : infDist x s < infDist x (s ∩ closedBall x (dist y x))
⊢ False

tactic: cases' le_or_lt (dist z x) (dist y x) with hle hlt
state_before: case intro.intro
ι : Sort ?u.67810
α : Type u
β : Type v
inst✝¹ : PseudoMetricSpace α
inst✝ : PseudoMetricSpace β
s t u : Set α
x y : α
Φ : α → β
h : y ∈ s ∩ closedBall x (dist y x)
hlt : infDist x s < infDist x (s ∩ closedBall x (dist y x))
z : α
hzs : z ∈ s
hz : dist x z < infDist x (s ∩ closedBall x (dist y x))
⊢ False

tactic: exact hz.not_le (infDist_le_dist_of_mem ⟨hzs, hle⟩)
state_before: case intro.intro.inl
ι : Sort ?u.67810
α : Type u
β : Type v
inst✝¹ : PseudoMetricSpace α
inst✝ : PseudoMetricSpace β
s t u : Set α
x y : α
Φ : α → β
h : y ∈ s ∩ closedBall x (dist y x)
hlt : infDist x s < infDist x (s ∩ closedBall x (dist y x))
z : α
hzs : z ∈ s
hz : dist x z < infDist x (s ∩ closedBall x (dist y x))
hle : dist z x ≤ dist y x
⊢ False

tactic: rw [dist_comm z, dist_comm y] at hlt
state_before: case intro.intro.inr
ι : Sort ?u.67810
α : Type u
β : Type v
inst✝¹ : PseudoMetricSpace α
inst✝ : PseudoMetricSpace β
s t u : Set α
x y : α
Φ : α → β
h : y ∈ s ∩ closedBall x (dist y x)
hlt✝ : infDist x s < infDist x (s ∩ closedBall x (dist y x))
z : α
hzs : z ∈ s
hz : dist x z < infDist x (s ∩ closedBall x (dist y x))
hlt : dist y x < dist z x
⊢ False

tactic: exact (hlt.trans hz).not_le (infDist_le_dist_of_mem h)
state_before: case intro.intro.inr
ι : Sort ?u.67810
α : Type u
β : Type v
inst✝¹ : PseudoMetricSpace α
inst✝ : PseudoMetricSpace β
s t u : Set α
x y : α
Φ : α → β
h : y ∈ s ∩ closedBall x (dist y x)
hlt✝ : infDist x s < infDist x (s ∩ closedBall x (dist y x))
z : α
hzs : z ∈ s
hz : dist x z < infDist x (s ∩ closedBall x (dist y x))
hlt : dist x y < dist x z
⊢ False
Theorem: Set.chainHeight_eq_zero_iff
File: Mathlib/Order/Height.lean

tactic: rw [← not_iff_not, ← Ne.def, ← ENat.one_le_iff_ne_zero, one_le_chainHeight_iff,
  nonempty_iff_ne_empty]
state_before: α : Type u_1
β : Type ?u.9191
inst✝¹ : LT α
inst✝ : LT β
s t : Set α
l : List α
a : α
⊢ chainHeight s = 0 ↔ s = ∅
Theorem: Nonneg.toNonneg_le
File: Mathlib/Algebra/Order/Nonneg/Ring.lean

tactic: cases' b with b hb
state_before: α : Type u_1
inst✝¹ : Zero α
inst✝ : LinearOrder α
a : α
b : { x // 0 ≤ x }
⊢ toNonneg a ≤ b ↔ a ≤ ↑b

tactic: simp [toNonneg, hb]
state_before: case mk
α : Type u_1
inst✝¹ : Zero α
inst✝ : LinearOrder α
a b : α
hb : 0 ≤ b
⊢ toNonneg a ≤ { val := b, property := hb } ↔ a ≤ ↑{ val := b, property := hb }
Theorem: YoungDiagram.mk_mem_col_iff
File: Mathlib/Combinatorics/Young/YoungDiagram.lean

tactic: simp [col]
state_before: μ : YoungDiagram
i j : ℕ
⊢ (i, j) ∈ col μ j ↔ (i, j) ∈ μ
Theorem: Multiset.toFinset_sum_count_nsmul_eq
File: Mathlib/Algebra/BigOperators/Basic.lean

tactic: rw [← Finset.sum_multiset_map_count, Multiset.sum_map_singleton]
state_before: ι : Type ?u.936659
β : Type u
α : Type v
γ : Type w
s✝ s₁ s₂ : Finset α
a : α
f g : α → β
inst✝ : DecidableEq α
s : Multiset α
⊢ ∑ a in toFinset s, count a s • {a} = s
Theorem: Ordinal.succ_log_def
File: Mathlib/SetTheory/Ordinal/Exponential.lean

tactic: let t := sInf { o | x < (b^o) }
state_before: b x : Ordinal
hb : 1 < b
hx : x ≠ 0
⊢ succ (log b x) = sInf {o | x < b ^ o}

tactic: have : x < (b^t) := csInf_mem (log_nonempty hb)
state_before: b x : Ordinal
hb : 1 < b
hx : x ≠ 0
t : Ordinal := sInf {o | x < b ^ o}
⊢ succ (log b x) = sInf {o | x < b ^ o}

tactic: rcases zero_or_succ_or_limit t with (h | h | h)
state_before: b x : Ordinal
hb : 1 < b
hx : x ≠ 0
t : Ordinal := sInf {o | x < b ^ o}
this : x < b ^ t
⊢ succ (log b x) = sInf {o | x < b ^ o}

tactic: refine' ((one_le_iff_ne_zero.2 hx).not_lt _).elim
state_before: case inl
b x : Ordinal
hb : 1 < b
hx : x ≠ 0
t : Ordinal := sInf {o | x < b ^ o}
this : x < b ^ t
h : t = 0
⊢ succ (log b x) = sInf {o | x < b ^ o}

tactic: simpa only [h, opow_zero] using this
state_before: case inl
b x : Ordinal
hb : 1 < b
hx : x ≠ 0
t : Ordinal := sInf {o | x < b ^ o}
this : x < b ^ t
h : t = 0
⊢ x < 1

tactic: rw [show log b x = pred t from log_def hb x, succ_pred_iff_is_succ.2 h]
state_before: case inr.inl
b x : Ordinal
hb : 1 < b
hx : x ≠ 0
t : Ordinal := sInf {o | x < b ^ o}
this : x < b ^ t
h : ∃ a, t = succ a
⊢ succ (log b x) = sInf {o | x < b ^ o}

tactic: rcases(lt_opow_of_limit (zero_lt_one.trans hb).ne' h).1 this with ⟨a, h₁, h₂⟩
state_before: case inr.inr
b x : Ordinal
hb : 1 < b
hx : x ≠ 0
t : Ordinal := sInf {o | x < b ^ o}
this : x < b ^ t
h : IsLimit t
⊢ succ (log b x) = sInf {o | x < b ^ o}

tactic: exact h₁.not_le.elim ((le_csInf_iff'' (log_nonempty hb)).1 le_rfl a h₂)
state_before: case inr.inr.intro.intro
b x : Ordinal
hb : 1 < b
hx : x ≠ 0
t : Ordinal := sInf {o | x < b ^ o}
this : x < b ^ t
h : IsLimit t
a : Ordinal
h₁ : a < t
h₂ : x < b ^ a
⊢ succ (log b x) = sInf {o | x < b ^ o}
Theorem: LatticeOrderedCommGroup.inf_eq_div_pos_div
File: Mathlib/Algebra/Order/LatticeGroup.lean

tactic: rw [mul_one a, div_eq_mul_inv, mul_comm b, mul_inv_cancel_left]
state_before: α : Type u
inst✝² : Lattice α
inst✝¹ : CommGroup α
inst✝ : CovariantClass α α (fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a b : α
⊢ a ⊓ b = a * 1 ⊓ a * (b / a)

tactic: rw [← mul_inf 1 (b / a) a]
state_before: α : Type u
inst✝² : Lattice α
inst✝¹ : CommGroup α
inst✝ : CovariantClass α α (fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a b : α
⊢ a * 1 ⊓ a * (b / a) = a * (1 ⊓ b / a)

tactic: rw [inf_comm]
state_before: α : Type u
inst✝² : Lattice α
inst✝¹ : CommGroup α
inst✝ : CovariantClass α α (fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a b : α
⊢ a * (1 ⊓ b / a) = a * (b / a ⊓ 1)

tactic: rw [div_eq_mul_inv]
state_before: α : Type u
inst✝² : Lattice α
inst✝¹ : CommGroup α
inst✝ : CovariantClass α α (fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a b : α
⊢ a * (b / a ⊓ 1) = a * ((a / b)⁻¹ ⊓ 1)

tactic: nth_rw 1 [← inv_inv b]
state_before: α : Type u
inst✝² : Lattice α
inst✝¹ : CommGroup α
inst✝ : CovariantClass α α (fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a b : α
⊢ a * (b * a⁻¹ ⊓ 1) = a * ((a / b)⁻¹ ⊓ 1)

tactic: rw [← mul_inv, mul_comm b⁻¹, ← div_eq_mul_inv]
state_before: α : Type u
inst✝² : Lattice α
inst✝¹ : CommGroup α
inst✝ : CovariantClass α α (fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a b : α
⊢ a * (b⁻¹⁻¹ * a⁻¹ ⊓ 1) = a * ((a / b)⁻¹ ⊓ 1)

tactic: rw [inv_one]
state_before: α : Type u
inst✝² : Lattice α
inst✝¹ : CommGroup α
inst✝ : CovariantClass α α (fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a b : α
⊢ a * ((a / b)⁻¹ ⊓ 1) = a * ((a / b)⁻¹ ⊓ 1⁻¹)

tactic: rw [← inv_sup_eq_inv_inf_inv, ← div_eq_mul_inv]
state_before: α : Type u
inst✝² : Lattice α
inst✝¹ : CommGroup α
inst✝ : CovariantClass α α (fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a b : α
⊢ a * ((a / b)⁻¹ ⊓ 1⁻¹) = a / (a / b ⊔ 1)
Theorem: SimpleGraph.set_walk_length_zero_eq_of_ne
File: Mathlib/Combinatorics/SimpleGraph/Connectivity.lean

tactic: ext p
state_before: V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
u v : V
h : u ≠ v
⊢ {p | Walk.length p = 0} = ∅

tactic: simp only [Set.mem_setOf_eq, Set.mem_empty_iff_false, iff_false_iff]
state_before: case h
V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
u v : V
h : u ≠ v
p : Walk G u v
⊢ p ∈ {p | Walk.length p = 0} ↔ p ∈ ∅

tactic: exact fun h' => absurd (Walk.eq_of_length_eq_zero h') h
state_before: case h
V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
u v : V
h : u ≠ v
p : Walk G u v
⊢ ¬Walk.length p = 0
Theorem: List.foldl_join
File: Mathlib/Data/List/Basic.lean

tactic: simp only [join, foldl_append, foldl_cons, foldl_join f (foldl f a l) L]
state_before: ι : Type ?u.231477
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α
f : α → β → α
a : α
l : List β
L : List (List β)
⊢ foldl f a (join (l :: L)) = foldl (foldl f) a (l :: L)
Theorem: finsum_smul
File: Mathlib/Algebra/BigOperators/Finprod.lean

tactic: rcases eq_or_ne x 0 with (rfl | hx)
state_before: G : Type ?u.140761
M✝ : Type ?u.140764
N : Type ?u.140767
α : Sort ?u.140770
β : Sort ?u.140773
ι : Sort u_3
inst✝⁵ : CommMonoid M✝
inst✝⁴ : CommMonoid N
R : Type u_1
M : Type u_2
inst✝³ : Ring R
inst✝² : AddCommGroup M
inst✝¹ : Module R M
inst✝ : NoZeroSMulDivisors R M
f : ι → R
x : M
⊢ (∑ᶠ (i : ι), f i) • x = ∑ᶠ (i : ι), f i • x

tactic: exact ((smulAddHom R M).flip x).map_finsum_of_injective (smul_left_injective R hx) _
state_before: case inr
G : Type ?u.140761
M✝ : Type ?u.140764
N : Type ?u.140767
α : Sort ?u.140770
β : Sort ?u.140773
ι : Sort u_3
inst✝⁵ : CommMonoid M✝
inst✝⁴ : CommMonoid N
R : Type u_1
M : Type u_2
inst✝³ : Ring R
inst✝² : AddCommGroup M
inst✝¹ : Module R M
inst✝ : NoZeroSMulDivisors R M
f : ι → R
x : M
hx : x ≠ 0
⊢ (∑ᶠ (i : ι), f i) • x = ∑ᶠ (i : ι), f i • x

tactic: simp
state_before: case inl
G : Type ?u.140761
M✝ : Type ?u.140764
N : Type ?u.140767
α : Sort ?u.140770
β : Sort ?u.140773
ι : Sort u_3
inst✝⁵ : CommMonoid M✝
inst✝⁴ : CommMonoid N
R : Type u_1
M : Type u_2
inst✝³ : Ring R
inst✝² : AddCommGroup M
inst✝¹ : Module R M
inst✝ : NoZeroSMulDivisors R M
f : ι → R
⊢ (∑ᶠ (i : ι), f i) • 0 = ∑ᶠ (i : ι), f i • 0
Theorem: Cardinal.lsub_lt_ord_of_isRegular
File: Mathlib/SetTheory/Cardinal/Cofinality.lean

tactic: rwa [hc.cof_eq]
state_before: α : Type ?u.157734
r : α → α → Prop
ι : Type (max u_1 u_2)
f : ι → Ordinal
c : Cardinal
hc : IsRegular c
hι : (#ι) < c
⊢ (#ι) < Ordinal.cof (ord c)
Theorem: Set.pi_inter_compl
File: Mathlib/Data/Set/Prod.lean

tactic: rw [← union_pi, union_compl_self]
state_before: ι : Type u_1
α : ι → Type u_2
β : ι → Type ?u.150973
s✝ s₁ s₂ : Set ι
t t₁ t₂ : (i : ι) → Set (α i)
i : ι
s : Set ι
⊢ pi s t ∩ pi (sᶜ) t = pi univ t
Theorem: toMatrix_dualTensorHom
File: Mathlib/LinearAlgebra/Contraction.lean

tactic: ext (i' j')
state_before: ι : Type w
R : Type u
M : Type v₁
N : Type v₂
P : Type v₃
Q : Type v₄
inst✝¹⁴ : CommSemiring R
inst✝¹³ : AddCommMonoid M
inst✝¹² : AddCommMonoid N
inst✝¹¹ : AddCommMonoid P
inst✝¹⁰ : AddCommMonoid Q
inst✝⁹ : Module R M
inst✝⁸ : Module R N
inst✝⁷ : Module R P
inst✝⁶ : Module R Q
inst✝⁵ : DecidableEq ι
inst✝⁴ : Fintype ι
b : Basis ι R M
m : Type u_1
n : Type u_2
inst✝³ : Fintype m
inst✝² : Fintype n
inst✝¹ : DecidableEq m
inst✝ : DecidableEq n
bM : Basis m R M
bN : Basis n R N
j : m
i : n
⊢ ↑(toMatrix bM bN) (↑(dualTensorHom R M N) (Basis.coord bM j ⊗ₜ[R] ↑bN i)) = stdBasisMatrix i j 1

tactic: by_cases hij : i = i' ∧ j = j' <;>
  simp [LinearMap.toMatrix_apply, Finsupp.single_eq_pi_single, hij]
state_before: case a.h
ι : Type w
R : Type u
M : Type v₁
N : Type v₂
P : Type v₃
Q : Type v₄
inst✝¹⁴ : CommSemiring R
inst✝¹³ : AddCommMonoid M
inst✝¹² : AddCommMonoid N
inst✝¹¹ : AddCommMonoid P
inst✝¹⁰ : AddCommMonoid Q
inst✝⁹ : Module R M
inst✝⁸ : Module R N
inst✝⁷ : Module R P
inst✝⁶ : Module R Q
inst✝⁵ : DecidableEq ι
inst✝⁴ : Fintype ι
b : Basis ι R M
m : Type u_1
n : Type u_2
inst✝³ : Fintype m
inst✝² : Fintype n
inst✝¹ : DecidableEq m
inst✝ : DecidableEq n
bM : Basis m R M
bN : Basis n R N
j : m
i i' : n
j' : m
⊢ ↑(toMatrix bM bN) (↑(dualTensorHom R M N) (Basis.coord bM j ⊗ₜ[R] ↑bN i)) i' j' = stdBasisMatrix i j 1 i' j'

tactic: rw [and_iff_not_or_not, Classical.not_not] at hij
state_before: case neg
ι : Type w
R : Type u
M : Type v₁
N : Type v₂
P : Type v₃
Q : Type v₄
inst✝¹⁴ : CommSemiring R
inst✝¹³ : AddCommMonoid M
inst✝¹² : AddCommMonoid N
inst✝¹¹ : AddCommMonoid P
inst✝¹⁰ : AddCommMonoid Q
inst✝⁹ : Module R M
inst✝⁸ : Module R N
inst✝⁷ : Module R P
inst✝⁶ : Module R Q
inst✝⁵ : DecidableEq ι
inst✝⁴ : Fintype ι
b : Basis ι R M
m : Type u_1
n : Type u_2
inst✝³ : Fintype m
inst✝² : Fintype n
inst✝¹ : DecidableEq m
inst✝ : DecidableEq n
bM : Basis m R M
bN : Basis n R N
j : m
i i' : n
j' : m
hij : ¬(i = i' ∧ j = j')
⊢ Pi.single i (Pi.single j' 1 j) i' = 0

tactic: cases' hij with hij hij <;> simp [hij]
state_before: case neg
ι : Type w
R : Type u
M : Type v₁
N : Type v₂
P : Type v₃
Q : Type v₄
inst✝¹⁴ : CommSemiring R
inst✝¹³ : AddCommMonoid M
inst✝¹² : AddCommMonoid N
inst✝¹¹ : AddCommMonoid P
inst✝¹⁰ : AddCommMonoid Q
inst✝⁹ : Module R M
inst✝⁸ : Module R N
inst✝⁷ : Module R P
inst✝⁶ : Module R Q
inst✝⁵ : DecidableEq ι
inst✝⁴ : Fintype ι
b : Basis ι R M
m : Type u_1
n : Type u_2
inst✝³ : Fintype m
inst✝² : Fintype n
inst✝¹ : DecidableEq m
inst✝ : DecidableEq n
bM : Basis m R M
bN : Basis n R N
j : m
i i' : n
j' : m
hij : ¬i = i' ∨ ¬j = j'
⊢ Pi.single i (Pi.single j' 1 j) i' = 0