tasksource/leandojo huggingface dataset:
Theorem: exists_pos_lt_subset_ball
File: Mathlib/Topology/MetricSpace/Basic.lean

tactic: rcases eq_empty_or_nonempty s with (rfl | hne)
state_before: α : Type u
β : Type v
X : Type ?u.436396
ι : Type ?u.436399
inst✝¹ : PseudoMetricSpace α
inst✝ : ProperSpace α
x : α
r : ℝ
s : Set α
hr : 0 < r
hs : IsClosed s
h : s ⊆ ball x r
⊢ ∃ r', r' ∈ Ioo 0 r ∧ s ⊆ ball x r'

tactic: have : IsCompact s :=
  isCompact_of_isClosed_subset (isCompact_closedBall x r) hs
    (h.trans ball_subset_closedBall)
state_before: case inr
α : Type u
β : Type v
X : Type ?u.436396
ι : Type ?u.436399
inst✝¹ : PseudoMetricSpace α
inst✝ : ProperSpace α
x : α
r : ℝ
s : Set α
hr : 0 < r
hs : IsClosed s
h : s ⊆ ball x r
hne : Set.Nonempty s
⊢ ∃ r', r' ∈ Ioo 0 r ∧ s ⊆ ball x r'

tactic: obtain ⟨y, hys, hy⟩ : ∃ y ∈ s, s ⊆ closedBall x (dist y x) :=
  this.exists_forall_ge hne (continuous_id.dist continuous_const).continuousOn
state_before: case inr
α : Type u
β : Type v
X : Type ?u.436396
ι : Type ?u.436399
inst✝¹ : PseudoMetricSpace α
inst✝ : ProperSpace α
x : α
r : ℝ
s : Set α
hr : 0 < r
hs : IsClosed s
h : s ⊆ ball x r
hne : Set.Nonempty s
this : IsCompact s
⊢ ∃ r', r' ∈ Ioo 0 r ∧ s ⊆ ball x r'

tactic: have hyr : dist y x < r := h hys
state_before: case inr.intro.intro
α : Type u
β : Type v
X : Type ?u.436396
ι : Type ?u.436399
inst✝¹ : PseudoMetricSpace α
inst✝ : ProperSpace α
x : α
r : ℝ
s : Set α
hr : 0 < r
hs : IsClosed s
h : s ⊆ ball x r
hne : Set.Nonempty s
this : IsCompact s
y : α
hys : y ∈ s
hy : s ⊆ closedBall x (dist y x)
⊢ ∃ r', r' ∈ Ioo 0 r ∧ s ⊆ ball x r'

tactic: rcases exists_between hyr with ⟨r', hyr', hrr'⟩
state_before: case inr.intro.intro
α : Type u
β : Type v
X : Type ?u.436396
ι : Type ?u.436399
inst✝¹ : PseudoMetricSpace α
inst✝ : ProperSpace α
x : α
r : ℝ
s : Set α
hr : 0 < r
hs : IsClosed s
h : s ⊆ ball x r
hne : Set.Nonempty s
this : IsCompact s
y : α
hys : y ∈ s
hy : s ⊆ closedBall x (dist y x)
hyr : dist y x < r
⊢ ∃ r', r' ∈ Ioo 0 r ∧ s ⊆ ball x r'

tactic: exact ⟨r', ⟨dist_nonneg.trans_lt hyr', hrr'⟩, hy.trans <| closedBall_subset_ball hyr'⟩
state_before: case inr.intro.intro.intro.intro
α : Type u
β : Type v
X : Type ?u.436396
ι : Type ?u.436399
inst✝¹ : PseudoMetricSpace α
inst✝ : ProperSpace α
x : α
r : ℝ
s : Set α
hr : 0 < r
hs : IsClosed s
h : s ⊆ ball x r
hne : Set.Nonempty s
this : IsCompact s
y : α
hys : y ∈ s
hy : s ⊆ closedBall x (dist y x)
hyr : dist y x < r
r' : ℝ
hyr' : dist y x < r'
hrr' : r' < r
⊢ ∃ r', r' ∈ Ioo 0 r ∧ s ⊆ ball x r'

tactic: exact ⟨r / 2, ⟨half_pos hr, half_lt_self hr⟩, empty_subset _⟩
state_before: case inl
α : Type u
β : Type v
X : Type ?u.436396
ι : Type ?u.436399
inst✝¹ : PseudoMetricSpace α
inst✝ : ProperSpace α
x : α
r : ℝ
hr : 0 < r
hs : IsClosed ∅
h : ∅ ⊆ ball x r
⊢ ∃ r', r' ∈ Ioo 0 r ∧ ∅ ⊆ ball x r'
Theorem: MeasureTheory.ite_ae_eq_of_measure_compl_zero
File: Mathlib/MeasureTheory/Measure/MeasureSpace.lean

tactic: change s ∈ μ.ae at hs_zero
state_before: α : Type u_2
β : Type ?u.720764
γ✝ : Type ?u.720767
δ : Type ?u.720770
ι : Type ?u.720773
R : Type ?u.720776
R' : Type ?u.720779
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ✝
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s✝ s' t : Set α
γ : Type u_1
f g : α → γ
s : Set α
hs_zero : ↑↑μ (sᶜ) = 0
⊢ (fun x => if x ∈ s then f x else g x) =ᶠ[ae μ] f

tactic: filter_upwards [hs_zero]
state_before: α : Type u_2
β : Type ?u.720764
γ✝ : Type ?u.720767
δ : Type ?u.720770
ι : Type ?u.720773
R : Type ?u.720776
R' : Type ?u.720779
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ✝
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s✝ s' t : Set α
γ : Type u_1
f g : α → γ
s : Set α
hs_zero : s ∈ ae μ
⊢ (fun x => if x ∈ s then f x else g x) =ᶠ[ae μ] f

tactic: intros
state_before: case h
α : Type u_2
β : Type ?u.720764
γ✝ : Type ?u.720767
δ : Type ?u.720770
ι : Type ?u.720773
R : Type ?u.720776
R' : Type ?u.720779
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ✝
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s✝ s' t : Set α
γ : Type u_1
f g : α → γ
s : Set α
hs_zero : s ∈ ae μ
⊢ ∀ (a : α), a ∈ s → (if a ∈ s then f a else g a) = f a

tactic: split_ifs
state_before: case h
α : Type u_2
β : Type ?u.720764
γ✝ : Type ?u.720767
δ : Type ?u.720770
ι : Type ?u.720773
R : Type ?u.720776
R' : Type ?u.720779
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ✝
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s✝ s' t : Set α
γ : Type u_1
f g : α → γ
s : Set α
hs_zero : s ∈ ae μ
a✝¹ : α
a✝ : a✝¹ ∈ s
⊢ (if a✝¹ ∈ s then f a✝¹ else g a✝¹) = f a✝¹

tactic: rfl
state_before: case h
α : Type u_2
β : Type ?u.720764
γ✝ : Type ?u.720767
δ : Type ?u.720770
ι : Type ?u.720773
R : Type ?u.720776
R' : Type ?u.720779
m0 : MeasurableSpace α
inst✝¹ : MeasurableSpace β
inst✝ : MeasurableSpace γ✝
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s✝ s' t : Set α
γ : Type u_1
f g : α → γ
s : Set α
hs_zero : s ∈ ae μ
a✝¹ : α
a✝ : a✝¹ ∈ s
⊢ f a✝¹ = f a✝¹
Theorem: SimpleGraph.isAcyclic_of_path_unique
File: Mathlib/Combinatorics/SimpleGraph/Acyclic.lean

tactic: intro v c hc
state_before: V : Type u
G : SimpleGraph V
h : ∀ (v w : V) (p q : Path G v w), p = q
⊢ IsAcyclic G

tactic: simp only [Walk.isCycle_def, Ne.def] at hc
state_before: V : Type u
G : SimpleGraph V
h : ∀ (v w : V) (p q : Path G v w), p = q
v : V
c : Walk G v v
hc : Walk.IsCycle c
⊢ False

tactic: cases c with
| nil => cases hc.2.1 rfl
| cons ha c' =>
  simp only [Walk.cons_isTrail_iff, Walk.support_cons, List.tail_cons, true_and_iff] at hc
  specialize h _ _ ⟨c', by simp only [Walk.isPath_def, hc.2]⟩ (Path.singleton ha.symm)
  rw [Path.singleton, Subtype.mk.injEq] at h
  simp [h] at hc
state_before: V : Type u
G : SimpleGraph V
h : ∀ (v w : V) (p q : Path G v w), p = q
v : V
c : Walk G v v
hc : Walk.IsTrail c ∧ ¬c = Walk.nil ∧ List.Nodup (List.tail (Walk.support c))
⊢ False

tactic: cases hc.2.1 rfl
state_before: case nil
V : Type u
G : SimpleGraph V
h : ∀ (v w : V) (p q : Path G v w), p = q
v : V
hc : Walk.IsTrail Walk.nil ∧ ¬Walk.nil = Walk.nil ∧ List.Nodup (List.tail (Walk.support Walk.nil))
⊢ False

tactic: simp only [Walk.cons_isTrail_iff, Walk.support_cons, List.tail_cons, true_and_iff] at hc
state_before: case cons
V : Type u
G : SimpleGraph V
h : ∀ (v w : V) (p q : Path G v w), p = q
v v✝ : V
ha : Adj G v v✝
c' : Walk G v✝ v
hc :
  Walk.IsTrail (Walk.cons ha c') ∧ ¬Walk.cons ha c' = Walk.nil ∧ List.Nodup (List.tail (Walk.support (Walk.cons ha c')))
⊢ False

tactic: specialize h _ _ ⟨c', by simp only [Walk.isPath_def, hc.2]⟩ (Path.singleton ha.symm)
state_before: case cons
V : Type u
G : SimpleGraph V
h : ∀ (v w : V) (p q : Path G v w), p = q
v v✝ : V
ha : Adj G v v✝
c' : Walk G v✝ v
hc : (Walk.IsTrail c' ∧ ¬Quotient.mk (Sym2.Rel.setoid V) (v, v✝) ∈ Walk.edges c') ∧ List.Nodup (Walk.support c')
⊢ False

tactic: rw [Path.singleton, Subtype.mk.injEq] at h
state_before: case cons
V : Type u
G : SimpleGraph V
v v✝ : V
ha : Adj G v v✝
c' : Walk G v✝ v
hc : (Walk.IsTrail c' ∧ ¬Quotient.mk (Sym2.Rel.setoid V) (v, v✝) ∈ Walk.edges c') ∧ List.Nodup (Walk.support c')
h : { val := c', property := (_ : Walk.IsPath c') } = Path.singleton (_ : Adj G v✝ v)
⊢ False

tactic: simp [h] at hc
state_before: case cons
V : Type u
G : SimpleGraph V
v v✝ : V
ha : Adj G v v✝
c' : Walk G v✝ v
hc : (Walk.IsTrail c' ∧ ¬Quotient.mk (Sym2.Rel.setoid V) (v, v✝) ∈ Walk.edges c') ∧ List.Nodup (Walk.support c')
h : c' = Walk.cons (_ : Adj G v✝ v) Walk.nil
⊢ False

tactic: simp only [Walk.isPath_def, hc.2]
state_before: V : Type u
G : SimpleGraph V
h : ∀ (v w : V) (p q : Path G v w), p = q
v v✝ : V
ha : Adj G v v✝
c' : Walk G v✝ v
hc : (Walk.IsTrail c' ∧ ¬Quotient.mk (Sym2.Rel.setoid V) (v, v✝) ∈ Walk.edges c') ∧ List.Nodup (Walk.support c')
⊢ Walk.IsPath c'
Theorem: Monotone.tendsto_leftLim_within
File: Mathlib/Topology/Algebra/Order/LeftRightLim.lean

tactic: apply tendsto_nhdsWithin_of_tendsto_nhds_of_eventually_within f (hf.tendsto_leftLim x)
state_before: α : Type u_1
β : Type u_2
inst✝⁵ : LinearOrder α
inst✝⁴ : ConditionallyCompleteLinearOrder β
inst✝³ : TopologicalSpace β
inst✝² : OrderTopology β
f : α → β
hf : Monotone f
x✝ y : α
inst✝¹ : TopologicalSpace α
inst✝ : OrderTopology α
x : α
⊢ Tendsto f (𝓝[Iio x] x) (𝓝[Iic (leftLim f x)] leftLim f x)

tactic: filter_upwards [@self_mem_nhdsWithin _ _ x (Iio x)] with y hy using hf.le_leftLim hy
state_before: α : Type u_1
β : Type u_2
inst✝⁵ : LinearOrder α
inst✝⁴ : ConditionallyCompleteLinearOrder β
inst✝³ : TopologicalSpace β
inst✝² : OrderTopology β
f : α → β
hf : Monotone f
x✝ y : α
inst✝¹ : TopologicalSpace α
inst✝ : OrderTopology α
x : α
⊢ ∀ᶠ (x_1 : α) in 𝓝[Iio x] x, f x_1 ∈ Iic (leftLim f x)
Theorem: MeasureTheory.hasFiniteIntegral_restrict_of_bounded
File: Mathlib/MeasureTheory/Integral/IntegrableOn.lean

tactic: rwa [Measure.restrict_apply_univ]
state_before: α : Type u_2
β : Type ?u.1492993
E : Type u_1
F : Type ?u.1492999
inst✝¹ : MeasurableSpace α
inst✝ : NormedAddCommGroup E
f : α → E
s : Set α
μ : Measure α
C : ℝ
hs : ↑↑μ s < ⊤
hf : ∀ᵐ (x : α) ∂Measure.restrict μ s, ‖f x‖ ≤ C
⊢ ↑↑(Measure.restrict μ s) univ < ⊤
Theorem: List.enumFrom_cons'
File: Mathlib/Data/List/Basic.lean

tactic: rw [enumFrom_cons, add_comm, ← map_fst_add_enumFrom_eq_enumFrom]
state_before: ι : Type ?u.450121
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α
n : ℕ
x : α
xs : List α
⊢ enumFrom n (x :: xs) = (n, x) :: map (Prod.map succ id) (enumFrom n xs)
Theorem: Int.succ_iterate
File: Mathlib/Data/Int/SuccPred.lean

tactic: rw [Function.iterate_succ', Int.ofNat_succ, ← add_assoc]
state_before: a : ℤ
n : ℕ
⊢ (succ^[n + 1]) a = a + ↑(n + 1)

tactic: exact congr_arg _ (succ_iterate a n)
state_before: a : ℤ
n : ℕ
⊢ (succ ∘ succ^[n]) a = a + ↑n + 1
Theorem: Finsupp.support_zipWith
File: Mathlib/Data/Finsupp/Defs.lean

tactic: rw [Subsingleton.elim D] <;> exact support_onFinset_subset
state_before: α : Type u_1
β : Type ?u.275665
γ : Type ?u.275668
ι : Type ?u.275671
M : Type u_3
M' : Type ?u.275677
N : Type u_4
P : Type u_2
G : Type ?u.275686
H : Type ?u.275689
R : Type ?u.275692
S : Type ?u.275695
inst✝² : Zero M
inst✝¹ : Zero N
inst✝ : Zero P
D : DecidableEq α
f : M → N → P
hf : f 0 0 = 0
g₁ : α →₀ M
g₂ : α →₀ N
⊢ (zipWith f hf g₁ g₂).support ⊆ g₁.support ∪ g₂.support
Theorem: Nat.div_le_self'
File: Mathlib/Data/Nat/Order/Basic.lean

tactic: rw [n0, Nat.div_zero]
state_before: m✝ n✝ k l m n : ℕ
n0 : n = 0
⊢ m / n ≤ m

tactic: apply zero_le
state_before: m✝ n✝ k l m n : ℕ
n0 : n = 0
⊢ 0 ≤ m
Theorem: TopologicalSpace.IsTopologicalBasis.open_eq_iUnion
File: Mathlib/Topology/Bases.lean

tactic: rw [← sUnion_eq_iUnion]
state_before: α : Type u
t : TopologicalSpace α
B : Set (Set α)
hB : IsTopologicalBasis B
u : Set α
ou : IsOpen u
⊢ u = ⋃ (i : ↑{s | s ∈ B ∧ s ⊆ u}), ↑i

tactic: apply hB.open_eq_sUnion' ou
state_before: α : Type u
t : TopologicalSpace α
B : Set (Set α)
hB : IsTopologicalBasis B
u : Set α
ou : IsOpen u
⊢ u = ⋃₀ {s | s ∈ B ∧ s ⊆ u}
Theorem: Isometry.preimage_setOf_dist
File: Mathlib/Topology/MetricSpace/Isometry.lean

tactic: ext y
state_before: ι : Type ?u.61211
α : Type u
β : Type v
γ : Type w
inst✝¹ : PseudoMetricSpace α
inst✝ : PseudoMetricSpace β
f : α → β
hf : Isometry f
x : α
p : ℝ → Prop
⊢ f ⁻¹' {y | p (dist y (f x))} = {y | p (dist y x)}

tactic: simp [hf.dist_eq]
state_before: case h
ι : Type ?u.61211
α : Type u
β : Type v
γ : Type w
inst✝¹ : PseudoMetricSpace α
inst✝ : PseudoMetricSpace β
f : α → β
hf : Isometry f
x : α
p : ℝ → Prop
y : α
⊢ y ∈ f ⁻¹' {y | p (dist y (f x))} ↔ y ∈ {y | p (dist y x)}
Theorem: MvPolynomial.indicator_mem_restrictDegree
File: Mathlib/FieldTheory/Finite/Polynomial.lean

tactic: rw [mem_restrictDegree_iff_sup, indicator]
state_before: K : Type u_2
σ : Type u_1
inst✝² : Fintype K
inst✝¹ : Fintype σ
inst✝ : CommRing K
c : σ → K
⊢ indicator c ∈ restrictDegree σ K (Fintype.card K - 1)

tactic: intro n
state_before: K : Type u_2
σ : Type u_1
inst✝² : Fintype K
inst✝¹ : Fintype σ
inst✝ : CommRing K
c : σ → K
⊢ ∀ (i : σ), Multiset.count i (degrees (∏ n : σ, (1 - (X n - ↑C (c n)) ^ (Fintype.card K - 1)))) ≤ Fintype.card K - 1

tactic: refine' le_trans (Multiset.count_le_of_le _ <| degrees_indicator _) (le_of_eq _)
state_before: K : Type u_2
σ : Type u_1
inst✝² : Fintype K
inst✝¹ : Fintype σ
inst✝ : CommRing K
c : σ → K
n : σ
⊢ Multiset.count n (degrees (∏ n : σ, (1 - (X n - ↑C (c n)) ^ (Fintype.card K - 1)))) ≤ Fintype.card K - 1

tactic: simp_rw [← Multiset.coe_countAddMonoidHom, (Multiset.countAddMonoidHom n).map_sum,
  AddMonoidHom.map_nsmul, Multiset.coe_countAddMonoidHom, nsmul_eq_mul, Nat.cast_id]
state_before: K : Type u_2
σ : Type u_1
inst✝² : Fintype K
inst✝¹ : Fintype σ
inst✝ : CommRing K
c : σ → K
n : σ
⊢ Multiset.count n (∑ s : σ, (Fintype.card K - 1) • {s}) = Fintype.card K - 1

tactic: trans
state_before: K : Type u_2
σ : Type u_1
inst✝² : Fintype K
inst✝¹ : Fintype σ
inst✝ : CommRing K
c : σ → K
n : σ
⊢ ∑ x : σ, (Fintype.card K - 1) * Multiset.count n {x} = Fintype.card K - 1

tactic: refine' Finset.sum_eq_single n _ _
state_before: K : Type u_2
σ : Type u_1
inst✝² : Fintype K
inst✝¹ : Fintype σ
inst✝ : CommRing K
c : σ → K
n : σ
⊢ ∑ x : σ, (Fintype.card K - 1) * Multiset.count n {x} = ?m.179638

K : Type u_2
σ : Type u_1
inst✝² : Fintype K
inst✝¹ : Fintype σ
inst✝ : CommRing K
c : σ → K
n : σ
⊢ ?m.179638 = Fintype.card K - 1

K : Type u_2
σ : Type u_1
inst✝² : Fintype K
inst✝¹ : Fintype σ
inst✝ : CommRing K
c : σ → K
n : σ
⊢ ℕ

tactic: intro b _ ne
state_before: case refine'_1
K : Type u_2
σ : Type u_1
inst✝² : Fintype K
inst✝¹ : Fintype σ
inst✝ : CommRing K
c : σ → K
n : σ
⊢ ∀ (b : σ), b ∈ Finset.univ → b ≠ n → (Fintype.card K - 1) * Multiset.count n {b} = 0

tactic: simp [Multiset.count_singleton, ne, if_neg (Ne.symm _)]
state_before: case refine'_1
K : Type u_2
σ : Type u_1
inst✝² : Fintype K
inst✝¹ : Fintype σ
inst✝ : CommRing K
c : σ → K
n b : σ
a✝ : b ∈ Finset.univ
ne : b ≠ n
⊢ (Fintype.card K - 1) * Multiset.count n {b} = 0

tactic: intro h
state_before: case refine'_2
K : Type u_2
σ : Type u_1
inst✝² : Fintype K
inst✝¹ : Fintype σ
inst✝ : CommRing K
c : σ → K
n : σ
⊢ ¬n ∈ Finset.univ → (Fintype.card K - 1) * Multiset.count n {n} = 0

tactic: exact (h <| Finset.mem_univ _).elim
state_before: case refine'_2
K : Type u_2
σ : Type u_1
inst✝² : Fintype K
inst✝¹ : Fintype σ
inst✝ : CommRing K
c : σ → K
n : σ
h : ¬n ∈ Finset.univ
⊢ (Fintype.card K - 1) * Multiset.count n {n} = 0

tactic: rw [Multiset.count_singleton_self, mul_one]
state_before: K : Type u_2
σ : Type u_1
inst✝² : Fintype K
inst✝¹ : Fintype σ
inst✝ : CommRing K
c : σ → K
n : σ
⊢ (Fintype.card K - 1) * Multiset.count n {n} = Fintype.card K - 1
Theorem: EReal.abs_mul_sign
File: Mathlib/Data/Real/EReal.lean

tactic: rw [EReal.mul_comm, EReal.sign_mul_abs]
state_before: x : EReal
⊢ ↑(EReal.abs x) * ↑(↑sign x) = x
Theorem: Turing.PartrecToTM2.head_supports
File: Mathlib/Computability/TMToPartrec.lean

tactic: dsimp only
state_before: S : Finset Λ'
k : K'
q : Λ'
H : Λ'.Supports S q
x✝ : Option Γ'
⊢ Λ'.Supports S ((fun s => ite (s = some Γ'.consₗ) id (Λ'.clear (fun x => decide (x = Γ'.consₗ)) k) (unrev q)) x✝)

tactic: split_ifs <;> exact H
state_before: S : Finset Λ'
k : K'
q : Λ'
H : Λ'.Supports S q
x✝ : Option Γ'
⊢ Λ'.Supports S (ite (x✝ = some Γ'.consₗ) id (Λ'.clear (fun x => decide (x = Γ'.consₗ)) k) (unrev q))
Theorem: CategoryTheory.Limits.biproduct.toSubtype_eq_desc
File: Mathlib/CategoryTheory/Limits/Shapes/Biproducts.lean

tactic: simp
state_before: J : Type w
C : Type u
inst✝⁴ : Category C
inst✝³ : HasZeroMorphisms C
f : J → C
inst✝² : HasBiproduct f
p : J → Prop
inst✝¹ : HasBiproduct (Subtype.restrict p f)
inst✝ : DecidablePred p
⊢ ∀ (j : J),
    ι f j ≫ toSubtype f p =
      ι f j ≫ desc fun j => if h : p j then ι (Subtype.restrict p f) { val := j, property := h } else 0
Theorem: FirstOrder.Language.BoundedFormula.semanticallyEquivalent_toPrenex
File: Mathlib/ModelTheory/Satisfiability.lean

tactic: rw [realize_iff, realize_toPrenex]
state_before: L : Language
T : Theory L
α : Type w
n : ℕ
φ : BoundedFormula L α n
M : Theory.ModelType ∅
v : α → ↑M
xs : Fin n → ↑M
⊢ Realize (φ ⇔ toPrenex φ) v xs
Theorem: NormedAddGroupHom.norm_id_le
File: Mathlib/Analysis/Normed/Group/Hom.lean

tactic: simp
state_before: V : Type u_1
V₁ : Type ?u.319330
V₂ : Type ?u.319333
V₃ : Type ?u.319336
inst✝³ : SeminormedAddCommGroup V
inst✝² : SeminormedAddCommGroup V₁
inst✝¹ : SeminormedAddCommGroup V₂
inst✝ : SeminormedAddCommGroup V₃
f g : NormedAddGroupHom V₁ V₂
x : V
⊢ ‖↑(id V) x‖ ≤ 1 * ‖x‖
Theorem: Equiv.Perm.two_le_length_toList_iff_mem_support
File: Mathlib/GroupTheory/Perm/Cycle/Concrete.lean

tactic: simp
state_before: α : Type u_1
inst✝¹ : Fintype α
inst✝ : DecidableEq α
p✝ : Perm α
x✝ : α
p : Perm α
x : α
⊢ 2 ≤ length (toList p x) ↔ x ∈ support p
Theorem: CommMonoid.toMonoid_injective
File: Mathlib/Algebra/Group/Ext.lean

tactic: rintro ⟨⟩ ⟨⟩ h
state_before: M : Type u
⊢ Function.Injective (@toMonoid M)

tactic: congr
state_before: case mk.mk
M : Type u
toMonoid✝¹ : Monoid M
mul_comm✝¹ : ∀ (a b : M), a * b = b * a
toMonoid✝ : Monoid M
mul_comm✝ : ∀ (a b : M), a * b = b * a
h : toMonoid = toMonoid
⊢ mk mul_comm✝¹ = mk mul_comm✝
Theorem: SimpleGraph.edgeFinset_inf
File: Mathlib/Combinatorics/SimpleGraph/Basic.lean

tactic: simp [edgeFinset]
state_before: ι : Sort ?u.122332
𝕜 : Type ?u.122335
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
G₁ G₂ : SimpleGraph V
inst✝³ : Fintype ↑(edgeSet G)
inst✝² : Fintype ↑(edgeSet G₁)
inst✝¹ : Fintype ↑(edgeSet G₂)
inst✝ : DecidableEq V
⊢ edgeFinset (G₁ ⊓ G₂) = edgeFinset G₁ ∩ edgeFinset G₂
Theorem: SimplicialObject.Splitting.ιSummand_id
File: Mathlib/AlgebraicTopology/SplitSimplicialObject.lean

tactic: erw [ιSummand_eq, X.map_id, comp_id]
state_before: C : Type u_2
inst✝¹ : Category C
inst✝ : HasFiniteCoproducts C
X Y : SimplicialObject C
s : Splitting X
n : ℕ
⊢ ιSummand s (IndexSet.id [n].op) = ι s n

tactic: rfl
state_before: C : Type u_2
inst✝¹ : Category C
inst✝ : HasFiniteCoproducts C
X Y : SimplicialObject C
s : Splitting X
n : ℕ
⊢ ι s (len (IndexSet.id [n].op).fst.unop) = ι s n
Theorem: Matrix.cons_vec_bit1_eq_alt1
File: Mathlib/Data/Fin/VecNotation.lean

tactic: rw [vecAlt1_vecAppend]
state_before: α : Type u
m n o : ℕ
m' : Type ?u.49849
n' : Type ?u.49852
o' : Type ?u.49855
x : α
u : Fin n → α
i : Fin (n + 1)
⊢ vecCons x u (bit1 i) =
    vecAlt1 (_ : Nat.succ n + Nat.succ n = Nat.succ n + Nat.succ n)
      (vecAppend (_ : Nat.succ n + Nat.succ n = Nat.succ n + Nat.succ n) (vecCons x u) (vecCons x u)) i

tactic: rfl
state_before: α : Type u
m n o : ℕ
m' : Type ?u.49849
n' : Type ?u.49852
o' : Type ?u.49855
x : α
u : Fin n → α
i : Fin (n + 1)
⊢ vecCons x u (bit1 i) = (vecCons x u ∘ bit1) i
Theorem: MvPowerSeries.add_mul
File: Mathlib/RingTheory/PowerSeries/Basic.lean

tactic: simp only [coeff_mul, add_mul, Finset.sum_add_distrib, LinearMap.map_add]
state_before: σ : Type u_1
R : Type u_2
inst✝ : Semiring R
m n✝ : σ →₀ ℕ
φ ψ φ₁ φ₂ φ₃ : MvPowerSeries σ R
n : σ →₀ ℕ
⊢ ↑(coeff R n) ((φ₁ + φ₂) * φ₃) = ↑(coeff R n) (φ₁ * φ₃ + φ₂ * φ₃)
Theorem: SubfieldClass.rat_smul_mem
File: Mathlib/FieldTheory/Subfield.lean

tactic: simpa only [Rat.smul_def] using mul_mem (coe_rat_mem s a) x.prop
state_before: K : Type u
L : Type v
M : Type w
inst✝³ : Field K
inst✝² : Field L
inst✝¹ : Field M
S : Type u_1
inst✝ : SetLike S K
h : SubfieldClass S K
s : S
a : ℚ
x : { x // x ∈ s }
⊢ a • ↑x ∈ s
Theorem: Multiset.mem_sub_of_nodup
File: Mathlib/Data/Multiset/Nodup.lean

tactic: refine' count_eq_zero.1 _ h
state_before: α : Type u_1
β : Type ?u.20962
γ : Type ?u.20965
r : α → α → Prop
s✝ t✝ : Multiset α
a✝ : α
inst✝ : DecidableEq α
a : α
s t : Multiset α
d : Nodup s
h : a ∈ s - t
h' : a ∈ t
⊢ False

tactic: rw [count_sub a s t, tsub_eq_zero_iff_le]
state_before: α : Type u_1
β : Type ?u.20962
γ : Type ?u.20965
r : α → α → Prop
s✝ t✝ : Multiset α
a✝ : α
inst✝ : DecidableEq α
a : α
s t : Multiset α
d : Nodup s
h : a ∈ s - t
h' : a ∈ t
⊢ count a (s - t) = 0

tactic: exact le_trans (nodup_iff_count_le_one.1 d _) (count_pos.2 h')
state_before: α : Type u_1
β : Type ?u.20962
γ : Type ?u.20965
r : α → α → Prop
s✝ t✝ : Multiset α
a✝ : α
inst✝ : DecidableEq α
a : α
s t : Multiset α
d : Nodup s
h : a ∈ s - t
h' : a ∈ t
⊢ count a s ≤ count a t
Theorem: Dense.Ioi_eq_biUnion
File: Mathlib/Topology/Order/Basic.lean

tactic: refine Subset.antisymm (fun z hz ↦ ?_) (iUnion₂_subset fun y hy ↦ Ioi_subset_Ioi (le_of_lt hy.2))
state_before: α : Type u
β : Type v
γ : Type w
inst✝³ : TopologicalSpace α
inst✝² : LinearOrder α
inst✝¹ : OrderClosedTopology α
f g : β → α
inst✝ : DenselyOrdered α
s : Set α
hs : Dense s
x : α
⊢ Ioi x = ⋃ (y : α) (_ : y ∈ s ∩ Ioi x), Ioi y

tactic: rcases hs.exists_between hz with ⟨y, hys, hxy, hyz⟩
state_before: α : Type u
β : Type v
γ : Type w
inst✝³ : TopologicalSpace α
inst✝² : LinearOrder α
inst✝¹ : OrderClosedTopology α
f g : β → α
inst✝ : DenselyOrdered α
s : Set α
hs : Dense s
x z : α
hz : z ∈ Ioi x
⊢ z ∈ ⋃ (y : α) (_ : y ∈ s ∩ Ioi x), Ioi y

tactic: exact mem_iUnion₂.2 ⟨y, ⟨hys, hxy⟩, hyz⟩
state_before: case intro.intro.intro
α : Type u
β : Type v
γ : Type w
inst✝³ : TopologicalSpace α
inst✝² : LinearOrder α
inst✝¹ : OrderClosedTopology α
f g : β → α
inst✝ : DenselyOrdered α
s : Set α
hs : Dense s
x z : α
hz : z ∈ Ioi x
y : α
hys : y ∈ s
hxy : x < y
hyz : y < z
⊢ z ∈ ⋃ (y : α) (_ : y ∈ s ∩ Ioi x), Ioi y
Theorem: Multiset.prod_hom
File: Mathlib/Algebra/BigOperators/Multiset/Basic.lean

tactic: simp only [l.prod_hom f, quot_mk_to_coe, coe_map, coe_prod]
state_before: ι : Type ?u.39786
α : Type u_2
β : Type u_1
γ : Type ?u.39795
inst✝² : CommMonoid α
s✝ t : Multiset α
a : α
m : Multiset ι
f✝ g : ι → α
inst✝¹ : CommMonoid β
s : Multiset α
F : Type u_3
inst✝ : MonoidHomClass F α β
f : F
l : List α
⊢ prod (map (↑f) (Quotient.mk (List.isSetoid α) l)) = ↑f (prod (Quotient.mk (List.isSetoid α) l))
Theorem: Polynomial.support_C_mul_X'
File: Mathlib/Data/Polynomial/Basic.lean

tactic: simpa only [C_mul_X_eq_monomial] using support_monomial' 1 c
state_before: R : Type u
a b : R
m n : ℕ
inst✝ : Semiring R
p q : R[X]
c : R
⊢ support (↑C c * X) ⊆ {1}
Theorem: Zsqrtd.exists_coprime_of_gcd_pos
File: Mathlib/NumberTheory/Zsqrtd/Basic.lean

tactic: obtain ⟨re, im, H1, Hre, Him⟩ := Int.exists_gcd_one hgcd
state_before: d : ℤ
a : ℤ√d
hgcd : 0 < Int.gcd a.re a.im
⊢ ∃ b, a = ↑↑(Int.gcd a.re a.im) * b ∧ IsCoprime b.re b.im

tactic: rw [mul_comm] at Hre Him
state_before: case intro.intro.intro.intro
d : ℤ
a : ℤ√d
hgcd : 0 < Int.gcd a.re a.im
re im : ℤ
H1 : Int.gcd re im = 1
Hre : a.re = re * ↑(Int.gcd a.re a.im)
Him : a.im = im * ↑(Int.gcd a.re a.im)
⊢ ∃ b, a = ↑↑(Int.gcd a.re a.im) * b ∧ IsCoprime b.re b.im

tactic: refine' ⟨⟨re, im⟩, _, _⟩
state_before: case intro.intro.intro.intro
d : ℤ
a : ℤ√d
hgcd : 0 < Int.gcd a.re a.im
re im : ℤ
H1 : Int.gcd re im = 1
Hre : a.re = ↑(Int.gcd a.re a.im) * re
Him : a.im = ↑(Int.gcd a.re a.im) * im
⊢ ∃ b, a = ↑↑(Int.gcd a.re a.im) * b ∧ IsCoprime b.re b.im

tactic: rw [smul_val, ext, ← Hre, ← Him]
state_before: case intro.intro.intro.intro.refine'_1
d : ℤ
a : ℤ√d
hgcd : 0 < Int.gcd a.re a.im
re im : ℤ
H1 : Int.gcd re im = 1
Hre : a.re = ↑(Int.gcd a.re a.im) * re
Him : a.im = ↑(Int.gcd a.re a.im) * im
⊢ a = ↑↑(Int.gcd a.re a.im) * { re := re, im := im }

tactic: constructor <;> rfl
state_before: case intro.intro.intro.intro.refine'_1
d : ℤ
a : ℤ√d
hgcd : 0 < Int.gcd a.re a.im
re im : ℤ
H1 : Int.gcd re im = 1
Hre : a.re = ↑(Int.gcd a.re a.im) * re
Him : a.im = ↑(Int.gcd a.re a.im) * im
⊢ a.re = { re := a.re, im := a.im }.re ∧ a.im = { re := a.re, im := a.im }.im

tactic: rw [← Int.gcd_eq_one_iff_coprime, H1]
state_before: case intro.intro.intro.intro.refine'_2
d : ℤ
a : ℤ√d
hgcd : 0 < Int.gcd a.re a.im
re im : ℤ
H1 : Int.gcd re im = 1
Hre : a.re = ↑(Int.gcd a.re a.im) * re
Him : a.im = ↑(Int.gcd a.re a.im) * im
⊢ IsCoprime { re := re, im := im }.re { re := re, im := im }.im