1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: List.mem_lookupAll
File: Mathlib/Data/List/Sigma.lean

tactic: simp
state_before: α : Type u
β : α → Type v
l l₁ l₂ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
⊢ b ∈ lookupAll a [] ↔ ⟨a, b⟩ ∈ []
state_after: no goals

tactic: by_cases h : a = a'
state_before: α : Type u
β : α → Type v
l✝ l₁ l₂ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
a' : α
b' : β a'
l : List (Sigma β)
⊢ b ∈ lookupAll a (⟨a', b'⟩ :: l) ↔ ⟨a, b⟩ ∈ ⟨a', b'⟩ :: l
state_after: case pos
α : Type u
β : α → Type v
l✝ l₁ l₂ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
a' : α
b' : β a'
l : List (Sigma β)
h : a = a'
⊢ b ∈ lookupAll a (⟨a', b'⟩ :: l) ↔ ⟨a, b⟩ ∈ ⟨a', b'⟩ :: l

case neg
α : Type u
β : α → Type v
l✝ l₁ l₂ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
a' : α
b' : β a'
l : List (Sigma β)
h : ¬a = a'
⊢ b ∈ lookupAll a (⟨a', b'⟩ :: l) ↔ ⟨a, b⟩ ∈ ⟨a', b'⟩ :: l

tactic: subst h
state_before: case pos
α : Type u
β : α → Type v
l✝ l₁ l₂ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
a' : α
b' : β a'
l : List (Sigma β)
h : a = a'
⊢ b ∈ lookupAll a (⟨a', b'⟩ :: l) ↔ ⟨a, b⟩ ∈ ⟨a', b'⟩ :: l
state_after: case pos
α : Type u
β : α → Type v
l✝ l₁ l₂ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
l : List (Sigma β)
b' : β a
⊢ b ∈ lookupAll a (⟨a, b'⟩ :: l) ↔ ⟨a, b⟩ ∈ ⟨a, b'⟩ :: l

tactic: simp [*, mem_lookupAll]
state_before: case pos
α : Type u
β : α → Type v
l✝ l₁ l₂ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
l : List (Sigma β)
b' : β a
⊢ b ∈ lookupAll a (⟨a, b'⟩ :: l) ↔ ⟨a, b⟩ ∈ ⟨a, b'⟩ :: l
state_after: no goals

tactic: simp [*, mem_lookupAll]
state_before: case neg
α : Type u
β : α → Type v
l✝ l₁ l₂ : List (Sigma β)
inst✝ : DecidableEq α
a : α
b : β a
a' : α
b' : β a'
l : List (Sigma β)
h : ¬a = a'
⊢ b ∈ lookupAll a (⟨a', b'⟩ :: l) ↔ ⟨a, b⟩ ∈ ⟨a', b'⟩ :: l
state_after: no goals
Theorem: Batteries.PairingHeapImp.Heap.WF.merge_node
File: .lake/packages/batteries/Batteries/Data/PairingHeap.lean

tactic: unfold merge
state_before: α✝ : Type u_1
le : α✝ → α✝ → Bool
a₁ : α✝
c₁ : Heap α✝
a₂ : α✝
c₂ s₁ s₂ : Heap α✝
h₁ : NodeWF le a₁ c₁
h₂ : NodeWF le a₂ c₂
⊢ WF le (merge le (Heap.node a₁ c₁ s₁) (Heap.node a₂ c₂ s₂))
state_after: α✝ : Type u_1
le : α✝ → α✝ → Bool
a₁ : α✝
c₁ : Heap α✝
a₂ : α✝
c₂ s₁ s₂ : Heap α✝
h₁ : NodeWF le a₁ c₁
h₂ : NodeWF le a₂ c₂
⊢ WF le
    (match Heap.node a₁ c₁ s₁, Heap.node a₂ c₂ s₂ with
    | Heap.nil, Heap.nil => Heap.nil
    | Heap.nil, Heap.node a₂ c₂ sibling => Heap.node a₂ c₂ Heap.nil
    | Heap.node a₁ c₁ sibling, Heap.nil => Heap.node a₁ c₁ Heap.nil
    | Heap.node a₁ c₁ sibling, Heap.node a₂ c₂ sibling_1 =>
      if le a₁ a₂ = true then Heap.node a₁ (Heap.node a₂ c₂ c₁) Heap.nil
      else Heap.node a₂ (Heap.node a₁ c₁ c₂) Heap.nil)

tactic: dsimp
state_before: α✝ : Type u_1
le : α✝ → α✝ → Bool
a₁ : α✝
c₁ : Heap α✝
a₂ : α✝
c₂ s₁ s₂ : Heap α✝
h₁ : NodeWF le a₁ c₁
h₂ : NodeWF le a₂ c₂
⊢ WF le
    (match Heap.node a₁ c₁ s₁, Heap.node a₂ c₂ s₂ with
    | Heap.nil, Heap.nil => Heap.nil
    | Heap.nil, Heap.node a₂ c₂ sibling => Heap.node a₂ c₂ Heap.nil
    | Heap.node a₁ c₁ sibling, Heap.nil => Heap.node a₁ c₁ Heap.nil
    | Heap.node a₁ c₁ sibling, Heap.node a₂ c₂ sibling_1 =>
      if le a₁ a₂ = true then Heap.node a₁ (Heap.node a₂ c₂ c₁) Heap.nil
      else Heap.node a₂ (Heap.node a₁ c₁ c₂) Heap.nil)
state_after: α✝ : Type u_1
le : α✝ → α✝ → Bool
a₁ : α✝
c₁ : Heap α✝
a₂ : α✝
c₂ s₁ s₂ : Heap α✝
h₁ : NodeWF le a₁ c₁
h₂ : NodeWF le a₂ c₂
⊢ WF le
    (if le a₁ a₂ = true then Heap.node a₁ (Heap.node a₂ c₂ c₁) Heap.nil else Heap.node a₂ (Heap.node a₁ c₁ c₂) Heap.nil)

tactic: split <;> rename_i h
state_before: α✝ : Type u_1
le : α✝ → α✝ → Bool
a₁ : α✝
c₁ : Heap α✝
a₂ : α✝
c₂ s₁ s₂ : Heap α✝
h₁ : NodeWF le a₁ c₁
h₂ : NodeWF le a₂ c₂
⊢ WF le
    (if le a₁ a₂ = true then Heap.node a₁ (Heap.node a₂ c₂ c₁) Heap.nil else Heap.node a₂ (Heap.node a₁ c₁ c₂) Heap.nil)
state_after: case isTrue
α✝ : Type u_1
le : α✝ → α✝ → Bool
a₁ : α✝
c₁ : Heap α✝
a₂ : α✝
c₂ s₁ s₂ : Heap α✝
h₁ : NodeWF le a₁ c₁
h₂ : NodeWF le a₂ c₂
h : le a₁ a₂ = true
⊢ WF le (Heap.node a₁ (Heap.node a₂ c₂ c₁) Heap.nil)

case isFalse
α✝ : Type u_1
le : α✝ → α✝ → Bool
a₁ : α✝
c₁ : Heap α✝
a₂ : α✝
c₂ s₁ s₂ : Heap α✝
h₁ : NodeWF le a₁ c₁
h₂ : NodeWF le a₂ c₂
h : ¬le a₁ a₂ = true
⊢ WF le (Heap.node a₂ (Heap.node a₁ c₁ c₂) Heap.nil)

tactic: exact node ⟨fun [_] => h, h₂, h₁⟩
state_before: case isTrue
α✝ : Type u_1
le : α✝ → α✝ → Bool
a₁ : α✝
c₁ : Heap α✝
a₂ : α✝
c₂ s₁ s₂ : Heap α✝
h₁ : NodeWF le a₁ c₁
h₂ : NodeWF le a₂ c₂
h : le a₁ a₂ = true
⊢ WF le (Heap.node a₁ (Heap.node a₂ c₂ c₁) Heap.nil)
state_after: no goals

tactic: exact node ⟨fun [_] => TotalBLE.total.resolve_left h, h₁, h₂⟩
state_before: case isFalse
α✝ : Type u_1
le : α✝ → α✝ → Bool
a₁ : α✝
c₁ : Heap α✝
a₂ : α✝
c₂ s₁ s₂ : Heap α✝
h₁ : NodeWF le a₁ c₁
h₂ : NodeWF le a₂ c₂
h : ¬le a₁ a₂ = true
⊢ WF le (Heap.node a₂ (Heap.node a₁ c₁ c₂) Heap.nil)
state_after: no goals
Theorem: Nat.divisors_subset_properDivisors
File: Mathlib/NumberTheory/Divisors.lean

tactic: apply Finset.subset_iff.2
state_before: n m : ℕ
hzero : n ≠ 0
h : m ∣ n
hdiff : m ≠ n
⊢ m.divisors ⊆ n.properDivisors
state_after: n m : ℕ
hzero : n ≠ 0
h : m ∣ n
hdiff : m ≠ n
⊢ ∀ ⦃x : ℕ⦄, x ∈ m.divisors → x ∈ n.properDivisors

tactic: intro x hx
state_before: n m : ℕ
hzero : n ≠ 0
h : m ∣ n
hdiff : m ≠ n
⊢ ∀ ⦃x : ℕ⦄, x ∈ m.divisors → x ∈ n.properDivisors
state_after: n m : ℕ
hzero : n ≠ 0
h : m ∣ n
hdiff : m ≠ n
x : ℕ
hx : x ∈ m.divisors
⊢ x ∈ n.properDivisors

tactic: exact
  Nat.mem_properDivisors.2
    ⟨(Nat.mem_divisors.1 hx).1.trans h,
      lt_of_le_of_lt (divisor_le hx)
        (lt_of_le_of_ne (divisor_le (Nat.mem_divisors.2 ⟨h, hzero⟩)) hdiff)⟩
state_before: n m : ℕ
hzero : n ≠ 0
h : m ∣ n
hdiff : m ≠ n
x : ℕ
hx : x ∈ m.divisors
⊢ x ∈ n.properDivisors
state_after: no goals
Theorem: let_value_heq
File: Mathlib/Init/Logic.lean

tactic: cases h
state_before: a b✝ c d : Prop
p : ?m.12207
α : Sort v
β : α → Sort u
a₁ a₂ : α
b : (x : α) → β x
h : a₁ = a₂
⊢ HEq
    (let x := a₁;
    b x)
    (let x := a₂;
    b x)
state_after: case refl
a b✝ c d : Prop
p : ?m.12207
α : Sort v
β : α → Sort u
a₁ : α
b : (x : α) → β x
⊢ HEq
    (let x := a₁;
    b x)
    (let x := a₁;
    b x)

tactic: rfl
state_before: case refl
a b✝ c d : Prop
p : ?m.12207
α : Sort v
β : α → Sort u
a₁ : α
b : (x : α) → β x
⊢ HEq
    (let x := a₁;
    b x)
    (let x := a₁;
    b x)
state_after: no goals
Theorem: Computable.pair
File: Mathlib/Computability/Partrec.lean

tactic: cases decode (α := α) n <;> simp [Seq.seq]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
σ : Type u_4
inst✝³ : Primcodable α
inst✝² : Primcodable β
inst✝¹ : Primcodable γ
inst✝ : Primcodable σ
f : α → β
g : α → γ
hf : Computable f
hg : Computable g
n : ℕ
⊢ (Seq.seq (Nat.pair <$> (↑(decode n)).bind fun a => map encode (↑f a)) fun x =>
      (↑(decode n)).bind fun a => map encode (↑g a)) =
    (↑(decode n)).bind fun a => map encode ((↑fun a => (f a, g a)) a)
state_after: no goals
Theorem: Subfield.rangeOfWType_eq_top
File: Mathlib/SetTheory/Cardinal/Subfield.lean

tactic: rw [← SetLike.mem_coe, ← Subtype.val_injective.mem_set_image]
state_before: α : Type u
s : Set α
inst✝ : DivisionRing α
a : ↥(closure s)
x✝ : a ∈ ⊤
⊢ a ∈ Subfield.rangeOfWType s
state_after: α : Type u
s : Set α
inst✝ : DivisionRing α
a : ↥(closure s)
x✝ : a ∈ ⊤
⊢ ↑a ∈ Subtype.val '' ↑(Subfield.rangeOfWType s)

tactic: change ↑a ∈ map (closure s).subtype _
state_before: α : Type u
s : Set α
inst✝ : DivisionRing α
a : ↥(closure s)
x✝ : a ∈ ⊤
⊢ ↑a ∈ Subtype.val '' ↑(Subfield.rangeOfWType s)
state_after: α : Type u
s : Set α
inst✝ : DivisionRing α
a : ↥(closure s)
x✝ : a ∈ ⊤
⊢ ↑a ∈ map (closure s).subtype (Subfield.rangeOfWType s)

tactic: refine closure_le.mpr (fun a ha ↦ ?_) a.prop
state_before: α : Type u
s : Set α
inst✝ : DivisionRing α
a : ↥(closure s)
x✝ : a ∈ ⊤
⊢ ↑a ∈ map (closure s).subtype (Subfield.rangeOfWType s)
state_after: α : Type u
s : Set α
inst✝ : DivisionRing α
a✝ : ↥(closure s)
x✝ : a✝ ∈ ⊤
a : α
ha : a ∈ s
⊢ a ∈ ↑(map (closure s).subtype (Subfield.rangeOfWType s))

tactic: exact ⟨⟨a, subset_closure ha⟩, ⟨WType.mk (.inr ⟨a, ha⟩) Empty.rec, rfl⟩, rfl⟩
state_before: α : Type u
s : Set α
inst✝ : DivisionRing α
a✝ : ↥(closure s)
x✝ : a✝ ∈ ⊤
a : α
ha : a ∈ s
⊢ a ∈ ↑(map (closure s).subtype (Subfield.rangeOfWType s))
state_after: no goals
Theorem: Polynomial.taylor_zero'
File: Mathlib/Algebra/Polynomial/Taylor.lean

tactic: ext
state_before: R : Type u_1
inst✝ : Semiring R
r : R
f : R[X]
⊢ taylor 0 = LinearMap.id
state_after: case h.h.a
R : Type u_1
inst✝ : Semiring R
r : R
f : R[X]
n✝¹ n✝ : ℕ
⊢ ((taylor 0 ∘ₗ monomial n✝¹) 1).coeff n✝ = ((LinearMap.id ∘ₗ monomial n✝¹) 1).coeff n✝

tactic: simp only [taylor_apply, add_zero, comp_X, _root_.map_zero, LinearMap.id_comp,
  Function.comp_apply, LinearMap.coe_comp]
state_before: case h.h.a
R : Type u_1
inst✝ : Semiring R
r : R
f : R[X]
n✝¹ n✝ : ℕ
⊢ ((taylor 0 ∘ₗ monomial n✝¹) 1).coeff n✝ = ((LinearMap.id ∘ₗ monomial n✝¹) 1).coeff n✝
state_after: no goals
Theorem: Vector.mem_iff_get
File: Mathlib/Data/Vector/Mem.lean

tactic: simp only [List.mem_iff_get, Fin.exists_iff, Vector.get_eq_get]
state_before: α : Type u_1
β : Type u_2
n : ℕ
a a' : α
v : Vector α n
⊢ a ∈ v.toList ↔ ∃ i, v.get i = a
state_after: α : Type u_1
β : Type u_2
n : ℕ
a a' : α
v : Vector α n
⊢ (∃ i, ∃ (h : i < v.toList.length), v.toList.get ⟨i, h⟩ = a) ↔ ∃ i, ∃ (h : i < n), v.toList.get (Fin.cast ⋯ ⟨i, h⟩) = a

tactic: exact
  ⟨fun ⟨i, hi, h⟩ => ⟨i, by rwa [toList_length] at hi, h⟩, fun ⟨i, hi, h⟩ =>
    ⟨i, by rwa [toList_length], h⟩⟩
state_before: α : Type u_1
β : Type u_2
n : ℕ
a a' : α
v : Vector α n
⊢ (∃ i, ∃ (h : i < v.toList.length), v.toList.get ⟨i, h⟩ = a) ↔ ∃ i, ∃ (h : i < n), v.toList.get (Fin.cast ⋯ ⟨i, h⟩) = a
state_after: no goals

tactic: rwa [toList_length] at hi
state_before: α : Type u_1
β : Type u_2
n : ℕ
a a' : α
v : Vector α n
x✝ : ∃ i, ∃ (h : i < v.toList.length), v.toList.get ⟨i, h⟩ = a
i : ℕ
hi : i < v.toList.length
h : v.toList.get ⟨i, hi⟩ = a
⊢ i < n
state_after: no goals

tactic: rwa [toList_length]
state_before: α : Type u_1
β : Type u_2
n : ℕ
a a' : α
v : Vector α n
x✝ : ∃ i, ∃ (h : i < n), v.toList.get (Fin.cast ⋯ ⟨i, h⟩) = a
i : ℕ
hi : i < n
h : v.toList.get (Fin.cast ⋯ ⟨i, hi⟩) = a
⊢ i < v.toList.length
state_after: no goals
Theorem: CategoryTheory.ShortComplex.mapRightHomologyIso_inv_naturality
File: Mathlib/Algebra/Homology/ShortComplex/PreservesHomology.lean

tactic: rw [← cancel_epi (S₁.mapRightHomologyIso F).hom, ← mapRightHomologyIso_hom_naturality_assoc,
  Iso.hom_inv_id, comp_id, Iso.hom_inv_id_assoc]
state_before: C : Type u_1
D : Type u_2
inst✝⁹ : Category.{u_3, u_1} C
inst✝⁸ : Category.{u_4, u_2} D
inst✝⁷ : HasZeroMorphisms C
inst✝⁶ : HasZeroMorphisms D
S : ShortComplex C
h₁✝ : S.LeftHomologyData
h₂✝ : S.RightHomologyData
F✝ : C ⥤ D
inst✝⁵ : F✝.PreservesZeroMorphisms
hl : S.LeftHomologyData
hr : S.RightHomologyData
S₁ S₂ : ShortComplex C
φ : S₁ ⟶ S₂
hl₁ : S₁.LeftHomologyData
hr₁ : S₁.RightHomologyData
hl₂ : S₂.LeftHomologyData
hr₂ : S₂.RightHomologyData
h₁ : S₁.HomologyData
h₂ : S₂.HomologyData
F : C ⥤ D
inst✝⁴ : F.PreservesZeroMorphisms
inst✝³ : S₁.HasRightHomology
inst✝² : S₂.HasRightHomology
inst✝¹ : F.PreservesRightHomologyOf S₁
inst✝ : F.PreservesRightHomologyOf S₂
⊢ F.map (rightHomologyMap φ) ≫ (S₂.mapRightHomologyIso F).inv =
    (S₁.mapRightHomologyIso F).inv ≫ rightHomologyMap (F.mapShortComplex.map φ)
state_after: no goals
Theorem: ContinuousMap.Homotopy.trans_apply
File: Mathlib/Topology/Homotopy/Basic.lean

tactic: rw [extend, ContinuousMap.coe_IccExtend, Set.IccExtend_of_mem]
state_before: case neg
F✝ : Type u_1
X : Type u
Y : Type v
Z : Type w
Z' : Type x
ι : Type u_2
inst✝³ : TopologicalSpace X
inst✝² : TopologicalSpace Y
inst✝¹ : TopologicalSpace Z
inst✝ : TopologicalSpace Z'
f₀ f₁ f₂ : C(X, Y)
F : f₀.Homotopy f₁
G : f₁.Homotopy f₂
x : ↑I × X
h✝ : ¬↑x.1 ≤ 1 / 2
⊢ (G.extend (2 * ↑x.1 - 1)) x.2 = G (⟨2 * ↑x.1 - 1, ⋯⟩, x.2)
state_after: case neg
F✝ : Type u_1
X : Type u
Y : Type v
Z : Type w
Z' : Type x
ι : Type u_2
inst✝³ : TopologicalSpace X
inst✝² : TopologicalSpace Y
inst✝¹ : TopologicalSpace Z
inst✝ : TopologicalSpace Z'
f₀ f₁ f₂ : C(X, Y)
F : f₀.Homotopy f₁
G : f₁.Homotopy f₂
x : ↑I × X
h✝ : ¬↑x.1 ≤ 1 / 2
⊢ (G.curry ⟨2 * ↑x.1 - 1, ?neg.hx✝⟩) x.2 = G (⟨2 * ↑x.1 - 1, ⋯⟩, x.2)

case neg.hx
F✝ : Type u_1
X : Type u
Y : Type v
Z : Type w
Z' : Type x
ι : Type u_2
inst✝³ : TopologicalSpace X
inst✝² : TopologicalSpace Y
inst✝¹ : TopologicalSpace Z
inst✝ : TopologicalSpace Z'
f₀ f₁ f₂ : C(X, Y)
F : f₀.Homotopy f₁
G : f₁.Homotopy f₂
x : ↑I × X
h✝ : ¬↑x.1 ≤ 1 / 2
⊢ 2 * ↑x.1 - 1 ∈ Set.Icc 0 1

tactic: rfl
state_before: case neg
F✝ : Type u_1
X : Type u
Y : Type v
Z : Type w
Z' : Type x
ι : Type u_2
inst✝³ : TopologicalSpace X
inst✝² : TopologicalSpace Y
inst✝¹ : TopologicalSpace Z
inst✝ : TopologicalSpace Z'
f₀ f₁ f₂ : C(X, Y)
F : f₀.Homotopy f₁
G : f₁.Homotopy f₂
x : ↑I × X
h✝ : ¬↑x.1 ≤ 1 / 2
⊢ (G.curry ⟨2 * ↑x.1 - 1, ?neg.hx✝⟩) x.2 = G (⟨2 * ↑x.1 - 1, ⋯⟩, x.2)

case neg.hx
F✝ : Type u_1
X : Type u
Y : Type v
Z : Type w
Z' : Type x
ι : Type u_2
inst✝³ : TopologicalSpace X
inst✝² : TopologicalSpace Y
inst✝¹ : TopologicalSpace Z
inst✝ : TopologicalSpace Z'
f₀ f₁ f₂ : C(X, Y)
F : f₀.Homotopy f₁
G : f₁.Homotopy f₂
x : ↑I × X
h✝ : ¬↑x.1 ≤ 1 / 2
⊢ 2 * ↑x.1 - 1 ∈ Set.Icc 0 1
state_after: no goals
Theorem: Finset.prod_sdiff_lt_prod_sdiff
File: Mathlib/Algebra/Order/BigOperators/Group/Finset.lean

tactic: rw [← mul_lt_mul_iff_right, ← prod_union (disjoint_sdiff_inter _ _), sdiff_union_inter,
  ← prod_union, inter_comm, sdiff_union_inter]
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
M : Type u_4
N : Type u_5
G : Type u_6
k : Type u_7
R : Type u_8
inst✝¹ : OrderedCancelCommMonoid M
f g : ι → M
s t : Finset ι
inst✝ : DecidableEq ι
⊢ ∏ i ∈ s \ t, f i < ∏ i ∈ t \ s, f i ↔ ∏ i ∈ s, f i < ∏ i ∈ t, f i
state_after: ι : Type u_1
α : Type u_2
β : Type u_3
M : Type u_4
N : Type u_5
G : Type u_6
k : Type u_7
R : Type u_8
inst✝¹ : OrderedCancelCommMonoid M
f g : ι → M
s t : Finset ι
inst✝ : DecidableEq ι
⊢ Disjoint (t \ s) (s ∩ t)

tactic: simpa only [inter_comm] using disjoint_sdiff_inter t s
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
M : Type u_4
N : Type u_5
G : Type u_6
k : Type u_7
R : Type u_8
inst✝¹ : OrderedCancelCommMonoid M
f g : ι → M
s t : Finset ι
inst✝ : DecidableEq ι
⊢ Disjoint (t \ s) (s ∩ t)
state_after: no goals
Theorem: Homeomorph.map_nhds_eq
File: Mathlib/Topology/Homeomorph.lean

tactic: simp
state_before: X : Type u_1
Y : Type u_2
Z : Type u_3
inst✝⁴ : TopologicalSpace X
inst✝³ : TopologicalSpace Y
inst✝² : TopologicalSpace Z
X' : Type u_4
Y' : Type u_5
inst✝¹ : TopologicalSpace X'
inst✝ : TopologicalSpace Y'
h : X ≃ₜ Y
x : X
⊢ range ⇑h ∈ 𝓝 (h x)
state_after: no goals
Theorem: Cycle.next_reverse_eq_prev
File: Mathlib/Data/List/Cycle.lean

tactic: simp [← prev_reverse_eq_next]
state_before: α : Type u_1
inst✝ : DecidableEq α
s : Cycle α
hs : s.Nodup
x : α
hx : x ∈ s
⊢ s.reverse.next ⋯ x ⋯ = s.prev hs x hx
state_after: no goals
Theorem: Bornology.inCompact.isBounded_iff
File: Mathlib/Topology/Compactness/Compact.lean

tactic: change sᶜ ∈ Filter.cocompact X ↔ _
state_before: X : Type u
Y : Type v
ι : Type u_1
inst✝¹ : TopologicalSpace X
inst✝ : TopologicalSpace Y
s t : Set X
⊢ IsBounded s ↔ ∃ t, IsCompact t ∧ s ⊆ t
state_after: X : Type u
Y : Type v
ι : Type u_1
inst✝¹ : TopologicalSpace X
inst✝ : TopologicalSpace Y
s t : Set X
⊢ sᶜ ∈ cocompact X ↔ ∃ t, IsCompact t ∧ s ⊆ t

tactic: rw [Filter.mem_cocompact]
state_before: X : Type u
Y : Type v
ι : Type u_1
inst✝¹ : TopologicalSpace X
inst✝ : TopologicalSpace Y
s t : Set X
⊢ sᶜ ∈ cocompact X ↔ ∃ t, IsCompact t ∧ s ⊆ t
state_after: X : Type u
Y : Type v
ι : Type u_1
inst✝¹ : TopologicalSpace X
inst✝ : TopologicalSpace Y
s t : Set X
⊢ (∃ t, IsCompact t ∧ tᶜ ⊆ sᶜ) ↔ ∃ t, IsCompact t ∧ s ⊆ t

tactic: simp
state_before: X : Type u
Y : Type v
ι : Type u_1
inst✝¹ : TopologicalSpace X
inst✝ : TopologicalSpace Y
s t : Set X
⊢ (∃ t, IsCompact t ∧ tᶜ ⊆ sᶜ) ↔ ∃ t, IsCompact t ∧ s ⊆ t
state_after: no goals
Theorem: Nat.card_eq_card_toFinset
File: Mathlib/SetTheory/Cardinal/Finite.lean

tactic: simp only [← Nat.card_eq_finsetCard, s.mem_toFinset]
state_before: α : Type u_1
β : Type u_2
s : Set α
inst✝ : Fintype ↑s
⊢ Nat.card ↑s = s.toFinset.card
state_after: no goals
Theorem: Matroid.basis'_restrict_iff
File: Mathlib/Data/Matroid/Restrict.lean

tactic: simp_rw [Basis', mem_maximals_setOf_iff, restrict_indep_iff, subset_inter_iff, and_imp]
state_before: α : Type u_1
M : Matroid α
R I J X Y : Set α
⊢ (M ↾ R).Basis' I X ↔ M.Basis' I (X ∩ R) ∧ I ⊆ R
state_after: α : Type u_1
M : Matroid α
R I J X Y : Set α
⊢ (((M.Indep I ∧ I ⊆ R) ∧ I ⊆ X) ∧ ∀ ⦃y : Set α⦄, M.Indep y → y ⊆ R → y ⊆ X → I ⊆ y → I = y) ↔
    ((M.Indep I ∧ I ⊆ X ∧ I ⊆ R) ∧ ∀ ⦃y : Set α⦄, M.Indep y → y ⊆ X → y ⊆ R → I ⊆ y → I = y) ∧ I ⊆ R

tactic: tauto
state_before: α : Type u_1
M : Matroid α
R I J X Y : Set α
⊢ (((M.Indep I ∧ I ⊆ R) ∧ I ⊆ X) ∧ ∀ ⦃y : Set α⦄, M.Indep y → y ⊆ R → y ⊆ X → I ⊆ y → I = y) ↔
    ((M.Indep I ∧ I ⊆ X ∧ I ⊆ R) ∧ ∀ ⦃y : Set α⦄, M.Indep y → y ⊆ X → y ⊆ R → I ⊆ y → I = y) ∧ I ⊆ R
state_after: no goals
Theorem: CategoryTheory.Over.over_right
File: Mathlib/CategoryTheory/Comma/Over.lean

tactic: simp only
state_before: T : Type u₁
inst✝ : Category.{v₁, u₁} T
X : T
U : Over X
⊢ U.right = { as := PUnit.unit }
state_after: no goals
Theorem: Finsupp.support_ceilDiv_subset
File: Mathlib/Algebra/Order/Floor/Div.lean

tactic: simp (config := { contextual := true}) [Finset.subset_iff, not_imp_not]
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
inst✝³ : OrderedAddCommMonoid α
inst✝² : OrderedAddCommMonoid β
inst✝¹ : SMulZeroClass α β
inst✝ : CeilDiv α β
f : ι →₀ β
a : α
⊢ (f ⌈/⌉ a).support ⊆ f.support
state_after: no goals
Theorem: CategoryTheory.NatTrans.congr
File: Mathlib/CategoryTheory/EqToHom.lean

tactic: rw [α.naturality_assoc]
state_before: C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
β : Sort u_1
D : Type u₂
inst✝ : Category.{v₂, u₂} D
F G : C ⥤ D
α : F ⟶ G
X Y : C
h : X = Y
⊢ α.app X = F.map (eqToHom h) ≫ α.app Y ≫ G.map (eqToHom ⋯)
state_after: C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
β : Sort u_1
D : Type u₂
inst✝ : Category.{v₂, u₂} D
F G : C ⥤ D
α : F ⟶ G
X Y : C
h : X = Y
⊢ α.app X = α.app X ≫ G.map (eqToHom h) ≫ G.map (eqToHom ⋯)

tactic: simp [eqToHom_map]
state_before: C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
β : Sort u_1
D : Type u₂
inst✝ : Category.{v₂, u₂} D
F G : C ⥤ D
α : F ⟶ G
X Y : C
h : X = Y
⊢ α.app X = α.app X ≫ G.map (eqToHom h) ≫ G.map (eqToHom ⋯)
state_after: no goals
Theorem: Polynomial.eval_natCast
File: Mathlib/Algebra/Polynomial/Eval.lean

tactic: simp only [← C_eq_natCast, eval_C]
state_before: R : Type u
S : Type v
T : Type w
ι : Type y
a b : R
m n✝ : ℕ
inst✝ : Semiring R
p q r : R[X]
x : R
n : ℕ
⊢ eval x ↑n = ↑n
state_after: no goals
Theorem: pow_dite
File: Mathlib/Algebra/Group/Basic.lean

tactic: split_ifs <;> rfl
state_before: α : Type u_1
β : Type u_2
G : Type u_3
M : Type u_4
inst✝¹ : Pow α β
p : Prop
inst✝ : Decidable p
a : α
b : p → β
c : ¬p → β
⊢ (a ^ if h : p then b h else c h) = if h : p then a ^ b h else a ^ c h
state_after: no goals
Theorem: HomogeneousLocalization.val_pow
File: Mathlib/RingTheory/GradedAlgebra/HomogeneousLocalization.lean

tactic: rw [← mk_pow, val_mk, val_mk, Localization.mk_pow]
state_before: ι : Type u_1
R : Type u_2
A : Type u_3
inst✝⁵ : AddCommMonoid ι
inst✝⁴ : DecidableEq ι
inst✝³ : CommRing R
inst✝² : CommRing A
inst✝¹ : Algebra R A
𝒜 : ι → Submodule R A
inst✝ : GradedAlgebra 𝒜
x : Submonoid A
y : NumDenSameDeg 𝒜 x
n : ℕ
⊢ (Quotient.mk'' y ^ n).val = val (Quotient.mk'' y) ^ n
state_after: ι : Type u_1
R : Type u_2
A : Type u_3
inst✝⁵ : AddCommMonoid ι
inst✝⁴ : DecidableEq ι
inst✝³ : CommRing R
inst✝² : CommRing A
inst✝¹ : Algebra R A
𝒜 : ι → Submodule R A
inst✝ : GradedAlgebra 𝒜
x : Submonoid A
y : NumDenSameDeg 𝒜 x
n : ℕ
⊢ Localization.mk ↑(y ^ n).num ⟨↑(y ^ n).den, ⋯⟩ = Localization.mk (↑y.num ^ n) (⟨↑y.den, ⋯⟩ ^ n)

tactic: rfl
state_before: ι : Type u_1
R : Type u_2
A : Type u_3
inst✝⁵ : AddCommMonoid ι
inst✝⁴ : DecidableEq ι
inst✝³ : CommRing R
inst✝² : CommRing A
inst✝¹ : Algebra R A
𝒜 : ι → Submodule R A
inst✝ : GradedAlgebra 𝒜
x : Submonoid A
y : NumDenSameDeg 𝒜 x
n : ℕ
⊢ Localization.mk ↑(y ^ n).num ⟨↑(y ^ n).den, ⋯⟩ = Localization.mk (↑y.num ^ n) (⟨↑y.den, ⋯⟩ ^ n)
state_after: no goals
Theorem: Nat.Prime.even_sub_one
File: Mathlib/Data/Nat/Prime.lean

tactic: rw [hn, Nat.add_sub_cancel, two_mul]
state_before: n✝ p : ℕ
hp : Prime p
h2 : p ≠ 2
n : ℕ
hn : p = 2 * n + 1
⊢ p - 1 = n + n
state_after: no goals
Theorem: CategoryTheory.MonoidalOfChosenFiniteProducts.symmetry
File: Mathlib/CategoryTheory/Monoidal/OfChosenFiniteProducts/Symmetric.lean

tactic: dsimp [tensorHom, Limits.BinaryFan.braiding]
state_before: C : Type u
inst✝ : Category.{v, u} C
X✝ Y✝ : C
𝒯 : LimitCone (Functor.empty C)
ℬ : (X Y : C) → LimitCone (pair X Y)
X Y : C
⊢ (BinaryFan.braiding (ℬ X Y).isLimit (ℬ Y X).isLimit).hom ≫ (BinaryFan.braiding (ℬ Y X).isLimit (ℬ X Y).isLimit).hom =
    𝟙 (tensorObj ℬ X Y)
state_after: C : Type u
inst✝ : Category.{v, u} C
X✝ Y✝ : C
𝒯 : LimitCone (Functor.empty C)
ℬ : (X Y : C) → LimitCone (pair X Y)
X Y : C
⊢ ((ℬ X Y).isLimit.conePointUniqueUpToIso (ℬ Y X).isLimit.swapBinaryFan).hom ≫
      ((ℬ Y X).isLimit.conePointUniqueUpToIso (ℬ X Y).isLimit.swapBinaryFan).hom =
    𝟙 (tensorObj ℬ X Y)

tactic: apply (ℬ _ _).isLimit.hom_ext
state_before: C : Type u
inst✝ : Category.{v, u} C
X✝ Y✝ : C
𝒯 : LimitCone (Functor.empty C)
ℬ : (X Y : C) → LimitCone (pair X Y)
X Y : C
⊢ ((ℬ X Y).isLimit.conePointUniqueUpToIso (ℬ Y X).isLimit.swapBinaryFan).hom ≫
      ((ℬ Y X).isLimit.conePointUniqueUpToIso (ℬ X Y).isLimit.swapBinaryFan).hom =
    𝟙 (tensorObj ℬ X Y)
state_after: C : Type u
inst✝ : Category.{v, u} C
X✝ Y✝ : C
𝒯 : LimitCone (Functor.empty C)
ℬ : (X Y : C) → LimitCone (pair X Y)
X Y : C
⊢ ∀ (j : Discrete WalkingPair),
    (((ℬ X Y).isLimit.conePointUniqueUpToIso (ℬ Y X).isLimit.swapBinaryFan).hom ≫
          ((ℬ Y X).isLimit.conePointUniqueUpToIso (ℬ X Y).isLimit.swapBinaryFan).hom) ≫
        (ℬ X Y).cone.π.app j =
      𝟙 (tensorObj ℬ X Y) ≫ (ℬ X Y).cone.π.app j

tactic: dsimp [Limits.IsLimit.conePointUniqueUpToIso]
state_before: case mk.right
C : Type u
inst✝ : Category.{v, u} C
X✝ Y✝ : C
𝒯 : LimitCone (Functor.empty C)
ℬ : (X Y : C) → LimitCone (pair X Y)
X Y : C
⊢ (((ℬ X Y).isLimit.conePointUniqueUpToIso (ℬ Y X).isLimit.swapBinaryFan).hom ≫
        ((ℬ Y X).isLimit.conePointUniqueUpToIso (ℬ X Y).isLimit.swapBinaryFan).hom) ≫
      (ℬ X Y).cone.π.app { as := WalkingPair.right } =
    𝟙 (tensorObj ℬ X Y) ≫ (ℬ X Y).cone.π.app { as := WalkingPair.right }
state_after: case mk.right
C : Type u
inst✝ : Category.{v, u} C
X✝ Y✝ : C
𝒯 : LimitCone (Functor.empty C)
ℬ : (X Y : C) → LimitCone (pair X Y)
X Y : C
⊢ ((ℬ Y X).isLimit.lift (BinaryFan.swap (ℬ X Y).cone) ≫ (ℬ X Y).isLimit.lift (BinaryFan.swap (ℬ Y X).cone)) ≫
      BinaryFan.snd (ℬ X Y).cone =
    𝟙 (tensorObj ℬ X Y) ≫ BinaryFan.snd (ℬ X Y).cone

tactic: simp
state_before: case mk.right
C : Type u
inst✝ : Category.{v, u} C
X✝ Y✝ : C
𝒯 : LimitCone (Functor.empty C)
ℬ : (X Y : C) → LimitCone (pair X Y)
X Y : C
⊢ ((ℬ Y X).isLimit.lift (BinaryFan.swap (ℬ X Y).cone) ≫ (ℬ X Y).isLimit.lift (BinaryFan.swap (ℬ Y X).cone)) ≫
      BinaryFan.snd (ℬ X Y).cone =
    𝟙 (tensorObj ℬ X Y) ≫ BinaryFan.snd (ℬ X Y).cone
state_after: no goals
Theorem: ZMod.valMinAbs_nonneg_iff
File: Mathlib/Data/ZMod/Basic.lean

tactic: rw [valMinAbs_def_pos]
state_before: n : ℕ
inst✝ : NeZero n
x : ZMod n
⊢ 0 ≤ x.valMinAbs ↔ x.val ≤ n / 2
state_after: n : ℕ
inst✝ : NeZero n
x : ZMod n
⊢ (0 ≤ if x.val ≤ n / 2 then ↑x.val else ↑x.val - ↑n) ↔ x.val ≤ n / 2

tactic: split_ifs with h
state_before: n : ℕ
inst✝ : NeZero n
x : ZMod n
⊢ (0 ≤ if x.val ≤ n / 2 then ↑x.val else ↑x.val - ↑n) ↔ x.val ≤ n / 2
state_after: case pos
n : ℕ
inst✝ : NeZero n
x : ZMod n
h : x.val ≤ n / 2
⊢ 0 ≤ ↑x.val ↔ x.val ≤ n / 2

case neg
n : ℕ
inst✝ : NeZero n
x : ZMod n
h : ¬x.val ≤ n / 2
⊢ 0 ≤ ↑x.val - ↑n ↔ x.val ≤ n / 2

tactic: exact iff_of_true (Nat.cast_nonneg _) h
state_before: case pos
n : ℕ
inst✝ : NeZero n
x : ZMod n
h : x.val ≤ n / 2
⊢ 0 ≤ ↑x.val ↔ x.val ≤ n / 2
state_after: no goals

tactic: exact iff_of_false (sub_lt_zero.2 <| Int.ofNat_lt.2 x.val_lt).not_le h
state_before: case neg
n : ℕ
inst✝ : NeZero n
x : ZMod n
h : ¬x.val ≤ n / 2
⊢ 0 ≤ ↑x.val - ↑n ↔ x.val ≤ n / 2
state_after: no goals