1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: RatFunc.single_one_eq_pow
File: Mathlib/RingTheory/LaurentSeries.lean

tactic: induction' n with n h_ind
state_before: R✝ : Type u_1
F : Type u
inst✝¹ : Field F
p q : F[X]
f g : RatFunc F
R : Type u_2
inst✝ : Ring R
n : ℕ
⊢ (single ↑n) 1 = (single 1) 1 ^ n
state_after: case zero
R✝ : Type u_1
F : Type u
inst✝¹ : Field F
p q : F[X]
f g : RatFunc F
R : Type u_2
inst✝ : Ring R
⊢ (single ↑0) 1 = (single 1) 1 ^ 0

case succ
R✝ : Type u_1
F : Type u
inst✝¹ : Field F
p q : F[X]
f g : RatFunc F
R : Type u_2
inst✝ : Ring R
n : ℕ
h_ind : (single ↑n) 1 = (single 1) 1 ^ n
⊢ (single ↑(n + 1)) 1 = (single 1) 1 ^ (n + 1)

tactic: simp
state_before: case zero
R✝ : Type u_1
F : Type u
inst✝¹ : Field F
p q : F[X]
f g : RatFunc F
R : Type u_2
inst✝ : Ring R
⊢ (single ↑0) 1 = (single 1) 1 ^ 0
state_after: no goals

tactic: rw [← Int.ofNat_add_one_out, pow_succ', ← h_ind, HahnSeries.single_mul_single, one_mul,
  add_comm]
state_before: case succ
R✝ : Type u_1
F : Type u
inst✝¹ : Field F
p q : F[X]
f g : RatFunc F
R : Type u_2
inst✝ : Ring R
n : ℕ
h_ind : (single ↑n) 1 = (single 1) 1 ^ n
⊢ (single ↑(n + 1)) 1 = (single 1) 1 ^ (n + 1)
state_after: no goals
Theorem: Set.toFinset_Ioo
File: Mathlib/Order/Interval/Finset/Defs.lean

tactic: ext
state_before: α✝ : Type u_1
β : Type u_2
inst✝⁴ : Preorder α✝
p : α✝ → Prop
inst✝³ : DecidablePred p
y : α✝
α : Type u_3
inst✝² : Preorder α
inst✝¹ : LocallyFiniteOrder α
a b : α
inst✝ : Fintype ↑(Ioo a b)
⊢ (Ioo a b).toFinset = Finset.Ioo a b
state_after: case a
α✝ : Type u_1
β : Type u_2
inst✝⁴ : Preorder α✝
p : α✝ → Prop
inst✝³ : DecidablePred p
y : α✝
α : Type u_3
inst✝² : Preorder α
inst✝¹ : LocallyFiniteOrder α
a b : α
inst✝ : Fintype ↑(Ioo a b)
a✝ : α
⊢ a✝ ∈ (Ioo a b).toFinset ↔ a✝ ∈ Finset.Ioo a b

tactic: simp
state_before: case a
α✝ : Type u_1
β : Type u_2
inst✝⁴ : Preorder α✝
p : α✝ → Prop
inst✝³ : DecidablePred p
y : α✝
α : Type u_3
inst✝² : Preorder α
inst✝¹ : LocallyFiniteOrder α
a b : α
inst✝ : Fintype ↑(Ioo a b)
a✝ : α
⊢ a✝ ∈ (Ioo a b).toFinset ↔ a✝ ∈ Finset.Ioo a b
state_after: no goals
Theorem: Set.coe_eq_image_val
File: Mathlib/Data/Set/Functor.lean

tactic: change ⋃ (x ∈ t), {x.1} = _
state_before: α β : Type u
s : Set α
f : α → Set β
g : Set (α → β)
t : Set ↑s
⊢ Lean.Internal.coeM t = ↑t
state_after: α β : Type u
s : Set α
f : α → Set β
g : Set (α → β)
t : Set ↑s
⊢ ⋃ x ∈ t, {↑x} = ↑t

tactic: ext
state_before: α β : Type u
s : Set α
f : α → Set β
g : Set (α → β)
t : Set ↑s
⊢ ⋃ x ∈ t, {↑x} = ↑t
state_after: case h
α β : Type u
s : Set α
f : α → Set β
g : Set (α → β)
t : Set ↑s
x✝ : α
⊢ x✝ ∈ ⋃ x ∈ t, {↑x} ↔ x✝ ∈ ↑t

tactic: simp
state_before: case h
α β : Type u
s : Set α
f : α → Set β
g : Set (α → β)
t : Set ↑s
x✝ : α
⊢ x✝ ∈ ⋃ x ∈ t, {↑x} ↔ x✝ ∈ ↑t
state_after: no goals
Theorem: SimpleGraph.Walk.tail_support_append
File: Mathlib/Combinatorics/SimpleGraph/Connectivity.lean

tactic: rw [support_append, List.tail_append_of_ne_nil _ _ (support_ne_nil _)]
state_before: V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
u v w : V
p : G.Walk u v
p' : G.Walk v w
⊢ (p.append p').support.tail = p.support.tail ++ p'.support.tail
state_after: no goals
Theorem: isLittleO_exp_neg_mul_rpow_atTop
File: Mathlib/Analysis/SpecialFunctions/Pow/Asymptotics.lean

tactic: apply isLittleO_of_tendsto'
state_before: a : ℝ
ha : 0 < a
b : ℝ
⊢ (fun x => rexp (-a * x)) =o[atTop] fun x => x ^ b
state_after: case hgf
a : ℝ
ha : 0 < a
b : ℝ
⊢ ∀ᶠ (x : ℝ) in atTop, x ^ b = 0 → rexp (-a * x) = 0

case a
a : ℝ
ha : 0 < a
b : ℝ
⊢ Tendsto (fun x => rexp (-a * x) / x ^ b) atTop (𝓝 0)

tactic: refine (eventually_gt_atTop 0).mono fun t ht h => ?_
state_before: case hgf
a : ℝ
ha : 0 < a
b : ℝ
⊢ ∀ᶠ (x : ℝ) in atTop, x ^ b = 0 → rexp (-a * x) = 0
state_after: case hgf
a : ℝ
ha : 0 < a
b t : ℝ
ht : 0 < t
h : t ^ b = 0
⊢ rexp (-a * t) = 0

tactic: rw [rpow_eq_zero_iff_of_nonneg ht.le] at h
state_before: case hgf
a : ℝ
ha : 0 < a
b t : ℝ
ht : 0 < t
h : t ^ b = 0
⊢ rexp (-a * t) = 0
state_after: case hgf
a : ℝ
ha : 0 < a
b t : ℝ
ht : 0 < t
h : t = 0 ∧ b ≠ 0
⊢ rexp (-a * t) = 0

tactic: exact (ht.ne' h.1).elim
state_before: case hgf
a : ℝ
ha : 0 < a
b t : ℝ
ht : 0 < t
h : t = 0 ∧ b ≠ 0
⊢ rexp (-a * t) = 0
state_after: no goals

tactic: refine (tendsto_exp_mul_div_rpow_atTop (-b) a ha).inv_tendsto_atTop.congr' ?_
state_before: case a
a : ℝ
ha : 0 < a
b : ℝ
⊢ Tendsto (fun x => rexp (-a * x) / x ^ b) atTop (𝓝 0)
state_after: case a
a : ℝ
ha : 0 < a
b : ℝ
⊢ (fun x => rexp (a * x) / x ^ (-b))⁻¹ =ᶠ[atTop] fun x => rexp (-a * x) / x ^ b

tactic: refine (eventually_ge_atTop 0).mono fun t ht => ?_
state_before: case a
a : ℝ
ha : 0 < a
b : ℝ
⊢ (fun x => rexp (a * x) / x ^ (-b))⁻¹ =ᶠ[atTop] fun x => rexp (-a * x) / x ^ b
state_after: case a
a : ℝ
ha : 0 < a
b t : ℝ
ht : 0 ≤ t
⊢ (fun x => rexp (a * x) / x ^ (-b))⁻¹ t = (fun x => rexp (-a * x) / x ^ b) t

tactic: field_simp [Real.exp_neg, rpow_neg ht]
state_before: case a
a : ℝ
ha : 0 < a
b t : ℝ
ht : 0 ≤ t
⊢ (fun x => rexp (a * x) / x ^ (-b))⁻¹ t = (fun x => rexp (-a * x) / x ^ b) t
state_after: no goals
Theorem: variationOnFromTo.antitoneOn
File: Mathlib/Analysis/BoundedVariation.lean

tactic: rintro a as c cs ac
state_before: α : Type u_1
inst✝¹ : LinearOrder α
E : Type u_2
inst✝ : PseudoEMetricSpace E
f : α → E
s : Set α
hf : LocallyBoundedVariationOn f s
b : α
bs : b ∈ s
⊢ AntitoneOn (fun a => variationOnFromTo f s a b) s
state_after: α : Type u_1
inst✝¹ : LinearOrder α
E : Type u_2
inst✝ : PseudoEMetricSpace E
f : α → E
s : Set α
hf : LocallyBoundedVariationOn f s
b : α
bs : b ∈ s
a : α
as : a ∈ s
c : α
cs : c ∈ s
ac : a ≤ c
⊢ (fun a => variationOnFromTo f s a b) c ≤ (fun a => variationOnFromTo f s a b) a

tactic: dsimp only
state_before: α : Type u_1
inst✝¹ : LinearOrder α
E : Type u_2
inst✝ : PseudoEMetricSpace E
f : α → E
s : Set α
hf : LocallyBoundedVariationOn f s
b : α
bs : b ∈ s
a : α
as : a ∈ s
c : α
cs : c ∈ s
ac : a ≤ c
⊢ (fun a => variationOnFromTo f s a b) c ≤ (fun a => variationOnFromTo f s a b) a
state_after: α : Type u_1
inst✝¹ : LinearOrder α
E : Type u_2
inst✝ : PseudoEMetricSpace E
f : α → E
s : Set α
hf : LocallyBoundedVariationOn f s
b : α
bs : b ∈ s
a : α
as : a ∈ s
c : α
cs : c ∈ s
ac : a ≤ c
⊢ variationOnFromTo f s c b ≤ variationOnFromTo f s a b

tactic: rw [← variationOnFromTo.add hf as cs bs]
state_before: α : Type u_1
inst✝¹ : LinearOrder α
E : Type u_2
inst✝ : PseudoEMetricSpace E
f : α → E
s : Set α
hf : LocallyBoundedVariationOn f s
b : α
bs : b ∈ s
a : α
as : a ∈ s
c : α
cs : c ∈ s
ac : a ≤ c
⊢ variationOnFromTo f s c b ≤ variationOnFromTo f s a b
state_after: α : Type u_1
inst✝¹ : LinearOrder α
E : Type u_2
inst✝ : PseudoEMetricSpace E
f : α → E
s : Set α
hf : LocallyBoundedVariationOn f s
b : α
bs : b ∈ s
a : α
as : a ∈ s
c : α
cs : c ∈ s
ac : a ≤ c
⊢ variationOnFromTo f s c b ≤ variationOnFromTo f s a c + variationOnFromTo f s c b

tactic: exact le_add_of_nonneg_left (variationOnFromTo.nonneg_of_le f s ac)
state_before: α : Type u_1
inst✝¹ : LinearOrder α
E : Type u_2
inst✝ : PseudoEMetricSpace E
f : α → E
s : Set α
hf : LocallyBoundedVariationOn f s
b : α
bs : b ∈ s
a : α
as : a ∈ s
c : α
cs : c ∈ s
ac : a ≤ c
⊢ variationOnFromTo f s c b ≤ variationOnFromTo f s a c + variationOnFromTo f s c b
state_after: no goals
Theorem: ite_eq_iff
File: Mathlib/Logic/Basic.lean

tactic: rw [exists_prop, exists_prop]
state_before: α : Sort u_1
σ : α → Sort u_2
P Q R : Prop
inst✝¹ : Decidable P
inst✝ : Decidable Q
a b c : α
A : P → α
B : ¬P → α
⊢ ((∃ h, a = c) ∨ ∃ h, b = c) ↔ P ∧ a = c ∨ ¬P ∧ b = c
state_after: no goals
Theorem: Matrix.invOf_mul_self_assoc
File: Mathlib/Data/Matrix/Invertible.lean

tactic: rw [← Matrix.mul_assoc, invOf_mul_self, Matrix.one_mul]
state_before: m : Type u_1
n : Type u_2
α : Type u_3
inst✝³ : Fintype n
inst✝² : DecidableEq n
inst✝¹ : Semiring α
A : Matrix n n α
B : Matrix n m α
inst✝ : Invertible A
⊢ ⅟A * (A * B) = B
state_after: no goals
Theorem: Finset.disjoint_right
File: Mathlib/Data/Finset/Basic.lean

tactic: rw [_root_.disjoint_comm, disjoint_left]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
f : α → β
s t u : Finset α
a b : α
⊢ _root_.Disjoint s t ↔ ∀ ⦃a : α⦄, a ∈ t → a ∉ s
state_after: no goals
Theorem: IsRelPrime.add_mul_left_left
File: Mathlib/RingTheory/Coprime/Basic.lean

tactic: simpa only [mul_neg, add_neg_cancel_right] using h
state_before: R : Type u_1
inst✝ : CommRing R
x y : R
h : IsRelPrime x y
z : R
⊢ IsRelPrime (x + y * z + y * -z) y
state_after: no goals
Theorem: CategoryTheory.shiftFunctorAdd'_zero_add_hom_app
File: Mathlib/CategoryTheory/Shift/Basic.lean

tactic: simpa using NatTrans.congr_app (congr_arg Iso.hom (shiftFunctorAdd'_zero_add C a)) X
state_before: C : Type u
A : Type u_1
inst✝² : Category.{v, u} C
inst✝¹ : AddMonoid A
inst✝ : HasShift C A
a : A
X : C
⊢ (shiftFunctorAdd' C 0 a a ⋯).hom.app X = (shiftFunctor C a).map ((shiftFunctorZero C A).inv.app X)
state_after: no goals
Theorem: PowerBasis.minpolyGen_map
File: Mathlib/RingTheory/PowerBasis.lean

tactic: dsimp only [minpolyGen, map_dim]
state_before: R : Type u_1
S : Type u_2
T : Type u_3
inst✝¹¹ : CommRing R
inst✝¹⁰ : Ring S
inst✝⁹ : Algebra R S
A : Type u_4
B : Type u_5
inst✝⁸ : CommRing A
inst✝⁷ : CommRing B
inst✝⁶ : IsDomain B
inst✝⁵ : Algebra A B
K : Type u_6
inst✝⁴ : Field K
S' : Type u_7
inst✝³ : CommRing S'
inst✝² : Algebra R S'
inst✝¹ : Algebra A S
inst✝ : Algebra A S'
pb : PowerBasis A S
e : S ≃ₐ[A] S'
⊢ (pb.map e).minpolyGen = pb.minpolyGen
state_after: R : Type u_1
S : Type u_2
T : Type u_3
inst✝¹¹ : CommRing R
inst✝¹⁰ : Ring S
inst✝⁹ : Algebra R S
A : Type u_4
B : Type u_5
inst✝⁸ : CommRing A
inst✝⁷ : CommRing B
inst✝⁶ : IsDomain B
inst✝⁵ : Algebra A B
K : Type u_6
inst✝⁴ : Field K
S' : Type u_7
inst✝³ : CommRing S'
inst✝² : Algebra R S'
inst✝¹ : Algebra A S
inst✝ : Algebra A S'
pb : PowerBasis A S
e : S ≃ₐ[A] S'
⊢ X ^ pb.dim - ∑ i : Fin pb.dim, C (((pb.map e).basis.repr ((pb.map e).gen ^ pb.dim)) i) * X ^ ↑i =
    X ^ pb.dim - ∑ i : Fin pb.dim, C ((pb.basis.repr (pb.gen ^ pb.dim)) i) * X ^ ↑i

tactic: simp only [LinearEquiv.trans_apply, map_basis, Basis.map_repr, map_gen,
  AlgEquiv.toLinearEquiv_apply, e.toLinearEquiv_symm, map_pow,
  AlgEquiv.symm_apply_apply, sub_right_inj]
state_before: R : Type u_1
S : Type u_2
T : Type u_3
inst✝¹¹ : CommRing R
inst✝¹⁰ : Ring S
inst✝⁹ : Algebra R S
A : Type u_4
B : Type u_5
inst✝⁸ : CommRing A
inst✝⁷ : CommRing B
inst✝⁶ : IsDomain B
inst✝⁵ : Algebra A B
K : Type u_6
inst✝⁴ : Field K
S' : Type u_7
inst✝³ : CommRing S'
inst✝² : Algebra R S'
inst✝¹ : Algebra A S
inst✝ : Algebra A S'
pb : PowerBasis A S
e : S ≃ₐ[A] S'
⊢ X ^ pb.dim - ∑ i : Fin pb.dim, C (((pb.map e).basis.repr ((pb.map e).gen ^ pb.dim)) i) * X ^ ↑i =
    X ^ pb.dim - ∑ i : Fin pb.dim, C ((pb.basis.repr (pb.gen ^ pb.dim)) i) * X ^ ↑i
state_after: no goals
Theorem: EReal.inv_nonneg_of_nonneg
File: Mathlib/Data/Real/EReal.lean

tactic: induction a with
| h_bot | h_top => simp
| h_real a => rw [← coe_inv a, EReal.coe_nonneg, inv_nonneg]; exact EReal.coe_nonneg.1 h
state_before: a : EReal
h : 0 ≤ a
⊢ 0 ≤ a⁻¹
state_after: no goals

tactic: simp
state_before: case h_top
h : 0 ≤ ⊤
⊢ 0 ≤ ⊤⁻¹
state_after: no goals

tactic: rw [← coe_inv a, EReal.coe_nonneg, inv_nonneg]
state_before: case h_real
a : ℝ
h : 0 ≤ ↑a
⊢ 0 ≤ (↑a)⁻¹
state_after: case h_real
a : ℝ
h : 0 ≤ ↑a
⊢ 0 ≤ a

tactic: exact EReal.coe_nonneg.1 h
state_before: case h_real
a : ℝ
h : 0 ≤ ↑a
⊢ 0 ≤ a
state_after: no goals
Theorem: Metric.thickening_empty
File: Mathlib/Topology/MetricSpace/Thickening.lean

tactic: simp only [thickening, setOf_false, infEdist_empty, not_top_lt]
state_before: ι : Sort u_1
α : Type u
β : Type v
inst✝ : PseudoEMetricSpace α
δ✝ : ℝ
s : Set α
x : α
δ : ℝ
⊢ thickening δ ∅ = ∅
state_after: no goals
Theorem: Finset.univ_pi_univ
File: Mathlib/Data/Fintype/Pi.lean

tactic: ext
state_before: α✝ : Type u_1
α : Type u_2
β : α → Type u_3
inst✝² : DecidableEq α
inst✝¹ : Fintype α
inst✝ : (a : α) → Fintype (β a)
⊢ (univ.pi fun a => univ) = univ
state_after: case a
α✝ : Type u_1
α : Type u_2
β : α → Type u_3
inst✝² : DecidableEq α
inst✝¹ : Fintype α
inst✝ : (a : α) → Fintype (β a)
a✝ : (a : α) → a ∈ univ → β a
⊢ (a✝ ∈ univ.pi fun a => univ) ↔ a✝ ∈ univ

tactic: simp
state_before: case a
α✝ : Type u_1
α : Type u_2
β : α → Type u_3
inst✝² : DecidableEq α
inst✝¹ : Fintype α
inst✝ : (a : α) → Fintype (β a)
a✝ : (a : α) → a ∈ univ → β a
⊢ (a✝ ∈ univ.pi fun a => univ) ↔ a✝ ∈ univ
state_after: no goals
Theorem: Option.elim_apply
File: Mathlib/Data/Option/Basic.lean

tactic: rw [elim_comp fun f : α → β => f y]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
f : γ → α → β
x : α → β
i : Option γ
y : α
⊢ i.elim x f y = i.elim (x y) fun j => f j y
state_after: no goals
Theorem: MeasureTheory.condexp_sub
File: Mathlib/MeasureTheory/Function/ConditionalExpectation/Basic.lean

tactic: simp_rw [sub_eq_add_neg]
state_before: α : Type u_1
F : Type u_2
F' : Type u_3
𝕜 : Type u_4
p : ℝ≥0∞
inst✝⁶ : RCLike 𝕜
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
inst✝³ : NormedAddCommGroup F'
inst✝² : NormedSpace 𝕜 F'
inst✝¹ : NormedSpace ℝ F'
inst✝ : CompleteSpace F'
m m0 : MeasurableSpace α
μ : Measure α
f g : α → F'
s : Set α
hf : Integrable f μ
hg : Integrable g μ
⊢ μ[f - g|m] =ᶠ[ae μ] μ[f|m] - μ[g|m]
state_after: α : Type u_1
F : Type u_2
F' : Type u_3
𝕜 : Type u_4
p : ℝ≥0∞
inst✝⁶ : RCLike 𝕜
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
inst✝³ : NormedAddCommGroup F'
inst✝² : NormedSpace 𝕜 F'
inst✝¹ : NormedSpace ℝ F'
inst✝ : CompleteSpace F'
m m0 : MeasurableSpace α
μ : Measure α
f g : α → F'
s : Set α
hf : Integrable f μ
hg : Integrable g μ
⊢ μ[f + -g|m] =ᶠ[ae μ] μ[f|m] + -μ[g|m]

tactic: exact (condexp_add hf hg.neg).trans (EventuallyEq.rfl.add (condexp_neg g))
state_before: α : Type u_1
F : Type u_2
F' : Type u_3
𝕜 : Type u_4
p : ℝ≥0∞
inst✝⁶ : RCLike 𝕜
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
inst✝³ : NormedAddCommGroup F'
inst✝² : NormedSpace 𝕜 F'
inst✝¹ : NormedSpace ℝ F'
inst✝ : CompleteSpace F'
m m0 : MeasurableSpace α
μ : Measure α
f g : α → F'
s : Set α
hf : Integrable f μ
hg : Integrable g μ
⊢ μ[f + -g|m] =ᶠ[ae μ] μ[f|m] + -μ[g|m]
state_after: no goals
Theorem: Asymptotics.isTheta_norm_left
File: Mathlib/Analysis/Asymptotics/Theta.lean

tactic: simp [IsTheta]
state_before: α : Type u_1
β : Type u_2
E : Type u_3
F : Type u_4
G : Type u_5
E' : Type u_6
F' : Type u_7
G' : Type u_8
E'' : Type u_9
F'' : Type u_10
G'' : Type u_11
R : Type u_12
R' : Type u_13
𝕜 : Type u_14
𝕜' : Type u_15
inst✝¹² : Norm E
inst✝¹¹ : Norm F
inst✝¹⁰ : Norm G
inst✝⁹ : SeminormedAddCommGroup E'
inst✝⁸ : SeminormedAddCommGroup F'
inst✝⁷ : SeminormedAddCommGroup G'
inst✝⁶ : NormedAddCommGroup E''
inst✝⁵ : NormedAddCommGroup F''
inst✝⁴ : NormedAddCommGroup G''
inst✝³ : SeminormedRing R
inst✝² : SeminormedRing R'
inst✝¹ : NormedField 𝕜
inst✝ : NormedField 𝕜'
c c' c₁ c₂ : ℝ
f : α → E
g : α → F
k : α → G
f' : α → E'
g' : α → F'
k' : α → G'
f'' : α → E''
g'' : α → F''
l l' : Filter α
⊢ (fun x => ‖f' x‖) =Θ[l] g ↔ f' =Θ[l] g
state_after: no goals
Theorem: MeasureTheory.isFiniteMeasure_withDensity
File: Mathlib/MeasureTheory/Measure/WithDensity.lean

tactic: rwa [withDensity_apply _ MeasurableSet.univ, Measure.restrict_univ, lt_top_iff_ne_top]
state_before: α : Type u_1
m0 : MeasurableSpace α
μ : Measure α
f : α → ℝ≥0∞
hf : ∫⁻ (a : α), f a ∂μ ≠ ⊤
⊢ (μ.withDensity f) univ < ⊤
state_after: no goals
Theorem: CategoryTheory.ShortComplex.RightHomologyData.p_comp_opcyclesIso_inv
File: Mathlib/Algebra/Homology/ShortComplex/RightHomology.lean

tactic: dsimp [pOpcycles, RightHomologyData.opcyclesIso]
state_before: C : Type u_1
inst✝² : Category.{u_2, u_1} C
inst✝¹ : HasZeroMorphisms C
S S₁ S₂ S₃ : ShortComplex C
h : S.RightHomologyData
inst✝ : S.HasRightHomology
⊢ h.p ≫ h.opcyclesIso.inv = S.pOpcycles
state_after: C : Type u_1
inst✝² : Category.{u_2, u_1} C
inst✝¹ : HasZeroMorphisms C
S S₁ S₂ S₃ : ShortComplex C
h : S.RightHomologyData
inst✝ : S.HasRightHomology
⊢ h.p ≫ opcyclesMap' (𝟙 S) h S.rightHomologyData = S.rightHomologyData.p

tactic: simp only [p_opcyclesMap', id_τ₂, id_comp]
state_before: C : Type u_1
inst✝² : Category.{u_2, u_1} C
inst✝¹ : HasZeroMorphisms C
S S₁ S₂ S₃ : ShortComplex C
h : S.RightHomologyData
inst✝ : S.HasRightHomology
⊢ h.p ≫ opcyclesMap' (𝟙 S) h S.rightHomologyData = S.rightHomologyData.p
state_after: no goals
Theorem: Ring.multichoose_succ_succ
File: Mathlib/RingTheory/Binomial.lean

tactic: refine nsmul_right_injective (Nat.factorial (k + 1)) (Nat.factorial_ne_zero (k + 1)) ?_
state_before: R✝ : Type u_1
inst✝⁶ : AddCommMonoid R✝
inst✝⁵ : Pow R✝ ℕ
inst✝⁴ : BinomialRing R✝
R : Type u_2
inst✝³ : NonAssocSemiring R
inst✝² : Pow R ℕ
inst✝¹ : NatPowAssoc R
inst✝ : BinomialRing R
r : R
k : ℕ
⊢ multichoose (r + 1) (k + 1) = multichoose r (k + 1) + multichoose (r + 1) k
state_after: R✝ : Type u_1
inst✝⁶ : AddCommMonoid R✝
inst✝⁵ : Pow R✝ ℕ
inst✝⁴ : BinomialRing R✝
R : Type u_2
inst✝³ : NonAssocSemiring R
inst✝² : Pow R ℕ
inst✝¹ : NatPowAssoc R
inst✝ : BinomialRing R
r : R
k : ℕ
⊢ (fun x => (k + 1).factorial • x) (multichoose (r + 1) (k + 1)) =
    (fun x => (k + 1).factorial • x) (multichoose r (k + 1) + multichoose (r + 1) k)

tactic: simp only [factorial_nsmul_multichoose_eq_ascPochhammer, smul_add]
state_before: R✝ : Type u_1
inst✝⁶ : AddCommMonoid R✝
inst✝⁵ : Pow R✝ ℕ
inst✝⁴ : BinomialRing R✝
R : Type u_2
inst✝³ : NonAssocSemiring R
inst✝² : Pow R ℕ
inst✝¹ : NatPowAssoc R
inst✝ : BinomialRing R
r : R
k : ℕ
⊢ (fun x => (k + 1).factorial • x) (multichoose (r + 1) (k + 1)) =
    (fun x => (k + 1).factorial • x) (multichoose r (k + 1) + multichoose (r + 1) k)
state_after: R✝ : Type u_1
inst✝⁶ : AddCommMonoid R✝
inst✝⁵ : Pow R✝ ℕ
inst✝⁴ : BinomialRing R✝
R : Type u_2
inst✝³ : NonAssocSemiring R
inst✝² : Pow R ℕ
inst✝¹ : NatPowAssoc R
inst✝ : BinomialRing R
r : R
k : ℕ
⊢ (ascPochhammer ℕ (k + 1)).smeval (r + 1) =
    (ascPochhammer ℕ (k + 1)).smeval r + (k + 1).factorial • multichoose (r + 1) k

tactic: rw [add_comm (smeval (ascPochhammer ℕ (k+1)) r), ascPochhammer_succ_succ r k]
state_before: R✝ : Type u_1
inst✝⁶ : AddCommMonoid R✝
inst✝⁵ : Pow R✝ ℕ
inst✝⁴ : BinomialRing R✝
R : Type u_2
inst✝³ : NonAssocSemiring R
inst✝² : Pow R ℕ
inst✝¹ : NatPowAssoc R
inst✝ : BinomialRing R
r : R
k : ℕ
⊢ (ascPochhammer ℕ (k + 1)).smeval (r + 1) =
    (ascPochhammer ℕ (k + 1)).smeval r + (k + 1).factorial • multichoose (r + 1) k
state_after: no goals
Theorem: Finset.inj_on_of_surj_on_of_card_le
File: Mathlib/Data/Finset/Card.lean

tactic: simpa
state_before: α : Type u_1
β : Type u_2
R : Type u_3
s t✝ u : Finset α
f✝ : α → β
n : ℕ
t : Finset β
f : (a : α) → a ∈ s → β
hf : ∀ (a : α) (ha : a ∈ s), f a ha ∈ t
hsurj : ∀ b ∈ t, ∃ a, ∃ (ha : a ∈ s), f a ha = b
hst : s.card ≤ t.card
a₁ : α
ha₁ : a₁ ∈ s
a₂ : α
ha₂ : a₂ ∈ s
ha₁a₂ : f a₁ ha₁ = f a₂ ha₂
this : Inhabited { x // x ∈ s }
f' : { x // x ∈ s } → { x // x ∈ t } := fun x => ⟨f ↑x ⋯, ⋯⟩
g : { x // x ∈ t } → { x // x ∈ s } := surjInv ⋯
hg : Injective g
x : { x // x ∈ s }
⊢ s.attach.card ≤ t.attach.card
state_after: no goals
Theorem: CategoryTheory.MonoidalCategory.tensor_inv_hom_id
File: Mathlib/CategoryTheory/Monoidal/Category.lean

tactic: rw [← tensor_comp, f.inv_hom_id]
state_before: C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V✝ W✝ X✝ Y✝ Z✝ V W X Y Z : C
f : V ≅ W
g : X ⟶ Y
h : Y ⟶ Z
⊢ (g ⊗ f.inv) ≫ (h ⊗ f.hom) = (g ⊗ 𝟙 W) ≫ (h ⊗ 𝟙 W)
state_after: C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V✝ W✝ X✝ Y✝ Z✝ V W X Y Z : C
f : V ≅ W
g : X ⟶ Y
h : Y ⟶ Z
⊢ g ≫ h ⊗ 𝟙 W = (g ⊗ 𝟙 W) ≫ (h ⊗ 𝟙 W)

tactic: simp [tensorHom_id]
state_before: C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V✝ W✝ X✝ Y✝ Z✝ V W X Y Z : C
f : V ≅ W
g : X ⟶ Y
h : Y ⟶ Z
⊢ g ≫ h ⊗ 𝟙 W = (g ⊗ 𝟙 W) ≫ (h ⊗ 𝟙 W)
state_after: no goals
Theorem: WeierstrassCurve.map_injective
File: Mathlib/AlgebraicGeometry/EllipticCurve/Weierstrass.lean

tactic: rcases mk.inj h with ⟨_, _, _, _, _⟩
state_before: R : Type u
inst✝¹ : CommRing R
W : WeierstrassCurve R
A : Type v
inst✝ : CommRing A
φ✝ φ : R →+* A
hφ : Function.Injective ⇑φ
x✝¹ x✝ : WeierstrassCurve R
h : (fun W => W.map φ) x✝¹ = (fun W => W.map φ) x✝
⊢ x✝¹ = x✝
state_after: case intro.intro.intro.intro
R : Type u
inst✝¹ : CommRing R
W : WeierstrassCurve R
A : Type v
inst✝ : CommRing A
φ✝ φ : R →+* A
hφ : Function.Injective ⇑φ
x✝¹ x✝ : WeierstrassCurve R
h : (fun W => W.map φ) x✝¹ = (fun W => W.map φ) x✝
left✝³ : φ x✝¹.a₁ = φ x✝.a₁
left✝² : φ x✝¹.a₂ = φ x✝.a₂
left✝¹ : φ x✝¹.a₃ = φ x✝.a₃
left✝ : φ x✝¹.a₄ = φ x✝.a₄
right✝ : φ x✝¹.a₆ = φ x✝.a₆
⊢ x✝¹ = x✝

tactic: ext <;> apply_fun _ using hφ <;> assumption
state_before: case intro.intro.intro.intro
R : Type u
inst✝¹ : CommRing R
W : WeierstrassCurve R
A : Type v
inst✝ : CommRing A
φ✝ φ : R →+* A
hφ : Function.Injective ⇑φ
x✝¹ x✝ : WeierstrassCurve R
h : (fun W => W.map φ) x✝¹ = (fun W => W.map φ) x✝
left✝³ : φ x✝¹.a₁ = φ x✝.a₁
left✝² : φ x✝¹.a₂ = φ x✝.a₂
left✝¹ : φ x✝¹.a₃ = φ x✝.a₃
left✝ : φ x✝¹.a₄ = φ x✝.a₄
right✝ : φ x✝¹.a₆ = φ x✝.a₆
⊢ x✝¹ = x✝
state_after: no goals
Theorem: Polynomial.C_mul_X_pow_eq_monomial
File: Mathlib/Algebra/Polynomial/Basic.lean

tactic: rw [pow_succ, ← mul_assoc, C_mul_X_pow_eq_monomial, X, monomial_mul_monomial, mul_one]
state_before: R : Type u
a b : R
m n✝ : ℕ
inst✝ : Semiring R
p q : R[X]
n : ℕ
⊢ C a * X ^ (n + 1) = (monomial (n + 1)) a
state_after: no goals
Theorem: EqualCharZero.of_not_mixedCharZero
File: Mathlib/Algebra/CharP/MixedCharZero.lean

tactic: intro I hI_ne_top
state_before: R : Type u_1
inst✝¹ : CommRing R
inst✝ : CharZero R
h : ∀ p > 0, ¬MixedCharZero R p
⊢ ∀ (I : Ideal R), I ≠ ⊤ → CharZero (R ⧸ I)
state_after: R : Type u_1
inst✝¹ : CommRing R
inst✝ : CharZero R
h : ∀ p > 0, ¬MixedCharZero R p
I : Ideal R
hI_ne_top : I ≠ ⊤
⊢ CharZero (R ⧸ I)

tactic: suffices CharP (R ⧸ I) 0 from CharP.charP_to_charZero _
state_before: R : Type u_1
inst✝¹ : CommRing R
inst✝ : CharZero R
h : ∀ p > 0, ¬MixedCharZero R p
I : Ideal R
hI_ne_top : I ≠ ⊤
⊢ CharZero (R ⧸ I)
state_after: R : Type u_1
inst✝¹ : CommRing R
inst✝ : CharZero R
h : ∀ p > 0, ¬MixedCharZero R p
I : Ideal R
hI_ne_top : I ≠ ⊤
⊢ CharP (R ⧸ I) 0

tactic: cases CharP.exists (R ⧸ I) with
| intro p hp =>
  cases p with
  | zero => exact hp
  | succ p =>
    have h_mixed : MixedCharZero R p.succ := ⟨⟨I, ⟨hI_ne_top, hp⟩⟩⟩
    exact absurd h_mixed (h p.succ p.succ_pos)
state_before: R : Type u_1
inst✝¹ : CommRing R
inst✝ : CharZero R
h : ∀ p > 0, ¬MixedCharZero R p
I : Ideal R
hI_ne_top : I ≠ ⊤
⊢ CharP (R ⧸ I) 0
state_after: no goals

tactic: cases p with
| zero => exact hp
| succ p =>
  have h_mixed : MixedCharZero R p.succ := ⟨⟨I, ⟨hI_ne_top, hp⟩⟩⟩
  exact absurd h_mixed (h p.succ p.succ_pos)
state_before: case intro
R : Type u_1
inst✝¹ : CommRing R
inst✝ : CharZero R
h : ∀ p > 0, ¬MixedCharZero R p
I : Ideal R
hI_ne_top : I ≠ ⊤
p : ℕ
hp : CharP (R ⧸ I) p
⊢ CharP (R ⧸ I) 0
state_after: no goals

tactic: exact hp
state_before: case intro.zero
R : Type u_1
inst✝¹ : CommRing R
inst✝ : CharZero R
h : ∀ p > 0, ¬MixedCharZero R p
I : Ideal R
hI_ne_top : I ≠ ⊤
hp : CharP (R ⧸ I) 0
⊢ CharP (R ⧸ I) 0
state_after: no goals

tactic: have h_mixed : MixedCharZero R p.succ := ⟨⟨I, ⟨hI_ne_top, hp⟩⟩⟩
state_before: case intro.succ
R : Type u_1
inst✝¹ : CommRing R
inst✝ : CharZero R
h : ∀ p > 0, ¬MixedCharZero R p
I : Ideal R
hI_ne_top : I ≠ ⊤
p : ℕ
hp : CharP (R ⧸ I) (p + 1)
⊢ CharP (R ⧸ I) 0
state_after: case intro.succ
R : Type u_1
inst✝¹ : CommRing R
inst✝ : CharZero R
h : ∀ p > 0, ¬MixedCharZero R p
I : Ideal R
hI_ne_top : I ≠ ⊤
p : ℕ
hp : CharP (R ⧸ I) (p + 1)
h_mixed : MixedCharZero R p.succ
⊢ CharP (R ⧸ I) 0

tactic: exact absurd h_mixed (h p.succ p.succ_pos)
state_before: case intro.succ
R : Type u_1
inst✝¹ : CommRing R
inst✝ : CharZero R
h : ∀ p > 0, ¬MixedCharZero R p
I : Ideal R
hI_ne_top : I ≠ ⊤
p : ℕ
hp : CharP (R ⧸ I) (p + 1)
h_mixed : MixedCharZero R p.succ
⊢ CharP (R ⧸ I) 0
state_after: no goals