1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: MeasureTheory.ProbabilityMeasure.map_prod_map
File: Mathlib/MeasureTheory/Measure/FiniteMeasureProd.lean

tactic: apply Subtype.ext
state_before: α : Type u_1
inst✝³ : MeasurableSpace α
β : Type u_2
inst✝² : MeasurableSpace β
μ : ProbabilityMeasure α
ν : ProbabilityMeasure β
α' : Type u_3
inst✝¹ : MeasurableSpace α'
β' : Type u_4
inst✝ : MeasurableSpace β'
f : α → α'
g : β → β'
f_mble : Measurable f
g_mble : Measurable g
⊢ (μ.map ⋯).prod (ν.map ⋯) = (μ.prod ν).map ⋯
state_after: case a
α : Type u_1
inst✝³ : MeasurableSpace α
β : Type u_2
inst✝² : MeasurableSpace β
μ : ProbabilityMeasure α
ν : ProbabilityMeasure β
α' : Type u_3
inst✝¹ : MeasurableSpace α'
β' : Type u_4
inst✝ : MeasurableSpace β'
f : α → α'
g : β → β'
f_mble : Measurable f
g_mble : Measurable g
⊢ ↑((μ.map ⋯).prod (ν.map ⋯)) = ↑((μ.prod ν).map ⋯)

tactic: simp only [val_eq_to_measure, toMeasure_prod, toMeasure_map]
state_before: case a
α : Type u_1
inst✝³ : MeasurableSpace α
β : Type u_2
inst✝² : MeasurableSpace β
μ : ProbabilityMeasure α
ν : ProbabilityMeasure β
α' : Type u_3
inst✝¹ : MeasurableSpace α'
β' : Type u_4
inst✝ : MeasurableSpace β'
f : α → α'
g : β → β'
f_mble : Measurable f
g_mble : Measurable g
⊢ ↑((μ.map ⋯).prod (ν.map ⋯)) = ↑((μ.prod ν).map ⋯)
state_after: case a
α : Type u_1
inst✝³ : MeasurableSpace α
β : Type u_2
inst✝² : MeasurableSpace β
μ : ProbabilityMeasure α
ν : ProbabilityMeasure β
α' : Type u_3
inst✝¹ : MeasurableSpace α'
β' : Type u_4
inst✝ : MeasurableSpace β'
f : α → α'
g : β → β'
f_mble : Measurable f
g_mble : Measurable g
⊢ (Measure.map f ↑μ).prod (Measure.map g ↑ν) = Measure.map (Prod.map f g) ((↑μ).prod ↑ν)

tactic: rw [Measure.map_prod_map _ _ f_mble g_mble]
state_before: case a
α : Type u_1
inst✝³ : MeasurableSpace α
β : Type u_2
inst✝² : MeasurableSpace β
μ : ProbabilityMeasure α
ν : ProbabilityMeasure β
α' : Type u_3
inst✝¹ : MeasurableSpace α'
β' : Type u_4
inst✝ : MeasurableSpace β'
f : α → α'
g : β → β'
f_mble : Measurable f
g_mble : Measurable g
⊢ (Measure.map f ↑μ).prod (Measure.map g ↑ν) = Measure.map (Prod.map f g) ((↑μ).prod ↑ν)
state_after: no goals
Theorem: Nat.factorial_dvd_factorial
File: Mathlib/Data/Nat/Factorial/Basic.lean

tactic: induction' h with n _ ih
state_before: m✝ n✝ m n : ℕ
h : m ≤ n
⊢ m ! ∣ n !
state_after: case refl
m✝ n✝ m n : ℕ
⊢ m ! ∣ m !

case step
m✝ n✝¹ m n✝ n : ℕ
a✝ : m.le n
ih : m ! ∣ n !
⊢ m ! ∣ n.succ !

tactic: exact Nat.dvd_refl _
state_before: case refl
m✝ n✝ m n : ℕ
⊢ m ! ∣ m !
state_after: no goals

tactic: exact Nat.dvd_trans ih (Nat.dvd_mul_left _ _)
state_before: case step
m✝ n✝¹ m n✝ n : ℕ
a✝ : m.le n
ih : m ! ∣ n !
⊢ m ! ∣ n.succ !
state_after: no goals
Theorem: Batteries.RBSet.mem_toList_insert
File: .lake/packages/batteries/Batteries/Data/RBMap/Lemmas.lean

tactic: let ⟨ht₁, _, _, ht₂⟩ := t.2.out
state_before: α : Type u_1
cmp : α → α → Ordering
v' v : α
inst✝ : TransCmp cmp
t : RBSet α cmp
⊢ v' ∈ (t.insert v).toList ↔ v' ∈ t.toList ∧ t.find? v ≠ some v' ∨ v' = v
state_after: α : Type u_1
cmp : α → α → Ordering
v' v : α
inst✝ : TransCmp cmp
t : RBSet α cmp
ht₁ : RBNode.Ordered cmp t.val
w✝¹ : RBColor
w✝ : Nat
ht₂ : t.val.Balanced w✝¹ w✝
⊢ v' ∈ (t.insert v).toList ↔ v' ∈ t.toList ∧ t.find? v ≠ some v' ∨ v' = v

tactic: simpa [mem_toList] using RBNode.mem_insert ht₂ ht₁
state_before: α : Type u_1
cmp : α → α → Ordering
v' v : α
inst✝ : TransCmp cmp
t : RBSet α cmp
ht₁ : RBNode.Ordered cmp t.val
w✝¹ : RBColor
w✝ : Nat
ht₂ : t.val.Balanced w✝¹ w✝
⊢ v' ∈ (t.insert v).toList ↔ v' ∈ t.toList ∧ t.find? v ≠ some v' ∨ v' = v
state_after: no goals
Theorem: Finset.product_eq_biUnion_right
File: Mathlib/Data/Finset/Prod.lean

tactic: simp only [mem_product, mem_biUnion, mem_image, exists_prop, Prod.mk.inj_iff, and_left_comm,
  exists_and_left, exists_eq_right, exists_eq_left]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
s✝ s' : Finset α
t✝ t' : Finset β
a : α
b : β
inst✝ : DecidableEq (α × β)
s : Finset α
t : Finset β
x✝ : α × β
x : α
y : β
⊢ (x, y) ∈ s ×ˢ t ↔ (x, y) ∈ t.biUnion fun b => image (fun a => (a, b)) s
state_after: no goals
Theorem: CategoryTheory.ShortComplex.π_leftRightHomologyComparison'_ι
File: Mathlib/Algebra/Homology/ShortComplex/Homology.lean

tactic: simp only [leftRightHomologyComparison'_eq_liftH,
  RightHomologyData.liftH_ι, LeftHomologyData.π_descH]
state_before: C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : HasZeroMorphisms C
S S₁ S₂ S₃ S₄ : ShortComplex C
φ : S₁ ⟶ S₂
h₁✝ : S₁.HomologyData
h₂✝ : S₂.HomologyData
h₁ : S.LeftHomologyData
h₂ : S.RightHomologyData
⊢ h₁.π ≫ leftRightHomologyComparison' h₁ h₂ ≫ h₂.ι = h₁.i ≫ h₂.p
state_after: no goals
Theorem: conjugate_le_conjugate'
File: Mathlib/Algebra/Star/Order.lean

tactic: simpa only [star_star] using conjugate_le_conjugate hab (star c)
state_before: R : Type u
inst✝³ : NonUnitalSemiring R
inst✝² : PartialOrder R
inst✝¹ : StarRing R
inst✝ : StarOrderedRing R
a b : R
hab : a ≤ b
c : R
⊢ c * a * star c ≤ c * b * star c
state_after: no goals
Theorem: Bornology.IsVonNBounded.neg
File: Mathlib/Analysis/LocallyConvex/Bounded.lean

tactic: rw [← neg_neg U]
state_before: 𝕜 : Type u_1
𝕜' : Type u_2
E : Type u_3
E' : Type u_4
F : Type u_5
ι : Type u_6
inst✝⁴ : SeminormedRing 𝕜
inst✝³ : AddGroup E
inst✝² : TopologicalSpace E
inst✝¹ : TopologicalAddGroup E
inst✝ : DistribMulAction 𝕜 E
s t : Set E
hs : IsVonNBounded 𝕜 s
U : Set E
hU : U ∈ 𝓝 0
⊢ Absorbs 𝕜 U (-s)
state_after: 𝕜 : Type u_1
𝕜' : Type u_2
E : Type u_3
E' : Type u_4
F : Type u_5
ι : Type u_6
inst✝⁴ : SeminormedRing 𝕜
inst✝³ : AddGroup E
inst✝² : TopologicalSpace E
inst✝¹ : TopologicalAddGroup E
inst✝ : DistribMulAction 𝕜 E
s t : Set E
hs : IsVonNBounded 𝕜 s
U : Set E
hU : U ∈ 𝓝 0
⊢ Absorbs 𝕜 (- -U) (-s)

tactic: exact (hs <| neg_mem_nhds_zero _ hU).neg_neg
state_before: 𝕜 : Type u_1
𝕜' : Type u_2
E : Type u_3
E' : Type u_4
F : Type u_5
ι : Type u_6
inst✝⁴ : SeminormedRing 𝕜
inst✝³ : AddGroup E
inst✝² : TopologicalSpace E
inst✝¹ : TopologicalAddGroup E
inst✝ : DistribMulAction 𝕜 E
s t : Set E
hs : IsVonNBounded 𝕜 s
U : Set E
hU : U ∈ 𝓝 0
⊢ Absorbs 𝕜 (- -U) (-s)
state_after: no goals
Theorem: Real.toNNReal_div'
File: Mathlib/Data/NNReal/Basic.lean

tactic: rw [div_eq_inv_mul, div_eq_inv_mul, Real.toNNReal_mul (inv_nonneg.2 hy), Real.toNNReal_inv]
state_before: x y : ℝ
hy : 0 ≤ y
⊢ (x / y).toNNReal = x.toNNReal / y.toNNReal
state_after: no goals
Theorem: Rat.cast_mul_of_ne_zero
File: Mathlib/Data/Rat/Cast/Defs.lean

tactic: rw [mul_eq_mkRat, cast_mkRat_of_ne_zero, cast_def, cast_def,
  (Nat.commute_cast _ _).div_mul_div_comm (Int.commute_cast _ _)]
state_before: F : Type u_1
ι : Type u_2
α : Type u_3
β : Type u_4
inst✝ : DivisionRing α
p q : ℚ
hp : ↑p.den ≠ 0
hq : ↑q.den ≠ 0
⊢ ↑(p * q) = ↑p * ↑q
state_after: F : Type u_1
ι : Type u_2
α : Type u_3
β : Type u_4
inst✝ : DivisionRing α
p q : ℚ
hp : ↑p.den ≠ 0
hq : ↑q.den ≠ 0
⊢ ↑(p.num * q.num) / ↑(p.den * q.den) = ↑p.num * ↑q.num / (↑p.den * ↑q.den)

case hb
F : Type u_1
ι : Type u_2
α : Type u_3
β : Type u_4
inst✝ : DivisionRing α
p q : ℚ
hp : ↑p.den ≠ 0
hq : ↑q.den ≠ 0
⊢ ↑(p.den * q.den) ≠ 0

tactic: push_cast
state_before: F : Type u_1
ι : Type u_2
α : Type u_3
β : Type u_4
inst✝ : DivisionRing α
p q : ℚ
hp : ↑p.den ≠ 0
hq : ↑q.den ≠ 0
⊢ ↑(p.num * q.num) / ↑(p.den * q.den) = ↑p.num * ↑q.num / (↑p.den * ↑q.den)
state_after: F : Type u_1
ι : Type u_2
α : Type u_3
β : Type u_4
inst✝ : DivisionRing α
p q : ℚ
hp : ↑p.den ≠ 0
hq : ↑q.den ≠ 0
⊢ ↑p.num * ↑q.num / (↑p.den * ↑q.den) = ↑p.num * ↑q.num / (↑p.den * ↑q.den)

tactic: rfl
state_before: F : Type u_1
ι : Type u_2
α : Type u_3
β : Type u_4
inst✝ : DivisionRing α
p q : ℚ
hp : ↑p.den ≠ 0
hq : ↑q.den ≠ 0
⊢ ↑p.num * ↑q.num / (↑p.den * ↑q.den) = ↑p.num * ↑q.num / (↑p.den * ↑q.den)
state_after: no goals

tactic: push_cast
state_before: case hb
F : Type u_1
ι : Type u_2
α : Type u_3
β : Type u_4
inst✝ : DivisionRing α
p q : ℚ
hp : ↑p.den ≠ 0
hq : ↑q.den ≠ 0
⊢ ↑(p.den * q.den) ≠ 0
state_after: case hb
F : Type u_1
ι : Type u_2
α : Type u_3
β : Type u_4
inst✝ : DivisionRing α
p q : ℚ
hp : ↑p.den ≠ 0
hq : ↑q.den ≠ 0
⊢ ↑p.den * ↑q.den ≠ 0

tactic: exact mul_ne_zero hp hq
state_before: case hb
F : Type u_1
ι : Type u_2
α : Type u_3
β : Type u_4
inst✝ : DivisionRing α
p q : ℚ
hp : ↑p.den ≠ 0
hq : ↑q.den ≠ 0
⊢ ↑p.den * ↑q.den ≠ 0
state_after: no goals
Theorem: Real.rpow_lt_rpow_of_exponent_neg
File: Mathlib/Analysis/SpecialFunctions/Pow/Real.lean

tactic: have hx : 0 < x := hy.trans hxy
state_before: x✝ y✝ z✝ : ℝ
n : ℕ
x y z : ℝ
hy : 0 < y
hxy : y < x
hz : z < 0
⊢ x ^ z < y ^ z
state_after: x✝ y✝ z✝ : ℝ
n : ℕ
x y z : ℝ
hy : 0 < y
hxy : y < x
hz : z < 0
hx : 0 < x
⊢ x ^ z < y ^ z

tactic: rw [← neg_neg z, Real.rpow_neg (le_of_lt hx) (-z), Real.rpow_neg (le_of_lt hy) (-z),
    inv_lt_inv (rpow_pos_of_pos hx _) (rpow_pos_of_pos hy _)]
state_before: x✝ y✝ z✝ : ℝ
n : ℕ
x y z : ℝ
hy : 0 < y
hxy : y < x
hz : z < 0
hx : 0 < x
⊢ x ^ z < y ^ z
state_after: x✝ y✝ z✝ : ℝ
n : ℕ
x y z : ℝ
hy : 0 < y
hxy : y < x
hz : z < 0
hx : 0 < x
⊢ y ^ (-z) < x ^ (-z)

tactic: exact Real.rpow_lt_rpow (by positivity) hxy <| neg_pos_of_neg hz
state_before: x✝ y✝ z✝ : ℝ
n : ℕ
x y z : ℝ
hy : 0 < y
hxy : y < x
hz : z < 0
hx : 0 < x
⊢ y ^ (-z) < x ^ (-z)
state_after: no goals

tactic: positivity
state_before: x✝ y✝ z✝ : ℝ
n : ℕ
x y z : ℝ
hy : 0 < y
hxy : y < x
hz : z < 0
hx : 0 < x
⊢ 0 ≤ y
state_after: no goals
Theorem: Irrational.of_one_div
File: Mathlib/Data/Real/Irrational.lean

tactic: rwa [cast_one]
state_before: q : ℚ
x y : ℝ
h : Irrational (1 / x)
⊢ Irrational (↑1 / x)
state_after: no goals
Theorem: hasStrictFDerivAt_list_prod_finRange'
File: Mathlib/Analysis/Calculus/FDeriv/Mul.lean

tactic: simp
state_before: 𝕜 : Type u_1
inst✝¹² : NontriviallyNormedField 𝕜
E : Type u_2
inst✝¹¹ : NormedAddCommGroup E
inst✝¹⁰ : NormedSpace 𝕜 E
F : Type u_3
inst✝⁹ : NormedAddCommGroup F
inst✝⁸ : NormedSpace 𝕜 F
G : Type u_4
inst✝⁷ : NormedAddCommGroup G
inst✝⁶ : NormedSpace 𝕜 G
G' : Type u_5
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
ι : Type u_6
𝔸 : Type u_7
𝔸' : Type u_8
inst✝³ : NormedRing 𝔸
inst✝² : NormedCommRing 𝔸'
inst✝¹ : NormedAlgebra 𝕜 𝔸
inst✝ : NormedAlgebra 𝕜 𝔸'
u : Finset ι
f : ι → E → 𝔸
f' : ι → E →L[𝕜] 𝔸
g : ι → E → 𝔸'
g' : ι → E →L[𝕜] 𝔸'
n : ℕ
x : Fin n → 𝔸
⊢ ∀ (i : Fin (List.finRange n).length), i ∈ Finset.univ ↔ (finCongr ⋯) i ∈ Finset.univ
state_after: no goals

tactic: simp [Fin.forall_iff]
state_before: 𝕜 : Type u_1
inst✝¹² : NontriviallyNormedField 𝕜
E : Type u_2
inst✝¹¹ : NormedAddCommGroup E
inst✝¹⁰ : NormedSpace 𝕜 E
F : Type u_3
inst✝⁹ : NormedAddCommGroup F
inst✝⁸ : NormedSpace 𝕜 F
G : Type u_4
inst✝⁷ : NormedAddCommGroup G
inst✝⁶ : NormedSpace 𝕜 G
G' : Type u_5
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
ι : Type u_6
𝔸 : Type u_7
𝔸' : Type u_8
inst✝³ : NormedRing 𝔸
inst✝² : NormedCommRing 𝔸'
inst✝¹ : NormedAlgebra 𝕜 𝔸
inst✝ : NormedAlgebra 𝕜 𝔸'
u : Finset ι
f : ι → E → 𝔸
f' : ι → E →L[𝕜] 𝔸
g : ι → E → 𝔸'
g' : ι → E →L[𝕜] 𝔸'
n : ℕ
x : Fin n → 𝔸
⊢ ∀ i ∈ Finset.univ,
    (List.map x (List.take (↑i) (List.finRange n))).prod •
        (proj ((List.finRange n).get i)).smulRight (List.map x (List.drop (↑i).succ (List.finRange n))).prod =
      (List.map x (List.take (↑((finCongr ⋯) i)) (List.finRange n))).prod •
        (proj ((finCongr ⋯) i)).smulRight (List.map x (List.drop (↑((finCongr ⋯) i)).succ (List.finRange n))).prod
state_after: no goals
Theorem: linearIndependent_le_span
File: Mathlib/LinearAlgebra/Dimension/StrongRankCondition.lean

tactic: apply linearIndependent_le_span' v i w
state_before: R : Type u
M : Type v
inst✝⁴ : Ring R
inst✝³ : AddCommGroup M
inst✝² : Module R M
ι✝ : Type w
ι' : Type w'
inst✝¹ : StrongRankCondition R
ι : Type u_1
v : ι → M
i : LinearIndependent R v
w : Set M
inst✝ : Fintype ↑w
s : span R w = ⊤
⊢ #ι ≤ ↑(Fintype.card ↑w)
state_after: R : Type u
M : Type v
inst✝⁴ : Ring R
inst✝³ : AddCommGroup M
inst✝² : Module R M
ι✝ : Type w
ι' : Type w'
inst✝¹ : StrongRankCondition R
ι : Type u_1
v : ι → M
i : LinearIndependent R v
w : Set M
inst✝ : Fintype ↑w
s : span R w = ⊤
⊢ range v ≤ ↑(span R w)

tactic: rw [s]
state_before: R : Type u
M : Type v
inst✝⁴ : Ring R
inst✝³ : AddCommGroup M
inst✝² : Module R M
ι✝ : Type w
ι' : Type w'
inst✝¹ : StrongRankCondition R
ι : Type u_1
v : ι → M
i : LinearIndependent R v
w : Set M
inst✝ : Fintype ↑w
s : span R w = ⊤
⊢ range v ≤ ↑(span R w)
state_after: R : Type u
M : Type v
inst✝⁴ : Ring R
inst✝³ : AddCommGroup M
inst✝² : Module R M
ι✝ : Type w
ι' : Type w'
inst✝¹ : StrongRankCondition R
ι : Type u_1
v : ι → M
i : LinearIndependent R v
w : Set M
inst✝ : Fintype ↑w
s : span R w = ⊤
⊢ range v ≤ ↑⊤

tactic: exact le_top
state_before: R : Type u
M : Type v
inst✝⁴ : Ring R
inst✝³ : AddCommGroup M
inst✝² : Module R M
ι✝ : Type w
ι' : Type w'
inst✝¹ : StrongRankCondition R
ι : Type u_1
v : ι → M
i : LinearIndependent R v
w : Set M
inst✝ : Fintype ↑w
s : span R w = ⊤
⊢ range v ≤ ↑⊤
state_after: no goals
Theorem: ContinuousInv.of_nhds_one
File: Mathlib/Topology/Algebra/Group/Basic.lean

tactic: refine ⟨continuous_iff_continuousAt.2 fun x₀ => ?_⟩
state_before: G✝ : Type w
H : Type x
α : Type u
β : Type v
inst✝⁵ : TopologicalSpace G✝
inst✝⁴ : Group G✝
inst✝³ : TopologicalGroup G✝
inst✝² : TopologicalSpace α
f : α → G✝
s : Set α
x : α
G : Type u_1
inst✝¹ : Group G
inst✝ : TopologicalSpace G
hinv : Tendsto (fun x => x⁻¹) (𝓝 1) (𝓝 1)
hleft : ∀ (x₀ : G), 𝓝 x₀ = map (fun x => x₀ * x) (𝓝 1)
hconj : ∀ (x₀ : G), Tendsto (fun x => x₀ * x * x₀⁻¹) (𝓝 1) (𝓝 1)
⊢ ContinuousInv G
state_after: G✝ : Type w
H : Type x
α : Type u
β : Type v
inst✝⁵ : TopologicalSpace G✝
inst✝⁴ : Group G✝
inst✝³ : TopologicalGroup G✝
inst✝² : TopologicalSpace α
f : α → G✝
s : Set α
x : α
G : Type u_1
inst✝¹ : Group G
inst✝ : TopologicalSpace G
hinv : Tendsto (fun x => x⁻¹) (𝓝 1) (𝓝 1)
hleft : ∀ (x₀ : G), 𝓝 x₀ = map (fun x => x₀ * x) (𝓝 1)
hconj : ∀ (x₀ : G), Tendsto (fun x => x₀ * x * x₀⁻¹) (𝓝 1) (𝓝 1)
x₀ : G
⊢ ContinuousAt (fun a => a⁻¹) x₀
Theorem: CategoryTheory.MonoidalFunctor.map_whiskerLeft
File: Mathlib/CategoryTheory/Monoidal/Functor.lean

tactic: simp
state_before: C : Type u₁
inst✝³ : Category.{v₁, u₁} C
inst✝² : MonoidalCategory C
D : Type u₂
inst✝¹ : Category.{v₂, u₂} D
inst✝ : MonoidalCategory D
F : MonoidalFunctor C D
X Y Z : C
f : Y ⟶ Z
⊢ F.map (X ◁ f) = inv (F.μ X Y) ≫ F.obj X ◁ F.map f ≫ F.μ X Z
state_after: no goals
Theorem: symmDiff_sdiff
File: Mathlib/Order/SymmDiff.lean

tactic: rw [symmDiff, sup_sdiff_distrib, sdiff_sdiff_left, sdiff_sdiff_left]
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
π : ι → Type u_4
inst✝ : GeneralizedCoheytingAlgebra α
a b c d : α
⊢ a ∆ b \ c = a \ (b ⊔ c) ⊔ b \ (a ⊔ c)
state_after: no goals
Theorem: List.sum_nat_mod
File: Mathlib/Algebra/BigOperators/Group/List.lean

tactic: induction' l with a l ih
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
M : Type u_4
N : Type u_5
P : Type u_6
G : Type u_7
l : List ℕ
n : ℕ
⊢ l.sum % n = (map (fun x => x % n) l).sum % n
state_after: case nil
ι : Type u_1
α : Type u_2
β : Type u_3
M : Type u_4
N : Type u_5
P : Type u_6
G : Type u_7
n : ℕ
⊢ [].sum % n = (map (fun x => x % n) []).sum % n

case cons
ι : Type u_1
α : Type u_2
β : Type u_3
M : Type u_4
N : Type u_5
P : Type u_6
G : Type u_7
n a : ℕ
l : List ℕ
ih : l.sum % n = (map (fun x => x % n) l).sum % n
⊢ (a :: l).sum % n = (map (fun x => x % n) (a :: l)).sum % n

tactic: simp only [Nat.zero_mod, map_nil]
state_before: case nil
ι : Type u_1
α : Type u_2
β : Type u_3
M : Type u_4
N : Type u_5
P : Type u_6
G : Type u_7
n : ℕ
⊢ [].sum % n = (map (fun x => x % n) []).sum % n
state_after: no goals

tactic: simpa only [map_cons, sum_cons, Nat.mod_add_mod, Nat.add_mod_mod] using congr((a + $ih) % n)
state_before: case cons
ι : Type u_1
α : Type u_2
β : Type u_3
M : Type u_4
N : Type u_5
P : Type u_6
G : Type u_7
n a : ℕ
l : List ℕ
ih : l.sum % n = (map (fun x => x % n) l).sum % n
⊢ (a :: l).sum % n = (map (fun x => x % n) (a :: l)).sum % n
state_after: no goals
Theorem: CategoryTheory.Presheaf.isSheaf_coherent_iff_regular_and_extensive
File: Mathlib/CategoryTheory/Sites/Coherent/SheafComparison.lean

tactic: rw [← extensive_regular_generate_coherent]
state_before: C : Type u_1
D : Type u_2
inst✝⁴ : Category.{u_3, u_1} C
inst✝³ : Category.{?u.40938, u_2} D
F✝ : C ⥤ D
A : Type u₃
inst✝² : Category.{v₃, u₃} A
F : Cᵒᵖ ⥤ A
inst✝¹ : Preregular C
inst✝ : FinitaryPreExtensive C
⊢ IsSheaf (coherentTopology C) F ↔ IsSheaf (extensiveTopology C) F ∧ IsSheaf (regularTopology C) F
state_after: C : Type u_1
D : Type u_2
inst✝⁴ : Category.{u_3, u_1} C
inst✝³ : Category.{?u.40938, u_2} D
F✝ : C ⥤ D
A : Type u₃
inst✝² : Category.{v₃, u₃} A
F : Cᵒᵖ ⥤ A
inst✝¹ : Preregular C
inst✝ : FinitaryPreExtensive C
⊢ IsSheaf (Coverage.toGrothendieck C (extensiveCoverage C ⊔ regularCoverage C)) F ↔
    IsSheaf (extensiveTopology C) F ∧ IsSheaf (regularTopology C) F

tactic: exact isSheaf_sup (extensiveCoverage C) (regularCoverage C) F
state_before: C : Type u_1
D : Type u_2
inst✝⁴ : Category.{u_3, u_1} C
inst✝³ : Category.{?u.40938, u_2} D
F✝ : C ⥤ D
A : Type u₃
inst✝² : Category.{v₃, u₃} A
F : Cᵒᵖ ⥤ A
inst✝¹ : Preregular C
inst✝ : FinitaryPreExtensive C
⊢ IsSheaf (Coverage.toGrothendieck C (extensiveCoverage C ⊔ regularCoverage C)) F ↔
    IsSheaf (extensiveTopology C) F ∧ IsSheaf (regularTopology C) F
state_after: no goals
Theorem: Complex.sinh_two_mul
File: Mathlib/Data/Complex/Exponential.lean

tactic: rw [two_mul, sinh_add]
state_before: x y : ℂ
⊢ sinh (2 * x) = 2 * sinh x * cosh x
state_after: x y : ℂ
⊢ sinh x * cosh x + cosh x * sinh x = 2 * sinh x * cosh x

tactic: ring
state_before: x y : ℂ
⊢ sinh x * cosh x + cosh x * sinh x = 2 * sinh x * cosh x
state_after: no goals
Theorem: ContDiffBump.one_lt_rOut_div_rIn
File: Mathlib/Analysis/Calculus/BumpFunction/Basic.lean

tactic: rw [one_lt_div f.rIn_pos]
state_before: E : Type u_1
X : Type u_2
c : E
f : ContDiffBump c
⊢ 1 < f.rOut / f.rIn
state_after: E : Type u_1
X : Type u_2
c : E
f : ContDiffBump c
⊢ f.rIn < f.rOut

tactic: exact f.rIn_lt_rOut
state_before: E : Type u_1
X : Type u_2
c : E
f : ContDiffBump c
⊢ f.rIn < f.rOut
state_after: no goals
Theorem: Set.image_update_Ioo_right
File: Mathlib/Order/Interval/Set/Pi.lean

tactic: simpa using image_update_Ioo f i (f i) b
state_before: ι : Type u_1
α : ι → Type u_2
inst✝¹ : DecidableEq ι
inst✝ : (i : ι) → PartialOrder (α i)
f : (i : ι) → α i
i : ι
b : α i
⊢ update f i '' Ioo (f i) b = Ioo f (update f i b)
state_after: no goals
Theorem: CategoryTheory.Projective.projective_iff_preservesEpimorphisms_preadditiveCoyoneda_obj
File: Mathlib/CategoryTheory/Preadditive/Yoneda/Projective.lean

tactic: rw [projective_iff_preservesEpimorphisms_coyoneda_obj]
state_before: C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : Preadditive C
P : C
⊢ Projective P ↔ (preadditiveCoyoneda.obj { unop := P }).PreservesEpimorphisms
state_after: C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : Preadditive C
P : C
⊢ (coyoneda.obj { unop := P }).PreservesEpimorphisms ↔ (preadditiveCoyoneda.obj { unop := P }).PreservesEpimorphisms

tactic: refine ⟨fun h : (preadditiveCoyoneda.obj (op P) ⋙
    forget AddCommGrp).PreservesEpimorphisms => ?_, ?_⟩
state_before: C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : Preadditive C
P : C
⊢ (coyoneda.obj { unop := P }).PreservesEpimorphisms ↔ (preadditiveCoyoneda.obj { unop := P }).PreservesEpimorphisms
state_after: case refine_1
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : Preadditive C
P : C
h : (preadditiveCoyoneda.obj { unop := P } ⋙ forget AddCommGrp).PreservesEpimorphisms
⊢ (preadditiveCoyoneda.obj { unop := P }).PreservesEpimorphisms

case refine_2
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : Preadditive C
P : C
⊢ (preadditiveCoyoneda.obj { unop := P }).PreservesEpimorphisms → (coyoneda.obj { unop := P }).PreservesEpimorphisms

tactic: exact Functor.preservesEpimorphisms_of_preserves_of_reflects (preadditiveCoyoneda.obj (op P))
    (forget _)
state_before: case refine_1
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : Preadditive C
P : C
h : (preadditiveCoyoneda.obj { unop := P } ⋙ forget AddCommGrp).PreservesEpimorphisms
⊢ (preadditiveCoyoneda.obj { unop := P }).PreservesEpimorphisms
state_after: no goals

tactic: intro
state_before: case refine_2
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : Preadditive C
P : C
⊢ (preadditiveCoyoneda.obj { unop := P }).PreservesEpimorphisms → (coyoneda.obj { unop := P }).PreservesEpimorphisms
state_after: case refine_2
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : Preadditive C
P : C
a✝ : (preadditiveCoyoneda.obj { unop := P }).PreservesEpimorphisms
⊢ (coyoneda.obj { unop := P }).PreservesEpimorphisms

tactic: exact (inferInstance : (preadditiveCoyoneda.obj (op P) ⋙ forget _).PreservesEpimorphisms)
state_before: case refine_2
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : Preadditive C
P : C
a✝ : (preadditiveCoyoneda.obj { unop := P }).PreservesEpimorphisms
⊢ (coyoneda.obj { unop := P }).PreservesEpimorphisms
state_after: no goals
Theorem: ENNReal.mul_lt_of_lt_div
File: Mathlib/Data/ENNReal/Inv.lean

tactic: contrapose! h
state_before: a b c d : ℝ≥0∞
r p q : ℝ≥0
h : a < b / c
⊢ a * c < b
state_after: a b c d : ℝ≥0∞
r p q : ℝ≥0
h : b ≤ a * c
⊢ b / c ≤ a

tactic: exact ENNReal.div_le_of_le_mul h
state_before: a b c d : ℝ≥0∞
r p q : ℝ≥0
h : b ≤ a * c
⊢ b / c ≤ a
state_after: no goals
Theorem: Complex.exp_ne_zero
File: Mathlib/Data/Complex/Exponential.lean

tactic: rw [← exp_zero, ← add_neg_self x, exp_add, h]
state_before: x y : ℂ
h : cexp x = 0
⊢ 0 = 1
state_after: x y : ℂ
h : cexp x = 0
⊢ x + -x = 0 * cexp (-x)

tactic: simp
state_before: x y : ℂ
h : cexp x = 0
⊢ x + -x = 0 * cexp (-x)
state_after: no goals
Theorem: Polynomial.leadingCoeff_divByMonic_X_sub_C
File: Mathlib/Algebra/Polynomial/RingDivision.lean

tactic: nontriviality
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]
hp : p.degree ≠ 0
a : R
⊢ (p /ₘ (X - C a)).leadingCoeff = p.leadingCoeff
state_after: R : Type u
S : Type v
T : Type w
a✝ b : R
n : ℕ
inst✝² : CommRing R
inst✝¹ : IsDomain R
p✝ q p : R[X]
hp : p.degree ≠ 0
a : R
inst✝ : Nontrivial R
⊢ (p /ₘ (X - C a)).leadingCoeff = p.leadingCoeff

tactic: cases' hp.lt_or_lt with hd hd
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]
hp : p.degree ≠ 0
a : R
inst✝ : Nontrivial R
⊢ (p /ₘ (X - C a)).leadingCoeff = p.leadingCoeff
state_after: case inl
R : Type u
S : Type v
T : Type w
a✝ b : R
n : ℕ
inst✝² : CommRing R
inst✝¹ : IsDomain R
p✝ q p : R[X]
hp : p.degree ≠ 0
a : R
inst✝ : Nontrivial R
hd : p.degree < 0
⊢ (p /ₘ (X - C a)).leadingCoeff = p.leadingCoeff

case inr
R : Type u
S : Type v
T : Type w
a✝ b : R
n : ℕ
inst✝² : CommRing R
inst✝¹ : IsDomain R
p✝ q p : R[X]
hp : p.degree ≠ 0
a : R
inst✝ : Nontrivial R
hd : 0 < p.degree
⊢ (p /ₘ (X - C a)).leadingCoeff = p.leadingCoeff

tactic: refine leadingCoeff_divByMonic_of_monic (monic_X_sub_C a) ?_
state_before: case inr
R : Type u
S : Type v
T : Type w
a✝ b : R
n : ℕ
inst✝² : CommRing R
inst✝¹ : IsDomain R
p✝ q p : R[X]
hp : p.degree ≠ 0
a : R
inst✝ : Nontrivial R
hd : 0 < p.degree
⊢ (p /ₘ (X - C a)).leadingCoeff = p.leadingCoeff
state_after: case inr
R : Type u
S : Type v
T : Type w
a✝ b : R
n : ℕ
inst✝² : CommRing R
inst✝¹ : IsDomain R
p✝ q p : R[X]
hp : p.degree ≠ 0
a : R
inst✝ : Nontrivial R
hd : 0 < p.degree
⊢ (X - C a).degree ≤ p.degree

tactic: rwa [degree_X_sub_C, Nat.WithBot.one_le_iff_zero_lt]
state_before: case inr
R : Type u
S : Type v
T : Type w
a✝ b : R
n : ℕ
inst✝² : CommRing R
inst✝¹ : IsDomain R
p✝ q p : R[X]
hp : p.degree ≠ 0
a : R
inst✝ : Nontrivial R
hd : 0 < p.degree
⊢ (X - C a).degree ≤ p.degree
state_after: no goals

tactic: rw [degree_eq_bot.mp <| Nat.WithBot.lt_zero_iff.mp hd, zero_divByMonic]
state_before: case inl
R : Type u
S : Type v
T : Type w
a✝ b : R
n : ℕ
inst✝² : CommRing R
inst✝¹ : IsDomain R
p✝ q p : R[X]
hp : p.degree ≠ 0
a : R
inst✝ : Nontrivial R
hd : p.degree < 0
⊢ (p /ₘ (X - C a)).leadingCoeff = p.leadingCoeff
state_after: no goals
Theorem: mul_zpow_neg_one
File: Mathlib/Algebra/Group/Basic.lean

tactic: simp only [zpow_neg, zpow_one, mul_inv_rev]
state_before: α : Type u_1
β : Type u_2
G : Type u_3
M : Type u_4
inst✝ : DivisionMonoid α
a✝ b✝ c d a b : α
⊢ (a * b) ^ (-1) = b ^ (-1) * a ^ (-1)
state_after: no goals