tasksource/leandojo huggingface dataset:
Theorem: Nat.squarefree_mul
File: Mathlib/Data/Nat/Squarefree.lean

tactic: simp only [squarefree_iff_prime_squarefree, ← sq, ← forall_and]
state_before: m n : ℕ
hmn : coprime m n
⊢ Squarefree (m * n) ↔ Squarefree m ∧ Squarefree n

tactic: refine' ball_congr fun p hp => _
state_before: m n : ℕ
hmn : coprime m n
⊢ (∀ (x : ℕ), Prime x → ¬x ^ 2 ∣ m * n) ↔ ∀ (x : ℕ), Prime x → ¬x ^ 2 ∣ m ∧ ¬x ^ 2 ∣ n

tactic: simp only [hmn.isPrimePow_dvd_mul (hp.isPrimePow.pow two_ne_zero), not_or]
state_before: m n : ℕ
hmn : coprime m n
p : ℕ
hp : Prime p
⊢ ¬p ^ 2 ∣ m * n ↔ ¬p ^ 2 ∣ m ∧ ¬p ^ 2 ∣ n
Theorem: Matrix.toLinAlgEquiv_apply
File: Mathlib/LinearAlgebra/Matrix/ToLin.lean

tactic: rw [Matrix.toLinAlgEquiv'_apply, v₁.equivFun_symm_apply]
state_before: R : Type u_2
inst✝⁹ : CommSemiring R
l : Type ?u.2458702
m : Type ?u.2458705
n : Type u_1
inst✝⁸ : Fintype n
inst✝⁷ : Fintype m
inst✝⁶ : DecidableEq n
M₁ : Type u_3
M₂ : Type ?u.2458729
inst✝⁵ : AddCommMonoid M₁
inst✝⁴ : AddCommMonoid M₂
inst✝³ : Module R M₁
inst✝² : Module R M₂
v₁ : Basis n R M₁
v₂ : Basis m R M₂
M₃ : Type ?u.2459231
inst✝¹ : AddCommMonoid M₃
inst✝ : Module R M₃
v₃ : Basis l R M₃
M : Matrix n n R
v : M₁
⊢ ↑(LinearEquiv.symm (Basis.equivFun v₁)) (↑(↑toLinAlgEquiv' M) ↑(↑v₁.repr v)) =
    ∑ j : n, mulVec M (↑(↑v₁.repr v)) j • ↑v₁ j
Theorem: MeasureTheory.Measure.empty_of_count_eq_zero'
File: Mathlib/MeasureTheory/Measure/MeasureSpace.lean

tactic: have hs : s.Finite := by
  rw [← count_apply_lt_top' s_mble, hsc]
  exact WithTop.zero_lt_top
state_before: α : Type u_1
β : Type ?u.381469
γ : Type ?u.381472
δ : Type ?u.381475
ι : Type ?u.381478
R : Type ?u.381481
R' : Type ?u.381484
m0 : MeasurableSpace α
inst✝² : MeasurableSpace β
inst✝¹ : MeasurableSpace γ
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s s' t : Set α
inst✝ : MeasurableSpace α
s_mble : MeasurableSet s
hsc : ↑↑count s = 0
⊢ s = ∅

tactic: simpa [count_apply_finite' hs s_mble] using hsc
state_before: α : Type u_1
β : Type ?u.381469
γ : Type ?u.381472
δ : Type ?u.381475
ι : Type ?u.381478
R : Type ?u.381481
R' : Type ?u.381484
m0 : MeasurableSpace α
inst✝² : MeasurableSpace β
inst✝¹ : MeasurableSpace γ
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s s' t : Set α
inst✝ : MeasurableSpace α
s_mble : MeasurableSet s
hsc : ↑↑count s = 0
hs : Set.Finite s
⊢ s = ∅

tactic: rw [← count_apply_lt_top' s_mble, hsc]
state_before: α : Type u_1
β : Type ?u.381469
γ : Type ?u.381472
δ : Type ?u.381475
ι : Type ?u.381478
R : Type ?u.381481
R' : Type ?u.381484
m0 : MeasurableSpace α
inst✝² : MeasurableSpace β
inst✝¹ : MeasurableSpace γ
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s s' t : Set α
inst✝ : MeasurableSpace α
s_mble : MeasurableSet s
hsc : ↑↑count s = 0
⊢ Set.Finite s

tactic: exact WithTop.zero_lt_top
state_before: α : Type u_1
β : Type ?u.381469
γ : Type ?u.381472
δ : Type ?u.381475
ι : Type ?u.381478
R : Type ?u.381481
R' : Type ?u.381484
m0 : MeasurableSpace α
inst✝² : MeasurableSpace β
inst✝¹ : MeasurableSpace γ
μ μ₁ μ₂ μ₃ ν ν' ν₁ ν₂ : Measure α
s s' t : Set α
inst✝ : MeasurableSpace α
s_mble : MeasurableSet s
hsc : ↑↑count s = 0
⊢ 0 < ⊤
Theorem: List.modifyNth_eq_modifyNthTR
File: Std/Data/List/Basic.lean

tactic: funext α f n l
state_before: ⊢ @modifyNth = @modifyNthTR

tactic: simp [modifyNthTR, modifyNthTR_go_eq]
state_before: case h.h.h.h
α : Type u_1
f : α → α
n : Nat
l : List α
⊢ modifyNth f n l = modifyNthTR f n l
Theorem: CategoryTheory.Limits.kernelComparison_comp_kernel_map
File: Mathlib/CategoryTheory/Limits/Shapes/Kernels.lean

tactic: rw [← G.map_comp, hpq, G.map_comp]
state_before: C : Type u
inst✝⁸ : Category C
inst✝⁷ : HasZeroMorphisms C
X Y : C
f : X ⟶ Y
D : Type u₂
inst✝⁶ : Category D
inst✝⁵ : HasZeroMorphisms D
G : C ⥤ D
inst✝⁴ : Functor.PreservesZeroMorphisms G
X' Y' : C
inst✝³ : HasKernel f
inst✝² : HasKernel (G.map f)
g : X' ⟶ Y'
inst✝¹ : HasKernel g
inst✝ : HasKernel (G.map g)
p : X ⟶ X'
q : Y ⟶ Y'
hpq : f ≫ q = p ≫ g
⊢ G.map f ≫ G.map q = G.map p ≫ G.map g

tactic: rw [← G.map_comp, kernel.condition, G.map_zero]
state_before: C : Type u
inst✝⁸ : Category C
inst✝⁷ : HasZeroMorphisms C
X Y : C
f : X ⟶ Y
D : Type u₂
inst✝⁶ : Category D
inst✝⁵ : HasZeroMorphisms D
G : C ⥤ D
inst✝⁴ : Functor.PreservesZeroMorphisms G
X' Y' : C
inst✝³ : HasKernel f
inst✝² : HasKernel (G.map f)
g : X' ⟶ Y'
inst✝¹ : HasKernel g
inst✝ : HasKernel (G.map g)
p : X ⟶ X'
q : Y ⟶ Y'
hpq : f ≫ q = p ≫ g
⊢ G.map (kernel.ι f) ≫ G.map f = 0

tactic: rw [← G.map_comp, kernel.condition, G.map_zero]
state_before: C : Type u
inst✝⁸ : Category C
inst✝⁷ : HasZeroMorphisms C
X Y : C
f : X ⟶ Y
D : Type u₂
inst✝⁶ : Category D
inst✝⁵ : HasZeroMorphisms D
G : C ⥤ D
inst✝⁴ : Functor.PreservesZeroMorphisms G
X' Y' : C
inst✝³ : HasKernel f
inst✝² : HasKernel (G.map f)
g : X' ⟶ Y'
inst✝¹ : HasKernel g
inst✝ : HasKernel (G.map g)
p : X ⟶ X'
q : Y ⟶ Y'
hpq : f ≫ q = p ≫ g
⊢ G.map (kernel.ι g) ≫ G.map g = 0

tactic: simp only [← G.map_comp]
state_before: C : Type u
inst✝⁸ : Category C
inst✝⁷ : HasZeroMorphisms C
X Y : C
f : X ⟶ Y
D : Type u₂
inst✝⁶ : Category D
inst✝⁵ : HasZeroMorphisms D
G : C ⥤ D
inst✝⁴ : Functor.PreservesZeroMorphisms G
X' Y' : C
inst✝³ : HasKernel f
inst✝² : HasKernel (G.map f)
g : X' ⟶ Y'
inst✝¹ : HasKernel g
inst✝ : HasKernel (G.map g)
p : X ⟶ X'
q : Y ⟶ Y'
hpq : f ≫ q = p ≫ g
⊢ G.map (kernel.ι f) ≫ G.map p = G.map (kernel.map f g p q hpq) ≫ G.map (kernel.ι g)

tactic: exact G.congr_map (kernel.lift_ι _ _ _).symm
state_before: C : Type u
inst✝⁸ : Category C
inst✝⁷ : HasZeroMorphisms C
X Y : C
f : X ⟶ Y
D : Type u₂
inst✝⁶ : Category D
inst✝⁵ : HasZeroMorphisms D
G : C ⥤ D
inst✝⁴ : Functor.PreservesZeroMorphisms G
X' Y' : C
inst✝³ : HasKernel f
inst✝² : HasKernel (G.map f)
g : X' ⟶ Y'
inst✝¹ : HasKernel g
inst✝ : HasKernel (G.map g)
p : X ⟶ X'
q : Y ⟶ Y'
hpq : f ≫ q = p ≫ g
⊢ G.map (kernel.ι f ≫ p) = G.map (kernel.map f g p q hpq ≫ kernel.ι g)
Theorem: norm_div_rev
File: Mathlib/Analysis/Normed/Group/Basic.lean

tactic: simpa only [dist_eq_norm_div] using dist_comm a b
state_before: 𝓕 : Type ?u.53499
𝕜 : Type ?u.53502
α : Type ?u.53505
ι : Type ?u.53508
κ : Type ?u.53511
E : Type u_1
F : Type ?u.53517
G : Type ?u.53520
inst✝² : SeminormedGroup E
inst✝¹ : SeminormedGroup F
inst✝ : SeminormedGroup G
s : Set E
a✝ a₁ a₂ b✝ b₁ b₂ : E
r r₁ r₂ : ℝ
a b : E
⊢ ‖a / b‖ = ‖b / a‖
Theorem: Encodable.mem_decode₂'
File: Mathlib/Logic/Encodable/Basic.lean

tactic: simp [decode₂]
state_before: α : Type u_1
β : Type ?u.4397
inst✝ : Encodable α
n : ℕ
a : α
⊢ a ∈ decode₂ α n ↔ a ∈ decode n ∧ encode a = n

tactic: exact ⟨fun ⟨_, h₁, rfl, h₂⟩ => ⟨h₁, h₂⟩, fun ⟨h₁, h₂⟩ => ⟨_, h₁, rfl, h₂⟩⟩
state_before: α : Type u_1
β : Type ?u.4397
inst✝ : Encodable α
n : ℕ
a : α
⊢ (∃ a_1, decode n = some a_1 ∧ a_1 = a ∧ encode a_1 = n) ↔ decode n = some a ∧ encode a = n
Theorem: Basis.equiv_refl
File: Mathlib/LinearAlgebra/Basis.lean

tactic: simp
state_before: ι : Type u_3
ι' : Type ?u.552010
R : Type u_2
R₂ : Type ?u.552016
K : Type ?u.552019
M : Type u_1
M' : Type ?u.552025
M'' : Type ?u.552028
V : Type u
V' : Type ?u.552033
inst✝⁶ : Semiring R
inst✝⁵ : AddCommMonoid M
inst✝⁴ : Module R M
inst✝³ : AddCommMonoid M'
inst✝² : Module R M'
b b₁ : Basis ι R M
i✝ : ι
c : R
x : M
b' : Basis ι' R M'
e : ι ≃ ι'
inst✝¹ : AddCommMonoid M''
inst✝ : Module R M''
i : ι
⊢ ↑(Basis.equiv b b (Equiv.refl ι)) (↑b i) = ↑(LinearEquiv.refl R M) (↑b i)
Theorem: le_mul_inv_iff_mul_le
File: Mathlib/Algebra/Order/Group/Defs.lean

tactic: rw [inv_mul_cancel_right]
state_before: α : Type u
inst✝² : Group α
inst✝¹ : LE α
inst✝ : CovariantClass α α (swap fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a b c : α
⊢ c * b ≤ a * b⁻¹ * b ↔ c * b ≤ a
Theorem: MeasureTheory.Measure.add_haar_ball_of_pos
File: Mathlib/MeasureTheory/Measure/Lebesgue/EqHaar.lean

tactic: rw [← add_haar_ball_mul_of_pos μ x hr, mul_one]
state_before: E : Type u_1
inst✝⁸ : NormedAddCommGroup E
inst✝⁷ : NormedSpace ℝ E
inst✝⁶ : MeasurableSpace E
inst✝⁵ : BorelSpace E
inst✝⁴ : FiniteDimensional ℝ E
μ : Measure E
inst✝³ : IsAddHaarMeasure μ
F : Type ?u.1980009
inst✝² : NormedAddCommGroup F
inst✝¹ : NormedSpace ℝ F
inst✝ : CompleteSpace F
s : Set E
x : E
r : ℝ
hr : 0 < r
⊢ ↑↑μ (ball x r) = ENNReal.ofReal (r ^ finrank ℝ E) * ↑↑μ (ball 0 1)
Theorem: Matrix.Represents.zero
File: Mathlib/LinearAlgebra/Matrix/Charpoly/LinearMap.lean

tactic: delta Matrix.Represents
state_before: ι : Type u_1
inst✝⁴ : Fintype ι
M : Type u_2
inst✝³ : AddCommGroup M
R : Type u_3
inst✝² : CommRing R
inst✝¹ : Module R M
I : Ideal R
b : ι → M
hb : Submodule.span R (Set.range b) = ⊤
inst✝ : DecidableEq ι
⊢ Represents b 0 0

tactic: rw [map_zero, map_zero]
state_before: ι : Type u_1
inst✝⁴ : Fintype ι
M : Type u_2
inst✝³ : AddCommGroup M
R : Type u_3
inst✝² : CommRing R
inst✝¹ : Module R M
I : Ideal R
b : ι → M
hb : Submodule.span R (Set.range b) = ⊤
inst✝ : DecidableEq ι
⊢ ↑(PiToModule.fromMatrix R b) 0 = ↑(PiToModule.fromEnd R b) 0
Theorem: ENNReal.rpow_neg_one
File: Mathlib/Analysis/SpecialFunctions/Pow/NNReal.lean

tactic: simp [rpow_neg]
state_before: x : ℝ≥0∞
⊢ x ^ (-1) = x⁻¹
Theorem: Int.le_of_sub_nonneg
File: Std/Data/Int/Lemmas.lean

tactic: have h := Int.add_le_add_right h b
state_before: a b : Int
h : 0 ≤ a - b
⊢ b ≤ a

tactic: rwa [Int.sub_add_cancel, Int.zero_add] at h
state_before: a b : Int
h✝ : 0 ≤ a - b
h : 0 + b ≤ a - b + b
⊢ b ≤ a
Theorem: char_zero_of_expChar_one
File: Mathlib/Algebra/CharP/ExpChar.lean

tactic: cases hq
state_before: R : Type u
inst✝¹ : Semiring R
inst✝ : Nontrivial R
p : ℕ
hp : CharP R p
hq : ExpChar R 1
⊢ p = 0

tactic: exact CharP.eq R hp inferInstance
state_before: case zero
R : Type u
inst✝² : Semiring R
inst✝¹ : Nontrivial R
p : ℕ
hp : CharP R p
inst✝ : CharZero R
⊢ p = 0

tactic: exact False.elim (CharP.char_ne_one R 1 rfl)
state_before: case prime
R : Type u
inst✝¹ : Semiring R
inst✝ : Nontrivial R
p : ℕ
hp : CharP R p
hprime✝ : Nat.Prime 1
hchar✝ : CharP R 1
⊢ p = 0
Theorem: Finset.Icc_diff_Ioc_self
File: Mathlib/Data/Finset/LocallyFinite.lean

tactic: simp [← coe_inj, h]
state_before: ι : Type ?u.97854
α : Type u_1
inst✝² : PartialOrder α
inst✝¹ : LocallyFiniteOrder α
a b c : α
inst✝ : DecidableEq α
h : a ≤ b
⊢ Icc a b \ Ioc a b = {a}
Theorem: FormalMultilinearSeries.summable_norm_apply
File: Mathlib/Analysis/Analytic/Basic.lean

tactic: rw [mem_emetric_ball_zero_iff] at hx
state_before: 𝕜 : Type u_1
E : Type u_2
F : Type u_3
G : Type ?u.211235
inst✝⁶ : NontriviallyNormedField 𝕜
inst✝⁵ : NormedAddCommGroup E
inst✝⁴ : NormedSpace 𝕜 E
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
inst✝¹ : NormedAddCommGroup G
inst✝ : NormedSpace 𝕜 G
p✝ : FormalMultilinearSeries 𝕜 E F
r : ℝ≥0
p : FormalMultilinearSeries 𝕜 E F
x : E
hx : x ∈ EMetric.ball 0 (radius p)
⊢ Summable fun n => ‖↑(p n) fun x_1 => x‖

tactic: refine' summable_of_nonneg_of_le
  (fun _ => norm_nonneg _) (fun n => ((p n).le_op_norm _).trans_eq _) (p.summable_norm_mul_pow hx)
state_before: 𝕜 : Type u_1
E : Type u_2
F : Type u_3
G : Type ?u.211235
inst✝⁶ : NontriviallyNormedField 𝕜
inst✝⁵ : NormedAddCommGroup E
inst✝⁴ : NormedSpace 𝕜 E
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
inst✝¹ : NormedAddCommGroup G
inst✝ : NormedSpace 𝕜 G
p✝ : FormalMultilinearSeries 𝕜 E F
r : ℝ≥0
p : FormalMultilinearSeries 𝕜 E F
x : E
hx : ↑‖x‖₊ < radius p
⊢ Summable fun n => ‖↑(p n) fun x_1 => x‖

tactic: simp
state_before: 𝕜 : Type u_1
E : Type u_2
F : Type u_3
G : Type ?u.211235
inst✝⁶ : NontriviallyNormedField 𝕜
inst✝⁵ : NormedAddCommGroup E
inst✝⁴ : NormedSpace 𝕜 E
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
inst✝¹ : NormedAddCommGroup G
inst✝ : NormedSpace 𝕜 G
p✝ : FormalMultilinearSeries 𝕜 E F
r : ℝ≥0
p : FormalMultilinearSeries 𝕜 E F
x : E
hx : ↑‖x‖₊ < radius p
n : ℕ
⊢ ‖p n‖ * ∏ i : Fin n, ‖x‖ = ‖p n‖ * ↑‖x‖₊ ^ n
Theorem: PowerBasis.constr_pow_algebraMap
File: Mathlib/RingTheory/PowerBasis.lean

tactic: convert pb.constr_pow_aeval hy (C x) <;> rw [aeval_C]
state_before: R : Type ?u.236266
S : Type u_2
T : Type ?u.236272
inst✝¹⁰ : CommRing R
inst✝⁹ : Ring S
inst✝⁸ : Algebra R S
A : Type u_1
B : Type ?u.236578
inst✝⁷ : CommRing A
inst✝⁶ : CommRing B
inst✝⁵ : IsDomain B
inst✝⁴ : Algebra A B
K : Type ?u.237000
inst✝³ : Field K
inst✝² : Algebra A S
S' : Type u_3
inst✝¹ : Ring S'
inst✝ : Algebra A S'
pb : PowerBasis A S
y : S'
hy : ↑(aeval y) (minpoly A pb.gen) = 0
x : A
⊢ ↑(↑(Basis.constr pb.basis A) fun i => y ^ ↑i) (↑(algebraMap A S) x) = ↑(algebraMap A S') x
Theorem: Path.refl_symm
File: Mathlib/Topology/PathConnected.lean

tactic: ext
state_before: X : Type u_1
Y : Type ?u.114429
inst✝¹ : TopologicalSpace X
inst✝ : TopologicalSpace Y
x y z : X
ι : Type ?u.114444
γ : Path x y
a : X
⊢ symm (refl a) = refl a

tactic: rfl
state_before: case a.h
X : Type u_1
Y : Type ?u.114429
inst✝¹ : TopologicalSpace X
inst✝ : TopologicalSpace Y
x y z : X
ι : Type ?u.114444
γ : Path x y
a : X
x✝ : ↑I
⊢ ↑(symm (refl a)) x✝ = ↑(refl a) x✝
Theorem: ExceptT.run_bind_lift
File: src/lean/Init/Control/Lawful.lean

tactic: simp[ExceptT.run, ExceptT.lift, bind, ExceptT.bind, ExceptT.mk, ExceptT.bindCont, map_eq_pure_bind]
state_before: m : Type u_1 → Type u_2
α ε β : Type u_1
inst✝¹ : Monad m
inst✝ : LawfulMonad m
x : m α
f : α → ExceptT ε m β
⊢ run (ExceptT.lift x >>= f) = do
    let a ← x
    run (f a)
Theorem: Finset.Ico_subset_Ici_self
File: Mathlib/Data/Finset/LocallyFinite.lean

tactic: simpa [← coe_subset] using Set.Ico_subset_Ici_self
state_before: ι : Type ?u.45288
α : Type u_1
inst✝² : Preorder α
inst✝¹ : LocallyFiniteOrder α
a a₁ a₂ b b₁ b₂ c x : α
inst✝ : LocallyFiniteOrderTop α
⊢ Ico a b ⊆ Ici a
Theorem: Array.map_data
File: Std/Data/Array/Init/Lemmas.lean

tactic: apply congrArg data (foldl_eq_foldl_data (fun bs a => push bs (f a)) #[] arr) |>.trans
state_before: α : Type u_1
β : Type u_2
f : α → β
arr : Array α
⊢ (map f arr).data = List.map f arr.data

tactic: have H (l arr) : List.foldl (fun bs a => push bs (f a)) arr l = ⟨arr.data ++ l.map f⟩ := by
  induction l generalizing arr <;> simp [*]
state_before: α : Type u_1
β : Type u_2
f : α → β
arr : Array α
⊢ (List.foldl (fun bs a => push bs (f a)) #[] arr.data).data = List.map f arr.data

tactic: simp [H]
state_before: α : Type u_1
β : Type u_2
f : α → β
arr : Array α
H : ∀ (l : List α) (arr : Array β), List.foldl (fun bs a => push bs (f a)) arr l = { data := arr.data ++ List.map f l }
⊢ (List.foldl (fun bs a => push bs (f a)) #[] arr.data).data = List.map f arr.data

tactic: induction l generalizing arr <;> simp [*]
state_before: α : Type u_1
β : Type u_2
f : α → β
arr✝ : Array α
l : List α
arr : Array β
⊢ List.foldl (fun bs a => push bs (f a)) arr l = { data := arr.data ++ List.map f l }
Theorem: Set.nonempty_biUnion
File: Mathlib/Data/Set/Lattice.lean

tactic: simp
state_before: α : Type u_1
β : Type u_2
γ : Type ?u.83587
ι : Sort ?u.83590
ι' : Sort ?u.83593
ι₂ : Sort ?u.83596
κ : ι → Sort ?u.83601
κ₁ : ι → Sort ?u.83606
κ₂ : ι → Sort ?u.83611
κ' : ι' → Sort ?u.83616
s✝ : ι → Set α
t : Set α
s : α → Set β
⊢ Set.Nonempty (⋃ (i : α) (_ : i ∈ t), s i) ↔ ∃ i, i ∈ t ∧ Set.Nonempty (s i)
Theorem: CategoryTheory.Limits.biprod.add_eq_lift_desc_id
File: Mathlib/CategoryTheory/Preadditive/Biproducts.lean

tactic: simp
state_before: C : Type u
inst✝³ : Category C
inst✝² : Preadditive C
J : Type
inst✝¹ : Fintype J
X Y : C
f g : X ⟶ Y
inst✝ : HasBinaryBiproduct Y Y
⊢ f + g = lift f g ≫ desc (𝟙 Y) (𝟙 Y)
Theorem: Int.card_Icc_of_le
File: Mathlib/Data/Int/Interval.lean

tactic: rw [card_Icc, toNat_sub_of_le h]
state_before: a b : ℤ
h : a ≤ b + 1
⊢ ↑(card (Icc a b)) = b + 1 - a
Theorem: AddMonoidAlgebra.mem_adjoin_support
File: Mathlib/RingTheory/FiniteType.lean

tactic: suffices span R (of' R M '' f.support) ≤
    Subalgebra.toSubmodule (adjoin R (of' R M '' f.support)) by
  exact this (mem_span_support f)
state_before: R : Type u_1
M : Type u_2
inst✝¹ : CommSemiring R
inst✝ : AddMonoid M
f : AddMonoidAlgebra R M
⊢ f ∈ adjoin R (of' R M '' ↑f.support)

tactic: rw [Submodule.span_le]
state_before: R : Type u_1
M : Type u_2
inst✝¹ : CommSemiring R
inst✝ : AddMonoid M
f : AddMonoidAlgebra R M
⊢ span R (of' R M '' ↑f.support) ≤ ↑Subalgebra.toSubmodule (adjoin R (of' R M '' ↑f.support))

tactic: exact subset_adjoin
state_before: R : Type u_1
M : Type u_2
inst✝¹ : CommSemiring R
inst✝ : AddMonoid M
f : AddMonoidAlgebra R M
⊢ of' R M '' ↑f.support ⊆ ↑(↑Subalgebra.toSubmodule (adjoin R (of' R M '' ↑f.support)))

tactic: exact this (mem_span_support f)
state_before: R : Type u_1
M : Type u_2
inst✝¹ : CommSemiring R
inst✝ : AddMonoid M
f : AddMonoidAlgebra R M
this : span R (of' R M '' ↑f.support) ≤ ↑Subalgebra.toSubmodule (adjoin R (of' R M '' ↑f.support))
⊢ f ∈ adjoin R (of' R M '' ↑f.support)
Theorem: Cardinal.le_mul_right
File: Mathlib/SetTheory/Cardinal/Ordinal.lean

tactic: rw [mul_comm]
state_before: a b : Cardinal
h : b ≠ 0
⊢ a ≤ a * b

tactic: exact le_mul_left h
state_before: a b : Cardinal
h : b ≠ 0
⊢ a ≤ b * a
Theorem: PNat.XgcdType.reduce_b
File: Mathlib/Data/PNat/Xgcd.lean

tactic: rw [reduce]
state_before: u✝ u : XgcdType
h : r u ≠ 0
⊢ reduce u = flip (reduce (step u))

tactic: exact if_neg h
state_before: u✝ u : XgcdType
h : r u ≠ 0
⊢ (if x : r u = 0 then finish u else flip (reduce (step u))) = flip (reduce (step u))
Theorem: LiouvilleNumber.remainder_pos
File: Mathlib/NumberTheory/Liouville/LiouvilleNumber.lean

tactic: positivity
state_before: m : ℝ
hm : 1 < m
k x✝ : ℕ
⊢ 0 ≤ 1 / m ^ (x✝ + (k + 1))!

tactic: positivity
state_before: m : ℝ
hm : 1 < m
k : ℕ
⊢ 0 < 1 / m ^ (0 + (k + 1))!
Theorem: SimpleGraph.Subgraph.neighborSet_sInf
File: Mathlib/Combinatorics/SimpleGraph/Subgraph.lean

tactic: ext
state_before: ι : Sort ?u.93021
V : Type u
W : Type v
G : SimpleGraph V
G₁ G₂ : Subgraph G
a b : V
s : Set (Subgraph G)
v : V
⊢ neighborSet (sInf s) v = (⋂ (G' : Subgraph G) (_ : G' ∈ s), neighborSet G' v) ∩ SimpleGraph.neighborSet G v

tactic: simp
state_before: case h
ι : Sort ?u.93021
V : Type u
W : Type v
G : SimpleGraph V
G₁ G₂ : Subgraph G
a b : V
s : Set (Subgraph G)
v x✝ : V
⊢ x✝ ∈ neighborSet (sInf s) v ↔ x✝ ∈ (⋂ (G' : Subgraph G) (_ : G' ∈ s), neighborSet G' v) ∩ SimpleGraph.neighborSet G v
Theorem: PrimeMultiset.prod_inf
File: Mathlib/Data/PNat/Factors.lean

tactic: let n := u.prod
state_before: u v : PrimeMultiset
⊢ prod (u ⊓ v) = PNat.gcd (prod u) (prod v)

tactic: let m := v.prod
state_before: u v : PrimeMultiset
n : ℕ+ := prod u
⊢ prod (u ⊓ v) = PNat.gcd (prod u) (prod v)

tactic: change (u ⊓ v).prod = PNat.gcd n m
state_before: u v : PrimeMultiset
n : ℕ+ := prod u
m : ℕ+ := prod v
⊢ prod (u ⊓ v) = PNat.gcd (prod u) (prod v)

tactic: have : u = n.factorMultiset := u.factorMultiset_prod.symm
state_before: u v : PrimeMultiset
n : ℕ+ := prod u
m : ℕ+ := prod v
⊢ prod (u ⊓ v) = PNat.gcd n m

tactic: rw [this]
state_before: u v : PrimeMultiset
n : ℕ+ := prod u
m : ℕ+ := prod v
this : u = PNat.factorMultiset n
⊢ prod (u ⊓ v) = PNat.gcd n m

tactic: have : v = m.factorMultiset := v.factorMultiset_prod.symm
state_before: u v : PrimeMultiset
n : ℕ+ := prod u
m : ℕ+ := prod v
this : u = PNat.factorMultiset n
⊢ prod (PNat.factorMultiset n ⊓ v) = PNat.gcd n m

tactic: rw [this]
state_before: u v : PrimeMultiset
n : ℕ+ := prod u
m : ℕ+ := prod v
this✝ : u = PNat.factorMultiset n
this : v = PNat.factorMultiset m
⊢ prod (PNat.factorMultiset n ⊓ v) = PNat.gcd n m

tactic: rw [← PNat.factorMultiset_gcd n m, PNat.prod_factorMultiset]
state_before: u v : PrimeMultiset
n : ℕ+ := prod u
m : ℕ+ := prod v
this✝ : u = PNat.factorMultiset n
this : v = PNat.factorMultiset m
⊢ prod (PNat.factorMultiset n ⊓ PNat.factorMultiset m) = PNat.gcd n m
Theorem: segment_subset_Icc
File: Mathlib/Analysis/Convex/Segment.lean

tactic: rintro z ⟨a, b, ha, hb, hab, rfl⟩
state_before: 𝕜 : Type u_2
E : Type u_1
F : Type ?u.229927
G : Type ?u.229930
ι : Type ?u.229933
π : ι → Type ?u.229938
inst✝³ : OrderedSemiring 𝕜
inst✝² : OrderedAddCommMonoid E
inst✝¹ : Module 𝕜 E
inst✝ : OrderedSMul 𝕜 E
x y : E
h : x ≤ y
⊢ [x-[𝕜]y] ⊆ Icc x y

tactic: constructor
state_before: case intro.intro.intro.intro.intro
𝕜 : Type u_2
E : Type u_1
F : Type ?u.229927
G : Type ?u.229930
ι : Type ?u.229933
π : ι → Type ?u.229938
inst✝³ : OrderedSemiring 𝕜
inst✝² : OrderedAddCommMonoid E
inst✝¹ : Module 𝕜 E
inst✝ : OrderedSMul 𝕜 E
x y : E
h : x ≤ y
a b : 𝕜
ha : 0 ≤ a
hb : 0 ≤ b
hab : a + b = 1
⊢ a • x + b • y ∈ Icc x y

tactic: calc
  x = a • x + b • x := (Convex.combo_self hab _).symm
  _ ≤ a • x + b • y := by gcongr
state_before: case intro.intro.intro.intro.intro.left
𝕜 : Type u_2
E : Type u_1
F : Type ?u.229927
G : Type ?u.229930
ι : Type ?u.229933
π : ι → Type ?u.229938
inst✝³ : OrderedSemiring 𝕜
inst✝² : OrderedAddCommMonoid E
inst✝¹ : Module 𝕜 E
inst✝ : OrderedSMul 𝕜 E
x y : E
h : x ≤ y
a b : 𝕜
ha : 0 ≤ a
hb : 0 ≤ b
hab : a + b = 1
⊢ x ≤ a • x + b • y

case intro.intro.intro.intro.intro.right
𝕜 : Type u_2
E : Type u_1
F : Type ?u.229927
G : Type ?u.229930
ι : Type ?u.229933
π : ι → Type ?u.229938
inst✝³ : OrderedSemiring 𝕜
inst✝² : OrderedAddCommMonoid E
inst✝¹ : Module 𝕜 E
inst✝ : OrderedSMul 𝕜 E
x y : E
h : x ≤ y
a b : 𝕜
ha : 0 ≤ a
hb : 0 ≤ b
hab : a + b = 1
⊢ a • x + b • y ≤ y

tactic: calc
  a • x + b • y ≤ a • y + b • y := by gcongr
  _ = y := Convex.combo_self hab _
state_before: case intro.intro.intro.intro.intro.right
𝕜 : Type u_2
E : Type u_1
F : Type ?u.229927
G : Type ?u.229930
ι : Type ?u.229933
π : ι → Type ?u.229938
inst✝³ : OrderedSemiring 𝕜
inst✝² : OrderedAddCommMonoid E
inst✝¹ : Module 𝕜 E
inst✝ : OrderedSMul 𝕜 E
x y : E
h : x ≤ y
a b : 𝕜
ha : 0 ≤ a
hb : 0 ≤ b
hab : a + b = 1
⊢ a • x + b • y ≤ y

tactic: gcongr
state_before: 𝕜 : Type u_2
E : Type u_1
F : Type ?u.229927
G : Type ?u.229930
ι : Type ?u.229933
π : ι → Type ?u.229938
inst✝³ : OrderedSemiring 𝕜
inst✝² : OrderedAddCommMonoid E
inst✝¹ : Module 𝕜 E
inst✝ : OrderedSMul 𝕜 E
x y : E
h : x ≤ y
a b : 𝕜
ha : 0 ≤ a
hb : 0 ≤ b
hab : a + b = 1
⊢ a • x + b • x ≤ a • x + b • y

tactic: gcongr
state_before: 𝕜 : Type u_2
E : Type u_1
F : Type ?u.229927
G : Type ?u.229930
ι : Type ?u.229933
π : ι → Type ?u.229938
inst✝³ : OrderedSemiring 𝕜
inst✝² : OrderedAddCommMonoid E
inst✝¹ : Module 𝕜 E
inst✝ : OrderedSMul 𝕜 E
x y : E
h : x ≤ y
a b : 𝕜
ha : 0 ≤ a
hb : 0 ≤ b
hab : a + b = 1
⊢ a • x + b • y ≤ a • y + b • y
Theorem: piecewise_ae_eq_of_ae_eq_set
File: Mathlib/MeasureTheory/Measure/MeasureSpace.lean

tactic: simp [piecewise, hx]
state_before: α : Type u_1
β : Type u_2
γ : Type ?u.4394524
δ : Type ?u.4394527
ι : Type ?u.4394530
R : Type ?u.4394533
R' : Type ?u.4394536
inst✝ : MeasurableSpace α
μ : MeasureTheory.Measure α
s t : Set α
f g : α → β
hst : s =ᶠ[ae μ] t
x : α
hx : x ∈ s ↔ x ∈ t
⊢ piecewise s f g x = piecewise t f g x
Theorem: Cardinal.ord_nat
File: Mathlib/SetTheory/Ordinal/Basic.lean

tactic: induction' n with n IH
state_before: α : Type ?u.227526
β : Type ?u.227529
γ : Type ?u.227532
r : α → α → Prop
s : β → β → Prop
t : γ → γ → Prop
n : ℕ
⊢ ↑n ≤ ord ↑n

tactic: apply Ordinal.zero_le
state_before: case zero
α : Type ?u.227526
β : Type ?u.227529
γ : Type ?u.227532
r : α → α → Prop
s : β → β → Prop
t : γ → γ → Prop
⊢ ↑Nat.zero ≤ ord ↑Nat.zero

tactic: exact succ_le_of_lt (IH.trans_lt <| ord_lt_ord.2 <| natCast_lt.2 (Nat.lt_succ_self n))
state_before: case succ
α : Type ?u.227526
β : Type ?u.227529
γ : Type ?u.227532
r : α → α → Prop
s : β → β → Prop
t : γ → γ → Prop
n : ℕ
IH : ↑n ≤ ord ↑n
⊢ ↑(Nat.succ n) ≤ ord ↑(Nat.succ n)
Theorem: Finset.coe_eq_empty
File: Mathlib/Data/Finset/Basic.lean

tactic: rw [← coe_empty, coe_inj]
state_before: α : Type u_1
β : Type ?u.23076
γ : Type ?u.23079
s✝ s : Finset α
⊢ ↑s = ∅ ↔ s = ∅
Theorem: HahnSeries.embDomain_zero
File: Mathlib/RingTheory/HahnSeries.lean

tactic: ext
state_before: Γ : Type u_1
R : Type u_3
inst✝² : PartialOrder Γ
inst✝¹ : Zero R
a b : Γ
r : R
Γ' : Type u_2
inst✝ : PartialOrder Γ'
f : Γ ↪o Γ'
⊢ embDomain f 0 = 0

tactic: simp [embDomain_notin_image_support]
state_before: case coeff.h
Γ : Type u_1
R : Type u_3
inst✝² : PartialOrder Γ
inst✝¹ : Zero R
a b : Γ
r : R
Γ' : Type u_2
inst✝ : PartialOrder Γ'
f : Γ ↪o Γ'
x✝ : Γ'
⊢ coeff (embDomain f 0) x✝ = coeff 0 x✝