ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: CategoryTheory.Limits.inr_inl_pushoutLeftPushoutInrIso_hom
File: Mathlib/CategoryTheory/Limits/Shapes/Pullback/Pasting.lean

Proof steps:
state_before: C : Type u
inst✝³ : Category.{v, u} C
W X Y Z : C
f : X ⟶ Y
g : X ⟶ Z
g' : Z ⟶ W
inst✝² : HasPushout f g
inst✝¹ : HasPushout (pushout.inr f g) g'
inst✝ : HasPushout f (g ≫ g')
⊢ pushout.inr f g ≫ pushout.inl (pushout.inr f g) g' ≫ (pushoutLeftPushoutInrIso f g g').hom =
    g' ≫ pushout.inr f (g ≫ g')
state_after: no goals
tactic: rw [← Category.assoc, ← Iso.eq_comp_inv, Category.assoc, inr_pushoutLeftPushoutInrIso_inv,
    pushout.condition]
Theorem: add_self
File: Mathlib/Algebra/Ring/BooleanRing.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : BooleanRing α
a b : α
⊢ a + a = 0
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : BooleanRing α
a b : α
this : a + a = a + a + (a + a)
⊢ a + a = 0
tactic: have : a + a = a + a + (a + a) :=
    calc
      a + a = (a + a) * (a + a) := by rw [mul_self]
      _ = a * a + a * a + (a * a + a * a) := by rw [add_mul, mul_add]
      _ = a + a + (a + a) := by rw [mul_self]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : BooleanRing α
a b : α
this : a + a = a + a + (a + a)
⊢ a + a = 0
state_after: no goals
tactic: rwa [self_eq_add_left] at this
Theorem: Set.range_dcomp
File: Mathlib/Data/Set/Prod.lean

Proof steps:
state_before: ι : Type u_1
α : ι → Type u_2
β : ι → Type u_3
s s₁ s₂ : Set ι
t t₁ t₂ : (i : ι) → Set (α i)
i : ι
f : (i : ι) → α i → β i
⊢ (range fun g i => f i (g i)) = univ.pi fun i => range (f i)
state_after: case refine_1
ι : Type u_1
α : ι → Type u_2
β : ι → Type u_3
s s₁ s₂ : Set ι
t t₁ t₂ : (i : ι) → Set (α i)
i : ι
f : (i : ι) → α i → β i
⊢ (range fun g i => f i (g i)) ⊆ univ.pi fun i => range (f i)

case refine_2
ι : Type u_1
α : ι → Type u_2
β : ι → Type u_3
s s₁ s₂ : Set ι
t t₁ t₂ : (i : ι) → Set (α i)
i : ι
f : (i : ι) → α i → β i
x : (i : ι) → β i
hx : x ∈ univ.pi fun i => range (f i)
⊢ x ∈ range fun g i => f i (g i)
tactic: refine Subset.antisymm ?_ fun x hx => ?_
Theorem: Finset.filter_and
File: Mathlib/Data/Finset/Basic.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
p q : α → Prop
inst✝² : DecidablePred p
inst✝¹ : DecidablePred q
s✝ t : Finset α
inst✝ : DecidableEq α
s : Finset α
x✝ : α
⊢ x✝ ∈ filter (fun a => p a ∧ q a) s ↔ x✝ ∈ filter p s ∩ filter q s
state_after: no goals
tactic: simp [mem_filter, mem_inter, and_comm, and_left_comm, and_self_iff, and_assoc]
Theorem: mul_sub_left_distrib
File: Mathlib/Algebra/Ring/Defs.lean

Proof steps:
state_before: α : Type u
β : Type v
γ : Type w
R : Type x
inst✝ : NonUnitalNonAssocRing α
a b c : α
⊢ a * (b - c) = a * b - a * c
state_after: no goals
tactic: simpa only [sub_eq_add_neg, neg_mul_eq_mul_neg] using mul_add a b (-c)
Theorem: SemilatSupCat.Iso.mk_inv_toSupHom_toFun
File: Mathlib/Order/Category/Semilat.lean

Proof steps:
state_before: α β : SemilatSupCat
e : α.X ≃o β.X
⊢ { toFun := ⇑e, map_sup' := ⋯, map_bot' := ⋯ } ≫ { toFun := ⇑e.symm, map_sup' := ⋯, map_bot' := ⋯ } = 𝟙 α
state_after: case w
α β : SemilatSupCat
e : α.X ≃o β.X
x✝ : (forget SemilatSupCat).obj α
⊢ ({ toFun := ⇑e, map_sup' := ⋯, map_bot' := ⋯ } ≫ { toFun := ⇑e.symm, map_sup' := ⋯, map_bot' := ⋯ }) x✝ = (𝟙 α) x✝
tactic: ext
state_before: case w
α β : SemilatSupCat
e : α.X ≃o β.X
x✝ : (forget SemilatSupCat).obj α
⊢ ({ toFun := ⇑e, map_sup' := ⋯, map_bot' := ⋯ } ≫ { toFun := ⇑e.symm, map_sup' := ⋯, map_bot' := ⋯ }) x✝ = (𝟙 α) x✝
state_after: no goals
tactic: exact e.symm_apply_apply _
state_before: α β : SemilatSupCat
e : α.X ≃o β.X
⊢ { toFun := ⇑e.symm, map_sup' := ⋯, map_bot' := ⋯ } ≫ { toFun := ⇑e, map_sup' := ⋯, map_bot' := ⋯ } = 𝟙 β
state_after: case w
α β : SemilatSupCat
e : α.X ≃o β.X
x✝ : (forget SemilatSupCat).obj β
⊢ ({ toFun := ⇑e.symm, map_sup' := ⋯, map_bot' := ⋯ } ≫ { toFun := ⇑e, map_sup' := ⋯, map_bot' := ⋯ }) x✝ = (𝟙 β) x✝
tactic: ext
state_before: case w
α β : SemilatSupCat
e : α.X ≃o β.X
x✝ : (forget SemilatSupCat).obj β
⊢ ({ toFun := ⇑e.symm, map_sup' := ⋯, map_bot' := ⋯ } ≫ { toFun := ⇑e, map_sup' := ⋯, map_bot' := ⋯ }) x✝ = (𝟙 β) x✝
state_after: no goals
tactic: exact e.apply_symm_apply _
Theorem: one_lt_zpow'
File: Mathlib/Algebra/Order/Group/Basic.lean

Proof steps:
state_before: α : Type u_1
M : Type u_2
R : Type u_3
inst✝ : OrderedCommGroup α
m n : ℤ
a b : α
ha : 1 < a
hn : 0 < n
⊢ 1 < a ^ n
state_after: case intro
α : Type u_1
M : Type u_2
R : Type u_3
inst✝ : OrderedCommGroup α
m : ℤ
a b : α
ha : 1 < a
n : ℕ
hn : 0 < ↑n
⊢ 1 < a ^ ↑n
tactic: obtain ⟨n, rfl⟩ := Int.eq_ofNat_of_zero_le hn.le
state_before: case intro
α : Type u_1
M : Type u_2
R : Type u_3
inst✝ : OrderedCommGroup α
m : ℤ
a b : α
ha : 1 < a
n : ℕ
hn : 0 < ↑n
⊢ 1 < a ^ ↑n
state_after: case intro
α : Type u_1
M : Type u_2
R : Type u_3
inst✝ : OrderedCommGroup α
m : ℤ
a b : α
ha : 1 < a
n : ℕ
hn : 0 < ↑n
⊢ 1 < a ^ n
tactic: rw [zpow_natCast]
state_before: case intro
α : Type u_1
M : Type u_2
R : Type u_3
inst✝ : OrderedCommGroup α
m : ℤ
a b : α
ha : 1 < a
n : ℕ
hn : 0 < ↑n
⊢ 1 < a ^ n
state_after: case intro
α : Type u_1
M : Type u_2
R : Type u_3
inst✝ : OrderedCommGroup α
m : ℤ
a b : α
ha : 1 < a
n : ℕ
hn : 0 < ↑n
⊢ n ≠ 0
tactic: refine one_lt_pow' ha ?_
state_before: case intro
α : Type u_1
M : Type u_2
R : Type u_3
inst✝ : OrderedCommGroup α
m : ℤ
a b : α
ha : 1 < a
n : ℕ
hn : 0 < ↑n
⊢ n ≠ 0
state_after: case intro
α : Type u_1
M : Type u_2
R : Type u_3
inst✝ : OrderedCommGroup α
m : ℤ
a b : α
ha : 1 < a
hn : 0 < ↑0
⊢ False
tactic: rintro rfl
state_before: case intro
α : Type u_1
M : Type u_2
R : Type u_3
inst✝ : OrderedCommGroup α
m : ℤ
a b : α
ha : 1 < a
hn : 0 < ↑0
⊢ False
state_after: no goals
tactic: simp at hn
Theorem: TypeVec.const_iff_true
File: Mathlib/Data/TypeVec.lean

Proof steps:
state_before: n : ℕ
α : TypeVec.{u_1} n
i : Fin2 n
x : α i
p : Prop
⊢ ofRepeat (TypeVec.const p α i x) ↔ p
state_after: no goals
tactic: induction i with
  | fz      => rfl
  | fs _ ih => erw [TypeVec.const, @ih (drop α) x]
Theorem: Nat.le_pow_iff_clog_le
File: Mathlib/Data/Nat/Log.lean

Proof steps:
state_before: b : ℕ
hb : 1 < b
x y : ℕ
⊢ x ≤ b ^ y ↔ clog b x ≤ y
state_after: case h
b : ℕ
hb : 1 < b
x : ℕ
ih : ∀ m < x, ∀ {y : ℕ}, m ≤ b ^ y ↔ clog b m ≤ y
y : ℕ
⊢ x ≤ b ^ y ↔ clog b x ≤ y
tactic: induction' x using Nat.strong_induction_on with x ih generalizing y
state_before: case h
b : ℕ
hb : 1 < b
x : ℕ
ih : ∀ m < x, ∀ {y : ℕ}, m ≤ b ^ y ↔ clog b m ≤ y
y : ℕ
⊢ x ≤ b ^ y ↔ clog b x ≤ y
state_after: case h.zero
b : ℕ
hb : 1 < b
x : ℕ
ih : ∀ m < x, ∀ {y : ℕ}, m ≤ b ^ y ↔ clog b m ≤ y
⊢ x ≤ b ^ 0 ↔ clog b x ≤ 0

case h.succ
b : ℕ
hb : 1 < b
x : ℕ
ih : ∀ m < x, ∀ {y : ℕ}, m ≤ b ^ y ↔ clog b m ≤ y
n✝ : ℕ
⊢ x ≤ b ^ (n✝ + 1) ↔ clog b x ≤ n✝ + 1
tactic: cases y
state_before: case h.succ
b : ℕ
hb : 1 < b
x : ℕ
ih : ∀ m < x, ∀ {y : ℕ}, m ≤ b ^ y ↔ clog b m ≤ y
n✝ : ℕ
⊢ x ≤ b ^ (n✝ + 1) ↔ clog b x ≤ n✝ + 1
state_after: case h.succ
b : ℕ
hb : 1 < b
x : ℕ
ih : ∀ m < x, ∀ {y : ℕ}, m ≤ b ^ y ↔ clog b m ≤ y
n✝ : ℕ
b_pos : 0 < b
⊢ x ≤ b ^ (n✝ + 1) ↔ clog b x ≤ n✝ + 1
tactic: have b_pos : 0 < b := zero_lt_of_lt hb
state_before: case h.succ
b : ℕ
hb : 1 < b
x : ℕ
ih : ∀ m < x, ∀ {y : ℕ}, m ≤ b ^ y ↔ clog b m ≤ y
n✝ : ℕ
b_pos : 0 < b
⊢ x ≤ b ^ (n✝ + 1) ↔ clog b x ≤ n✝ + 1
state_after: case h.succ
b : ℕ
hb : 1 < b
x : ℕ
ih : ∀ m < x, ∀ {y : ℕ}, m ≤ b ^ y ↔ clog b m ≤ y
n✝ : ℕ
b_pos : 0 < b
⊢ x ≤ b ^ (n✝ + 1) ↔ (if h : 1 < b ∧ 1 < x then clog b ((x + b - 1) / b) + 1 else 0) ≤ n✝ + 1
tactic: rw [clog]
state_before: case h.succ
b : ℕ
hb : 1 < b
x : ℕ
ih : ∀ m < x, ∀ {y : ℕ}, m ≤ b ^ y ↔ clog b m ≤ y
n✝ : ℕ
b_pos : 0 < b
⊢ x ≤ b ^ (n✝ + 1) ↔ (if h : 1 < b ∧ 1 < x then clog b ((x + b - 1) / b) + 1 else 0) ≤ n✝ + 1
state_after: case pos
b : ℕ
hb : 1 < b
x : ℕ
ih : ∀ m < x, ∀ {y : ℕ}, m ≤ b ^ y ↔ clog b m ≤ y
n✝ : ℕ
b_pos : 0 < b
h : 1 < b ∧ 1 < x
⊢ x ≤ b ^ (n✝ + 1) ↔ clog b ((x + b - 1) / b) + 1 ≤ n✝ + 1

case neg
b : ℕ
hb : 1 < b
x : ℕ
ih : ∀ m < x, ∀ {y : ℕ}, m ≤ b ^ y ↔ clog b m ≤ y
n✝ : ℕ
b_pos : 0 < b
h : ¬(1 < b ∧ 1 < x)
⊢ x ≤ b ^ (n✝ + 1) ↔ 0 ≤ n✝ + 1
tactic: split_ifs with h
Theorem: AlgebraicGeometry.Scheme.OpenCover.add_J
File: Mathlib/AlgebraicGeometry/Cover/Open.lean

Proof steps:
state_before: X✝ Y✝ Z : Scheme
𝒰✝ : X✝.OpenCover
f✝ : X✝ ⟶ Z
g : Y✝ ⟶ Z
inst✝¹ : ∀ (x : 𝒰✝.J), HasPullback (𝒰✝.map x ≫ f✝) g
X Y : Scheme
𝒰 : X.OpenCover
f : Y ⟶ X
inst✝ : IsOpenImmersion f
⊢ ∀ (x : Option 𝒰.J), IsOpenImmersion ((fun i => Option.rec f 𝒰.map i) x)
state_after: no goals
tactic: rintro (_ | _) <;> dsimp <;> infer_instance
Theorem: SimpleGraph.Walk.append_assoc
File: Mathlib/Combinatorics/SimpleGraph/Walk.lean

Proof steps:
state_before: V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
u v w x : V
p : G.Walk u v
q : G.Walk v w
r : G.Walk w x
⊢ p.append (q.append r) = (p.append q).append r
state_after: no goals
tactic: induction p with
  | nil => rfl
  | cons h p' ih =>
    dsimp only [append]
    rw [ih]
Theorem: congr_heq
File: Mathlib/Logic/Basic.lean

Proof steps:
state_before: α✝ : Sort u_1
α β : Sort u_2
γ : Sort u_3
f : α → γ
g : β → γ
x : α
y : β
h₁ : HEq f g
h₂ : HEq x y
⊢ f x = g y
state_after: case refl
α✝ : Sort u_1
α : Sort u_2
γ : Sort u_3
f : α → γ
x : α
g : α → γ
h₁ : HEq f g
⊢ f x = g x
tactic: cases h₂
state_before: case refl
α✝ : Sort u_1
α : Sort u_2
γ : Sort u_3
f : α → γ
x : α
g : α → γ
h₁ : HEq f g
⊢ f x = g x
state_after: case refl.refl
α✝ : Sort u_1
α : Sort u_2
γ : Sort u_3
f : α → γ
x : α
⊢ f x = f x
tactic: cases h₁
state_before: case refl.refl
α✝ : Sort u_1
α : Sort u_2
γ : Sort u_3
f : α → γ
x : α
⊢ f x = f x
state_after: no goals
tactic: rfl
Theorem: LightProfinite.proj_comp_transitionMap'
File: Mathlib/Topology/Category/LightProfinite/AsLimit.lean

Proof steps:
state_before: S : LightProfinite
n : ℕ
⊢ ⇑(S.transitionMap n) ∘ ⇑(S.proj (n + 1)) = ⇑(S.proj n)
state_after: S : LightProfinite
n : ℕ
⊢ ⇑(S.transitionMap n) ∘ ⇑(S.proj (n + 1)) = ⇑(S.proj (n + 1) ≫ S.diagram.map (Opposite.op (homOfLE ⋯)))
tactic: rw [← S.proj_comp_transitionMap n]
state_before: S : LightProfinite
n : ℕ
⊢ ⇑(S.transitionMap n) ∘ ⇑(S.proj (n + 1)) = ⇑(S.proj (n + 1) ≫ S.diagram.map (Opposite.op (homOfLE ⋯)))
state_after: no goals
tactic: rfl
Theorem: CategoryTheory.Cokleisli.Adjunction.toCokleisli_obj
File: Mathlib/CategoryTheory/Monad/Kleisli.lean

Proof steps:
state_before: C : Type u
inst✝ : Category.{v, u} C
U : Comonad C
X Y x✝ : C
f : X ⟶ Y
g : Y ⟶ x✝
⊢ { obj := fun X => X, map := fun {X x} f => U.ε.app X ≫ f }.map (f ≫ g) =
    { obj := fun X => X, map := fun {X x} f => U.ε.app X ≫ f }.map f ≫
      { obj := fun X => X, map := fun {X x} f => U.ε.app X ≫ f }.map g
state_after: C : Type u
inst✝ : Category.{v, u} C
U : Comonad C
X Y x✝ : C
f : X ⟶ Y
g : Y ⟶ x✝
⊢ U.ε.app X ≫ f ≫ g = U.δ.app X ≫ U.map (U.ε.app X ≫ f) ≫ U.ε.app Y ≫ g
tactic: change U.ε.app X ≫ f ≫ g = U.δ.app X ≫ U.map (U.ε.app X ≫ f) ≫ U.ε.app Y ≫ g
state_before: C : Type u
inst✝ : Category.{v, u} C
U : Comonad C
X Y x✝ : C
f : X ⟶ Y
g : Y ⟶ x✝
⊢ U.ε.app X ≫ f ≫ g = U.δ.app X ≫ U.map (U.ε.app X ≫ f) ≫ U.ε.app Y ≫ g
state_after: no goals
tactic: simp [← U.ε.naturality g]
Theorem: Real.comap_exp_atTop
File: Mathlib/Analysis/SpecialFunctions/Exp.lean

Proof steps:
state_before: α : Type u_1
x y z : ℝ
l : Filter α
⊢ comap rexp atTop = atTop
state_after: no goals
tactic: rw [← map_exp_atTop, comap_map exp_injective, map_exp_atTop]
Theorem: AddSubgroup.mem_iff_toAddUnits_mem_addUnits
File: Mathlib/Algebra/Group/Submonoid/Units.lean

Proof steps:
state_before: M : Type u_1
inst✝¹ : Monoid M
G : Type u_2
inst✝ : Group G
H : Subgroup G
x : G
⊢ toUnits x ∈ H.units ↔ x ∈ H
state_after: no goals
tactic: simp_rw [mem_units_iff_val_mem, val_toUnits_apply]
Theorem: ContinuousLinearEquiv.subsingleton_or_norm_symm_pos
File: Mathlib/Analysis/NormedSpace/OperatorNorm/NormedSpace.lean

Proof steps:
state_before: 𝕜 : Type u_1
𝕜₂ : Type u_2
𝕜₃ : Type u_3
E : Type u_4
Eₗ : Type u_5
F : Type u_6
Fₗ : Type u_7
G : Type u_8
Gₗ : Type u_9
𝓕 : Type u_10
inst✝¹² : NormedAddCommGroup E
inst✝¹¹ : NormedAddCommGroup F
inst✝¹⁰ : NormedAddCommGroup G
inst✝⁹ : NormedAddCommGroup Fₗ
inst✝⁸ : NontriviallyNormedField 𝕜
inst✝⁷ : NontriviallyNormedField 𝕜₂
inst✝⁶ : NontriviallyNormedField 𝕜₃
inst✝⁵ : NormedSpace 𝕜 E
inst✝⁴ : NormedSpace 𝕜₂ F
σ₁₂ : 𝕜 →+* 𝕜₂
σ₂₁ : 𝕜₂ →+* 𝕜
inst✝³ : RingHomInvPair σ₁₂ σ₂₁
inst✝² : RingHomInvPair σ₂₁ σ₁₂
inst✝¹ : RingHomIsometric σ₂₁
inst✝ : RingHomIsometric σ₁₂
e : E ≃SL[σ₁₂] F
⊢ Subsingleton E ∨ 0 < ‖↑e.symm‖
state_after: case inl
𝕜 : Type u_1
𝕜₂ : Type u_2
𝕜₃ : Type u_3
E : Type u_4
Eₗ : Type u_5
F : Type u_6
Fₗ : Type u_7
G : Type u_8
Gₗ : Type u_9
𝓕 : Type u_10
inst✝¹² : NormedAddCommGroup E
inst✝¹¹ : NormedAddCommGroup F
inst✝¹⁰ : NormedAddCommGroup G
inst✝⁹ : NormedAddCommGroup Fₗ
inst✝⁸ : NontriviallyNormedField 𝕜
inst✝⁷ : NontriviallyNormedField 𝕜₂
inst✝⁶ : NontriviallyNormedField 𝕜₃
inst✝⁵ : NormedSpace 𝕜 E
inst✝⁴ : NormedSpace 𝕜₂ F
σ₁₂ : 𝕜 →+* 𝕜₂
σ₂₁ : 𝕜₂ →+* 𝕜
inst✝³ : RingHomInvPair σ₁₂ σ₂₁
inst✝² : RingHomInvPair σ₂₁ σ₁₂
inst✝¹ : RingHomIsometric σ₂₁
inst✝ : RingHomIsometric σ₁₂
e : E ≃SL[σ₁₂] F
_i : Subsingleton E
⊢ Subsingleton E ∨ 0 < ‖↑e.symm‖

case inr
𝕜 : Type u_1
𝕜₂ : Type u_2
𝕜₃ : Type u_3
E : Type u_4
Eₗ : Type u_5
F : Type u_6
Fₗ : Type u_7
G : Type u_8
Gₗ : Type u_9
𝓕 : Type u_10
inst✝¹² : NormedAddCommGroup E
inst✝¹¹ : NormedAddCommGroup F
inst✝¹⁰ : NormedAddCommGroup G
inst✝⁹ : NormedAddCommGroup Fₗ
inst✝⁸ : NontriviallyNormedField 𝕜
inst✝⁷ : NontriviallyNormedField 𝕜₂
inst✝⁶ : NontriviallyNormedField 𝕜₃
inst✝⁵ : NormedSpace 𝕜 E
inst✝⁴ : NormedSpace 𝕜₂ F
σ₁₂ : 𝕜 →+* 𝕜₂
σ₂₁ : 𝕜₂ →+* 𝕜
inst✝³ : RingHomInvPair σ₁₂ σ₂₁
inst✝² : RingHomInvPair σ₂₁ σ₁₂
inst✝¹ : RingHomIsometric σ₂₁
inst✝ : RingHomIsometric σ₁₂
e : E ≃SL[σ₁₂] F
_i : Nontrivial E
⊢ Subsingleton E ∨ 0 < ‖↑e.symm‖
tactic: rcases subsingleton_or_nontrivial E with (_i | _i)
Theorem: PLift.down_inj
File: Mathlib/Logic/Function/ULift.lean

Proof steps:
state_before: α : Sort u_1
a b : PLift α
h : a = b
⊢ a.down = b.down
state_after: no goals
tactic: rw [h]
Theorem: Function.IsPeriodicPt.sub
File: Mathlib/Dynamics/PeriodicPts.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
f fa : α → α
fb : β → β
x y : α
m n : ℕ
hm : IsPeriodicPt f m x
hn : IsPeriodicPt f n x
⊢ IsPeriodicPt f (m - n) x
state_after: case inl
α : Type u_1
β : Type u_2
f fa : α → α
fb : β → β
x y : α
m n : ℕ
hm : IsPeriodicPt f m x
hn : IsPeriodicPt f n x
h : n ≤ m
⊢ IsPeriodicPt f (m - n) x

case inr
α : Type u_1
β : Type u_2
f fa : α → α
fb : β → β
x y : α
m n : ℕ
hm : IsPeriodicPt f m x
hn : IsPeriodicPt f n x
h : m ≤ n
⊢ IsPeriodicPt f (m - n) x
tactic: rcases le_total n m with h | h
Theorem: Set.Icc.one_sub_nonneg
File: Mathlib/Algebra/Order/Interval/Set/Instances.lean

Proof steps:
state_before: α : Type u_1
inst✝¹ : OrderedSemiring α
β : Type u_2
inst✝ : OrderedRing β
x : ↑(Icc 0 1)
⊢ 0 ≤ 1 - ↑x
state_after: no goals
tactic: simpa using x.2.2
Theorem: Finset.filter_le_lt_eq_Ico
File: Mathlib/Order/Interval/Finset/Basic.lean

Proof steps:
state_before: ι : Type u_1
α : Type u_2
inst✝³ : Preorder α
inst✝² : LocallyFiniteOrder α
a a₁ a₂ b b₁ b₂ c x : α
inst✝¹ : Fintype α
inst✝ : DecidablePred fun j => a ≤ j ∧ j < b
⊢ filter (fun j => a ≤ j ∧ j < b) univ = Ico a b
state_after: case a
ι : Type u_1
α : Type u_2
inst✝³ : Preorder α
inst✝² : LocallyFiniteOrder α
a a₁ a₂ b b₁ b₂ c x : α
inst✝¹ : Fintype α
inst✝ : DecidablePred fun j => a ≤ j ∧ j < b
a✝ : α
⊢ a✝ ∈ filter (fun j => a ≤ j ∧ j < b) univ ↔ a✝ ∈ Ico a b
tactic: ext
state_before: case a
ι : Type u_1
α : Type u_2
inst✝³ : Preorder α
inst✝² : LocallyFiniteOrder α
a a₁ a₂ b b₁ b₂ c x : α
inst✝¹ : Fintype α
inst✝ : DecidablePred fun j => a ≤ j ∧ j < b
a✝ : α
⊢ a✝ ∈ filter (fun j => a ≤ j ∧ j < b) univ ↔ a✝ ∈ Ico a b
state_after: no goals
tactic: simp
Theorem: finsum_mem_inter_support_eq
File: Mathlib/Algebra/BigOperators/Finprod.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
ι : Type u_3
G : Type u_4
M : Type u_5
N : Type u_6
inst✝¹ : CommMonoid M
inst✝ : CommMonoid N
f : α → M
s t : Set α
h : s ∩ mulSupport f = t ∩ mulSupport f
⊢ ∏ᶠ (i : α) (_ : i ∈ s), f i = ∏ᶠ (i : α) (_ : i ∈ t), f i
state_after: no goals
tactic: rw [← finprod_mem_inter_mulSupport, h, finprod_mem_inter_mulSupport]
Theorem: hyperoperation_ge_three_eq_one
File: Mathlib/Data/Nat/Hyperoperation.lean

Proof steps:
state_before: n m : ℕ
⊢ hyperoperation (n + 3) m 0 = 1
state_after: no goals
tactic: rw [hyperoperation]
Theorem: WeierstrassCurve.Projective.equation_some
File: Mathlib/AlgebraicGeometry/EllipticCurve/Projective.lean

Proof steps:
state_before: R : Type u
inst✝ : CommRing R
W : Projective R
X Y : R
⊢ W.Equation ![X, Y, 1] ↔ W.toAffine.Equation X Y
state_after: R : Type u
inst✝ : CommRing R
W : Projective R
X Y : R
⊢ ![X, Y, 1] 1 ^ 2 * ![X, Y, 1] 2 + W.a₁ * ![X, Y, 1] 0 * ![X, Y, 1] 1 * ![X, Y, 1] 2 +
        W.a₃ * ![X, Y, 1] 1 * ![X, Y, 1] 2 ^ 2 =
      ![X, Y, 1] 0 ^ 3 + W.a₂ * ![X, Y, 1] 0 ^ 2 * ![X, Y, 1] 2 + W.a₄ * ![X, Y, 1] 0 * ![X, Y, 1] 2 ^ 2 +
        W.a₆ * ![X, Y, 1] 2 ^ 3 ↔
    Y ^ 2 + W.toAffine.a₁ * X * Y + W.toAffine.a₃ * Y =
      X ^ 3 + W.toAffine.a₂ * X ^ 2 + W.toAffine.a₄ * X + W.toAffine.a₆
tactic: rw [equation_iff, W.toAffine.equation_iff]
state_before: R : Type u
inst✝ : CommRing R
W : Projective R
X Y : R
⊢ ![X, Y, 1] 1 ^ 2 * ![X, Y, 1] 2 + W.a₁ * ![X, Y, 1] 0 * ![X, Y, 1] 1 * ![X, Y, 1] 2 +
        W.a₃ * ![X, Y, 1] 1 * ![X, Y, 1] 2 ^ 2 =
      ![X, Y, 1] 0 ^ 3 + W.a₂ * ![X, Y, 1] 0 ^ 2 * ![X, Y, 1] 2 + W.a₄ * ![X, Y, 1] 0 * ![X, Y, 1] 2 ^ 2 +
        W.a₆ * ![X, Y, 1] 2 ^ 3 ↔
    Y ^ 2 + W.toAffine.a₁ * X * Y + W.toAffine.a₃ * Y =
      X ^ 3 + W.toAffine.a₂ * X ^ 2 + W.toAffine.a₄ * X + W.toAffine.a₆
state_after: no goals
tactic: congr! 1 <;> matrix_simp <;> ring1
Theorem: ADEInequality.admissible_of_one_lt_sumInv
File: Mathlib/NumberTheory/ADEInequality.lean

Proof steps:
state_before: p q r : ℕ+
H : 1 < sumInv {p, q, r}
⊢ Admissible {p, q, r}
state_after: p q r : ℕ+
H : 1 < sumInv {p, q, r}
⊢ (∃ q_1 r_1, A' q_1 r_1 = {p, q, r}) ∨
    (∃ r_1, D' r_1 = {p, q, r}) ∨ E' 3 = {p, q, r} ∨ E' 4 = {p, q, r} ∨ E' 5 = {p, q, r}
tactic: simp only [Admissible]
state_before: p q r : ℕ+
H : 1 < sumInv {p, q, r}
S : List ℕ+ := sort (fun x x_1 => x ≤ x_1) {p, q, r}
hS : List.Sorted (fun x x_1 => x ≤ x_1) S
⊢ (∃ q_1 r_1, A' q_1 r_1 = {p, q, r}) ∨
    (∃ r_1, D' r_1 = {p, q, r}) ∨ E' 3 = {p, q, r} ∨ E' 4 = {p, q, r} ∨ E' 5 = {p, q, r}
state_after: p q r : ℕ+
H : 1 < sumInv {p, q, r}
S : List ℕ+ := sort (fun x x_1 => x ≤ x_1) {p, q, r}
hS : List.Sorted (fun x x_1 => x ≤ x_1) S
hpqr : {p, q, r} = ↑S
⊢ (∃ q_1 r_1, A' q_1 r_1 = {p, q, r}) ∨
    (∃ r_1, D' r_1 = {p, q, r}) ∨ E' 3 = {p, q, r} ∨ E' 4 = {p, q, r} ∨ E' 5 = {p, q, r}
tactic: have hpqr : ({p, q, r} : Multiset ℕ+) = S := (sort_eq LE.le {p, q, r}).symm
state_before: p q r : ℕ+
H : 1 < sumInv {p, q, r}
S : List ℕ+ := sort (fun x x_1 => x ≤ x_1) {p, q, r}
hS : List.Sorted (fun x x_1 => x ≤ x_1) S
hpqr : {p, q, r} = ↑S
⊢ (∃ q_1 r_1, A' q_1 r_1 = {p, q, r}) ∨
    (∃ r_1, D' r_1 = {p, q, r}) ∨ E' 3 = {p, q, r} ∨ E' 4 = {p, q, r} ∨ E' 5 = {p, q, r}
state_after: p q r : ℕ+
H : 1 < sumInv {p, q, r}
S : List ℕ+ := sort (fun x x_1 => x ≤ x_1) {p, q, r}
hS : List.Sorted (fun x x_1 => x ≤ x_1) S
hpqr : {p, q, r} = ↑S
⊢ (∃ q r, A' q r = ↑S) ∨ (∃ r, D' r = ↑S) ∨ E' 3 = ↑S ∨ E' 4 = ↑S ∨ E' 5 = ↑S
tactic: rw [hpqr]
state_before: p q r : ℕ+
H : 1 < sumInv {p, q, r}
S : List ℕ+ := sort (fun x x_1 => x ≤ x_1) {p, q, r}
hS : List.Sorted (fun x x_1 => x ≤ x_1) S
hpqr : {p, q, r} = ↑S
⊢ (∃ q r, A' q r = ↑S) ∨ (∃ r, D' r = ↑S) ∨ E' 3 = ↑S ∨ E' 4 = ↑S ∨ E' 5 = ↑S
state_after: p q r : ℕ+
S : List ℕ+ := sort (fun x x_1 => x ≤ x_1) {p, q, r}
H : 1 < sumInv ↑S
hS : List.Sorted (fun x x_1 => x ≤ x_1) S
hpqr : {p, q, r} = ↑S
⊢ (∃ q r, A' q r = ↑S) ∨ (∃ r, D' r = ↑S) ∨ E' 3 = ↑S ∨ E' 4 = ↑S ∨ E' 5 = ↑S
tactic: rw [hpqr] at H
state_before: p q r : ℕ+
S : List ℕ+ := sort (fun x x_1 => x ≤ x_1) {p, q, r}
H : 1 < sumInv ↑S
hS : List.Sorted (fun x x_1 => x ≤ x_1) S
hpqr : {p, q, r} = ↑S
⊢ (∃ q r, A' q r = ↑S) ∨ (∃ r, D' r = ↑S) ∨ E' 3 = ↑S ∨ E' 4 = ↑S ∨ E' 5 = ↑S
state_after: p q r : ℕ+
S : List ℕ+ := sort (fun x x_1 => x ≤ x_1) {p, q, r}
H : 1 < sumInv ↑S
hS : List.Sorted (fun x x_1 => x ≤ x_1) S
hpqr : {p, q, r} = ↑S
⊢ S.length = 3
tactic: apply admissible_of_one_lt_sumInv_aux hS _ H
state_before: p q r : ℕ+
S : List ℕ+ := sort (fun x x_1 => x ≤ x_1) {p, q, r}
H : 1 < sumInv ↑S
hS : List.Sorted (fun x x_1 => x ≤ x_1) S
hpqr : {p, q, r} = ↑S
⊢ S.length = 3
state_after: no goals
tactic: simp only [S, insert_eq_cons, length_sort, card_cons, card_singleton]
Theorem: SimpleGraph.chromaticNumber_eq_iff_forall_surjective
File: Mathlib/Combinatorics/SimpleGraph/Coloring.lean

Proof steps:
state_before: V : Type u
G : SimpleGraph V
n : ℕ
α : Type u_1
β : Type u_2
C : G.Coloring α
hG : G.Colorable n
⊢ G.chromaticNumber = ↑n ↔ ∀ (C : G.Coloring (Fin n)), Surjective ⇑C
state_after: no goals
tactic: rw [← hG.chromaticNumber_le.ge_iff_eq, le_chromaticNumber_iff_forall_surjective]
Theorem: Mathlib.Tactic.PushNeg.empty_ne_eq_nonempty
File: Mathlib/Tactic/PushNeg.lean

Proof steps:
state_before: p q : Prop
α : Sort u_1
s✝ : α → Prop
β : Type u_2
inst✝ : LinearOrder β
s : Set β
⊢ (∅ ≠ s) = s.Nonempty
state_after: no goals
tactic: rw [ne_comm, ne_empty_eq_nonempty]
Theorem: Matrix.transpose_fromColumns
File: Mathlib/Data/Matrix/ColumnRowPartitioned.lean

Proof steps:
state_before: R : Type u_1
m : Type u_2
m₁ : Type u_3
m₂ : Type u_4
n : Type u_5
n₁ : Type u_6
n₂ : Type u_7
inst✝¹¹ : Fintype m
inst✝¹⁰ : Fintype m₁
inst✝⁹ : Fintype m₂
inst✝⁸ : Fintype n
inst✝⁷ : Fintype n₁
inst✝⁶ : Fintype n₂
inst✝⁵ : DecidableEq m
inst✝⁴ : DecidableEq m₁
inst✝³ : DecidableEq m₂
inst✝² : DecidableEq n
inst✝¹ : DecidableEq n₁
inst✝ : DecidableEq n₂
A₁ : Matrix m n₁ R
A₂ : Matrix m n₂ R
⊢ (A₁.fromColumns A₂)ᵀ = A₁ᵀ.fromRows A₂ᵀ
state_after: no goals
tactic: ext (i | i) j <;> simp
Theorem: slope_neg
File: Mathlib/LinearAlgebra/AffineSpace/Slope.lean

Proof steps:
state_before: k : Type u_1
E : Type u_2
PE : Type u_3
inst✝³ : Field k
inst✝² : AddCommGroup E
inst✝¹ : Module k E
inst✝ : AddTorsor E PE
f : k → E
x y : k
⊢ slope (fun t => -f t) x y = -slope f x y
state_after: no goals
tactic: simp only [slope_def_module, neg_sub_neg, ← smul_neg, neg_sub]
Theorem: Subsemiring.coe_pow
File: Mathlib/Algebra/Ring/Subsemiring/Basic.lean

Proof steps:
state_before: R✝ : Type u
S : Type v
T : Type w
inst✝³ : NonAssocSemiring R✝
M : Submonoid R✝
inst✝² : NonAssocSemiring S
inst✝¹ : NonAssocSemiring T
s✝ : Subsemiring R✝
R : Type u_1
inst✝ : Semiring R
s : Subsemiring R
x : ↥s
n : ℕ
⊢ ↑(x ^ n) = ↑x ^ n
state_after: case zero
R✝ : Type u
S : Type v
T : Type w
inst✝³ : NonAssocSemiring R✝
M : Submonoid R✝
inst✝² : NonAssocSemiring S
inst✝¹ : NonAssocSemiring T
s✝ : Subsemiring R✝
R : Type u_1
inst✝ : Semiring R
s : Subsemiring R
x : ↥s
⊢ ↑(x ^ 0) = ↑x ^ 0

case succ
R✝ : Type u
S : Type v
T : Type w
inst✝³ : NonAssocSemiring R✝
M : Submonoid R✝
inst✝² : NonAssocSemiring S
inst✝¹ : NonAssocSemiring T
s✝ : Subsemiring R✝
R : Type u_1
inst✝ : Semiring R
s : Subsemiring R
x : ↥s
n : ℕ
ih : ↑(x ^ n) = ↑x ^ n
⊢ ↑(x ^ (n + 1)) = ↑x ^ (n + 1)
tactic: induction' n with n ih
Theorem: Nat.coprime_div_gcd_of_squarefree
File: Mathlib/Data/Nat/Squarefree.lean

Proof steps:
state_before: s : Finset ℕ
m n p : ℕ
hm : Squarefree m
hn : n ≠ 0
⊢ (m / m.gcd n).Coprime n
state_after: s : Finset ℕ
m n p : ℕ
hm : Squarefree m
hn : n ≠ 0
this : (m / m.gcd n).Coprime (m.gcd n)
⊢ (m / m.gcd n).Coprime n
tactic: have : Coprime (m / gcd m n) (gcd m n) :=
    coprime_of_squarefree_mul <| by simpa [Nat.div_mul_cancel, gcd_dvd_left]
state_before: s : Finset ℕ
m n p : ℕ
hm : Squarefree m
hn : n ≠ 0
this : (m / m.gcd n).Coprime (m.gcd n)
⊢ (m / m.gcd n).Coprime n
state_after: no goals
tactic: simpa [Nat.div_mul_cancel, gcd_dvd_right] using
    (coprime_div_gcd_div_gcd (m := m) (gcd_ne_zero_right hn).bot_lt).mul_right this
Theorem: List.Chain'.two_mul_count_bool_of_even
File: Mathlib/Data/Bool/Count.lean

Proof steps:
state_before: l : List Bool
hl : Chain' (fun x x_1 => x ≠ x_1) l
h2 : Even l.length
b : Bool
⊢ 2 * count b l = l.length
state_after: no goals
tactic: rw [← count_not_add_count l b, hl.count_not_eq_count h2, two_mul]