tasksource/leandojo huggingface dataset:
Theorem: Nat.prod_factorial_dvd_factorial_sum
File: Mathlib/Data/Nat/Factorial/BigOperators.lean

tactic: induction' s using Finset.induction with a' s' has ih
state_before: α : Type u_1
s : Finset α
f : α → ℕ
⊢ ∏ i in s, (f i)! ∣ (∑ i in s, f i)!

tactic: simp only [Finset.sum_empty, Finset.prod_empty, factorial]
state_before: case empty
α : Type u_1
s : Finset α
f : α → ℕ
⊢ ∏ i in ∅, (f i)! ∣ (∑ i in ∅, f i)!

tactic: simp only [Finset.prod_insert has, Finset.sum_insert has]
state_before: case insert
α : Type u_1
s : Finset α
f : α → ℕ
a' : α
s' : Finset α
has : ¬a' ∈ s'
ih : ∏ i in s', (f i)! ∣ (∑ i in s', f i)!
⊢ ∏ i in insert a' s', (f i)! ∣ (∑ i in insert a' s', f i)!

tactic: refine' dvd_trans (mul_dvd_mul_left (f a')! ih) _
state_before: case insert
α : Type u_1
s : Finset α
f : α → ℕ
a' : α
s' : Finset α
has : ¬a' ∈ s'
ih : ∏ i in s', (f i)! ∣ (∑ i in s', f i)!
⊢ (f a')! * ∏ i in s', (f i)! ∣ (f a' + ∑ i in s', f i)!

tactic: apply Nat.factorial_mul_factorial_dvd_factorial_add
state_before: case insert
α : Type u_1
s : Finset α
f : α → ℕ
a' : α
s' : Finset α
has : ¬a' ∈ s'
ih : ∏ i in s', (f i)! ∣ (∑ i in s', f i)!
⊢ (f a')! * (∑ i in s', f i)! ∣ (f a' + ∑ i in s', f i)!
Theorem: List.indexOf_get?
File: Mathlib/Data/List/Basic.lean

tactic: rw [nthLe_get?, indexOf_nthLe (indexOf_lt_length.2 h)]
state_before: ι : Type ?u.93582
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α
inst✝ : DecidableEq α
a : α
l : List α
h : a ∈ l
⊢ get? l (indexOf a l) = some a
Theorem: MonoidHom.isOfFinOrder
File: Mathlib/GroupTheory/OrderOfElement.lean

tactic: rcases(isOfFinOrder_iff_pow_eq_one _).mp h with ⟨n, npos, hn⟩
state_before: G : Type u
A : Type v
x✝ y : G
a b : A
n m : ℕ
inst✝² : Monoid G
inst✝¹ : AddMonoid A
H : Type v
inst✝ : Monoid H
f : G →* H
x : G
h : IsOfFinOrder x
⊢ ∃ n, 0 < n ∧ ↑f x ^ n = 1

tactic: exact ⟨n, npos, by rw [← f.map_pow, hn, f.map_one]⟩
state_before: case intro.intro
G : Type u
A : Type v
x✝ y : G
a b : A
n✝ m : ℕ
inst✝² : Monoid G
inst✝¹ : AddMonoid A
H : Type v
inst✝ : Monoid H
f : G →* H
x : G
h : IsOfFinOrder x
n : ℕ
npos : 0 < n
hn : x ^ n = 1
⊢ ∃ n, 0 < n ∧ ↑f x ^ n = 1

tactic: rw [← f.map_pow, hn, f.map_one]
state_before: G : Type u
A : Type v
x✝ y : G
a b : A
n✝ m : ℕ
inst✝² : Monoid G
inst✝¹ : AddMonoid A
H : Type v
inst✝ : Monoid H
f : G →* H
x : G
h : IsOfFinOrder x
n : ℕ
npos : 0 < n
hn : x ^ n = 1
⊢ ↑f x ^ n = 1
Theorem: Set.image_preimage_eq_inter_range
File: Mathlib/Data/Set/Image.lean

tactic: rw [preimage, mem_setOf, h_eq]
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.73849
ι : Sort ?u.73852
ι' : Sort ?u.73855
f✝ : ι → α
s t✝ : Set α
f : α → β
t : Set β
x : β
x✝ : x ∈ t ∩ range f
hx : x ∈ t
y : α
h_eq : f y = x
⊢ y ∈ f ⁻¹' t

tactic: exact hx
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.73849
ι : Sort ?u.73852
ι' : Sort ?u.73855
f✝ : ι → α
s t✝ : Set α
f : α → β
t : Set β
x : β
x✝ : x ∈ t ∩ range f
hx : x ∈ t
y : α
h_eq : f y = x
⊢ x ∈ t
Theorem: mem_ball_symmetry
File: Mathlib/Topology/UniformSpace/Basic.lean

tactic: unfold SymmetricRel at hV
state_before: α : Type ua
β : Type ub
γ : Type uc
δ : Type ud
ι : Sort ?u.55006
inst✝ : UniformSpace α
V : Set (β × β)
hV : SymmetricRel V
x y : β
⊢ (x, y) ∈ Prod.swap ⁻¹' V ↔ (x, y) ∈ V

tactic: rw [hV]
state_before: α : Type ua
β : Type ub
γ : Type uc
δ : Type ud
ι : Sort ?u.55006
inst✝ : UniformSpace α
V : Set (β × β)
hV : Prod.swap ⁻¹' V = V
x y : β
⊢ (x, y) ∈ Prod.swap ⁻¹' V ↔ (x, y) ∈ V
Theorem: Finset.mem_sup
File: Mathlib/Data/Finset/Lattice.lean

tactic: change _ ↔ ∃ v ∈ s, x ∈ (f v).val
state_before: F : Type ?u.415321
α✝ : Type ?u.415324
β✝ : Type ?u.415327
γ : Type ?u.415330
ι : Type ?u.415333
κ : Type ?u.415336
α : Type u_1
β : Type u_2
inst✝ : DecidableEq β
s : Finset α
f : α → Finset β
x : β
⊢ x ∈ sup s f ↔ ∃ v, v ∈ s ∧ x ∈ f v

tactic: rw [← Multiset.mem_sup, ← Multiset.mem_toFinset, sup_toFinset]
state_before: F : Type ?u.415321
α✝ : Type ?u.415324
β✝ : Type ?u.415327
γ : Type ?u.415330
ι : Type ?u.415333
κ : Type ?u.415336
α : Type u_1
β : Type u_2
inst✝ : DecidableEq β
s : Finset α
f : α → Finset β
x : β
⊢ x ∈ sup s f ↔ ∃ v, v ∈ s ∧ x ∈ (f v).val

tactic: simp_rw [val_toFinset]
state_before: F : Type ?u.415321
α✝ : Type ?u.415324
β✝ : Type ?u.415327
γ : Type ?u.415330
ι : Type ?u.415333
κ : Type ?u.415336
α : Type u_1
β : Type u_2
inst✝ : DecidableEq β
s : Finset α
f : α → Finset β
x : β
⊢ x ∈ sup s f ↔ x ∈ sup s fun x => Multiset.toFinset (f x).val
Theorem: Function.iterate_succ'
File: Mathlib/Logic/Function/Iterate.lean

tactic: rw [iterate_succ, (Commute.self_iterate f n).comp_eq]
state_before: α : Type u
β : Type v
f : α → α
n : ℕ
⊢ f^[Nat.succ n] = f ∘ f^[n]
Theorem: List.foldr_map
File: Std/Data/List/Lemmas.lean

tactic: induction l generalizing init <;> simp [*]
state_before: α₁ : Type u_1
α₂ : Type u_2
β : Type u_3
f : α₁ → α₂
g : α₂ → β → β
l : List α₁
init : β
⊢ foldr g init (map f l) = foldr (fun x y => g (f x) y) init l
Theorem: Multiset.trop_inf
File: Mathlib/Algebra/Tropical/BigOperators.lean

tactic: induction' s using Multiset.induction with s x IH
state_before: R : Type u_1
S : Type ?u.25149
inst✝¹ : LinearOrder R
inst✝ : OrderTop R
s : Multiset R
⊢ trop (inf s) = sum (map trop s)

tactic: simp
state_before: case empty
R : Type u_1
S : Type ?u.25149
inst✝¹ : LinearOrder R
inst✝ : OrderTop R
⊢ trop (inf 0) = sum (map trop 0)

tactic: simp [← IH]
state_before: case cons
R : Type u_1
S : Type ?u.25149
inst✝¹ : LinearOrder R
inst✝ : OrderTop R
s : R
x : Multiset R
IH : trop (inf x) = sum (map trop x)
⊢ trop (inf (s ::ₘ x)) = sum (map trop (s ::ₘ x))
Theorem: Int.sq_add_sq_of_two_mul_sq_add_sq
File: Mathlib/NumberTheory/SumFourSquares.lean

tactic: simp [← h, even_mul]
state_before: m x y : ℤ
h : ↑2 * m = x ^ 2 + y ^ 2
⊢ Even (x ^ 2 + y ^ 2)

tactic: simpa [sq, parity_simps]
state_before: m x y : ℤ
h : ↑2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
⊢ Even (x + y)

tactic: simpa [sq, parity_simps]
state_before: m x y : ℤ
h : ↑2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
hxaddy : Even (x + y)
⊢ Even (x - y)

tactic: decide
state_before: m x y : ℤ
h : ↑2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
hxaddy : Even (x + y)
hxsuby : Even (x - y)
⊢ 2 * 2 ≠ 0

tactic: rw [mul_assoc, h]
state_before: m x y : ℤ
h : ↑2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
hxaddy : Even (x + y)
hxsuby : Even (x - y)
⊢ ↑2 * ↑2 * m = (x - y) ^ 2 + (x + y) ^ 2

tactic: ring
state_before: m x y : ℤ
h : ↑2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
hxaddy : Even (x + y)
hxsuby : Even (x - y)
⊢ ↑2 * (x ^ 2 + y ^ 2) = (x - y) ^ 2 + (x + y) ^ 2

tactic: rw [even_iff_two_dvd] at hxsuby hxaddy
state_before: m x y : ℤ
h : ↑2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
hxaddy : Even (x + y)
hxsuby : Even (x - y)
⊢ (x - y) ^ 2 + (x + y) ^ 2 = (2 * ((x - y) / 2)) ^ 2 + (2 * ((x + y) / 2)) ^ 2

tactic: rw [Int.mul_ediv_cancel' hxsuby, Int.mul_ediv_cancel' hxaddy]
state_before: m x y : ℤ
h : ↑2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
hxaddy : 2 ∣ x + y
hxsuby : 2 ∣ x - y
⊢ (x - y) ^ 2 + (x + y) ^ 2 = (2 * ((x - y) / 2)) ^ 2 + (2 * ((x + y) / 2)) ^ 2

tactic: simp [mul_add, pow_succ, mul_comm, mul_assoc, mul_left_comm]
state_before: m x y : ℤ
h : ↑2 * m = x ^ 2 + y ^ 2
this : Even (x ^ 2 + y ^ 2)
hxaddy : Even (x + y)
hxsuby : Even (x - y)
⊢ (2 * ((x - y) / 2)) ^ 2 + (2 * ((x + y) / 2)) ^ 2 = ↑2 * ↑2 * (((x - y) / 2) ^ 2 + ((x + y) / 2) ^ 2)
Theorem: PSet.equiv_of_isEmpty
File: Mathlib/SetTheory/ZFC/Basic.lean

tactic: simp
state_before: x : PSet
y : PSet
inst✝¹ : IsEmpty (Type x)
inst✝ : IsEmpty (Type y)
⊢ (∀ (i : Type x), ∃ j, Equiv (Func x i) (Func y j)) ∧ ∀ (j : Type y), ∃ i, Equiv (Func x i) (Func y j)
Theorem: Real.tan_neg_of_neg_of_pi_div_two_lt
File: Mathlib/Analysis/SpecialFunctions/Trigonometric/Basic.lean

tactic: linarith
state_before: x : ℝ
hx0 : x < 0
hpx : -(π / 2) < x
⊢ 0 < -x

tactic: linarith [pi_pos]
state_before: x : ℝ
hx0 : x < 0
hpx : -(π / 2) < x
⊢ -x < π / 2
Theorem: Ordnode.Sized.dual_iff
File: Mathlib/Data/Ordmap/Ordset.lean

tactic: rw [← dual_dual t]
state_before: α : Type u_1
t : Ordnode α
h : Sized (Ordnode.dual t)
⊢ Sized t

tactic: exact h.dual
state_before: α : Type u_1
t : Ordnode α
h : Sized (Ordnode.dual t)
⊢ Sized (Ordnode.dual (Ordnode.dual t))
Theorem: Function.Embedding.toEquivRange_symm_apply_self
File: Mathlib/Logic/Equiv/Fintype.lean

tactic: simp [Equiv.symm_apply_eq]
state_before: α : Type u_1
β : Type u_2
inst✝¹ : Fintype α
inst✝ : DecidableEq β
e : Equiv.Perm α
f : α ↪ β
a : α
⊢ ↑(toEquivRange f).symm { val := ↑f a, property := (_ : ↑f a ∈ Set.range ↑f) } = a
Theorem: Equiv.Perm.zpow_apply_eq_of_apply_apply_eq_self
File: Mathlib/GroupTheory/Perm/Support.lean

tactic: rw [zpow_negSucc, inv_eq_iff_eq, ← f.injective.eq_iff, ← mul_apply, ← pow_succ, eq_comm,
  inv_eq_iff_eq, ← mul_apply, ← pow_succ', @eq_comm _ x, or_comm]
state_before: α : Type u_1
f g h : Perm α
x : α
hffx : ↑f (↑f x) = x
n : ℕ
⊢ ↑(f ^ Int.negSucc n) x = x ∨ ↑(f ^ Int.negSucc n) x = ↑f x

tactic: exact pow_apply_eq_of_apply_apply_eq_self hffx _
state_before: α : Type u_1
f g h : Perm α
x : α
hffx : ↑f (↑f x) = x
n : ℕ
⊢ ↑(f ^ (n + 1 + 1)) x = x ∨ ↑(f ^ (n + 1 + 1)) x = ↑f x
Theorem: Equiv.Perm.disjoint_iff_disjoint_support
File: Mathlib/GroupTheory/Perm/Support.lean

tactic: simp [disjoint_iff_eq_or_eq, disjoint_iff, disjoint_iff, Finset.ext_iff, not_and_or,
  imp_iff_not_or]
state_before: α : Type u_1
inst✝¹ : DecidableEq α
inst✝ : Fintype α
f g : Perm α
⊢ Disjoint f g ↔ _root_.Disjoint (support f) (support g)
Theorem: Interval.coe_iInf
File: Mathlib/Order/Interval.lean

tactic: simp [iInf]
state_before: α : Type u_1
β : Type ?u.65135
γ : Type ?u.65138
δ : Type ?u.65141
ι : Sort u_2
κ : ι → Sort ?u.65149
inst✝¹ : CompleteLattice α
inst✝ : DecidableRel fun x x_1 => x ≤ x_1
f : ι → Interval α
⊢ ↑(⨅ (i : ι), f i) = ⋂ (i : ι), ↑(f i)
Theorem: MvPolynomial.degreeOf_add_le
File: Mathlib/Data/MvPolynomial/Variables.lean

tactic: letI := Classical.decEq σ
state_before: R : Type u
S : Type v
σ : Type u_1
τ : Type ?u.308701
r : R
e : ℕ
n✝ m : σ
s : σ →₀ ℕ
inst✝ : CommSemiring R
p q : MvPolynomial σ R
n : σ
f g : MvPolynomial σ R
⊢ degreeOf n (f + g) ≤ max (degreeOf n f) (degreeOf n g)

tactic: repeat' rw [degreeOf]
state_before: R : Type u
S : Type v
σ : Type u_1
τ : Type ?u.308701
r : R
e : ℕ
n✝ m : σ
s : σ →₀ ℕ
inst✝ : CommSemiring R
p q : MvPolynomial σ R
n : σ
f g : MvPolynomial σ R
this : DecidableEq σ := Classical.decEq σ
⊢ degreeOf n (f + g) ≤ max (degreeOf n f) (degreeOf n g)

tactic: apply (Multiset.count_le_of_le n (degrees_add f g)).trans
state_before: R : Type u
S : Type v
σ : Type u_1
τ : Type ?u.308701
r : R
e : ℕ
n✝ m : σ
s : σ →₀ ℕ
inst✝ : CommSemiring R
p q : MvPolynomial σ R
n : σ
f g : MvPolynomial σ R
this : DecidableEq σ := Classical.decEq σ
⊢ Multiset.count n (degrees (f + g)) ≤ max (Multiset.count n (degrees f)) (Multiset.count n (degrees g))

tactic: dsimp
state_before: R : Type u
S : Type v
σ : Type u_1
τ : Type ?u.308701
r : R
e : ℕ
n✝ m : σ
s : σ →₀ ℕ
inst✝ : CommSemiring R
p q : MvPolynomial σ R
n : σ
f g : MvPolynomial σ R
this : DecidableEq σ := Classical.decEq σ
⊢ Multiset.count n (degrees f ⊔ degrees g) ≤ max (Multiset.count n (degrees f)) (Multiset.count n (degrees g))

tactic: rw [Multiset.count_union]
state_before: R : Type u
S : Type v
σ : Type u_1
τ : Type ?u.308701
r : R
e : ℕ
n✝ m : σ
s : σ →₀ ℕ
inst✝ : CommSemiring R
p q : MvPolynomial σ R
n : σ
f g : MvPolynomial σ R
this : DecidableEq σ := Classical.decEq σ
⊢ Multiset.count n (degrees f ∪ degrees g) ≤ max (Multiset.count n (degrees f)) (Multiset.count n (degrees g))

tactic: rw [degreeOf]
state_before: R : Type u
S : Type v
σ : Type u_1
τ : Type ?u.308701
r : R
e : ℕ
n✝ m : σ
s : σ →₀ ℕ
inst✝ : CommSemiring R
p q : MvPolynomial σ R
n : σ
f g : MvPolynomial σ R
this : DecidableEq σ := Classical.decEq σ
⊢ Multiset.count n (degrees (f + g)) ≤ max (Multiset.count n (degrees f)) (Multiset.count n (degrees g))
Theorem: List.unzip_zip
File: Mathlib/Data/List/Zip.lean

tactic: rw [← Prod.mk.eta (p := unzip (zip l₁ l₂)),
  unzip_zip_left (le_of_eq h), unzip_zip_right (ge_of_eq h)]
state_before: α : Type u
β : Type u_1
γ : Type ?u.87252
δ : Type ?u.87255
ε : Type ?u.87258
l₁ : List α
l₂ : List β
h : length l₁ = length l₂
⊢ unzip (zip l₁ l₂) = (l₁, l₂)
Theorem: mul_inv_eq_of_eq_mul
File: Mathlib/Algebra/Group/Basic.lean

tactic: simp [h]
state_before: α : Type ?u.51063
β : Type ?u.51066
G : Type u_1
inst✝ : Group G
a b c d : G
h : a = c * b
⊢ a * b⁻¹ = c
Theorem: List.injective_foldl_comp
File: Mathlib/Data/List/Basic.lean

tactic: induction' l with lh lt l_ih generalizing f
state_before: ι : Type ?u.235575
α✝ : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α✝
α : Type u_1
l : List (α → α)
f : α → α
hl : ∀ (f : α → α), f ∈ l → Injective f
hf : Injective f
⊢ Injective (foldl comp f l)

tactic: exact hf
state_before: case nil
ι : Type ?u.235575
α✝ : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α✝
α : Type u_1
l : List (α → α)
f✝ : α → α
hl✝ : ∀ (f : α → α), f ∈ l → Injective f
hf✝ : Injective f✝
f : α → α
hl : ∀ (f : α → α), f ∈ [] → Injective f
hf : Injective f
⊢ Injective (foldl comp f [])

tactic: apply l_ih fun _ h => hl _ (List.mem_cons_of_mem _ h)
state_before: case cons
ι : Type ?u.235575
α✝ : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α✝
α : Type u_1
l : List (α → α)
f✝ : α → α
hl✝ : ∀ (f : α → α), f ∈ l → Injective f
hf✝ : Injective f✝
lh : α → α
lt : List (α → α)
l_ih : ∀ {f : α → α}, (∀ (f : α → α), f ∈ lt → Injective f) → Injective f → Injective (foldl comp f lt)
f : α → α
hl : ∀ (f : α → α), f ∈ lh :: lt → Injective f
hf : Injective f
⊢ Injective (foldl comp f (lh :: lt))

tactic: apply Function.Injective.comp hf
state_before: case cons
ι : Type ?u.235575
α✝ : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α✝
α : Type u_1
l : List (α → α)
f✝ : α → α
hl✝ : ∀ (f : α → α), f ∈ l → Injective f
hf✝ : Injective f✝
lh : α → α
lt : List (α → α)
l_ih : ∀ {f : α → α}, (∀ (f : α → α), f ∈ lt → Injective f) → Injective f → Injective (foldl comp f lt)
f : α → α
hl : ∀ (f : α → α), f ∈ lh :: lt → Injective f
hf : Injective f
⊢ Injective (f ∘ lh)

tactic: apply hl _ (List.mem_cons_self _ _)
state_before: case cons
ι : Type ?u.235575
α✝ : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α✝
α : Type u_1
l : List (α → α)
f✝ : α → α
hl✝ : ∀ (f : α → α), f ∈ l → Injective f
hf✝ : Injective f✝
lh : α → α
lt : List (α → α)
l_ih : ∀ {f : α → α}, (∀ (f : α → α), f ∈ lt → Injective f) → Injective f → Injective (foldl comp f lt)
f : α → α
hl : ∀ (f : α → α), f ∈ lh :: lt → Injective f
hf : Injective f
⊢ Injective lh
Theorem: Int.ediv_pos_of_pos_of_dvd
File: Mathlib/Data/Int/Order/Basic.lean

tactic: rwa [zero_mul]
state_before: a✝ b✝ : ℤ
n : ℕ
a b : ℤ
H1 : 0 < a
H2 : 0 ≤ b
H3 : b ∣ a
⊢ 0 * b < a
Theorem: tsum_bool
File: Mathlib/Topology/Algebra/InfiniteSum/Basic.lean

tactic: rw [tsum_fintype, Finset.sum_eq_add] <;> simp
state_before: α : Type u_1
β : Type ?u.317051
γ : Type ?u.317054
δ : Type ?u.317057
inst✝² : AddCommMonoid α
inst✝¹ : TopologicalSpace α
inst✝ : T2Space α
f✝ g : β → α
a a₁ a₂ : α
f : Bool → α
⊢ (∑' (i : Bool), f i) = f (decide False) + f (decide True)
Theorem: Real.mul_pos
File: Mathlib/Data/Real/Basic.lean

tactic: induction' a using Real.ind_mk with a
state_before: x y a b : ℝ
⊢ 0 < a → 0 < b → 0 < a * b

tactic: induction' b using Real.ind_mk with b
state_before: case h
x y b : ℝ
a : CauSeq ℚ abs
⊢ 0 < mk a → 0 < b → 0 < mk a * b

tactic: simpa only [mk_lt, mk_pos, ← mk_mul] using CauSeq.mul_pos
state_before: case h.h
x y : ℝ
a b : CauSeq ℚ abs
⊢ 0 < mk a → 0 < mk b → 0 < mk a * mk b
Theorem: Rat.add_assoc
File: Mathlib/Data/Rat/Defs.lean

tactic: simp [h₁, h₂, h₃]
state_before: a b c : ℚ
n₁ : ℤ
d₁ : ℕ
h₁ : d₁ ≠ 0
n₂ : ℤ
d₂ : ℕ
h₂ : d₂ ≠ 0
n₃ : ℤ
d₃ : ℕ
h₃ : d₃ ≠ 0
⊢ n₁ /. ↑d₁ + n₂ /. ↑d₂ + n₃ /. ↑d₃ = n₁ /. ↑d₁ + (n₂ /. ↑d₂ + n₃ /. ↑d₃)

tactic: rw [mul_assoc, add_mul, add_mul, mul_assoc, add_assoc]
state_before: a b c : ℚ
n₁ : ℤ
d₁ : ℕ
h₁ : d₁ ≠ 0
n₂ : ℤ
d₂ : ℕ
h₂ : d₂ ≠ 0
n₃ : ℤ
d₃ : ℕ
h₃ : d₃ ≠ 0
⊢ ((n₁ * ↑d₂ + n₂ * ↑d₁) * ↑d₃ + n₃ * (↑d₁ * ↑d₂)) /. (↑d₁ * ↑d₂ * ↑d₃) =
    (n₁ * (↑d₂ * ↑d₃) + (n₂ * ↑d₃ + n₃ * ↑d₂) * ↑d₁) /. (↑d₁ * (↑d₂ * ↑d₃))

tactic: congr 2
state_before: a b c : ℚ
n₁ : ℤ
d₁ : ℕ
h₁ : d₁ ≠ 0
n₂ : ℤ
d₂ : ℕ
h₂ : d₂ ≠ 0
n₃ : ℤ
d₃ : ℕ
h₃ : d₃ ≠ 0
⊢ (n₁ * (↑d₂ * ↑d₃) + (n₂ * ↑d₁ * ↑d₃ + n₃ * (↑d₁ * ↑d₂))) /. (↑d₁ * (↑d₂ * ↑d₃)) =
    (n₁ * (↑d₂ * ↑d₃) + (n₂ * ↑d₃ * ↑d₁ + n₃ * ↑d₂ * ↑d₁)) /. (↑d₁ * (↑d₂ * ↑d₃))

tactic: ac_rfl
state_before: case e_a.e_a
a b c : ℚ
n₁ : ℤ
d₁ : ℕ
h₁ : d₁ ≠ 0
n₂ : ℤ
d₂ : ℕ
h₂ : d₂ ≠ 0
n₃ : ℤ
d₃ : ℕ
h₃ : d₃ ≠ 0
⊢ n₂ * ↑d₁ * ↑d₃ + n₃ * (↑d₁ * ↑d₂) = n₂ * ↑d₃ * ↑d₁ + n₃ * ↑d₂ * ↑d₁
Theorem: MeasureTheory.Memℒp.smul_of_top_right
File: Mathlib/MeasureTheory/Function/LpSeminorm.lean

tactic: apply hf.smul hφ
state_before: α : Type u_2
E : Type u_1
F : Type ?u.5938996
G : Type ?u.5938999
m m0 : MeasurableSpace α
p✝ : ℝ≥0∞
q : ℝ
μ ν : Measure α
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedAddCommGroup F
inst✝⁵ : NormedAddCommGroup G
𝕜 : Type u_3
inst✝⁴ : NormedRing 𝕜
inst✝³ : MulActionWithZero 𝕜 E
inst✝² : MulActionWithZero 𝕜 F
inst✝¹ : BoundedSMul 𝕜 E
inst✝ : BoundedSMul 𝕜 F
p : ℝ≥0∞
f : α → E
φ : α → 𝕜
hf : Memℒp f p
hφ : Memℒp φ ⊤
⊢ Memℒp (φ • f) p

tactic: simp only [ENNReal.div_top, zero_add]
state_before: α : Type u_2
E : Type u_1
F : Type ?u.5938996
G : Type ?u.5938999
m m0 : MeasurableSpace α
p✝ : ℝ≥0∞
q : ℝ
μ ν : Measure α
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedAddCommGroup F
inst✝⁵ : NormedAddCommGroup G
𝕜 : Type u_3
inst✝⁴ : NormedRing 𝕜
inst✝³ : MulActionWithZero 𝕜 E
inst✝² : MulActionWithZero 𝕜 F
inst✝¹ : BoundedSMul 𝕜 E
inst✝ : BoundedSMul 𝕜 F
p : ℝ≥0∞
f : α → E
φ : α → 𝕜
hf : Memℒp f p
hφ : Memℒp φ ⊤
⊢ 1 / p = 1 / ⊤ + 1 / p
Theorem: Complex.cos_sub
File: Mathlib/Data/Complex/Exponential.lean

tactic: simp [sub_eq_add_neg, cos_add, sin_neg, cos_neg]
state_before: x y : ℂ
⊢ cos (x - y) = cos x * cos y + sin x * sin y
Theorem: OrderTop.ext_top
File: Mathlib/Order/BoundedOrder.lean

tactic: cases PartialOrder.ext H
state_before: α✝ : Type u
β : Type v
γ : Type ?u.18268
δ : Type ?u.18271
α : Type u_1
hA : PartialOrder α
A : OrderTop α
hB : PartialOrder α
B : OrderTop α
H : ∀ (x y : α), x ≤ y ↔ x ≤ y
⊢ ⊤ = ⊤

tactic: apply top_unique
state_before: case refl
α✝ : Type u
β : Type v
γ : Type ?u.18268
δ : Type ?u.18271
α : Type u_1
hA : PartialOrder α
A B : OrderTop α
H : ∀ (x y : α), x ≤ y ↔ x ≤ y
⊢ ⊤ = ⊤

tactic: exact @le_top _ _ A _
state_before: case refl.h
α✝ : Type u
β : Type v
γ : Type ?u.18268
δ : Type ?u.18271
α : Type u_1
hA : PartialOrder α
A B : OrderTop α
H : ∀ (x y : α), x ≤ y ↔ x ≤ y
⊢ ⊤ ≤ ⊤
Theorem: Group.conjugatesOf_subset
File: Mathlib/Deprecated/Subgroup.lean

tactic: obtain ⟨c, w⟩ := isConj_iff.1 hc
state_before: G : Type u_1
H : Type ?u.142727
A : Type ?u.142730
a✝ a₁ a₂ b c : G
s : Set G
inst✝ : Group G
t : Set G
ht : IsNormalSubgroup t
a : G
h : a ∈ t
x : G
hc : x ∈ conjugatesOf a
⊢ x ∈ t

tactic: have H := IsNormalSubgroup.normal ht a h c
state_before: case intro
G : Type u_1
H : Type ?u.142727
A : Type ?u.142730
a✝ a₁ a₂ b c✝ : G
s : Set G
inst✝ : Group G
t : Set G
ht : IsNormalSubgroup t
a : G
h : a ∈ t
x : G
hc : x ∈ conjugatesOf a
c : G
w : c * a * c⁻¹ = x
⊢ x ∈ t

tactic: rwa [← w]
state_before: case intro
G : Type u_1
H✝ : Type ?u.142727
A : Type ?u.142730
a✝ a₁ a₂ b c✝ : G
s : Set G
inst✝ : Group G
t : Set G
ht : IsNormalSubgroup t
a : G
h : a ∈ t
x : G
hc : x ∈ conjugatesOf a
c : G
w : c * a * c⁻¹ = x
H : c * a * c⁻¹ ∈ t
⊢ x ∈ t
Theorem: LipschitzOnWith.of_dist_le'
File: Mathlib/Topology/MetricSpace/Lipschitz.lean

tactic: gcongr
state_before: α : Type u
β : Type v
γ : Type w
ι : Type x
inst✝² : PseudoMetricSpace α
inst✝¹ : PseudoMetricSpace β
inst✝ : PseudoMetricSpace γ
K✝ : ℝ≥0
s : Set α
f : α → β
K : ℝ
h : ∀ (x : α), x ∈ s → ∀ (y : α), y ∈ s → dist (f x) (f y) ≤ K * dist x y
x : α
hx : x ∈ s
y : α
hy : y ∈ s
⊢ K * dist x y ≤ ↑(Real.toNNReal K) * dist x y

tactic: apply Real.le_coe_toNNReal
state_before: case h
α : Type u
β : Type v
γ : Type w
ι : Type x
inst✝² : PseudoMetricSpace α
inst✝¹ : PseudoMetricSpace β
inst✝ : PseudoMetricSpace γ
K✝ : ℝ≥0
s : Set α
f : α → β
K : ℝ
h : ∀ (x : α), x ∈ s → ∀ (y : α), y ∈ s → dist (f x) (f y) ≤ K * dist x y
x : α
hx : x ∈ s
y : α
hy : y ∈ s
⊢ K ≤ ↑(Real.toNNReal K)
Theorem: ContinuousLinearEquiv.comp_fderivWithin
File: Mathlib/Analysis/Calculus/FDeriv/Equiv.lean

tactic: by_cases h : DifferentiableWithinAt 𝕜 f s x
state_before: 𝕜 : Type u_2
inst✝⁸ : NontriviallyNormedField 𝕜
E : Type u_4
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace 𝕜 E
F : Type u_3
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
G : Type u_1
inst✝³ : NormedAddCommGroup G
inst✝² : NormedSpace 𝕜 G
G' : Type ?u.139136
inst✝¹ : NormedAddCommGroup G'
inst✝ : NormedSpace 𝕜 G'
f✝ f₀ f₁ g : E → F
f' f₀' f₁' g' e : E →L[𝕜] F
x✝ : E
s✝ t : Set E
L L₁ L₂ : Filter E
iso : E ≃L[𝕜] F
f : G → E
s : Set G
x : G
hxs : UniqueDiffWithinAt 𝕜 s x
⊢ fderivWithin 𝕜 (↑iso ∘ f) s x = comp (↑iso) (fderivWithin 𝕜 f s x)

tactic: rw [fderiv.comp_fderivWithin x iso.differentiableAt h hxs, iso.fderiv]
state_before: case pos
𝕜 : Type u_2
inst✝⁸ : NontriviallyNormedField 𝕜
E : Type u_4
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace 𝕜 E
F : Type u_3
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
G : Type u_1
inst✝³ : NormedAddCommGroup G
inst✝² : NormedSpace 𝕜 G
G' : Type ?u.139136
inst✝¹ : NormedAddCommGroup G'
inst✝ : NormedSpace 𝕜 G'
f✝ f₀ f₁ g : E → F
f' f₀' f₁' g' e : E →L[𝕜] F
x✝ : E
s✝ t : Set E
L L₁ L₂ : Filter E
iso : E ≃L[𝕜] F
f : G → E
s : Set G
x : G
hxs : UniqueDiffWithinAt 𝕜 s x
h : DifferentiableWithinAt 𝕜 f s x
⊢ fderivWithin 𝕜 (↑iso ∘ f) s x = comp (↑iso) (fderivWithin 𝕜 f s x)

tactic: have : ¬DifferentiableWithinAt 𝕜 (iso ∘ f) s x := mt iso.comp_differentiableWithinAt_iff.1 h
state_before: case neg
𝕜 : Type u_2
inst✝⁸ : NontriviallyNormedField 𝕜
E : Type u_4
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace 𝕜 E
F : Type u_3
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
G : Type u_1
inst✝³ : NormedAddCommGroup G
inst✝² : NormedSpace 𝕜 G
G' : Type ?u.139136
inst✝¹ : NormedAddCommGroup G'
inst✝ : NormedSpace 𝕜 G'
f✝ f₀ f₁ g : E → F
f' f₀' f₁' g' e : E →L[𝕜] F
x✝ : E
s✝ t : Set E
L L₁ L₂ : Filter E
iso : E ≃L[𝕜] F
f : G → E
s : Set G
x : G
hxs : UniqueDiffWithinAt 𝕜 s x
h : ¬DifferentiableWithinAt 𝕜 f s x
⊢ fderivWithin 𝕜 (↑iso ∘ f) s x = comp (↑iso) (fderivWithin 𝕜 f s x)

tactic: rw [fderivWithin_zero_of_not_differentiableWithinAt h,
  fderivWithin_zero_of_not_differentiableWithinAt this, ContinuousLinearMap.comp_zero]
state_before: case neg
𝕜 : Type u_2
inst✝⁸ : NontriviallyNormedField 𝕜
E : Type u_4
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace 𝕜 E
F : Type u_3
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
G : Type u_1
inst✝³ : NormedAddCommGroup G
inst✝² : NormedSpace 𝕜 G
G' : Type ?u.139136
inst✝¹ : NormedAddCommGroup G'
inst✝ : NormedSpace 𝕜 G'
f✝ f₀ f₁ g : E → F
f' f₀' f₁' g' e : E →L[𝕜] F
x✝ : E
s✝ t : Set E
L L₁ L₂ : Filter E
iso : E ≃L[𝕜] F
f : G → E
s : Set G
x : G
hxs : UniqueDiffWithinAt 𝕜 s x
h : ¬DifferentiableWithinAt 𝕜 f s x
this : ¬DifferentiableWithinAt 𝕜 (↑iso ∘ f) s x
⊢ fderivWithin 𝕜 (↑iso ∘ f) s x = comp (↑iso) (fderivWithin 𝕜 f s x)
Theorem: ZNum.of_to_int
File: Mathlib/Data/Num/Lemmas.lean

tactic: rw [← ofInt'_eq, of_to_int']
state_before: α : Type ?u.1060897
n : ZNum
⊢ ↑↑n = n