tasksource/leandojo huggingface dataset:
Theorem: Set.Iic_union_Icc
File: Mathlib/Data/Set/Intervals/Basic.lean

tactic: cases' le_or_lt c d with hcd hcd <;> simp [hcd] at h
state_before: α : Type u_1
β : Type ?u.109826
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
h : min c d ≤ b
⊢ Iic b ∪ Icc c d = Iic (max b d)

tactic: exact Iic_union_Icc' h
state_before: case inl
α : Type u_1
β : Type ?u.109826
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
hcd : c ≤ d
h : c ≤ b
⊢ Iic b ∪ Icc c d = Iic (max b d)

tactic: cases' h with h h
state_before: case inr
α : Type u_1
β : Type ?u.109826
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
hcd : d < c
h : c ≤ b ∨ d ≤ b
⊢ Iic b ∪ Icc c d = Iic (max b d)

tactic: have hdb : d ≤ b := hcd.le.trans h
state_before: case inr.inl
α : Type u_1
β : Type ?u.109826
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
hcd : d < c
h : c ≤ b
⊢ Iic b ∪ Icc c d = Iic (max b d)

tactic: simp [*]
state_before: case inr.inl
α : Type u_1
β : Type ?u.109826
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
hcd : d < c
h : c ≤ b
hdb : d ≤ b
⊢ Iic b ∪ Icc c d = Iic (max b d)

tactic: simp [*]
state_before: case inr.inr
α : Type u_1
β : Type ?u.109826
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
hcd : d < c
h : d ≤ b
⊢ Iic b ∪ Icc c d = Iic (max b d)
Theorem: String.utf8Len_append
File: Std/Data/String/Lemmas.lean

tactic: induction cs₁ <;> simp [*, Nat.add_right_comm]
state_before: cs₁ cs₂ : List Char
⊢ utf8Len (cs₁ ++ cs₂) = utf8Len cs₁ + utf8Len cs₂
Theorem: HasFPowerSeriesAt.sub
File: Mathlib/Analysis/Analytic/Basic.lean

tactic: simpa only [sub_eq_add_neg] using hf.add hg.neg
state_before: 𝕜 : Type u_1
E : Type u_2
F : Type u_3
G : Type ?u.553210
inst✝⁶ : NontriviallyNormedField 𝕜
inst✝⁵ : NormedAddCommGroup E
inst✝⁴ : NormedSpace 𝕜 E
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
inst✝¹ : NormedAddCommGroup G
inst✝ : NormedSpace 𝕜 G
f g : E → F
p pf pg : FormalMultilinearSeries 𝕜 E F
x : E
r r' : ℝ≥0∞
hf : HasFPowerSeriesAt f pf x
hg : HasFPowerSeriesAt g pg x
⊢ HasFPowerSeriesAt (f - g) (pf - pg) x
Theorem: IsGroupHom.map_inv
File: Mathlib/Deprecated/Group.lean

tactic: rw [← hf.map_mul, inv_mul_self, hf.map_one]
state_before: α : Type u
β : Type v
inst✝¹ : Group α
inst✝ : Group β
f : α → β
hf✝ hf : IsGroupHom f
a : α
⊢ f a⁻¹ * f a = 1
Theorem: Submonoid.LocalizationMap.mul_mk'_eq_mk'_of_mul
File: Mathlib/GroupTheory/MonoidLocalization.lean

tactic: rw [← mk'_one, ← mk'_mul, one_mul]
state_before: M : Type u_1
inst✝² : CommMonoid M
S : Submonoid M
N : Type u_2
inst✝¹ : CommMonoid N
P : Type ?u.915559
inst✝ : CommMonoid P
f : LocalizationMap S N
x₁ x₂ : M
y : { x // x ∈ S }
⊢ ↑(toMap f) x₁ * mk' f x₂ y = mk' f (x₁ * x₂) y
Theorem: SimpleGraph.nonuniformWitness_subset
File: Mathlib/Combinatorics/SimpleGraph/Regularity/Uniform.lean

tactic: unfold nonuniformWitness
state_before: α : Type u_1
𝕜 : Type u_2
inst✝¹ : LinearOrderedField 𝕜
G : SimpleGraph α
inst✝ : DecidableRel G.Adj
ε : 𝕜
s t : Finset α
a b : α
h : ¬IsUniform G ε s t
⊢ nonuniformWitness G ε s t ⊆ s

tactic: split_ifs
state_before: α : Type u_1
𝕜 : Type u_2
inst✝¹ : LinearOrderedField 𝕜
G : SimpleGraph α
inst✝ : DecidableRel G.Adj
ε : 𝕜
s t : Finset α
a b : α
h : ¬IsUniform G ε s t
⊢ (if WellOrderingRel s t then (nonuniformWitnesses G ε s t).fst else (nonuniformWitnesses G ε t s).snd) ⊆ s

tactic: exact G.left_nonuniformWitnesses_subset h
state_before: case inl
α : Type u_1
𝕜 : Type u_2
inst✝¹ : LinearOrderedField 𝕜
G : SimpleGraph α
inst✝ : DecidableRel G.Adj
ε : 𝕜
s t : Finset α
a b : α
h : ¬IsUniform G ε s t
h✝ : WellOrderingRel s t
⊢ (nonuniformWitnesses G ε s t).fst ⊆ s

tactic: exact G.right_nonuniformWitnesses_subset fun i => h i.symm
state_before: case inr
α : Type u_1
𝕜 : Type u_2
inst✝¹ : LinearOrderedField 𝕜
G : SimpleGraph α
inst✝ : DecidableRel G.Adj
ε : 𝕜
s t : Finset α
a b : α
h : ¬IsUniform G ε s t
h✝ : ¬WellOrderingRel s t
⊢ (nonuniformWitnesses G ε t s).snd ⊆ s
Theorem: IsLocalization.mk'_mul_mk'_eq_one
File: Mathlib/RingTheory/Localization/Basic.lean

tactic: rw [← mk'_mul, mul_comm]
state_before: R : Type u_1
inst✝⁴ : CommSemiring R
M : Submonoid R
S : Type u_2
inst✝³ : CommSemiring S
inst✝² : Algebra R S
P : Type ?u.817480
inst✝¹ : CommSemiring P
inst✝ : IsLocalization M S
x y : { x // x ∈ M }
⊢ mk' S (↑x) y * mk' S (↑y) x = 1

tactic: exact mk'_self _ _
state_before: R : Type u_1
inst✝⁴ : CommSemiring R
M : Submonoid R
S : Type u_2
inst✝³ : CommSemiring S
inst✝² : Algebra R S
P : Type ?u.817480
inst✝¹ : CommSemiring P
inst✝ : IsLocalization M S
x y : { x // x ∈ M }
⊢ mk' S (↑y * ↑x) (y * x) = 1
Theorem: Class.toSet_of_ZFSet
File: Mathlib/SetTheory/ZFC/Basic.lean

tactic: rwa [ofSet.inj yx] at py
state_before: A : Class
x : ZFSet
x✝ : ToSet A ↑x
y : ZFSet
yx : ↑y = ↑x
py : A y
⊢ A x
Theorem: dite_apply
File: Mathlib/Logic/Basic.lean

tactic: by_cases h:P <;> simp [h]
state_before: α : Sort u_2
β : Sort ?u.39434
σ : α → Sort u_1
f✝ : α → β
P Q : Prop
inst✝¹ : Decidable P
inst✝ : Decidable Q
a✝ b c : α
A : P → α
B : ¬P → α
f : P → (a : α) → σ a
g : ¬P → (a : α) → σ a
a : α
⊢ dite P f g a = if h : P then f h a else g h a
Theorem: one_lt_div_iff
File: Mathlib/Algebra/Order/Field/Basic.lean

tactic: rcases lt_trichotomy b 0 with (hb | rfl | hb)
state_before: ι : Type ?u.160788
α : Type u_1
β : Type ?u.160794
inst✝ : LinearOrderedField α
a b c d : α
n : ℤ
⊢ 1 < a / b ↔ 0 < b ∧ b < a ∨ b < 0 ∧ a < b

tactic: simp [hb, hb.not_lt, one_lt_div_of_neg]
state_before: case inl
ι : Type ?u.160788
α : Type u_1
β : Type ?u.160794
inst✝ : LinearOrderedField α
a b c d : α
n : ℤ
hb : b < 0
⊢ 1 < a / b ↔ 0 < b ∧ b < a ∨ b < 0 ∧ a < b

tactic: simp [lt_irrefl, zero_le_one]
state_before: case inr.inl
ι : Type ?u.160788
α : Type u_1
β : Type ?u.160794
inst✝ : LinearOrderedField α
a c d : α
n : ℤ
⊢ 1 < a / 0 ↔ 0 < 0 ∧ 0 < a ∨ 0 < 0 ∧ a < 0

tactic: simp [hb, hb.not_lt, one_lt_div]
state_before: case inr.inr
ι : Type ?u.160788
α : Type u_1
β : Type ?u.160794
inst✝ : LinearOrderedField α
a b c d : α
n : ℤ
hb : 0 < b
⊢ 1 < a / b ↔ 0 < b ∧ b < a ∨ b < 0 ∧ a < b
Theorem: HasDerivWithinAt.limsup_slope_norm_le
File: Mathlib/Analysis/Calculus/Deriv/Slope.lean

tactic: apply (hf.limsup_norm_slope_le hr).mono
state_before: E : Type u
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace ℝ E
f : ℝ → E
f' : E
s : Set ℝ
x r : ℝ
hf : HasDerivWithinAt f f' s x
hr : ‖f'‖ < r
⊢ ∀ᶠ (z : ℝ) in 𝓝[s] x, ‖z - x‖⁻¹ * (‖f z‖ - ‖f x‖) < r

tactic: intro z hz
state_before: E : Type u
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace ℝ E
f : ℝ → E
f' : E
s : Set ℝ
x r : ℝ
hf : HasDerivWithinAt f f' s x
hr : ‖f'‖ < r
⊢ ∀ (x_1 : ℝ), ‖x_1 - x‖⁻¹ * ‖f x_1 - f x‖ < r → ‖x_1 - x‖⁻¹ * (‖f x_1‖ - ‖f x‖) < r

tactic: refine' lt_of_le_of_lt (mul_le_mul_of_nonneg_left (norm_sub_norm_le _ _) _) hz
state_before: E : Type u
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace ℝ E
f : ℝ → E
f' : E
s : Set ℝ
x r : ℝ
hf : HasDerivWithinAt f f' s x
hr : ‖f'‖ < r
z : ℝ
hz : ‖z - x‖⁻¹ * ‖f z - f x‖ < r
⊢ ‖z - x‖⁻¹ * (‖f z‖ - ‖f x‖) < r

tactic: exact inv_nonneg.2 (norm_nonneg _)
state_before: E : Type u
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace ℝ E
f : ℝ → E
f' : E
s : Set ℝ
x r : ℝ
hf : HasDerivWithinAt f f' s x
hr : ‖f'‖ < r
z : ℝ
hz : ‖z - x‖⁻¹ * ‖f z - f x‖ < r
⊢ 0 ≤ ‖z - x‖⁻¹
Theorem: Real.pi_gt_3141592
File: Mathlib/Data/Real/Pi/Bounds.lean

tactic: pi_lower_bound
    [11482 / 8119, 7792 / 4217, 54055 / 27557, 949247 / 476920, 3310126 / 1657059,
      2635492 / 1318143, 1580265 / 790192, 1221775 / 610899, 3612247 / 1806132, 849943 / 424972]
state_before: ⊢ 3.141592 < π
Theorem: Quaternion.normSq_def'
File: Mathlib/Algebra/Quaternion.lean

tactic: simp only [normSq_def, sq, mul_neg, sub_neg_eq_add, mul_re, star_re, star_imI, star_imJ,
  star_imK]
state_before: S : Type ?u.539505
T : Type ?u.539508
R : Type u_1
inst✝ : CommRing R
r x y z : R
a b c : ℍ[R]
⊢ ↑normSq a = a.re ^ 2 + a.imI ^ 2 + a.imJ ^ 2 + a.imK ^ 2
Theorem: Set.preimage_const_mul_Ico
File: Mathlib/Data/Set/Pointwise/Interval.lean

tactic: simp [← Ici_inter_Iio, h]
state_before: α : Type u_1
inst✝ : LinearOrderedField α
a✝ a b c : α
h : 0 < c
⊢ (fun x x_1 => x * x_1) c ⁻¹' Ico a b = Ico (a / c) (b / c)
Theorem: Mathlib.Tactic.LinearCombination.eq_of_add
File: Mathlib/Tactic/LinearCombination.lean

tactic: rw [← sub_eq_zero] at p ⊢
state_before: α : Type u_1
a b a' b' : α
inst✝ : AddGroup α
p : a = b
H : a' - b' - (a - b) = 0
⊢ a' = b'

tactic: rwa [sub_eq_zero, p] at H
state_before: α : Type u_1
a b a' b' : α
inst✝ : AddGroup α
p✝ : a = b
p : a - b = 0
H : a' - b' - (a - b) = 0
⊢ a' - b' = 0
Theorem: Real.deriv_arcsin
File: Mathlib/Analysis/SpecialFunctions/Trigonometric/InverseDeriv.lean

tactic: funext x
state_before: ⊢ deriv arcsin = fun x => 1 / sqrt (1 - x ^ 2)

tactic: by_cases h : x ≠ -1 ∧ x ≠ 1
state_before: case h
x : ℝ
⊢ deriv arcsin x = 1 / sqrt (1 - x ^ 2)

tactic: exact (hasDerivAt_arcsin h.1 h.2).deriv
state_before: case pos
x : ℝ
h : x ≠ -1 ∧ x ≠ 1
⊢ deriv arcsin x = 1 / sqrt (1 - x ^ 2)

tactic: rw [deriv_zero_of_not_differentiableAt (mt differentiableAt_arcsin.1 h)]
state_before: case neg
x : ℝ
h : ¬(x ≠ -1 ∧ x ≠ 1)
⊢ deriv arcsin x = 1 / sqrt (1 - x ^ 2)

tactic: simp only [not_and_or, Ne.def, Classical.not_not] at h
state_before: case neg
x : ℝ
h : ¬(x ≠ -1 ∧ x ≠ 1)
⊢ 0 = 1 / sqrt (1 - x ^ 2)

tactic: rcases h with (rfl | rfl) <;> simp
state_before: case neg
x : ℝ
h : x = -1 ∨ x = 1
⊢ 0 = 1 / sqrt (1 - x ^ 2)
Theorem: Set.toFinset_range
File: Mathlib/Data/Fintype/Basic.lean

tactic: ext
state_before: α : Type u_1
β : Type u_2
γ : Type ?u.95007
s t : Set α
inst✝² : DecidableEq α
inst✝¹ : Fintype β
f : β → α
inst✝ : Fintype ↑(range f)
⊢ toFinset (range f) = Finset.image f Finset.univ

tactic: simp
state_before: case a
α : Type u_1
β : Type u_2
γ : Type ?u.95007
s t : Set α
inst✝² : DecidableEq α
inst✝¹ : Fintype β
f : β → α
inst✝ : Fintype ↑(range f)
a✝ : α
⊢ a✝ ∈ toFinset (range f) ↔ a✝ ∈ Finset.image f Finset.univ
Theorem: Associates.eq_of_factors_eq_factors
File: Mathlib/RingTheory/UniqueFactorizationDomain.lean

tactic: have : a.factors.prod = b.factors.prod := by rw [h]
state_before: α : Type u_1
inst✝¹ : CancelCommMonoidWithZero α
dec_irr : (p : Associates α) → Decidable (Irreducible p)
inst✝ : UniqueFactorizationMonoid α
dec : DecidableEq α
dec' : DecidableEq (Associates α)
a b : Associates α
h : factors a = factors b
⊢ a = b

tactic: rwa [factors_prod, factors_prod] at this
state_before: α : Type u_1
inst✝¹ : CancelCommMonoidWithZero α
dec_irr : (p : Associates α) → Decidable (Irreducible p)
inst✝ : UniqueFactorizationMonoid α
dec : DecidableEq α
dec' : DecidableEq (Associates α)
a b : Associates α
h : factors a = factors b
this : FactorSet.prod (factors a) = FactorSet.prod (factors b)
⊢ a = b

tactic: rw [h]
state_before: α : Type u_1
inst✝¹ : CancelCommMonoidWithZero α
dec_irr : (p : Associates α) → Decidable (Irreducible p)
inst✝ : UniqueFactorizationMonoid α
dec : DecidableEq α
dec' : DecidableEq (Associates α)
a b : Associates α
h : factors a = factors b
⊢ FactorSet.prod (factors a) = FactorSet.prod (factors b)
Theorem: mul_self_pos
File: Mathlib/Algebra/Order/Ring/Defs.lean

tactic: constructor
state_before: α : Type u
β : Type ?u.211359
inst✝ : LinearOrderedRing α
a✝ b c a : α
⊢ 0 < a * a ↔ a ≠ 0

tactic: rintro h rfl
state_before: case mp
α : Type u
β : Type ?u.211359
inst✝ : LinearOrderedRing α
a✝ b c a : α
⊢ 0 < a * a → a ≠ 0

tactic: rw [mul_zero] at h
state_before: case mp
α : Type u
β : Type ?u.211359
inst✝ : LinearOrderedRing α
a b c : α
h : 0 < 0 * 0
⊢ False

tactic: exact h.false
state_before: case mp
α : Type u
β : Type ?u.211359
inst✝ : LinearOrderedRing α
a b c : α
h : 0 < 0
⊢ False

tactic: intro h
state_before: case mpr
α : Type u
β : Type ?u.211359
inst✝ : LinearOrderedRing α
a✝ b c a : α
⊢ a ≠ 0 → 0 < a * a

tactic: cases' h.lt_or_lt with h h
state_before: case mpr
α : Type u
β : Type ?u.211359
inst✝ : LinearOrderedRing α
a✝ b c a : α
h : a ≠ 0
⊢ 0 < a * a

tactic: exacts [mul_pos_of_neg_of_neg h h, mul_pos h h]
state_before: case mpr.inl
α : Type u
β : Type ?u.211359
inst✝ : LinearOrderedRing α
a✝ b c a : α
h✝ : a ≠ 0
h : a < 0
⊢ 0 < a * a

case mpr.inr
α : Type u
β : Type ?u.211359
inst✝ : LinearOrderedRing α
a✝ b c a : α
h✝ : a ≠ 0
h : 0 < a
⊢ 0 < a * a
Theorem: FormalMultilinearSeries.removeZero_of_pos
File: Mathlib/Analysis/Calculus/FormalMultilinearSeries.lean

tactic: rw [← Nat.succ_pred_eq_of_pos h]
state_before: 𝕜 : Type u
𝕜' : Type u'
E : Type v
F : Type w
G : Type x
inst✝¹⁵ : CommRing 𝕜
inst✝¹⁴ : AddCommGroup E
inst✝¹³ : Module 𝕜 E
inst✝¹² : TopologicalSpace E
inst✝¹¹ : TopologicalAddGroup E
inst✝¹⁰ : ContinuousConstSMul 𝕜 E
inst✝⁹ : AddCommGroup F
inst✝⁸ : Module 𝕜 F
inst✝⁷ : TopologicalSpace F
inst✝⁶ : TopologicalAddGroup F
inst✝⁵ : ContinuousConstSMul 𝕜 F
inst✝⁴ : AddCommGroup G
inst✝³ : Module 𝕜 G
inst✝² : TopologicalSpace G
inst✝¹ : TopologicalAddGroup G
inst✝ : ContinuousConstSMul 𝕜 G
p : FormalMultilinearSeries 𝕜 E F
n : ℕ
h : 0 < n
⊢ removeZero p n = p n

tactic: rfl
state_before: 𝕜 : Type u
𝕜' : Type u'
E : Type v
F : Type w
G : Type x
inst✝¹⁵ : CommRing 𝕜
inst✝¹⁴ : AddCommGroup E
inst✝¹³ : Module 𝕜 E
inst✝¹² : TopologicalSpace E
inst✝¹¹ : TopologicalAddGroup E
inst✝¹⁰ : ContinuousConstSMul 𝕜 E
inst✝⁹ : AddCommGroup F
inst✝⁸ : Module 𝕜 F
inst✝⁷ : TopologicalSpace F
inst✝⁶ : TopologicalAddGroup F
inst✝⁵ : ContinuousConstSMul 𝕜 F
inst✝⁴ : AddCommGroup G
inst✝³ : Module 𝕜 G
inst✝² : TopologicalSpace G
inst✝¹ : TopologicalAddGroup G
inst✝ : ContinuousConstSMul 𝕜 G
p : FormalMultilinearSeries 𝕜 E F
n : ℕ
h : 0 < n
⊢ removeZero p (Nat.succ (Nat.pred n)) = p (Nat.succ (Nat.pred n))
Theorem: Nat.properDivisors.not_self_mem
File: Mathlib/NumberTheory/Divisors.lean

tactic: simp [properDivisors]
state_before: n : ℕ
⊢ ¬n ∈ properDivisors n
Theorem: List.permutations'Aux_eq_permutationsAux2
File: Mathlib/Data/List/Permutation.lean

tactic: induction' ts with a ts ih
state_before: α : Type u_1
β : Type ?u.7760
t : α
ts : List α
⊢ permutations'Aux t ts = (permutationsAux2 t [] [ts ++ [t]] ts id).snd

tactic: simp [permutations'Aux, permutationsAux2_snd_cons, ih]
state_before: case cons
α : Type u_1
β : Type ?u.7760
t a : α
ts : List α
ih : permutations'Aux t ts = (permutationsAux2 t [] [ts ++ [t]] ts id).snd
⊢ permutations'Aux t (a :: ts) = (permutationsAux2 t [] [a :: ts ++ [t]] (a :: ts) id).snd

tactic: simp (config := { singlePass := true }) only [← permutationsAux2_append]
state_before: case cons
α : Type u_1
β : Type ?u.7760
t a : α
ts : List α
ih : permutations'Aux t ts = (permutationsAux2 t [] [ts ++ [t]] ts id).snd
⊢ map (cons a) (permutationsAux2 t [] [ts ++ [t]] ts id).snd =
    (permutationsAux2 t [] [a :: (ts ++ [t])] ts fun x => a :: x).snd

tactic: simp [map_permutationsAux2]
state_before: case cons
α : Type u_1
β : Type ?u.7760
t a : α
ts : List α
ih : permutations'Aux t ts = (permutationsAux2 t [] [ts ++ [t]] ts id).snd
⊢ map (cons a) ((permutationsAux2 t [] [] ts id).snd ++ [ts ++ [t]]) =
    (permutationsAux2 t [] [] ts fun x => a :: x).snd ++ [a :: (ts ++ [t])]

tactic: rfl
state_before: case nil
α : Type u_1
β : Type ?u.7760
t : α
⊢ permutations'Aux t [] = (permutationsAux2 t [] [[] ++ [t]] [] id).snd
Theorem: Set.infsep_pos_iff_nontrivial_of_finite
File: Mathlib/Topology/MetricSpace/Infsep.lean

tactic: rw [infsep_pos, einfsep_lt_top_iff, and_iff_right_iff_imp]
state_before: α : Type u_1
β : Type ?u.81734
inst✝¹ : MetricSpace α
s : Set α
inst✝ : Finite ↑s
⊢ 0 < infsep s ↔ Set.Nontrivial s

tactic: exact fun _ => einfsep_pos_of_finite
state_before: α : Type u_1
β : Type ?u.81734
inst✝¹ : MetricSpace α
s : Set α
inst✝ : Finite ↑s
⊢ Set.Nontrivial s → 0 < einfsep s
Theorem: nhds_bot_order
File: Mathlib/Topology/Order/Basic.lean

tactic: simp [nhds_eq_order (⊥ : α)]
state_before: α : Type u
β : Type v
γ : Type w
inst✝³ : TopologicalSpace α
inst✝² : Preorder α
inst✝¹ : OrderBot α
inst✝ : OrderTopology α
⊢ 𝓝 ⊥ = ⨅ (l : α) (_ : ⊥ < l), 𝓟 (Iio l)
Theorem: Substring.ValidFor.toIterator
File: Std/Data/String/Lemmas.lean

tactic: simp [Substring.toIterator]
state_before: l m r : List Char
x✝ : Substring
h : ValidFor l m r x✝
⊢ Iterator.ValidFor (List.reverse l) (m ++ r) (Substring.toIterator x✝)

tactic: exact .of_eq _ (by simp [h.str, List.reverseAux_eq]) (by simp [h.startPos])
state_before: l m r : List Char
x✝ : Substring
h : ValidFor l m r x✝
⊢ Iterator.ValidFor (List.reverse l) (m ++ r) { s := x✝.str, i := x✝.startPos }

tactic: simp [h.str, List.reverseAux_eq]
state_before: l m r : List Char
x✝ : Substring
h : ValidFor l m r x✝
⊢ { s := x✝.str, i := x✝.startPos }.s.data = List.reverseAux (List.reverse l) (m ++ r)

tactic: simp [h.startPos]
state_before: l m r : List Char
x✝ : Substring
h : ValidFor l m r x✝
⊢ { s := x✝.str, i := x✝.startPos }.i.byteIdx = utf8Len (List.reverse l)
Theorem: inv_div_inv
File: Mathlib/Algebra/Group/Basic.lean

tactic: simp
state_before: α : Type u_1
β : Type ?u.32640
G : Type ?u.32643
inst✝ : DivisionCommMonoid α
a b c d : α
⊢ a⁻¹ / b⁻¹ = b / a
Theorem: circleIntegral.integral_congr
File: Mathlib/MeasureTheory/Integral/CircleIntegral.lean

tactic: simp only [h (circleMap_mem_sphere _ hR _)]
state_before: E : Type u_1
inst✝² : NormedAddCommGroup E
inst✝¹ : NormedSpace ℂ E
inst✝ : CompleteSpace E
f g : ℂ → E
c : ℂ
R : ℝ
hR : 0 ≤ R
h : EqOn f g (sphere c R)
θ : ℝ
x✝ : θ ∈ [[0, 2 * π]]
⊢ deriv (circleMap c R) θ • (fun z => f z) (circleMap c R θ) =
    deriv (circleMap c R) θ • (fun z => g z) (circleMap c R θ)
Theorem: DenseInducing.interior_compact_eq_empty
File: Mathlib/Topology/DenseEmbedding.lean

tactic: refine' eq_empty_iff_forall_not_mem.2 fun x hx => _
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.2548
δ : Type ?u.2551
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
i : α → β
di✝ : DenseInducing i
inst✝ : T2Space β
di : DenseInducing i
hd : Dense (range iᶜ)
s : Set α
hs : IsCompact s
⊢ interior s = ∅

tactic: rw [mem_interior_iff_mem_nhds] at hx
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.2548
δ : Type ?u.2551
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
i : α → β
di✝ : DenseInducing i
inst✝ : T2Space β
di : DenseInducing i
hd : Dense (range iᶜ)
s : Set α
hs : IsCompact s
x : α
hx : x ∈ interior s
⊢ False

tactic: have := di.closure_image_mem_nhds hx
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.2548
δ : Type ?u.2551
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
i : α → β
di✝ : DenseInducing i
inst✝ : T2Space β
di : DenseInducing i
hd : Dense (range iᶜ)
s : Set α
hs : IsCompact s
x : α
hx : s ∈ 𝓝 x
⊢ False

tactic: rw [(hs.image di.continuous).isClosed.closure_eq] at this
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.2548
δ : Type ?u.2551
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
i : α → β
di✝ : DenseInducing i
inst✝ : T2Space β
di : DenseInducing i
hd : Dense (range iᶜ)
s : Set α
hs : IsCompact s
x : α
hx : s ∈ 𝓝 x
this : closure (i '' s) ∈ 𝓝 (i x)
⊢ False

tactic: rcases hd.inter_nhds_nonempty this with ⟨y, hyi, hys⟩
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.2548
δ : Type ?u.2551
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
i : α → β
di✝ : DenseInducing i
inst✝ : T2Space β
di : DenseInducing i
hd : Dense (range iᶜ)
s : Set α
hs : IsCompact s
x : α
hx : s ∈ 𝓝 x
this : i '' s ∈ 𝓝 (i x)
⊢ False

tactic: exact hyi (image_subset_range _ _ hys)
state_before: case intro.intro
α : Type u_2
β : Type u_1
γ : Type ?u.2548
δ : Type ?u.2551
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
i : α → β
di✝ : DenseInducing i
inst✝ : T2Space β
di : DenseInducing i
hd : Dense (range iᶜ)
s : Set α
hs : IsCompact s
x : α
hx : s ∈ 𝓝 x
this : i '' s ∈ 𝓝 (i x)
y : β
hyi : y ∈ range iᶜ
hys : y ∈ i '' s
⊢ False
Theorem: Filter.HasBasis.uniformity_of_nhds_one_swapped
File: Mathlib/Topology/Algebra/UniformGroup.lean

tactic: rw [uniformity_eq_comap_nhds_one_swapped]
state_before: α : Type u_2
β : Type ?u.175746
inst✝² : UniformSpace α
inst✝¹ : Group α
inst✝ : UniformGroup α
ι : Sort u_1
p : ι → Prop
U : ι → Set α
h : HasBasis (𝓝 1) p U
⊢ HasBasis (𝓤 α) p fun i => {x | x.fst / x.snd ∈ U i}

tactic: exact h.comap _
state_before: α : Type u_2
β : Type ?u.175746
inst✝² : UniformSpace α
inst✝¹ : Group α
inst✝ : UniformGroup α
ι : Sort u_1
p : ι → Prop
U : ι → Set α
h : HasBasis (𝓝 1) p U
⊢ HasBasis (Filter.comap (fun x => x.fst / x.snd) (𝓝 1)) p fun i => {x | x.fst / x.snd ∈ U i}
Theorem: Set.Ico_union_right
File: Mathlib/Data/Set/Intervals/Basic.lean

tactic: simpa only [dual_Ioc, dual_Icc] using Ioc_union_left hab.dual
state_before: α : Type u_1
β : Type ?u.47570
inst✝ : PartialOrder α
a b c : α
hab : a ≤ b
⊢ Ico a b ∪ {b} = Icc a b
Theorem: ProbabilityTheory.iIndep.indep
File: Mathlib/Probability/Independence/Basic.lean

tactic: change IndepSets ((fun x => MeasurableSet[m x]) i) ((fun x => MeasurableSet[m x]) j) μ
state_before: Ω : Type u_1
ι : Type u_2
m : ι → MeasurableSpace Ω
inst✝ : MeasurableSpace Ω
μ : MeasureTheory.Measure Ω
h_indep : iIndep m
i j : ι
hij : i ≠ j
⊢ Indep (m i) (m j)

tactic: exact iIndepSets.indepSets h_indep hij
state_before: Ω : Type u_1
ι : Type u_2
m : ι → MeasurableSpace Ω
inst✝ : MeasurableSpace Ω
μ : MeasureTheory.Measure Ω
h_indep : iIndep m
i j : ι
hij : i ≠ j
⊢ IndepSets ((fun x => MeasurableSet) i) ((fun x => MeasurableSet) j)
Theorem: SimpleGraph.sInf_adj_of_nonempty
File: Mathlib/Combinatorics/SimpleGraph/Basic.lean

tactic: obtain ⟨G, hG⟩ := hs
state_before: ι : Sort ?u.22992
𝕜 : Type ?u.22995
V : Type u
W : Type v
X : Type w
G : SimpleGraph V
G' : SimpleGraph W
a b c u v w : V
e : Sym2 V
s : Set (SimpleGraph V)
hs : Set.Nonempty s
⊢ (∀ (G : SimpleGraph V), G ∈ s → Adj G a b) → a ≠ b

tactic: exact fun h => (h _ hG).ne
state_before: case intro
ι : Sort ?u.22992
𝕜 : Type ?u.22995
V : Type u
W : Type v
X : Type w
G✝ : SimpleGraph V
G' : SimpleGraph W
a b c u v w : V
e : Sym2 V
s : Set (SimpleGraph V)
G : SimpleGraph V
hG : G ∈ s
⊢ (∀ (G : SimpleGraph V), G ∈ s → Adj G a b) → a ≠ b
Theorem: prevD_nat
File: Mathlib/Algebra/Homology/Homotopy.lean

tactic: dsimp [prevD]
state_before: ι : Type ?u.115833
V : Type u
inst✝¹ : Category V
inst✝ : Preadditive V
c : ComplexShape ι
C✝ D✝ E : HomologicalComplex V c
f✝ g : C✝ ⟶ D✝
h k : D✝ ⟶ E
i✝ : ι
C D : CochainComplex V ℕ
i : ℕ
f : (i j : ℕ) → X C i ⟶ X D j
⊢ ↑(prevD i) f = f i (i - 1) ≫ d D (i - 1) i

tactic: cases i
state_before: ι : Type ?u.115833
V : Type u
inst✝¹ : Category V
inst✝ : Preadditive V
c : ComplexShape ι
C✝ D✝ E : HomologicalComplex V c
f✝ g : C✝ ⟶ D✝
h k : D✝ ⟶ E
i✝ : ι
C D : CochainComplex V ℕ
i : ℕ
f : (i j : ℕ) → X C i ⟶ X D j
⊢ f i (ComplexShape.prev (ComplexShape.up ℕ) i) ≫ d D (ComplexShape.prev (ComplexShape.up ℕ) i) i =
    f i (i - 1) ≫ d D (i - 1) i

tactic: . congr <;> simp
state_before: case succ
ι : Type ?u.115833
V : Type u
inst✝¹ : Category V
inst✝ : Preadditive V
c : ComplexShape ι
C✝ D✝ E : HomologicalComplex V c
f✝ g : C✝ ⟶ D✝
h k : D✝ ⟶ E
i : ι
C D : CochainComplex V ℕ
f : (i j : ℕ) → X C i ⟶ X D j
n✝ : ℕ
⊢ f (Nat.succ n✝) (ComplexShape.prev (ComplexShape.up ℕ) (Nat.succ n✝)) ≫
      d D (ComplexShape.prev (ComplexShape.up ℕ) (Nat.succ n✝)) (Nat.succ n✝) =
    f (Nat.succ n✝) (Nat.succ n✝ - 1) ≫ d D (Nat.succ n✝ - 1) (Nat.succ n✝)

tactic: simp only [shape, CochainComplex.prev_nat_zero, ComplexShape.up_Rel, Nat.one_ne_zero,
  not_false_iff, comp_zero]
state_before: case zero
ι : Type ?u.115833
V : Type u
inst✝¹ : Category V
inst✝ : Preadditive V
c : ComplexShape ι
C✝ D✝ E : HomologicalComplex V c
f✝ g : C✝ ⟶ D✝
h k : D✝ ⟶ E
i : ι
C D : CochainComplex V ℕ
f : (i j : ℕ) → X C i ⟶ X D j
⊢ f Nat.zero (ComplexShape.prev (ComplexShape.up ℕ) Nat.zero) ≫
      d D (ComplexShape.prev (ComplexShape.up ℕ) Nat.zero) Nat.zero =
    f Nat.zero (Nat.zero - 1) ≫ d D (Nat.zero - 1) Nat.zero

tactic: congr <;> simp
state_before: case succ
ι : Type ?u.115833
V : Type u
inst✝¹ : Category V
inst✝ : Preadditive V
c : ComplexShape ι
C✝ D✝ E : HomologicalComplex V c
f✝ g : C✝ ⟶ D✝
h k : D✝ ⟶ E
i : ι
C D : CochainComplex V ℕ
f : (i j : ℕ) → X C i ⟶ X D j
n✝ : ℕ
⊢ f (Nat.succ n✝) (ComplexShape.prev (ComplexShape.up ℕ) (Nat.succ n✝)) ≫
      d D (ComplexShape.prev (ComplexShape.up ℕ) (Nat.succ n✝)) (Nat.succ n✝) =
    f (Nat.succ n✝) (Nat.succ n✝ - 1) ≫ d D (Nat.succ n✝ - 1) (Nat.succ n✝)