1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: IntermediateField.fieldRange_le
File: Mathlib/FieldTheory/IntermediateField.lean

tactic: rwa [Set.mem_range, ← RingHom.mem_fieldRange]
state_before: K : Type u_1
L : Type u_2
L' : Type u_3
inst✝⁴ : Field K
inst✝³ : Field L
inst✝² : Field L'
inst✝¹ : Algebra K L
inst✝ : Algebra K L'
S : IntermediateField K L
x : L
hx : x ∈ (algebraMap K L).fieldRange
⊢ x ∈ Set.range ⇑(algebraMap K L)
state_after: no goals
Theorem: Set.ite_eq_of_subset_right
File: Mathlib/Data/Set/Basic.lean

tactic: ext x
state_before: α : Type u
β : Type v
γ : Type w
ι : Sort x
a b : α
s s₁✝ s₂✝ t✝ t₁ t₂ u t s₁ s₂ : Set α
h : s₂ ⊆ s₁
⊢ t.ite s₁ s₂ = s₁ ∩ t ∪ s₂
state_after: case h
α : Type u
β : Type v
γ : Type w
ι : Sort x
a b : α
s s₁✝ s₂✝ t✝ t₁ t₂ u t s₁ s₂ : Set α
h : s₂ ⊆ s₁
x : α
⊢ x ∈ t.ite s₁ s₂ ↔ x ∈ s₁ ∩ t ∪ s₂

tactic: by_cases hx : x ∈ t <;> simp [*, Set.ite, or_iff_left_of_imp (@h x)]
state_before: case h
α : Type u
β : Type v
γ : Type w
ι : Sort x
a b : α
s s₁✝ s₂✝ t✝ t₁ t₂ u t s₁ s₂ : Set α
h : s₂ ⊆ s₁
x : α
⊢ x ∈ t.ite s₁ s₂ ↔ x ∈ s₁ ∩ t ∪ s₂
state_after: no goals
Theorem: Orientation.cos_oangle_sub_right_of_oangle_eq_pi_div_two
File: Mathlib/Geometry/Euclidean/Angle/Oriented/RightAngle.lean

tactic: have hs : (o.oangle y (y - x)).sign = 1 := by
  rw [oangle_sign_sub_right_swap, 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 y (y - x)).cos = ‖y‖ / ‖y - 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 y (y - x)).sign = 1
⊢ (o.oangle y (y - x)).cos = ‖y‖ / ‖y - x‖

tactic: rw [o.oangle_eq_angle_of_sign_eq_one hs, Real.Angle.cos_coe,
  InnerProductGeometry.cos_angle_sub_of_inner_eq_zero
    (o.inner_rev_eq_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 y (y - x)).sign = 1
⊢ (o.oangle y (y - x)).cos = ‖y‖ / ‖y - x‖
state_after: no goals

tactic: rw [oangle_sign_sub_right_swap, 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 y (y - x)).sign = 1
state_after: no goals
Theorem: Filter.inf_neBot_iff_frequently_left
File: Mathlib/Order/Filter/Bases.lean

tactic: simp only [inf_neBot_iff, frequently_iff, and_comm]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
ι' : Sort u_5
l l' : Filter α
p : ι → Prop
s : ι → Set α
t : Set α
i : ι
p' : ι' → Prop
s' : ι' → Set α
i' : ι'
f g : Filter α
⊢ (f ⊓ g).NeBot ↔ ∀ {p : α → Prop}, (∀ᶠ (x : α) in f, p x) → ∃ᶠ (x : α) in g, p x
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
ι' : Sort u_5
l l' : Filter α
p : ι → Prop
s : ι → Set α
t : Set α
i : ι
p' : ι' → Prop
s' : ι' → Set α
i' : ι'
f g : Filter α
⊢ (∀ ⦃s : Set α⦄, s ∈ f → ∀ ⦃s' : Set α⦄, s' ∈ g → (s ∩ s').Nonempty) ↔
    ∀ {p : α → Prop}, (∀ᶠ (x : α) in f, p x) → ∀ {U : Set α}, U ∈ g → ∃ x, p x ∧ x ∈ U

tactic: rfl
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
ι' : Sort u_5
l l' : Filter α
p : ι → Prop
s : ι → Set α
t : Set α
i : ι
p' : ι' → Prop
s' : ι' → Set α
i' : ι'
f g : Filter α
⊢ (∀ ⦃s : Set α⦄, s ∈ f → ∀ ⦃s' : Set α⦄, s' ∈ g → (s ∩ s').Nonempty) ↔
    ∀ {p : α → Prop}, (∀ᶠ (x : α) in f, p x) → ∀ {U : Set α}, U ∈ g → ∃ x, p x ∧ x ∈ U
state_after: no goals
Theorem: Option.map_pbind
File: Mathlib/Data/Option/Basic.lean

tactic: cases x <;> simp only [pbind, map_none']
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
p : α → Prop
f✝ : (a : α) → p a → β
x✝ : Option α
f : β → γ
x : Option α
g : (a : α) → a ∈ x → Option β
⊢ Option.map f (x.pbind g) = x.pbind fun a H => Option.map f (g a H)
state_after: no goals
Theorem: Irreducible.isRelPrime_iff_not_dvd
File: Mathlib/Algebra/Associated.lean

tactic: refine ⟨fun h contra ↦ hp.not_unit (h dvd_rfl contra), fun hpn d hdp hdn ↦ ?_⟩
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝ : Monoid α
p n : α
hp : Irreducible p
⊢ IsRelPrime p n ↔ ¬p ∣ n
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝ : Monoid α
p n : α
hp : Irreducible p
hpn : ¬p ∣ n
d : α
hdp : d ∣ p
hdn : d ∣ n
⊢ IsUnit d

tactic: contrapose! hpn
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝ : Monoid α
p n : α
hp : Irreducible p
hpn : ¬p ∣ n
d : α
hdp : d ∣ p
hdn : d ∣ n
⊢ IsUnit d
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝ : Monoid α
p n : α
hp : Irreducible p
d : α
hdp : d ∣ p
hdn : d ∣ n
hpn : ¬IsUnit d
⊢ p ∣ n

tactic: suffices Associated p d from this.dvd.trans hdn
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝ : Monoid α
p n : α
hp : Irreducible p
d : α
hdp : d ∣ p
hdn : d ∣ n
hpn : ¬IsUnit d
⊢ p ∣ n
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝ : Monoid α
p n : α
hp : Irreducible p
d : α
hdp : d ∣ p
hdn : d ∣ n
hpn : ¬IsUnit d
⊢ p ~ᵤ d

tactic: exact (hp.dvd_iff.mp hdp).resolve_left hpn
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝ : Monoid α
p n : α
hp : Irreducible p
d : α
hdp : d ∣ p
hdn : d ∣ n
hpn : ¬IsUnit d
⊢ p ~ᵤ d
state_after: no goals
Theorem: Finset.bind_toFinset
File: Mathlib/Data/Finset/Union.lean

tactic: simp only [Multiset.mem_toFinset, mem_biUnion, Multiset.mem_bind, exists_prop]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
s✝ s₁ s₂ : Finset α
t✝ t₁ t₂ : α → Finset β
inst✝¹ : DecidableEq β
inst✝ : DecidableEq α
s : Multiset α
t : α → Multiset β
x : β
⊢ x ∈ (s.bind t).toFinset ↔ x ∈ s.toFinset.biUnion fun a => (t a).toFinset
state_after: no goals
Theorem: ProbabilityTheory.condexpKernel_ae_eq_condexp
File: Mathlib/Probability/Kernel/Condexp.lean

tactic: rw [inf_of_le_left hm]
state_before: Ω : Type u_1
F : Type u_2
m mΩ : MeasurableSpace Ω
inst✝³ : StandardBorelSpace Ω
inst✝² : Nonempty Ω
μ : Measure Ω
inst✝¹ inst✝ : IsFiniteMeasure μ
hm : m ≤ mΩ
s : Set Ω
hs : MeasurableSet s
⊢ μ[s.indicator fun ω => 1|m ⊓ mΩ] =ᶠ[ae μ] μ[s.indicator fun ω => 1|m]
state_after: no goals
Theorem: Real.arctan_add_eq_sub_pi
File: Mathlib/Analysis/SpecialFunctions/Trigonometric/Arctan.lean

tactic: rw [← neg_mul_neg] at h
state_before: x y : ℝ
h : 1 < x * y
hx : x < 0
⊢ arctan x + arctan y = arctan ((x + y) / (1 - x * y)) - π
state_after: x y : ℝ
h : 1 < -x * -y
hx : x < 0
⊢ arctan x + arctan y = arctan ((x + y) / (1 - x * y)) - π

tactic: have k := arctan_add_eq_add_pi h (neg_pos.mpr hx)
state_before: x y : ℝ
h : 1 < -x * -y
hx : x < 0
⊢ arctan x + arctan y = arctan ((x + y) / (1 - x * y)) - π
state_after: x y : ℝ
h : 1 < -x * -y
hx : x < 0
k : arctan (-x) + arctan (-y) = arctan ((-x + -y) / (1 - -x * -y)) + π
⊢ arctan x + arctan y = arctan ((x + y) / (1 - x * y)) - π

tactic: rw [show _ / _ = -((x + y) / (1 - x * y)) by ring, ← neg_inj] at k
state_before: x y : ℝ
h : 1 < -x * -y
hx : x < 0
k : arctan (-x) + arctan (-y) = arctan ((-x + -y) / (1 - -x * -y)) + π
⊢ arctan x + arctan y = arctan ((x + y) / (1 - x * y)) - π
state_after: x y : ℝ
h : 1 < -x * -y
hx : x < 0
k : -(arctan (-x) + arctan (-y)) = -(arctan (-((x + y) / (1 - x * y))) + π)
⊢ arctan x + arctan y = arctan ((x + y) / (1 - x * y)) - π

tactic: simp only [arctan_neg, neg_add, neg_neg, ← sub_eq_add_neg _ π] at k
state_before: x y : ℝ
h : 1 < -x * -y
hx : x < 0
k : -(arctan (-x) + arctan (-y)) = -(arctan (-((x + y) / (1 - x * y))) + π)
⊢ arctan x + arctan y = arctan ((x + y) / (1 - x * y)) - π
state_after: x y : ℝ
h : 1 < -x * -y
hx : x < 0
k : arctan x + arctan y = arctan ((x + y) / (1 - x * y)) - π
⊢ arctan x + arctan y = arctan ((x + y) / (1 - x * y)) - π

tactic: exact k
state_before: x y : ℝ
h : 1 < -x * -y
hx : x < 0
k : arctan x + arctan y = arctan ((x + y) / (1 - x * y)) - π
⊢ arctan x + arctan y = arctan ((x + y) / (1 - x * y)) - π
state_after: no goals

tactic: ring
state_before: x y : ℝ
h : 1 < -x * -y
hx : x < 0
k : arctan (-x) + arctan (-y) = arctan ((-x + -y) / (1 - -x * -y)) + π
⊢ (-x + -y) / (1 - -x * -y) = -((x + y) / (1 - x * y))
state_after: no goals
Theorem: cycles'Map_comp
File: Mathlib/Algebra/Homology/Homology.lean

tactic: dsimp only [cycles'Map]
state_before: ι : Type u_1
V : Type u
inst✝² : Category.{v, u} V
inst✝¹ : HasZeroMorphisms V
c : ComplexShape ι
C : HomologicalComplex V c
inst✝ : HasKernels V
C₁ C₂ C₃ : HomologicalComplex V c
f✝ f : C₁ ⟶ C₂
g : C₂ ⟶ C₃
i : ι
⊢ cycles'Map (f ≫ g) i = cycles'Map f i ≫ cycles'Map g i
state_after: ι : Type u_1
V : Type u
inst✝² : Category.{v, u} V
inst✝¹ : HasZeroMorphisms V
c : ComplexShape ι
C : HomologicalComplex V c
inst✝ : HasKernels V
C₁ C₂ C₃ : HomologicalComplex V c
f✝ f : C₁ ⟶ C₂
g : C₂ ⟶ C₃
i : ι
⊢ (C₃.cycles' i).factorThru ((C₁.cycles' i).arrow ≫ (f ≫ g).f i) ⋯ =
    (C₂.cycles' i).factorThru ((C₁.cycles' i).arrow ≫ f.f i) ⋯ ≫
      (C₃.cycles' i).factorThru ((C₂.cycles' i).arrow ≫ g.f i) ⋯

tactic: simp [Subobject.factorThru_right]
state_before: ι : Type u_1
V : Type u
inst✝² : Category.{v, u} V
inst✝¹ : HasZeroMorphisms V
c : ComplexShape ι
C : HomologicalComplex V c
inst✝ : HasKernels V
C₁ C₂ C₃ : HomologicalComplex V c
f✝ f : C₁ ⟶ C₂
g : C₂ ⟶ C₃
i : ι
⊢ (C₃.cycles' i).factorThru ((C₁.cycles' i).arrow ≫ (f ≫ g).f i) ⋯ =
    (C₂.cycles' i).factorThru ((C₁.cycles' i).arrow ≫ f.f i) ⋯ ≫
      (C₃.cycles' i).factorThru ((C₂.cycles' i).arrow ≫ g.f i) ⋯
state_after: no goals
Theorem: ExpChar.eq
File: Mathlib/Algebra/CharP/ExpChar.lean

tactic: cases' hp with hp _ hp' hp
state_before: R : Type u
inst✝ : Semiring R
p q : ℕ
hp : ExpChar R p
hq : ExpChar R q
⊢ p = q
state_after: case zero
R : Type u
inst✝ : Semiring R
q : ℕ
hq : ExpChar R q
hp : CharZero R
⊢ 1 = q

case prime
R : Type u
inst✝ : Semiring R
p q : ℕ
hq : ExpChar R q
hp' : Nat.Prime p
hp : CharP R p
⊢ p = q

tactic: cases' hq with hq _ hq' hq
state_before: case zero
R : Type u
inst✝ : Semiring R
q : ℕ
hq : ExpChar R q
hp : CharZero R
⊢ 1 = q
state_after: case zero.zero
R : Type u
inst✝ : Semiring R
hp hq : CharZero R
⊢ 1 = 1

case zero.prime
R : Type u
inst✝ : Semiring R
q : ℕ
hp : CharZero R
hq' : Nat.Prime q
hq : CharP R q
⊢ 1 = q

tactic: exacts [rfl, False.elim (Nat.not_prime_zero (CharP.eq R hq (CharP.ofCharZero R) ▸ hq'))]
state_before: case zero.zero
R : Type u
inst✝ : Semiring R
hp hq : CharZero R
⊢ 1 = 1

case zero.prime
R : Type u
inst✝ : Semiring R
q : ℕ
hp : CharZero R
hq' : Nat.Prime q
hq : CharP R q
⊢ 1 = q
state_after: no goals

tactic: cases' hq with hq _ hq' hq
state_before: case prime
R : Type u
inst✝ : Semiring R
p q : ℕ
hq : ExpChar R q
hp' : Nat.Prime p
hp : CharP R p
⊢ p = q
state_after: case prime.zero
R : Type u
inst✝ : Semiring R
p : ℕ
hp' : Nat.Prime p
hp : CharP R p
hq : CharZero R
⊢ p = 1

case prime.prime
R : Type u
inst✝ : Semiring R
p q : ℕ
hp' : Nat.Prime p
hp : CharP R p
hq' : Nat.Prime q
hq : CharP R q
⊢ p = q

tactic: exacts [False.elim (Nat.not_prime_zero (CharP.eq R hp (CharP.ofCharZero R) ▸ hp')),
  CharP.eq R hp hq]
state_before: case prime.zero
R : Type u
inst✝ : Semiring R
p : ℕ
hp' : Nat.Prime p
hp : CharP R p
hq : CharZero R
⊢ p = 1

case prime.prime
R : Type u
inst✝ : Semiring R
p q : ℕ
hp' : Nat.Prime p
hp : CharP R p
hq' : Nat.Prime q
hq : CharP R q
⊢ p = q
state_after: no goals
Theorem: Filter.principal_subtype
File: Mathlib/Order/Filter/Basic.lean

tactic: rw [comap_principal, preimage_image_eq _ Subtype.coe_injective]
state_before: α✝ : Type u
β : Type v
γ : Type w
δ : Type u_1
ι : Sort x
l f f₁ f₂ : Filter α✝
g g₁ g₂ : Filter β
m : α✝ → β
m' : β → γ
s✝ : Set α✝
t✝ : Set β
α : Type u_2
s : Set α
t : Set ↑s
⊢ 𝓟 t = comap Subtype.val (𝓟 (Subtype.val '' t))
state_after: no goals
Theorem: List.concat_get_prefix
File: Mathlib/Data/List/Infix.lean

tactic: use y.drop (x.length + 1)
state_before: α : Type u_1
β : Type u_2
l l₁ l₂ l₃ : List α
a b : α
m n : ℕ
x y : List α
h : x <+: y
hl : x.length < y.length
⊢ x ++ [y.get ⟨x.length, hl⟩] <+: y
state_after: case h
α : Type u_1
β : Type u_2
l l₁ l₂ l₃ : List α
a b : α
m n : ℕ
x y : List α
h : x <+: y
hl : x.length < y.length
⊢ x ++ [y.get ⟨x.length, hl⟩] ++ drop (x.length + 1) y = y

tactic: nth_rw 1 [List.prefix_iff_eq_take.mp h]
state_before: case h
α : Type u_1
β : Type u_2
l l₁ l₂ l₃ : List α
a b : α
m n : ℕ
x y : List α
h : x <+: y
hl : x.length < y.length
⊢ x ++ [y.get ⟨x.length, hl⟩] ++ drop (x.length + 1) y = y
state_after: case h
α : Type u_1
β : Type u_2
l l₁ l₂ l₃ : List α
a b : α
m n : ℕ
x y : List α
h : x <+: y
hl : x.length < y.length
⊢ take x.length y ++ [y.get ⟨x.length, hl⟩] ++ drop (x.length + 1) y = y

tactic: convert List.take_append_drop (x.length + 1) y using 2
state_before: case h
α : Type u_1
β : Type u_2
l l₁ l₂ l₃ : List α
a b : α
m n : ℕ
x y : List α
h : x <+: y
hl : x.length < y.length
⊢ take x.length y ++ [y.get ⟨x.length, hl⟩] ++ drop (x.length + 1) y = y
state_after: case h.e'_2.h.e'_5
α : Type u_1
β : Type u_2
l l₁ l₂ l₃ : List α
a b : α
m n : ℕ
x y : List α
h : x <+: y
hl : x.length < y.length
⊢ take x.length y ++ [y.get ⟨x.length, hl⟩] = take (x.length + 1) y

tactic: rw [← List.take_concat_get, List.concat_eq_append]
state_before: case h.e'_2.h.e'_5
α : Type u_1
β : Type u_2
l l₁ l₂ l₃ : List α
a b : α
m n : ℕ
x y : List α
h : x <+: y
hl : x.length < y.length
⊢ take x.length y ++ [y.get ⟨x.length, hl⟩] = take (x.length + 1) y
state_after: case h.e'_2.h.e'_5
α : Type u_1
β : Type u_2
l l₁ l₂ l₃ : List α
a b : α
m n : ℕ
x y : List α
h : x <+: y
hl : x.length < y.length
⊢ take x.length y ++ [y.get ⟨x.length, hl⟩] = take x.length y ++ [y[x.length]]

case h.e'_2.h.e'_5.h
α : Type u_1
β : Type u_2
l l₁ l₂ l₃ : List α
a b : α
m n : ℕ
x y : List α
h : x <+: y
hl : x.length < y.length
⊢ x.length < y.length

tactic: rfl
state_before: case h.e'_2.h.e'_5
α : Type u_1
β : Type u_2
l l₁ l₂ l₃ : List α
a b : α
m n : ℕ
x y : List α
h : x <+: y
hl : x.length < y.length
⊢ take x.length y ++ [y.get ⟨x.length, hl⟩] = take x.length y ++ [y[x.length]]

case h.e'_2.h.e'_5.h
α : Type u_1
β : Type u_2
l l₁ l₂ l₃ : List α
a b : α
m n : ℕ
x y : List α
h : x <+: y
hl : x.length < y.length
⊢ x.length < y.length
state_after: no goals
Theorem: Submonoid.sup_eq_closure
File: Mathlib/Algebra/Group/Submonoid/Basic.lean

tactic: simp_rw [closure_union, closure_eq]
state_before: M : Type u_1
N✝ : Type u_2
A : Type u_3
inst✝¹ : MulOneClass M
s : Set M
inst✝ : AddZeroClass A
t : Set A
S N N' : Submonoid M
⊢ N ⊔ N' = closure (↑N ∪ ↑N')
state_after: no goals
Theorem: Multiset.lt_singleton
File: Mathlib/Data/Multiset/Basic.lean

tactic: simp only [lt_iff_le_and_ne, le_singleton, or_and_right, Ne, and_not_self, or_false,
  and_iff_left_iff_imp]
state_before: α : Type u_1
β : Type v
γ : Type u_2
s t : Multiset α
a : α
⊢ s < {a} ↔ s = 0
state_after: α : Type u_1
β : Type v
γ : Type u_2
s t : Multiset α
a : α
⊢ s = 0 → ¬s = {a}

tactic: rintro rfl
state_before: α : Type u_1
β : Type v
γ : Type u_2
s t : Multiset α
a : α
⊢ s = 0 → ¬s = {a}
state_after: α : Type u_1
β : Type v
γ : Type u_2
t : Multiset α
a : α
⊢ ¬0 = {a}

tactic: exact (singleton_ne_zero _).symm
state_before: α : Type u_1
β : Type v
γ : Type u_2
t : Multiset α
a : α
⊢ ¬0 = {a}
state_after: no goals
Theorem: LinearMap.isSkewAdjoint_iff_neg_self_adjoint
File: Mathlib/LinearAlgebra/SesquilinearForm.lean

tactic: simp
state_before: R : Type u_1
R₁ : Type u_2
R₂ : Type u_3
R₃ : Type u_4
M : Type u_5
M₁ : Type u_6
M₂ : Type u_7
M₃ : Type u_8
Mₗ₁ : Type u_9
Mₗ₁' : Type u_10
Mₗ₂ : Type u_11
Mₗ₂' : Type u_12
K : Type u_13
K₁ : Type u_14
K₂ : Type u_15
V : Type u_16
V₁ : Type u_17
V₂ : Type u_18
n : Type u_19
inst✝⁶ : CommRing R
inst✝⁵ : AddCommGroup M
inst✝⁴ : Module R M
inst✝³ : AddCommGroup M₁
inst✝² : Module R M₁
inst✝¹ : AddCommGroup M₂
inst✝ : Module R M₂
B F : M →ₗ[R] M →ₗ[R] M₂
f : Module.End R M
⊢ (∀ (x y : M), (B (f x)) y = (B x) ((-f) y)) ↔ ∀ (x y : M), (B (f x)) y = ((-B) x) (f y)
state_after: no goals
Theorem: trop_sum
File: Mathlib/Algebra/Tropical/BigOperators.lean

tactic: convert Multiset.trop_sum (s.val.map f)
state_before: R : Type u_1
S : Type u_2
inst✝ : AddCommMonoid R
s : Finset S
f : S → R
⊢ trop (∑ i ∈ s, f i) = ∏ i ∈ s, trop (f i)
state_after: case h.e'_3
R : Type u_1
S : Type u_2
inst✝ : AddCommMonoid R
s : Finset S
f : S → R
⊢ ∏ i ∈ s, trop (f i) = (Multiset.map trop (Multiset.map f s.val)).prod

tactic: simp only [Multiset.map_map, Function.comp_apply]
state_before: case h.e'_3
R : Type u_1
S : Type u_2
inst✝ : AddCommMonoid R
s : Finset S
f : S → R
⊢ ∏ i ∈ s, trop (f i) = (Multiset.map trop (Multiset.map f s.val)).prod
state_after: case h.e'_3
R : Type u_1
S : Type u_2
inst✝ : AddCommMonoid R
s : Finset S
f : S → R
⊢ ∏ i ∈ s, trop (f i) = (Multiset.map (fun i => trop (f i)) s.val).prod

tactic: rfl
state_before: case h.e'_3
R : Type u_1
S : Type u_2
inst✝ : AddCommMonoid R
s : Finset S
f : S → R
⊢ ∏ i ∈ s, trop (f i) = (Multiset.map (fun i => trop (f i)) s.val).prod
state_after: no goals
Theorem: spectrum.not_mem_iff
File: Mathlib/Algebra/Algebra/Spectrum.lean

tactic: apply not_iff_not.mp
state_before: R : Type u
A : Type v
inst✝² : CommSemiring R
inst✝¹ : Ring A
inst✝ : Algebra R A
r : R
a : A
⊢ r ∉ σ a ↔ IsUnit (↑ₐ r - a)
state_after: R : Type u
A : Type v
inst✝² : CommSemiring R
inst✝¹ : Ring A
inst✝ : Algebra R A
r : R
a : A
⊢ ¬r ∉ σ a ↔ ¬IsUnit (↑ₐ r - a)

tactic: simp [Set.not_not_mem, mem_iff]
state_before: R : Type u
A : Type v
inst✝² : CommSemiring R
inst✝¹ : Ring A
inst✝ : Algebra R A
r : R
a : A
⊢ ¬r ∉ σ a ↔ ¬IsUnit (↑ₐ r - a)
state_after: no goals
Theorem: Summable.of_nonneg_of_le
File: Mathlib/Topology/Instances/ENNReal.lean

tactic: lift f to β → ℝ≥0 using fun b => (hg b).trans (hgf b)
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
f g : β → ℝ
hg : ∀ (b : β), 0 ≤ g b
hgf : ∀ (b : β), g b ≤ f b
hf : Summable f
⊢ Summable g
state_after: case intro
α : Type u_1
β : Type u_2
γ : Type u_3
g : β → ℝ
hg : ∀ (b : β), 0 ≤ g b
f : β → ℝ≥0
hgf : ∀ (b : β), g b ≤ (fun i => ↑(f i)) b
hf : Summable fun i => ↑(f i)
⊢ Summable g

tactic: lift g to β → ℝ≥0 using hg
state_before: case intro
α : Type u_1
β : Type u_2
γ : Type u_3
g : β → ℝ
hg : ∀ (b : β), 0 ≤ g b
f : β → ℝ≥0
hgf : ∀ (b : β), g b ≤ (fun i => ↑(f i)) b
hf : Summable fun i => ↑(f i)
⊢ Summable g
state_after: case intro.intro
α : Type u_1
β : Type u_2
γ : Type u_3
f : β → ℝ≥0
hf : Summable fun i => ↑(f i)
g : β → ℝ≥0
hgf : ∀ (b : β), (fun i => ↑(g i)) b ≤ (fun i => ↑(f i)) b
⊢ Summable fun i => ↑(g i)

tactic: rw [NNReal.summable_coe] at hf ⊢
state_before: case intro.intro
α : Type u_1
β : Type u_2
γ : Type u_3
f : β → ℝ≥0
hf : Summable fun i => ↑(f i)
g : β → ℝ≥0
hgf : ∀ (b : β), (fun i => ↑(g i)) b ≤ (fun i => ↑(f i)) b
⊢ Summable fun i => ↑(g i)
state_after: case intro.intro
α : Type u_1
β : Type u_2
γ : Type u_3
f : β → ℝ≥0
hf : Summable f
g : β → ℝ≥0
hgf : ∀ (b : β), (fun i => ↑(g i)) b ≤ (fun i => ↑(f i)) b
⊢ Summable g

tactic: exact NNReal.summable_of_le (fun b => NNReal.coe_le_coe.1 (hgf b)) hf
state_before: case intro.intro
α : Type u_1
β : Type u_2
γ : Type u_3
f : β → ℝ≥0
hf : Summable f
g : β → ℝ≥0
hgf : ∀ (b : β), (fun i => ↑(g i)) b ≤ (fun i => ↑(f i)) b
⊢ Summable g
state_after: no goals
Theorem: Finset.disjSups_inter_subset_left
File: Mathlib/Data/Finset/Sups.lean

tactic: simpa only [disjSups, inter_product, filter_inter_distrib] using image_inter_subset _ _ _
state_before: F : Type u_1
α : Type u_2
β : Type u_3
inst✝⁴ : DecidableEq α
inst✝³ : DecidableEq β
inst✝² : SemilatticeSup α
inst✝¹ : OrderBot α
inst✝ : DecidableRel Disjoint
s s₁ s₂ t t₁ t₂ u : Finset α
a b c : α
⊢ (s₁ ∩ s₂) ○ t ⊆ s₁ ○ t ∩ s₂ ○ t
state_after: no goals
Theorem: Polynomial.derivative_bernoulli_add_one
File: Mathlib/NumberTheory/BernoulliPolynomials.lean

tactic: simp_rw [bernoulli, derivative_sum, derivative_monomial, Nat.sub_sub, Nat.add_sub_add_right]
state_before: k : ℕ
⊢ derivative (bernoulli (k + 1)) = (↑k + 1) * bernoulli k
state_after: k : ℕ
⊢ ∑ x ∈ range (k + 1 + 1), (monomial (k - x)) (_root_.bernoulli x * ↑((k + 1).choose x) * ↑(k + 1 - x)) =
    (↑k + 1) * ∑ i ∈ range (k + 1), (monomial (k - i)) (_root_.bernoulli i * ↑(k.choose i))

tactic: rw [range_add_one, sum_insert not_mem_range_self, tsub_self, cast_zero, mul_zero,
  map_zero, zero_add, mul_sum]
state_before: k : ℕ
⊢ ∑ x ∈ range (k + 1 + 1), (monomial (k - x)) (_root_.bernoulli x * ↑((k + 1).choose x) * ↑(k + 1 - x)) =
    (↑k + 1) * ∑ i ∈ range (k + 1), (monomial (k - i)) (_root_.bernoulli i * ↑(k.choose i))
state_after: k : ℕ
⊢ ∑ x ∈ range (k + 1), (monomial (k - x)) (_root_.bernoulli x * ↑((k + 1).choose x) * ↑(k + 1 - x)) =
    ∑ i ∈ range (k + 1), (↑k + 1) * (monomial (k - i)) (_root_.bernoulli i * ↑(k.choose i))

tactic: refine sum_congr (by rfl) fun m _ => ?_
state_before: k : ℕ
⊢ ∑ x ∈ range (k + 1), (monomial (k - x)) (_root_.bernoulli x * ↑((k + 1).choose x) * ↑(k + 1 - x)) =
    ∑ i ∈ range (k + 1), (↑k + 1) * (monomial (k - i)) (_root_.bernoulli i * ↑(k.choose i))
state_after: k m : ℕ
x✝ : m ∈ range (k + 1)
⊢ (monomial (k - m)) (_root_.bernoulli m * ↑((k + 1).choose m) * ↑(k + 1 - m)) =
    (↑k + 1) * (monomial (k - m)) (_root_.bernoulli m * ↑(k.choose m))

tactic: conv_rhs => rw [← Nat.cast_one, ← Nat.cast_add, ← C_eq_natCast, C_mul_monomial, mul_comm]
state_before: k m : ℕ
x✝ : m ∈ range (k + 1)
⊢ (monomial (k - m)) (_root_.bernoulli m * ↑((k + 1).choose m) * ↑(k + 1 - m)) =
    (↑k + 1) * (monomial (k - m)) (_root_.bernoulli m * ↑(k.choose m))
state_after: k m : ℕ
x✝ : m ∈ range (k + 1)
⊢ (monomial (k - m)) (_root_.bernoulli m * ↑((k + 1).choose m) * ↑(k + 1 - m)) =
    (monomial (k - m)) (_root_.bernoulli m * ↑(k.choose m) * ↑(k + 1))

tactic: rw [mul_assoc, mul_assoc, ← Nat.cast_mul, ← Nat.cast_mul]
state_before: k m : ℕ
x✝ : m ∈ range (k + 1)
⊢ (monomial (k - m)) (_root_.bernoulli m * ↑((k + 1).choose m) * ↑(k + 1 - m)) =
    (monomial (k - m)) (_root_.bernoulli m * ↑(k.choose m) * ↑(k + 1))
state_after: k m : ℕ
x✝ : m ∈ range (k + 1)
⊢ (monomial (k - m)) (_root_.bernoulli m * ↑((k + 1).choose m * (k + 1 - m))) =
    (monomial (k - m)) (_root_.bernoulli m * ↑(k.choose m * (k + 1)))

tactic: congr 3
state_before: k m : ℕ
x✝ : m ∈ range (k + 1)
⊢ (monomial (k - m)) (_root_.bernoulli m * ↑((k + 1).choose m * (k + 1 - m))) =
    (monomial (k - m)) (_root_.bernoulli m * ↑(k.choose m * (k + 1)))
state_after: case h.e_6.h.e_a.e_a
k m : ℕ
x✝ : m ∈ range (k + 1)
⊢ (k + 1).choose m * (k + 1 - m) = k.choose m * (k + 1)

tactic: rw [(choose_mul_succ_eq k m).symm]
state_before: case h.e_6.h.e_a.e_a
k m : ℕ
x✝ : m ∈ range (k + 1)
⊢ (k + 1).choose m * (k + 1 - m) = k.choose m * (k + 1)
state_after: no goals

tactic: rfl
state_before: k : ℕ
⊢ range (k + 1) = range (k + 1)
state_after: no goals
Theorem: RatFunc.laurent_laurent
File: Mathlib/FieldTheory/Laurent.lean

tactic: induction f using RatFunc.induction_on
state_before: R : Type u
inst✝ : CommRing R
hdomain : IsDomain R
r s : R
p q : R[X]
f : RatFunc R
⊢ (laurent r) ((laurent s) f) = (laurent (r + s)) f
state_after: case f
R : Type u
inst✝ : CommRing R
hdomain : IsDomain R
r s : R
p q : R[X]
f : RatFunc R
p✝ q✝ : R[X]
hq✝ : q✝ ≠ 0
⊢ (laurent r) ((laurent s) ((algebraMap R[X] (RatFunc R)) p✝ / (algebraMap R[X] (RatFunc R)) q✝)) =
    (laurent (r + s)) ((algebraMap R[X] (RatFunc R)) p✝ / (algebraMap R[X] (RatFunc R)) q✝)

tactic: simp_rw [laurent_div, taylor_taylor]
state_before: case f
R : Type u
inst✝ : CommRing R
hdomain : IsDomain R
r s : R
p q : R[X]
f : RatFunc R
p✝ q✝ : R[X]
hq✝ : q✝ ≠ 0
⊢ (laurent r) ((laurent s) ((algebraMap R[X] (RatFunc R)) p✝ / (algebraMap R[X] (RatFunc R)) q✝)) =
    (laurent (r + s)) ((algebraMap R[X] (RatFunc R)) p✝ / (algebraMap R[X] (RatFunc R)) q✝)
state_after: no goals