tasksource/leandojo huggingface dataset:
Theorem: TopologicalSpace.nhds_mkOfNhds_filterBasis
File: Mathlib/Topology/Order.lean

tactic: rw [TopologicalSpace.nhds_mkOfNhds] <;> intro x n hn <;>
  obtain ⟨m, hm₁, hm₂⟩ := (B x).mem_filter_iff.mp hn
state_before: α : Type u
B : α → FilterBasis α
a : α
h₀ : ∀ (x : α) (n : Set α), n ∈ B x → x ∈ n
h₁ : ∀ (x : α) (n : Set α), n ∈ B x → ∃ n₁, n₁ ∈ B x ∧ n₁ ⊆ n ∧ ∀ (x' : α), x' ∈ n₁ → ∃ n₂, n₂ ∈ B x' ∧ n₂ ⊆ n
⊢ 𝓝 a = FilterBasis.filter (B a)

tactic: exact hm₂ (h₀ _ _ hm₁)
state_before: case h₀.intro.intro
α : Type u
B : α → FilterBasis α
a : α
h₀ : ∀ (x : α) (n : Set α), n ∈ B x → x ∈ n
h₁ : ∀ (x : α) (n : Set α), n ∈ B x → ∃ n₁, n₁ ∈ B x ∧ n₁ ⊆ n ∧ ∀ (x' : α), x' ∈ n₁ → ∃ n₂, n₂ ∈ B x' ∧ n₂ ⊆ n
x : α
n : Set α
hn : n ∈ (fun x => FilterBasis.filter (B x)) x
m : Set α
hm₁ : m ∈ B x
hm₂ : m ⊆ n
⊢ n ∈ pure x

tactic: obtain ⟨n₁, hn₁, hn₂, hn₃⟩ := h₁ x m hm₁
state_before: case h₁.intro.intro
α : Type u
B : α → FilterBasis α
a : α
h₀ : ∀ (x : α) (n : Set α), n ∈ B x → x ∈ n
h₁ : ∀ (x : α) (n : Set α), n ∈ B x → ∃ n₁, n₁ ∈ B x ∧ n₁ ⊆ n ∧ ∀ (x' : α), x' ∈ n₁ → ∃ n₂, n₂ ∈ B x' ∧ n₂ ⊆ n
x : α
n : Set α
hn : n ∈ FilterBasis.filter (B x)
m : Set α
hm₁ : m ∈ B x
hm₂ : m ⊆ n
⊢ ∃ t, t ∈ FilterBasis.filter (B x) ∧ t ⊆ n ∧ ∀ (a' : α), a' ∈ t → n ∈ FilterBasis.filter (B a')

tactic: refine'
  ⟨n₁, (B x).mem_filter_of_mem hn₁, hn₂.trans hm₂, fun x' hx' => (B x').mem_filter_iff.mp _⟩
state_before: case h₁.intro.intro.intro.intro.intro
α : Type u
B : α → FilterBasis α
a : α
h₀ : ∀ (x : α) (n : Set α), n ∈ B x → x ∈ n
h₁ : ∀ (x : α) (n : Set α), n ∈ B x → ∃ n₁, n₁ ∈ B x ∧ n₁ ⊆ n ∧ ∀ (x' : α), x' ∈ n₁ → ∃ n₂, n₂ ∈ B x' ∧ n₂ ⊆ n
x : α
n : Set α
hn : n ∈ FilterBasis.filter (B x)
m : Set α
hm₁ : m ∈ B x
hm₂ : m ⊆ n
n₁ : Set α
hn₁ : n₁ ∈ B x
hn₂ : n₁ ⊆ m
hn₃ : ∀ (x' : α), x' ∈ n₁ → ∃ n₂, n₂ ∈ B x' ∧ n₂ ⊆ m
⊢ ∃ t, t ∈ FilterBasis.filter (B x) ∧ t ⊆ n ∧ ∀ (a' : α), a' ∈ t → n ∈ FilterBasis.filter (B a')

tactic: obtain ⟨n₂, hn₄, hn₅⟩ := hn₃ x' hx'
state_before: case h₁.intro.intro.intro.intro.intro
α : Type u
B : α → FilterBasis α
a : α
h₀ : ∀ (x : α) (n : Set α), n ∈ B x → x ∈ n
h₁ : ∀ (x : α) (n : Set α), n ∈ B x → ∃ n₁, n₁ ∈ B x ∧ n₁ ⊆ n ∧ ∀ (x' : α), x' ∈ n₁ → ∃ n₂, n₂ ∈ B x' ∧ n₂ ⊆ n
x : α
n : Set α
hn : n ∈ FilterBasis.filter (B x)
m : Set α
hm₁ : m ∈ B x
hm₂ : m ⊆ n
n₁ : Set α
hn₁ : n₁ ∈ B x
hn₂ : n₁ ⊆ m
hn₃ : ∀ (x' : α), x' ∈ n₁ → ∃ n₂, n₂ ∈ B x' ∧ n₂ ⊆ m
x' : α
hx' : x' ∈ n₁
⊢ n ∈ FilterBasis.filter (B x')

tactic: exact ⟨n₂, hn₄, hn₅.trans hm₂⟩
state_before: case h₁.intro.intro.intro.intro.intro.intro.intro
α : Type u
B : α → FilterBasis α
a : α
h₀ : ∀ (x : α) (n : Set α), n ∈ B x → x ∈ n
h₁ : ∀ (x : α) (n : Set α), n ∈ B x → ∃ n₁, n₁ ∈ B x ∧ n₁ ⊆ n ∧ ∀ (x' : α), x' ∈ n₁ → ∃ n₂, n₂ ∈ B x' ∧ n₂ ⊆ n
x : α
n : Set α
hn : n ∈ FilterBasis.filter (B x)
m : Set α
hm₁ : m ∈ B x
hm₂ : m ⊆ n
n₁ : Set α
hn₁ : n₁ ∈ B x
hn₂ : n₁ ⊆ m
hn₃ : ∀ (x' : α), x' ∈ n₁ → ∃ n₂, n₂ ∈ B x' ∧ n₂ ⊆ m
x' : α
hx' : x' ∈ n₁
n₂ : Set α
hn₄ : n₂ ∈ B x'
hn₅ : n₂ ⊆ m
⊢ n ∈ FilterBasis.filter (B x')
Theorem: CategoryTheory.homOfElement_eq_iff
File: Mathlib/CategoryTheory/Types.lean

tactic: aesop
state_before: X : Type u
x y : X
⊢ x = y → homOfElement x = homOfElement y
Theorem: WithTop.map_add
File: Mathlib/Algebra/Order/Monoid/WithTop.lean

tactic: induction a using WithTop.recTopCoe
state_before: α : Type u
β : Type v
inst✝² : Add α
a✝ b✝ c d : WithTop α
x y : α
F : Type u_1
inst✝¹ : Add β
inst✝ : AddHomClass F α β
f : F
a b : WithTop α
⊢ map (↑f) (a + b) = map (↑f) a + map (↑f) b

tactic: exact (top_add _).symm
state_before: case top
α : Type u
β : Type v
inst✝² : Add α
a b✝ c d : WithTop α
x y : α
F : Type u_1
inst✝¹ : Add β
inst✝ : AddHomClass F α β
f : F
b : WithTop α
⊢ map (↑f) (⊤ + b) = map ↑f ⊤ + map (↑f) b

tactic: induction b using WithTop.recTopCoe
state_before: case coe
α : Type u
β : Type v
inst✝² : Add α
a b✝ c d : WithTop α
x y : α
F : Type u_1
inst✝¹ : Add β
inst✝ : AddHomClass F α β
f : F
b : WithTop α
a✝ : α
⊢ map (↑f) (↑a✝ + b) = map ↑f ↑a✝ + map (↑f) b

tactic: exact (add_top _).symm
state_before: case coe.top
α : Type u
β : Type v
inst✝² : Add α
a b c d : WithTop α
x y : α
F : Type u_1
inst✝¹ : Add β
inst✝ : AddHomClass F α β
f : F
a✝ : α
⊢ map (↑f) (↑a✝ + ⊤) = map ↑f ↑a✝ + map ↑f ⊤

tactic: rw [map_coe, map_coe, ← coe_add, ← coe_add, ← map_add]
state_before: case coe.coe
α : Type u
β : Type v
inst✝² : Add α
a b c d : WithTop α
x y : α
F : Type u_1
inst✝¹ : Add β
inst✝ : AddHomClass F α β
f : F
a✝¹ a✝ : α
⊢ map (↑f) (↑a✝¹ + ↑a✝) = map ↑f ↑a✝¹ + map ↑f ↑a✝

tactic: rfl
state_before: case coe.coe
α : Type u
β : Type v
inst✝² : Add α
a b c d : WithTop α
x y : α
F : Type u_1
inst✝¹ : Add β
inst✝ : AddHomClass F α β
f : F
a✝¹ a✝ : α
⊢ map ↑f ↑(a✝¹ + a✝) = ↑(↑f (a✝¹ + a✝))
Theorem: CharP.neg_one_pow_char
File: Mathlib/Algebra/CharP/Basic.lean

tactic: rw [eq_neg_iff_add_eq_zero]
state_before: R : Type u_1
inst✝² : CommRing R
p : ℕ
inst✝¹ : CharP R p
inst✝ : Fact (Nat.Prime p)
⊢ (-1) ^ p = -1

tactic: nth_rw 2 [← one_pow p]
state_before: R : Type u_1
inst✝² : CommRing R
p : ℕ
inst✝¹ : CharP R p
inst✝ : Fact (Nat.Prime p)
⊢ (-1) ^ p + 1 = 0

tactic: rw [← add_pow_char, add_left_neg, zero_pow (Fact.out (p := Nat.Prime p)).pos]
state_before: R : Type u_1
inst✝² : CommRing R
p : ℕ
inst✝¹ : CharP R p
inst✝ : Fact (Nat.Prime p)
⊢ (-1) ^ p + 1 ^ p = 0
Theorem: padicValInt.mul
File: Mathlib/NumberTheory/Padics/PadicVal.lean

tactic: simp_rw [padicValInt]
state_before: p : ℕ
hp : Fact (Nat.Prime p)
a b : ℤ
ha : a ≠ 0
hb : b ≠ 0
⊢ padicValInt p (a * b) = padicValInt p a + padicValInt p b

tactic: rw [Int.natAbs_mul, padicValNat.mul] <;> rwa [Int.natAbs_ne_zero]
state_before: p : ℕ
hp : Fact (Nat.Prime p)
a b : ℤ
ha : a ≠ 0
hb : b ≠ 0
⊢ padicValNat p (Int.natAbs (a * b)) = padicValNat p (Int.natAbs a) + padicValNat p (Int.natAbs b)
Theorem: CompositionSeries.append_castAdd_aux
File: Mathlib/Order/JordanHolder.lean

tactic: cases i
state_before: X : Type u
inst✝¹ : Lattice X
inst✝ : JordanHolderLattice X
α : Type u_1
m n : ℕ
a : Fin (Nat.succ m) → α
b : Fin (Nat.succ n) → α
i : Fin m
⊢ Matrix.vecAppend (_ : Nat.succ (m + n) = m + Nat.succ n) (a ∘ ↑Fin.castSucc) b (↑Fin.castSucc (↑(Fin.castAdd n) i)) =
    a (↑Fin.castSucc i)

tactic: simp [Matrix.vecAppend_eq_ite, *]
state_before: case mk
X : Type u
inst✝¹ : Lattice X
inst✝ : JordanHolderLattice X
α : Type u_1
m n : ℕ
a : Fin (Nat.succ m) → α
b : Fin (Nat.succ n) → α
val✝ : ℕ
isLt✝ : val✝ < m
⊢ Matrix.vecAppend (_ : Nat.succ (m + n) = m + Nat.succ n) (a ∘ ↑Fin.castSucc) b
      (↑Fin.castSucc (↑(Fin.castAdd n) { val := val✝, isLt := isLt✝ })) =
    a (↑Fin.castSucc { val := val✝, isLt := isLt✝ })
Theorem: Polynomial.eval₂_smul
File: Mathlib/Data/Polynomial/Eval.lean

tactic: have A : p.natDegree < p.natDegree.succ := Nat.lt_succ_self _
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 : R →+* S
x✝ : S
g : R →+* S
p : R[X]
x : S
s : R
⊢ eval₂ g x (s • p) = ↑g s * eval₂ g x p

tactic: have B : (s • p).natDegree < p.natDegree.succ := (natDegree_smul_le _ _).trans_lt A
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 : R →+* S
x✝ : S
g : R →+* S
p : R[X]
x : S
s : R
A : natDegree p < Nat.succ (natDegree p)
⊢ eval₂ g x (s • p) = ↑g s * eval₂ g x p

tactic: rw [eval₂_eq_sum, eval₂_eq_sum, sum_over_range' _ _ _ A, sum_over_range' _ _ _ B] <;>
  simp [mul_sum, mul_assoc]
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 : R →+* S
x✝ : S
g : R →+* S
p : R[X]
x : S
s : R
A : natDegree p < Nat.succ (natDegree p)
B : natDegree (s • p) < Nat.succ (natDegree p)
⊢ eval₂ g x (s • p) = ↑g s * eval₂ g x p
Theorem: Filter.hasBasis_iInf_principal
File: Mathlib/Order/Filter/Bases.lean

tactic: simpa only [true_and] using mem_iInf_of_directed (h.mono_comp monotone_principal.dual) t
state_before: α : Type u_1
β : Type ?u.62085
γ : Type ?u.62088
ι : Sort u_2
ι' : Sort ?u.62094
l l' : Filter α
p : ι → Prop
s✝ : ι → Set α
t✝ : Set α
i : ι
p' : ι' → Prop
s' : ι' → Set α
i' : ι'
s : ι → Set α
h : Directed (fun x x_1 => x ≥ x_1) s
inst✝ : Nonempty ι
t : Set α
⊢ (t ∈ ⨅ (i : ι), 𝓟 (s i)) ↔ ∃ i, True ∧ s i ⊆ t
Theorem: iteratedFDeriv_succ_apply_right
File: Mathlib/Analysis/Calculus/ContDiffDef.lean

tactic: rw [← iteratedFDerivWithin_univ, ← iteratedFDerivWithin_univ, ← fderivWithin_univ]
state_before: 𝕜 : Type u
inst✝⁸ : NontriviallyNormedField 𝕜
E : Type uE
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace 𝕜 E
F : Type uF
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
G : Type uG
inst✝³ : NormedAddCommGroup G
inst✝² : NormedSpace 𝕜 G
X : Type uX
inst✝¹ : NormedAddCommGroup X
inst✝ : NormedSpace 𝕜 X
s s₁ t u : Set E
f f₁ : E → F
g : F → G
x x₀ : E
c : F
m✝ n✝ : ℕ∞
p : E → FormalMultilinearSeries 𝕜 E F
n : ℕ
m : Fin (n + 1) → E
⊢ ↑(iteratedFDeriv 𝕜 (n + 1) f x) m = ↑(↑(iteratedFDeriv 𝕜 n (fun y => fderiv 𝕜 f y) x) (init m)) (m (last n))

tactic: exact iteratedFDerivWithin_succ_apply_right uniqueDiffOn_univ (mem_univ _) _
state_before: 𝕜 : Type u
inst✝⁸ : NontriviallyNormedField 𝕜
E : Type uE
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace 𝕜 E
F : Type uF
inst✝⁵ : NormedAddCommGroup F
inst✝⁴ : NormedSpace 𝕜 F
G : Type uG
inst✝³ : NormedAddCommGroup G
inst✝² : NormedSpace 𝕜 G
X : Type uX
inst✝¹ : NormedAddCommGroup X
inst✝ : NormedSpace 𝕜 X
s s₁ t u : Set E
f f₁ : E → F
g : F → G
x x₀ : E
c : F
m✝ n✝ : ℕ∞
p : E → FormalMultilinearSeries 𝕜 E F
n : ℕ
m : Fin (n + 1) → E
⊢ ↑(iteratedFDerivWithin 𝕜 (n + 1) f univ x) m =
    ↑(↑(iteratedFDerivWithin 𝕜 n (fun y => fderivWithin 𝕜 f univ y) univ x) (init m)) (m (last n))
Theorem: MeasureTheory.Egorov.iUnionNotConvergentSeq_subset
File: Mathlib/MeasureTheory/Function/Egorov.lean

tactic: rw [iUnionNotConvergentSeq, ← Set.inter_iUnion]
state_before: α : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace α
inst✝³ : MetricSpace β
μ : Measure α
n : ℕ
i j : ι
s : Set α
ε : ℝ
f : ι → α → β
g : α → β
inst✝² : SemilatticeSup ι
inst✝¹ : Nonempty ι
inst✝ : Countable ι
hε : 0 < ε
hf : ∀ (n : ι), StronglyMeasurable (f n)
hg : StronglyMeasurable g
hsm : MeasurableSet s
hs : ↑↑μ s ≠ ⊤
hfg : ∀ᵐ (x : α) ∂μ, x ∈ s → Tendsto (fun n => f n x) atTop (𝓝 (g x))
⊢ iUnionNotConvergentSeq hε hf hg hsm hs hfg ⊆ s

tactic: exact Set.inter_subset_left _ _
state_before: α : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace α
inst✝³ : MetricSpace β
μ : Measure α
n : ℕ
i j : ι
s : Set α
ε : ℝ
f : ι → α → β
g : α → β
inst✝² : SemilatticeSup ι
inst✝¹ : Nonempty ι
inst✝ : Countable ι
hε : 0 < ε
hf : ∀ (n : ι), StronglyMeasurable (f n)
hg : StronglyMeasurable g
hsm : MeasurableSet s
hs : ↑↑μ s ≠ ⊤
hfg : ∀ᵐ (x : α) ∂μ, x ∈ s → Tendsto (fun n => f n x) atTop (𝓝 (g x))
⊢ (s ∩ ⋃ (i : ℕ), notConvergentSeq (fun n => f n) g i (notConvergentSeqLtIndex (_ : 0 < ε / 2) hf hg hsm hs hfg i)) ⊆ s
Theorem: PowerSeries.X_dvd_iff
File: Mathlib/RingTheory/PowerSeries/Basic.lean

tactic: rw [← pow_one (X : PowerSeries R), X_pow_dvd_iff, ← coeff_zero_eq_constantCoeff_apply]
state_before: R : Type u_1
inst✝ : Semiring R
φ : PowerSeries R
⊢ X ∣ φ ↔ ↑(constantCoeff R) φ = 0

tactic: constructor <;> intro h
state_before: R : Type u_1
inst✝ : Semiring R
φ : PowerSeries R
⊢ (∀ (m : ℕ), m < 1 → ↑(coeff R m) φ = 0) ↔ ↑(coeff R 0) φ = 0

tactic: exact h 0 zero_lt_one
state_before: case mp
R : Type u_1
inst✝ : Semiring R
φ : PowerSeries R
h : ∀ (m : ℕ), m < 1 → ↑(coeff R m) φ = 0
⊢ ↑(coeff R 0) φ = 0

tactic: intro m hm
state_before: case mpr
R : Type u_1
inst✝ : Semiring R
φ : PowerSeries R
h : ↑(coeff R 0) φ = 0
⊢ ∀ (m : ℕ), m < 1 → ↑(coeff R m) φ = 0

tactic: rwa [Nat.eq_zero_of_le_zero (Nat.le_of_succ_le_succ hm)]
state_before: case mpr
R : Type u_1
inst✝ : Semiring R
φ : PowerSeries R
h : ↑(coeff R 0) φ = 0
m : ℕ
hm : m < 1
⊢ ↑(coeff R m) φ = 0
Theorem: nhdsWithin_Ioc_eq_nhdsWithin_Iic
File: Mathlib/Topology/Order/Basic.lean

tactic: simpa only [dual_Ico] using nhdsWithin_Ico_eq_nhdsWithin_Ici h.dual
state_before: α : Type u
β : Type v
γ : Type w
inst✝³ : TopologicalSpace α
inst✝² : LinearOrder α
inst✝¹ : OrderClosedTopology α
a✝ b✝ : α
inst✝ : TopologicalSpace γ
a b : α
h : a < b
⊢ 𝓝[Ioc a b] b = 𝓝[Iic b] b
Theorem: Nat.Partrec'.vec_iff
File: Mathlib/Computability/Halting.lean

tactic: simpa only [ofFn_get] using vector_ofFn fun i => to_part (h i)
state_before: m n : ℕ
f : Vector ℕ m → Vector ℕ n
h : Vec f
⊢ Computable f
Theorem: CategoryTheory.CostructuredArrow.eqToHom_left
File: Mathlib/CategoryTheory/StructuredArrow.lean

tactic: rw [h]
state_before: C : Type u₁
inst✝¹ : Category C
D : Type u₂
inst✝ : Category D
T T' T'' : D
Y✝ Y' : C
S : C ⥤ D
X Y : CostructuredArrow S T
h : X = Y
⊢ X.left = Y.left

tactic: subst h
state_before: C : Type u₁
inst✝¹ : Category C
D : Type u₂
inst✝ : Category D
T T' T'' : D
Y✝ Y' : C
S : C ⥤ D
X Y : CostructuredArrow S T
h : X = Y
⊢ (eqToHom h).left = eqToHom (_ : X.left = Y.left)

tactic: simp only [eqToHom_refl, id_left]
state_before: C : Type u₁
inst✝¹ : Category C
D : Type u₂
inst✝ : Category D
T T' T'' : D
Y Y' : C
S : C ⥤ D
X : CostructuredArrow S T
⊢ (eqToHom (_ : X = X)).left = eqToHom (_ : X.left = X.left)
Theorem: Filter.map_eval_pi
File: Mathlib/Order/Filter/Pi.lean

tactic: refine' le_antisymm (tendsto_eval_pi f i) fun s hs => _
state_before: ι : Type u_2
α : ι → Type u_1
f✝ f₁ f₂ : (i : ι) → Filter (α i)
s : (i : ι) → Set (α i)
f : (i : ι) → Filter (α i)
inst✝ : ∀ (i : ι), NeBot (f i)
i : ι
⊢ map (eval i) (pi f) = f i

tactic: rcases mem_pi.1 (mem_map.1 hs) with ⟨I, hIf, t, htf, hI⟩
state_before: ι : Type u_2
α : ι → Type u_1
f✝ f₁ f₂ : (i : ι) → Filter (α i)
s✝ : (i : ι) → Set (α i)
f : (i : ι) → Filter (α i)
inst✝ : ∀ (i : ι), NeBot (f i)
i : ι
s : Set (α i)
hs : s ∈ map (eval i) (pi f)
⊢ s ∈ f i

tactic: rw [← image_subset_iff] at hI
state_before: case intro.intro.intro.intro
ι : Type u_2
α : ι → Type u_1
f✝ f₁ f₂ : (i : ι) → Filter (α i)
s✝ : (i : ι) → Set (α i)
f : (i : ι) → Filter (α i)
inst✝ : ∀ (i : ι), NeBot (f i)
i : ι
s : Set (α i)
hs : s ∈ map (eval i) (pi f)
I : Set ι
hIf : Set.Finite I
t : (i : ι) → Set (α i)
htf : ∀ (i : ι), t i ∈ f i
hI : Set.pi I t ⊆ eval i ⁻¹' s
⊢ s ∈ f i

tactic: refine' mem_of_superset (htf i) ((subset_eval_image_pi _ _).trans hI)
state_before: case intro.intro.intro.intro
ι : Type u_2
α : ι → Type u_1
f✝ f₁ f₂ : (i : ι) → Filter (α i)
s✝ : (i : ι) → Set (α i)
f : (i : ι) → Filter (α i)
inst✝ : ∀ (i : ι), NeBot (f i)
i : ι
s : Set (α i)
hs : s ∈ map (eval i) (pi f)
I : Set ι
hIf : Set.Finite I
t : (i : ι) → Set (α i)
htf : ∀ (i : ι), t i ∈ f i
hI : eval i '' Set.pi I t ⊆ s
⊢ s ∈ f i

tactic: exact nonempty_of_mem (pi_mem_pi hIf fun i _ => htf i)
state_before: case intro.intro.intro.intro
ι : Type u_2
α : ι → Type u_1
f✝ f₁ f₂ : (i : ι) → Filter (α i)
s✝ : (i : ι) → Set (α i)
f : (i : ι) → Filter (α i)
inst✝ : ∀ (i : ι), NeBot (f i)
i : ι
s : Set (α i)
hs : s ∈ map (eval i) (pi f)
I : Set ι
hIf : Set.Finite I
t : (i : ι) → Set (α i)
htf : ∀ (i : ι), t i ∈ f i
hI : eval i '' Set.pi I t ⊆ s
⊢ Set.Nonempty (Set.pi I t)
Theorem: List.Perm.countp_congr
File: Mathlib/Data/List/Perm.lean

tactic: rw [← s.countp_eq p']
state_before: α : Type uu
β : Type vv
l₁ l₂ : List α
s : l₁ ~ l₂
p p' : α → Bool
hp : ∀ (x : α), x ∈ l₁ → p x = p' x
⊢ countp p l₁ = countp p' l₂

tactic: clear s
state_before: α : Type uu
β : Type vv
l₁ l₂ : List α
s : l₁ ~ l₂
p p' : α → Bool
hp : ∀ (x : α), x ∈ l₁ → p x = p' x
⊢ countp p l₁ = countp p' l₁

tactic: induction' l₁ with y s hs
state_before: α : Type uu
β : Type vv
l₁ l₂ : List α
p p' : α → Bool
hp : ∀ (x : α), x ∈ l₁ → p x = p' x
⊢ countp p l₁ = countp p' l₁

tactic: rfl
state_before: case nil
α : Type uu
β : Type vv
l₁ l₂ : List α
p p' : α → Bool
hp✝ : ∀ (x : α), x ∈ l₁ → p x = p' x
hp : ∀ (x : α), x ∈ [] → p x = p' x
⊢ countp p [] = countp p' []

tactic: simp only [mem_cons, forall_eq_or_imp] at hp
state_before: case cons
α : Type uu
β : Type vv
l₁ l₂ : List α
p p' : α → Bool
hp✝ : ∀ (x : α), x ∈ l₁ → p x = p' x
y : α
s : List α
hs : (∀ (x : α), x ∈ s → p x = p' x) → countp p s = countp p' s
hp : ∀ (x : α), x ∈ y :: s → p x = p' x
⊢ countp p (y :: s) = countp p' (y :: s)

tactic: simp only [countp_cons, hs hp.2, hp.1]
state_before: case cons
α : Type uu
β : Type vv
l₁ l₂ : List α
p p' : α → Bool
hp✝ : ∀ (x : α), x ∈ l₁ → p x = p' x
y : α
s : List α
hs : (∀ (x : α), x ∈ s → p x = p' x) → countp p s = countp p' s
hp : p y = p' y ∧ ∀ (a : α), a ∈ s → p a = p' a
⊢ countp p (y :: s) = countp p' (y :: s)
Theorem: MeasureTheory.Measure.restrict_apply₀
File: Mathlib/MeasureTheory/Measure/MeasureSpace.lean

tactic: suffices μ (s ∩ t) = μ (s ∩ t ∩ s') + μ ((s ∩ t) \ s') by
  simpa [← Set.inter_assoc, Set.inter_comm _ s, ← inter_diff_assoc]
state_before: α : Type u_1
β : Type ?u.278939
γ : Type ?u.278942
δ : Type ?u.278945
ι : Type ?u.278948
R : Type ?u.278951
R' : Type ?u.278954
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s s'✝ t✝ : Set α
ht : NullMeasurableSet t✝
s' : Set α
hs' : MeasurableSet s'
t : Set α
⊢ ↑(↑(OuterMeasure.restrict s) ↑μ) t =
    ↑(↑(OuterMeasure.restrict s) ↑μ) (t ∩ s') + ↑(↑(OuterMeasure.restrict s) ↑μ) (t \ s')

tactic: exact le_toOuterMeasure_caratheodory _ _ hs' _
state_before: α : Type u_1
β : Type ?u.278939
γ : Type ?u.278942
δ : Type ?u.278945
ι : Type ?u.278948
R : Type ?u.278951
R' : Type ?u.278954
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s s'✝ t✝ : Set α
ht : NullMeasurableSet t✝
s' : Set α
hs' : MeasurableSet s'
t : Set α
⊢ ↑↑μ (s ∩ t) = ↑↑μ (s ∩ t ∩ s') + ↑↑μ ((s ∩ t) \ s')

tactic: simpa [← Set.inter_assoc, Set.inter_comm _ s, ← inter_diff_assoc]
state_before: α : Type u_1
β : Type ?u.278939
γ : Type ?u.278942
δ : Type ?u.278945
ι : Type ?u.278948
R : Type ?u.278951
R' : Type ?u.278954
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s s'✝ t✝ : Set α
ht : NullMeasurableSet t✝
s' : Set α
hs' : MeasurableSet s'
t : Set α
this : ↑↑μ (s ∩ t) = ↑↑μ (s ∩ t ∩ s') + ↑↑μ ((s ∩ t) \ s')
⊢ ↑(↑(OuterMeasure.restrict s) ↑μ) t =
    ↑(↑(OuterMeasure.restrict s) ↑μ) (t ∩ s') + ↑(↑(OuterMeasure.restrict s) ↑μ) (t \ s')

tactic: simp only [OuterMeasure.restrict_apply]
state_before: α : Type u_1
β : Type ?u.278939
γ : Type ?u.278942
δ : Type ?u.278945
ι : Type ?u.278948
R : Type ?u.278951
R' : Type ?u.278954
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s s' t : Set α
ht : NullMeasurableSet t
⊢ ↑(↑(OuterMeasure.restrict s) ↑μ) t = ↑↑μ (t ∩ s)
Theorem: Filter.tendsto_iff_rtendsto
File: Mathlib/Order/Filter/Partial.lean

tactic: simp [tendsto_def, Function.graph, rtendsto_def, Rel.core, Set.preimage]
state_before: α : Type u
β : Type v
γ : Type w
l₁ : Filter α
l₂ : Filter β
f : α → β
⊢ Tendsto f l₁ l₂ ↔ RTendsto (Function.graph f) l₁ l₂
Theorem: Int.measurable_floor
File: Mathlib/MeasureTheory/Function/Floor.lean

tactic: simpa only [Int.preimage_floor_singleton] using measurableSet_Ico
state_before: α : Type ?u.120
R : Type u_1
inst✝⁶ : MeasurableSpace α
inst✝⁵ : LinearOrderedRing R
inst✝⁴ : FloorRing R
inst✝³ : TopologicalSpace R
inst✝² : OrderTopology R
inst✝¹ : MeasurableSpace R
inst✝ : OpensMeasurableSpace R
x : R
⊢ MeasurableSet (floor ⁻¹' {⌊x⌋})
Theorem: Nat.coprime_one_right_iff
File: Mathlib/Data/Nat/GCD/Basic.lean

tactic: simp [coprime]
state_before: n : ℕ
⊢ coprime n 1 ↔ True
Theorem: Real.Angle.toReal_coe_eq_self_sub_two_mul_int_mul_pi_iff
File: Mathlib/Analysis/SpecialFunctions/Trigonometric/Angle.lean

tactic: rw [← sub_zero (θ : Angle), ← zsmul_zero k, ← coe_two_pi, ← coe_zsmul, ← coe_sub, zsmul_eq_mul, ←
  mul_assoc, mul_comm (k : ℝ), toReal_coe_eq_self_iff, Set.mem_Ioc]
state_before: θ : ℝ
k : ℤ
⊢ toReal ↑θ = θ - 2 * ↑k * π ↔ θ ∈ Set.Ioc ((2 * ↑k - 1) * π) ((2 * ↑k + 1) * π)

tactic: exact ⟨fun h => ⟨by linarith, by linarith⟩, fun h => ⟨by linarith, by linarith⟩⟩
state_before: θ : ℝ
k : ℤ
⊢ -π < θ - 2 * ↑k * π ∧ θ - 2 * ↑k * π ≤ π ↔ (2 * ↑k - 1) * π < θ ∧ θ ≤ (2 * ↑k + 1) * π

tactic: linarith
state_before: θ : ℝ
k : ℤ
h : -π < θ - 2 * ↑k * π ∧ θ - 2 * ↑k * π ≤ π
⊢ (2 * ↑k - 1) * π < θ

tactic: linarith
state_before: θ : ℝ
k : ℤ
h : -π < θ - 2 * ↑k * π ∧ θ - 2 * ↑k * π ≤ π
⊢ θ ≤ (2 * ↑k + 1) * π

tactic: linarith
state_before: θ : ℝ
k : ℤ
h : (2 * ↑k - 1) * π < θ ∧ θ ≤ (2 * ↑k + 1) * π
⊢ -π < θ - 2 * ↑k * π

tactic: linarith
state_before: θ : ℝ
k : ℤ
h : (2 * ↑k - 1) * π < θ ∧ θ ≤ (2 * ↑k + 1) * π
⊢ θ - 2 * ↑k * π ≤ π
Theorem: gc_nhds
File: Mathlib/Topology/Order.lean

tactic: rw [le_nhds_iff]
state_before: α : Type u
β : Type v
a : α
f : Filter α
t : TopologicalSpace α
⊢ nhdsAdjoint a f ≤ t ↔ f ≤ (fun t => 𝓝 a) t

tactic: exact ⟨fun H s hs has => H _ has hs, fun H s has hs => H _ hs has⟩
state_before: α : Type u
β : Type v
a : α
f : Filter α
t : TopologicalSpace α
⊢ nhdsAdjoint a f ≤ t ↔ ∀ (s : Set α), a ∈ s → IsOpen s → s ∈ f
Theorem: Padic.exi_rat_seq_conv
File: Mathlib/NumberTheory/Padics/PadicNumbers.lean

tactic: refine' (exists_nat_gt (1 / ε)).imp fun N hN i hi ↦ _
state_before: p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ↑padicNormE
ε : ℚ
hε : 0 < ε
⊢ ∃ N, ∀ (i : ℕ), i ≥ N → ↑padicNormE (↑f i - ↑(limSeq f i)) < ε

tactic: have h := Classical.choose_spec (rat_dense' (f i) (div_nat_pos i))
state_before: p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ↑padicNormE
ε : ℚ
hε : 0 < ε
N : ℕ
hN : 1 / ε < ↑N
i : ℕ
hi : i ≥ N
⊢ ↑padicNormE (↑f i - ↑(limSeq f i)) < ε

tactic: refine' lt_of_lt_of_le h ((div_le_iff' <| by exact_mod_cast succ_pos _).mpr _)
state_before: p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ↑padicNormE
ε : ℚ
hε : 0 < ε
N : ℕ
hN : 1 / ε < ↑N
i : ℕ
hi : i ≥ N
h : ↑padicNormE (↑f i - ↑(Classical.choose (_ : ∃ r, ↑padicNormE (↑f i - ↑r) < 1 / (↑i + 1)))) < 1 / (↑i + 1)
⊢ ↑padicNormE (↑f i - ↑(limSeq f i)) < ε

tactic: rw [right_distrib]
state_before: p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ↑padicNormE
ε : ℚ
hε : 0 < ε
N : ℕ
hN : 1 / ε < ↑N
i : ℕ
hi : i ≥ N
h : ↑padicNormE (↑f i - ↑(Classical.choose (_ : ∃ r, ↑padicNormE (↑f i - ↑r) < 1 / (↑i + 1)))) < 1 / (↑i + 1)
⊢ 1 ≤ (↑i + 1) * ε

tactic: apply le_add_of_le_of_nonneg
state_before: p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ↑padicNormE
ε : ℚ
hε : 0 < ε
N : ℕ
hN : 1 / ε < ↑N
i : ℕ
hi : i ≥ N
h : ↑padicNormE (↑f i - ↑(Classical.choose (_ : ∃ r, ↑padicNormE (↑f i - ↑r) < 1 / (↑i + 1)))) < 1 / (↑i + 1)
⊢ 1 ≤ ↑i * ε + 1 * ε

tactic: exact_mod_cast succ_pos _
state_before: p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ↑padicNormE
ε : ℚ
hε : 0 < ε
N : ℕ
hN : 1 / ε < ↑N
i : ℕ
hi : i ≥ N
h : ↑padicNormE (↑f i - ↑(Classical.choose (_ : ∃ r, ↑padicNormE (↑f i - ↑r) < 1 / (↑i + 1)))) < 1 / (↑i + 1)
⊢ 0 < ↑i + 1

tactic: exact (div_le_iff hε).mp (le_trans (le_of_lt hN) (by exact_mod_cast hi))
state_before: case hbc
p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ↑padicNormE
ε : ℚ
hε : 0 < ε
N : ℕ
hN : 1 / ε < ↑N
i : ℕ
hi : i ≥ N
h : ↑padicNormE (↑f i - ↑(Classical.choose (_ : ∃ r, ↑padicNormE (↑f i - ↑r) < 1 / (↑i + 1)))) < 1 / (↑i + 1)
⊢ 1 ≤ ↑i * ε

tactic: exact_mod_cast hi
state_before: p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ↑padicNormE
ε : ℚ
hε : 0 < ε
N : ℕ
hN : 1 / ε < ↑N
i : ℕ
hi : i ≥ N
h : ↑padicNormE (↑f i - ↑(Classical.choose (_ : ∃ r, ↑padicNormE (↑f i - ↑r) < 1 / (↑i + 1)))) < 1 / (↑i + 1)
⊢ ↑N ≤ ↑i

tactic: apply le_of_lt
state_before: case ha
p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ↑padicNormE
ε : ℚ
hε : 0 < ε
N : ℕ
hN : 1 / ε < ↑N
i : ℕ
hi : i ≥ N
h : ↑padicNormE (↑f i - ↑(Classical.choose (_ : ∃ r, ↑padicNormE (↑f i - ↑r) < 1 / (↑i + 1)))) < 1 / (↑i + 1)
⊢ 0 ≤ 1 * ε

tactic: simpa
state_before: case ha.a
p : ℕ
inst✝ : Fact (Nat.Prime p)
f : CauSeq ℚ_[p] ↑padicNormE
ε : ℚ
hε : 0 < ε
N : ℕ
hN : 1 / ε < ↑N
i : ℕ
hi : i ≥ N
h : ↑padicNormE (↑f i - ↑(Classical.choose (_ : ∃ r, ↑padicNormE (↑f i - ↑r) < 1 / (↑i + 1)))) < 1 / (↑i + 1)
⊢ 0 < 1 * ε