1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: Filter.limsup_sup_filter
File: Mathlib/Order/LiminfLimsup.lean

tactic: refine le_antisymm ?_
  (sup_le (limsup_le_limsup_of_le le_sup_left) (limsup_le_limsup_of_le le_sup_right))
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Type u_4
ι' : Type u_5
inst✝ : CompleteDistribLattice α
f : Filter β
p q : β → Prop
u : β → α
g : Filter β
⊢ limsup u (f ⊔ g) = limsup u f ⊔ limsup u g
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Type u_4
ι' : Type u_5
inst✝ : CompleteDistribLattice α
f : Filter β
p q : β → Prop
u : β → α
g : Filter β
⊢ limsup u (f ⊔ g) ≤ limsup u f ⊔ limsup u g

tactic: simp_rw [limsup_eq, sInf_sup_eq, sup_sInf_eq, mem_setOf_eq, le_iInf₂_iff]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Type u_4
ι' : Type u_5
inst✝ : CompleteDistribLattice α
f : Filter β
p q : β → Prop
u : β → α
g : Filter β
⊢ limsup u (f ⊔ g) ≤ limsup u f ⊔ limsup u g
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Type u_4
ι' : Type u_5
inst✝ : CompleteDistribLattice α
f : Filter β
p q : β → Prop
u : β → α
g : Filter β
⊢ ∀ (i : α),
    (∀ᶠ (n : β) in f, u n ≤ i) →
      ∀ (i_1 : α), (∀ᶠ (n : β) in g, u n ≤ i_1) → sInf {a | ∀ᶠ (n : β) in f ⊔ g, u n ≤ a} ≤ i ⊔ i_1

tactic: intro a ha b hb
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Type u_4
ι' : Type u_5
inst✝ : CompleteDistribLattice α
f : Filter β
p q : β → Prop
u : β → α
g : Filter β
⊢ ∀ (i : α),
    (∀ᶠ (n : β) in f, u n ≤ i) →
      ∀ (i_1 : α), (∀ᶠ (n : β) in g, u n ≤ i_1) → sInf {a | ∀ᶠ (n : β) in f ⊔ g, u n ≤ a} ≤ i ⊔ i_1
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Type u_4
ι' : Type u_5
inst✝ : CompleteDistribLattice α
f : Filter β
p q : β → Prop
u : β → α
g : Filter β
a : α
ha : ∀ᶠ (n : β) in f, u n ≤ a
b : α
hb : ∀ᶠ (n : β) in g, u n ≤ b
⊢ sInf {a | ∀ᶠ (n : β) in f ⊔ g, u n ≤ a} ≤ a ⊔ b

tactic: exact sInf_le ⟨ha.mono fun _ h ↦ h.trans le_sup_left, hb.mono fun _ h ↦ h.trans le_sup_right⟩
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Type u_4
ι' : Type u_5
inst✝ : CompleteDistribLattice α
f : Filter β
p q : β → Prop
u : β → α
g : Filter β
a : α
ha : ∀ᶠ (n : β) in f, u n ≤ a
b : α
hb : ∀ᶠ (n : β) in g, u n ≤ b
⊢ sInf {a | ∀ᶠ (n : β) in f ⊔ g, u n ≤ a} ≤ a ⊔ b
state_after: no goals
Theorem: MeasurableEquiv.piCongrLeft_apply_apply
File: Mathlib/MeasureTheory/MeasurableSpace/Embedding.lean

tactic: rw [piCongrLeft, coe_mk, Equiv.piCongrLeft_apply_apply]
state_before: α : Type u_1
β✝ : Type u_2
γ : Type u_3
δ : Type u_4
δ' : Type u_5
ι✝ : Sort uι
s t u : Set α
inst✝⁶ : MeasurableSpace α
inst✝⁵ : MeasurableSpace β✝
inst✝⁴ : MeasurableSpace γ
inst✝³ : MeasurableSpace δ
π : δ' → Type u_6
π' : δ' → Type u_7
inst✝² : (x : δ') → MeasurableSpace (π x)
inst✝¹ : (x : δ') → MeasurableSpace (π' x)
ι : Type u_8
ι' : Type u_9
e : ι ≃ ι'
β : ι' → Type u_10
inst✝ : (i' : ι') → MeasurableSpace (β i')
x : (i : ι) → β (e i)
i : ι
⊢ (piCongrLeft (fun i' => β i') e) x (e i) = x i
state_after: no goals
Theorem: Matrix.conjTranspose_inv_natCast_smul
File: Mathlib/Data/Matrix/Basic.lean

tactic: simp
state_before: l : Type u_1
m : Type u_2
n : Type u_3
o : Type u_4
m' : o → Type u_5
n' : o → Type u_6
R : Type u_7
S : Type u_8
α : Type v
β : Type w
γ : Type u_9
inst✝³ : DivisionSemiring R
inst✝² : AddCommMonoid α
inst✝¹ : StarAddMonoid α
inst✝ : Module R α
c : ℕ
M : Matrix m n α
⊢ ∀ (i : n) (j : m), ((↑c)⁻¹ • M)ᴴ i j = ((↑c)⁻¹ • Mᴴ) i j
state_after: no goals
Theorem: AdjoinRoot.algHom_subsingleton
File: Mathlib/RingTheory/AdjoinRoot.lean

tactic: rw [← f.commutes, ← f.map_mul, algebraMap_eq, root_isInv, map_one]
state_before: R : Type u
S✝ : Type v
K : Type w
inst✝⁴ : CommRing R
f✝ : R[X]
inst✝³ : CommRing S✝
i : R →+* S✝
a : S✝
h : eval₂ i a f✝ = 0
inst✝² : Algebra R S✝
hfx : (aeval a) f✝ = 0
S : Type u_1
inst✝¹ : CommRing S
inst✝ : Algebra R S
r : R
f g : AdjoinRoot (C r * X - 1) →ₐ[R] S
⊢ (algebraMap R S) r * f (root (C r * X - 1)) = 1
state_after: no goals

tactic: rw [← g.commutes, ← g.map_mul, algebraMap_eq, root_isInv, map_one]
state_before: R : Type u
S✝ : Type v
K : Type w
inst✝⁴ : CommRing R
f✝ : R[X]
inst✝³ : CommRing S✝
i : R →+* S✝
a : S✝
h : eval₂ i a f✝ = 0
inst✝² : Algebra R S✝
hfx : (aeval a) f✝ = 0
S : Type u_1
inst✝¹ : CommRing S
inst✝ : Algebra R S
r : R
f g : AdjoinRoot (C r * X - 1) →ₐ[R] S
⊢ (algebraMap R S) r * g (root (C r * X - 1)) = 1
state_after: no goals
Theorem: EReal.inv_nonpos_of_nonpos
File: Mathlib/Data/Real/EReal.lean

tactic: induction a with
| h_bot | h_top => simp
| h_real a => rw [← coe_inv a, EReal.coe_nonpos, inv_nonpos]; exact EReal.coe_nonpos.1 h
state_before: a : EReal
h : a ≤ 0
⊢ a⁻¹ ≤ 0
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_nonpos, inv_nonpos]
state_before: case h_real
a : ℝ
h : ↑a ≤ 0
⊢ (↑a)⁻¹ ≤ 0
state_after: case h_real
a : ℝ
h : ↑a ≤ 0
⊢ a ≤ 0

tactic: exact EReal.coe_nonpos.1 h
state_before: case h_real
a : ℝ
h : ↑a ≤ 0
⊢ a ≤ 0
state_after: no goals
Theorem: NNReal.sqrt_eq_one
File: Mathlib/Data/Real/Sqrt.lean

tactic: simp [sqrt_eq_iff_eq_sq]
state_before: x y : ℝ≥0
⊢ sqrt x = 1 ↔ x = 1
state_after: no goals
Theorem: IsSelfAdjoint.val_re_map_spectrum
File: Mathlib/Analysis/NormedSpace/Star/Spectrum.lean

tactic: rintro ⟨z, hz, rfl⟩
state_before: A : Type u_1
inst✝⁵ : NormedRing A
inst✝⁴ : NormedAlgebra ℂ A
inst✝³ : CompleteSpace A
inst✝² : StarRing A
inst✝¹ : CstarRing A
inst✝ : StarModule ℂ A
a : A
ha : IsSelfAdjoint a
z : ℂ
⊢ z ∈ ofReal' ∘ re '' spectrum ℂ a → z ∈ spectrum ℂ a
state_after: case intro.intro
A : Type u_1
inst✝⁵ : NormedRing A
inst✝⁴ : NormedAlgebra ℂ A
inst✝³ : CompleteSpace A
inst✝² : StarRing A
inst✝¹ : CstarRing A
inst✝ : StarModule ℂ A
a : A
ha : IsSelfAdjoint a
z : ℂ
hz : z ∈ spectrum ℂ a
⊢ (ofReal' ∘ re) z ∈ spectrum ℂ a

tactic: simpa only [(ha.mem_spectrum_eq_re hz).symm, Function.comp_apply] using hz
state_before: case intro.intro
A : Type u_1
inst✝⁵ : NormedRing A
inst✝⁴ : NormedAlgebra ℂ A
inst✝³ : CompleteSpace A
inst✝² : StarRing A
inst✝¹ : CstarRing A
inst✝ : StarModule ℂ A
a : A
ha : IsSelfAdjoint a
z : ℂ
hz : z ∈ spectrum ℂ a
⊢ (ofReal' ∘ re) z ∈ spectrum ℂ a
state_after: no goals
Theorem: Polynomial.natSepDegree_le_of_dvd
File: Mathlib/FieldTheory/SeparableDegree.lean

tactic: simp_rw [natSepDegree_eq_of_isAlgClosed (AlgebraicClosure F)]
state_before: F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
f g : F[X]
h1 : f ∣ g
h2 : g ≠ 0
⊢ f.natSepDegree ≤ g.natSepDegree
state_after: F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
f g : F[X]
h1 : f ∣ g
h2 : g ≠ 0
⊢ (f.aroots (AlgebraicClosure F)).toFinset.card ≤ (g.aroots (AlgebraicClosure F)).toFinset.card

tactic: exact Finset.card_le_card <| Multiset.toFinset_subset.mpr <|
  Multiset.Le.subset <| roots.le_of_dvd (map_ne_zero h2) <| map_dvd _ h1
state_before: F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
f g : F[X]
h1 : f ∣ g
h2 : g ≠ 0
⊢ (f.aroots (AlgebraicClosure F)).toFinset.card ≤ (g.aroots (AlgebraicClosure F)).toFinset.card
state_after: no goals
Theorem: List.lt_findIdx_of_not
File: Mathlib/Data/List/Indexes.lean

tactic: by_contra! f
state_before: α : Type u
β : Type v
p : α → Bool
xs : List α
i : ℕ
h : i < xs.length
h2 : ∀ (j : ℕ) (hji : j ≤ i), ¬p (xs.get ⟨j, ⋯⟩) = true
⊢ i < findIdx p xs
state_after: α : Type u
β : Type v
p : α → Bool
xs : List α
i : ℕ
h : i < xs.length
h2 : ∀ (j : ℕ) (hji : j ≤ i), ¬p (xs.get ⟨j, ⋯⟩) = true
f : findIdx p xs ≤ i
⊢ False

tactic: exact absurd (@findIdx_get _ p xs (f.trans_lt h)) (h2 (xs.findIdx p) f)
state_before: α : Type u
β : Type v
p : α → Bool
xs : List α
i : ℕ
h : i < xs.length
h2 : ∀ (j : ℕ) (hji : j ≤ i), ¬p (xs.get ⟨j, ⋯⟩) = true
f : findIdx p xs ≤ i
⊢ False
state_after: no goals
Theorem: Localization.AtPrime.nilpotent_iff_not_unit_of_minimal
File: Mathlib/RingTheory/Ideal/MinimalPrime.lean

tactic: simpa only [← LocalRing.mem_maximalIdeal] using nilpotent_iff_mem_maximal_of_minimal hMin
state_before: R : Type u_1
inst✝ : CommSemiring R
I : Ideal R
hI : I.IsPrime
hMin : I ∈ minimalPrimes R
x : Localization I.primeCompl
⊢ IsNilpotent x ↔ x ∈ nonunits (Localization I.primeCompl)
state_after: no goals
Theorem: le_min
File: Mathlib/Init/Order/LinearOrder.lean

tactic: if h : a ≤ b
then simp [min_def, if_pos h]; exact h₁
else simp [min_def, if_neg h]; exact h₂
state_before: α : Type u
inst✝ : LinearOrder α
a b c : α
h₁ : c ≤ a
h₂ : c ≤ b
⊢ c ≤ min a b
state_after: no goals

tactic: simp [min_def, if_pos h]
state_before: α : Type u
inst✝ : LinearOrder α
a b c : α
h₁ : c ≤ a
h₂ : c ≤ b
h : a ≤ b
⊢ c ≤ min a b
state_after: α : Type u
inst✝ : LinearOrder α
a b c : α
h₁ : c ≤ a
h₂ : c ≤ b
h : a ≤ b
⊢ c ≤ a

tactic: exact h₁
state_before: α : Type u
inst✝ : LinearOrder α
a b c : α
h₁ : c ≤ a
h₂ : c ≤ b
h : a ≤ b
⊢ c ≤ a
state_after: no goals

tactic: simp [min_def, if_neg h]
state_before: α : Type u
inst✝ : LinearOrder α
a b c : α
h₁ : c ≤ a
h₂ : c ≤ b
h : ¬a ≤ b
⊢ c ≤ min a b
state_after: α : Type u
inst✝ : LinearOrder α
a b c : α
h₁ : c ≤ a
h₂ : c ≤ b
h : ¬a ≤ b
⊢ c ≤ b

tactic: exact h₂
state_before: α : Type u
inst✝ : LinearOrder α
a b c : α
h₁ : c ≤ a
h₂ : c ≤ b
h : ¬a ≤ b
⊢ c ≤ b
state_after: no goals
Theorem: Polynomial.cardinal_mk_le_max
File: Mathlib/Algebra/Polynomial/Cardinal.lean

tactic: cases subsingleton_or_nontrivial R
state_before: R : Type u
inst✝ : Semiring R
⊢ #R[X] ≤ max #R ℵ₀
state_after: case inl
R : Type u
inst✝ : Semiring R
h✝ : Subsingleton R
⊢ #R[X] ≤ max #R ℵ₀

case inr
R : Type u
inst✝ : Semiring R
h✝ : Nontrivial R
⊢ #R[X] ≤ max #R ℵ₀

tactic: exact (mk_eq_one _).trans_le (le_max_of_le_right one_le_aleph0)
state_before: case inl
R : Type u
inst✝ : Semiring R
h✝ : Subsingleton R
⊢ #R[X] ≤ max #R ℵ₀
state_after: no goals

tactic: exact cardinal_mk_eq_max.le
state_before: case inr
R : Type u
inst✝ : Semiring R
h✝ : Nontrivial R
⊢ #R[X] ≤ max #R ℵ₀
state_after: no goals
Theorem: AlgebraicGeometry.IsAffineOpen.isLocalization_of_eq_basicOpen
File: Mathlib/AlgebraicGeometry/AffineScheme.lean

tactic: subst e
state_before: X Y : Scheme
U : Opens ↑↑X.toPresheafedSpace
hU : IsAffineOpen U
f : ↑Γ(X, U)
V : Opens ↑↑X.toPresheafedSpace
i : V ⟶ U
e : V = X.basicOpen f
⊢ IsLocalization.Away f ↑Γ(X, V)
state_after: X Y : Scheme
U : Opens ↑↑X.toPresheafedSpace
hU : IsAffineOpen U
f : ↑Γ(X, U)
i : X.basicOpen f ⟶ U
⊢ IsLocalization.Away f ↑Γ(X, X.basicOpen f)

tactic: convert isLocalization_basicOpen hU f using 3
state_before: X Y : Scheme
U : Opens ↑↑X.toPresheafedSpace
hU : IsAffineOpen U
f : ↑Γ(X, U)
i : X.basicOpen f ⟶ U
⊢ IsLocalization.Away f ↑Γ(X, X.basicOpen f)
state_after: no goals
Theorem: convexHull_nonempty_iff
File: Mathlib/Analysis/Convex/Hull.lean

tactic: rw [nonempty_iff_ne_empty, nonempty_iff_ne_empty, Ne, Ne]
state_before: 𝕜 : Type u_1
E : Type u_2
F : Type u_3
inst✝⁴ : OrderedSemiring 𝕜
inst✝³ : AddCommMonoid E
inst✝² : AddCommMonoid F
inst✝¹ : Module 𝕜 E
inst✝ : Module 𝕜 F
s t : Set E
x y : E
⊢ ((convexHull 𝕜) s).Nonempty ↔ s.Nonempty
state_after: 𝕜 : Type u_1
E : Type u_2
F : Type u_3
inst✝⁴ : OrderedSemiring 𝕜
inst✝³ : AddCommMonoid E
inst✝² : AddCommMonoid F
inst✝¹ : Module 𝕜 E
inst✝ : Module 𝕜 F
s t : Set E
x y : E
⊢ ¬(convexHull 𝕜) s = ∅ ↔ ¬s = ∅

tactic: exact not_congr convexHull_empty_iff
state_before: 𝕜 : Type u_1
E : Type u_2
F : Type u_3
inst✝⁴ : OrderedSemiring 𝕜
inst✝³ : AddCommMonoid E
inst✝² : AddCommMonoid F
inst✝¹ : Module 𝕜 E
inst✝ : Module 𝕜 F
s t : Set E
x y : E
⊢ ¬(convexHull 𝕜) s = ∅ ↔ ¬s = ∅
state_after: no goals
Theorem: mem_maximals_iff
File: Mathlib/Order/Minimal.lean

tactic: simp only [maximals, Set.mem_sep_iff, and_congr_right_iff]
state_before: α : Type u_1
β : Type u_2
r r₁ r₂ : α → α → Prop
s t : Set α
a b x : α
inst✝ : IsAntisymm α r
⊢ x ∈ maximals r s ↔ x ∈ s ∧ ∀ ⦃y : α⦄, y ∈ s → r x y → x = y
state_after: α : Type u_1
β : Type u_2
r r₁ r₂ : α → α → Prop
s t : Set α
a b x : α
inst✝ : IsAntisymm α r
⊢ x ∈ s → ((∀ ⦃b : α⦄, b ∈ s → r x b → r b x) ↔ ∀ ⦃y : α⦄, y ∈ s → r x y → x = y)

tactic: refine fun _ ↦ ⟨fun h y hys hxy ↦ antisymm hxy (h hys hxy), fun h y hys hxy ↦ ?_⟩
state_before: α : Type u_1
β : Type u_2
r r₁ r₂ : α → α → Prop
s t : Set α
a b x : α
inst✝ : IsAntisymm α r
⊢ x ∈ s → ((∀ ⦃b : α⦄, b ∈ s → r x b → r b x) ↔ ∀ ⦃y : α⦄, y ∈ s → r x y → x = y)
state_after: α : Type u_1
β : Type u_2
r r₁ r₂ : α → α → Prop
s t : Set α
a b x : α
inst✝ : IsAntisymm α r
x✝ : x ∈ s
h : ∀ ⦃y : α⦄, y ∈ s → r x y → x = y
y : α
hys : y ∈ s
hxy : r x y
⊢ r y x

tactic: convert hxy <;> rw [h hys hxy]
state_before: α : Type u_1
β : Type u_2
r r₁ r₂ : α → α → Prop
s t : Set α
a b x : α
inst✝ : IsAntisymm α r
x✝ : x ∈ s
h : ∀ ⦃y : α⦄, y ∈ s → r x y → x = y
y : α
hys : y ∈ s
hxy : r x y
⊢ r y x
state_after: no goals
Theorem: ContinuousLinearMap.ring_inverse_eq_map_inverse
File: Mathlib/Topology/Algebra/Module/Basic.lean

tactic: ext
state_before: R : Type u_1
M : Type u_2
M₂ : Type u_3
inst✝⁷ : TopologicalSpace M
inst✝⁶ : TopologicalSpace M₂
inst✝⁵ : Ring R
inst✝⁴ : AddCommGroup M
inst✝³ : TopologicalAddGroup M
inst✝² : Module R M
inst✝¹ : AddCommGroup M₂
inst✝ : Module R M₂
⊢ Ring.inverse = inverse
state_after: case h.h
R : Type u_1
M : Type u_2
M₂ : Type u_3
inst✝⁷ : TopologicalSpace M
inst✝⁶ : TopologicalSpace M₂
inst✝⁵ : Ring R
inst✝⁴ : AddCommGroup M
inst✝³ : TopologicalAddGroup M
inst✝² : Module R M
inst✝¹ : AddCommGroup M₂
inst✝ : Module R M₂
x✝¹ : M →L[R] M
x✝ : M
⊢ (Ring.inverse x✝¹) x✝ = x✝¹.inverse x✝

tactic: simp [to_ring_inverse (ContinuousLinearEquiv.refl R M)]
state_before: case h.h
R : Type u_1
M : Type u_2
M₂ : Type u_3
inst✝⁷ : TopologicalSpace M
inst✝⁶ : TopologicalSpace M₂
inst✝⁵ : Ring R
inst✝⁴ : AddCommGroup M
inst✝³ : TopologicalAddGroup M
inst✝² : Module R M
inst✝¹ : AddCommGroup M₂
inst✝ : Module R M₂
x✝¹ : M →L[R] M
x✝ : M
⊢ (Ring.inverse x✝¹) x✝ = x✝¹.inverse x✝
state_after: no goals
Theorem: DFinsupp.comapDomain_zero
File: Mathlib/Data/DFinsupp/Basic.lean

tactic: ext
state_before: ι : Type u
γ : Type w
β : ι → Type v
β₁ : ι → Type v₁
β₂ : ι → Type v₂
inst✝¹ : DecidableEq ι
κ : Type u_1
inst✝ : (i : ι) → Zero (β i)
h : κ → ι
hh : Function.Injective h
⊢ comapDomain h hh 0 = 0
state_after: case h
ι : Type u
γ : Type w
β : ι → Type v
β₁ : ι → Type v₁
β₂ : ι → Type v₂
inst✝¹ : DecidableEq ι
κ : Type u_1
inst✝ : (i : ι) → Zero (β i)
h : κ → ι
hh : Function.Injective h
i✝ : κ
⊢ (comapDomain h hh 0) i✝ = 0 i✝

tactic: rw [zero_apply, comapDomain_apply, zero_apply]
state_before: case h
ι : Type u
γ : Type w
β : ι → Type v
β₁ : ι → Type v₁
β₂ : ι → Type v₂
inst✝¹ : DecidableEq ι
κ : Type u_1
inst✝ : (i : ι) → Zero (β i)
h : κ → ι
hh : Function.Injective h
i✝ : κ
⊢ (comapDomain h hh 0) i✝ = 0 i✝
state_after: no goals
Theorem: Polynomial.eval_zero_map
File: Mathlib/Algebra/Polynomial/Eval.lean

tactic: simp [← coeff_zero_eq_eval_zero]
state_before: R : Type u
S : Type v
T : Type w
ι : Type y
a b : R
m n : ℕ
inst✝¹ : Semiring R
p✝ q r : R[X]
inst✝ : Semiring S
f✝ f : R →+* S
p : R[X]
⊢ eval 0 (map f p) = f (eval 0 p)
state_after: no goals
Theorem: Turing.ToPartrec.stepNormal.is_ret
File: Mathlib/Computability/TMToPartrec.lean

tactic: induction c generalizing k v with
| cons _f fs IHf _IHfs => apply IHf
| comp f _g _IHf IHg => apply IHg
| case f g IHf IHg =>
  rw [stepNormal]
  simp only []
  cases v.headI <;> [apply IHf; apply IHg]
| fix f IHf => apply IHf
| _ => exact ⟨_, _, rfl⟩
state_before: c : Code
k : Cont
v : List ℕ
⊢ ∃ k' v', stepNormal c k v = Cfg.ret k' v'
state_after: no goals

tactic: apply IHf
state_before: case cons
_f fs : Code
IHf : ∀ (k : Cont) (v : List ℕ), ∃ k' v', stepNormal _f k v = Cfg.ret k' v'
_IHfs : ∀ (k : Cont) (v : List ℕ), ∃ k' v', stepNormal fs k v = Cfg.ret k' v'
k : Cont
v : List ℕ
⊢ ∃ k' v', stepNormal (_f.cons fs) k v = Cfg.ret k' v'
state_after: no goals

tactic: apply IHg
state_before: case comp
f _g : Code
_IHf : ∀ (k : Cont) (v : List ℕ), ∃ k' v', stepNormal f k v = Cfg.ret k' v'
IHg : ∀ (k : Cont) (v : List ℕ), ∃ k' v', stepNormal _g k v = Cfg.ret k' v'
k : Cont
v : List ℕ
⊢ ∃ k' v', stepNormal (f.comp _g) k v = Cfg.ret k' v'
state_after: no goals

tactic: rw [stepNormal]
state_before: case case
f g : Code
IHf : ∀ (k : Cont) (v : List ℕ), ∃ k' v', stepNormal f k v = Cfg.ret k' v'
IHg : ∀ (k : Cont) (v : List ℕ), ∃ k' v', stepNormal g k v = Cfg.ret k' v'
k : Cont
v : List ℕ
⊢ ∃ k' v', stepNormal (f.case g) k v = Cfg.ret k' v'
state_after: case case
f g : Code
IHf : ∀ (k : Cont) (v : List ℕ), ∃ k' v', stepNormal f k v = Cfg.ret k' v'
IHg : ∀ (k : Cont) (v : List ℕ), ∃ k' v', stepNormal g k v = Cfg.ret k' v'
k : Cont
v : List ℕ
⊢ ∃ k' v',
    (fun k v => Nat.rec (stepNormal f k v.tail) (fun y x => stepNormal g k (y :: v.tail)) v.headI) k v = Cfg.ret k' v'

tactic: simp only []
state_before: case case
f g : Code
IHf : ∀ (k : Cont) (v : List ℕ), ∃ k' v', stepNormal f k v = Cfg.ret k' v'
IHg : ∀ (k : Cont) (v : List ℕ), ∃ k' v', stepNormal g k v = Cfg.ret k' v'
k : Cont
v : List ℕ
⊢ ∃ k' v',
    (fun k v => Nat.rec (stepNormal f k v.tail) (fun y x => stepNormal g k (y :: v.tail)) v.headI) k v = Cfg.ret k' v'
state_after: case case
f g : Code
IHf : ∀ (k : Cont) (v : List ℕ), ∃ k' v', stepNormal f k v = Cfg.ret k' v'
IHg : ∀ (k : Cont) (v : List ℕ), ∃ k' v', stepNormal g k v = Cfg.ret k' v'
k : Cont
v : List ℕ
⊢ ∃ k' v', Nat.rec (stepNormal f k v.tail) (fun y x => stepNormal g k (y :: v.tail)) v.headI = Cfg.ret k' v'

tactic: cases v.headI <;> [apply IHf; apply IHg]
state_before: case case
f g : Code
IHf : ∀ (k : Cont) (v : List ℕ), ∃ k' v', stepNormal f k v = Cfg.ret k' v'
IHg : ∀ (k : Cont) (v : List ℕ), ∃ k' v', stepNormal g k v = Cfg.ret k' v'
k : Cont
v : List ℕ
⊢ ∃ k' v', Nat.rec (stepNormal f k v.tail) (fun y x => stepNormal g k (y :: v.tail)) v.headI = Cfg.ret k' v'
state_after: no goals

tactic: apply IHf
state_before: case fix
f : Code
IHf : ∀ (k : Cont) (v : List ℕ), ∃ k' v', stepNormal f k v = Cfg.ret k' v'
k : Cont
v : List ℕ
⊢ ∃ k' v', stepNormal f.fix k v = Cfg.ret k' v'
state_after: no goals

tactic: exact ⟨_, _, rfl⟩
state_before: case tail
k : Cont
v : List ℕ
⊢ ∃ k' v', stepNormal Code.tail k v = Cfg.ret k' v'
state_after: no goals
Theorem: Stream'.get_interleave_right
File: Mathlib/Data/Stream/Init.lean

tactic: change get (s₁ ⋈ s₂) (succ (succ (2 * n + 1))) = get s₂ (succ n)
state_before: α : Type u
β : Type v
δ : Type w
n : ℕ
s₁ s₂ : Stream' α
⊢ (s₁ ⋈ s₂).get (2 * (n + 1) + 1) = s₂.get (n + 1)
state_after: α : Type u
β : Type v
δ : Type w
n : ℕ
s₁ s₂ : Stream' α
⊢ (s₁ ⋈ s₂).get (2 * n + 1).succ.succ = s₂.get n.succ

tactic: rw [get_succ, get_succ, interleave_eq, tail_cons, tail_cons,
  get_interleave_right n (tail s₁) (tail s₂)]
state_before: α : Type u
β : Type v
δ : Type w
n : ℕ
s₁ s₂ : Stream' α
⊢ (s₁ ⋈ s₂).get (2 * n + 1).succ.succ = s₂.get n.succ
state_after: α : Type u
β : Type v
δ : Type w
n : ℕ
s₁ s₂ : Stream' α
⊢ s₂.tail.get n = s₂.get n.succ

tactic: rfl
state_before: α : Type u
β : Type v
δ : Type w
n : ℕ
s₁ s₂ : Stream' α
⊢ s₂.tail.get n = s₂.get n.succ
state_after: no goals
Theorem: SimpleGraph.degree_lt_card_verts
File: Mathlib/Combinatorics/SimpleGraph/Finite.lean

tactic: classical
apply Finset.card_lt_card
rw [Finset.ssubset_iff]
exact ⟨v, by simp, Finset.subset_univ _⟩
state_before: V : Type u_1
G : SimpleGraph V
e : Sym2 V
inst✝¹ : Fintype V
inst✝ : DecidableRel G.Adj
v : V
⊢ G.degree v < Fintype.card V
state_after: no goals

tactic: apply Finset.card_lt_card
state_before: V : Type u_1
G : SimpleGraph V
e : Sym2 V
inst✝¹ : Fintype V
inst✝ : DecidableRel G.Adj
v : V
⊢ G.degree v < Fintype.card V
state_after: case h
V : Type u_1
G : SimpleGraph V
e : Sym2 V
inst✝¹ : Fintype V
inst✝ : DecidableRel G.Adj
v : V
⊢ G.neighborFinset v ⊂ univ

tactic: rw [Finset.ssubset_iff]
state_before: case h
V : Type u_1
G : SimpleGraph V
e : Sym2 V
inst✝¹ : Fintype V
inst✝ : DecidableRel G.Adj
v : V
⊢ G.neighborFinset v ⊂ univ
state_after: case h
V : Type u_1
G : SimpleGraph V
e : Sym2 V
inst✝¹ : Fintype V
inst✝ : DecidableRel G.Adj
v : V
⊢ ∃ a ∉ G.neighborFinset v, insert a (G.neighborFinset v) ⊆ univ

tactic: exact ⟨v, by simp, Finset.subset_univ _⟩
state_before: case h
V : Type u_1
G : SimpleGraph V
e : Sym2 V
inst✝¹ : Fintype V
inst✝ : DecidableRel G.Adj
v : V
⊢ ∃ a ∉ G.neighborFinset v, insert a (G.neighborFinset v) ⊆ univ
state_after: no goals

tactic: simp
state_before: V : Type u_1
G : SimpleGraph V
e : Sym2 V
inst✝¹ : Fintype V
inst✝ : DecidableRel G.Adj
v : V
⊢ v ∉ G.neighborFinset v
state_after: no goals
Theorem: Complex.hasDerivAt_exp
File: Mathlib/Analysis/SpecialFunctions/ExpDeriv.lean

tactic: rw [hasDerivAt_iff_isLittleO_nhds_zero]
state_before: 𝕜 : Type u_1
inst✝¹ : NontriviallyNormedField 𝕜
inst✝ : NormedAlgebra 𝕜 ℂ
x : ℂ
⊢ HasDerivAt cexp (cexp x) x
state_after: 𝕜 : Type u_1
inst✝¹ : NontriviallyNormedField 𝕜
inst✝ : NormedAlgebra 𝕜 ℂ
x : ℂ
⊢ (fun h => cexp (x + h) - cexp x - h • cexp x) =o[𝓝 0] fun h => h

tactic: have : (1 : ℕ) < 2 := by norm_num
state_before: 𝕜 : Type u_1
inst✝¹ : NontriviallyNormedField 𝕜
inst✝ : NormedAlgebra 𝕜 ℂ
x : ℂ
⊢ (fun h => cexp (x + h) - cexp x - h • cexp x) =o[𝓝 0] fun h => h
state_after: 𝕜 : Type u_1
inst✝¹ : NontriviallyNormedField 𝕜
inst✝ : NormedAlgebra 𝕜 ℂ
x : ℂ
this : 1 < 2
⊢ (fun h => cexp (x + h) - cexp x - h • cexp x) =o[𝓝 0] fun h => h

tactic: refine (IsBigO.of_bound ‖exp x‖ ?_).trans_isLittleO (isLittleO_pow_id this)
state_before: 𝕜 : Type u_1
inst✝¹ : NontriviallyNormedField 𝕜
inst✝ : NormedAlgebra 𝕜 ℂ
x : ℂ
this : 1 < 2
⊢ (fun h => cexp (x + h) - cexp x - h • cexp x) =o[𝓝 0] fun h => h
state_after: 𝕜 : Type u_1
inst✝¹ : NontriviallyNormedField 𝕜
inst✝ : NormedAlgebra 𝕜 ℂ
x : ℂ
this : 1 < 2
⊢ ∀ᶠ (x_1 : ℂ) in 𝓝 0, ‖cexp (x + x_1) - cexp x - x_1 • cexp x‖ ≤ ‖cexp x‖ * ‖x_1 ^ 2‖

tactic: filter_upwards [Metric.ball_mem_nhds (0 : ℂ) zero_lt_one]
state_before: 𝕜 : Type u_1
inst✝¹ : NontriviallyNormedField 𝕜
inst✝ : NormedAlgebra 𝕜 ℂ
x : ℂ
this : 1 < 2
⊢ ∀ᶠ (x_1 : ℂ) in 𝓝 0, ‖cexp (x + x_1) - cexp x - x_1 • cexp x‖ ≤ ‖cexp x‖ * ‖x_1 ^ 2‖
state_after: case h
𝕜 : Type u_1
inst✝¹ : NontriviallyNormedField 𝕜
inst✝ : NormedAlgebra 𝕜 ℂ
x : ℂ
this : 1 < 2
⊢ ∀ a ∈ Metric.ball 0 1, ‖cexp (x + a) - cexp x - a • cexp x‖ ≤ ‖cexp x‖ * ‖a ^ 2‖

tactic: simp only [Metric.mem_ball, dist_zero_right, norm_pow]
state_before: case h
𝕜 : Type u_1
inst✝¹ : NontriviallyNormedField 𝕜
inst✝ : NormedAlgebra 𝕜 ℂ
x : ℂ
this : 1 < 2
⊢ ∀ a ∈ Metric.ball 0 1, ‖cexp (x + a) - cexp x - a • cexp x‖ ≤ ‖cexp x‖ * ‖a ^ 2‖
state_after: case h
𝕜 : Type u_1
inst✝¹ : NontriviallyNormedField 𝕜
inst✝ : NormedAlgebra 𝕜 ℂ
x : ℂ
this : 1 < 2
⊢ ∀ (a : ℂ), ‖a‖ < 1 → ‖cexp (x + a) - cexp x - a • cexp x‖ ≤ ‖cexp x‖ * ‖a‖ ^ 2

tactic: exact fun z hz => exp_bound_sq x z hz.le
state_before: case h
𝕜 : Type u_1
inst✝¹ : NontriviallyNormedField 𝕜
inst✝ : NormedAlgebra 𝕜 ℂ
x : ℂ
this : 1 < 2
⊢ ∀ (a : ℂ), ‖a‖ < 1 → ‖cexp (x + a) - cexp x - a • cexp x‖ ≤ ‖cexp x‖ * ‖a‖ ^ 2
state_after: no goals

tactic: norm_num
state_before: 𝕜 : Type u_1
inst✝¹ : NontriviallyNormedField 𝕜
inst✝ : NormedAlgebra 𝕜 ℂ
x : ℂ
⊢ 1 < 2
state_after: no goals
Theorem: IsSemiringHom.comp
File: Mathlib/Deprecated/Ring.lean

tactic: simpa [map_zero hf] using map_zero hg
state_before: α : Type u
β : Type v
inst✝² : Semiring α
inst✝¹ : Semiring β
f : α → β
hf✝ : IsSemiringHom f
x y : α
hf : IsSemiringHom f
γ : Type u_1
inst✝ : Semiring γ
g : β → γ
hg : IsSemiringHom g
⊢ (g ∘ f) 0 = 0
state_after: no goals

tactic: simpa [map_one hf] using map_one hg
state_before: α : Type u
β : Type v
inst✝² : Semiring α
inst✝¹ : Semiring β
f : α → β
hf✝ : IsSemiringHom f
x y : α
hf : IsSemiringHom f
γ : Type u_1
inst✝ : Semiring γ
g : β → γ
hg : IsSemiringHom g
⊢ (g ∘ f) 1 = 1
state_after: no goals

tactic: simp [map_add hf, map_add hg]
state_before: α : Type u
β : Type v
inst✝² : Semiring α
inst✝¹ : Semiring β
f : α → β
hf✝ : IsSemiringHom f
x✝ y✝ : α
hf : IsSemiringHom f
γ : Type u_1
inst✝ : Semiring γ
g : β → γ
hg : IsSemiringHom g
x y : α
⊢ (g ∘ f) (x + y) = (g ∘ f) x + (g ∘ f) y
state_after: no goals

tactic: simp [map_mul hf, map_mul hg]
state_before: α : Type u
β : Type v
inst✝² : Semiring α
inst✝¹ : Semiring β
f : α → β
hf✝ : IsSemiringHom f
x✝ y✝ : α
hf : IsSemiringHom f
γ : Type u_1
inst✝ : Semiring γ
g : β → γ
hg : IsSemiringHom g
x y : α
⊢ (g ∘ f) (x * y) = (g ∘ f) x * (g ∘ f) y
state_after: no goals