tasksource/leandojo huggingface dataset:
Theorem: Cardinal.small_iff_lift_mk_lt_univ
File: Mathlib/SetTheory/Ordinal/Basic.lean

tactic: rw [lt_univ']
state_before: α✝ : Type ?u.236087
β : Type ?u.236090
γ : Type ?u.236093
r : α✝ → α✝ → Prop
s : β → β → Prop
t : γ → γ → Prop
α : Type u
⊢ Small α ↔ lift (#α) < univ

tactic: constructor
state_before: α✝ : Type ?u.236087
β : Type ?u.236090
γ : Type ?u.236093
r : α✝ → α✝ → Prop
s : β → β → Prop
t : γ → γ → Prop
α : Type u
⊢ Small α ↔ ∃ c', lift (#α) = lift c'

tactic: rintro ⟨β, e⟩
state_before: case mp
α✝ : Type ?u.236087
β : Type ?u.236090
γ : Type ?u.236093
r : α✝ → α✝ → Prop
s : β → β → Prop
t : γ → γ → Prop
α : Type u
⊢ Small α → ∃ c', lift (#α) = lift c'

tactic: exact ⟨#β, lift_mk_eq.{u, _, v + 1}.2 e⟩
state_before: case mp.mk.intro
α✝ : Type ?u.236087
β✝ : Type ?u.236090
γ : Type ?u.236093
r : α✝ → α✝ → Prop
s : β✝ → β✝ → Prop
t : γ → γ → Prop
α : Type u
β : Type v
e : Nonempty (α ≃ β)
⊢ ∃ c', lift (#α) = lift c'

tactic: rintro ⟨c, hc⟩
state_before: case mpr
α✝ : Type ?u.236087
β : Type ?u.236090
γ : Type ?u.236093
r : α✝ → α✝ → Prop
s : β → β → Prop
t : γ → γ → Prop
α : Type u
⊢ (∃ c', lift (#α) = lift c') → Small α

tactic: exact ⟨⟨c.out, lift_mk_eq.{u, _, v + 1}.1 (hc.trans (congr rfl c.mk_out.symm))⟩⟩
state_before: case mpr.intro
α✝ : Type ?u.236087
β : Type ?u.236090
γ : Type ?u.236093
r : α✝ → α✝ → Prop
s : β → β → Prop
t : γ → γ → Prop
α : Type u
c : Cardinal
hc : lift (#α) = lift c
⊢ Small α
Theorem: mem_const_vadd_affineSegment
File: Mathlib/Analysis/Convex/Between.lean

tactic: rw [← affineSegment_const_vadd_image, (AddAction.injective v).mem_set_image]
state_before: R : Type u_3
V : Type u_2
V' : Type ?u.46449
P : Type u_1
P' : Type ?u.46455
inst✝⁶ : OrderedRing R
inst✝⁵ : AddCommGroup V
inst✝⁴ : Module R V
inst✝³ : AddTorsor V P
inst✝² : AddCommGroup V'
inst✝¹ : Module R V'
inst✝ : AddTorsor V' P'
x y z : P
v : V
⊢ v +ᵥ z ∈ affineSegment R (v +ᵥ x) (v +ᵥ y) ↔ z ∈ affineSegment R x y
Theorem: EMetric.disjoint_closedBall_of_lt_infEdist
File: Mathlib/Topology/MetricSpace/HausdorffDistance.lean

tactic: rw [disjoint_left]
state_before: ι : Sort ?u.18874
α : Type u
β : Type v
inst✝¹ : PseudoEMetricSpace α
inst✝ : PseudoEMetricSpace β
x y : α
s t : Set α
Φ : α → β
r : ℝ≥0∞
h : r < infEdist x s
⊢ Disjoint (closedBall x r) s

tactic: intro y hy h'y
state_before: ι : Sort ?u.18874
α : Type u
β : Type v
inst✝¹ : PseudoEMetricSpace α
inst✝ : PseudoEMetricSpace β
x y : α
s t : Set α
Φ : α → β
r : ℝ≥0∞
h : r < infEdist x s
⊢ ∀ ⦃a : α⦄, a ∈ closedBall x r → ¬a ∈ s

tactic: apply lt_irrefl (infEdist x s)
state_before: ι : Sort ?u.18874
α : Type u
β : Type v
inst✝¹ : PseudoEMetricSpace α
inst✝ : PseudoEMetricSpace β
x y✝ : α
s t : Set α
Φ : α → β
r : ℝ≥0∞
h : r < infEdist x s
y : α
hy : y ∈ closedBall x r
h'y : y ∈ s
⊢ False

tactic: calc
  infEdist x s ≤ edist x y := infEdist_le_edist_of_mem h'y
  _ ≤ r := by rwa [mem_closedBall, edist_comm] at hy
  _ < infEdist x s := h
state_before: ι : Sort ?u.18874
α : Type u
β : Type v
inst✝¹ : PseudoEMetricSpace α
inst✝ : PseudoEMetricSpace β
x y✝ : α
s t : Set α
Φ : α → β
r : ℝ≥0∞
h : r < infEdist x s
y : α
hy : y ∈ closedBall x r
h'y : y ∈ s
⊢ infEdist x s < infEdist x s

tactic: rwa [mem_closedBall, edist_comm] at hy
state_before: ι : Sort ?u.18874
α : Type u
β : Type v
inst✝¹ : PseudoEMetricSpace α
inst✝ : PseudoEMetricSpace β
x y✝ : α
s t : Set α
Φ : α → β
r : ℝ≥0∞
h : r < infEdist x s
y : α
hy : y ∈ closedBall x r
h'y : y ∈ s
⊢ edist x y ≤ r
Theorem: Tuple.monotone_proj
File: Mathlib/Data/Fin/Tuple/Sort.lean

tactic: rintro ⟨⟨x, i⟩, hx⟩ ⟨⟨y, j⟩, hy⟩ (_ | h)
state_before: n : ℕ
α : Type u_1
inst✝ : LinearOrder α
f : Fin n → α
⊢ Monotone graph.proj

tactic: exact le_of_lt ‹_›
state_before: case mk.mk.mk.mk.left
n : ℕ
α : Type u_1
inst✝ : LinearOrder α
f : Fin n → α
x : α
i : Fin n
hx : (x, i) ∈ graph f
y : α
j : Fin n
hy : (y, j) ∈ graph f
h✝ : x < y
⊢ graph.proj { val := (x, i), property := hx } ≤ graph.proj { val := (y, j), property := hy }

tactic: simp [graph.proj]
state_before: case mk.mk.mk.mk.right
n : ℕ
α : Type u_1
inst✝ : LinearOrder α
f : Fin n → α
x : α
i : Fin n
hx : (x, i) ∈ graph f
j : Fin n
hy : (x, j) ∈ graph f
h✝ : i ≤ j
⊢ graph.proj { val := (x, i), property := hx } ≤ graph.proj { val := (x, j), property := hy }
Theorem: QuadraticForm.exists_quadraticForm_ne_zero
File: Mathlib/LinearAlgebra/QuadraticForm/Basic.lean

tactic: rw [← not_forall]
state_before: S : Type ?u.453261
R : Type u_1
R₁ : Type ?u.453267
M : Type u_2
inst✝⁷ : Ring R
inst✝⁶ : CommRing R₁
inst✝⁵ : AddCommGroup M
inst✝⁴ : Module R M
inst✝³ : Module R₁ M
inst✝² : CommSemiring S
inst✝¹ : Algebra S R
inst✝ : Invertible 2
B₁ : BilinForm R M
Q✝ Q : QuadraticForm R M
hB₁ : ↑associated' Q ≠ 0
⊢ ∃ x, ↑Q x ≠ 0

tactic: intro h
state_before: S : Type ?u.453261
R : Type u_1
R₁ : Type ?u.453267
M : Type u_2
inst✝⁷ : Ring R
inst✝⁶ : CommRing R₁
inst✝⁵ : AddCommGroup M
inst✝⁴ : Module R M
inst✝³ : Module R₁ M
inst✝² : CommSemiring S
inst✝¹ : Algebra S R
inst✝ : Invertible 2
B₁ : BilinForm R M
Q✝ Q : QuadraticForm R M
hB₁ : ↑associated' Q ≠ 0
⊢ ¬∀ (x : M), ↑Q x = 0

tactic: apply hB₁
state_before: S : Type ?u.453261
R : Type u_1
R₁ : Type ?u.453267
M : Type u_2
inst✝⁷ : Ring R
inst✝⁶ : CommRing R₁
inst✝⁵ : AddCommGroup M
inst✝⁴ : Module R M
inst✝³ : Module R₁ M
inst✝² : CommSemiring S
inst✝¹ : Algebra S R
inst✝ : Invertible 2
B₁ : BilinForm R M
Q✝ Q : QuadraticForm R M
hB₁ : ↑associated' Q ≠ 0
h : ∀ (x : M), ↑Q x = 0
⊢ False

tactic: rw [(QuadraticForm.ext h : Q = 0), LinearMap.map_zero]
state_before: S : Type ?u.453261
R : Type u_1
R₁ : Type ?u.453267
M : Type u_2
inst✝⁷ : Ring R
inst✝⁶ : CommRing R₁
inst✝⁵ : AddCommGroup M
inst✝⁴ : Module R M
inst✝³ : Module R₁ M
inst✝² : CommSemiring S
inst✝¹ : Algebra S R
inst✝ : Invertible 2
B₁ : BilinForm R M
Q✝ Q : QuadraticForm R M
hB₁ : ↑associated' Q ≠ 0
h : ∀ (x : M), ↑Q x = 0
⊢ ↑associated' Q = 0
Theorem: Complex.cos_sq
File: Mathlib/Data/Complex/Exponential.lean

tactic: simp [cos_two_mul, div_add_div_same, mul_div_cancel_left, two_ne_zero, -one_div]
state_before: x y : ℂ
⊢ cos x ^ 2 = 1 / 2 + cos (2 * x) / 2
Theorem: Nat.log_eq_iff
File: Mathlib/Data/Nat/Log.lean

tactic: rcases em (1 < b ∧ n ≠ 0) with (⟨hb, hn⟩ | hbn)
state_before: b m n : ℕ
h : m ≠ 0 ∨ 1 < b ∧ n ≠ 0
⊢ log b n = m ↔ b ^ m ≤ n ∧ n < b ^ (m + 1)

tactic: rw [le_antisymm_iff, ← lt_succ_iff, ← pow_le_iff_le_log, ← lt_pow_iff_log_lt, and_comm] <;>
  assumption
state_before: case inl.intro
b m n : ℕ
h : m ≠ 0 ∨ 1 < b ∧ n ≠ 0
hb : 1 < b
hn : n ≠ 0
⊢ log b n = m ↔ b ^ m ≤ n ∧ n < b ^ (m + 1)

tactic: have hm : m ≠ 0 := h.resolve_right hbn
state_before: case inr
b m n : ℕ
h : m ≠ 0 ∨ 1 < b ∧ n ≠ 0
hbn : ¬(1 < b ∧ n ≠ 0)
⊢ log b n = m ↔ b ^ m ≤ n ∧ n < b ^ (m + 1)

tactic: rw [not_and_or, not_lt, Ne.def, not_not] at hbn
state_before: case inr
b m n : ℕ
h : m ≠ 0 ∨ 1 < b ∧ n ≠ 0
hbn : ¬(1 < b ∧ n ≠ 0)
hm : m ≠ 0
⊢ log b n = m ↔ b ^ m ≤ n ∧ n < b ^ (m + 1)

tactic: rcases hbn with (hb | rfl)
state_before: case inr
b m n : ℕ
h : m ≠ 0 ∨ 1 < b ∧ n ≠ 0
hbn : b ≤ 1 ∨ n = 0
hm : m ≠ 0
⊢ log b n = m ↔ b ^ m ≤ n ∧ n < b ^ (m + 1)

tactic: simpa only [log_of_left_le_one hb, hm.symm, false_iff_iff, not_and, not_lt] using
  le_trans (pow_le_pow_of_le_one' hb m.le_succ)
state_before: case inr.inl
b m n : ℕ
h : m ≠ 0 ∨ 1 < b ∧ n ≠ 0
hm : m ≠ 0
hb : b ≤ 1
⊢ log b n = m ↔ b ^ m ≤ n ∧ n < b ^ (m + 1)

tactic: simpa only [log_zero_right, hm.symm, nonpos_iff_eq_zero, false_iff, not_and, not_lt,
  add_pos_iff, or_true, pow_eq_zero_iff] using pow_eq_zero
state_before: case inr.inr
b m : ℕ
hm : m ≠ 0
h : m ≠ 0 ∨ 1 < b ∧ 0 ≠ 0
⊢ log b 0 = m ↔ b ^ m ≤ 0 ∧ 0 < b ^ (m + 1)
Theorem: Fin.prod_univ_two
File: Mathlib/Algebra/BigOperators/Fin.lean

tactic: simp [prod_univ_succ]
state_before: α : Type ?u.16374
β : Type u_1
inst✝ : CommMonoid β
f : Fin 2 → β
⊢ ∏ i : Fin 2, f i = f 0 * f 1
Theorem: IsSubgroup.div_mem
File: Mathlib/Deprecated/Subgroup.lean

tactic: simpa only [div_eq_mul_inv] using hs.mul_mem hx (hs.inv_mem hy)
state_before: G : Type u_1
H : Type ?u.1244
A : Type ?u.1247
a a₁ a₂ b c : G
inst✝¹ : Group G
inst✝ : AddGroup A
s : Set G
hs : IsSubgroup s
x y : G
hx : x ∈ s
hy : y ∈ s
⊢ x / y ∈ s
Theorem: Set.mem_fintype_prod
File: Mathlib/Data/Set/Pointwise/BigOperators.lean

tactic: rw [mem_finset_prod]
state_before: ι : Type u_1
α : Type u_2
β : Type ?u.59011
F : Type ?u.59014
inst✝³ : CommMonoid α
inst✝² : CommMonoid β
inst✝¹ : MonoidHomClass F α β
inst✝ : Fintype ι
f : ι → Set α
a : α
⊢ a ∈ ∏ i : ι, f i ↔ ∃ g x, ∏ i : ι, g i = a

tactic: simp
state_before: ι : Type u_1
α : Type u_2
β : Type ?u.59011
F : Type ?u.59014
inst✝³ : CommMonoid α
inst✝² : CommMonoid β
inst✝¹ : MonoidHomClass F α β
inst✝ : Fintype ι
f : ι → Set α
a : α
⊢ (∃ g x, ∏ i : ι, g i = a) ↔ ∃ g x, ∏ i : ι, g i = a
Theorem: ZMod.cast_one
File: Mathlib/Data/ZMod/Basic.lean

tactic: cases' n with n
state_before: n : ℕ
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
h : m ∣ n
⊢ ↑1 = 1

tactic: show ((1 % (n + 1) : ℕ) : R) = 1
state_before: case succ
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
n : ℕ
h : m ∣ Nat.succ n
⊢ ↑1 = 1

tactic: cases n
state_before: case succ
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
n : ℕ
h : m ∣ Nat.succ n
⊢ ↑(1 % (n + 1)) = 1

tactic: rw [Nat.mod_eq_of_lt]
state_before: case succ.succ
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
n✝ : ℕ
h : m ∣ Nat.succ (Nat.succ n✝)
⊢ ↑(1 % (Nat.succ n✝ + 1)) = 1

tactic: exact Nat.lt_of_sub_eq_succ rfl
state_before: case succ.succ
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
n✝ : ℕ
h : m ∣ Nat.succ (Nat.succ n✝)
⊢ 1 < Nat.succ n✝ + 1

tactic: exact Int.cast_one
state_before: case zero
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
h : m ∣ Nat.zero
⊢ ↑1 = 1

tactic: rw [Nat.dvd_one] at h
state_before: case succ.zero
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
h : m ∣ Nat.succ Nat.zero
⊢ ↑(1 % (Nat.zero + 1)) = 1

tactic: subst m
state_before: case succ.zero
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
h : m = 1
⊢ ↑(1 % (Nat.zero + 1)) = 1

tactic: apply Subsingleton.elim
state_before: case succ.zero
R : Type u_1
inst✝¹ : Ring R
inst✝ : CharP R 1
⊢ ↑(1 % (Nat.zero + 1)) = 1

tactic: exact Nat.cast_one
state_before: case succ.succ
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
n✝ : ℕ
h : m ∣ Nat.succ (Nat.succ n✝)
⊢ ↑1 = 1
Theorem: Equiv.Perm.sameCycle_inv_apply_right
File: Mathlib/GroupTheory/Perm/Cycle/Basic.lean

tactic: rw [← sameCycle_apply_right, apply_inv_self]
state_before: ι : Type ?u.77704
α : Type u_1
β : Type ?u.77710
f g : Perm α
p : α → Prop
x y z : α
⊢ SameCycle f x (↑f⁻¹ y) ↔ SameCycle f x y
Theorem: LatticeOrderedCommGroup.one_le_abs
File: Mathlib/Algebra/Order/LatticeGroup.lean

tactic: rw [← m_pos_abs]
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 : α
⊢ 1 ≤ abs a

tactic: exact one_le_pos _
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 : α
⊢ 1 ≤ abs a⁺
Theorem: CategoryTheory.Limits.epi_image_of_epi
File: Mathlib/CategoryTheory/Limits/Shapes/Images.lean

tactic: rw [← image.fac f] at E
state_before: C : Type u
inst✝¹ : Category C
X✝ Y✝ : C
f✝ : X✝ ⟶ Y✝
X Y : C
f : X ⟶ Y
inst✝ : HasImage f
E : Epi f
⊢ Epi (image.ι f)

tactic: skip
state_before: C : Type u
inst✝¹ : Category C
X✝ Y✝ : C
f✝ : X✝ ⟶ Y✝
X Y : C
f : X ⟶ Y
inst✝ : HasImage f
E : Epi (factorThruImage f ≫ image.ι f)
⊢ Epi (image.ι f)

tactic: exact epi_of_epi (factorThruImage f) (image.ι f)
state_before: C : Type u
inst✝¹ : Category C
X✝ Y✝ : C
f✝ : X✝ ⟶ Y✝
X Y : C
f : X ⟶ Y
inst✝ : HasImage f
E : Epi (factorThruImage f ≫ image.ι f)
⊢ Epi (image.ι f)
Theorem: List.replaceF_of_forall_none
File: Std/Data/List/Lemmas.lean

tactic: induction l with
| nil => rfl
| cons _ _ ih => simp [h _ (.head ..), ih (forall_mem_cons.1 h).2]
state_before: α : Type u_1
p : α → Option α
l : List α
h : ∀ (a : α), a ∈ l → p a = none
⊢ replaceF p l = l

tactic: rfl
state_before: case nil
α : Type u_1
p : α → Option α
h : ∀ (a : α), a ∈ [] → p a = none
⊢ replaceF p [] = []

tactic: simp [h _ (.head ..), ih (forall_mem_cons.1 h).2]
state_before: case cons
α : Type u_1
p : α → Option α
head✝ : α
tail✝ : List α
ih : (∀ (a : α), a ∈ tail✝ → p a = none) → replaceF p tail✝ = tail✝
h : ∀ (a : α), a ∈ head✝ :: tail✝ → p a = none
⊢ replaceF p (head✝ :: tail✝) = head✝ :: tail✝
Theorem: Matrix.StdBasisMatrix.diag_same
File: Mathlib/Data/Matrix/Basis.lean

tactic: ext j
state_before: l : Type ?u.25244
m : Type ?u.25247
n : Type u_1
R : Type ?u.25253
α : Type u_2
inst✝³ : DecidableEq l
inst✝² : DecidableEq m
inst✝¹ : DecidableEq n
inst✝ : Semiring α
i j : n
c : α
i' j' : n
⊢ diag (stdBasisMatrix i i c) = Pi.single i c

tactic: by_cases hij : i = j <;> (try rw [hij]) <;> simp [hij]
state_before: case h
l : Type ?u.25244
m : Type ?u.25247
n : Type u_1
R : Type ?u.25253
α : Type u_2
inst✝³ : DecidableEq l
inst✝² : DecidableEq m
inst✝¹ : DecidableEq n
inst✝ : Semiring α
i j✝ : n
c : α
i' j' j : n
⊢ diag (stdBasisMatrix i i c) j = Pi.single i c j

tactic: try rw [hij]
state_before: case neg
l : Type ?u.25244
m : Type ?u.25247
n : Type u_1
R : Type ?u.25253
α : Type u_2
inst✝³ : DecidableEq l
inst✝² : DecidableEq m
inst✝¹ : DecidableEq n
inst✝ : Semiring α
i j✝ : n
c : α
i' j' j : n
hij : ¬i = j
⊢ diag (stdBasisMatrix i i c) j = Pi.single i c j

tactic: rw [hij]
state_before: case neg
l : Type ?u.25244
m : Type ?u.25247
n : Type u_1
R : Type ?u.25253
α : Type u_2
inst✝³ : DecidableEq l
inst✝² : DecidableEq m
inst✝¹ : DecidableEq n
inst✝ : Semiring α
i j✝ : n
c : α
i' j' j : n
hij : ¬i = j
⊢ diag (stdBasisMatrix i i c) j = Pi.single i c j
Theorem: RingHom.map_geom_sum₂
File: Mathlib/Algebra/GeomSum.lean

tactic: simp [f.map_sum]
state_before: α : Type u
β : Type u_1
inst✝¹ : Semiring α
inst✝ : Semiring β
x y : α
n : ℕ
f : α →+* β
⊢ ↑f (∑ i in range n, x ^ i * y ^ (n - 1 - i)) = ∑ i in range n, ↑f x ^ i * ↑f y ^ (n - 1 - i)
Theorem: Finsupp.prod_add_index
File: Mathlib/Algebra/BigOperators/Finsupp.lean

tactic: rw [Finsupp.prod_of_support_subset f (subset_union_left _ g.support) h h_zero,
  Finsupp.prod_of_support_subset g (subset_union_right f.support _) h h_zero, ←
  Finset.prod_mul_distrib, Finsupp.prod_of_support_subset (f + g) Finsupp.support_add h h_zero]
state_before: α : Type u_1
ι : Type ?u.333212
γ : Type ?u.333215
A : Type ?u.333218
B : Type ?u.333221
C : Type ?u.333224
inst✝⁵ : AddCommMonoid A
inst✝⁴ : AddCommMonoid B
inst✝³ : AddCommMonoid C
t : ι → A → C
h0 : ∀ (i : ι), t i 0 = 0
h1 : ∀ (i : ι) (x y : A), t i (x + y) = t i x + t i y
s : Finset α
f✝ : α → ι →₀ A
i : ι
g✝ : ι →₀ A
k : ι → A → γ → B
x : γ
β : Type ?u.336354
M : Type u_2
M' : Type ?u.336360
N : Type u_3
P : Type ?u.336366
G : Type ?u.336369
H : Type ?u.336372
R : Type ?u.336375
S : Type ?u.336378
inst✝² : DecidableEq α
inst✝¹ : AddZeroClass M
inst✝ : CommMonoid N
f g : α →₀ M
h : α → M → N
h_zero : ∀ (a : α), a ∈ f.support ∪ g.support → h a 0 = 1
h_add : ∀ (a : α), a ∈ f.support ∪ g.support → ∀ (b₁ b₂ : M), h a (b₁ + b₂) = h a b₁ * h a b₂
⊢ prod (f + g) h = prod f h * prod g h

tactic: exact Finset.prod_congr rfl fun x hx => by apply h_add x hx
state_before: α : Type u_1
ι : Type ?u.333212
γ : Type ?u.333215
A : Type ?u.333218
B : Type ?u.333221
C : Type ?u.333224
inst✝⁵ : AddCommMonoid A
inst✝⁴ : AddCommMonoid B
inst✝³ : AddCommMonoid C
t : ι → A → C
h0 : ∀ (i : ι), t i 0 = 0
h1 : ∀ (i : ι) (x y : A), t i (x + y) = t i x + t i y
s : Finset α
f✝ : α → ι →₀ A
i : ι
g✝ : ι →₀ A
k : ι → A → γ → B
x : γ
β : Type ?u.336354
M : Type u_2
M' : Type ?u.336360
N : Type u_3
P : Type ?u.336366
G : Type ?u.336369
H : Type ?u.336372
R : Type ?u.336375
S : Type ?u.336378
inst✝² : DecidableEq α
inst✝¹ : AddZeroClass M
inst✝ : CommMonoid N
f g : α →₀ M
h : α → M → N
h_zero : ∀ (a : α), a ∈ f.support ∪ g.support → h a 0 = 1
h_add : ∀ (a : α), a ∈ f.support ∪ g.support → ∀ (b₁ b₂ : M), h a (b₁ + b₂) = h a b₁ * h a b₂
⊢ ∏ x in f.support ∪ g.support, h x (↑(f + g) x) = ∏ x in f.support ∪ g.support, h x (↑f x) * h x (↑g x)

tactic: apply h_add x hx
state_before: α : Type u_1
ι : Type ?u.333212
γ : Type ?u.333215
A : Type ?u.333218
B : Type ?u.333221
C : Type ?u.333224
inst✝⁵ : AddCommMonoid A
inst✝⁴ : AddCommMonoid B
inst✝³ : AddCommMonoid C
t : ι → A → C
h0 : ∀ (i : ι), t i 0 = 0
h1 : ∀ (i : ι) (x y : A), t i (x + y) = t i x + t i y
s : Finset α
f✝ : α → ι →₀ A
i : ι
g✝ : ι →₀ A
k : ι → A → γ → B
x✝ : γ
β : Type ?u.336354
M : Type u_2
M' : Type ?u.336360
N : Type u_3
P : Type ?u.336366
G : Type ?u.336369
H : Type ?u.336372
R : Type ?u.336375
S : Type ?u.336378
inst✝² : DecidableEq α
inst✝¹ : AddZeroClass M
inst✝ : CommMonoid N
f g : α →₀ M
h : α → M → N
h_zero : ∀ (a : α), a ∈ f.support ∪ g.support → h a 0 = 1
h_add : ∀ (a : α), a ∈ f.support ∪ g.support → ∀ (b₁ b₂ : M), h a (b₁ + b₂) = h a b₁ * h a b₂
x : α
hx : x ∈ f.support ∪ g.support
⊢ h x (↑(f + g) x) = h x (↑f x) * h x (↑g x)
Theorem: Polynomial.roots_smul_nonzero
File: Mathlib/Data/Polynomial/RingDivision.lean

tactic: rw [smul_eq_C_mul, roots_C_mul _ ha]
state_before: R : Type u
S : Type v
T : Type w
a b : R
n : ℕ
inst✝¹ : CommRing R
inst✝ : IsDomain R
p✝ q p : R[X]
ha : a ≠ 0
⊢ roots (a • p) = roots p
Theorem: Polynomial.Chebyshev.T_derivative_eq_U
File: Mathlib/RingTheory/Polynomial/Chebyshev.lean

tactic: simp only [T_one, U_zero, derivative_X, Nat.cast_zero, zero_add, mul_one]
state_before: R : Type u_1
S : Type ?u.44951
inst✝¹ : CommRing R
inst✝ : CommRing S
⊢ ↑derivative (T R (0 + 1)) = (↑0 + 1) * U R 0

tactic: simp [T_two, U_one, derivative_sub, derivative_one, derivative_mul, derivative_X_pow, add_mul]
state_before: R : Type u_1
S : Type ?u.44951
inst✝¹ : CommRing R
inst✝ : CommRing S
⊢ ↑derivative (T R (1 + 1)) = (↑1 + 1) * U R 1

tactic: rw [T_add_two _ (n + 1), derivative_sub, derivative_mul, derivative_mul, derivative_X,
  derivative_ofNat]
state_before: R : Type u_1
S : Type ?u.44951
inst✝¹ : CommRing R
inst✝ : CommRing S
n : ℕ
⊢ ↑derivative (T R (n + 2 + 1)) = 2 * T R (n + 2) + 2 * X * ↑derivative (T R (n + 1 + 1)) - ↑derivative (T R (n + 1))

tactic: ring_nf
state_before: R : Type u_1
S : Type ?u.44951
inst✝¹ : CommRing R
inst✝ : CommRing S
n : ℕ
⊢ (0 * X + 2 * 1) * T R (n + 1 + 1) + 2 * X * ↑derivative (T R (n + 1 + 1)) - ↑derivative (T R (n + 1)) =
    2 * T R (n + 2) + 2 * X * ↑derivative (T R (n + 1 + 1)) - ↑derivative (T R (n + 1))

tactic: rw_mod_cast [T_derivative_eq_U (n + 1), T_derivative_eq_U n, T_eq_U_sub_X_mul_U _ (n + 1)]
state_before: R : Type u_1
S : Type ?u.44951
inst✝¹ : CommRing R
inst✝ : CommRing S
n : ℕ
⊢ 2 * T R (n + 2) + 2 * X * ↑derivative (T R (n + 1 + 1)) - ↑derivative (T R (n + 1)) =
    2 * (U R (n + 1 + 1) - X * U R (n + 1)) + 2 * X * ((↑n + 1 + 1) * U R (n + 1)) - (↑n + 1) * U R n

tactic: ring
state_before: R : Type u_1
S : Type ?u.44951
inst✝¹ : CommRing R
inst✝ : CommRing S
n : ℕ
⊢ 2 * (U R (n + 1 + 1) - X * U R (n + 1)) + 2 * X * ((↑n + 1 + 1) * U R (n + 1)) - (↑n + 1) * U R n =
    (↑n + 1) * (2 * X * U R (n + 1) - U R n) + 2 * U R (n + 2)

tactic: rw [U_add_two]
state_before: R : Type u_1
S : Type ?u.44951
inst✝¹ : CommRing R
inst✝ : CommRing S
n : ℕ
⊢ (↑n + 1) * (2 * X * U R (n + 1) - U R n) + 2 * U R (n + 2) = (↑n + 1) * U R (n + 2) + 2 * U R (n + 2)

tactic: ring
state_before: R : Type u_1
S : Type ?u.44951
inst✝¹ : CommRing R
inst✝ : CommRing S
n : ℕ
⊢ (↑n + 1) * U R (n + 2) + 2 * U R (n + 2) = (↑n + 2 + 1) * U R (n + 2)

tactic: norm_cast
state_before: R : Type u_1
S : Type ?u.44951
inst✝¹ : CommRing R
inst✝ : CommRing S
n : ℕ
⊢ (↑n + 2 + 1) * U R (n + 2) = (↑(n + 2) + 1) * U R (n + 2)
Theorem: IsCoprime.of_add_mul_right_left
File: Mathlib/RingTheory/Coprime/Basic.lean

tactic: rw [mul_comm] at h
state_before: R : Type u
inst✝ : CommSemiring R
x y z : R
h : IsCoprime (x + z * y) y
⊢ IsCoprime x y

tactic: exact h.of_add_mul_left_left
state_before: R : Type u
inst✝ : CommSemiring R
x y z : R
h : IsCoprime (x + y * z) y
⊢ IsCoprime x y
Theorem: Finsupp.card_Icc
File: Mathlib/Data/Finsupp/Interval.lean

tactic: simp_rw [icc_eq, card_finsupp, coe_rangeIcc]
state_before: ι : Type u_1
α : Type u_2
inst✝² : PartialOrder α
inst✝¹ : Zero α
inst✝ : LocallyFiniteOrder α
f g : ι →₀ α
⊢ card (Icc f g) = ∏ i in f.support ∪ g.support, card (Icc (↑f i) (↑g i))
Theorem: Set.Nontrivial.preimage
File: Mathlib/Data/Set/Image.lean

tactic: rcases hs with ⟨fx, hx, fy, hy, hxy⟩
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.102072
ι : Sort ?u.102075
ι' : Sort ?u.102078
s✝ : Set α
s : Set β
hs : Set.Nontrivial s
f : α → β
hf : Surjective f
⊢ Set.Nontrivial (f ⁻¹' s)

tactic: rcases hf fx, hf fy with ⟨⟨x, rfl⟩, ⟨y, rfl⟩⟩
state_before: case intro.intro.intro.intro
α : Type u_2
β : Type u_1
γ : Type ?u.102072
ι : Sort ?u.102075
ι' : Sort ?u.102078
s✝ : Set α
s : Set β
f : α → β
hf : Surjective f
fx : β
hx : fx ∈ s
fy : β
hy : fy ∈ s
hxy : fx ≠ fy
⊢ Set.Nontrivial (f ⁻¹' s)

tactic: exact ⟨x, hx, y, hy, mt (congr_arg f) hxy⟩
state_before: case intro.intro.intro.intro.intro.intro
α : Type u_2
β : Type u_1
γ : Type ?u.102072
ι : Sort ?u.102075
ι' : Sort ?u.102078
s✝ : Set α
s : Set β
f : α → β
hf : Surjective f
x : α
hx : f x ∈ s
y : α
hy : f y ∈ s
hxy : f x ≠ f y
⊢ Set.Nontrivial (f ⁻¹' s)
Theorem: Ordnode.Sized.rotateL_size
File: Mathlib/Data/Ordmap/Ordset.lean

tactic: cases r <;> simp [Ordnode.rotateL]
state_before: α : Type u_1
l : Ordnode α
x : α
r : Ordnode α
hm : Sized r
⊢ size (Ordnode.rotateL l x r) = size l + size r + 1

tactic: simp [size, hm.1]
state_before: case node
α : Type u_1
l : Ordnode α
x : α
size✝ : ℕ
l✝ : Ordnode α
x✝ : α
r✝ : Ordnode α
hm : Sized (node size✝ l✝ x✝ r✝)
⊢ size (if size l✝ < ratio * size r✝ then Ordnode.node3L l x l✝ x✝ r✝ else Ordnode.node4L l x l✝ x✝ r✝) =
    size l + size✝ + 1

tactic: split_ifs <;> simp [node3L_size, node4L_size hm.2.1] <;> abel
state_before: case node
α : Type u_1
l : Ordnode α
x : α
size✝ : ℕ
l✝ : Ordnode α
x✝ : α
r✝ : Ordnode α
hm : Sized (node size✝ l✝ x✝ r✝)
⊢ size (if size l✝ < ratio * size r✝ then Ordnode.node3L l x l✝ x✝ r✝ else Ordnode.node4L l x l✝ x✝ r✝) =
    size l + (size l✝ + size r✝ + 1) + 1
Theorem: continuousAt_iff_continuous_left'_right'
File: Mathlib/Topology/Algebra/Order/LeftRight.lean

tactic: rw [continuousWithinAt_Ioi_iff_Ici, continuousWithinAt_Iio_iff_Iic,
  continuousAt_iff_continuous_left_right]
state_before: α : Type u_1
β : Type u_2
inst✝² : TopologicalSpace α
inst✝¹ : LinearOrder α
inst✝ : TopologicalSpace β
a : α
f : α → β
⊢ ContinuousAt f a ↔ ContinuousWithinAt f (Iio a) a ∧ ContinuousWithinAt f (Ioi a) a
Theorem: Finset.filter_inter
File: Mathlib/Data/Finset/Basic.lean

tactic: ext
state_before: α : Type u_1
β : Type ?u.378112
γ : Type ?u.378115
p q : α → Prop
inst✝² : DecidablePred p
inst✝¹ : DecidablePred q
inst✝ : DecidableEq α
s t : Finset α
⊢ filter p s ∩ t = filter p (s ∩ t)

tactic: simp only [mem_inter, mem_filter, and_right_comm]
state_before: case a
α : Type u_1
β : Type ?u.378112
γ : Type ?u.378115
p q : α → Prop
inst✝² : DecidablePred p
inst✝¹ : DecidablePred q
inst✝ : DecidableEq α
s t : Finset α
a✝ : α
⊢ a✝ ∈ filter p s ∩ t ↔ a✝ ∈ filter p (s ∩ t)
Theorem: MeasureTheory.MeasurePreserving.lintegral_comp
File: Mathlib/MeasureTheory/Integral/Lebesgue.lean

tactic: rw [← hg.map_eq, lintegral_map hf hg.measurable]
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.1686621
δ : Type ?u.1686624
m : MeasurableSpace α
μ ν✝ : Measure α
mb : MeasurableSpace β
ν : Measure β
g : α → β
hg : MeasurePreserving g
f : β → ℝ≥0∞
hf : Measurable f
⊢ (∫⁻ (a : α), f (g a) ∂μ) = ∫⁻ (b : β), f b ∂ν
Theorem: Multiset.disjoint_ndinsert_left
File: Mathlib/Data/Multiset/FinsetOps.lean

tactic: simp [Disjoint]
state_before: α : Type u_1
inst✝ : DecidableEq α
s✝ : Multiset α
a : α
s t : Multiset α
⊢ Disjoint (ndinsert a s) t ↔ Disjoint (a ::ₘ s) t
Theorem: List.tfae_singleton
File: Mathlib/Data/List/TFAE.lean

tactic: simp [TFAE, -eq_iff_iff]
state_before: p : Prop
⊢ TFAE [p]
Theorem: NNReal.summable_nat_add_iff
File: Mathlib/Topology/Instances/NNReal.lean

tactic: rw [← summable_coe, ← summable_coe]
state_before: α : Type ?u.36846
f : ℕ → ℝ≥0
k : ℕ
⊢ (Summable fun i => f (i + k)) ↔ Summable f

tactic: exact @summable_nat_add_iff ℝ _ _ _ (fun i => (f i : ℝ)) k
state_before: α : Type ?u.36846
f : ℕ → ℝ≥0
k : ℕ
⊢ (Summable fun a => ↑(f (a + k))) ↔ Summable fun a => ↑(f a)