tasksource/leandojo huggingface dataset:
Theorem: Fintype.card_units
File: Mathlib/Data/Fintype/Units.lean

tactic: rw [eq_comm, Nat.sub_eq_iff_eq_add (Fintype.card_pos_iff.2 ⟨(0 : α)⟩),
  Fintype.card_congr (unitsEquivNeZero α)]
state_before: α : Type u_1
inst✝² : GroupWithZero α
inst✝¹ : Fintype α
inst✝ : Fintype αˣ
⊢ card αˣ = card α - 1

tactic: rwa [Fintype.card_sum, add_comm, Fintype.card_subtype_eq] at this
state_before: α : Type u_1
inst✝² : GroupWithZero α
inst✝¹ : Fintype α
inst✝ : Fintype αˣ
this : card α = card ({ a // a = 0 } ⊕ { a // ¬a = 0 })
⊢ card α = card { a // a ≠ 0 } + Nat.succ 0
Theorem: zero_lt_mul_left
File: Mathlib/Algebra/Order/Ring/Lemmas.lean

tactic: rw [←mul_zero c, mul_lt_mul_left h]
state_before: α : Type u_1
a b c d : α
inst✝³ : MulZeroClass α
inst✝² : Preorder α
inst✝¹ : PosMulStrictMono α
inst✝ : PosMulReflectLT α
h : 0 < c
⊢ 0 < c * b ↔ 0 < b

tactic: simp
state_before: α : Type u_1
a b c d : α
inst✝³ : MulZeroClass α
inst✝² : Preorder α
inst✝¹ : PosMulStrictMono α
inst✝ : PosMulReflectLT α
h : 0 < c
⊢ 0 < b ↔ c * 0 < b
Theorem: Int.cast_div
File: Mathlib/Data/Int/Cast/Field.lean

tactic: rcases n_dvd with ⟨k, rfl⟩
state_before: α : Type u_1
inst✝ : DivisionRing α
m n : ℤ
n_dvd : n ∣ m
n_nonzero : ↑n ≠ 0
⊢ ↑(m / n) = ↑m / ↑n

tactic: have : n ≠ 0 := by
  rintro rfl
  simp at n_nonzero
state_before: case intro
α : Type u_1
inst✝ : DivisionRing α
n : ℤ
n_nonzero : ↑n ≠ 0
k : ℤ
⊢ ↑(n * k / n) = ↑(n * k) / ↑n

tactic: rw [Int.mul_ediv_cancel_left _ this, mul_comm n k, Int.cast_mul, mul_div_cancel _ n_nonzero]
state_before: case intro
α : Type u_1
inst✝ : DivisionRing α
n : ℤ
n_nonzero : ↑n ≠ 0
k : ℤ
this : n ≠ 0
⊢ ↑(n * k / n) = ↑(n * k) / ↑n

tactic: rintro rfl
state_before: α : Type u_1
inst✝ : DivisionRing α
n : ℤ
n_nonzero : ↑n ≠ 0
k : ℤ
⊢ n ≠ 0

tactic: simp at n_nonzero
state_before: α : Type u_1
inst✝ : DivisionRing α
k : ℤ
n_nonzero : ↑0 ≠ 0
⊢ False
Theorem: Stream'.Seq.ofList_append
File: Mathlib/Data/Seq/Seq.lean

tactic: induction l <;> simp [*]
state_before: α : Type u
β : Type v
γ : Type w
l l' : List α
⊢ ↑(l ++ l') = append ↑l ↑l'
Theorem: Submonoid.LocalizationMap.lift_mul_left
File: Mathlib/GroupTheory/MonoidLocalization.lean

tactic: rw [mul_comm, lift_mul_right]
state_before: M : Type u_2
inst✝² : CommMonoid M
S : Submonoid M
N : Type u_3
inst✝¹ : CommMonoid N
P : Type u_1
inst✝ : CommMonoid P
f : LocalizationMap S N
g : M →* P
hg : ∀ (y : { x // x ∈ S }), IsUnit (↑g ↑y)
z : N
⊢ ↑g ↑(sec f z).snd * ↑(lift f hg) z = ↑g (sec f z).fst
Theorem: exists_finset_piecewise_mem_of_mem_nhds
File: Mathlib/Topology/Constructions.lean

tactic: simp only [nhds_pi, Filter.mem_pi'] at hs
state_before: α : Type u
β : Type v
γ : Type ?u.340703
δ : Type ?u.340706
ε : Type ?u.340709
ζ : Type ?u.340712
ι : Type u_1
π : ι → Type u_2
κ : Type ?u.340723
inst✝² : TopologicalSpace α
inst✝¹ : (i : ι) → TopologicalSpace (π i)
f : α → (i : ι) → π i
inst✝ : DecidableEq ι
s : Set ((a : ι) → π a)
x : (a : ι) → π a
hs : s ∈ 𝓝 x
y : (a : ι) → π a
⊢ ∃ I, Finset.piecewise I x y ∈ s

tactic: rcases hs with ⟨I, t, htx, hts⟩
state_before: α : Type u
β : Type v
γ : Type ?u.340703
δ : Type ?u.340706
ε : Type ?u.340709
ζ : Type ?u.340712
ι : Type u_1
π : ι → Type u_2
κ : Type ?u.340723
inst✝² : TopologicalSpace α
inst✝¹ : (i : ι) → TopologicalSpace (π i)
f : α → (i : ι) → π i
inst✝ : DecidableEq ι
s : Set ((a : ι) → π a)
x y : (a : ι) → π a
hs : ∃ I t, (∀ (i : ι), t i ∈ 𝓝 (x i)) ∧ Set.pi (↑I) t ⊆ s
⊢ ∃ I, Finset.piecewise I x y ∈ s

tactic: refine' ⟨I, hts fun i hi => _⟩
state_before: case intro.intro.intro
α : Type u
β : Type v
γ : Type ?u.340703
δ : Type ?u.340706
ε : Type ?u.340709
ζ : Type ?u.340712
ι : Type u_1
π : ι → Type u_2
κ : Type ?u.340723
inst✝² : TopologicalSpace α
inst✝¹ : (i : ι) → TopologicalSpace (π i)
f : α → (i : ι) → π i
inst✝ : DecidableEq ι
s : Set ((a : ι) → π a)
x y : (a : ι) → π a
I : Finset ι
t : (i : ι) → Set (π i)
htx : ∀ (i : ι), t i ∈ 𝓝 (x i)
hts : Set.pi (↑I) t ⊆ s
⊢ ∃ I, Finset.piecewise I x y ∈ s

tactic: simpa [Finset.mem_coe.1 hi] using mem_of_mem_nhds (htx i)
state_before: case intro.intro.intro
α : Type u
β : Type v
γ : Type ?u.340703
δ : Type ?u.340706
ε : Type ?u.340709
ζ : Type ?u.340712
ι : Type u_1
π : ι → Type u_2
κ : Type ?u.340723
inst✝² : TopologicalSpace α
inst✝¹ : (i : ι) → TopologicalSpace (π i)
f : α → (i : ι) → π i
inst✝ : DecidableEq ι
s : Set ((a : ι) → π a)
x y : (a : ι) → π a
I : Finset ι
t : (i : ι) → Set (π i)
htx : ∀ (i : ι), t i ∈ 𝓝 (x i)
hts : Set.pi (↑I) t ⊆ s
i : ι
hi : i ∈ ↑I
⊢ Finset.piecewise I x y i ∈ t i
Theorem: MeasureTheory.Measure.singularPart_zero
File: Mathlib/MeasureTheory/Decomposition/Lebesgue.lean

tactic: refine' (eq_singularPart measurable_zero MutuallySingular.zero_left _).symm
state_before: α : Type u_1
β : Type ?u.43416
m : MeasurableSpace α
μ ν✝ ν : Measure α
⊢ singularPart 0 ν = 0

tactic: rw [zero_add, withDensity_zero]
state_before: α : Type u_1
β : Type ?u.43416
m : MeasurableSpace α
μ ν✝ ν : Measure α
⊢ 0 = 0 + withDensity ν 0
Theorem: Set.mulIndicator_compl_mul_self_apply
File: Mathlib/Algebra/IndicatorFunction.lean

tactic: simp [ha]
state_before: α : Type u_1
β : Type ?u.58114
ι : Type ?u.58117
M : Type u_2
N : Type ?u.58123
inst✝ : MulOneClass M
s✝ t : Set α
f✝ g : α → M
a✝ : α
s : Set α
f : α → M
a : α
ha : a ∈ s
⊢ mulIndicator (sᶜ) f a * mulIndicator s f a = f a

tactic: simp [ha]
state_before: α : Type u_1
β : Type ?u.58114
ι : Type ?u.58117
M : Type u_2
N : Type ?u.58123
inst✝ : MulOneClass M
s✝ t : Set α
f✝ g : α → M
a✝ : α
s : Set α
f : α → M
a : α
ha : ¬a ∈ s
⊢ mulIndicator (sᶜ) f a * mulIndicator s f a = f a
Theorem: Polynomial.of_mem_support_derivative
File: Mathlib/Data/Polynomial/Derivative.lean

tactic: rw [coeff_derivative, h1, zero_mul]
state_before: R : Type u
S : Type v
T : Type w
ι : Type y
A : Type z
a b : R
n✝ : ℕ
inst✝ : Semiring R
p : R[X]
n : ℕ
h : n ∈ support (↑derivative p)
h1 : coeff p (n + 1) = 0
⊢ coeff (↑derivative p) n = 0
Theorem: Set.Icc_union_Ici'
File: Mathlib/Data/Set/Intervals/Basic.lean

tactic: ext1 x
state_before: α : Type u_1
β : Type ?u.91582
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
h₁ : c ≤ b
⊢ Icc a b ∪ Ici c = Ici (min a c)

tactic: simp_rw [mem_union, mem_Icc, mem_Ici, min_le_iff]
state_before: case h
α : Type u_1
β : Type ?u.91582
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
h₁ : c ≤ b
x : α
⊢ x ∈ Icc a b ∪ Ici c ↔ x ∈ Ici (min a c)

tactic: by_cases hc : c ≤ x
state_before: case h
α : Type u_1
β : Type ?u.91582
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
h₁ : c ≤ b
x : α
⊢ a ≤ x ∧ x ≤ b ∨ c ≤ x ↔ a ≤ x ∨ c ≤ x

tactic: simp only [hc, or_true]
state_before: case pos
α : Type u_1
β : Type ?u.91582
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
h₁ : c ≤ b
x : α
hc : c ≤ x
⊢ a ≤ x ∧ x ≤ b ∨ c ≤ x ↔ a ≤ x ∨ c ≤ x

tactic: have hxb : x ≤ b := (le_of_not_ge hc).trans h₁
state_before: case neg
α : Type u_1
β : Type ?u.91582
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
h₁ : c ≤ b
x : α
hc : ¬c ≤ x
⊢ a ≤ x ∧ x ≤ b ∨ c ≤ x ↔ a ≤ x ∨ c ≤ x

tactic: simp only [hxb, and_true]
state_before: case neg
α : Type u_1
β : Type ?u.91582
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
h₁ : c ≤ b
x : α
hc : ¬c ≤ x
hxb : x ≤ b
⊢ a ≤ x ∧ x ≤ b ∨ c ≤ x ↔ a ≤ x ∨ c ≤ x
Theorem: CategoryTheory.Quotient.lift_spec
File: Mathlib/CategoryTheory/Quotient.lean

tactic: apply Functor.ext
state_before: C : Type u_1
inst✝¹ : Category C
r : HomRel C
D : Type u_3
inst✝ : Category D
F : C ⥤ D
H : ∀ (x y : C) (f₁ f₂ : x ⟶ y), r f₁ f₂ → F.map f₁ = F.map f₂
⊢ functor r ⋙ lift r F H = F

tactic: rotate_left
state_before: case h_map
C : Type u_1
inst✝¹ : Category C
r : HomRel C
D : Type u_3
inst✝ : Category D
F : C ⥤ D
H : ∀ (x y : C) (f₁ f₂ : x ⟶ y), r f₁ f₂ → F.map f₁ = F.map f₂
⊢ autoParam
    (∀ (X Y : C) (f : X ⟶ Y),
      (functor r ⋙ lift r F H).map f =
        eqToHom (_ : ?F.obj X = ?G.obj X) ≫ F.map f ≫ eqToHom (_ : F.obj Y = (functor r ⋙ lift r F H).obj Y))
    _auto✝

case h_obj
C : Type u_1
inst✝¹ : Category C
r : HomRel C
D : Type u_3
inst✝ : Category D
F : C ⥤ D
H : ∀ (x y : C) (f₁ f₂ : x ⟶ y), r f₁ f₂ → F.map f₁ = F.map f₂
⊢ ∀ (X : C), (functor r ⋙ lift r F H).obj X = F.obj X

tactic: rintro X
state_before: case h_obj
C : Type u_1
inst✝¹ : Category C
r : HomRel C
D : Type u_3
inst✝ : Category D
F : C ⥤ D
H : ∀ (x y : C) (f₁ f₂ : x ⟶ y), r f₁ f₂ → F.map f₁ = F.map f₂
⊢ ∀ (X : C), (functor r ⋙ lift r F H).obj X = F.obj X

tactic: rfl
state_before: case h_obj
C : Type u_1
inst✝¹ : Category C
r : HomRel C
D : Type u_3
inst✝ : Category D
F : C ⥤ D
H : ∀ (x y : C) (f₁ f₂ : x ⟶ y), r f₁ f₂ → F.map f₁ = F.map f₂
X : C
⊢ (functor r ⋙ lift r F H).obj X = F.obj X

tactic: rintro X Y f
state_before: case h_map
C : Type u_1
inst✝¹ : Category C
r : HomRel C
D : Type u_3
inst✝ : Category D
F : C ⥤ D
H : ∀ (x y : C) (f₁ f₂ : x ⟶ y), r f₁ f₂ → F.map f₁ = F.map f₂
⊢ autoParam
    (∀ (X Y : C) (f : X ⟶ Y),
      (functor r ⋙ lift r F H).map f =
        eqToHom (_ : (functor r ⋙ lift r F H).obj X = (functor r ⋙ lift r F H).obj X) ≫
          F.map f ≫ eqToHom (_ : F.obj Y = (functor r ⋙ lift r F H).obj Y))
    _auto✝

tactic: simp
state_before: case h_map
C : Type u_1
inst✝¹ : Category C
r : HomRel C
D : Type u_3
inst✝ : Category D
F : C ⥤ D
H : ∀ (x y : C) (f₁ f₂ : x ⟶ y), r f₁ f₂ → F.map f₁ = F.map f₂
X Y : C
f : X ⟶ Y
⊢ (functor r ⋙ lift r F H).map f =
    eqToHom (_ : (functor r ⋙ lift r F H).obj X = (functor r ⋙ lift r F H).obj X) ≫
      F.map f ≫ eqToHom (_ : F.obj Y = (functor r ⋙ lift r F H).obj Y)
Theorem: LinearMap.rank_zero
File: Mathlib/LinearAlgebra/Dimension.lean

tactic: rw [rank, LinearMap.range_zero, rank_bot]
state_before: K : Type u
V V₁ V₂ V₃ : Type v
V' V'₁ : Type v'
V'' : Type v''
ι : Type w
ι' : Type w'
η : Type u₁'
φ : η → Type ?u.1100037
inst✝⁷ : Ring K
inst✝⁶ : AddCommGroup V
inst✝⁵ : Module K V
inst✝⁴ : AddCommGroup V₁
inst✝³ : Module K V₁
inst✝² : AddCommGroup V'
inst✝¹ : Module K V'
inst✝ : Nontrivial K
⊢ rank 0 = 0
Theorem: MvPolynomial.funext_iff
File: Mathlib/Data/MvPolynomial/Funext.lean

tactic: rintro rfl
state_before: R : Type u_2
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : Infinite R
σ : Type u_1
p q : MvPolynomial σ R
⊢ p = q → ∀ (x : σ → R), ↑(eval x) p = ↑(eval x) q

tactic: simp only [forall_const, eq_self_iff_true]
state_before: R : Type u_2
inst✝² : CommRing R
inst✝¹ : IsDomain R
inst✝ : Infinite R
σ : Type u_1
p : MvPolynomial σ R
⊢ ∀ (x : σ → R), ↑(eval x) p = ↑(eval x) p
Theorem: Complex.cos_two_mul
File: Mathlib/Data/Complex/Exponential.lean

tactic: rw [cos_two_mul', eq_sub_iff_add_eq.2 (sin_sq_add_cos_sq x), ← sub_add, sub_add_eq_add_sub,
  two_mul]
state_before: x y : ℂ
⊢ cos (2 * x) = 2 * cos x ^ 2 - 1
Theorem: dist_vadd_cancel_right
File: Mathlib/Analysis/Normed/Group/AddTorsor.lean

tactic: rw [dist_eq_norm_vsub V, dist_eq_norm, vadd_vsub_vadd_cancel_right]
state_before: α : Type ?u.8057
V : Type u_2
P : Type u_1
W : Type ?u.8066
Q : Type ?u.8069
inst✝⁵ : SeminormedAddCommGroup V
inst✝⁴ : PseudoMetricSpace P
inst✝³ : NormedAddTorsor V P
inst✝² : NormedAddCommGroup W
inst✝¹ : MetricSpace Q
inst✝ : NormedAddTorsor W Q
v₁ v₂ : V
x : P
⊢ dist (v₁ +ᵥ x) (v₂ +ᵥ x) = dist v₁ v₂
Theorem: CategoryTheory.MonoidalCategory.id_tensor_associator_naturality
File: Mathlib/CategoryTheory/Monoidal/Category.lean

tactic: rw [← tensor_id, associator_naturality]
state_before: C✝ : Type u
𝒞 : Category C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z✝ X Y Z Z' : C
h : Z ⟶ Z'
⊢ (𝟙 (X ⊗ Y) ⊗ h) ≫ (α_ X Y Z').hom = (α_ X Y Z).hom ≫ (𝟙 X ⊗ 𝟙 Y ⊗ h)
Theorem: Set.indicator_eq_zero_iff_not_mem
File: Mathlib/Algebra/IndicatorFunction.lean

tactic: classical simp [indicator_apply, imp_false]
state_before: α : Type u_1
β : Type ?u.142655
ι : Type ?u.142658
M : Type u_2
N : Type ?u.142664
inst✝¹ : MulZeroOneClass M
inst✝ : Nontrivial M
U : Set α
x : α
⊢ indicator U 1 x = 0 ↔ ¬x ∈ U

tactic: simp [indicator_apply, imp_false]
state_before: α : Type u_1
β : Type ?u.142655
ι : Type ?u.142658
M : Type u_2
N : Type ?u.142664
inst✝¹ : MulZeroOneClass M
inst✝ : Nontrivial M
U : Set α
x : α
⊢ indicator U 1 x = 0 ↔ ¬x ∈ U
Theorem: ContinuousMap.dist_apply_le_dist
File: Mathlib/Topology/ContinuousFunction/Compact.lean

tactic: simp only [← dist_mkOfCompact, dist_coe_le_dist, ← mkOfCompact_apply]
state_before: α : Type u_2
β : Type u_1
E : Type ?u.70790
inst✝³ : TopologicalSpace α
inst✝² : CompactSpace α
inst✝¹ : MetricSpace β
inst✝ : NormedAddCommGroup E
f g : C(α, β)
C : ℝ
x : α
⊢ dist (↑f x) (↑g x) ≤ dist f g
Theorem: CircleDeg1Lift.tendsto_translation_number₀'
File: Mathlib/Dynamics/Circle/RotationNumber/TranslationNumber.lean

tactic: refine'
  tendsto_iff_dist_tendsto_zero.2 <|
    squeeze_zero (fun _ => dist_nonneg) (fun n => _)
      ((tendsto_const_div_atTop_nhds_0_nat 1).comp (tendsto_add_atTop_nat 1))
state_before: f g : CircleDeg1Lift
⊢ Tendsto (fun n => ↑(f ^ (n + 1)) 0 / (↑n + 1)) atTop (𝓝 (τ f))

tactic: dsimp
state_before: f g : CircleDeg1Lift
n : ℕ
⊢ dist (↑(f ^ (n + 1)) 0 / (↑n + 1)) (τ f) ≤ ((fun n => 1 / ↑n) ∘ fun a => a + 1) n

tactic: have : (0 : ℝ) < n + 1 := n.cast_add_one_pos
state_before: f g : CircleDeg1Lift
n : ℕ
⊢ dist (↑(f ^ (n + 1)) 0 / (↑n + 1)) (τ f) ≤ 1 / ↑(n + 1)

tactic: rw [Real.dist_eq, div_sub' _ _ _ (ne_of_gt this), abs_div, ← Real.dist_eq, abs_of_pos this,
  Nat.cast_add_one, div_le_div_right this, ← Nat.cast_add_one]
state_before: f g : CircleDeg1Lift
n : ℕ
this : 0 < ↑n + 1
⊢ dist (↑(f ^ (n + 1)) 0 / (↑n + 1)) (τ f) ≤ 1 / ↑(n + 1)

tactic: apply dist_pow_map_zero_mul_translationNumber_le
state_before: f g : CircleDeg1Lift
n : ℕ
this : 0 < ↑n + 1
⊢ dist (↑(f ^ (n + 1)) 0) (↑(n + 1) * τ f) ≤ 1
Theorem: LieSubmodule.ucs_le_of_normalizer_eq_self
File: Mathlib/Algebra/Lie/Nilpotent.lean

tactic: rw [← ucs_eq_self_of_normalizer_eq_self h k]
state_before: R : Type u
L : Type v
M : Type w
inst✝⁶ : CommRing R
inst✝⁵ : LieRing L
inst✝⁴ : LieAlgebra R L
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : LieRingModule L M
inst✝ : LieModule R L M
k✝ : ℕ
N N₁ N₂ : LieSubmodule R L M
h : normalizer N₁ = N₁
k : ℕ
⊢ ucs k ⊥ ≤ N₁

tactic: mono
state_before: R : Type u
L : Type v
M : Type w
inst✝⁶ : CommRing R
inst✝⁵ : LieRing L
inst✝⁴ : LieAlgebra R L
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : LieRingModule L M
inst✝ : LieModule R L M
k✝ : ℕ
N N₁ N₂ : LieSubmodule R L M
h : normalizer N₁ = N₁
k : ℕ
⊢ ucs k ⊥ ≤ ucs k N₁

tactic: simp
state_before: case h
R : Type u
L : Type v
M : Type w
inst✝⁶ : CommRing R
inst✝⁵ : LieRing L
inst✝⁴ : LieAlgebra R L
inst✝³ : AddCommGroup M
inst✝² : Module R M
inst✝¹ : LieRingModule L M
inst✝ : LieModule R L M
k✝ : ℕ
N N₁ N₂ : LieSubmodule R L M
h : normalizer N₁ = N₁
k : ℕ
h_symm : N₁ = normalizer N₁
⊢ ⊥ ≤ N₁
Theorem: charmatrix_reindex
File: Mathlib/LinearAlgebra/Matrix/Charpoly/Basic.lean

tactic: ext (i j x)
state_before: R : Type u
inst✝⁴ : CommRing R
n : Type w
inst✝³ : DecidableEq n
inst✝² : Fintype n
m : Type v
inst✝¹ : DecidableEq m
inst✝ : Fintype m
e : n ≃ m
M : Matrix n n R
⊢ charmatrix (↑(reindex e e) M) = ↑(reindex e e) (charmatrix M)

tactic: by_cases h : i = j
state_before: case a.h.a
R : Type u
inst✝⁴ : CommRing R
n : Type w
inst✝³ : DecidableEq n
inst✝² : Fintype n
m : Type v
inst✝¹ : DecidableEq m
inst✝ : Fintype m
e : n ≃ m
M : Matrix n n R
i j : m
x : ℕ
⊢ coeff (charmatrix (↑(reindex e e) M) i j) x = coeff (↑(reindex e e) (charmatrix M) i j) x

tactic: all_goals simp [h]
state_before: case pos
R : Type u
inst✝⁴ : CommRing R
n : Type w
inst✝³ : DecidableEq n
inst✝² : Fintype n
m : Type v
inst✝¹ : DecidableEq m
inst✝ : Fintype m
e : n ≃ m
M : Matrix n n R
i j : m
x : ℕ
h : i = j
⊢ coeff (charmatrix (↑(reindex e e) M) i j) x = coeff (↑(reindex e e) (charmatrix M) i j) x

case neg
R : Type u
inst✝⁴ : CommRing R
n : Type w
inst✝³ : DecidableEq n
inst✝² : Fintype n
m : Type v
inst✝¹ : DecidableEq m
inst✝ : Fintype m
e : n ≃ m
M : Matrix n n R
i j : m
x : ℕ
h : ¬i = j
⊢ coeff (charmatrix (↑(reindex e e) M) i j) x = coeff (↑(reindex e e) (charmatrix M) i j) x

tactic: simp [h]
state_before: case neg
R : Type u
inst✝⁴ : CommRing R
n : Type w
inst✝³ : DecidableEq n
inst✝² : Fintype n
m : Type v
inst✝¹ : DecidableEq m
inst✝ : Fintype m
e : n ≃ m
M : Matrix n n R
i j : m
x : ℕ
h : ¬i = j
⊢ coeff (charmatrix (↑(reindex e e) M) i j) x = coeff (↑(reindex e e) (charmatrix M) i j) x
Theorem: Ordering.ite_eq_gt_distrib
File: Mathlib/Init/Data/Ordering/Lemmas.lean

tactic: by_cases c <;> simp [*]
state_before: c : Prop
inst✝ : Decidable c
a b : Ordering
⊢ ((if c then a else b) = gt) = if c then a = gt else b = gt
Theorem: tendsto_one_plus_div_rpow_exp
File: Mathlib/Analysis/SpecialFunctions/Pow/Deriv.lean

tactic: apply ((Real.continuous_exp.tendsto _).comp (tendsto_mul_log_one_plus_div_atTop t)).congr' _
state_before: t : ℝ
⊢ Tendsto (fun x => (1 + t / x) ^ x) atTop (𝓝 (exp t))

tactic: have h₁ : (1 : ℝ) / 2 < 1 := by linarith
state_before: t : ℝ
⊢ (exp ∘ fun x => x * log (1 + t / x)) =ᶠ[atTop] fun x => (1 + t / x) ^ x

tactic: have h₂ : Tendsto (fun x : ℝ => 1 + t / x) atTop (𝓝 1) := by
  simpa using (tendsto_inv_atTop_zero.const_mul t).const_add 1
state_before: t : ℝ
h₁ : 1 / 2 < 1
⊢ (exp ∘ fun x => x * log (1 + t / x)) =ᶠ[atTop] fun x => (1 + t / x) ^ x

tactic: refine' (eventually_ge_of_tendsto_gt h₁ h₂).mono fun x hx => _
state_before: t : ℝ
h₁ : 1 / 2 < 1
h₂ : Tendsto (fun x => 1 + t / x) atTop (𝓝 1)
⊢ (exp ∘ fun x => x * log (1 + t / x)) =ᶠ[atTop] fun x => (1 + t / x) ^ x

tactic: have hx' : 0 < 1 + t / x := by linarith
state_before: t : ℝ
h₁ : 1 / 2 < 1
h₂ : Tendsto (fun x => 1 + t / x) atTop (𝓝 1)
x : ℝ
hx : 1 / 2 ≤ 1 + t / x
⊢ (exp ∘ fun x => x * log (1 + t / x)) x = (fun x => (1 + t / x) ^ x) x

tactic: simp [mul_comm x, exp_mul, exp_log hx']
state_before: t : ℝ
h₁ : 1 / 2 < 1
h₂ : Tendsto (fun x => 1 + t / x) atTop (𝓝 1)
x : ℝ
hx : 1 / 2 ≤ 1 + t / x
hx' : 0 < 1 + t / x
⊢ (exp ∘ fun x => x * log (1 + t / x)) x = (fun x => (1 + t / x) ^ x) x

tactic: linarith
state_before: t : ℝ
⊢ 1 / 2 < 1

tactic: simpa using (tendsto_inv_atTop_zero.const_mul t).const_add 1
state_before: t : ℝ
h₁ : 1 / 2 < 1
⊢ Tendsto (fun x => 1 + t / x) atTop (𝓝 1)

tactic: linarith
state_before: t : ℝ
h₁ : 1 / 2 < 1
h₂ : Tendsto (fun x => 1 + t / x) atTop (𝓝 1)
x : ℝ
hx : 1 / 2 ≤ 1 + t / x
⊢ 0 < 1 + t / x
Theorem: Int.subNatNat_add_left
File: Std/Data/Int/Lemmas.lean

tactic: unfold subNatNat
state_before: m n : Nat
⊢ subNatNat (m + n) m = ↑n

tactic: rw [Nat.sub_eq_zero_of_le (Nat.le_add_right ..), Nat.add_sub_cancel_left, ofNat_eq_coe]
state_before: m n : Nat
⊢ (match m - (m + n) with
    | 0 => ofNat (m + n - m)
    | succ k => -[k+1]) =
    ↑n
Theorem: LieAlgebra.ad_ker_eq_bot_of_semisimple
File: Mathlib/Algebra/Lie/Semisimple.lean

tactic: simp
state_before: R : Type u
L : Type v
inst✝³ : CommRing R
inst✝² : LieRing L
inst✝¹ : LieAlgebra R L
inst✝ : IsSemisimple R L
⊢ LieHom.ker (ad R L) = ⊥
Theorem: constant_of_derivWithin_zero
File: Mathlib/Analysis/Calculus/MeanValue.lean

tactic: have H : ∀ x ∈ Ico a b, ‖derivWithin f (Icc a b) x‖ ≤ 0 := by
  simpa only [norm_le_zero_iff] using fun x hx => hderiv x hx
state_before: E : Type u_1
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace ℝ E
F : Type ?u.49446
inst✝¹ : NormedAddCommGroup F
inst✝ : NormedSpace ℝ F
f : ℝ → E
a b : ℝ
hdiff : DifferentiableOn ℝ f (Icc a b)
hderiv : ∀ (x : ℝ), x ∈ Ico a b → derivWithin f (Icc a b) x = 0
⊢ ∀ (x : ℝ), x ∈ Icc a b → f x = f a

tactic: simpa only [zero_mul, norm_le_zero_iff, sub_eq_zero] using fun x hx =>
  norm_image_sub_le_of_norm_deriv_le_segment hdiff H x hx
state_before: E : Type u_1
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace ℝ E
F : Type ?u.49446
inst✝¹ : NormedAddCommGroup F
inst✝ : NormedSpace ℝ F
f : ℝ → E
a b : ℝ
hdiff : DifferentiableOn ℝ f (Icc a b)
hderiv : ∀ (x : ℝ), x ∈ Ico a b → derivWithin f (Icc a b) x = 0
H : ∀ (x : ℝ), x ∈ Ico a b → ‖derivWithin f (Icc a b) x‖ ≤ 0
⊢ ∀ (x : ℝ), x ∈ Icc a b → f x = f a

tactic: simpa only [norm_le_zero_iff] using fun x hx => hderiv x hx
state_before: E : Type u_1
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace ℝ E
F : Type ?u.49446
inst✝¹ : NormedAddCommGroup F
inst✝ : NormedSpace ℝ F
f : ℝ → E
a b : ℝ
hdiff : DifferentiableOn ℝ f (Icc a b)
hderiv : ∀ (x : ℝ), x ∈ Ico a b → derivWithin f (Icc a b) x = 0
⊢ ∀ (x : ℝ), x ∈ Ico a b → ‖derivWithin f (Icc a b) x‖ ≤ 0
Theorem: Matrix.sub_mulVec
File: Mathlib/Data/Matrix/Basic.lean

tactic: simp [sub_eq_add_neg, add_mulVec, neg_mulVec]
state_before: l : Type ?u.910087
m : Type u_2
n : Type u_1
o : Type ?u.910096
m' : o → Type ?u.910101
n' : o → Type ?u.910106
R : Type ?u.910109
S : Type ?u.910112
α : Type v
β : Type w
γ : Type ?u.910119
inst✝¹ : NonUnitalNonAssocRing α
inst✝ : Fintype n
A B : Matrix m n α
x : n → α
⊢ mulVec (A - B) x = mulVec A x - mulVec B x
Theorem: upperClosure_prod
File: Mathlib/Order/UpperLower/Basic.lean

tactic: ext
state_before: α : Type u_1
β : Type u_2
γ : Type ?u.191238
ι : Sort ?u.191241
κ : ι → Sort ?u.191246
inst✝¹ : Preorder α
inst✝ : Preorder β
s : Set α
t : Set β
⊢ upperClosure (s ×ˢ t) = upperClosure s ×ˢ upperClosure t

tactic: simp [Prod.le_def, @and_and_and_comm _ (_ ∈ t)]
state_before: case a.h
α : Type u_1
β : Type u_2
γ : Type ?u.191238
ι : Sort ?u.191241
κ : ι → Sort ?u.191246
inst✝¹ : Preorder α
inst✝ : Preorder β
s : Set α
t : Set β
x✝ : α × β
⊢ x✝ ∈ ↑(upperClosure (s ×ˢ t)) ↔ x✝ ∈ ↑(upperClosure s ×ˢ upperClosure t)
Theorem: Stream'.WSeq.mem_think
File: Mathlib/Data/Seq/WSeq.lean

tactic: cases' s with f al
state_before: α : Type u
β : Type v
γ : Type w
s : WSeq α
a : α
⊢ a ∈ think s ↔ a ∈ s

tactic: change (some (some a) ∈ some none::f) ↔ some (some a) ∈ f
state_before: case mk
α : Type u
β : Type v
γ : Type w
a : α
f : Stream' (Option (Option α))
al : IsSeq f
⊢ a ∈ think { val := f, property := al } ↔ a ∈ { val := f, property := al }

tactic: constructor <;> intro h
state_before: case mk
α : Type u
β : Type v
γ : Type w
a : α
f : Stream' (Option (Option α))
al : IsSeq f
⊢ some (some a) ∈ some none :: f ↔ some (some a) ∈ f

tactic: apply (Stream'.eq_or_mem_of_mem_cons h).resolve_left
state_before: case mk.mp
α : Type u
β : Type v
γ : Type w
a : α
f : Stream' (Option (Option α))
al : IsSeq f
h : some (some a) ∈ some none :: f
⊢ some (some a) ∈ f

tactic: intro
state_before: case mk.mp
α : Type u
β : Type v
γ : Type w
a : α
f : Stream' (Option (Option α))
al : IsSeq f
h : some (some a) ∈ some none :: f
⊢ ¬some (some a) = some none

tactic: injections
state_before: case mk.mp
α : Type u
β : Type v
γ : Type w
a : α
f : Stream' (Option (Option α))
al : IsSeq f
h : some (some a) ∈ some none :: f
a✝ : some (some a) = some none
⊢ False

tactic: apply Stream'.mem_cons_of_mem _ h
state_before: case mk.mpr
α : Type u
β : Type v
γ : Type w
a : α
f : Stream' (Option (Option α))
al : IsSeq f
h : some (some a) ∈ f
⊢ some (some a) ∈ some none :: f
Theorem: IntermediateField.coe_sum
File: Mathlib/FieldTheory/IntermediateField.lean

tactic: induction' (Finset.univ : Finset ι) using Finset.induction_on with i s hi H
state_before: K : Type u_3
L : Type u_2
L' : Type ?u.104812
inst✝⁵ : Field K
inst✝⁴ : Field L
inst✝³ : Field L'
inst✝² : Algebra K L
inst✝¹ : Algebra K L'
S : IntermediateField K L
ι : Type u_1
inst✝ : Fintype ι
f : ι → { x // x ∈ S }
⊢ ↑(∑ i : ι, f i) = ∑ i : ι, ↑(f i)

tactic: simp
state_before: case empty
K : Type u_3
L : Type u_2
L' : Type ?u.104812
inst✝⁵ : Field K
inst✝⁴ : Field L
inst✝³ : Field L'
inst✝² : Algebra K L
inst✝¹ : Algebra K L'
S : IntermediateField K L
ι : Type u_1
inst✝ : Fintype ι
f : ι → { x // x ∈ S }
⊢ ↑(∑ i in ∅, f i) = ∑ i in ∅, ↑(f i)

tactic: rw [Finset.sum_insert hi, AddMemClass.coe_add, H, Finset.sum_insert hi]
state_before: case insert
K : Type u_3
L : Type u_2
L' : Type ?u.104812
inst✝⁵ : Field K
inst✝⁴ : Field L
inst✝³ : Field L'
inst✝² : Algebra K L
inst✝¹ : Algebra K L'
S : IntermediateField K L
ι : Type u_1
inst✝ : Fintype ι
f : ι → { x // x ∈ S }
i : ι
s : Finset ι
hi : ¬i ∈ s
H : ↑(∑ i in s, f i) = ∑ i in s, ↑(f i)
⊢ ↑(∑ i in insert i s, f i) = ∑ i in insert i s, ↑(f i)