1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: Complex.cos_surjective
File: Mathlib/Analysis/SpecialFunctions/Trigonometric/Complex.lean

tactic: intro x
state_before: ⊢ Function.Surjective cos
state_after: x : ℂ
⊢ ∃ a, cos a = x

tactic: obtain ⟨w, w₀, hw⟩ : ∃ w ≠ 0, 1 * w * w + -2 * x * w + 1 = 0 := by
  rcases exists_quadratic_eq_zero one_ne_zero
      ⟨_, (cpow_nat_inv_pow _ two_ne_zero).symm.trans <| pow_two _⟩ with
    ⟨w, hw⟩
  refine ⟨w, ?_, hw⟩
  rintro rfl
  simp only [zero_add, one_ne_zero, mul_zero] at hw
state_before: x : ℂ
⊢ ∃ a, cos a = x
state_after: case intro.intro
x w : ℂ
w₀ : w ≠ 0
hw : 1 * w * w + -2 * x * w + 1 = 0
⊢ ∃ a, cos a = x

tactic: refine ⟨log w / I, cos_eq_iff_quadratic.2 ?_⟩
state_before: case intro.intro
x w : ℂ
w₀ : w ≠ 0
hw : 1 * w * w + -2 * x * w + 1 = 0
⊢ ∃ a, cos a = x
state_after: case intro.intro
x w : ℂ
w₀ : w ≠ 0
hw : 1 * w * w + -2 * x * w + 1 = 0
⊢ cexp (log w / I * I) ^ 2 - 2 * x * cexp (log w / I * I) + 1 = 0

tactic: rw [div_mul_cancel₀ _ I_ne_zero, exp_log w₀]
state_before: case intro.intro
x w : ℂ
w₀ : w ≠ 0
hw : 1 * w * w + -2 * x * w + 1 = 0
⊢ cexp (log w / I * I) ^ 2 - 2 * x * cexp (log w / I * I) + 1 = 0
state_after: case intro.intro
x w : ℂ
w₀ : w ≠ 0
hw : 1 * w * w + -2 * x * w + 1 = 0
⊢ w ^ 2 - 2 * x * w + 1 = 0

tactic: convert hw using 1
state_before: case intro.intro
x w : ℂ
w₀ : w ≠ 0
hw : 1 * w * w + -2 * x * w + 1 = 0
⊢ w ^ 2 - 2 * x * w + 1 = 0
state_after: case h.e'_2
x w : ℂ
w₀ : w ≠ 0
hw : 1 * w * w + -2 * x * w + 1 = 0
⊢ w ^ 2 - 2 * x * w + 1 = 1 * w * w + -2 * x * w + 1

tactic: ring
state_before: case h.e'_2
x w : ℂ
w₀ : w ≠ 0
hw : 1 * w * w + -2 * x * w + 1 = 0
⊢ w ^ 2 - 2 * x * w + 1 = 1 * w * w + -2 * x * w + 1
state_after: no goals

tactic: rcases exists_quadratic_eq_zero one_ne_zero
    ⟨_, (cpow_nat_inv_pow _ two_ne_zero).symm.trans <| pow_two _⟩ with
  ⟨w, hw⟩
state_before: x : ℂ
⊢ ∃ w, w ≠ 0 ∧ 1 * w * w + -2 * x * w + 1 = 0
state_after: case intro
x w : ℂ
hw : 1 * w * w + ?m.84247 * w + ?m.84248 = 0
⊢ ∃ w, w ≠ 0 ∧ 1 * w * w + -2 * x * w + 1 = 0

tactic: refine ⟨w, ?_, hw⟩
state_before: case intro
x w : ℂ
hw : 1 * w * w + ?m.84247 * w + ?m.84248 = 0
⊢ ∃ w, w ≠ 0 ∧ 1 * w * w + -2 * x * w + 1 = 0
state_after: case intro
x w : ℂ
hw : 1 * w * w + -2 * x * w + 1 = 0
⊢ w ≠ 0

tactic: rintro rfl
state_before: case intro
x w : ℂ
hw : 1 * w * w + -2 * x * w + 1 = 0
⊢ w ≠ 0
state_after: case intro
x : ℂ
hw : 1 * 0 * 0 + -2 * x * 0 + 1 = 0
⊢ False

tactic: simp only [zero_add, one_ne_zero, mul_zero] at hw
state_before: case intro
x : ℂ
hw : 1 * 0 * 0 + -2 * x * 0 + 1 = 0
⊢ False
state_after: no goals
Theorem: compositionAsSet_card
File: Mathlib/Combinatorics/Enumerative/Composition.lean

tactic: have : Fintype.card (Finset (Fin (n - 1))) = 2 ^ (n - 1) := by simp
state_before: n✝ n : ℕ
⊢ Fintype.card (CompositionAsSet n) = 2 ^ (n - 1)
state_after: n✝ n : ℕ
this : Fintype.card (Finset (Fin (n - 1))) = 2 ^ (n - 1)
⊢ Fintype.card (CompositionAsSet n) = 2 ^ (n - 1)

tactic: rw [← this]
state_before: n✝ n : ℕ
this : Fintype.card (Finset (Fin (n - 1))) = 2 ^ (n - 1)
⊢ Fintype.card (CompositionAsSet n) = 2 ^ (n - 1)
state_after: n✝ n : ℕ
this : Fintype.card (Finset (Fin (n - 1))) = 2 ^ (n - 1)
⊢ Fintype.card (CompositionAsSet n) = Fintype.card (Finset (Fin (n - 1)))

tactic: exact Fintype.card_congr (compositionAsSetEquiv n)
state_before: n✝ n : ℕ
this : Fintype.card (Finset (Fin (n - 1))) = 2 ^ (n - 1)
⊢ Fintype.card (CompositionAsSet n) = Fintype.card (Finset (Fin (n - 1)))
state_after: no goals

tactic: simp
state_before: n✝ n : ℕ
⊢ Fintype.card (Finset (Fin (n - 1))) = 2 ^ (n - 1)
state_after: no goals
Theorem: CategoryTheory.PreservesImage.inv_comp_image_ι_map
File: Mathlib/CategoryTheory/Limits/Preserves/Shapes/Images.lean

tactic: simp
state_before: A : Type u₁
B : Type u₂
inst✝⁷ : Category.{v₁, u₁} A
inst✝⁶ : Category.{v₂, u₂} B
inst✝⁵ : HasEqualizers A
inst✝⁴ : HasImages A
inst✝³ : StrongEpiCategory B
inst✝² : HasImages B
L : A ⥤ B
inst✝¹ : {X Y Z : A} → (f : X ⟶ Z) → (g : Y ⟶ Z) → PreservesLimit (cospan f g) L
inst✝ : {X Y Z : A} → (f : X ⟶ Y) → (g : X ⟶ Z) → PreservesColimit (span f g) L
X Y : A
f : X ⟶ Y
⊢ (iso L f).inv ≫ image.ι (L.map f) = L.map (image.ι f)
state_after: no goals
Theorem: MeasureTheory.Measure.singularPart_zero_right
File: Mathlib/MeasureTheory/Decomposition/Lebesgue.lean

tactic: conv_rhs => rw [haveLebesgueDecomposition_add μ 0]
state_before: α : Type u_1
β : Type u_2
m : MeasurableSpace α
μ✝ ν μ : Measure α
⊢ μ.singularPart 0 = μ
state_after: α : Type u_1
β : Type u_2
m : MeasurableSpace α
μ✝ ν μ : Measure α
⊢ μ.singularPart 0 = μ.singularPart 0 + withDensity 0 (μ.rnDeriv 0)

tactic: simp
state_before: α : Type u_1
β : Type u_2
m : MeasurableSpace α
μ✝ ν μ : Measure α
⊢ μ.singularPart 0 = μ.singularPart 0 + withDensity 0 (μ.rnDeriv 0)
state_after: no goals
Theorem: TopCat.pullbackIsoProdSubtype_hom_apply
File: Mathlib/Topology/Category/TopCat/Limits/Pullbacks.lean

tactic: simpa using ConcreteCategory.congr_hom pullback.condition x
state_before: J : Type v
inst✝ : SmallCategory J
X Y Z : TopCat
f : X ⟶ Z
g : Y ⟶ Z
x : ConcreteCategory.forget.obj (pullback f g)
⊢ f (pullback.fst x, pullback.snd x).1 = g (pullback.fst x, pullback.snd x).2
state_after: no goals

tactic: apply Subtype.ext
state_before: J : Type v
inst✝ : SmallCategory J
X Y Z : TopCat
f : X ⟶ Z
g : Y ⟶ Z
x : ConcreteCategory.forget.obj (pullback f g)
⊢ (pullbackIsoProdSubtype f g).hom x = ⟨(pullback.fst x, pullback.snd x), ⋯⟩
state_after: case a
J : Type v
inst✝ : SmallCategory J
X Y Z : TopCat
f : X ⟶ Z
g : Y ⟶ Z
x : ConcreteCategory.forget.obj (pullback f g)
⊢ ↑((pullbackIsoProdSubtype f g).hom x) = ↑⟨(pullback.fst x, pullback.snd x), ⋯⟩

tactic: apply Prod.ext
state_before: case a
J : Type v
inst✝ : SmallCategory J
X Y Z : TopCat
f : X ⟶ Z
g : Y ⟶ Z
x : ConcreteCategory.forget.obj (pullback f g)
⊢ ↑((pullbackIsoProdSubtype f g).hom x) = ↑⟨(pullback.fst x, pullback.snd x), ⋯⟩
state_after: case a.a
J : Type v
inst✝ : SmallCategory J
X Y Z : TopCat
f : X ⟶ Z
g : Y ⟶ Z
x : ConcreteCategory.forget.obj (pullback f g)
⊢ (↑((pullbackIsoProdSubtype f g).hom x)).1 = (↑⟨(pullback.fst x, pullback.snd x), ⋯⟩).1

case a.a
J : Type v
inst✝ : SmallCategory J
X Y Z : TopCat
f : X ⟶ Z
g : Y ⟶ Z
x : ConcreteCategory.forget.obj (pullback f g)
⊢ (↑((pullbackIsoProdSubtype f g).hom x)).2 = (↑⟨(pullback.fst x, pullback.snd x), ⋯⟩).2

tactic: exacts [ConcreteCategory.congr_hom (pullbackIsoProdSubtype_hom_fst f g) x,
  ConcreteCategory.congr_hom (pullbackIsoProdSubtype_hom_snd f g) x]
state_before: case a.a
J : Type v
inst✝ : SmallCategory J
X Y Z : TopCat
f : X ⟶ Z
g : Y ⟶ Z
x : ConcreteCategory.forget.obj (pullback f g)
⊢ (↑((pullbackIsoProdSubtype f g).hom x)).1 = (↑⟨(pullback.fst x, pullback.snd x), ⋯⟩).1

case a.a
J : Type v
inst✝ : SmallCategory J
X Y Z : TopCat
f : X ⟶ Z
g : Y ⟶ Z
x : ConcreteCategory.forget.obj (pullback f g)
⊢ (↑((pullbackIsoProdSubtype f g).hom x)).2 = (↑⟨(pullback.fst x, pullback.snd x), ⋯⟩).2
state_after: no goals
Theorem: Real.Angle.sin_neg
File: Mathlib/Analysis/SpecialFunctions/Trigonometric/Angle.lean

tactic: induction θ using Real.Angle.induction_on
state_before: θ : Angle
⊢ (-θ).sin = -θ.sin
state_after: case h
x✝ : ℝ
⊢ (-↑x✝).sin = -(↑x✝).sin

tactic: exact Real.sin_neg _
state_before: case h
x✝ : ℝ
⊢ (-↑x✝).sin = -(↑x✝).sin
state_after: no goals
Theorem: YoungDiagram.transpose_eq_iff
File: Mathlib/Combinatorics/Young/YoungDiagram.lean

tactic: rw [transpose_eq_iff_eq_transpose]
state_before: μ ν : YoungDiagram
⊢ μ.transpose = ν.transpose ↔ μ = ν
state_after: μ ν : YoungDiagram
⊢ μ = ν.transpose.transpose ↔ μ = ν

tactic: simp
state_before: μ ν : YoungDiagram
⊢ μ = ν.transpose.transpose ↔ μ = ν
state_after: no goals
Theorem: norm_add_sq_eq_norm_sq_add_norm_sq_of_inner_eq_zero
File: Mathlib/Analysis/InnerProductSpace/Basic.lean

tactic: rw [@norm_add_mul_self 𝕜, add_right_cancel_iff, add_right_eq_self, mul_eq_zero]
state_before: 𝕜 : Type u_1
E : Type u_2
F : Type u_3
inst✝⁴ : _root_.RCLike 𝕜
inst✝³ : NormedAddCommGroup E
inst✝² : InnerProductSpace 𝕜 E
inst✝¹ : NormedAddCommGroup F
inst✝ : InnerProductSpace ℝ F
x y : E
h : ⟪x, y⟫_𝕜 = 0
⊢ ‖x + y‖ * ‖x + y‖ = ‖x‖ * ‖x‖ + ‖y‖ * ‖y‖
state_after: 𝕜 : Type u_1
E : Type u_2
F : Type u_3
inst✝⁴ : _root_.RCLike 𝕜
inst✝³ : NormedAddCommGroup E
inst✝² : InnerProductSpace 𝕜 E
inst✝¹ : NormedAddCommGroup F
inst✝ : InnerProductSpace ℝ F
x y : E
h : ⟪x, y⟫_𝕜 = 0
⊢ 2 = 0 ∨ re ⟪x, y⟫_𝕜 = 0

tactic: apply Or.inr
state_before: 𝕜 : Type u_1
E : Type u_2
F : Type u_3
inst✝⁴ : _root_.RCLike 𝕜
inst✝³ : NormedAddCommGroup E
inst✝² : InnerProductSpace 𝕜 E
inst✝¹ : NormedAddCommGroup F
inst✝ : InnerProductSpace ℝ F
x y : E
h : ⟪x, y⟫_𝕜 = 0
⊢ 2 = 0 ∨ re ⟪x, y⟫_𝕜 = 0
state_after: case h
𝕜 : Type u_1
E : Type u_2
F : Type u_3
inst✝⁴ : _root_.RCLike 𝕜
inst✝³ : NormedAddCommGroup E
inst✝² : InnerProductSpace 𝕜 E
inst✝¹ : NormedAddCommGroup F
inst✝ : InnerProductSpace ℝ F
x y : E
h : ⟪x, y⟫_𝕜 = 0
⊢ re ⟪x, y⟫_𝕜 = 0

tactic: simp only [h, zero_re']
state_before: case h
𝕜 : Type u_1
E : Type u_2
F : Type u_3
inst✝⁴ : _root_.RCLike 𝕜
inst✝³ : NormedAddCommGroup E
inst✝² : InnerProductSpace 𝕜 E
inst✝¹ : NormedAddCommGroup F
inst✝ : InnerProductSpace ℝ F
x y : E
h : ⟪x, y⟫_𝕜 = 0
⊢ re ⟪x, y⟫_𝕜 = 0
state_after: no goals
Theorem: LinearEquiv.finrank_eq
File: Mathlib/LinearAlgebra/Dimension/Finrank.lean

tactic: unfold finrank
state_before: R✝ : Type u
M✝ : Type v
N : Type w
inst✝⁹ : Ring R✝
inst✝⁸ : AddCommGroup M✝
inst✝⁷ : Module R✝ M✝
inst✝⁶ : AddCommGroup N
inst✝⁵ : Module R✝ N
R : Type u_1
M : Type u_2
M₂ : Type u_3
inst✝⁴ : Ring R
inst✝³ : AddCommGroup M
inst✝² : AddCommGroup M₂
inst✝¹ : Module R M
inst✝ : Module R M₂
f : M ≃ₗ[R] M₂
⊢ finrank R M = finrank R M₂
state_after: R✝ : Type u
M✝ : Type v
N : Type w
inst✝⁹ : Ring R✝
inst✝⁸ : AddCommGroup M✝
inst✝⁷ : Module R✝ M✝
inst✝⁶ : AddCommGroup N
inst✝⁵ : Module R✝ N
R : Type u_1
M : Type u_2
M₂ : Type u_3
inst✝⁴ : Ring R
inst✝³ : AddCommGroup M
inst✝² : AddCommGroup M₂
inst✝¹ : Module R M
inst✝ : Module R M₂
f : M ≃ₗ[R] M₂
⊢ toNat (Module.rank R M) = toNat (Module.rank R M₂)

tactic: rw [← Cardinal.toNat_lift, f.lift_rank_eq, Cardinal.toNat_lift]
state_before: R✝ : Type u
M✝ : Type v
N : Type w
inst✝⁹ : Ring R✝
inst✝⁸ : AddCommGroup M✝
inst✝⁷ : Module R✝ M✝
inst✝⁶ : AddCommGroup N
inst✝⁵ : Module R✝ N
R : Type u_1
M : Type u_2
M₂ : Type u_3
inst✝⁴ : Ring R
inst✝³ : AddCommGroup M
inst✝² : AddCommGroup M₂
inst✝¹ : Module R M
inst✝ : Module R M₂
f : M ≃ₗ[R] M₂
⊢ toNat (Module.rank R M) = toNat (Module.rank R M₂)
state_after: no goals
Theorem: WeierstrassCurve.Affine.CoordinateRing.XYIdeal_eq₁
File: Mathlib/AlgebraicGeometry/EllipticCurve/Group.lean

tactic: simp only [XYIdeal, XClass, YClass, linePolynomial]
state_before: R : Type u
S : Type v
inst✝¹ : CommRing R
inst✝ : CommRing S
W : Affine R
f : R →+* S
x y L : R
⊢ XYIdeal W x (C y) = XYIdeal W x (linePolynomial x y L)
state_after: R : Type u
S : Type v
inst✝¹ : CommRing R
inst✝ : CommRing S
W : Affine R
f : R →+* S
x y L : R
⊢ span {(mk W) (C (X - C x)), (mk W) (Y - C (C y))} =
    span {(mk W) (C (X - C x)), (mk W) (Y - C (C L * (X - C x) + C y))}

tactic: rw [← span_pair_add_mul_right <| mk W <| C <| C <| -L, ← _root_.map_mul, ← map_add]
state_before: R : Type u
S : Type v
inst✝¹ : CommRing R
inst✝ : CommRing S
W : Affine R
f : R →+* S
x y L : R
⊢ span {(mk W) (C (X - C x)), (mk W) (Y - C (C y))} =
    span {(mk W) (C (X - C x)), (mk W) (Y - C (C L * (X - C x) + C y))}
state_after: R : Type u
S : Type v
inst✝¹ : CommRing R
inst✝ : CommRing S
W : Affine R
f : R →+* S
x y L : R
⊢ span {(mk W) (C (X - C x)), (mk W) (Y - C (C y) + C (X - C x) * C (C (-L)))} =
    span {(mk W) (C (X - C x)), (mk W) (Y - C (C L * (X - C x) + C y))}

tactic: apply congr_arg (_ ∘ _ ∘ _ ∘ _)
state_before: R : Type u
S : Type v
inst✝¹ : CommRing R
inst✝ : CommRing S
W : Affine R
f : R →+* S
x y L : R
⊢ span {(mk W) (C (X - C x)), (mk W) (Y - C (C y) + C (X - C x) * C (C (-L)))} =
    span {(mk W) (C (X - C x)), (mk W) (Y - C (C L * (X - C x) + C y))}
state_after: R : Type u
S : Type v
inst✝¹ : CommRing R
inst✝ : CommRing S
W : Affine R
f : R →+* S
x y L : R
⊢ Y - C (C y) + C (X - C x) * C (C (-L)) = Y - C (C L * (X - C x) + C y)

tactic: C_simp
state_before: R : Type u
S : Type v
inst✝¹ : CommRing R
inst✝ : CommRing S
W : Affine R
f : R →+* S
x y L : R
⊢ Y - C (C y) + C (X - C x) * C (C (-L)) = Y - C (C L * (X - C x) + C y)
state_after: R : Type u
S : Type v
inst✝¹ : CommRing R
inst✝ : CommRing S
W : Affine R
f : R →+* S
x y L : R
⊢ Y - C (C y) + (C X - C (C x)) * -C (C L) = Y - (C (C L) * (C X - C (C x)) + C (C y))

tactic: ring1
state_before: R : Type u
S : Type v
inst✝¹ : CommRing R
inst✝ : CommRing S
W : Affine R
f : R →+* S
x y L : R
⊢ Y - C (C y) + (C X - C (C x)) * -C (C L) = Y - (C (C L) * (C X - C (C x)) + C (C y))
state_after: no goals
Theorem: Fintype.card_filter_piFinset_const
File: Mathlib/Data/Fintype/BigOperators.lean

tactic: rw [prod_const s.card, card_erase_of_mem (mem_univ _), card_univ]
state_before: α✝ : Type u_1
β : Type u_2
γ : Type u_3
ι : Type u_4
κ : Type u_5
α : ι → Type u_6
inst✝³ : DecidableEq ι
inst✝² : DecidableEq κ
inst✝¹ : Fintype ι
inst✝ : (i : ι) → DecidableEq (α i)
s : Finset κ
i : ι
j : κ
⊢ (if j ∈ s then ∏ b ∈ univ.erase i, s.card else 0) = if j ∈ s then s.card ^ (card ι - 1) else 0
state_after: no goals
Theorem: Function.Injective.sbtw_map_iff
File: Mathlib/Analysis/Convex/Between.lean

tactic: simp_rw [Sbtw, hf.wbtw_map_iff, hf.ne_iff]
state_before: R : Type u_1
V : Type u_2
V' : Type u_3
P : Type u_4
P' : Type u_5
inst✝⁶ : OrderedRing R
inst✝⁵ : AddCommGroup V
inst✝⁴ : Module R V
inst✝³ : AddTorsor V P
inst✝² : AddCommGroup V'
inst✝¹ : Module R V'
inst✝ : AddTorsor V' P'
x y z : P
f : P →ᵃ[R] P'
hf : Injective ⇑f
⊢ Sbtw R (f x) (f y) (f z) ↔ Sbtw R x y z
state_after: no goals
Theorem: SimpleGraph.Walk.IsPath.transfer
File: Mathlib/Combinatorics/SimpleGraph/Connectivity.lean

tactic: induction p with
| nil => simp
| cons _ _ ih =>
  simp only [Walk.transfer, cons_isPath_iff, support_transfer _ ] at pp ⊢
  exact ⟨ih _ pp.1, pp.2⟩
state_before: V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
u v : V
p : G.Walk u v
H : SimpleGraph V
hp : ∀ e ∈ p.edges, e ∈ H.edgeSet
pp : p.IsPath
⊢ (p.transfer H hp).IsPath
state_after: no goals

tactic: simp
state_before: case nil
V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
u v : V
p : G.Walk u v
H : SimpleGraph V
u✝ : V
hp : ∀ e ∈ Walk.nil.edges, e ∈ H.edgeSet
pp : Walk.nil.IsPath
⊢ (Walk.nil.transfer H hp).IsPath
state_after: no goals

tactic: simp only [Walk.transfer, cons_isPath_iff, support_transfer _ ] at pp ⊢
state_before: case cons
V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
u v : V
p : G.Walk u v
H : SimpleGraph V
u✝ v✝ w✝ : V
h✝ : G.Adj u✝ v✝
p✝ : G.Walk v✝ w✝
ih : ∀ (hp : ∀ e ∈ p✝.edges, e ∈ H.edgeSet), p✝.IsPath → (p✝.transfer H hp).IsPath
hp : ∀ e ∈ (cons h✝ p✝).edges, e ∈ H.edgeSet
pp : (cons h✝ p✝).IsPath
⊢ ((cons h✝ p✝).transfer H hp).IsPath
state_after: case cons
V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
u v : V
p : G.Walk u v
H : SimpleGraph V
u✝ v✝ w✝ : V
h✝ : G.Adj u✝ v✝
p✝ : G.Walk v✝ w✝
ih : ∀ (hp : ∀ e ∈ p✝.edges, e ∈ H.edgeSet), p✝.IsPath → (p✝.transfer H hp).IsPath
hp : ∀ e ∈ (cons h✝ p✝).edges, e ∈ H.edgeSet
pp : p✝.IsPath ∧ u✝ ∉ p✝.support
⊢ (p✝.transfer H ⋯).IsPath ∧ u✝ ∉ p✝.support

tactic: exact ⟨ih _ pp.1, pp.2⟩
state_before: case cons
V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
u v : V
p : G.Walk u v
H : SimpleGraph V
u✝ v✝ w✝ : V
h✝ : G.Adj u✝ v✝
p✝ : G.Walk v✝ w✝
ih : ∀ (hp : ∀ e ∈ p✝.edges, e ∈ H.edgeSet), p✝.IsPath → (p✝.transfer H hp).IsPath
hp : ∀ e ∈ (cons h✝ p✝).edges, e ∈ H.edgeSet
pp : p✝.IsPath ∧ u✝ ∉ p✝.support
⊢ (p✝.transfer H ⋯).IsPath ∧ u✝ ∉ p✝.support
state_after: no goals
Theorem: Isometry.completion_extension
File: Mathlib/Topology/MetricSpace/Completion.lean

tactic: fun_prop
state_before: α : Type u
β : Type v
inst✝² : PseudoMetricSpace α
inst✝¹ : MetricSpace β
inst✝ : CompleteSpace β
f : α → β
h : Isometry f
x y : Completion α
⊢ Continuous fun x => dist (Completion.extension f x.1) (Completion.extension f x.2)
state_after: no goals

tactic: fun_prop
state_before: α : Type u
β : Type v
inst✝² : PseudoMetricSpace α
inst✝¹ : MetricSpace β
inst✝ : CompleteSpace β
f : α → β
h : Isometry f
x y : Completion α
⊢ Continuous fun x => dist x.1 x.2
state_after: no goals

tactic: simp only [extension_coe h.uniformContinuous, Completion.dist_eq, h.dist_eq]
state_before: α : Type u
β : Type v
inst✝² : PseudoMetricSpace α
inst✝¹ : MetricSpace β
inst✝ : CompleteSpace β
f : α → β
h : Isometry f
x y : Completion α
x✝¹ x✝ : α
⊢ dist (Completion.extension f (↑α x✝¹)) (Completion.extension f (↑α x✝)) = dist (↑α x✝¹) (↑α x✝)
state_after: no goals
Theorem: MulAction.mem_stabilizer_of_finite_iff_le_smul
File: Mathlib/GroupTheory/GroupAction/Basic.lean

tactic: rw [← @inv_mem_iff, mem_stabilizer_of_finite_iff_smul_le s hs]
state_before: G : Type u_1
inst✝¹ : Group G
α : Type u_2
inst✝ : MulAction G α
s : Set α
hs : s.Finite
g : G
⊢ g ∈ stabilizer G s ↔ s ⊆ g • s
state_after: G : Type u_1
inst✝¹ : Group G
α : Type u_2
inst✝ : MulAction G α
s : Set α
hs : s.Finite
g : G
⊢ g⁻¹ • s ⊆ s ↔ s ⊆ g • s

tactic: exact Set.subset_set_smul_iff.symm
state_before: G : Type u_1
inst✝¹ : Group G
α : Type u_2
inst✝ : MulAction G α
s : Set α
hs : s.Finite
g : G
⊢ g⁻¹ • s ⊆ s ↔ s ⊆ g • s
state_after: no goals
Theorem: CategoryTheory.MonoidalPreadditive.tensor_add
File: Mathlib/CategoryTheory/Monoidal/Preadditive.lean

tactic: simp [tensorHom_def]
state_before: C : Type u_1
inst✝³ : Category.{u_2, u_1} C
inst✝² : Preadditive C
inst✝¹ : MonoidalCategory C
inst✝ : MonoidalPreadditive C
W X Y Z : C
f : W ⟶ X
g h : Y ⟶ Z
⊢ f ⊗ (g + h) = f ⊗ g + f ⊗ h
state_after: no goals
Theorem: Zsqrtd.not_divides_sq
File: Mathlib/NumberTheory/Zsqrtd/Basic.lean

tactic: have t := (divides_sq_eq_zero e).left
state_before: d : ℕ
dnsq : Nonsquare d
x y : ℕ
e : (x + 1) * (x + 1) = d * (y + 1) * (y + 1)
⊢ False
state_after: d : ℕ
dnsq : Nonsquare d
x y : ℕ
e : (x + 1) * (x + 1) = d * (y + 1) * (y + 1)
t : x + 1 = 0
⊢ False

tactic: contradiction
state_before: d : ℕ
dnsq : Nonsquare d
x y : ℕ
e : (x + 1) * (x + 1) = d * (y + 1) * (y + 1)
t : x + 1 = 0
⊢ False
state_after: no goals
Theorem: IsAlgebraic.of_pow
File: Mathlib/RingTheory/Algebraic.lean

tactic: obtain ⟨p, p_nonzero, hp⟩ := ht
state_before: R : Type u
S : Type u_1
A : Type v
inst✝⁶ : CommRing R
inst✝⁵ : CommRing S
inst✝⁴ : Ring A
inst✝³ : Algebra R A
inst✝² : Algebra R S
inst✝¹ : Algebra S A
inst✝ : IsScalarTower R S A
r : A
n : ℕ
hn : 0 < n
ht : IsAlgebraic R (r ^ n)
⊢ IsAlgebraic R r
state_after: case intro.intro
R : Type u
S : Type u_1
A : Type v
inst✝⁶ : CommRing R
inst✝⁵ : CommRing S
inst✝⁴ : Ring A
inst✝³ : Algebra R A
inst✝² : Algebra R S
inst✝¹ : Algebra S A
inst✝ : IsScalarTower R S A
r : A
n : ℕ
hn : 0 < n
p : R[X]
p_nonzero : p ≠ 0
hp : (aeval (r ^ n)) p = 0
⊢ IsAlgebraic R r

tactic: refine ⟨Polynomial.expand _ n p, ?_, ?_⟩
state_before: case intro.intro
R : Type u
S : Type u_1
A : Type v
inst✝⁶ : CommRing R
inst✝⁵ : CommRing S
inst✝⁴ : Ring A
inst✝³ : Algebra R A
inst✝² : Algebra R S
inst✝¹ : Algebra S A
inst✝ : IsScalarTower R S A
r : A
n : ℕ
hn : 0 < n
p : R[X]
p_nonzero : p ≠ 0
hp : (aeval (r ^ n)) p = 0
⊢ IsAlgebraic R r
state_after: case intro.intro.refine_1
R : Type u
S : Type u_1
A : Type v
inst✝⁶ : CommRing R
inst✝⁵ : CommRing S
inst✝⁴ : Ring A
inst✝³ : Algebra R A
inst✝² : Algebra R S
inst✝¹ : Algebra S A
inst✝ : IsScalarTower R S A
r : A
n : ℕ
hn : 0 < n
p : R[X]
p_nonzero : p ≠ 0
hp : (aeval (r ^ n)) p = 0
⊢ (expand R n) p ≠ 0

case intro.intro.refine_2
R : Type u
S : Type u_1
A : Type v
inst✝⁶ : CommRing R
inst✝⁵ : CommRing S
inst✝⁴ : Ring A
inst✝³ : Algebra R A
inst✝² : Algebra R S
inst✝¹ : Algebra S A
inst✝ : IsScalarTower R S A
r : A
n : ℕ
hn : 0 < n
p : R[X]
p_nonzero : p ≠ 0
hp : (aeval (r ^ n)) p = 0
⊢ (aeval r) ((expand R n) p) = 0

tactic: rwa [Polynomial.expand_ne_zero hn]
state_before: case intro.intro.refine_1
R : Type u
S : Type u_1
A : Type v
inst✝⁶ : CommRing R
inst✝⁵ : CommRing S
inst✝⁴ : Ring A
inst✝³ : Algebra R A
inst✝² : Algebra R S
inst✝¹ : Algebra S A
inst✝ : IsScalarTower R S A
r : A
n : ℕ
hn : 0 < n
p : R[X]
p_nonzero : p ≠ 0
hp : (aeval (r ^ n)) p = 0
⊢ (expand R n) p ≠ 0
state_after: no goals

tactic: rwa [Polynomial.expand_aeval n p r]
state_before: case intro.intro.refine_2
R : Type u
S : Type u_1
A : Type v
inst✝⁶ : CommRing R
inst✝⁵ : CommRing S
inst✝⁴ : Ring A
inst✝³ : Algebra R A
inst✝² : Algebra R S
inst✝¹ : Algebra S A
inst✝ : IsScalarTower R S A
r : A
n : ℕ
hn : 0 < n
p : R[X]
p_nonzero : p ≠ 0
hp : (aeval (r ^ n)) p = 0
⊢ (aeval r) ((expand R n) p) = 0
state_after: no goals
Theorem: MeasureTheory.exp_neg_llr
File: Mathlib/MeasureTheory/Measure/LogLikelihoodRatio.lean

tactic: filter_upwards [neg_llr hμν, exp_llr_of_ac' ν μ hμν] with x hx hx_exp_log
state_before: α : Type u_1
mα : MeasurableSpace α
μ ν : Measure α
f : α → ℝ
inst✝¹ : SigmaFinite μ
inst✝ : SigmaFinite ν
hμν : μ ≪ ν
⊢ (fun x => rexp (-llr μ ν x)) =ᶠ[ae μ] fun x => (ν.rnDeriv μ x).toReal
state_after: case h
α : Type u_1
mα : MeasurableSpace α
μ ν : Measure α
f : α → ℝ
inst✝¹ : SigmaFinite μ
inst✝ : SigmaFinite ν
hμν : μ ≪ ν
x : α
hx : (-llr μ ν) x = llr ν μ x
hx_exp_log : rexp (llr ν μ x) = (ν.rnDeriv μ x).toReal
⊢ rexp (-llr μ ν x) = (ν.rnDeriv μ x).toReal

tactic: rw [Pi.neg_apply] at hx
state_before: case h
α : Type u_1
mα : MeasurableSpace α
μ ν : Measure α
f : α → ℝ
inst✝¹ : SigmaFinite μ
inst✝ : SigmaFinite ν
hμν : μ ≪ ν
x : α
hx : (-llr μ ν) x = llr ν μ x
hx_exp_log : rexp (llr ν μ x) = (ν.rnDeriv μ x).toReal
⊢ rexp (-llr μ ν x) = (ν.rnDeriv μ x).toReal
state_after: case h
α : Type u_1
mα : MeasurableSpace α
μ ν : Measure α
f : α → ℝ
inst✝¹ : SigmaFinite μ
inst✝ : SigmaFinite ν
hμν : μ ≪ ν
x : α
hx : -llr μ ν x = llr ν μ x
hx_exp_log : rexp (llr ν μ x) = (ν.rnDeriv μ x).toReal
⊢ rexp (-llr μ ν x) = (ν.rnDeriv μ x).toReal

tactic: rw [hx, hx_exp_log]
state_before: case h
α : Type u_1
mα : MeasurableSpace α
μ ν : Measure α
f : α → ℝ
inst✝¹ : SigmaFinite μ
inst✝ : SigmaFinite ν
hμν : μ ≪ ν
x : α
hx : -llr μ ν x = llr ν μ x
hx_exp_log : rexp (llr ν μ x) = (ν.rnDeriv μ x).toReal
⊢ rexp (-llr μ ν x) = (ν.rnDeriv μ x).toReal
state_after: no goals
Theorem: RingHom.kerLift_injective
File: Mathlib/RingTheory/Ideal/QuotientOperations.lean

tactic: simp only [mem_ker, imp_self]
state_before: R : Type u
S : Type v
inst✝¹ : CommRing R
inst✝ : Semiring S
f : R →+* S
a : R
⊢ a ∈ ker f → f a = 0
state_after: no goals
Theorem: MeasureTheory.AECover.integral_tendsto_of_countably_generated
File: Mathlib/MeasureTheory/Integral/IntegralEqImproper.lean

tactic: convert h using 2
state_before: α : Type u_1
ι : Type u_2
E : Type u_3
inst✝⁴ : MeasurableSpace α
μ : Measure α
l : Filter ι
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace ℝ E
inst✝¹ : CompleteSpace E
inst✝ : l.IsCountablyGenerated
φ : ι → Set α
hφ : AECover μ l φ
f : α → E
hfi : Integrable f μ
h : Tendsto (fun i => ∫ (x : α), (φ i).indicator f x ∂μ) l (𝓝 (∫ (x : α), f x ∂μ))
⊢ Tendsto (fun i => ∫ (x : α) in φ i, f x ∂μ) l (𝓝 (∫ (x : α), f x ∂μ))
state_after: case h.e'_3.h
α : Type u_1
ι : Type u_2
E : Type u_3
inst✝⁴ : MeasurableSpace α
μ : Measure α
l : Filter ι
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace ℝ E
inst✝¹ : CompleteSpace E
inst✝ : l.IsCountablyGenerated
φ : ι → Set α
hφ : AECover μ l φ
f : α → E
hfi : Integrable f μ
h : Tendsto (fun i => ∫ (x : α), (φ i).indicator f x ∂μ) l (𝓝 (∫ (x : α), f x ∂μ))
x✝ : ι
⊢ ∫ (x : α) in φ x✝, f x ∂μ = ∫ (x : α), (φ x✝).indicator f x ∂μ

tactic: rw [integral_indicator (hφ.measurableSet _)]
state_before: case h.e'_3.h
α : Type u_1
ι : Type u_2
E : Type u_3
inst✝⁴ : MeasurableSpace α
μ : Measure α
l : Filter ι
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace ℝ E
inst✝¹ : CompleteSpace E
inst✝ : l.IsCountablyGenerated
φ : ι → Set α
hφ : AECover μ l φ
f : α → E
hfi : Integrable f μ
h : Tendsto (fun i => ∫ (x : α), (φ i).indicator f x ∂μ) l (𝓝 (∫ (x : α), f x ∂μ))
x✝ : ι
⊢ ∫ (x : α) in φ x✝, f x ∂μ = ∫ (x : α), (φ x✝).indicator f x ∂μ
state_after: no goals