1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: integral_log
File: Mathlib/Analysis/SpecialFunctions/Integrals.lean

tactic: have h' := fun x (hx : x ∈ [[a, b]]) => ne_of_mem_of_not_mem hx h
state_before: a b : ℝ
n : ℕ
h : 0 ∉ [[a, b]]
⊢ ∫ (x : ℝ) in a..b, Real.log x = b * Real.log b - a * Real.log a - b + a
state_after: a b : ℝ
n : ℕ
h : 0 ∉ [[a, b]]
h' : ∀ x ∈ [[a, b]], x ≠ 0
⊢ ∫ (x : ℝ) in a..b, Real.log x = b * Real.log b - a * Real.log a - b + a

tactic: have heq := fun x hx => mul_inv_cancel (h' x hx)
state_before: a b : ℝ
n : ℕ
h : 0 ∉ [[a, b]]
h' : ∀ x ∈ [[a, b]], x ≠ 0
⊢ ∫ (x : ℝ) in a..b, Real.log x = b * Real.log b - a * Real.log a - b + a
state_after: a b : ℝ
n : ℕ
h : 0 ∉ [[a, b]]
h' : ∀ x ∈ [[a, b]], x ≠ 0
heq : ∀ x ∈ [[a, b]], x * x⁻¹ = 1
⊢ ∫ (x : ℝ) in a..b, Real.log x = b * Real.log b - a * Real.log a - b + a

tactic: convert integral_mul_deriv_eq_deriv_mul (fun x hx => hasDerivAt_log (h' x hx))
  (fun x _ => hasDerivAt_id x) (continuousOn_inv₀.mono <|
    subset_compl_singleton_iff.mpr h).intervalIntegrable
      continuousOn_const.intervalIntegrable using 1 <;>
simp [integral_congr heq, mul_comm, ← sub_add]
state_before: a b : ℝ
n : ℕ
h : 0 ∉ [[a, b]]
h' : ∀ x ∈ [[a, b]], x ≠ 0
heq : ∀ x ∈ [[a, b]], x * x⁻¹ = 1
⊢ ∫ (x : ℝ) in a..b, Real.log x = b * Real.log b - a * Real.log a - b + a
state_after: no goals
Theorem: AddMonoidHom.coe_addMonoidHom_mkRingHomOfMulSelfOfTwoNeZero
File: Mathlib/Algebra/Ring/Hom/Defs.lean

tactic: ext
state_before: F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
inst✝² : CommRing α
inst✝¹ : IsDomain α
inst✝ : CommRing β
f : β →+ α
h : ∀ (x : β), f (x * x) = f x * f x
h_two : 2 ≠ 0
h_one : f 1 = 1
⊢ ↑(f.mkRingHomOfMulSelfOfTwoNeZero h h_two h_one) = f
state_after: case h
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
inst✝² : CommRing α
inst✝¹ : IsDomain α
inst✝ : CommRing β
f : β →+ α
h : ∀ (x : β), f (x * x) = f x * f x
h_two : 2 ≠ 0
h_one : f 1 = 1
x✝ : β
⊢ ↑(f.mkRingHomOfMulSelfOfTwoNeZero h h_two h_one) x✝ = f x✝

tactic: rfl
state_before: case h
F : Type u_1
α : Type u_2
β : Type u_3
γ : Type u_4
inst✝² : CommRing α
inst✝¹ : IsDomain α
inst✝ : CommRing β
f : β →+ α
h : ∀ (x : β), f (x * x) = f x * f x
h_two : 2 ≠ 0
h_one : f 1 = 1
x✝ : β
⊢ ↑(f.mkRingHomOfMulSelfOfTwoNeZero h h_two h_one) x✝ = f x✝
state_after: no goals
Theorem: Orientation.norm_div_tan_oangle_add_right_of_oangle_eq_pi_div_two
File: Mathlib/Geometry/Euclidean/Angle/Oriented/RightAngle.lean

tactic: have hs : (o.oangle x (x + y)).sign = 1 := by
  rw [oangle_sign_add_right, h, Real.Angle.sign_coe_pi_div_two]
state_before: V : Type u_1
inst✝¹ : NormedAddCommGroup V
inst✝ : InnerProductSpace ℝ V
hd2 : Fact (finrank ℝ V = 2)
o : Orientation ℝ V (Fin 2)
x y : V
h : o.oangle x y = ↑(π / 2)
⊢ ‖y‖ / (o.oangle x (x + y)).tan = ‖x‖
state_after: V : Type u_1
inst✝¹ : NormedAddCommGroup V
inst✝ : InnerProductSpace ℝ V
hd2 : Fact (finrank ℝ V = 2)
o : Orientation ℝ V (Fin 2)
x y : V
h : o.oangle x y = ↑(π / 2)
hs : (o.oangle x (x + y)).sign = 1
⊢ ‖y‖ / (o.oangle x (x + y)).tan = ‖x‖

tactic: rw [o.oangle_eq_angle_of_sign_eq_one hs, Real.Angle.tan_coe,
  InnerProductGeometry.norm_div_tan_angle_add_of_inner_eq_zero
    (o.inner_eq_zero_of_oangle_eq_pi_div_two h)
    (Or.inr (o.right_ne_zero_of_oangle_eq_pi_div_two h))]
state_before: V : Type u_1
inst✝¹ : NormedAddCommGroup V
inst✝ : InnerProductSpace ℝ V
hd2 : Fact (finrank ℝ V = 2)
o : Orientation ℝ V (Fin 2)
x y : V
h : o.oangle x y = ↑(π / 2)
hs : (o.oangle x (x + y)).sign = 1
⊢ ‖y‖ / (o.oangle x (x + y)).tan = ‖x‖
state_after: no goals

tactic: rw [oangle_sign_add_right, h, Real.Angle.sign_coe_pi_div_two]
state_before: V : Type u_1
inst✝¹ : NormedAddCommGroup V
inst✝ : InnerProductSpace ℝ V
hd2 : Fact (finrank ℝ V = 2)
o : Orientation ℝ V (Fin 2)
x y : V
h : o.oangle x y = ↑(π / 2)
⊢ (o.oangle x (x + y)).sign = 1
state_after: no goals
Theorem: Matrix.IsDiag.add
File: Mathlib/LinearAlgebra/Matrix/IsDiag.lean

tactic: intro i j h
state_before: α : Type u_1
β : Type u_2
R : Type u_3
n : Type u_4
m : Type u_5
inst✝ : AddZeroClass α
A B : Matrix n n α
ha : A.IsDiag
hb : B.IsDiag
⊢ (A + B).IsDiag
state_after: α : Type u_1
β : Type u_2
R : Type u_3
n : Type u_4
m : Type u_5
inst✝ : AddZeroClass α
A B : Matrix n n α
ha : A.IsDiag
hb : B.IsDiag
i j : n
h : i ≠ j
⊢ (A + B) i j = 0

tactic: simp [ha h, hb h]
state_before: α : Type u_1
β : Type u_2
R : Type u_3
n : Type u_4
m : Type u_5
inst✝ : AddZeroClass α
A B : Matrix n n α
ha : A.IsDiag
hb : B.IsDiag
i j : n
h : i ≠ j
⊢ (A + B) i j = 0
state_after: no goals
Theorem: AlgHom.ofLinearMap_toLinearMap
File: Mathlib/Algebra/Algebra/Hom.lean

tactic: ext
state_before: R : Type u
A : Type v
B : Type w
C : Type u₁
D : Type v₁
inst✝⁸ : CommSemiring R
inst✝⁷ : Semiring A
inst✝⁶ : Semiring B
inst✝⁵ : Semiring C
inst✝⁴ : Semiring D
inst✝³ : Algebra R A
inst✝² : Algebra R B
inst✝¹ : Algebra R C
inst✝ : Algebra R D
φ : A →ₐ[R] B
map_one : φ.toLinearMap 1 = 1
map_mul : ∀ (x y : A), φ.toLinearMap (x * y) = φ.toLinearMap x * φ.toLinearMap y
⊢ ofLinearMap φ.toLinearMap map_one map_mul = φ
state_after: case H
R : Type u
A : Type v
B : Type w
C : Type u₁
D : Type v₁
inst✝⁸ : CommSemiring R
inst✝⁷ : Semiring A
inst✝⁶ : Semiring B
inst✝⁵ : Semiring C
inst✝⁴ : Semiring D
inst✝³ : Algebra R A
inst✝² : Algebra R B
inst✝¹ : Algebra R C
inst✝ : Algebra R D
φ : A →ₐ[R] B
map_one : φ.toLinearMap 1 = 1
map_mul : ∀ (x y : A), φ.toLinearMap (x * y) = φ.toLinearMap x * φ.toLinearMap y
x✝ : A
⊢ (ofLinearMap φ.toLinearMap map_one map_mul) x✝ = φ x✝

tactic: rfl
state_before: case H
R : Type u
A : Type v
B : Type w
C : Type u₁
D : Type v₁
inst✝⁸ : CommSemiring R
inst✝⁷ : Semiring A
inst✝⁶ : Semiring B
inst✝⁵ : Semiring C
inst✝⁴ : Semiring D
inst✝³ : Algebra R A
inst✝² : Algebra R B
inst✝¹ : Algebra R C
inst✝ : Algebra R D
φ : A →ₐ[R] B
map_one : φ.toLinearMap 1 = 1
map_mul : ∀ (x y : A), φ.toLinearMap (x * y) = φ.toLinearMap x * φ.toLinearMap y
x✝ : A
⊢ (ofLinearMap φ.toLinearMap map_one map_mul) x✝ = φ x✝
state_after: no goals
Theorem: MeasureTheory.SimpleFunc.setToSimpleFunc_zero_apply
File: Mathlib/MeasureTheory/Integral/SetToL1.lean

tactic: cases isEmpty_or_nonempty α <;> simp [setToSimpleFunc]
state_before: α : Type u_1
E : Type u_2
F : Type u_3
F' : Type u_4
G : Type u_5
𝕜 : Type u_6
p : ℝ≥0∞
inst✝⁶ : NormedAddCommGroup E
inst✝⁵ : NormedSpace ℝ E
inst✝⁴ : NormedAddCommGroup F
inst✝³ : NormedSpace ℝ F
inst✝² : NormedAddCommGroup F'
inst✝¹ : NormedSpace ℝ F'
inst✝ : NormedAddCommGroup G
m✝ : MeasurableSpace α
μ : Measure α
m : MeasurableSpace α
T : Set α → F →L[ℝ] F'
⊢ setToSimpleFunc T 0 = 0
state_after: no goals
Theorem: IsCompl.disjoint_left_iff
File: Mathlib/Order/Disjoint.lean

tactic: rw [disjoint_iff]
state_before: α : Type u_1
inst✝¹ : DistribLattice α
inst✝ : BoundedOrder α
a b x y z : α
h : IsCompl y z
⊢ Disjoint x y ↔ x ≤ z
state_after: α : Type u_1
inst✝¹ : DistribLattice α
inst✝ : BoundedOrder α
a b x y z : α
h : IsCompl y z
⊢ x ⊓ y = ⊥ ↔ x ≤ z

tactic: exact h.inf_left_eq_bot_iff
state_before: α : Type u_1
inst✝¹ : DistribLattice α
inst✝ : BoundedOrder α
a b x y z : α
h : IsCompl y z
⊢ x ⊓ y = ⊥ ↔ x ≤ z
state_after: no goals
Theorem: Ordinal.principal_mul_omega
File: Mathlib/SetTheory/Ordinal/Principal.lean

tactic: dsimp only
state_before: a b : Ordinal.{u_1}
m n : ℕ
ha : ↑m < ω
hb : ↑n < ω
⊢ (fun x x_1 => x * x_1) ↑m ↑n < ω
state_after: a b : Ordinal.{u_1}
m n : ℕ
ha : ↑m < ω
hb : ↑n < ω
⊢ ↑m * ↑n < ω

tactic: rw [← natCast_mul]
state_before: a b : Ordinal.{u_1}
m n : ℕ
ha : ↑m < ω
hb : ↑n < ω
⊢ ↑m * ↑n < ω
state_after: a b : Ordinal.{u_1}
m n : ℕ
ha : ↑m < ω
hb : ↑n < ω
⊢ ↑(m * n) < ω

tactic: apply nat_lt_omega
state_before: a b : Ordinal.{u_1}
m n : ℕ
ha : ↑m < ω
hb : ↑n < ω
⊢ ↑(m * n) < ω
state_after: no goals
Theorem: Polynomial.degreeLTEquiv_eq_zero_iff_eq_zero
File: Mathlib/RingTheory/Polynomial/Basic.lean

tactic: rw [LinearEquiv.map_eq_zero_iff, Submodule.mk_eq_zero]
state_before: R : Type u
S : Type u_1
inst✝ : Semiring R
n : ℕ
p : R[X]
hp : p ∈ degreeLT R n
⊢ (degreeLTEquiv R n) ⟨p, hp⟩ = 0 ↔ p = 0
state_after: no goals
Theorem: MeasureTheory.integral_finset
File: Mathlib/MeasureTheory/Integral/Bochner.lean

tactic: rw [integral_countable _ s.countable_toSet hf, ← Finset.tsum_subtype']
state_before: α : Type u_1
E : Type u_2
F : Type u_3
𝕜 : Type u_4
inst✝¹² : NormedAddCommGroup E
inst✝¹¹ : NormedSpace ℝ E
hE : CompleteSpace E
inst✝¹⁰ : NontriviallyNormedField 𝕜
inst✝⁹ : NormedSpace 𝕜 E
inst✝⁸ : SMulCommClass ℝ 𝕜 E
inst✝⁷ : NormedAddCommGroup F
inst✝⁶ : NormedSpace ℝ F
inst✝⁵ : CompleteSpace F
G : Type u_5
inst✝⁴ : NormedAddCommGroup G
inst✝³ : NormedSpace ℝ G
f✝ g : α → E
m : MeasurableSpace α
μ : Measure α
X : Type u_6
inst✝² : TopologicalSpace X
inst✝¹ : FirstCountableTopology X
ν : Measure α
inst✝ : MeasurableSingletonClass α
s : Finset α
f : α → E
hf : Integrable f (μ.restrict ↑s)
⊢ ∫ (x : α) in ↑s, f x ∂μ = ∑ x ∈ s, (μ {x}).toReal • f x
state_after: no goals
Theorem: List.mem_dlookup
File: Mathlib/Data/List/Sigma.lean

tactic: cases' Option.isSome_iff_exists.mp (dlookup_isSome.mpr (mem_keys_of_mem h)) with b' h'
state_before: α : Type u
β : α → Type v
l✝ l₁ l₂ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
l : List (Sigma β)
nd : l.NodupKeys
h : ⟨a, b⟩ ∈ l
⊢ b ∈ dlookup a l
state_after: case intro
α : Type u
β : α → Type v
l✝ l₁ l₂ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
l : List (Sigma β)
nd : l.NodupKeys
h : ⟨a, b⟩ ∈ l
b' : β ⟨a, b⟩.fst
h' : dlookup ⟨a, b⟩.fst l = some b'
⊢ b ∈ dlookup a l

tactic: cases nd.eq_of_mk_mem h (of_mem_dlookup h')
state_before: case intro
α : Type u
β : α → Type v
l✝ l₁ l₂ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
l : List (Sigma β)
nd : l.NodupKeys
h : ⟨a, b⟩ ∈ l
b' : β ⟨a, b⟩.fst
h' : dlookup ⟨a, b⟩.fst l = some b'
⊢ b ∈ dlookup a l
state_after: case intro.refl
α : Type u
β : α → Type v
l✝ l₁ l₂ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
l : List (Sigma β)
nd : l.NodupKeys
h : ⟨a, b⟩ ∈ l
h' : dlookup ⟨a, b⟩.fst l = some b
⊢ b ∈ dlookup a l

tactic: exact h'
state_before: case intro.refl
α : Type u
β : α → Type v
l✝ l₁ l₂ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
l : List (Sigma β)
nd : l.NodupKeys
h : ⟨a, b⟩ ∈ l
h' : dlookup ⟨a, b⟩.fst l = some b
⊢ b ∈ dlookup a l
state_after: no goals
Theorem: MeasureTheory.quasiMeasurePreserving_inv_of_right_invariant
File: Mathlib/MeasureTheory/Group/Prod.lean

tactic: rw [← μ.inv_inv]
state_before: G : Type u_1
inst✝⁶ : MeasurableSpace G
inst✝⁵ : Group G
inst✝⁴ : MeasurableMul₂ G
μ ν : Measure G
inst✝³ : SigmaFinite ν
inst✝² : SigmaFinite μ
s : Set G
inst✝¹ : MeasurableInv G
inst✝ : μ.IsMulRightInvariant
⊢ QuasiMeasurePreserving Inv.inv μ μ
state_after: G : Type u_1
inst✝⁶ : MeasurableSpace G
inst✝⁵ : Group G
inst✝⁴ : MeasurableMul₂ G
μ ν : Measure G
inst✝³ : SigmaFinite ν
inst✝² : SigmaFinite μ
s : Set G
inst✝¹ : MeasurableInv G
inst✝ : μ.IsMulRightInvariant
⊢ QuasiMeasurePreserving Inv.inv μ.inv.inv μ.inv.inv

tactic: exact
  (quasiMeasurePreserving_inv μ.inv).mono (inv_absolutelyContinuous μ.inv)
    (absolutelyContinuous_inv μ.inv)
state_before: G : Type u_1
inst✝⁶ : MeasurableSpace G
inst✝⁵ : Group G
inst✝⁴ : MeasurableMul₂ G
μ ν : Measure G
inst✝³ : SigmaFinite ν
inst✝² : SigmaFinite μ
s : Set G
inst✝¹ : MeasurableInv G
inst✝ : μ.IsMulRightInvariant
⊢ QuasiMeasurePreserving Inv.inv μ.inv.inv μ.inv.inv
state_after: no goals
Theorem: symmDiff_eq_top
File: Mathlib/Order/SymmDiff.lean

tactic: rw [symmDiff_eq', ← compl_inf, inf_eq_top_iff, compl_eq_top, isCompl_iff, disjoint_iff,
  codisjoint_iff, and_comm]
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
π : ι → Type u_4
inst✝ : BooleanAlgebra α
a b c d : α
⊢ a ∆ b = ⊤ ↔ IsCompl a b
state_after: no goals
Theorem: CategoryTheory.Limits.IsTerminal.strict_hom_ext
File: Mathlib/CategoryTheory/Limits/Shapes/StrictInitial.lean

tactic: haveI := hI.isIso_from f
state_before: C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : HasStrictTerminalObjects C
I : C
hI : IsTerminal I
A : C
f g : I ⟶ A
⊢ f = g
state_after: C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : HasStrictTerminalObjects C
I : C
hI : IsTerminal I
A : C
f g : I ⟶ A
this : IsIso f
⊢ f = g

tactic: haveI := hI.isIso_from g
state_before: C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : HasStrictTerminalObjects C
I : C
hI : IsTerminal I
A : C
f g : I ⟶ A
this : IsIso f
⊢ f = g
state_after: C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : HasStrictTerminalObjects C
I : C
hI : IsTerminal I
A : C
f g : I ⟶ A
this✝ : IsIso f
this : IsIso g
⊢ f = g

tactic: exact eq_of_inv_eq_inv (hI.hom_ext (inv f) (inv g))
state_before: C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : HasStrictTerminalObjects C
I : C
hI : IsTerminal I
A : C
f g : I ⟶ A
this✝ : IsIso f
this : IsIso g
⊢ f = g
state_after: no goals
Theorem: div_lt_div_iff'
File: Mathlib/Algebra/Order/Group/Defs.lean

tactic: simpa only [div_eq_mul_inv] using mul_inv_lt_mul_inv_iff'
state_before: α : Type u
inst✝² : CommGroup α
inst✝¹ : LT α
inst✝ : CovariantClass α α (fun x x_1 => x * x_1) fun x x_1 => x < x_1
a b c d : α
⊢ a / b < c / d ↔ a * d < c * b
state_after: no goals
Theorem: TensorAlgebra.equivFreeAlgebra_ι_apply
File: Mathlib/LinearAlgebra/TensorAlgebra/Basis.lean

tactic: simp
state_before: κ : Type uκ
R : Type uR
M : Type uM
inst✝² : CommSemiring R
inst✝¹ : AddCommMonoid M
inst✝ : Module R M
b : Basis κ R M
i : κ
⊢ (Finsupp.total κ (FreeAlgebra R κ) R (FreeAlgebra.ι R) ∘ₗ ↑b.repr) (b i) = FreeAlgebra.ι R i
state_after: no goals
Theorem: EMetric.exists_real_pos_lt_infEdist_of_not_mem_closure
File: Mathlib/Topology/MetricSpace/HausdorffDistance.lean

tactic: rw [← infEdist_pos_iff_not_mem_closure, ENNReal.lt_iff_exists_real_btwn] at h
state_before: ι : Sort u_1
α : Type u
β : Type v
inst✝¹ : PseudoEMetricSpace α
inst✝ : PseudoEMetricSpace β
x✝ y : α
s t : Set α
Φ : α → β
x : α
E : Set α
h : x ∉ closure E
⊢ ∃ ε, 0 < ε ∧ ENNReal.ofReal ε < infEdist x E
state_after: ι : Sort u_1
α : Type u
β : Type v
inst✝¹ : PseudoEMetricSpace α
inst✝ : PseudoEMetricSpace β
x✝ y : α
s t : Set α
Φ : α → β
x : α
E : Set α
h : ∃ r, 0 ≤ r ∧ 0 < ENNReal.ofReal r ∧ ENNReal.ofReal r < infEdist x E
⊢ ∃ ε, 0 < ε ∧ ENNReal.ofReal ε < infEdist x E

tactic: rcases h with ⟨ε, ⟨_, ⟨ε_pos, ε_lt⟩⟩⟩
state_before: ι : Sort u_1
α : Type u
β : Type v
inst✝¹ : PseudoEMetricSpace α
inst✝ : PseudoEMetricSpace β
x✝ y : α
s t : Set α
Φ : α → β
x : α
E : Set α
h : ∃ r, 0 ≤ r ∧ 0 < ENNReal.ofReal r ∧ ENNReal.ofReal r < infEdist x E
⊢ ∃ ε, 0 < ε ∧ ENNReal.ofReal ε < infEdist x E
state_after: case intro.intro.intro
ι : Sort u_1
α : Type u
β : Type v
inst✝¹ : PseudoEMetricSpace α
inst✝ : PseudoEMetricSpace β
x✝ y : α
s t : Set α
Φ : α → β
x : α
E : Set α
ε : ℝ
left✝ : 0 ≤ ε
ε_pos : 0 < ENNReal.ofReal ε
ε_lt : ENNReal.ofReal ε < infEdist x E
⊢ ∃ ε, 0 < ε ∧ ENNReal.ofReal ε < infEdist x E

tactic: exact ⟨ε, ⟨ENNReal.ofReal_pos.mp ε_pos, ε_lt⟩⟩
state_before: case intro.intro.intro
ι : Sort u_1
α : Type u
β : Type v
inst✝¹ : PseudoEMetricSpace α
inst✝ : PseudoEMetricSpace β
x✝ y : α
s t : Set α
Φ : α → β
x : α
E : Set α
ε : ℝ
left✝ : 0 ≤ ε
ε_pos : 0 < ENNReal.ofReal ε
ε_lt : ENNReal.ofReal ε < infEdist x E
⊢ ∃ ε, 0 < ε ∧ ENNReal.ofReal ε < infEdist x E
state_after: no goals
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
⊢ cast 1 = 1
state_after: case zero
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
h : m ∣ 0
⊢ cast 1 = 1

case succ
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
n : ℕ
h : m ∣ n + 1
⊢ cast 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 ∣ n + 1
⊢ cast 1 = 1
state_after: case succ
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
n : ℕ
h : m ∣ n + 1
⊢ ↑(1 % (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 ∣ n + 1
⊢ ↑(1 % (n + 1)) = 1
state_after: case succ.zero
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
h : m ∣ 0 + 1
⊢ ↑(1 % (0 + 1)) = 1

case succ.succ
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
n✝ : ℕ
h : m ∣ n✝ + 1 + 1
⊢ ↑(1 % (n✝ + 1 + 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 ∣ n✝ + 1 + 1
⊢ ↑(1 % (n✝ + 1 + 1)) = 1
state_after: case succ.succ
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
n✝ : ℕ
h : m ∣ n✝ + 1 + 1
⊢ ↑1 = 1

case succ.succ
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
n✝ : ℕ
h : m ∣ n✝ + 1 + 1
⊢ 1 < 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 ∣ n✝ + 1 + 1
⊢ 1 < n✝ + 1 + 1
state_after: no goals

tactic: exact Int.cast_one
state_before: case zero
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
h : m ∣ 0
⊢ cast 1 = 1
state_after: no goals

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 ∣ 0 + 1
⊢ ↑(1 % (0 + 1)) = 1
state_after: case succ.zero
R : Type u_1
inst✝¹ : Ring R
m : ℕ
inst✝ : CharP R m
h : m = 1
⊢ ↑(1 % (0 + 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 % (0 + 1)) = 1
state_after: case succ.zero
R : Type u_1
inst✝¹ : Ring R
inst✝ : CharP R 1
⊢ ↑(1 % (0 + 1)) = 1

tactic: have : Subsingleton R := CharP.CharOne.subsingleton
state_before: case succ.zero
R : Type u_1
inst✝¹ : Ring R
inst✝ : CharP R 1
⊢ ↑(1 % (0 + 1)) = 1
state_after: case succ.zero
R : Type u_1
inst✝¹ : Ring R
inst✝ : CharP R 1
this : Subsingleton R
⊢ ↑(1 % (0 + 1)) = 1

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

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 ∣ n✝ + 1 + 1
⊢ ↑1 = 1
state_after: no goals
Theorem: Rack.self_invAct_eq_iff_eq
File: Mathlib/Algebra/Quandle.lean

tactic: have h := @self_act_eq_iff_eq _ _ (op x) (op y)
state_before: R : Type u_1
inst✝ : Rack R
x y : R
⊢ x ◃⁻¹ x = y ◃⁻¹ y ↔ x = y
state_after: R : Type u_1
inst✝ : Rack R
x y : R
h : op x ◃ op x = op y ◃ op y ↔ op x = op y
⊢ x ◃⁻¹ x = y ◃⁻¹ y ↔ x = y

tactic: simpa using h
state_before: R : Type u_1
inst✝ : Rack R
x y : R
h : op x ◃ op x = op y ◃ op y ↔ op x = op y
⊢ x ◃⁻¹ x = y ◃⁻¹ y ↔ x = y
state_after: no goals
Theorem: MeasureTheory.Measure.le_intro
File: Mathlib/MeasureTheory/Measure/MeasureSpace.lean

tactic: rintro rfl
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
ι : Type u_5
R : Type u_6
R' : Type u_7
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s✝ s' t : Set α
h : ∀ (s : Set α), MeasurableSet s → s.Nonempty → μ₁ s ≤ μ₂ s
s : Set α
hs : MeasurableSet s
⊢ s = ∅ → μ₁ s ≤ μ₂ s
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
ι : Type u_5
R : Type u_6
R' : Type u_7
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s s' t : Set α
h : ∀ (s : Set α), MeasurableSet s → s.Nonempty → μ₁ s ≤ μ₂ s
hs : MeasurableSet ∅
⊢ μ₁ ∅ ≤ μ₂ ∅

tactic: simp
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
ι : Type u_5
R : Type u_6
R' : Type u_7
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s s' t : Set α
h : ∀ (s : Set α), MeasurableSet s → s.Nonempty → μ₁ s ≤ μ₂ s
hs : MeasurableSet ∅
⊢ μ₁ ∅ ≤ μ₂ ∅
state_after: no goals
Theorem: Multiset.map_add_left_Ioo
File: Mathlib/Algebra/Order/Interval/Multiset.lean

tactic: classical rw [Ioo, Ioo, ← Finset.image_add_left_Ioo, Finset.image_val,
    ((Finset.nodup _).map <| add_right_injective c).dedup]
state_before: α : Type u_1
inst✝² : OrderedCancelAddCommMonoid α
inst✝¹ : ExistsAddOfLE α
inst✝ : LocallyFiniteOrder α
a b c : α
⊢ map (fun x => c + x) (Ioo a b) = Ioo (c + a) (c + b)
state_after: no goals

tactic: rw [Ioo, Ioo, ← Finset.image_add_left_Ioo, Finset.image_val,
((Finset.nodup _).map <| add_right_injective c).dedup]
state_before: α : Type u_1
inst✝² : OrderedCancelAddCommMonoid α
inst✝¹ : ExistsAddOfLE α
inst✝ : LocallyFiniteOrder α
a b c : α
⊢ map (fun x => c + x) (Ioo a b) = Ioo (c + a) (c + b)
state_after: no goals
Theorem: Set.image_const_mul_uIcc
File: Mathlib/Data/Set/Pointwise/Interval.lean

tactic: simpa only [mul_comm] using image_mul_const_uIcc a b c
state_before: α : Type u_1
inst✝ : LinearOrderedField α
a✝ a b c : α
⊢ (fun x => a * x) '' [[b, c]] = [[a * b, a * c]]
state_after: no goals
Theorem: List.Ico.append_consecutive
File: Mathlib/Data/List/Intervals.lean

tactic: dsimp only [Ico]
state_before: n m l : ℕ
hnm : n ≤ m
hml : m ≤ l
⊢ Ico n m ++ Ico m l = Ico n l
state_after: n m l : ℕ
hnm : n ≤ m
hml : m ≤ l
⊢ range' n (m - n) ++ range' m (l - m) = range' n (l - n)

tactic: convert range'_append n (m-n) (l-m) 1 using 2
state_before: n m l : ℕ
hnm : n ≤ m
hml : m ≤ l
⊢ range' n (m - n) ++ range' m (l - m) = range' n (l - n)
state_after: case h.e'_2.h.e'_6
n m l : ℕ
hnm : n ≤ m
hml : m ≤ l
⊢ range' m (l - m) = range' (n + 1 * (m - n)) (l - m)

case h.e'_3.h.e'_2
n m l : ℕ
hnm : n ≤ m
hml : m ≤ l
⊢ l - n = l - m + (m - n)

tactic: rw [Nat.one_mul, Nat.add_sub_cancel' hnm]
state_before: case h.e'_2.h.e'_6
n m l : ℕ
hnm : n ≤ m
hml : m ≤ l
⊢ range' m (l - m) = range' (n + 1 * (m - n)) (l - m)
state_after: no goals

tactic: rw [Nat.sub_add_sub_cancel hml hnm]
state_before: case h.e'_3.h.e'_2
n m l : ℕ
hnm : n ≤ m
hml : m ≤ l
⊢ l - n = l - m + (m - n)
state_after: no goals
Theorem: RingQuot.eq_lift_comp_mkRingHom
File: Mathlib/Algebra/RingQuot.lean

tactic: conv_lhs => rw [← lift.apply_symm_apply f]
state_before: R : Type uR
inst✝⁴ : Semiring R
S : Type uS
inst✝³ : CommSemiring S
T : Type uT
A : Type uA
inst✝² : Semiring A
inst✝¹ : Algebra S A
r✝ : R → R → Prop
inst✝ : Semiring T
r : R → R → Prop
f : RingQuot r →+* T
⊢ f = lift ⟨f.comp (mkRingHom r), ⋯⟩
state_after: R : Type uR
inst✝⁴ : Semiring R
S : Type uS
inst✝³ : CommSemiring S
T : Type uT
A : Type uA
inst✝² : Semiring A
inst✝¹ : Algebra S A
r✝ : R → R → Prop
inst✝ : Semiring T
r : R → R → Prop
f : RingQuot r →+* T
⊢ lift (lift.symm f) = lift ⟨f.comp (mkRingHom r), ⋯⟩

tactic: rw [lift_def]
state_before: R : Type uR
inst✝⁴ : Semiring R
S : Type uS
inst✝³ : CommSemiring S
T : Type uT
A : Type uA
inst✝² : Semiring A
inst✝¹ : Algebra S A
r✝ : R → R → Prop
inst✝ : Semiring T
r : R → R → Prop
f : RingQuot r →+* T
⊢ lift (lift.symm f) = lift ⟨f.comp (mkRingHom r), ⋯⟩
state_after: R : Type uR
inst✝⁴ : Semiring R
S : Type uS
inst✝³ : CommSemiring S
T : Type uT
A : Type uA
inst✝² : Semiring A
inst✝¹ : Algebra S A
r✝ : R → R → Prop
inst✝ : Semiring T
r : R → R → Prop
f : RingQuot r →+* T
⊢ { toFun := fun f => preLift ⋯, invFun := fun F => ⟨F.comp (mkRingHom r), ⋯⟩, left_inv := ⋯, right_inv := ⋯ }
      ({ toFun := fun f => preLift ⋯, invFun := fun F => ⟨F.comp (mkRingHom r), ⋯⟩, left_inv := ⋯, right_inv := ⋯ }.symm
        f) =
    { toFun := fun f => preLift ⋯, invFun := fun F => ⟨F.comp (mkRingHom r), ⋯⟩, left_inv := ⋯, right_inv := ⋯ }
      ⟨f.comp (mkRingHom r), ⋯⟩

tactic: rfl
state_before: R : Type uR
inst✝⁴ : Semiring R
S : Type uS
inst✝³ : CommSemiring S
T : Type uT
A : Type uA
inst✝² : Semiring A
inst✝¹ : Algebra S A
r✝ : R → R → Prop
inst✝ : Semiring T
r : R → R → Prop
f : RingQuot r →+* T
⊢ { toFun := fun f => preLift ⋯, invFun := fun F => ⟨F.comp (mkRingHom r), ⋯⟩, left_inv := ⋯, right_inv := ⋯ }
      ({ toFun := fun f => preLift ⋯, invFun := fun F => ⟨F.comp (mkRingHom r), ⋯⟩, left_inv := ⋯, right_inv := ⋯ }.symm
        f) =
    { toFun := fun f => preLift ⋯, invFun := fun F => ⟨F.comp (mkRingHom r), ⋯⟩, left_inv := ⋯, right_inv := ⋯ }
      ⟨f.comp (mkRingHom r), ⋯⟩
state_after: no goals