tasksource/leandojo huggingface dataset:
Theorem: multiset_prod_mem
File: Mathlib/GroupTheory/Submonoid/Membership.lean

tactic: lift m to Multiset S using hm
state_before: M✝ : Type ?u.14811
A : Type ?u.14814
B : Type u_2
inst✝⁵ : Monoid M✝
inst✝⁴ : SetLike B M✝
inst✝³ : SubmonoidClass B M✝
S : B
M : Type u_1
inst✝² : CommMonoid M
inst✝¹ : SetLike B M
inst✝ : SubmonoidClass B M
m : Multiset M
hm : ∀ (a : M), a ∈ m → a ∈ S
⊢ Multiset.prod m ∈ S

tactic: rw [← coe_multiset_prod]
state_before: case intro
M✝ : Type ?u.14811
A : Type ?u.14814
B : Type u_2
inst✝⁵ : Monoid M✝
inst✝⁴ : SetLike B M✝
inst✝³ : SubmonoidClass B M✝
S : B
M : Type u_1
inst✝² : CommMonoid M
inst✝¹ : SetLike B M
inst✝ : SubmonoidClass B M
m : Multiset { x // x ∈ S }
⊢ Multiset.prod (Multiset.map Subtype.val m) ∈ S

tactic: exact m.prod.coe_prop
state_before: case intro
M✝ : Type ?u.14811
A : Type ?u.14814
B : Type u_2
inst✝⁵ : Monoid M✝
inst✝⁴ : SetLike B M✝
inst✝³ : SubmonoidClass B M✝
S : B
M : Type u_1
inst✝² : CommMonoid M
inst✝¹ : SetLike B M
inst✝ : SubmonoidClass B M
m : Multiset { x // x ∈ S }
⊢ ↑(Multiset.prod m) ∈ S
Theorem: CategoryTheory.Limits.image.compIso_inv_comp_image_ι
File: Mathlib/CategoryTheory/Limits/Shapes/Images.lean

tactic: ext
state_before: C : Type u
inst✝³ : Category C
X Y : C
f : X ⟶ Y
Z : C
g : Y ⟶ Z
inst✝² : HasEqualizers C
inst✝¹ : HasImage f
inst✝ : IsIso g
⊢ (compIso f g).inv ≫ ι f = ι (f ≫ g) ≫ inv g

tactic: simp [image.compIso]
state_before: case w
C : Type u
inst✝³ : Category C
X Y : C
f : X ⟶ Y
Z : C
g : Y ⟶ Z
inst✝² : HasEqualizers C
inst✝¹ : HasImage f
inst✝ : IsIso g
⊢ factorThruImage (f ≫ g) ≫ (compIso f g).inv ≫ ι f = factorThruImage (f ≫ g) ≫ ι (f ≫ g) ≫ inv g
Theorem: Cardinal.lt_univ
File: Mathlib/SetTheory/Ordinal/Basic.lean

tactic: have := ord_lt_ord.2 h
state_before: α : Type ?u.234970
β : Type ?u.234973
γ : Type ?u.234976
r : α → α → Prop
s : β → β → Prop
t : γ → γ → Prop
c : Cardinal
h : c < univ
⊢ ∃ c', c = lift c'

tactic: rw [ord_univ] at this
state_before: α : Type ?u.234970
β : Type ?u.234973
γ : Type ?u.234976
r : α → α → Prop
s : β → β → Prop
t : γ → γ → Prop
c : Cardinal
h : c < univ
this : ord c < ord univ
⊢ ∃ c', c = lift c'

tactic: cases' lift.principalSeg.{u, u + 1}.down.1 (by simpa only [lift.principalSeg_top] ) with o e
state_before: α : Type ?u.234970
β : Type ?u.234973
γ : Type ?u.234976
r : α → α → Prop
s : β → β → Prop
t : γ → γ → Prop
c : Cardinal
h : c < univ
this : ord c < Ordinal.univ
⊢ ∃ c', c = lift c'

tactic: have := card_ord c
state_before: case intro
α : Type ?u.234970
β : Type ?u.234973
γ : Type ?u.234976
r : α → α → Prop
s : β → β → Prop
t : γ → γ → Prop
c : Cardinal
h : c < univ
this : ord c < Ordinal.univ
o : Ordinal
e : ↑lift.principalSeg.toRelEmbedding o = ord c
⊢ ∃ c', c = lift c'

tactic: rw [← e, lift.principalSeg_coe, ← lift_card] at this
state_before: case intro
α : Type ?u.234970
β : Type ?u.234973
γ : Type ?u.234976
r : α → α → Prop
s : β → β → Prop
t : γ → γ → Prop
c : Cardinal
h : c < univ
this✝ : ord c < Ordinal.univ
o : Ordinal
e : ↑lift.principalSeg.toRelEmbedding o = ord c
this : card (ord c) = c
⊢ ∃ c', c = lift c'

tactic: exact ⟨_, this.symm⟩
state_before: case intro
α : Type ?u.234970
β : Type ?u.234973
γ : Type ?u.234976
r : α → α → Prop
s : β → β → Prop
t : γ → γ → Prop
c : Cardinal
h : c < univ
this✝ : ord c < Ordinal.univ
o : Ordinal
e : ↑lift.principalSeg.toRelEmbedding o = ord c
this : lift (card o) = c
⊢ ∃ c', c = lift c'

tactic: simpa only [lift.principalSeg_top]
state_before: α : Type ?u.234970
β : Type ?u.234973
γ : Type ?u.234976
r : α → α → Prop
s : β → β → Prop
t : γ → γ → Prop
c : Cardinal
h : c < univ
this : ord c < Ordinal.univ
⊢ ?m.235236 < lift.principalSeg.top
Theorem: preperfect_iff_nhds
File: Mathlib/Topology/Perfect.lean

tactic: simp only [Preperfect, accPt_iff_nhds]
state_before: α : Type u_1
inst✝ : TopologicalSpace α
C : Set α
⊢ Preperfect C ↔ ∀ (x : α), x ∈ C → ∀ (U : Set α), U ∈ 𝓝 x → ∃ y, y ∈ U ∩ C ∧ y ≠ x
Theorem: Stream'.WSeq.ofList_cons
File: Mathlib/Data/Seq/WSeq.lean

tactic: simp
state_before: α : Type u
β : Type v
γ : Type w
a : α
l : List α
⊢ Seq.map some ↑(a :: l) = Seq.cons (some a) (Seq.map some ↑l)
Theorem: Sum.Ioo_inl_inr
File: Mathlib/Data/Sum/Interval.lean

tactic: rfl
state_before: α : Type u_1
β : Type u_2
inst✝³ : Preorder α
inst✝² : Preorder β
inst✝¹ : LocallyFiniteOrder α
inst✝ : LocallyFiniteOrder β
a₁ a₂ : α
b₁ b₂ : β
a b : α ⊕ β
⊢ Ioo (inl a₁) (inr b₂) = ∅
Theorem: PNat.XgcdType.flip_isReduced
File: Mathlib/Data/PNat/Xgcd.lean

tactic: dsimp [IsReduced, flip]
state_before: u : XgcdType
⊢ IsReduced (flip u) ↔ IsReduced u

tactic: constructor <;> intro h <;> exact h.symm
state_before: u : XgcdType
⊢ u.bp = u.ap ↔ u.ap = u.bp
Theorem: disjoin_manyOneReducible
File: Mathlib/Computability/Reduce.lean

tactic: cases x <;> [apply h₁; apply h₂]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝² : Primcodable α
inst✝¹ : Primcodable β
inst✝ : Primcodable γ
p : α → Prop
q : β → Prop
r : γ → Prop
f : α → γ
c₁ : Computable f
h₁ : ∀ (a : α), p a ↔ r (f a)
g : β → γ
c₂ : Computable g
h₂ : ∀ (a : β), q a ↔ r (g a)
x : α ⊕ β
⊢ (p ⊕' q) x ↔ r ((f ⊕' g) x)
Theorem: Submodule.mem_span_insert
File: Mathlib/LinearAlgebra/Span.lean

tactic: simp only [← union_singleton, span_union, mem_sup, mem_span_singleton, exists_prop,
  exists_exists_eq_and]
state_before: R : Type u_2
R₂ : Type ?u.162771
K : Type ?u.162774
M : Type u_1
M₂ : Type ?u.162780
V : Type ?u.162783
S : Type ?u.162786
inst✝⁵ : Semiring R
inst✝⁴ : AddCommMonoid M
inst✝³ : Module R M
x : M
p p' : Submodule R M
inst✝² : Semiring R₂
σ₁₂ : R →+* R₂
inst✝¹ : AddCommMonoid M₂
inst✝ : Module R₂ M₂
s t : Set M
y : M
⊢ x ∈ span R (insert y s) ↔ ∃ a z, z ∈ span R s ∧ x = a • y + z

tactic: rw [exists_comm]
state_before: R : Type u_2
R₂ : Type ?u.162771
K : Type ?u.162774
M : Type u_1
M₂ : Type ?u.162780
V : Type ?u.162783
S : Type ?u.162786
inst✝⁵ : Semiring R
inst✝⁴ : AddCommMonoid M
inst✝³ : Module R M
x : M
p p' : Submodule R M
inst✝² : Semiring R₂
σ₁₂ : R →+* R₂
inst✝¹ : AddCommMonoid M₂
inst✝ : Module R₂ M₂
s t : Set M
y : M
⊢ (∃ y_1, y_1 ∈ span R s ∧ ∃ a, y_1 + a • y = x) ↔ ∃ a z, z ∈ span R s ∧ x = a • y + z

tactic: simp only [eq_comm, add_comm, exists_and_left]
state_before: R : Type u_2
R₂ : Type ?u.162771
K : Type ?u.162774
M : Type u_1
M₂ : Type ?u.162780
V : Type ?u.162783
S : Type ?u.162786
inst✝⁵ : Semiring R
inst✝⁴ : AddCommMonoid M
inst✝³ : Module R M
x : M
p p' : Submodule R M
inst✝² : Semiring R₂
σ₁₂ : R →+* R₂
inst✝¹ : AddCommMonoid M₂
inst✝ : Module R₂ M₂
s t : Set M
y : M
⊢ (∃ y_1, y_1 ∈ span R s ∧ ∃ a, y_1 + a • y = x) ↔ ∃ b a, b ∈ span R s ∧ x = a • y + b
Theorem: Int.rel_of_forall_rel_succ_of_lt
File: Mathlib/Order/Monotone/Basic.lean

tactic: rcases lt.dest hab with ⟨n, rfl⟩
state_before: ι : Type ?u.42313
α : Type u
β : Type v
γ : Type w
δ : Type ?u.42322
π : ι → Type ?u.42327
r✝ : α → α → Prop
inst✝¹ : Preorder α
r : β → β → Prop
inst✝ : IsTrans β r
f : ℤ → β
h : ∀ (n : ℤ), r (f n) (f (n + 1))
a b : ℤ
hab : a < b
⊢ r (f a) (f b)

tactic: clear hab
state_before: case intro
ι : Type ?u.42313
α : Type u
β : Type v
γ : Type w
δ : Type ?u.42322
π : ι → Type ?u.42327
r✝ : α → α → Prop
inst✝¹ : Preorder α
r : β → β → Prop
inst✝ : IsTrans β r
f : ℤ → β
h : ∀ (n : ℤ), r (f n) (f (n + 1))
a : ℤ
n : ℕ
hab : a < a + ↑(Nat.succ n)
⊢ r (f a) (f (a + ↑(Nat.succ n)))

tactic: induction' n with n ihn
state_before: case intro
ι : Type ?u.42313
α : Type u
β : Type v
γ : Type w
δ : Type ?u.42322
π : ι → Type ?u.42327
r✝ : α → α → Prop
inst✝¹ : Preorder α
r : β → β → Prop
inst✝ : IsTrans β r
f : ℤ → β
h : ∀ (n : ℤ), r (f n) (f (n + 1))
a : ℤ
n : ℕ
⊢ r (f a) (f (a + ↑(Nat.succ n)))

tactic: rw [Int.ofNat_one]
state_before: case intro.zero
ι : Type ?u.42313
α : Type u
β : Type v
γ : Type w
δ : Type ?u.42322
π : ι → Type ?u.42327
r✝ : α → α → Prop
inst✝¹ : Preorder α
r : β → β → Prop
inst✝ : IsTrans β r
f : ℤ → β
h : ∀ (n : ℤ), r (f n) (f (n + 1))
a : ℤ
⊢ r (f a) (f (a + ↑(Nat.succ Nat.zero)))

tactic: apply h
state_before: case intro.zero
ι : Type ?u.42313
α : Type u
β : Type v
γ : Type w
δ : Type ?u.42322
π : ι → Type ?u.42327
r✝ : α → α → Prop
inst✝¹ : Preorder α
r : β → β → Prop
inst✝ : IsTrans β r
f : ℤ → β
h : ∀ (n : ℤ), r (f n) (f (n + 1))
a : ℤ
⊢ r (f a) (f (a + 1))

tactic: rw [Int.ofNat_succ, ← Int.add_assoc]
state_before: case intro.succ
ι : Type ?u.42313
α : Type u
β : Type v
γ : Type w
δ : Type ?u.42322
π : ι → Type ?u.42327
r✝ : α → α → Prop
inst✝¹ : Preorder α
r : β → β → Prop
inst✝ : IsTrans β r
f : ℤ → β
h : ∀ (n : ℤ), r (f n) (f (n + 1))
a : ℤ
n : ℕ
ihn : r (f a) (f (a + ↑(Nat.succ n)))
⊢ r (f a) (f (a + ↑(Nat.succ (Nat.succ n))))

tactic: exact _root_.trans ihn (h _)
state_before: case intro.succ
ι : Type ?u.42313
α : Type u
β : Type v
γ : Type w
δ : Type ?u.42322
π : ι → Type ?u.42327
r✝ : α → α → Prop
inst✝¹ : Preorder α
r : β → β → Prop
inst✝ : IsTrans β r
f : ℤ → β
h : ∀ (n : ℤ), r (f n) (f (n + 1))
a : ℤ
n : ℕ
ihn : r (f a) (f (a + ↑(Nat.succ n)))
⊢ r (f a) (f (a + ↑(n + 1) + 1))
Theorem: Succ.rec_iff
File: Mathlib/Order/SuccPred/Basic.lean

tactic: obtain ⟨n, rfl⟩ := h.exists_succ_iterate
state_before: α : Type u_1
inst✝² : Preorder α
inst✝¹ : SuccOrder α
inst✝ : IsSuccArchimedean α
a✝ b✝ : α
p : α → Prop
hsucc : ∀ (a : α), p a ↔ p (succ a)
a b : α
h : a ≤ b
⊢ p a ↔ p b

tactic: exact Iterate.rec (fun b => p a ↔ p b) (fun c hc => hc.trans (hsucc _)) Iff.rfl n
state_before: case intro
α : Type u_1
inst✝² : Preorder α
inst✝¹ : SuccOrder α
inst✝ : IsSuccArchimedean α
a✝ b : α
p : α → Prop
hsucc : ∀ (a : α), p a ↔ p (succ a)
a : α
n : ℕ
h : a ≤ (succ^[n]) a
⊢ p a ↔ p ((succ^[n]) a)
Theorem: List.Sublist.trans
File: Std/Data/List/Lemmas.lean

tactic: induction h₂ generalizing l₁ with
| slnil => exact h₁
| cons _ _ IH => exact (IH h₁).cons _
| @cons₂ l₂ _ a _ IH =>
  generalize e : a :: l₂ = l₂'
  match e ▸ h₁ with
  | .slnil => apply nil_sublist
  | .cons a' h₁' => cases e; apply (IH h₁').cons
  | .cons₂ a' h₁' => cases e; apply (IH h₁').cons₂
state_before: α : Type u_1
l₁ l₂ l₃ : List α
h₁ : l₁ <+ l₂
h₂ : l₂ <+ l₃
⊢ l₁ <+ l₃

tactic: exact h₁
state_before: case slnil
α : Type u_1
l₂ l₃ l₁ : List α
h₁ : l₁ <+ []
⊢ l₁ <+ []

tactic: exact (IH h₁).cons _
state_before: case cons
α : Type u_1
l₂ l₃ l₁✝ l₂✝ : List α
a✝¹ : α
a✝ : l₁✝ <+ l₂✝
IH : ∀ {l₁ : List α}, l₁ <+ l₁✝ → l₁ <+ l₂✝
l₁ : List α
h₁ : l₁ <+ l₁✝
⊢ l₁ <+ a✝¹ :: l₂✝

tactic: generalize e : a :: l₂ = l₂'
state_before: case cons₂
α : Type u_1
l₂✝¹ l₃ l₂ l₂✝ : List α
a : α
a✝ : l₂ <+ l₂✝
IH : ∀ {l₁ : List α}, l₁ <+ l₂ → l₁ <+ l₂✝
l₁ : List α
h₁ : l₁ <+ a :: l₂
⊢ l₁ <+ a :: l₂✝

tactic: match e ▸ h₁ with
| .slnil => apply nil_sublist
| .cons a' h₁' => cases e; apply (IH h₁').cons
| .cons₂ a' h₁' => cases e; apply (IH h₁').cons₂
state_before: case cons₂
α : Type u_1
l₂✝¹ l₃ l₂ l₂✝ : List α
a : α
a✝ : l₂ <+ l₂✝
IH : ∀ {l₁ : List α}, l₁ <+ l₂ → l₁ <+ l₂✝
l₁ : List α
h₁ : l₁ <+ a :: l₂
l₂' : List α
e : a :: l₂ = l₂'
⊢ l₁ <+ a :: l₂✝

tactic: apply nil_sublist
state_before: α : Type u_1
l₂✝¹ l₃ l₂ l₂✝ : List α
a : α
a✝ : l₂ <+ l₂✝
IH : ∀ {l₁ : List α}, l₁ <+ l₂ → l₁ <+ l₂✝
h₁ : [] <+ a :: l₂
e : a :: l₂ = []
⊢ [] <+ a :: l₂✝

tactic: cases e
state_before: α : Type u_1
l₂✝² l₃ l₂ l₂✝¹ : List α
a : α
a✝ : l₂ <+ l₂✝¹
IH : ∀ {l₁ : List α}, l₁ <+ l₂ → l₁ <+ l₂✝¹
l₁ l₂✝ : List α
a' : α
h₁' : l₁ <+ l₂✝
h₁ : l₁ <+ a :: l₂
e : a :: l₂ = a' :: l₂✝
⊢ l₁ <+ a :: l₂✝¹

tactic: apply (IH h₁').cons
state_before: case refl
α : Type u_1
l₂✝¹ l₃ l₂ l₂✝ : List α
a : α
a✝ : l₂ <+ l₂✝
IH : ∀ {l₁ : List α}, l₁ <+ l₂ → l₁ <+ l₂✝
l₁ : List α
h₁ : l₁ <+ a :: l₂
h₁' : l₁ <+ l₂
⊢ l₁ <+ a :: l₂✝

tactic: cases e
state_before: α : Type u_1
l₂✝² l₃ l₂ l₂✝¹ : List α
a : α
a✝ : l₂ <+ l₂✝¹
IH : ∀ {l₁ : List α}, l₁ <+ l₂ → l₁ <+ l₂✝¹
l₁✝ l₂✝ : List α
a' : α
h₁' : l₁✝ <+ l₂✝
h₁ : a' :: l₁✝ <+ a :: l₂
e : a :: l₂ = a' :: l₂✝
⊢ a' :: l₁✝ <+ a :: l₂✝¹

tactic: apply (IH h₁').cons₂
state_before: case refl
α : Type u_1
l₂✝¹ l₃ l₂ l₂✝ : List α
a : α
a✝ : l₂ <+ l₂✝
IH : ∀ {l₁ : List α}, l₁ <+ l₂ → l₁ <+ l₂✝
l₁✝ : List α
h₁ : a :: l₁✝ <+ a :: l₂
h₁' : l₁✝ <+ l₂
⊢ a :: l₁✝ <+ a :: l₂✝
Theorem: Subalgebra.fg_of_fg_toSubmodule
File: Mathlib/RingTheory/Adjoin/FG.lean

tactic: rw [ht]
state_before: R : Type u
A : Type v
B : Type w
inst✝⁴ : CommSemiring R
inst✝³ : Semiring A
inst✝² : Algebra R A
inst✝¹ : Semiring B
inst✝ : Algebra R B
S : Subalgebra R A
x✝ : Submodule.FG (↑toSubmodule S)
t : Finset A
ht : span R ↑t = ↑toSubmodule S
x : A
hx : x ∈ ↑toSubmodule S
⊢ x ∈ span R ↑t

tactic: exact hx
state_before: R : Type u
A : Type v
B : Type w
inst✝⁴ : CommSemiring R
inst✝³ : Semiring A
inst✝² : Algebra R A
inst✝¹ : Semiring B
inst✝ : Algebra R B
S : Subalgebra R A
x✝ : Submodule.FG (↑toSubmodule S)
t : Finset A
ht : span R ↑t = ↑toSubmodule S
x : A
hx : x ∈ ↑toSubmodule S
⊢ x ∈ ↑toSubmodule S
Theorem: PowerBasis.minpolyGen_monic
File: Mathlib/RingTheory/PowerBasis.lean

tactic: nontriviality A
state_before: R : Type ?u.111432
S : Type u_2
T : Type ?u.111438
inst✝⁸ : CommRing R
inst✝⁷ : Ring S
inst✝⁶ : Algebra R S
A : Type u_1
B : Type ?u.111744
inst✝⁵ : CommRing A
inst✝⁴ : CommRing B
inst✝³ : IsDomain B
inst✝² : Algebra A B
K : Type ?u.112166
inst✝¹ : Field K
inst✝ : Algebra A S
pb : PowerBasis A S
⊢ Monic (minpolyGen pb)

tactic: apply (monic_X_pow _).sub_of_left _
state_before: R : Type ?u.111432
S : Type u_2
T : Type ?u.111438
inst✝⁸ : CommRing R
inst✝⁷ : Ring S
inst✝⁶ : Algebra R S
A : Type u_1
B : Type ?u.111744
inst✝⁵ : CommRing A
inst✝⁴ : CommRing B
inst✝³ : IsDomain B
inst✝² : Algebra A B
K : Type ?u.112166
inst✝¹ : Field K
inst✝ : Algebra A S
pb : PowerBasis A S
✝ : Nontrivial A
⊢ Monic (minpolyGen pb)

tactic: rw [degree_X_pow]
state_before: R : Type ?u.111432
S : Type u_2
T : Type ?u.111438
inst✝⁸ : CommRing R
inst✝⁷ : Ring S
inst✝⁶ : Algebra R S
A : Type u_1
B : Type ?u.111744
inst✝⁵ : CommRing A
inst✝⁴ : CommRing B
inst✝³ : IsDomain B
inst✝² : Algebra A B
K : Type ?u.112166
inst✝¹ : Field K
inst✝ : Algebra A S
pb : PowerBasis A S
✝ : Nontrivial A
⊢ degree (∑ i : Fin pb.dim, ↑C (↑(↑pb.basis.repr (pb.gen ^ pb.dim)) i) * X ^ ↑i) < degree (X ^ pb.dim)

tactic: exact degree_sum_fin_lt _
state_before: R : Type ?u.111432
S : Type u_2
T : Type ?u.111438
inst✝⁸ : CommRing R
inst✝⁷ : Ring S
inst✝⁶ : Algebra R S
A : Type u_1
B : Type ?u.111744
inst✝⁵ : CommRing A
inst✝⁴ : CommRing B
inst✝³ : IsDomain B
inst✝² : Algebra A B
K : Type ?u.112166
inst✝¹ : Field K
inst✝ : Algebra A S
pb : PowerBasis A S
✝ : Nontrivial A
⊢ degree (∑ i : Fin pb.dim, ↑C (↑(↑pb.basis.repr (pb.gen ^ pb.dim)) i) * X ^ ↑i) < ↑pb.dim
Theorem: Polynomial.leadingCoeff_mul'
File: Mathlib/Data/Polynomial/Degree/Definitions.lean

tactic: unfold leadingCoeff
state_before: R : Type u
S : Type v
a b c d : R
n m : ℕ
inst✝ : Semiring R
p q : R[X]
ι : Type ?u.660965
h : leadingCoeff p * leadingCoeff q ≠ 0
⊢ leadingCoeff (p * q) = leadingCoeff p * leadingCoeff q

tactic: rw [natDegree_mul' h, coeff_mul_degree_add_degree]
state_before: R : Type u
S : Type v
a b c d : R
n m : ℕ
inst✝ : Semiring R
p q : R[X]
ι : Type ?u.660965
h : leadingCoeff p * leadingCoeff q ≠ 0
⊢ coeff (p * q) (natDegree (p * q)) = coeff p (natDegree p) * coeff q (natDegree q)

tactic: rfl
state_before: R : Type u
S : Type v
a b c d : R
n m : ℕ
inst✝ : Semiring R
p q : R[X]
ι : Type ?u.660965
h : leadingCoeff p * leadingCoeff q ≠ 0
⊢ leadingCoeff p * leadingCoeff q = coeff p (natDegree p) * coeff q (natDegree q)
Theorem: MeasureTheory.L1.SimpleFunc.setToL1S_sub
File: Mathlib/MeasureTheory/Integral/SetToL1.lean

tactic: rw [sub_eq_add_neg, setToL1S_add T h_zero h_add, setToL1S_neg h_zero h_add, sub_eq_add_neg]
state_before: α : Type u_1
E : Type u_2
F : Type u_3
F' : Type ?u.675870
G : Type ?u.675873
𝕜 : Type ?u.675876
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 α
inst✝¹ : NormedField 𝕜
inst✝ : NormedSpace 𝕜 E
T : Set α → E →L[ℝ] F
h_zero : ∀ (s : Set α), MeasurableSet s → ↑↑μ s = 0 → T s = 0
h_add : FinMeasAdditive μ T
f g : { x // x ∈ simpleFunc E 1 μ }
⊢ setToL1S T (f - g) = setToL1S T f - setToL1S T g
Theorem: CategoryTheory.Limits.isCokernelEpiComp_desc
File: Mathlib/CategoryTheory/Limits/Shapes/Kernels.lean

tactic: rw [← cancel_epi g, ← Category.assoc, ← hh]
state_before: C : Type u
inst✝¹ : Category C
inst✝ : HasZeroMorphisms C
X Y : C
f : X ⟶ Y
c : CokernelCofork f
i : IsColimit c
W : C
g : W ⟶ X
hg : Epi g
h : W ⟶ Y
hh : h = g ≫ f
s : CokernelCofork h
⊢ f ≫ Cofork.π s = 0 ≫ Cofork.π s

tactic: simp
state_before: C : Type u
inst✝¹ : Category C
inst✝ : HasZeroMorphisms C
X Y : C
f : X ⟶ Y
c : CokernelCofork f
i : IsColimit c
W : C
g : W ⟶ X
hg : Epi g
h : W ⟶ Y
hh : h = g ≫ f
s : CokernelCofork h
⊢ h ≫ Cofork.π s = g ≫ 0 ≫ Cofork.π s
Theorem: Complex.ofReal_tan_ofReal_re
File: Mathlib/Data/Complex/Exponential.lean

tactic: rw [← tan_conj, conj_ofReal]
state_before: x✝ y : ℂ
x : ℝ
⊢ ↑(starRingEnd ℂ) (tan ↑x) = tan ↑x
Theorem: Polynomial.splits_iff
File: Mathlib/Data/Polynomial/Splits.lean

tactic: rw [Splits, map_eq_zero]
state_before: F : Type u
K : Type v
L : Type w
inst✝² : Field K
inst✝¹ : Field L
inst✝ : Field F
i : K →+* L
f : K[X]
⊢ Splits i f ↔ f = 0 ∨ ∀ {g : L[X]}, Irreducible g → g ∣ map i f → degree g = 1
Theorem: Asymptotics.IsBigOWith.rpow
File: Mathlib/Analysis/SpecialFunctions/Pow/Asymptotics.lean

tactic: apply IsBigOWith.of_bound
state_before: α : Type u_1
r c : ℝ
l : Filter α
f g : α → ℝ
h : IsBigOWith c l f g
hc : 0 ≤ c
hr : 0 ≤ r
hg : 0 ≤ᶠ[l] g
⊢ IsBigOWith (c ^ r) l (fun x => f x ^ r) fun x => g x ^ r

tactic: filter_upwards [hg, h.bound]with x hgx hx
state_before: case a
α : Type u_1
r c : ℝ
l : Filter α
f g : α → ℝ
h : IsBigOWith c l f g
hc : 0 ≤ c
hr : 0 ≤ r
hg : 0 ≤ᶠ[l] g
⊢ ∀ᶠ (x : α) in l, ‖f x ^ r‖ ≤ c ^ r * ‖g x ^ r‖

tactic: calc
  |f x ^ r| ≤ |f x| ^ r := abs_rpow_le_abs_rpow _ _
  _ ≤ (c * |g x|) ^ r := (rpow_le_rpow (abs_nonneg _) hx hr)
  _ = c ^ r * |g x ^ r| := by rw [mul_rpow hc (abs_nonneg _), abs_rpow_of_nonneg hgx]
state_before: case h
α : Type u_1
r c : ℝ
l : Filter α
f g : α → ℝ
h : IsBigOWith c l f g
hc : 0 ≤ c
hr : 0 ≤ r
hg : 0 ≤ᶠ[l] g
x : α
hgx : OfNat.ofNat 0 x ≤ g x
hx : ‖f x‖ ≤ c * ‖g x‖
⊢ ‖f x ^ r‖ ≤ c ^ r * ‖g x ^ r‖

tactic: rw [mul_rpow hc (abs_nonneg _), abs_rpow_of_nonneg hgx]
state_before: α : Type u_1
r c : ℝ
l : Filter α
f g : α → ℝ
h : IsBigOWith c l f g
hc : 0 ≤ c
hr : 0 ≤ r
hg : 0 ≤ᶠ[l] g
x : α
hgx : OfNat.ofNat 0 x ≤ g x
hx : ‖f x‖ ≤ c * ‖g x‖
⊢ (c * abs (g x)) ^ r = c ^ r * abs (g x ^ r)
Theorem: Ordinal.exists_blsub_cof
File: Mathlib/SetTheory/Cardinal/Cofinality.lean

tactic: rcases exists_lsub_cof o with ⟨ι, f, hf, hι⟩
state_before: α : Type ?u.37034
r : α → α → Prop
o : Ordinal
⊢ ∃ f, blsub (ord (cof o)) f = o

tactic: rcases Cardinal.ord_eq ι with ⟨r, hr, hι'⟩
state_before: case intro.intro.intro
α : Type ?u.37034
r : α → α → Prop
o : Ordinal
ι : Type u
f : ι → Ordinal
hf : lsub f = o
hι : (#ι) = cof o
⊢ ∃ f, blsub (ord (cof o)) f = o

tactic: rw [← @blsub_eq_lsub' ι r hr] at hf
state_before: case intro.intro.intro.intro.intro
α : Type ?u.37034
r✝ : α → α → Prop
o : Ordinal
ι : Type u
f : ι → Ordinal
hf : lsub f = o
hι : (#ι) = cof o
r : ι → ι → Prop
hr : IsWellOrder ι r
hι' : ord (#ι) = type r
⊢ ∃ f, blsub (ord (cof o)) f = o

tactic: rw [← hι, hι']
state_before: case intro.intro.intro.intro.intro
α : Type ?u.37034
r✝ : α → α → Prop
o : Ordinal
ι : Type u
f : ι → Ordinal
hι : (#ι) = cof o
r : ι → ι → Prop
hr : IsWellOrder ι r
hf : blsub (type r) (bfamilyOfFamily' r f) = o
hι' : ord (#ι) = type r
⊢ ∃ f, blsub (ord (cof o)) f = o

tactic: exact ⟨_, hf⟩
state_before: case intro.intro.intro.intro.intro
α : Type ?u.37034
r✝ : α → α → Prop
o : Ordinal
ι : Type u
f : ι → Ordinal
hι : (#ι) = cof o
r : ι → ι → Prop
hr : IsWellOrder ι r
hf : blsub (type r) (bfamilyOfFamily' r f) = o
hι' : ord (#ι) = type r
⊢ ∃ f, blsub (type r) f = o
Theorem: Algebra.FinitePresentation.ker_fG_of_surjective
File: Mathlib/RingTheory/FinitePresentation.lean

tactic: obtain ⟨n, g, hg, _⟩ := hRA
state_before: R : Type w₁
A : Type w₂
B : Type w₃
inst✝⁴ : CommRing R
inst✝³ : CommRing A
inst✝² : Algebra R A
inst✝¹ : CommRing B
inst✝ : Algebra R B
f : A →ₐ[R] B
hf : Surjective ↑f
hRA : FinitePresentation R A
hRB : FinitePresentation R B
⊢ Ideal.FG (RingHom.ker ↑f)

tactic: convert (ker_fg_of_mvPolynomial (f.comp g) (hf.comp hg) hRB).map g.toRingHom
state_before: case intro.intro.intro
R : Type w₁
A : Type w₂
B : Type w₃
inst✝⁴ : CommRing R
inst✝³ : CommRing A
inst✝² : Algebra R A
inst✝¹ : CommRing B
inst✝ : Algebra R B
f : A →ₐ[R] B
hf : Surjective ↑f
hRB : FinitePresentation R B
n : ℕ
g : MvPolynomial (Fin n) R →ₐ[R] A
hg : Surjective ↑g
right✝ : Ideal.FG (RingHom.ker ↑g)
⊢ Ideal.FG (RingHom.ker ↑f)

tactic: simp_rw [RingHom.ker_eq_comap_bot, AlgHom.toRingHom_eq_coe, AlgHom.comp_toRingHom]
state_before: case h.e'_3
R : Type w₁
A : Type w₂
B : Type w₃
inst✝⁴ : CommRing R
inst✝³ : CommRing A
inst✝² : Algebra R A
inst✝¹ : CommRing B
inst✝ : Algebra R B
f : A →ₐ[R] B
hf : Surjective ↑f
hRB : FinitePresentation R B
n : ℕ
g : MvPolynomial (Fin n) R →ₐ[R] A
hg : Surjective ↑g
right✝ : Ideal.FG (RingHom.ker ↑g)
⊢ RingHom.ker ↑f = Ideal.map (↑g) (RingHom.ker ↑(AlgHom.comp f g))

tactic: rw [← Ideal.comap_comap, Ideal.map_comap_of_surjective (g : MvPolynomial (Fin n) R →+* A) hg]
state_before: case h.e'_3
R : Type w₁
A : Type w₂
B : Type w₃
inst✝⁴ : CommRing R
inst✝³ : CommRing A
inst✝² : Algebra R A
inst✝¹ : CommRing B
inst✝ : Algebra R B
f : A →ₐ[R] B
hf : Surjective ↑f
hRB : FinitePresentation R B
n : ℕ
g : MvPolynomial (Fin n) R →ₐ[R] A
hg : Surjective ↑g
right✝ : Ideal.FG (RingHom.ker ↑g)
⊢ Ideal.comap ↑f ⊥ = Ideal.map (↑g) (Ideal.comap (RingHom.comp ↑f ↑g) ⊥)
Theorem: MeasureTheory.integrableOn_singleton_iff
File: Mathlib/MeasureTheory/Integral/IntegrableOn.lean

tactic: have : f =ᵐ[μ.restrict {x}] fun _ => f x := by
  filter_upwards [ae_restrict_mem (measurableSet_singleton x)]with _ ha
  simp only [mem_singleton_iff.1 ha]
state_before: α : Type u_1
β : Type ?u.1501840
E : Type u_2
F : Type ?u.1501846
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
x : α
inst✝ : MeasurableSingletonClass α
⊢ IntegrableOn f {x} ↔ f x = 0 ∨ ↑↑μ {x} < ⊤

tactic: rw [IntegrableOn, integrable_congr this, integrable_const_iff]
state_before: α : Type u_1
β : Type ?u.1501840
E : Type u_2
F : Type ?u.1501846
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
x : α
inst✝ : MeasurableSingletonClass α
this : f =ᵐ[Measure.restrict μ {x}] fun x_1 => f x
⊢ IntegrableOn f {x} ↔ f x = 0 ∨ ↑↑μ {x} < ⊤

tactic: simp
state_before: α : Type u_1
β : Type ?u.1501840
E : Type u_2
F : Type ?u.1501846
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
x : α
inst✝ : MeasurableSingletonClass α
this : f =ᵐ[Measure.restrict μ {x}] fun x_1 => f x
⊢ f x = 0 ∨ ↑↑(Measure.restrict μ {x}) univ < ⊤ ↔ f x = 0 ∨ ↑↑μ {x} < ⊤

tactic: filter_upwards [ae_restrict_mem (measurableSet_singleton x)]with _ ha
state_before: α : Type u_1
β : Type ?u.1501840
E : Type u_2
F : Type ?u.1501846
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
x : α
inst✝ : MeasurableSingletonClass α
⊢ f =ᵐ[Measure.restrict μ {x}] fun x_1 => f x

tactic: simp only [mem_singleton_iff.1 ha]
state_before: case h
α : Type u_1
β : Type ?u.1501840
E : Type u_2
F : Type ?u.1501846
inst✝² : MeasurableSpace α
inst✝¹ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
x : α
inst✝ : MeasurableSingletonClass α
a✝ : α
ha : a✝ ∈ {x}
⊢ f a✝ = f x
Theorem: intervalIntegral.integral_const'
File: Mathlib/MeasureTheory/Integral/IntervalIntegral.lean

tactic: simp only [intervalIntegral, set_integral_const, sub_smul]
state_before: ι : Type ?u.13595937
𝕜 : Type ?u.13595940
E : Type u_1
F : Type ?u.13595946
A : Type ?u.13595949
inst✝² : NormedAddCommGroup E
inst✝¹ : CompleteSpace E
inst✝ : NormedSpace ℝ E
a b : ℝ
f g : ℝ → E
μ : MeasureTheory.Measure ℝ
c : E
⊢ (∫ (x : ℝ) in a..b, c ∂μ) = (ENNReal.toReal (↑↑μ (Ioc a b)) - ENNReal.toReal (↑↑μ (Ioc b a))) • c