tasksource/leandojo huggingface dataset:
Theorem: PowerSeries.X_pow_order_dvd
File: Mathlib/RingTheory/PowerSeries/Basic.lean

tactic: refine' ⟨PowerSeries.mk fun n => coeff R (n + (order φ).get h) φ, _⟩
state_before: R : Type u_1
inst✝ : Semiring R
φ : PowerSeries R
h : (order φ).Dom
⊢ X ^ Part.get (order φ) h ∣ φ

tactic: ext n
state_before: R : Type u_1
inst✝ : Semiring R
φ : PowerSeries R
h : (order φ).Dom
⊢ φ = X ^ Part.get (order φ) h * mk fun n => ↑(coeff R (n + Part.get (order φ) h)) φ

tactic: simp only [coeff_mul, coeff_X_pow, coeff_mk, boole_mul, Finset.sum_ite,
  Finset.Nat.filter_fst_eq_antidiagonal, Finset.sum_const_zero, add_zero]
state_before: case h
R : Type u_1
inst✝ : Semiring R
φ : PowerSeries R
h : (order φ).Dom
n : ℕ
⊢ ↑(coeff R n) φ = ↑(coeff R n) (X ^ Part.get (order φ) h * mk fun n => ↑(coeff R (n + Part.get (order φ) h)) φ)

tactic: split_ifs with hn
state_before: case h
R : Type u_1
inst✝ : Semiring R
φ : PowerSeries R
h : (order φ).Dom
n : ℕ
⊢ ↑(coeff R n) φ =
    ∑ x in if Part.get (order φ) h ≤ n then {(Part.get (order φ) h, n - Part.get (order φ) h)} else ∅,
      ↑(coeff R (x.snd + Part.get (order φ) h)) φ

tactic: simp [tsub_add_cancel_of_le hn]
state_before: case h.inl
R : Type u_1
inst✝ : Semiring R
φ : PowerSeries R
h : (order φ).Dom
n : ℕ
hn : Part.get (order φ) h ≤ n
⊢ ↑(coeff R n) φ =
    ∑ x in {(Part.get (order φ) h, n - Part.get (order φ) h)}, ↑(coeff R (x.snd + Part.get (order φ) h)) φ

tactic: simp only [Finset.sum_empty]
state_before: case h.inr
R : Type u_1
inst✝ : Semiring R
φ : PowerSeries R
h : (order φ).Dom
n : ℕ
hn : ¬Part.get (order φ) h ≤ n
⊢ ↑(coeff R n) φ = ∑ x in ∅, ↑(coeff R (x.snd + Part.get (order φ) h)) φ

tactic: refine' coeff_of_lt_order _ _
state_before: case h.inr
R : Type u_1
inst✝ : Semiring R
φ : PowerSeries R
h : (order φ).Dom
n : ℕ
hn : ¬Part.get (order φ) h ≤ n
⊢ ↑(coeff R n) φ = 0

tactic: simpa [PartENat.coe_lt_iff] using fun _ => hn
state_before: case h.inr
R : Type u_1
inst✝ : Semiring R
φ : PowerSeries R
h : (order φ).Dom
n : ℕ
hn : ¬Part.get (order φ) h ≤ n
⊢ ↑n < order φ
Theorem: MeasureTheory.integral_smul_eq_self
File: Mathlib/MeasureTheory/Group/Integration.lean

tactic: have h : MeasurableEmbedding fun x : α => g • x := (MeasurableEquiv.smul g).measurableEmbedding
state_before: 𝕜 : Type ?u.84709
M : Type ?u.84712
α : Type u_1
G : Type u_2
E : Type u_3
F : Type ?u.84724
inst✝⁹ : MeasurableSpace G
inst✝⁸ : NormedAddCommGroup E
inst✝⁷ : NormedSpace ℝ E
inst✝⁶ : CompleteSpace E
inst✝⁵ : NormedAddCommGroup F
μ✝ : Measure G
f✝ : G → E
g✝ : G
inst✝⁴ : Group G
inst✝³ : MeasurableSpace α
inst✝² : MulAction G α
inst✝¹ : MeasurableSMul G α
μ : Measure α
inst✝ : SMulInvariantMeasure G α μ
f : α → E
g : G
⊢ (∫ (x : α), f (g • x) ∂μ) = ∫ (x : α), f x ∂μ

tactic: rw [← h.integral_map, map_smul]
state_before: 𝕜 : Type ?u.84709
M : Type ?u.84712
α : Type u_1
G : Type u_2
E : Type u_3
F : Type ?u.84724
inst✝⁹ : MeasurableSpace G
inst✝⁸ : NormedAddCommGroup E
inst✝⁷ : NormedSpace ℝ E
inst✝⁶ : CompleteSpace E
inst✝⁵ : NormedAddCommGroup F
μ✝ : Measure G
f✝ : G → E
g✝ : G
inst✝⁴ : Group G
inst✝³ : MeasurableSpace α
inst✝² : MulAction G α
inst✝¹ : MeasurableSMul G α
μ : Measure α
inst✝ : SMulInvariantMeasure G α μ
f : α → E
g : G
h : MeasurableEmbedding fun x => g • x
⊢ (∫ (x : α), f (g • x) ∂μ) = ∫ (x : α), f x ∂μ
Theorem: TrivSqZeroExt.fst_exp
File: Mathlib/Analysis/NormedSpace/TrivSqZeroExt.lean

tactic: rw [exp_def, fst_add, fst_inl, fst_inr, add_zero]
state_before: 𝕜 : Type u_3
R : Type u_1
M : Type u_2
inst✝¹⁵ : IsROrC 𝕜
inst✝¹⁴ : NormedCommRing R
inst✝¹³ : AddCommGroup M
inst✝¹² : NormedAlgebra 𝕜 R
inst✝¹¹ : Module R M
inst✝¹⁰ : Module Rᵐᵒᵖ M
inst✝⁹ : IsCentralScalar R M
inst✝⁸ : Module 𝕜 M
inst✝⁷ : IsScalarTower 𝕜 R M
inst✝⁶ : TopologicalSpace M
inst✝⁵ : TopologicalRing R
inst✝⁴ : TopologicalAddGroup M
inst✝³ : ContinuousSMul R M
inst✝² : CompleteSpace R
inst✝¹ : T2Space R
inst✝ : T2Space M
x : tsze R M
⊢ fst (exp 𝕜 x) = exp 𝕜 (fst x)
Theorem: Finset.fold_max_add
File: Mathlib/Data/Finset/Fold.lean

tactic: classical
  induction' s using Finset.induction_on with a s _ ih <;> simp [*, max_add_add_right]
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.73169
op : β → β → β
hc : IsCommutative β op
ha : IsAssociative β op
f : α → β
b : β
s✝ : Finset α
a : α
inst✝² : LinearOrder β
c : β
inst✝¹ : Add β
inst✝ : CovariantClass β β (Function.swap fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
n : WithBot β
s : Finset α
⊢ fold max ⊥ (fun x => ↑(f x) + n) s = fold max ⊥ (WithBot.some ∘ f) s + n

tactic: induction' s using Finset.induction_on with a s _ ih <;> simp [*, max_add_add_right]
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.73169
op : β → β → β
hc : IsCommutative β op
ha : IsAssociative β op
f : α → β
b : β
s✝ : Finset α
a : α
inst✝² : LinearOrder β
c : β
inst✝¹ : Add β
inst✝ : CovariantClass β β (Function.swap fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
n : WithBot β
s : Finset α
⊢ fold max ⊥ (fun x => ↑(f x) + n) s = fold max ⊥ (WithBot.some ∘ f) s + n
Theorem: Finset.affineCombination_subtype_eq_filter
File: Mathlib/LinearAlgebra/AffineSpace/Combination.lean

tactic: rw [affineCombination_apply, affineCombination_apply, weightedVSubOfPoint_subtype_eq_filter]
state_before: k : Type u_3
V : Type u_4
P : Type u_2
inst✝³ : Ring k
inst✝² : AddCommGroup V
inst✝¹ : Module k V
S : AffineSpace V P
ι : Type u_1
s : Finset ι
ι₂ : Type ?u.365709
s₂ : Finset ι₂
w : ι → k
p : ι → P
pred : ι → Prop
inst✝ : DecidablePred pred
⊢ (↑(affineCombination k (Finset.subtype pred s) fun i => p ↑i) fun i => w ↑i) =
    ↑(affineCombination k (filter pred s) p) w
Theorem: MeasureTheory.unifIntegrable_const
File: Mathlib/MeasureTheory/Function/UniformIntegrable.lean

tactic: intro ε hε
state_before: α : Type u_2
β : Type u_1
ι : Type u_3
m : MeasurableSpace α
μ : Measure α
inst✝ : NormedAddCommGroup β
p : ℝ≥0∞
f g : α → β
hp : 1 ≤ p
hp_ne_top : p ≠ ⊤
hg : Memℒp g p
⊢ UnifIntegrable (fun x => g) p μ

tactic: obtain ⟨δ, hδ_pos, hgδ⟩ := hg.snorm_indicator_le μ hp hp_ne_top hε
state_before: α : Type u_2
β : Type u_1
ι : Type u_3
m : MeasurableSpace α
μ : Measure α
inst✝ : NormedAddCommGroup β
p : ℝ≥0∞
f g : α → β
hp : 1 ≤ p
hp_ne_top : p ≠ ⊤
hg : Memℒp g p
ε : ℝ
hε : 0 < ε
⊢ ∃ δ x,
    ∀ (i : ι) (s : Set α),
      MeasurableSet s → ↑↑μ s ≤ ENNReal.ofReal δ → snorm (Set.indicator s ((fun x => g) i)) p μ ≤ ENNReal.ofReal ε

tactic: exact ⟨δ, hδ_pos, fun _ => hgδ⟩
state_before: case intro.intro
α : Type u_2
β : Type u_1
ι : Type u_3
m : MeasurableSpace α
μ : Measure α
inst✝ : NormedAddCommGroup β
p : ℝ≥0∞
f g : α → β
hp : 1 ≤ p
hp_ne_top : p ≠ ⊤
hg : Memℒp g p
ε : ℝ
hε : 0 < ε
δ : ℝ
hδ_pos : 0 < δ
hgδ : ∀ (s : Set α), MeasurableSet s → ↑↑μ s ≤ ENNReal.ofReal δ → snorm (Set.indicator s g) p μ ≤ ENNReal.ofReal ε
⊢ ∃ δ x,
    ∀ (i : ι) (s : Set α),
      MeasurableSet s → ↑↑μ s ≤ ENNReal.ofReal δ → snorm (Set.indicator s ((fun x => g) i)) p μ ≤ ENNReal.ofReal ε
Theorem: Real.logb_inv
File: Mathlib/Analysis/SpecialFunctions/Log/Base.lean

tactic: simp [logb, neg_div]
state_before: b x✝ y x : ℝ
⊢ logb b x⁻¹ = -logb b x
Theorem: zpow_two_nonneg
File: Mathlib/Algebra/Order/Field/Power.lean

tactic: convert zpow_bit0_nonneg a 1
state_before: α : Type u_1
inst✝ : LinearOrderedField α
a✝ b c d : α
n : ℤ
a : α
⊢ 0 ≤ a ^ 2
Theorem: List.mem_pure
File: Mathlib/Data/List/Basic.lean

tactic: simp
state_before: ι : Type ?u.23772
α✝ : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α✝
α : Type u_1
x y : α
⊢ x ∈ [y] ↔ x = y
Theorem: Nat.mul_div_eq_iff_dvd
File: Mathlib/Data/Nat/Order/Lemmas.lean

tactic: rw [div_add_mod]
state_before: a b m n✝ k n d : ℕ
⊢ d * (n / d) = n ↔ d * (n / d) = d * (n / d) + n % d

tactic: rw [self_eq_add_right, dvd_iff_mod_eq_zero]
state_before: a b m n✝ k n d : ℕ
⊢ d * (n / d) = d * (n / d) + n % d ↔ d ∣ n
Theorem: Int.mul_le_mul_of_nonneg_left
File: Std/Data/Int/Lemmas.lean

tactic: if hba : b ≤ a then rw [Int.le_antisymm hba h₁]; apply Int.le_refl else
if hc0 : c ≤ 0 then simp [Int.le_antisymm hc0 h₂, Int.zero_mul] else
exact Int.le_of_lt <| Int.mul_lt_mul_of_pos_left
  (Int.lt_iff_le_not_le.2 ⟨h₁, hba⟩) (Int.lt_iff_le_not_le.2 ⟨h₂, hc0⟩)
state_before: a b c : Int
h₁ : a ≤ b
h₂ : 0 ≤ c
⊢ c * a ≤ c * b

tactic: rw [Int.le_antisymm hba h₁]
state_before: a b c : Int
h₁ : a ≤ b
h₂ : 0 ≤ c
hba : b ≤ a
⊢ c * a ≤ c * b

tactic: apply Int.le_refl
state_before: a b c : Int
h₁ : a ≤ b
h₂ : 0 ≤ c
hba : b ≤ a
⊢ c * a ≤ c * a

tactic: if hc0 : c ≤ 0 then simp [Int.le_antisymm hc0 h₂, Int.zero_mul] else
exact Int.le_of_lt <| Int.mul_lt_mul_of_pos_left
  (Int.lt_iff_le_not_le.2 ⟨h₁, hba⟩) (Int.lt_iff_le_not_le.2 ⟨h₂, hc0⟩)
state_before: a b c : Int
h₁ : a ≤ b
h₂ : 0 ≤ c
hba : ¬b ≤ a
⊢ c * a ≤ c * b

tactic: simp [Int.le_antisymm hc0 h₂, Int.zero_mul]
state_before: a b c : Int
h₁ : a ≤ b
h₂ : 0 ≤ c
hba : ¬b ≤ a
hc0 : c ≤ 0
⊢ c * a ≤ c * b

tactic: exact Int.le_of_lt <| Int.mul_lt_mul_of_pos_left
  (Int.lt_iff_le_not_le.2 ⟨h₁, hba⟩) (Int.lt_iff_le_not_le.2 ⟨h₂, hc0⟩)
state_before: a b c : Int
h₁ : a ≤ b
h₂ : 0 ≤ c
hba : ¬b ≤ a
hc0 : ¬c ≤ 0
⊢ c * a ≤ c * b
Theorem: lucas_lehmer_sufficiency
File: Mathlib/NumberTheory/LucasLehmer.lean

tactic: let p' := p - 2
state_before: p : ℕ
w : 1 < p
⊢ LucasLehmerTest p → Nat.Prime (mersenne p)

tactic: have z : p = p' + 2 := (tsub_eq_iff_eq_add_of_le w.nat_succ_le).mp rfl
state_before: p : ℕ
w : 1 < p
p' : ℕ := p - 2
⊢ LucasLehmerTest p → Nat.Prime (mersenne p)

tactic: have w : 1 < p' + 2 := Nat.lt_of_sub_eq_succ rfl
state_before: p : ℕ
w : 1 < p
p' : ℕ := p - 2
z : p = p' + 2
⊢ LucasLehmerTest p → Nat.Prime (mersenne p)

tactic: contrapose
state_before: p : ℕ
w✝ : 1 < p
p' : ℕ := p - 2
z : p = p' + 2
w : 1 < p' + 2
⊢ LucasLehmerTest p → Nat.Prime (mersenne p)

tactic: intro a t
state_before: p : ℕ
w✝ : 1 < p
p' : ℕ := p - 2
z : p = p' + 2
w : 1 < p' + 2
⊢ ¬Nat.Prime (mersenne p) → ¬LucasLehmerTest p

tactic: rw [z] at a
state_before: p : ℕ
w✝ : 1 < p
p' : ℕ := p - 2
z : p = p' + 2
w : 1 < p' + 2
a : ¬Nat.Prime (mersenne p)
t : LucasLehmerTest p
⊢ False

tactic: rw [z] at t
state_before: p : ℕ
w✝ : 1 < p
p' : ℕ := p - 2
z : p = p' + 2
w : 1 < p' + 2
a : ¬Nat.Prime (mersenne (p' + 2))
t : LucasLehmerTest p
⊢ False

tactic: have h₁ := order_ineq p' t
state_before: p : ℕ
w✝ : 1 < p
p' : ℕ := p - 2
z : p = p' + 2
w : 1 < p' + 2
a : ¬Nat.Prime (mersenne (p' + 2))
t : LucasLehmerTest (p' + 2)
⊢ False

tactic: have h₂ := Nat.minFac_sq_le_self (mersenne_pos (Nat.lt_of_succ_lt w)) a
state_before: p : ℕ
w✝ : 1 < p
p' : ℕ := p - 2
z : p = p' + 2
w : 1 < p' + 2
a : ¬Nat.Prime (mersenne (p' + 2))
t : LucasLehmerTest (p' + 2)
h₁ : 2 ^ (p' + 2) < ↑(q (p' + 2)) ^ 2
⊢ False

tactic: have h := lt_of_lt_of_le h₁ h₂
state_before: p : ℕ
w✝ : 1 < p
p' : ℕ := p - 2
z : p = p' + 2
w : 1 < p' + 2
a : ¬Nat.Prime (mersenne (p' + 2))
t : LucasLehmerTest (p' + 2)
h₁ : 2 ^ (p' + 2) < ↑(q (p' + 2)) ^ 2
h₂ : Nat.minFac (mersenne (p' + 2)) ^ 2 ≤ mersenne (p' + 2)
⊢ False

tactic: exact not_lt_of_ge (Nat.sub_le _ _) h
state_before: p : ℕ
w✝ : 1 < p
p' : ℕ := p - 2
z : p = p' + 2
w : 1 < p' + 2
a : ¬Nat.Prime (mersenne (p' + 2))
t : LucasLehmerTest (p' + 2)
h₁ : 2 ^ (p' + 2) < ↑(q (p' + 2)) ^ 2
h₂ : Nat.minFac (mersenne (p' + 2)) ^ 2 ≤ mersenne (p' + 2)
h : 2 ^ (p' + 2) < mersenne (p' + 2)
⊢ False
Theorem: CompleteLattice.Independent.comp'
File: Mathlib/Order/SupIndep.lean

tactic: intro i
state_before: α : Type u_3
β : Type ?u.52493
ι✝ : Type ?u.52496
ι'✝ : Type ?u.52499
inst✝ : CompleteLattice α
s : Set α
hs : SetIndependent s
t✝ : ι✝ → α
ht✝ : Independent t✝
ι : Sort u_1
ι' : Sort u_2
t : ι → α
f : ι' → ι
ht : Independent (t ∘ f)
hf : Surjective f
⊢ Independent t

tactic: obtain ⟨i', rfl⟩ := hf i
state_before: α : Type u_3
β : Type ?u.52493
ι✝ : Type ?u.52496
ι'✝ : Type ?u.52499
inst✝ : CompleteLattice α
s : Set α
hs : SetIndependent s
t✝ : ι✝ → α
ht✝ : Independent t✝
ι : Sort u_1
ι' : Sort u_2
t : ι → α
f : ι' → ι
ht : Independent (t ∘ f)
hf : Surjective f
i : ι
⊢ Disjoint (t i) (⨆ (j : ι) (_ : j ≠ i), t j)

tactic: rw [← hf.iSup_comp]
state_before: case intro
α : Type u_3
β : Type ?u.52493
ι✝ : Type ?u.52496
ι'✝ : Type ?u.52499
inst✝ : CompleteLattice α
s : Set α
hs : SetIndependent s
t✝ : ι✝ → α
ht✝ : Independent t✝
ι : Sort u_1
ι' : Sort u_2
t : ι → α
f : ι' → ι
ht : Independent (t ∘ f)
hf : Surjective f
i' : ι'
⊢ Disjoint (t (f i')) (⨆ (j : ι) (_ : j ≠ f i'), t j)

tactic: exact (ht i').mono_right (biSup_mono fun j' hij => mt (congr_arg f) hij)
state_before: case intro
α : Type u_3
β : Type ?u.52493
ι✝ : Type ?u.52496
ι'✝ : Type ?u.52499
inst✝ : CompleteLattice α
s : Set α
hs : SetIndependent s
t✝ : ι✝ → α
ht✝ : Independent t✝
ι : Sort u_1
ι' : Sort u_2
t : ι → α
f : ι' → ι
ht : Independent (t ∘ f)
hf : Surjective f
i' : ι'
⊢ Disjoint (t (f i')) (⨆ (x : ι') (_ : f x ≠ f i'), t (f x))
Theorem: acc_iff_cluster
File: Mathlib/Topology/Basic.lean

tactic: rw [AccPt, nhdsWithin, ClusterPt, inf_assoc]
state_before: α : Type u
β : Type v
ι : Sort w
a : α
s s₁ s₂ t : Set α
p p₁ p₂ : α → Prop
inst✝ : TopologicalSpace α
x : α
F : Filter α
⊢ AccPt x F ↔ ClusterPt x (𝓟 ({x}ᶜ) ⊓ F)
Theorem: Cardinal.mk_finsupp_lift_of_infinite'
File: Mathlib/SetTheory/Cardinal/Ordinal.lean

tactic: cases fintypeOrInfinite α
state_before: α : Type u
β : Type v
inst✝² : Nonempty α
inst✝¹ : Zero β
inst✝ : Infinite β
⊢ (#α →₀ β) = max (lift (#α)) (lift (#β))

tactic: rw [mk_finsupp_lift_of_fintype]
state_before: case inl
α : Type u
β : Type v
inst✝² : Nonempty α
inst✝¹ : Zero β
inst✝ : Infinite β
val✝ : Fintype α
⊢ (#α →₀ β) = max (lift (#α)) (lift (#β))

tactic: have : ℵ₀ ≤ (#β).lift := aleph0_le_lift.2 (aleph0_le_mk β)
state_before: case inl
α : Type u
β : Type v
inst✝² : Nonempty α
inst✝¹ : Zero β
inst✝ : Infinite β
val✝ : Fintype α
⊢ lift (#β) ^ Fintype.card α = max (lift (#α)) (lift (#β))

tactic: rw [max_eq_right (le_trans _ this), power_nat_eq this]
state_before: case inl
α : Type u
β : Type v
inst✝² : Nonempty α
inst✝¹ : Zero β
inst✝ : Infinite β
val✝ : Fintype α
this : ℵ₀ ≤ lift (#β)
⊢ lift (#β) ^ Fintype.card α = max (lift (#α)) (lift (#β))

tactic: exacts [Fintype.card_pos, lift_le_aleph0.2 (lt_aleph0_of_finite _).le]
state_before: case inl
α : Type u
β : Type v
inst✝² : Nonempty α
inst✝¹ : Zero β
inst✝ : Infinite β
val✝ : Fintype α
this : ℵ₀ ≤ lift (#β)
⊢ 1 ≤ Fintype.card α

α : Type u
β : Type v
inst✝² : Nonempty α
inst✝¹ : Zero β
inst✝ : Infinite β
val✝ : Fintype α
this : ℵ₀ ≤ lift (#β)
⊢ lift (#α) ≤ ℵ₀

tactic: apply mk_finsupp_lift_of_infinite
state_before: case inr
α : Type u
β : Type v
inst✝² : Nonempty α
inst✝¹ : Zero β
inst✝ : Infinite β
val✝ : Infinite α
⊢ (#α →₀ β) = max (lift (#α)) (lift (#β))
Theorem: Nat.Partrec'.tail
File: Mathlib/Computability/Halting.lean

tactic: simp
state_before: n : ℕ
f : Vector ℕ n →. ℕ
hf : Partrec' f
v : Vector ℕ (succ n)
⊢ (mOfFn fun i => (↑fun v => Vector.get v (Fin.succ i)) v) >>= f = f (Vector.tail v)

tactic: rw [← ofFn_get v.tail]
state_before: n : ℕ
f : Vector ℕ n →. ℕ
hf : Partrec' f
v : Vector ℕ (succ n)
⊢ f (ofFn fun i => Vector.get v (Fin.succ i)) = f (Vector.tail v)

tactic: congr
state_before: n : ℕ
f : Vector ℕ n →. ℕ
hf : Partrec' f
v : Vector ℕ (succ n)
⊢ f (ofFn fun i => Vector.get v (Fin.succ i)) = f (ofFn (Vector.get (Vector.tail v)))

tactic: funext i
state_before: case e_a.e_a
n : ℕ
f : Vector ℕ n →. ℕ
hf : Partrec' f
v : Vector ℕ (succ n)
⊢ (fun i => Vector.get v (Fin.succ i)) = Vector.get (Vector.tail v)

tactic: simp
state_before: case e_a.e_a.h
n : ℕ
f : Vector ℕ n →. ℕ
hf : Partrec' f
v : Vector ℕ (succ n)
i : Fin n
⊢ Vector.get v (Fin.succ i) = Vector.get (Vector.tail v) i
Theorem: Nat.Prime.not_dvd_mul
File: Mathlib/Data/Nat/Prime.lean

tactic: simp [Hm, Hn]
state_before: p m n : ℕ
pp : Prime p
Hm : ¬p ∣ m
Hn : ¬p ∣ n
⊢ ¬(p ∣ m ∨ p ∣ n)
Theorem: edist_congr_right
File: Mathlib/Topology/MetricSpace/EMetricSpace.lean

tactic: apply le_antisymm
state_before: α : Type u
β : Type v
X : Type ?u.5599
inst✝ : PseudoEMetricSpace α
x y z : α
h : edist x y = 0
⊢ edist x z = edist y z

tactic: rw [← zero_add (edist y z), ← h]
state_before: case a
α : Type u
β : Type v
X : Type ?u.5599
inst✝ : PseudoEMetricSpace α
x y z : α
h : edist x y = 0
⊢ edist x z ≤ edist y z

tactic: apply edist_triangle
state_before: case a
α : Type u
β : Type v
X : Type ?u.5599
inst✝ : PseudoEMetricSpace α
x y z : α
h : edist x y = 0
⊢ edist x z ≤ edist x y + edist y z

tactic: rw [edist_comm] at h
state_before: case a
α : Type u
β : Type v
X : Type ?u.5599
inst✝ : PseudoEMetricSpace α
x y z : α
h : edist x y = 0
⊢ edist y z ≤ edist x z

tactic: rw [← zero_add (edist x z), ← h]
state_before: case a
α : Type u
β : Type v
X : Type ?u.5599
inst✝ : PseudoEMetricSpace α
x y z : α
h : edist y x = 0
⊢ edist y z ≤ edist x z

tactic: apply edist_triangle
state_before: case a
α : Type u
β : Type v
X : Type ?u.5599
inst✝ : PseudoEMetricSpace α
x y z : α
h : edist y x = 0
⊢ edist y z ≤ edist y x + edist x z
Theorem: PFunctor.M.ichildren_mk
File: Mathlib/Data/PFunctor/Univariate/M.lean

tactic: dsimp only [ichildren, PFunctor.Obj.iget]
state_before: F : PFunctor
X : Type ?u.26833
f : X → Obj F X
inst✝¹ : DecidableEq F.A
inst✝ : Inhabited (M F)
x : Obj F (M F)
i : IdxCat F
⊢ ichildren i (M.mk x) = Obj.iget x i

tactic: congr with h
state_before: F : PFunctor
X : Type ?u.26833
f : X → Obj F X
inst✝¹ : DecidableEq F.A
inst✝ : Inhabited (M F)
x : Obj F (M F)
i : IdxCat F
⊢ (if H' : i.fst = head (M.mk x) then children (M.mk x) (cast (_ : B F i.fst = B F (head (M.mk x))) i.snd)
    else default) =
    if h : i.fst = x.fst then Sigma.snd x (cast (_ : B F i.fst = B F x.fst) i.snd) else default
Theorem: CategoryTheory.epi_from_simple_zero_of_not_iso
File: Mathlib/CategoryTheory/Simple.lean

tactic: classical
  by_contra h
  exact w (isIso_of_epi_of_nonzero h)
state_before: C : Type u
inst✝³ : Category C
inst✝² : Abelian C
X Y : C
inst✝¹ : Simple X
f : X ⟶ Y
inst✝ : Epi f
w : IsIso f → False
⊢ f = 0

tactic: by_contra h
state_before: C : Type u
inst✝³ : Category C
inst✝² : Abelian C
X Y : C
inst✝¹ : Simple X
f : X ⟶ Y
inst✝ : Epi f
w : IsIso f → False
⊢ f = 0

tactic: exact w (isIso_of_epi_of_nonzero h)
state_before: C : Type u
inst✝³ : Category C
inst✝² : Abelian C
X Y : C
inst✝¹ : Simple X
f : X ⟶ Y
inst✝ : Epi f
w : IsIso f → False
h : ¬f = 0
⊢ False
Theorem: Finset.Icc_erase_left
File: Mathlib/Data/Finset/LocallyFinite.lean

tactic: simp [← coe_inj]
state_before: ι : Type ?u.72862
α : Type u_1
inst✝² : PartialOrder α
inst✝¹ : LocallyFiniteOrder α
a✝ b✝ c : α
inst✝ : DecidableEq α
a b : α
⊢ erase (Icc a b) a = Ioc a b
Theorem: Equiv.Perm.cycleFactorsFinset_eq_empty_iff
File: Mathlib/GroupTheory/Perm/Cycle/Basic.lean

tactic: simpa [cycleFactorsFinset_eq_finset] using eq_comm
state_before: ι : Type ?u.2748424
α : Type u_1
β : Type ?u.2748430
inst✝¹ : DecidableEq α
inst✝ : Fintype α
f✝ f : Perm α
⊢ cycleFactorsFinset f = ∅ ↔ f = 1
Theorem: LinearMap.isUnit_iff_range_eq_top
File: Mathlib/LinearAlgebra/FiniteDimensional.lean

tactic: rw [isUnit_iff_ker_eq_bot, ker_eq_bot_iff_range_eq_top]
state_before: K : Type u
V : Type v
inst✝³ : DivisionRing K
inst✝² : AddCommGroup V
inst✝¹ : Module K V
inst✝ : FiniteDimensional K V
f : V →ₗ[K] V
⊢ IsUnit f ↔ range f = ⊤
Theorem: exists_dist_lt_le
File: Mathlib/Analysis/NormedSpace/Pointwise.lean

tactic: obtain ⟨y, yz, xy⟩ :=
  exists_dist_le_lt hε hδ (show dist z x < δ + ε by simpa only [dist_comm, add_comm] using h)
state_before: 𝕜 : Type ?u.212520
E : Type u_1
inst✝³ : NormedField 𝕜
inst✝² : SeminormedAddCommGroup E
inst✝¹ : NormedSpace 𝕜 E
inst✝ : NormedSpace ℝ E
x y z : E
δ ε : ℝ
hδ : 0 < δ
hε : 0 ≤ ε
h : dist x z < ε + δ
⊢ ∃ y, dist x y < δ ∧ dist y z ≤ ε

tactic: exact ⟨y, by simp [dist_comm x y, dist_comm y z, *]⟩
state_before: case intro.intro
𝕜 : Type ?u.212520
E : Type u_1
inst✝³ : NormedField 𝕜
inst✝² : SeminormedAddCommGroup E
inst✝¹ : NormedSpace 𝕜 E
inst✝ : NormedSpace ℝ E
x y✝ z : E
δ ε : ℝ
hδ : 0 < δ
hε : 0 ≤ ε
h : dist x z < ε + δ
y : E
yz : dist z y ≤ ε
xy : dist y x < δ
⊢ ∃ y, dist x y < δ ∧ dist y z ≤ ε

tactic: simpa only [dist_comm, add_comm] using h
state_before: 𝕜 : Type ?u.212520
E : Type u_1
inst✝³ : NormedField 𝕜
inst✝² : SeminormedAddCommGroup E
inst✝¹ : NormedSpace 𝕜 E
inst✝ : NormedSpace ℝ E
x y z : E
δ ε : ℝ
hδ : 0 < δ
hε : 0 ≤ ε
h : dist x z < ε + δ
⊢ dist z x < δ + ε

tactic: simp [dist_comm x y, dist_comm y z, *]
state_before: 𝕜 : Type ?u.212520
E : Type u_1
inst✝³ : NormedField 𝕜
inst✝² : SeminormedAddCommGroup E
inst✝¹ : NormedSpace 𝕜 E
inst✝ : NormedSpace ℝ E
x y✝ z : E
δ ε : ℝ
hδ : 0 < δ
hε : 0 ≤ ε
h : dist x z < ε + δ
y : E
yz : dist z y ≤ ε
xy : dist y x < δ
⊢ dist x y < δ ∧ dist y z ≤ ε
Theorem: Set.preimage_sub_const_Ici
File: Mathlib/Data/Set/Pointwise/Interval.lean

tactic: simp [sub_eq_add_neg]
state_before: α : Type u_1
inst✝ : OrderedAddCommGroup α
a b c : α
⊢ (fun x => x - a) ⁻¹' Ici b = Ici (b + a)
Theorem: CategoryTheory.Limits.comp_factorThruImage_eq_zero
File: Mathlib/CategoryTheory/Limits/Shapes/ZeroMorphisms.lean

tactic: simp [h]
state_before: C : Type u
inst✝³ : Category C
D : Type u'
inst✝² : Category D
inst✝¹ : HasZeroMorphisms C
X Y Z : C
f : X ⟶ Y
g : Y ⟶ Z
inst✝ : HasImage g
h : f ≫ g = 0
⊢ (f ≫ factorThruImage g) ≫ image.ι g = 0
Theorem: CochainComplex.of_d
File: Mathlib/Algebra/Homology/HomologicalComplex.lean

tactic: dsimp [of]
state_before: ι : Type ?u.215700
V : Type u
inst✝⁴ : Category V
inst✝³ : HasZeroMorphisms V
α : Type u_1
inst✝² : AddRightCancelSemigroup α
inst✝¹ : One α
inst✝ : DecidableEq α
X : α → V
d : (n : α) → X n ⟶ X (n + 1)
sq : ∀ (n : α), d n ≫ d (n + 1) = 0
j : α
⊢ HomologicalComplex.d (of X d sq) j (j + 1) = d j

tactic: rw [if_pos rfl, Category.comp_id]
state_before: ι : Type ?u.215700
V : Type u
inst✝⁴ : Category V
inst✝³ : HasZeroMorphisms V
α : Type u_1
inst✝² : AddRightCancelSemigroup α
inst✝¹ : One α
inst✝ : DecidableEq α
X : α → V
d : (n : α) → X n ⟶ X (n + 1)
sq : ∀ (n : α), d n ≫ d (n + 1) = 0
j : α
⊢ (if j + 1 = j + 1 then d j ≫ 𝟙 (X (j + 1)) else 0) = d j
Theorem: Nat.bit1_div_two
File: Mathlib/Data/Nat/Parity.lean

tactic: rw [← Nat.bit1_eq_bit1, bit1, bit0_eq_two_mul, Nat.two_mul_div_two_add_one_of_odd (odd_bit1 n)]
state_before: m n : ℕ
⊢ bit1 n / 2 = n
Theorem: MeasureTheory.lintegral_trim_ae
File: Mathlib/MeasureTheory/Integral/Lebesgue.lean

tactic: rw [lintegral_congr_ae (ae_eq_of_ae_eq_trim hf.ae_eq_mk), lintegral_congr_ae hf.ae_eq_mk,
  lintegral_trim hm hf.measurable_mk]
state_before: α : Type u_1
β : Type ?u.1823472
γ : Type ?u.1823475
δ : Type ?u.1823478
m m0 : MeasurableSpace α
μ : Measure α
hm : m ≤ m0
f : α → ℝ≥0∞
hf : AEMeasurable f
⊢ (∫⁻ (a : α), f a ∂Measure.trim μ hm) = ∫⁻ (a : α), f a ∂μ
Theorem: convexJoin_assoc
File: Mathlib/Analysis/Convex/Join.lean

tactic: refine' (convexJoin_assoc_aux _ _ _).antisymm _
state_before: ι : Sort ?u.66107
𝕜 : Type u_2
E : Type u_1
inst✝² : LinearOrderedField 𝕜
inst✝¹ : AddCommGroup E
inst✝ : Module 𝕜 E
s✝ t✝ u✝ : Set E
x y : E
s t u : Set E
⊢ convexJoin 𝕜 (convexJoin 𝕜 s t) u = convexJoin 𝕜 s (convexJoin 𝕜 t u)

tactic: simp_rw [convexJoin_comm s, convexJoin_comm _ u]
state_before: ι : Sort ?u.66107
𝕜 : Type u_2
E : Type u_1
inst✝² : LinearOrderedField 𝕜
inst✝¹ : AddCommGroup E
inst✝ : Module 𝕜 E
s✝ t✝ u✝ : Set E
x y : E
s t u : Set E
⊢ convexJoin 𝕜 s (convexJoin 𝕜 t u) ⊆ convexJoin 𝕜 (convexJoin 𝕜 s t) u

tactic: exact convexJoin_assoc_aux _ _ _
state_before: ι : Sort ?u.66107
𝕜 : Type u_2
E : Type u_1
inst✝² : LinearOrderedField 𝕜
inst✝¹ : AddCommGroup E
inst✝ : Module 𝕜 E
s✝ t✝ u✝ : Set E
x y : E
s t u : Set E
⊢ convexJoin 𝕜 (convexJoin 𝕜 u t) s ⊆ convexJoin 𝕜 u (convexJoin 𝕜 t s)
Theorem: Nat.lor'_assoc
File: Mathlib/Data/Nat/Bitwise.lean

tactic: bitwise_assoc_tac
state_before: n m k : ℕ
⊢ lor' (lor' n m) k = lor' n (lor' m k)
Theorem: MulOpposite.op_div
File: Mathlib/Algebra/Group/Opposite.lean

tactic: simp [div_eq_mul_inv]
state_before: α : Type u
inst✝ : DivInvMonoid α
x y : α
⊢ op (x / y) = (op y)⁻¹ * op x