tasksource/leandojo huggingface dataset:
Theorem: exists_dist_eq
File: Mathlib/Analysis/NormedSpace/Pointwise.lean

tactic: use a • x + b • z
state_before: 𝕜 : Type ?u.200626
E : Type u_1
inst✝³ : NormedField 𝕜
inst✝² : SeminormedAddCommGroup E
inst✝¹ : NormedSpace 𝕜 E
inst✝ : NormedSpace ℝ E
x✝ y z✝ : E
δ ε : ℝ
x z : E
a b : ℝ
ha : 0 ≤ a
hb : 0 ≤ b
hab : a + b = 1
⊢ ∃ y, dist x y = b * dist x z ∧ dist y z = a * dist x z

tactic: nth_rw 1 [← one_smul ℝ x]
state_before: 𝕜 : Type ?u.200626
E : Type u_1
inst✝³ : NormedField 𝕜
inst✝² : SeminormedAddCommGroup E
inst✝¹ : NormedSpace 𝕜 E
inst✝ : NormedSpace ℝ E
x✝ y z✝ : E
δ ε : ℝ
x z : E
a b : ℝ
ha : 0 ≤ a
hb : 0 ≤ b
hab : a + b = 1
⊢ dist x (a • x + b • z) = b * dist x z ∧ dist (a • x + b • z) z = a * dist x z

tactic: nth_rw 4 [← one_smul ℝ z]
state_before: 𝕜 : Type ?u.200626
E : Type u_1
inst✝³ : NormedField 𝕜
inst✝² : SeminormedAddCommGroup E
inst✝¹ : NormedSpace 𝕜 E
inst✝ : NormedSpace ℝ E
x✝ y z✝ : E
δ ε : ℝ
x z : E
a b : ℝ
ha : 0 ≤ a
hb : 0 ≤ b
hab : a + b = 1
⊢ dist (1 • x) (a • x + b • z) = b * dist x z ∧ dist (a • x + b • z) z = a * dist x z

tactic: simp [dist_eq_norm, ← hab, add_smul, ← smul_sub, norm_smul_of_nonneg, ha, hb]
state_before: 𝕜 : Type ?u.200626
E : Type u_1
inst✝³ : NormedField 𝕜
inst✝² : SeminormedAddCommGroup E
inst✝¹ : NormedSpace 𝕜 E
inst✝ : NormedSpace ℝ E
x✝ y z✝ : E
δ ε : ℝ
x z : E
a b : ℝ
ha : 0 ≤ a
hb : 0 ≤ b
hab : a + b = 1
⊢ dist (1 • x) (a • x + b • z) = b * dist x z ∧ dist (a • x + b • z) (1 • z) = a * dist x z
Theorem: Fin.cast_nat_eq_last
File: Mathlib/Data/Fin/Basic.lean

tactic: rw [← Fin.ofNat_eq_val, Fin.ofNat'', Fin.last]
state_before: n✝ m n : ℕ
⊢ ↑n = last n

tactic: simp only [Nat.mod_eq_of_lt n.lt_succ_self]
state_before: n✝ m n : ℕ
⊢ { val := n % (n + 1), isLt := (_ : n % (n + 1) < n + 1) } = { val := n, isLt := (_ : n < Nat.succ n) }
Theorem: Homotopy.dNext_cochainComplex
File: Mathlib/Algebra/Homology/Homotopy.lean

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

tactic: have : (ComplexShape.up ℕ).next j = j + 1 := CochainComplex.next ℕ j
state_before: ι : Type ?u.364174
V : Type u
inst✝¹ : Category V
inst✝ : Preadditive V
c : ComplexShape ι
C D E : HomologicalComplex V c
f✝ g : C ⟶ D
h k : D ⟶ E
i : ι
P Q : CochainComplex V ℕ
f : (i j : ℕ) → X P i ⟶ X Q j
j : ℕ
⊢ d P j (ComplexShape.next (ComplexShape.up ℕ) j) ≫ f (ComplexShape.next (ComplexShape.up ℕ) j) j =
    d P j (j + 1) ≫ f (j + 1) j

tactic: congr 2
state_before: ι : Type ?u.364174
V : Type u
inst✝¹ : Category V
inst✝ : Preadditive V
c : ComplexShape ι
C D E : HomologicalComplex V c
f✝ g : C ⟶ D
h k : D ⟶ E
i : ι
P Q : CochainComplex V ℕ
f : (i j : ℕ) → X P i ⟶ X Q j
j : ℕ
this : ComplexShape.next (ComplexShape.up ℕ) j = j + 1
⊢ d P j (ComplexShape.next (ComplexShape.up ℕ) j) ≫ f (ComplexShape.next (ComplexShape.up ℕ) j) j =
    d P j (j + 1) ≫ f (j + 1) j
Theorem: CategoryTheory.MonoidalCategory.unitors_equal
File: Mathlib/CategoryTheory/Monoidal/CoherenceLemmas.lean

tactic: coherence
state_before: C : Type u_2
inst✝¹ : Category C
inst✝ : MonoidalCategory C
⊢ (λ_ (𝟙_ C)).hom = (ρ_ (𝟙_ C)).hom
Theorem: Multiset.map_union
File: Mathlib/Data/Multiset/Basic.lean

tactic: rw [List.map_append f, List.map_diff finj]
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.168994
inst✝¹ : DecidableEq α
s✝ t✝ u : Multiset α
a b : α
inst✝ : DecidableEq β
f : α → β
finj : Injective f
s t : Multiset α
l₁ l₂ : List α
⊢ List.map f (List.diff l₁ l₂ ++ l₂) = List.diff (List.map f l₁) (List.map f l₂) ++ List.map f l₂
Theorem: Polynomial.card_roots_le_map
File: Mathlib/Data/Polynomial/RingDivision.lean

tactic: rw [← p.roots.card_map f]
state_before: R : Type u
S : Type v
T : Type w
a b : R
n : ℕ
A : Type u_1
B : Type u_2
inst✝³ : CommRing A
inst✝² : CommRing B
inst✝¹ : IsDomain A
inst✝ : IsDomain B
p : A[X]
f : A →+* B
h : map f p ≠ 0
⊢ ↑Multiset.card (roots p) ≤ ↑Multiset.card (roots (map f p))

tactic: exact Multiset.card_le_of_le (map_roots_le h)
state_before: R : Type u
S : Type v
T : Type w
a b : R
n : ℕ
A : Type u_1
B : Type u_2
inst✝³ : CommRing A
inst✝² : CommRing B
inst✝¹ : IsDomain A
inst✝ : IsDomain B
p : A[X]
f : A →+* B
h : map f p ≠ 0
⊢ ↑Multiset.card (Multiset.map (↑f) (roots p)) ≤ ↑Multiset.card (roots (map f p))
Theorem: Representation.asGroupHom_apply
File: Mathlib/RepresentationTheory/Basic.lean

tactic: simp only [asGroupHom, MonoidHom.coe_toHomUnits]
state_before: k : Type u_2
G : Type u_3
V : Type u_1
inst✝³ : CommSemiring k
inst✝² : Group G
inst✝¹ : AddCommMonoid V
inst✝ : Module k V
ρ : Representation k G V
g : G
⊢ ↑(↑(asGroupHom ρ) g) = ↑ρ g
Theorem: CategoryTheory.GrothendieckTopology.toSheafify_naturality
File: Mathlib/CategoryTheory/Sites/Sheafification.lean

tactic: dsimp [sheafifyMap, sheafify, toSheafify]
state_before: C : Type u
inst✝³ : Category C
J : GrothendieckTopology C
D : Type w
inst✝² : Category D
inst✝¹ : ∀ (P : Cᵒᵖ ⥤ D) (X : C) (S : Cover J X), HasMultiequalizer (Cover.index S P)
inst✝ : ∀ (X : C), HasColimitsOfShape (Cover J X)ᵒᵖ D
P Q : Cᵒᵖ ⥤ D
η : P ⟶ Q
⊢ η ≫ toSheafify J Q = toSheafify J P ≫ sheafifyMap J η

tactic: simp
state_before: C : Type u
inst✝³ : Category C
J : GrothendieckTopology C
D : Type w
inst✝² : Category D
inst✝¹ : ∀ (P : Cᵒᵖ ⥤ D) (X : C) (S : Cover J X), HasMultiequalizer (Cover.index S P)
inst✝ : ∀ (X : C), HasColimitsOfShape (Cover J X)ᵒᵖ D
P Q : Cᵒᵖ ⥤ D
η : P ⟶ Q
⊢ η ≫ toPlus J Q ≫ plusMap J (toPlus J Q) = (toPlus J P ≫ plusMap J (toPlus J P)) ≫ plusMap J (plusMap J η)
Theorem: DirectSum.Gmodule.one_smul'
File: Mathlib/Algebra/Module/GradedModule.lean

tactic: suffices smulAddMonoidHom A M 1 = AddMonoidHom.id (⨁ i, M i) from FunLike.congr_fun this x
state_before: ι : Type u_1
A : ι → Type u_2
M : ι → Type u_3
inst✝⁵ : AddMonoid ι
inst✝⁴ : (i : ι) → AddCommMonoid (A i)
inst✝³ : (i : ι) → AddCommMonoid (M i)
inst✝² : DecidableEq ι
inst✝¹ : GMonoid A
inst✝ : Gmodule A M
x : ⨁ (i : ι), M i
⊢ 1 • x = x

tactic: apply DirectSum.addHom_ext
state_before: ι : Type u_1
A : ι → Type u_2
M : ι → Type u_3
inst✝⁵ : AddMonoid ι
inst✝⁴ : (i : ι) → AddCommMonoid (A i)
inst✝³ : (i : ι) → AddCommMonoid (M i)
inst✝² : DecidableEq ι
inst✝¹ : GMonoid A
inst✝ : Gmodule A M
x : ⨁ (i : ι), M i
⊢ ↑(smulAddMonoidHom A M) 1 = AddMonoidHom.id (⨁ (i : ι), M i)

tactic: intro i xi
state_before: case H
ι : Type u_1
A : ι → Type u_2
M : ι → Type u_3
inst✝⁵ : AddMonoid ι
inst✝⁴ : (i : ι) → AddCommMonoid (A i)
inst✝³ : (i : ι) → AddCommMonoid (M i)
inst✝² : DecidableEq ι
inst✝¹ : GMonoid A
inst✝ : Gmodule A M
x : ⨁ (i : ι), M i
⊢ ∀ (i : ι) (y : M i),
    ↑(↑(smulAddMonoidHom A M) 1) (↑(of (fun i => M i) i) y) =
      ↑(AddMonoidHom.id (⨁ (i : ι), M i)) (↑(of (fun i => M i) i) y)

tactic: rw [show (1 : DirectSum ι fun i => A i) = (of A 0) GOne.one by rfl]
state_before: case H
ι : Type u_1
A : ι → Type u_2
M : ι → Type u_3
inst✝⁵ : AddMonoid ι
inst✝⁴ : (i : ι) → AddCommMonoid (A i)
inst✝³ : (i : ι) → AddCommMonoid (M i)
inst✝² : DecidableEq ι
inst✝¹ : GMonoid A
inst✝ : Gmodule A M
x : ⨁ (i : ι), M i
i : ι
xi : M i
⊢ ↑(↑(smulAddMonoidHom A M) 1) (↑(of (fun i => M i) i) xi) =
    ↑(AddMonoidHom.id (⨁ (i : ι), M i)) (↑(of (fun i => M i) i) xi)

tactic: rw [smulAddMonoidHom_apply_of_of]
state_before: case H
ι : Type u_1
A : ι → Type u_2
M : ι → Type u_3
inst✝⁵ : AddMonoid ι
inst✝⁴ : (i : ι) → AddCommMonoid (A i)
inst✝³ : (i : ι) → AddCommMonoid (M i)
inst✝² : DecidableEq ι
inst✝¹ : GMonoid A
inst✝ : Gmodule A M
x : ⨁ (i : ι), M i
i : ι
xi : M i
⊢ ↑(↑(smulAddMonoidHom A M) (↑(of A 0) GOne.one)) (↑(of (fun i => M i) i) xi) =
    ↑(AddMonoidHom.id (⨁ (i : ι), M i)) (↑(of (fun i => M i) i) xi)

tactic: exact DirectSum.of_eq_of_gradedMonoid_eq (one_smul (GradedMonoid A) <| GradedMonoid.mk i xi)
state_before: case H
ι : Type u_1
A : ι → Type u_2
M : ι → Type u_3
inst✝⁵ : AddMonoid ι
inst✝⁴ : (i : ι) → AddCommMonoid (A i)
inst✝³ : (i : ι) → AddCommMonoid (M i)
inst✝² : DecidableEq ι
inst✝¹ : GMonoid A
inst✝ : Gmodule A M
x : ⨁ (i : ι), M i
i : ι
xi : M i
⊢ ↑(of M (0 + i)) (GSmul.smul GOne.one xi) = ↑(AddMonoidHom.id (⨁ (i : ι), M i)) (↑(of (fun i => M i) i) xi)

tactic: rfl
state_before: ι : Type u_1
A : ι → Type u_2
M : ι → Type u_3
inst✝⁵ : AddMonoid ι
inst✝⁴ : (i : ι) → AddCommMonoid (A i)
inst✝³ : (i : ι) → AddCommMonoid (M i)
inst✝² : DecidableEq ι
inst✝¹ : GMonoid A
inst✝ : Gmodule A M
x : ⨁ (i : ι), M i
i : ι
xi : M i
⊢ 1 = ↑(of A 0) GOne.one
Theorem: Set.Icc_diff_left
File: Mathlib/Data/Set/Intervals/Basic.lean

tactic: simp [lt_iff_le_and_ne, eq_comm, and_right_comm]
state_before: α : Type u_1
β : Type ?u.32157
inst✝ : PartialOrder α
a b c x : α
⊢ x ∈ Icc a b \ {a} ↔ x ∈ Ioc a b
Theorem: BilinForm.exists_bilinForm_self_ne_zero
File: Mathlib/LinearAlgebra/QuadraticForm/Basic.lean

tactic: lift B to QuadraticForm R M using hB₂ with Q
state_before: S : Type ?u.666424
R : Type u_1
R₁ : Type ?u.666430
M : Type u_2
inst✝² : Ring R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
htwo : Invertible 2
B : BilinForm R M
hB₁ : B ≠ 0
hB₂ : IsSymm B
⊢ ∃ x, ¬IsOrtho B x x

tactic: obtain ⟨x, hx⟩ := QuadraticForm.exists_quadraticForm_ne_zero hB₁
state_before: case intro
S : Type ?u.666424
R : Type u_1
R₁ : Type ?u.666430
M : Type u_2
inst✝² : Ring R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
htwo : Invertible 2
B : BilinForm R M
Q : QuadraticForm R M
hB₁✝ hB₁ : ↑(QuadraticForm.associatedHom ℕ) Q ≠ 0
⊢ ∃ x, ¬IsOrtho (↑(QuadraticForm.associatedHom ℕ) Q) x x

tactic: exact ⟨x, fun h => hx (Q.associated_eq_self_apply ℕ x ▸ h)⟩
state_before: case intro.intro
S : Type ?u.666424
R : Type u_1
R₁ : Type ?u.666430
M : Type u_2
inst✝² : Ring R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
htwo : Invertible 2
B : BilinForm R M
Q : QuadraticForm R M
hB₁✝ hB₁ : ↑(QuadraticForm.associatedHom ℕ) Q ≠ 0
x : M
hx : ↑Q x ≠ 0
⊢ ∃ x, ¬IsOrtho (↑(QuadraticForm.associatedHom ℕ) Q) x x
Theorem: UpperSemicontinuousAt.add'
File: Mathlib/Topology/Semicontinuous.lean

tactic: simp_rw [← upperSemicontinuousWithinAt_univ_iff] at *
state_before: α : Type u_1
inst✝⁴ : TopologicalSpace α
β : Type ?u.183589
inst✝³ : Preorder β
f✝ g✝ : α → β
x : α
s t : Set α
y z : β
ι : Type ?u.183615
γ : Type u_2
inst✝² : LinearOrderedAddCommMonoid γ
inst✝¹ : TopologicalSpace γ
inst✝ : OrderTopology γ
f g : α → γ
hf : UpperSemicontinuousAt f x
hg : UpperSemicontinuousAt g x
hcont : ContinuousAt (fun p => p.fst + p.snd) (f x, g x)
⊢ UpperSemicontinuousAt (fun z => f z + g z) x

tactic: exact hf.add' hg hcont
state_before: α : Type u_1
inst✝⁴ : TopologicalSpace α
β : Type ?u.183589
inst✝³ : Preorder β
f✝ g✝ : α → β
x : α
s t : Set α
y z : β
ι : Type ?u.183615
γ : Type u_2
inst✝² : LinearOrderedAddCommMonoid γ
inst✝¹ : TopologicalSpace γ
inst✝ : OrderTopology γ
f g : α → γ
hcont : ContinuousAt (fun p => p.fst + p.snd) (f x, g x)
hf : UpperSemicontinuousWithinAt f univ x
hg : UpperSemicontinuousWithinAt g univ x
⊢ UpperSemicontinuousWithinAt (fun z => f z + g z) univ x
Theorem: LieSubalgebra.exists_nested_lieIdeal_ofLe_normalizer
File: Mathlib/Algebra/Lie/Normalizer.lean

tactic: rw [exists_nested_lieIdeal_coe_eq_iff]
state_before: R : Type u_1
L : Type u_2
M : Type ?u.59016
M' : Type ?u.59019
inst✝¹⁰ : CommRing R
inst✝⁹ : LieRing L
inst✝⁸ : LieAlgebra R L
inst✝⁷ : AddCommGroup M
inst✝⁶ : Module R M
inst✝⁵ : LieRingModule L M
inst✝⁴ : LieModule R L M
inst✝³ : AddCommGroup M'
inst✝² : Module R M'
inst✝¹ : LieRingModule L M'
inst✝ : LieModule R L M'
H K : LieSubalgebra R L
h₁ : H ≤ K
h₂ : K ≤ normalizer H
⊢ ∃ I, ↑R { x // x ∈ K } I = ofLe h₁

tactic: exact fun x y hx hy => ideal_in_normalizer (h₂ hx) hy
state_before: R : Type u_1
L : Type u_2
M : Type ?u.59016
M' : Type ?u.59019
inst✝¹⁰ : CommRing R
inst✝⁹ : LieRing L
inst✝⁸ : LieAlgebra R L
inst✝⁷ : AddCommGroup M
inst✝⁶ : Module R M
inst✝⁵ : LieRingModule L M
inst✝⁴ : LieModule R L M
inst✝³ : AddCommGroup M'
inst✝² : Module R M'
inst✝¹ : LieRingModule L M'
inst✝ : LieModule R L M'
H K : LieSubalgebra R L
h₁ : H ≤ K
h₂ : K ≤ normalizer H
⊢ ∀ (x y : L), x ∈ K → y ∈ H → ⁅x, y⁆ ∈ H
Theorem: exp_unop
File: Mathlib/Analysis/NormedSpace/Exponential.lean

tactic: simp_rw [exp, expSeries_sum_eq, ← MulOpposite.unop_pow, ← MulOpposite.unop_smul, tsum_unop]
state_before: 𝕂 : Type u_2
𝔸 : Type u_1
inst✝⁵ : Field 𝕂
inst✝⁴ : Ring 𝔸
inst✝³ : Algebra 𝕂 𝔸
inst✝² : TopologicalSpace 𝔸
inst✝¹ : TopologicalRing 𝔸
inst✝ : T2Space 𝔸
x : 𝔸ᵐᵒᵖ
⊢ exp 𝕂 (MulOpposite.unop x) = MulOpposite.unop (exp 𝕂 x)
Theorem: support_factorization
File: Mathlib/RingTheory/UniqueFactorizationDomain.lean

tactic: simp [factorization, Multiset.toFinsupp_support]
state_before: α : Type u_1
inst✝³ : CancelCommMonoidWithZero α
inst✝² : UniqueFactorizationMonoid α
inst✝¹ : NormalizationMonoid α
inst✝ : DecidableEq α
n : α
⊢ (factorization n).support = Multiset.toFinset (normalizedFactors n)
Theorem: Subgroup.mem_normalizer_iff'
File: Mathlib/GroupTheory/Subgroup/Basic.lean

tactic: rw [h, mul_assoc, mul_inv_cancel_right]
state_before: G : Type u_1
G' : Type ?u.381690
inst✝² : Group G
inst✝¹ : Group G'
A : Type ?u.381699
inst✝ : AddGroup A
H K : Subgroup G
g : G
h : g ∈ normalizer H
n : G
⊢ n * g ∈ H ↔ g * n ∈ H

tactic: rw [mul_assoc, ← h, inv_mul_cancel_right]
state_before: G : Type u_1
G' : Type ?u.381690
inst✝² : Group G
inst✝¹ : Group G'
A : Type ?u.381699
inst✝ : AddGroup A
H K : Subgroup G
g : G
h : ∀ (n : G), n * g ∈ H ↔ g * n ∈ H
n : G
⊢ n ∈ H ↔ g * n * g⁻¹ ∈ H
Theorem: MonoidHom.range_eq_top_of_cancel
File: Mathlib/Algebra/Category/GroupCat/EpiMono.lean

tactic: specialize h 1 (QuotientGroup.mk' _) _
state_before: A : Type u
B : Type v
inst✝¹ : CommGroup A
inst✝ : CommGroup B
f : A →* B
h : ∀ (u v : B →* B ⧸ range f), comp u f = comp v f → u = v
⊢ range f = ⊤

tactic: replace h : (QuotientGroup.mk' _).ker = (1 : B →* B ⧸ f.range).ker := by rw [h]
state_before: A : Type u
B : Type v
inst✝¹ : CommGroup A
inst✝ : CommGroup B
f : A →* B
h : 1 = QuotientGroup.mk' (range f)
⊢ range f = ⊤

tactic: rwa [ker_one, QuotientGroup.ker_mk'] at h
state_before: A : Type u
B : Type v
inst✝¹ : CommGroup A
inst✝ : CommGroup B
f : A →* B
h : ker (QuotientGroup.mk' (range f)) = ker 1
⊢ range f = ⊤

tactic: ext1 x
state_before: A : Type u
B : Type v
inst✝¹ : CommGroup A
inst✝ : CommGroup B
f : A →* B
h : ∀ (u v : B →* B ⧸ range f), comp u f = comp v f → u = v
⊢ comp 1 f = comp (QuotientGroup.mk' (range f)) f

tactic: simp only [one_apply, coe_comp, coe_mk', Function.comp_apply]
state_before: case h
A : Type u
B : Type v
inst✝¹ : CommGroup A
inst✝ : CommGroup B
f : A →* B
h : ∀ (u v : B →* B ⧸ range f), comp u f = comp v f → u = v
x : A
⊢ ↑(comp 1 f) x = ↑(comp (QuotientGroup.mk' (range f)) f) x

tactic: rw [show (1 : B ⧸ f.range) = (1 : B) from QuotientGroup.mk_one _, QuotientGroup.eq, inv_one,
  one_mul]
state_before: case h
A : Type u
B : Type v
inst✝¹ : CommGroup A
inst✝ : CommGroup B
f : A →* B
h : ∀ (u v : B →* B ⧸ range f), comp u f = comp v f → u = v
x : A
⊢ 1 = ↑(↑f x)

tactic: exact ⟨x, rfl⟩
state_before: case h
A : Type u
B : Type v
inst✝¹ : CommGroup A
inst✝ : CommGroup B
f : A →* B
h : ∀ (u v : B →* B ⧸ range f), comp u f = comp v f → u = v
x : A
⊢ ↑f x ∈ range f

tactic: rw [h]
state_before: A : Type u
B : Type v
inst✝¹ : CommGroup A
inst✝ : CommGroup B
f : A →* B
h : 1 = QuotientGroup.mk' (range f)
⊢ ker (QuotientGroup.mk' ?m.20988) = ker 1
Theorem: Function.nodup_periodicOrbit
File: Mathlib/Dynamics/PeriodicPts.lean

tactic: rw [periodicOrbit, Cycle.nodup_coe_iff, List.nodup_map_iff_inj_on (List.nodup_range _)]
state_before: α : Type u_1
β : Type ?u.32137
f fa : α → α
fb : β → β
x y : α
m n : ℕ
⊢ Cycle.Nodup (periodicOrbit f x)

tactic: intro m hm n hn hmn
state_before: α : Type u_1
β : Type ?u.32137
f fa : α → α
fb : β → β
x y : α
m n : ℕ
⊢ ∀ (x_1 : ℕ),
    x_1 ∈ List.range (minimalPeriod f x) →
      ∀ (y : ℕ), y ∈ List.range (minimalPeriod f x) → (f^[x_1]) x = (f^[y]) x → x_1 = y

tactic: rw [List.mem_range] at hm hn
state_before: α : Type u_1
β : Type ?u.32137
f fa : α → α
fb : β → β
x y : α
m✝ n✝ m : ℕ
hm : m ∈ List.range (minimalPeriod f x)
n : ℕ
hn : n ∈ List.range (minimalPeriod f x)
hmn : (f^[m]) x = (f^[n]) x
⊢ m = n

tactic: rwa [eq_iff_lt_minimalPeriod_of_iterate_eq hm hn] at hmn
state_before: α : Type u_1
β : Type ?u.32137
f fa : α → α
fb : β → β
x y : α
m✝ n✝ m : ℕ
hm : m < minimalPeriod f x
n : ℕ
hn : n < minimalPeriod f x
hmn : (f^[m]) x = (f^[n]) x
⊢ m = n
Theorem: Fintype.prod_eq_mul
File: Mathlib/Data/Fintype/BigOperators.lean

tactic: apply Finset.prod_eq_mul a b h₁ fun x _ hx => h₂ x hx <;>
  exact fun hc => (hc (Finset.mem_univ _)).elim
state_before: α : Type u_1
β : Type ?u.5479
γ : Type ?u.5482
M : Type u_2
inst✝¹ : Fintype α
inst✝ : CommMonoid M
f : α → M
a b : α
h₁ : a ≠ b
h₂ : ∀ (x : α), x ≠ a ∧ x ≠ b → f x = 1
⊢ ∏ x : α, f x = f a * f b
Theorem: CategoryTheory.IsPushout.inr_fst'
File: Mathlib/CategoryTheory/Limits/Shapes/CommSq.lean

tactic: refine' of_bot _ (by simp) (of_isBilimit h)
state_before: C : Type u₁
inst✝² : Category C
Z X Y P : C
f : Z ⟶ X
g : Z ⟶ Y
inl : X ⟶ P
inr : Y ⟶ P
inst✝¹ : HasZeroObject C
inst✝ : HasZeroMorphisms C
b : BinaryBicone X Y
h : BinaryBicone.IsBilimit b
⊢ IsPushout b.inr 0 b.fst 0

tactic: simp
state_before: C : Type u₁
inst✝² : Category C
Z X Y P : C
f : Z ⟶ X
g : Z ⟶ Y
inl : X ⟶ P
inr : Y ⟶ P
inst✝¹ : HasZeroObject C
inst✝ : HasZeroMorphisms C
b : BinaryBicone X Y
h : BinaryBicone.IsBilimit b
⊢ IsPushout 0 (0 ≫ 0) (b.inl ≫ b.fst) 0

tactic: simp
state_before: C : Type u₁
inst✝² : Category C
Z X Y P : C
f : Z ⟶ X
g : Z ⟶ Y
inl : X ⟶ P
inr : Y ⟶ P
inst✝¹ : HasZeroObject C
inst✝ : HasZeroMorphisms C
b : BinaryBicone X Y
h : BinaryBicone.IsBilimit b
⊢ b.inr ≫ b.fst = 0 ≫ 0
Theorem: CategoryTheory.isConnected_of_zigzag
File: Mathlib/CategoryTheory/IsConnected.lean

tactic: apply zigzag_isConnected
state_before: J : Type u₁
inst✝² : Category J
K : Type u₂
inst✝¹ : Category K
inst✝ : Nonempty J
h : ∀ (j₁ j₂ : J), ∃ l, List.Chain Zag j₁ l ∧ List.getLast (j₁ :: l) (_ : j₁ :: l ≠ []) = j₂
⊢ IsConnected J

tactic: intro j₁ j₂
state_before: case h
J : Type u₁
inst✝² : Category J
K : Type u₂
inst✝¹ : Category K
inst✝ : Nonempty J
h : ∀ (j₁ j₂ : J), ∃ l, List.Chain Zag j₁ l ∧ List.getLast (j₁ :: l) (_ : j₁ :: l ≠ []) = j₂
⊢ ∀ (j₁ j₂ : J), Zigzag j₁ j₂

tactic: rcases h j₁ j₂ with ⟨l, hl₁, hl₂⟩
state_before: case h
J : Type u₁
inst✝² : Category J
K : Type u₂
inst✝¹ : Category K
inst✝ : Nonempty J
h : ∀ (j₁ j₂ : J), ∃ l, List.Chain Zag j₁ l ∧ List.getLast (j₁ :: l) (_ : j₁ :: l ≠ []) = j₂
j₁ j₂ : J
⊢ Zigzag j₁ j₂

tactic: apply List.relationReflTransGen_of_exists_chain l hl₁ hl₂
state_before: case h.intro.intro
J : Type u₁
inst✝² : Category J
K : Type u₂
inst✝¹ : Category K
inst✝ : Nonempty J
h : ∀ (j₁ j₂ : J), ∃ l, List.Chain Zag j₁ l ∧ List.getLast (j₁ :: l) (_ : j₁ :: l ≠ []) = j₂
j₁ j₂ : J
l : List J
hl₁ : List.Chain Zag j₁ l
hl₂ : List.getLast (j₁ :: l) (_ : j₁ :: l ≠ []) = j₂
⊢ Zigzag j₁ j₂
Theorem: Finpartition.sum_card_parts
File: Mathlib/Order/Partition/Finpartition.lean

tactic: convert congr_arg Finset.card P.biUnion_parts
state_before: α : Type u_1
inst✝ : DecidableEq α
s t : Finset α
P : Finpartition s
⊢ ∑ i in P.parts, card i = card s

tactic: rw [card_biUnion P.supIndep.pairwiseDisjoint]
state_before: case h.e'_2
α : Type u_1
inst✝ : DecidableEq α
s t : Finset α
P : Finpartition s
⊢ ∑ i in P.parts, card i = card (Finset.biUnion P.parts id)

tactic: rfl
state_before: case h.e'_2
α : Type u_1
inst✝ : DecidableEq α
s t : Finset α
P : Finpartition s
⊢ ∑ i in P.parts, card i = ∑ u in P.parts, card (id u)
Theorem: div_le_iff
File: Mathlib/Algebra/Order/Field/Basic.lean

tactic: rw [div_mul_cancel _ (ne_of_lt hb).symm]
state_before: ι : Type ?u.23876
α : Type u_1
β : Type ?u.23882
inst✝ : LinearOrderedSemifield α
a b c d e : α
m n : ℤ
hb : 0 < b
h : a / b ≤ c
⊢ a = a / b * b

tactic: refine' (div_eq_iff (ne_of_gt hb)).mpr rfl
state_before: ι : Type ?u.23876
α : Type u_1
β : Type ?u.23882
inst✝ : LinearOrderedSemifield α
a b c d e : α
m n : ℤ
hb : 0 < b
h : a ≤ c * b
⊢ c * b / b = c
Theorem: CauSeq.inv_mul_cancel
File: Mathlib/Data/Real/CauSeq.lean

tactic: simpa [(abv_pos abv).1 (lt_of_lt_of_le K0 (H _ ij)), abv_zero abv] using ε0
state_before: α : Type u_1
β : Type u_2
inst✝² : LinearOrderedField α
inst✝¹ : DivisionRing β
abv : β → α
inst✝ : IsAbsoluteValue abv
f : CauSeq β abv
hf : ¬LimZero f
ε : α
ε0 : ε > 0
K : α
K0 : K > 0
i : ℕ
H : ∀ (j : ℕ), j ≥ i → K ≤ abv (↑f j)
j : ℕ
ij : j ≥ i
⊢ abv (↑(inv f hf * f - 1) j) < ε
Theorem: comp_mul_left
File: Mathlib/Algebra/Group/Basic.lean

tactic: ext z
state_before: α : Type u_1
β : Type ?u.14
G : Type ?u.17
inst✝ : Semigroup α
x y : α
⊢ ((fun x_1 => x * x_1) ∘ fun x => y * x) = fun x_1 => x * y * x_1

tactic: simp [mul_assoc]
state_before: case h
α : Type u_1
β : Type ?u.14
G : Type ?u.17
inst✝ : Semigroup α
x y z : α
⊢ ((fun x_1 => x * x_1) ∘ fun x => y * x) z = x * y * z
Theorem: Sym2.fromRel_top
File: Mathlib/Data/Sym/Sym2.lean

tactic: apply Set.eq_univ_of_forall fun e => _
state_before: α : Type u_1
β : Type ?u.44384
γ : Type ?u.44387
r : α → α → Prop
⊢ fromRel (_ : ∀ (x y : α), ⊤ x y → ⊤ x y) = Set.univ

tactic: apply Sym2.ind
state_before: α : Type u_1
β : Type ?u.44384
γ : Type ?u.44387
r : α → α → Prop
⊢ ∀ (e : Sym2 α), e ∈ fromRel (_ : ∀ (x y : α), ⊤ x y → ⊤ x y)

tactic: simp [-Set.top_eq_univ, Prop.top_eq_true]
state_before: case h
α : Type u_1
β : Type ?u.44384
γ : Type ?u.44387
r : α → α → Prop
⊢ ∀ (x y : α), Quotient.mk (Rel.setoid α) (x, y) ∈ fromRel (_ : ∀ (x y : α), ⊤ x y → ⊤ x y)
Theorem: Subsemigroup.dense_induction
File: Mathlib/GroupTheory/Subsemigroup/Basic.lean

tactic: have : ∀ x ∈ closure s, p x := fun x hx => closure_induction hx Hs Hmul
state_before: M : Type u_1
N : Type ?u.18436
A : Type ?u.18439
inst✝¹ : Mul M
s✝ : Set M
inst✝ : Add A
t : Set A
S : Subsemigroup M
p : M → Prop
x : M
s : Set M
hs : closure s = ⊤
Hs : ∀ (x : M), x ∈ s → p x
Hmul : ∀ (x y : M), p x → p y → p (x * y)
⊢ p x

tactic: simpa [hs] using this x
state_before: M : Type u_1
N : Type ?u.18436
A : Type ?u.18439
inst✝¹ : Mul M
s✝ : Set M
inst✝ : Add A
t : Set A
S : Subsemigroup M
p : M → Prop
x : M
s : Set M
hs : closure s = ⊤
Hs : ∀ (x : M), x ∈ s → p x
Hmul : ∀ (x y : M), p x → p y → p (x * y)
this : ∀ (x : M), x ∈ closure s → p x
⊢ p x
Theorem: GroupCat.SurjectiveOfEpiAuxs.fromCoset_eq_of_mem_range
File: Mathlib/Algebra/Category/GroupCat/EpiMono.lean

tactic: congr
state_before: A B : GroupCat
f : A ⟶ B
b : ↑B
hb : b ∈ MonoidHom.range f
⊢ fromCoset
      { val := b *l (MonoidHom.range f).toSubmonoid.toSubsemigroup.carrier,
        property :=
          (_ :
            ∃ y,
              Function.swap leftCoset (MonoidHom.range f).toSubmonoid.toSubsemigroup.carrier y =
                b *l (MonoidHom.range f).toSubmonoid.toSubsemigroup.carrier) } =
    fromCoset
      { val := (MonoidHom.range f).toSubmonoid.toSubsemigroup.carrier,
        property :=
          (_ :
            ∃ y,
              Function.swap leftCoset (MonoidHom.range f).toSubmonoid.toSubsemigroup.carrier y =
                (MonoidHom.range f).toSubmonoid.toSubsemigroup.carrier) }

tactic: let b : B.α := b
state_before: case e_a.e_val
A B : GroupCat
f : A ⟶ B
b : ↑B
hb : b ∈ MonoidHom.range f
⊢ b *l (MonoidHom.range f).toSubmonoid.toSubsemigroup.carrier = (MonoidHom.range f).toSubmonoid.toSubsemigroup.carrier

tactic: change b *l f.range = f.range
state_before: case e_a.e_val
A B : GroupCat
f : A ⟶ B
b✝ : ↑B
hb : b✝ ∈ MonoidHom.range f
b : ↑B := b✝
⊢ b✝ *l (MonoidHom.range f).toSubmonoid.toSubsemigroup.carrier = (MonoidHom.range f).toSubmonoid.toSubsemigroup.carrier

tactic: nth_rw 2 [show (f.range : Set B.α) = 1 *l f.range from (one_leftCoset _).symm]
state_before: case e_a.e_val
A B : GroupCat
f : A ⟶ B
b✝ : ↑B
hb : b✝ ∈ MonoidHom.range f
b : ↑B := b✝
⊢ b *l ↑(MonoidHom.range f) = ↑(MonoidHom.range f)

tactic: rw [leftCoset_eq_iff, mul_one]
state_before: case e_a.e_val
A B : GroupCat
f : A ⟶ B
b✝ : ↑B
hb : b✝ ∈ MonoidHom.range f
b : ↑B := b✝
⊢ b *l ↑(MonoidHom.range f) = 1 *l ↑(MonoidHom.range f)

tactic: exact Subgroup.inv_mem _ hb
state_before: case e_a.e_val
A B : GroupCat
f : A ⟶ B
b✝ : ↑B
hb : b✝ ∈ MonoidHom.range f
b : ↑B := b✝
⊢ b⁻¹ ∈ MonoidHom.range f
Theorem: inv_mul'
File: Mathlib/Algebra/Group/Basic.lean

tactic: simp
state_before: α : Type u_1
β : Type ?u.32026
G : Type ?u.32029
inst✝ : DivisionCommMonoid α
a b c d : α
⊢ (a * b)⁻¹ = a⁻¹ / b