1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: Polynomial.eq_zero_of_degree_lt_of_eval_index_eq_zero
File: Mathlib/LinearAlgebra/Lagrange.lean

tactic: classical
  rw [← card_image_of_injOn hvs] at degree_f_lt
  refine eq_zero_of_degree_lt_of_eval_finset_eq_zero _ degree_f_lt ?_
  intro x hx
  rcases mem_image.mp hx with ⟨_, hj, rfl⟩
  exact eval_f _ hj
state_before: R : Type u_1
inst✝¹ : CommRing R
inst✝ : IsDomain R
f g : R[X]
ι : Type u_2
v : ι → R
s : Finset ι
hvs : Set.InjOn v ↑s
degree_f_lt : f.degree < ↑s.card
eval_f : ∀ i ∈ s, eval (v i) f = 0
⊢ f = 0
state_after: no goals

tactic: rw [← card_image_of_injOn hvs] at degree_f_lt
state_before: R : Type u_1
inst✝¹ : CommRing R
inst✝ : IsDomain R
f g : R[X]
ι : Type u_2
v : ι → R
s : Finset ι
hvs : Set.InjOn v ↑s
degree_f_lt : f.degree < ↑s.card
eval_f : ∀ i ∈ s, eval (v i) f = 0
⊢ f = 0
state_after: R : Type u_1
inst✝¹ : CommRing R
inst✝ : IsDomain R
f g : R[X]
ι : Type u_2
v : ι → R
s : Finset ι
hvs : Set.InjOn v ↑s
degree_f_lt : f.degree < ↑(image v s).card
eval_f : ∀ i ∈ s, eval (v i) f = 0
⊢ f = 0

tactic: refine eq_zero_of_degree_lt_of_eval_finset_eq_zero _ degree_f_lt ?_
state_before: R : Type u_1
inst✝¹ : CommRing R
inst✝ : IsDomain R
f g : R[X]
ι : Type u_2
v : ι → R
s : Finset ι
hvs : Set.InjOn v ↑s
degree_f_lt : f.degree < ↑(image v s).card
eval_f : ∀ i ∈ s, eval (v i) f = 0
⊢ f = 0
state_after: R : Type u_1
inst✝¹ : CommRing R
inst✝ : IsDomain R
f g : R[X]
ι : Type u_2
v : ι → R
s : Finset ι
hvs : Set.InjOn v ↑s
degree_f_lt : f.degree < ↑(image v s).card
eval_f : ∀ i ∈ s, eval (v i) f = 0
⊢ ∀ x ∈ image v s, eval x f = 0

tactic: intro x hx
state_before: R : Type u_1
inst✝¹ : CommRing R
inst✝ : IsDomain R
f g : R[X]
ι : Type u_2
v : ι → R
s : Finset ι
hvs : Set.InjOn v ↑s
degree_f_lt : f.degree < ↑(image v s).card
eval_f : ∀ i ∈ s, eval (v i) f = 0
⊢ ∀ x ∈ image v s, eval x f = 0
state_after: R : Type u_1
inst✝¹ : CommRing R
inst✝ : IsDomain R
f g : R[X]
ι : Type u_2
v : ι → R
s : Finset ι
hvs : Set.InjOn v ↑s
degree_f_lt : f.degree < ↑(image v s).card
eval_f : ∀ i ∈ s, eval (v i) f = 0
x : R
hx : x ∈ image v s
⊢ eval x f = 0

tactic: rcases mem_image.mp hx with ⟨_, hj, rfl⟩
state_before: R : Type u_1
inst✝¹ : CommRing R
inst✝ : IsDomain R
f g : R[X]
ι : Type u_2
v : ι → R
s : Finset ι
hvs : Set.InjOn v ↑s
degree_f_lt : f.degree < ↑(image v s).card
eval_f : ∀ i ∈ s, eval (v i) f = 0
x : R
hx : x ∈ image v s
⊢ eval x f = 0
state_after: case intro.intro
R : Type u_1
inst✝¹ : CommRing R
inst✝ : IsDomain R
f g : R[X]
ι : Type u_2
v : ι → R
s : Finset ι
hvs : Set.InjOn v ↑s
degree_f_lt : f.degree < ↑(image v s).card
eval_f : ∀ i ∈ s, eval (v i) f = 0
w✝ : ι
hj : w✝ ∈ s
hx : v w✝ ∈ image v s
⊢ eval (v w✝) f = 0

tactic: exact eval_f _ hj
state_before: case intro.intro
R : Type u_1
inst✝¹ : CommRing R
inst✝ : IsDomain R
f g : R[X]
ι : Type u_2
v : ι → R
s : Finset ι
hvs : Set.InjOn v ↑s
degree_f_lt : f.degree < ↑(image v s).card
eval_f : ∀ i ∈ s, eval (v i) f = 0
w✝ : ι
hj : w✝ ∈ s
hx : v w✝ ∈ image v s
⊢ eval (v w✝) f = 0
state_after: no goals
Theorem: FreeAbelianGroup.support_neg
File: Mathlib/GroupTheory/FreeAbelianGroupFinsupp.lean

tactic: simp only [support, AddMonoidHom.map_neg, Finsupp.support_neg]
state_before: X : Type u_1
a : FreeAbelianGroup X
⊢ (-a).support = a.support
state_after: no goals
Theorem: QuotientRing.isOpenMap_coe
File: Mathlib/Topology/Algebra/Ring/Ideal.lean

tactic: intro s s_op
state_before: R : Type u_1
inst✝² : TopologicalSpace R
inst✝¹ : CommRing R
N : Ideal R
inst✝ : TopologicalRing R
⊢ IsOpenMap ⇑(mk N)
state_after: R : Type u_1
inst✝² : TopologicalSpace R
inst✝¹ : CommRing R
N : Ideal R
inst✝ : TopologicalRing R
s : Set R
s_op : IsOpen s
⊢ IsOpen (⇑(mk N) '' s)

tactic: change IsOpen (mk N ⁻¹' (mk N '' s))
state_before: R : Type u_1
inst✝² : TopologicalSpace R
inst✝¹ : CommRing R
N : Ideal R
inst✝ : TopologicalRing R
s : Set R
s_op : IsOpen s
⊢ IsOpen (⇑(mk N) '' s)
state_after: R : Type u_1
inst✝² : TopologicalSpace R
inst✝¹ : CommRing R
N : Ideal R
inst✝ : TopologicalRing R
s : Set R
s_op : IsOpen s
⊢ IsOpen (⇑(mk N) ⁻¹' (⇑(mk N) '' s))

tactic: rw [quotient_ring_saturate]
state_before: R : Type u_1
inst✝² : TopologicalSpace R
inst✝¹ : CommRing R
N : Ideal R
inst✝ : TopologicalRing R
s : Set R
s_op : IsOpen s
⊢ IsOpen (⇑(mk N) ⁻¹' (⇑(mk N) '' s))
state_after: R : Type u_1
inst✝² : TopologicalSpace R
inst✝¹ : CommRing R
N : Ideal R
inst✝ : TopologicalRing R
s : Set R
s_op : IsOpen s
⊢ IsOpen (⋃ x, (fun y => ↑x + y) '' s)

tactic: exact isOpen_iUnion fun ⟨n, _⟩ => isOpenMap_add_left n s s_op
state_before: R : Type u_1
inst✝² : TopologicalSpace R
inst✝¹ : CommRing R
N : Ideal R
inst✝ : TopologicalRing R
s : Set R
s_op : IsOpen s
⊢ IsOpen (⋃ x, (fun y => ↑x + y) '' s)
state_after: no goals
Theorem: Matroid.restrictSubtype_dual'
File: Mathlib/Data/Matroid/Map.lean

tactic: rw [← hM, restrictSubtype_dual]
state_before: α : Type u_1
β : Type u_2
f : α → β
E✝ I✝ s : Set α
M✝ : Matroid α
N : Matroid β
E X I : Set α
M : Matroid α
hM : M.E = E
⊢ (M.restrictSubtype E)✶ = M✶.restrictSubtype E
state_after: no goals
Theorem: Sum.LiftRel.exists_of_isLeft_left
File: Mathlib/Data/Sum/Basic.lean

tactic: rcases isLeft_iff.mp h₂ with ⟨_, rfl⟩
state_before: α : Type u
α' : Type w
β : Type v
β' : Type x
γ : Type u_1
δ : Type u_2
r : α → γ → Prop
s : β → δ → Prop
x : α ⊕ β
y : γ ⊕ δ
a : α
b : β
c : γ
d : δ
h₁ : LiftRel r s x y
h₂ : x.isLeft = true
⊢ ∃ a c, r a c ∧ x = inl a ∧ y = inl c
state_after: case intro
α : Type u
α' : Type w
β : Type v
β' : Type x
γ : Type u_1
δ : Type u_2
r : α → γ → Prop
s : β → δ → Prop
y : γ ⊕ δ
a : α
b : β
c : γ
d : δ
w✝ : α
h₁ : LiftRel r s (inl w✝) y
h₂ : (inl w✝).isLeft = true
⊢ ∃ a c, r a c ∧ inl w✝ = inl a ∧ y = inl c

tactic: simp only [liftRel_iff, false_and, and_false, exists_false, or_false] at h₁
state_before: case intro
α : Type u
α' : Type w
β : Type v
β' : Type x
γ : Type u_1
δ : Type u_2
r : α → γ → Prop
s : β → δ → Prop
y : γ ⊕ δ
a : α
b : β
c : γ
d : δ
w✝ : α
h₁ : LiftRel r s (inl w✝) y
h₂ : (inl w✝).isLeft = true
⊢ ∃ a c, r a c ∧ inl w✝ = inl a ∧ y = inl c
state_after: case intro
α : Type u
α' : Type w
β : Type v
β' : Type x
γ : Type u_1
δ : Type u_2
r : α → γ → Prop
s : β → δ → Prop
y : γ ⊕ δ
a : α
b : β
c : γ
d : δ
w✝ : α
h₂ : (inl w✝).isLeft = true
h₁ : ∃ a c, r a c ∧ inl w✝ = inl a ∧ y = inl c
⊢ ∃ a c, r a c ∧ inl w✝ = inl a ∧ y = inl c

tactic: exact h₁
state_before: case intro
α : Type u
α' : Type w
β : Type v
β' : Type x
γ : Type u_1
δ : Type u_2
r : α → γ → Prop
s : β → δ → Prop
y : γ ⊕ δ
a : α
b : β
c : γ
d : δ
w✝ : α
h₂ : (inl w✝).isLeft = true
h₁ : ∃ a c, r a c ∧ inl w✝ = inl a ∧ y = inl c
⊢ ∃ a c, r a c ∧ inl w✝ = inl a ∧ y = inl c
state_after: no goals
Theorem: Polynomial.natDegree_opRingEquiv
File: Mathlib/RingTheory/Polynomial/Opposites.lean

tactic: by_cases p0 : p = 0
state_before: R : Type u_1
inst✝ : Semiring R
p : R[X]ᵐᵒᵖ
⊢ ((opRingEquiv R) p).natDegree = (unop p).natDegree
state_after: case pos
R : Type u_1
inst✝ : Semiring R
p : R[X]ᵐᵒᵖ
p0 : p = 0
⊢ ((opRingEquiv R) p).natDegree = (unop p).natDegree

case neg
R : Type u_1
inst✝ : Semiring R
p : R[X]ᵐᵒᵖ
p0 : ¬p = 0
⊢ ((opRingEquiv R) p).natDegree = (unop p).natDegree

tactic: simp only [p0, _root_.map_zero, natDegree_zero, unop_zero]
state_before: case pos
R : Type u_1
inst✝ : Semiring R
p : R[X]ᵐᵒᵖ
p0 : p = 0
⊢ ((opRingEquiv R) p).natDegree = (unop p).natDegree
state_after: no goals

tactic: simp only [p0, natDegree_eq_support_max', Ne, AddEquivClass.map_eq_zero_iff, not_false_iff,
  support_opRingEquiv, unop_eq_zero_iff]
state_before: case neg
R : Type u_1
inst✝ : Semiring R
p : R[X]ᵐᵒᵖ
p0 : ¬p = 0
⊢ ((opRingEquiv R) p).natDegree = (unop p).natDegree
state_after: no goals
Theorem: AffineSubspace.mem_perpBisector_iff_inner_eq_inner
File: Mathlib/Geometry/Euclidean/PerpBisector.lean

tactic: rw [Iff.comm, mem_perpBisector_iff_inner_eq_zero, ← add_neg_eq_zero, ← inner_neg_right,
  neg_vsub_eq_vsub_rev, ← inner_add_left, vsub_midpoint, invOf_eq_inv, ← smul_add,
  real_inner_smul_left]
state_before: V : Type u_1
P : Type u_2
inst✝³ : NormedAddCommGroup V
inst✝² : InnerProductSpace ℝ V
inst✝¹ : MetricSpace P
inst✝ : NormedAddTorsor V P
c c₁ c₂ p₁ p₂ : P
⊢ c ∈ perpBisector p₁ p₂ ↔ ⟪c -ᵥ p₁, p₂ -ᵥ p₁⟫_ℝ = ⟪c -ᵥ p₂, p₁ -ᵥ p₂⟫_ℝ
state_after: V : Type u_1
P : Type u_2
inst✝³ : NormedAddCommGroup V
inst✝² : InnerProductSpace ℝ V
inst✝¹ : MetricSpace P
inst✝ : NormedAddTorsor V P
c c₁ c₂ p₁ p₂ : P
⊢ ⟪c -ᵥ p₁ + (c -ᵥ p₂), p₂ -ᵥ p₁⟫_ℝ = 0 ↔ 2⁻¹ * ⟪c -ᵥ p₁ + (c -ᵥ p₂), p₂ -ᵥ p₁⟫_ℝ = 0

tactic: simp
state_before: V : Type u_1
P : Type u_2
inst✝³ : NormedAddCommGroup V
inst✝² : InnerProductSpace ℝ V
inst✝¹ : MetricSpace P
inst✝ : NormedAddTorsor V P
c c₁ c₂ p₁ p₂ : P
⊢ ⟪c -ᵥ p₁ + (c -ᵥ p₂), p₂ -ᵥ p₁⟫_ℝ = 0 ↔ 2⁻¹ * ⟪c -ᵥ p₁ + (c -ᵥ p₂), p₂ -ᵥ p₁⟫_ℝ = 0
state_after: no goals
Theorem: Mathlib.Meta.NormNum.isInt_emod_neg
File: Mathlib/Tactic/NormNum/DivMod.lean

tactic: rw [← Int.emod_neg, h.out]
state_before: a b : ℤ
r : ℕ
h : IsNat (a % -b) r
⊢ a % b = ↑r
state_after: no goals
Theorem: Cycle.Nodup.nontrivial_iff
File: Mathlib/Data/List/Cycle.lean

tactic: rw [length_subsingleton_iff]
state_before: α : Type u_1
s : Cycle α
h : s.Nodup
⊢ s.Nontrivial ↔ ¬s.Subsingleton
state_after: α : Type u_1
s : Cycle α
h : s.Nodup
⊢ s.Nontrivial ↔ ¬s.length ≤ 1

tactic: induction s using Quotient.inductionOn'
state_before: α : Type u_1
s : Cycle α
h : s.Nodup
⊢ s.Nontrivial ↔ ¬s.length ≤ 1
state_after: case h
α : Type u_1
a✝ : List α
h : Nodup (Quotient.mk'' a✝)
⊢ Nontrivial (Quotient.mk'' a✝) ↔ ¬length (Quotient.mk'' a✝) ≤ 1

tactic: simp only [mk''_eq_coe, nodup_coe_iff] at h
state_before: case h
α : Type u_1
a✝ : List α
h : Nodup (Quotient.mk'' a✝)
⊢ Nontrivial (Quotient.mk'' a✝) ↔ ¬length (Quotient.mk'' a✝) ≤ 1
state_after: case h
α : Type u_1
a✝ : List α
h : a✝.Nodup
⊢ Nontrivial (Quotient.mk'' a✝) ↔ ¬length (Quotient.mk'' a✝) ≤ 1

tactic: simp [h, Nat.succ_le_iff]
state_before: case h
α : Type u_1
a✝ : List α
h : a✝.Nodup
⊢ Nontrivial (Quotient.mk'' a✝) ↔ ¬length (Quotient.mk'' a✝) ≤ 1
state_after: no goals
Theorem: Real.measure_ext_Ioo_rat
File: Mathlib/MeasureTheory/Constructions/BorelSpace/Real.lean

tactic: simp only [mem_iUnion, mem_singleton_iff]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
ι : Sort y
s t u : Set α
μ ν : Measure ℝ
inst✝ : IsLocallyFiniteMeasure μ
h : ∀ (a b : ℚ), μ (Ioo ↑a ↑b) = ν (Ioo ↑a ↑b)
⊢ ∀ s ∈ ⋃ a, ⋃ b, ⋃ (_ : a < b), {Ioo ↑a ↑b}, μ s = ν s
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
ι : Sort y
s t u : Set α
μ ν : Measure ℝ
inst✝ : IsLocallyFiniteMeasure μ
h : ∀ (a b : ℚ), μ (Ioo ↑a ↑b) = ν (Ioo ↑a ↑b)
⊢ ∀ (s : Set ℝ), (∃ i i_1, ∃ (_ : i < i_1), s = Ioo ↑i ↑i_1) → μ s = ν s

tactic: rintro _ ⟨a, b, -, rfl⟩
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
ι : Sort y
s t u : Set α
μ ν : Measure ℝ
inst✝ : IsLocallyFiniteMeasure μ
h : ∀ (a b : ℚ), μ (Ioo ↑a ↑b) = ν (Ioo ↑a ↑b)
⊢ ∀ (s : Set ℝ), (∃ i i_1, ∃ (_ : i < i_1), s = Ioo ↑i ↑i_1) → μ s = ν s
state_after: case intro.intro.intro
α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
ι : Sort y
s t u : Set α
μ ν : Measure ℝ
inst✝ : IsLocallyFiniteMeasure μ
h : ∀ (a b : ℚ), μ (Ioo ↑a ↑b) = ν (Ioo ↑a ↑b)
a b : ℚ
⊢ μ (Ioo ↑a ↑b) = ν (Ioo ↑a ↑b)

tactic: apply h
state_before: case intro.intro.intro
α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
ι : Sort y
s t u : Set α
μ ν : Measure ℝ
inst✝ : IsLocallyFiniteMeasure μ
h : ∀ (a b : ℚ), μ (Ioo ↑a ↑b) = ν (Ioo ↑a ↑b)
a b : ℚ
⊢ μ (Ioo ↑a ↑b) = ν (Ioo ↑a ↑b)
state_after: no goals
Theorem: CliffordAlgebra.EquivEven.neg_e0_mul_v
File: Mathlib/LinearAlgebra/CliffordAlgebra/EvenEquiv.lean

tactic: refine neg_eq_of_add_eq_zero_right ((ι_mul_ι_add_swap _ _).trans ?_)
state_before: R : Type u_1
M : Type u_2
inst✝² : CommRing R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
Q : QuadraticForm R M
m : M
⊢ -(e0 Q * (v Q) m) = (v Q) m * e0 Q
state_after: R : Type u_1
M : Type u_2
inst✝² : CommRing R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
Q : QuadraticForm R M
m : M
⊢ (algebraMap R (CliffordAlgebra (Q' Q))) (QuadraticForm.polar ⇑(Q' Q) (0, 1) ((LinearMap.inl R M R) m)) = 0

tactic: dsimp [QuadraticForm.polar]
state_before: R : Type u_1
M : Type u_2
inst✝² : CommRing R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
Q : QuadraticForm R M
m : M
⊢ (algebraMap R (CliffordAlgebra (Q' Q))) (QuadraticForm.polar ⇑(Q' Q) (0, 1) ((LinearMap.inl R M R) m)) = 0
state_after: R : Type u_1
M : Type u_2
inst✝² : CommRing R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
Q : QuadraticForm R M
m : M
⊢ (algebraMap R (CliffordAlgebra (Q' Q))) (Q (0 + m) + -((1 + 0) * (1 + 0)) - (Q 0 + -(1 * 1)) - (Q m + -(0 * 0))) = 0

tactic: simp only [add_zero, mul_zero, mul_one, zero_add, neg_zero, QuadraticForm.map_zero,
  add_sub_cancel_right, sub_self, map_zero, zero_sub]
state_before: R : Type u_1
M : Type u_2
inst✝² : CommRing R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
Q : QuadraticForm R M
m : M
⊢ (algebraMap R (CliffordAlgebra (Q' Q))) (Q (0 + m) + -((1 + 0) * (1 + 0)) - (Q 0 + -(1 * 1)) - (Q m + -(0 * 0))) = 0
state_after: no goals
Theorem: LinearMap.eqOn_sup
File: Mathlib/Algebra/Module/Submodule/EqLocus.lean

tactic: rw [← le_eqLocus] at hS hT ⊢
state_before: R : Type u_1
R₂ : Type u_2
M : Type u_3
M₂ : Type u_4
inst✝⁷ : Semiring R
inst✝⁶ : Semiring R₂
inst✝⁵ : AddCommMonoid M
inst✝⁴ : AddCommMonoid M₂
inst✝³ : Module R M
inst✝² : Module R₂ M₂
τ₁₂ : R →+* R₂
F : Type u_5
inst✝¹ : FunLike F M M₂
inst✝ : SemilinearMapClass F τ₁₂ M M₂
f g : F
S T : Submodule R M
hS : Set.EqOn ⇑f ⇑g ↑S
hT : Set.EqOn ⇑f ⇑g ↑T
⊢ Set.EqOn ⇑f ⇑g ↑(S ⊔ T)
state_after: R : Type u_1
R₂ : Type u_2
M : Type u_3
M₂ : Type u_4
inst✝⁷ : Semiring R
inst✝⁶ : Semiring R₂
inst✝⁵ : AddCommMonoid M
inst✝⁴ : AddCommMonoid M₂
inst✝³ : Module R M
inst✝² : Module R₂ M₂
τ₁₂ : R →+* R₂
F : Type u_5
inst✝¹ : FunLike F M M₂
inst✝ : SemilinearMapClass F τ₁₂ M M₂
f g : F
S T : Submodule R M
hS : S ≤ eqLocus f g
hT : T ≤ eqLocus f g
⊢ S ⊔ T ≤ eqLocus f g

tactic: exact sup_le hS hT
state_before: R : Type u_1
R₂ : Type u_2
M : Type u_3
M₂ : Type u_4
inst✝⁷ : Semiring R
inst✝⁶ : Semiring R₂
inst✝⁵ : AddCommMonoid M
inst✝⁴ : AddCommMonoid M₂
inst✝³ : Module R M
inst✝² : Module R₂ M₂
τ₁₂ : R →+* R₂
F : Type u_5
inst✝¹ : FunLike F M M₂
inst✝ : SemilinearMapClass F τ₁₂ M M₂
f g : F
S T : Submodule R M
hS : S ≤ eqLocus f g
hT : T ≤ eqLocus f g
⊢ S ⊔ T ≤ eqLocus f g
state_after: no goals
Theorem: Filter.frequently_top
File: Mathlib/Order/Filter/Basic.lean

tactic: simp [Filter.Frequently]
state_before: α : Type u
β : Type v
γ : Type w
δ : Type u_1
ι : Sort x
p : α → Prop
⊢ (∃ᶠ (x : α) in ⊤, p x) ↔ ∃ x, p x
state_after: no goals
Theorem: Finsupp.total_option
File: Mathlib/LinearAlgebra/Finsupp.lean

tactic: rw [total_apply, sum_option_index_smul, total_apply]
state_before: α : Type u_1
M : Type u_2
N : Type u_3
P : Type u_4
R : Type u_5
S : Type u_6
inst✝⁹ : Semiring R
inst✝⁸ : Semiring S
inst✝⁷ : AddCommMonoid M
inst✝⁶ : Module R M
inst✝⁵ : AddCommMonoid N
inst✝⁴ : Module R N
inst✝³ : AddCommMonoid P
inst✝² : Module R P
α' : Type u_7
M' : Type u_8
inst✝¹ : AddCommMonoid M'
inst✝ : Module R M'
v✝ : α → M
v' : α' → M'
v : Option α → M
f : Option α →₀ R
⊢ (Finsupp.total (Option α) M R v) f = f none • v none + (Finsupp.total α M R (v ∘ Option.some)) f.some
state_after: α : Type u_1
M : Type u_2
N : Type u_3
P : Type u_4
R : Type u_5
S : Type u_6
inst✝⁹ : Semiring R
inst✝⁸ : Semiring S
inst✝⁷ : AddCommMonoid M
inst✝⁶ : Module R M
inst✝⁵ : AddCommMonoid N
inst✝⁴ : Module R N
inst✝³ : AddCommMonoid P
inst✝² : Module R P
α' : Type u_7
M' : Type u_8
inst✝¹ : AddCommMonoid M'
inst✝ : Module R M'
v✝ : α → M
v' : α' → M'
v : Option α → M
f : Option α →₀ R
⊢ (f none • v none + f.some.sum fun a r => r • v (Option.some a)) =
    f none • v none + f.some.sum fun i a => a • (v ∘ Option.some) i

tactic: simp
state_before: α : Type u_1
M : Type u_2
N : Type u_3
P : Type u_4
R : Type u_5
S : Type u_6
inst✝⁹ : Semiring R
inst✝⁸ : Semiring S
inst✝⁷ : AddCommMonoid M
inst✝⁶ : Module R M
inst✝⁵ : AddCommMonoid N
inst✝⁴ : Module R N
inst✝³ : AddCommMonoid P
inst✝² : Module R P
α' : Type u_7
M' : Type u_8
inst✝¹ : AddCommMonoid M'
inst✝ : Module R M'
v✝ : α → M
v' : α' → M'
v : Option α → M
f : Option α →₀ R
⊢ (f none • v none + f.some.sum fun a r => r • v (Option.some a)) =
    f none • v none + f.some.sum fun i a => a • (v ∘ Option.some) i
state_after: no goals
Theorem: MeasureTheory.Measure.restrict_biUnion_congr
File: Mathlib/MeasureTheory/Measure/Restrict.lean

tactic: haveI := hc.toEncodable
state_before: R : Type u_1
α : Type u_2
β : Type u_3
δ : Type u_4
γ : Type u_5
ι : Type u_6
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s✝ s' t✝ : Set α
s : Set ι
t : ι → Set α
hc : s.Countable
⊢ μ.restrict (⋃ i ∈ s, t i) = ν.restrict (⋃ i ∈ s, t i) ↔ ∀ i ∈ s, μ.restrict (t i) = ν.restrict (t i)
state_after: R : Type u_1
α : Type u_2
β : Type u_3
δ : Type u_4
γ : Type u_5
ι : Type u_6
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s✝ s' t✝ : Set α
s : Set ι
t : ι → Set α
hc : s.Countable
this : Encodable ↑s
⊢ μ.restrict (⋃ i ∈ s, t i) = ν.restrict (⋃ i ∈ s, t i) ↔ ∀ i ∈ s, μ.restrict (t i) = ν.restrict (t i)

tactic: simp only [biUnion_eq_iUnion, SetCoe.forall', restrict_iUnion_congr]
state_before: R : Type u_1
α : Type u_2
β : Type u_3
δ : Type u_4
γ : Type u_5
ι : Type u_6
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s✝ s' t✝ : Set α
s : Set ι
t : ι → Set α
hc : s.Countable
this : Encodable ↑s
⊢ μ.restrict (⋃ i ∈ s, t i) = ν.restrict (⋃ i ∈ s, t i) ↔ ∀ i ∈ s, μ.restrict (t i) = ν.restrict (t i)
state_after: no goals
Theorem: DihedralGroup.orderOf_sr
File: Mathlib/GroupTheory/SpecificGroups/Dihedral.lean

tactic: apply orderOf_eq_prime
state_before: n : ℕ
i : ZMod n
⊢ orderOf (sr i) = 2
state_after: case hg
n : ℕ
i : ZMod n
⊢ sr i ^ 2 = 1

case hg1
n : ℕ
i : ZMod n
⊢ sr i ≠ 1

tactic: rw [sq, sr_mul_self]
state_before: case hg
n : ℕ
i : ZMod n
⊢ sr i ^ 2 = 1
state_after: no goals

tactic: revert n
state_before: case hg1
n : ℕ
i : ZMod n
⊢ sr i ≠ 1
state_after: case hg1

⊢ ∀ {n : ℕ} (i : ZMod n), sr i ≠ 1

tactic: simp_rw [one_def, ne_eq, forall_const, not_false_eq_true]
state_before: case hg1

⊢ ∀ {n : ℕ} (i : ZMod n), sr i ≠ 1
state_after: no goals
Theorem: MeasureTheory.Measure.dirac_apply_of_mem
File: Mathlib/MeasureTheory/Measure/Dirac.lean

tactic: have : ∀ t : Set α, a ∈ t → t.indicator (1 : α → ℝ≥0∞) a = 1 := fun t ht => indicator_of_mem ht 1
state_before: α : Type u_1
β : Type u_2
δ : Type u_3
inst✝¹ : MeasurableSpace α
inst✝ : MeasurableSpace β
s : Set α
a✝ a : α
h : a ∈ s
⊢ (dirac a) s = 1
state_after: α : Type u_1
β : Type u_2
δ : Type u_3
inst✝¹ : MeasurableSpace α
inst✝ : MeasurableSpace β
s : Set α
a✝ a : α
h : a ∈ s
this : ∀ (t : Set α), a ∈ t → t.indicator 1 a = 1
⊢ (dirac a) s = 1

tactic: refine le_antisymm (this univ trivial ▸ ?_) (this s h ▸ le_dirac_apply)
state_before: α : Type u_1
β : Type u_2
δ : Type u_3
inst✝¹ : MeasurableSpace α
inst✝ : MeasurableSpace β
s : Set α
a✝ a : α
h : a ∈ s
this : ∀ (t : Set α), a ∈ t → t.indicator 1 a = 1
⊢ (dirac a) s = 1
state_after: α : Type u_1
β : Type u_2
δ : Type u_3
inst✝¹ : MeasurableSpace α
inst✝ : MeasurableSpace β
s : Set α
a✝ a : α
h : a ∈ s
this : ∀ (t : Set α), a ∈ t → t.indicator 1 a = 1
⊢ (dirac a) s ≤ univ.indicator 1 a

tactic: rw [← dirac_apply' a MeasurableSet.univ]
state_before: α : Type u_1
β : Type u_2
δ : Type u_3
inst✝¹ : MeasurableSpace α
inst✝ : MeasurableSpace β
s : Set α
a✝ a : α
h : a ∈ s
this : ∀ (t : Set α), a ∈ t → t.indicator 1 a = 1
⊢ (dirac a) s ≤ univ.indicator 1 a
state_after: α : Type u_1
β : Type u_2
δ : Type u_3
inst✝¹ : MeasurableSpace α
inst✝ : MeasurableSpace β
s : Set α
a✝ a : α
h : a ∈ s
this : ∀ (t : Set α), a ∈ t → t.indicator 1 a = 1
⊢ (dirac a) s ≤ (dirac a) univ

tactic: exact measure_mono (subset_univ s)
state_before: α : Type u_1
β : Type u_2
δ : Type u_3
inst✝¹ : MeasurableSpace α
inst✝ : MeasurableSpace β
s : Set α
a✝ a : α
h : a ∈ s
this : ∀ (t : Set α), a ∈ t → t.indicator 1 a = 1
⊢ (dirac a) s ≤ (dirac a) univ
state_after: no goals
Theorem: Localization.mk_eq_monoidOf_mk'_apply
File: Mathlib/GroupTheory/MonoidLocalization.lean

tactic: rw [← mk_one_eq_monoidOf_mk, ← mk_one_eq_monoidOf_mk, mk_mul x y y 1, mul_comm y 1]
state_before: M : Type u_1
inst✝² : CommMonoid M
S : Submonoid M
N : Type u_2
inst✝¹ : CommMonoid N
P : Type u_3
inst✝ : CommMonoid P
x : M
y : ↥S
⊢ mk x y * (monoidOf S).toMap ↑y = (monoidOf S).toMap x
state_after: M : Type u_1
inst✝² : CommMonoid M
S : Submonoid M
N : Type u_2
inst✝¹ : CommMonoid N
P : Type u_3
inst✝ : CommMonoid P
x : M
y : ↥S
⊢ mk (x * ↑y) (1 * y) = mk x 1

tactic: conv => rhs; rw [← mul_one 1]; rw [← mul_one x]
state_before: M : Type u_1
inst✝² : CommMonoid M
S : Submonoid M
N : Type u_2
inst✝¹ : CommMonoid N
P : Type u_3
inst✝ : CommMonoid P
x : M
y : ↥S
⊢ mk (x * ↑y) (1 * y) = mk x 1
state_after: M : Type u_1
inst✝² : CommMonoid M
S : Submonoid M
N : Type u_2
inst✝¹ : CommMonoid N
P : Type u_3
inst✝ : CommMonoid P
x : M
y : ↥S
⊢ mk (x * ↑y) (1 * y) = mk (x * 1) (1 * 1)

tactic: exact mk_eq_mk_iff.2 (Con.symm _ <| (Localization.r S).mul (Con.refl _ (x, 1)) <| one_rel _)
state_before: M : Type u_1
inst✝² : CommMonoid M
S : Submonoid M
N : Type u_2
inst✝¹ : CommMonoid N
P : Type u_3
inst✝ : CommMonoid P
x : M
y : ↥S
⊢ mk (x * ↑y) (1 * y) = mk (x * 1) (1 * 1)
state_after: no goals
Theorem: ContinuousMultilinearMap.opNorm_add_le
File: Mathlib/Analysis/NormedSpace/Multilinear/Basic.lean

tactic: rw [add_mul]
state_before: 𝕜 : Type u
ι : Type v
ι' : Type v'
E : ι → Type wE
E₁ : ι → Type wE₁
E' : ι' → Type wE'
G : Type wG
G' : Type wG'
inst✝¹² : Fintype ι
inst✝¹¹ : Fintype ι'
inst✝¹⁰ : NontriviallyNormedField 𝕜
inst✝⁹ : (i : ι) → SeminormedAddCommGroup (E i)
inst✝⁸ : (i : ι) → NormedSpace 𝕜 (E i)
inst✝⁷ : (i : ι) → SeminormedAddCommGroup (E₁ i)
inst✝⁶ : (i : ι) → NormedSpace 𝕜 (E₁ i)
inst✝⁵ : (i : ι') → SeminormedAddCommGroup (E' i)
inst✝⁴ : (i : ι') → NormedSpace 𝕜 (E' i)
inst✝³ : SeminormedAddCommGroup G
inst✝² : NormedSpace 𝕜 G
inst✝¹ : SeminormedAddCommGroup G'
inst✝ : NormedSpace 𝕜 G'
c : 𝕜
f g : ContinuousMultilinearMap 𝕜 E G
m x : (i : ι) → E i
⊢ ‖(f + g) x‖ ≤ (‖f‖ + ‖g‖) * ∏ i : ι, ‖x i‖
state_after: 𝕜 : Type u
ι : Type v
ι' : Type v'
E : ι → Type wE
E₁ : ι → Type wE₁
E' : ι' → Type wE'
G : Type wG
G' : Type wG'
inst✝¹² : Fintype ι
inst✝¹¹ : Fintype ι'
inst✝¹⁰ : NontriviallyNormedField 𝕜
inst✝⁹ : (i : ι) → SeminormedAddCommGroup (E i)
inst✝⁸ : (i : ι) → NormedSpace 𝕜 (E i)
inst✝⁷ : (i : ι) → SeminormedAddCommGroup (E₁ i)
inst✝⁶ : (i : ι) → NormedSpace 𝕜 (E₁ i)
inst✝⁵ : (i : ι') → SeminormedAddCommGroup (E' i)
inst✝⁴ : (i : ι') → NormedSpace 𝕜 (E' i)
inst✝³ : SeminormedAddCommGroup G
inst✝² : NormedSpace 𝕜 G
inst✝¹ : SeminormedAddCommGroup G'
inst✝ : NormedSpace 𝕜 G'
c : 𝕜
f g : ContinuousMultilinearMap 𝕜 E G
m x : (i : ι) → E i
⊢ ‖(f + g) x‖ ≤ ‖f‖ * ∏ i : ι, ‖x i‖ + ‖g‖ * ∏ i : ι, ‖x i‖

tactic: exact norm_add_le_of_le (le_opNorm _ _) (le_opNorm _ _)
state_before: 𝕜 : Type u
ι : Type v
ι' : Type v'
E : ι → Type wE
E₁ : ι → Type wE₁
E' : ι' → Type wE'
G : Type wG
G' : Type wG'
inst✝¹² : Fintype ι
inst✝¹¹ : Fintype ι'
inst✝¹⁰ : NontriviallyNormedField 𝕜
inst✝⁹ : (i : ι) → SeminormedAddCommGroup (E i)
inst✝⁸ : (i : ι) → NormedSpace 𝕜 (E i)
inst✝⁷ : (i : ι) → SeminormedAddCommGroup (E₁ i)
inst✝⁶ : (i : ι) → NormedSpace 𝕜 (E₁ i)
inst✝⁵ : (i : ι') → SeminormedAddCommGroup (E' i)
inst✝⁴ : (i : ι') → NormedSpace 𝕜 (E' i)
inst✝³ : SeminormedAddCommGroup G
inst✝² : NormedSpace 𝕜 G
inst✝¹ : SeminormedAddCommGroup G'
inst✝ : NormedSpace 𝕜 G'
c : 𝕜
f g : ContinuousMultilinearMap 𝕜 E G
m x : (i : ι) → E i
⊢ ‖(f + g) x‖ ≤ ‖f‖ * ∏ i : ι, ‖x i‖ + ‖g‖ * ∏ i : ι, ‖x i‖
state_after: no goals
Theorem: Finset.untrop_sum
File: Mathlib/Algebra/Tropical/BigOperators.lean

tactic: simpa [← _root_.untrop_sum] using (sum_attach _ _).symm
state_before: R : Type u_1
S : Type u_2
inst✝ : ConditionallyCompleteLinearOrder R
s : Finset S
f : S → Tropical (WithTop R)
⊢ untrop (∑ i ∈ s, f i) = ⨅ i, untrop (f ↑i)
state_after: no goals
Theorem: Multiset.nsmul_cons
File: Mathlib/Data/Multiset/Basic.lean

tactic: rw [← singleton_add, nsmul_add]
state_before: α : Type u_1
β : Type v
γ : Type u_2
s : Multiset α
n : ℕ
a : α
⊢ n • (a ::ₘ s) = n • {a} + n • s
state_after: no goals