tasksource/leandojo huggingface dataset:
Theorem: Acc.rec_eq_recC
File: Std/WF.lean

tactic: funext α r motive intro a t
state_before: ⊢ @rec = @Acc.recC

tactic: induction t with
| intro x h ih =>
  dsimp only [recC_intro intro h]
  congr; funext y hr; exact ih _ hr
state_before: case h.h.h.h.h.h
α : Sort u_1
r : α → α → Prop
motive : (a : α) → Acc r a → Sort u_2
intro :
  (x : α) → (h : ∀ (y : α), r y x → Acc r y) → ((y : α) → (a : r y x) → motive y (_ : Acc r y)) → motive x (_ : Acc r x)
a : α
t : Acc r a
⊢ rec intro t = Acc.recC intro t

tactic: dsimp only [recC_intro intro h]
state_before: case h.h.h.h.h.h.intro
α : Sort u_1
r : α → α → Prop
motive : (a : α) → Acc r a → Sort u_2
intro :
  (x : α) → (h : ∀ (y : α), r y x → Acc r y) → ((y : α) → (a : r y x) → motive y (_ : Acc r y)) → motive x (_ : Acc r x)
a x : α
h : ∀ (y : α), r y x → Acc r y
ih : ∀ (y : α) (a : r y x), rec intro (_ : Acc ?m.2505 y) = Acc.recC intro (_ : Acc ?m.2505 y)
⊢ rec intro (_ : Acc r x) = Acc.recC intro (_ : Acc r x)

tactic: congr
state_before: case h.h.h.h.h.h.intro
α : Sort u_1
r : α → α → Prop
motive : (a : α) → Acc r a → Sort u_2
intro :
  (x : α) → (h : ∀ (y : α), r y x → Acc r y) → ((y : α) → (a : r y x) → motive y (_ : Acc r y)) → motive x (_ : Acc r x)
a x : α
h : ∀ (y : α), r y x → Acc r y
ih : ∀ (y : α) (a : r y x), rec intro (_ : Acc ?m.2505 y) = Acc.recC intro (_ : Acc ?m.2505 y)
⊢ (intro x h fun y a => rec intro (_ : Acc ?m.2505 y)) = intro x h fun y hr => Acc.recC intro (_ : Acc ?m.2505 y)

tactic: funext y hr
state_before: case h.h.h.h.h.h.intro.e_h_ih
α : Sort u_1
r : α → α → Prop
motive : (a : α) → Acc r a → Sort u_2
intro :
  (x : α) → (h : ∀ (y : α), r y x → Acc r y) → ((y : α) → (a : r y x) → motive y (_ : Acc r y)) → motive x (_ : Acc r x)
a x : α
h : ∀ (y : α), r y x → Acc r y
ih : ∀ (y : α) (a : r y x), rec intro (_ : Acc ?m.2505 y) = Acc.recC intro (_ : Acc ?m.2505 y)
⊢ (fun y a => rec intro (_ : Acc ?m.2505 y)) = fun y hr => Acc.recC intro (_ : Acc ?m.2505 y)

tactic: exact ih _ hr
state_before: case h.h.h.h.h.h.intro.e_h_ih.h.h
α : Sort u_1
r : α → α → Prop
motive : (a : α) → Acc r a → Sort u_2
intro :
  (x : α) → (h : ∀ (y : α), r y x → Acc r y) → ((y : α) → (a : r y x) → motive y (_ : Acc r y)) → motive x (_ : Acc r x)
a x : α
h : ∀ (y : α), r y x → Acc r y
ih : ∀ (y : α) (a : r y x), rec intro (_ : Acc ?m.2505 y) = Acc.recC intro (_ : Acc ?m.2505 y)
y : α
hr : r y x
⊢ rec intro (_ : Acc ?m.2505 y) = Acc.recC intro (_ : Acc ?m.2505 y)
Theorem: CategoryTheory.Groupoid.Free.congr_reverse
File: Mathlib/CategoryTheory/Groupoid/FreeGroupoid.lean

tactic: rintro ⟨XW, pp, qq, WY, _, Z, f⟩
state_before: V : Type u
inst✝ : Quiver V
X Y : Paths (Quiver.Symmetrify V)
p q : X ⟶ Y
⊢ Quotient.CompClosure redStep p q → Quotient.CompClosure redStep (Quiver.Path.reverse p) (Quiver.Path.reverse q)

tactic: have : Quotient.CompClosure redStep (WY.reverse ≫ 𝟙 _ ≫ XW.reverse)
    (WY.reverse ≫ (f.toPath ≫ (Quiver.reverse f).toPath) ≫ XW.reverse) := by
  constructor
  constructor
state_before: case intro.step
V : Type u
inst✝ : Quiver V
X✝¹ Y✝ X Y : Paths (Quiver.Symmetrify V)
X✝ Z : Quiver.Symmetrify V
f : X✝ ⟶ Z
XW : X✝¹ ⟶ Paths.of.obj X✝
WY : Paths.of.obj X✝ ⟶ Y✝
⊢ Quotient.CompClosure redStep (Quiver.Path.reverse (XW ≫ 𝟙 (Paths.of.obj X✝) ≫ WY))
    (Quiver.Path.reverse (XW ≫ (Quiver.Hom.toPath f ≫ Quiver.Hom.toPath (Quiver.reverse f)) ≫ WY))

tactic: simpa only [CategoryStruct.comp, CategoryStruct.id, Quiver.Path.reverse, Quiver.Path.nil_comp,
  Quiver.Path.reverse_comp, Quiver.reverse_reverse, Quiver.Path.reverse_toPath,
  Quiver.Path.comp_assoc] using this
state_before: case intro.step
V : Type u
inst✝ : Quiver V
X✝¹ Y✝ X Y : Paths (Quiver.Symmetrify V)
X✝ Z : Quiver.Symmetrify V
f : X✝ ⟶ Z
XW : X✝¹ ⟶ Paths.of.obj X✝
WY : Paths.of.obj X✝ ⟶ Y✝
this :
  Quotient.CompClosure redStep (Quiver.Path.reverse WY ≫ 𝟙 (Paths.of.obj X✝) ≫ Quiver.Path.reverse XW)
    (Quiver.Path.reverse WY ≫ (Quiver.Hom.toPath f ≫ Quiver.Hom.toPath (Quiver.reverse f)) ≫ Quiver.Path.reverse XW)
⊢ Quotient.CompClosure redStep (Quiver.Path.reverse (XW ≫ 𝟙 (Paths.of.obj X✝) ≫ WY))
    (Quiver.Path.reverse (XW ≫ (Quiver.Hom.toPath f ≫ Quiver.Hom.toPath (Quiver.reverse f)) ≫ WY))

tactic: constructor
state_before: V : Type u
inst✝ : Quiver V
X✝¹ Y✝ X Y : Paths (Quiver.Symmetrify V)
X✝ Z : Quiver.Symmetrify V
f : X✝ ⟶ Z
XW : X✝¹ ⟶ Paths.of.obj X✝
WY : Paths.of.obj X✝ ⟶ Y✝
⊢ Quotient.CompClosure redStep (Quiver.Path.reverse WY ≫ 𝟙 (Paths.of.obj X✝) ≫ Quiver.Path.reverse XW)
    (Quiver.Path.reverse WY ≫ (Quiver.Hom.toPath f ≫ Quiver.Hom.toPath (Quiver.reverse f)) ≫ Quiver.Path.reverse XW)

tactic: constructor
state_before: case h
V : Type u
inst✝ : Quiver V
X✝¹ Y✝ X Y : Paths (Quiver.Symmetrify V)
X✝ Z : Quiver.Symmetrify V
f : X✝ ⟶ Z
XW : X✝¹ ⟶ Paths.of.obj X✝
WY : Paths.of.obj X✝ ⟶ Y✝
⊢ redStep (𝟙 (Paths.of.obj X✝)) (Quiver.Hom.toPath f ≫ Quiver.Hom.toPath (Quiver.reverse f))
Theorem: Ordering.Compares.eq_eq
File: Mathlib/Order/Compare.lean

tactic: injection h
state_before: α : Type u_1
β : Type ?u.7392
inst✝ : Preorder α
a b : α
h✝ : Compares lt a b
h : lt = eq
⊢ a = b

tactic: injection h
state_before: α : Type u_1
β : Type ?u.7392
inst✝ : Preorder α
a b : α
h✝ : Compares gt a b
h : gt = eq
⊢ a = b
Theorem: Multiset.revzip_powersetAux_perm_aux'
File: Mathlib/Data/Multiset/Powerset.lean

tactic: haveI := Classical.decEq α
state_before: α : Type u_1
l : List α
⊢ revzip (powersetAux l) ~ revzip (powersetAux' l)

tactic: rw [revzip_powersetAux_lemma l revzip_powersetAux, revzip_powersetAux_lemma l revzip_powersetAux']
state_before: α : Type u_1
l : List α
this : DecidableEq α
⊢ revzip (powersetAux l) ~ revzip (powersetAux' l)

tactic: exact powersetAux_perm_powersetAux'.map _
state_before: α : Type u_1
l : List α
this : DecidableEq α
⊢ List.map (fun x => (x, ↑l - x)) (powersetAux l) ~ List.map (fun x => (x, ↑l - x)) (powersetAux' l)
Theorem: AddSubmonoid.mul_eq_closure_mul_set
File: Mathlib/GroupTheory/Submonoid/Pointwise.lean

tactic: rw [← closure_mul_closure, closure_eq, closure_eq]
state_before: α : Type ?u.247712
G : Type ?u.247715
M✝ : Type ?u.247718
R : Type u_1
A : Type ?u.247724
inst✝² : Monoid M✝
inst✝¹ : AddMonoid A
inst✝ : NonUnitalNonAssocSemiring R
M N : AddSubmonoid R
⊢ M * N = closure (↑M * ↑N)
Theorem: toIocMod_apply_left
File: Mathlib/Algebra/Order/ToIntervalMod.lean

tactic: rw [toIocMod_eq_iff hp, Set.right_mem_Ioc]
state_before: α : Type u_1
inst✝ : LinearOrderedAddCommGroup α
hα : Archimedean α
p : α
hp : 0 < p
a✝ b c : α
n : ℤ
a : α
⊢ toIocMod hp a a = a + p

tactic: exact ⟨lt_add_of_pos_right _ hp, -1, by simp⟩
state_before: α : Type u_1
inst✝ : LinearOrderedAddCommGroup α
hα : Archimedean α
p : α
hp : 0 < p
a✝ b c : α
n : ℤ
a : α
⊢ a < a + p ∧ ∃ z, a = a + p + z • p

tactic: simp
state_before: α : Type u_1
inst✝ : LinearOrderedAddCommGroup α
hα : Archimedean α
p : α
hp : 0 < p
a✝ b c : α
n : ℤ
a : α
⊢ a = a + p + -1 • p
Theorem: Colex.lt_singleton_iff_mem_lt
File: Mathlib/Combinatorics/Colex.lean

tactic: simp only [lt_def, mem_singleton, ← and_assoc, exists_eq_right]
state_before: α : Type u_1
inst✝ : LinearOrder α
r : α
s : Finset α
⊢ toColex s < toColex {r} ↔ ∀ (x : α), x ∈ s → x < r

tactic: constructor
state_before: α : Type u_1
inst✝ : LinearOrder α
r : α
s : Finset α
⊢ (∀ {x : α}, r < x → (x ∈ s ↔ x = r)) ∧ ¬r ∈ s ↔ ∀ (x : α), x ∈ s → x < r

tactic: intro t x hx
state_before: case mp
α : Type u_1
inst✝ : LinearOrder α
r : α
s : Finset α
⊢ (∀ {x : α}, r < x → (x ∈ s ↔ x = r)) ∧ ¬r ∈ s → ∀ (x : α), x ∈ s → x < r

tactic: rw [← not_le]
state_before: case mp
α : Type u_1
inst✝ : LinearOrder α
r : α
s : Finset α
t : (∀ {x : α}, r < x → (x ∈ s ↔ x = r)) ∧ ¬r ∈ s
x : α
hx : x ∈ s
⊢ x < r

tactic: intro h
state_before: case mp
α : Type u_1
inst✝ : LinearOrder α
r : α
s : Finset α
t : (∀ {x : α}, r < x → (x ∈ s ↔ x = r)) ∧ ¬r ∈ s
x : α
hx : x ∈ s
⊢ ¬r ≤ x

tactic: rcases lt_or_eq_of_le h with (h₁ | rfl)
state_before: case mp
α : Type u_1
inst✝ : LinearOrder α
r : α
s : Finset α
t : (∀ {x : α}, r < x → (x ∈ s ↔ x = r)) ∧ ¬r ∈ s
x : α
hx : x ∈ s
h : r ≤ x
⊢ False

tactic: exact ne_of_irrefl h₁ ((t.1 h₁).1 hx).symm
state_before: case mp.inl
α : Type u_1
inst✝ : LinearOrder α
r : α
s : Finset α
t : (∀ {x : α}, r < x → (x ∈ s ↔ x = r)) ∧ ¬r ∈ s
x : α
hx : x ∈ s
h : r ≤ x
h₁ : r < x
⊢ False

tactic: exact t.2 hx
state_before: case mp.inr
α : Type u_1
inst✝ : LinearOrder α
r : α
s : Finset α
t : (∀ {x : α}, r < x → (x ∈ s ↔ x = r)) ∧ ¬r ∈ s
hx : r ∈ s
h : r ≤ r
⊢ False

tactic: exact fun h =>
  ⟨@fun z hz => ⟨@fun i => (asymm hz (h _ i)).elim, @fun i => (hz.ne' i).elim⟩,
      by simpa using h r⟩
state_before: case mpr
α : Type u_1
inst✝ : LinearOrder α
r : α
s : Finset α
⊢ (∀ (x : α), x ∈ s → x < r) → (∀ {x : α}, r < x → (x ∈ s ↔ x = r)) ∧ ¬r ∈ s

tactic: simpa using h r
state_before: α : Type u_1
inst✝ : LinearOrder α
r : α
s : Finset α
h : ∀ (x : α), x ∈ s → x < r
⊢ ¬r ∈ s
Theorem: Substring.Valid.nextn_stop
File: Std/Data/String/Lemmas.lean

tactic: simp [h.bsize, h.nextn_stop]
state_before: x✝ : Substring
h✝ : Valid x✝
n : Nat
l m r : List Char
h : ValidFor l m r x✝
⊢ nextn x✝ n { byteIdx := Substring.bsize x✝ } = { byteIdx := Substring.bsize x✝ }
Theorem: Rel.edgeDensity_empty_right
File: Mathlib/Combinatorics/SimpleGraph/Density.lean

tactic: rw [edgeDensity, Finset.card_empty, Nat.cast_zero, mul_zero, div_zero]
state_before: 𝕜 : Type ?u.21155
ι : Type ?u.21158
κ : Type ?u.21161
α : Type u_1
β : Type u_2
inst✝¹ : LinearOrderedField 𝕜
r : α → β → Prop
inst✝ : (a : α) → DecidablePred (r a)
s✝ s₁ s₂ : Finset α
t t₁ t₂ : Finset β
a : α
b : β
δ : 𝕜
s : Finset α
⊢ edgeDensity r s ∅ = 0
Theorem: Filter.tendsto_mul_const_atBot_of_neg
File: Mathlib/Order/Filter/AtTopBot.lean

tactic: simpa only [mul_comm] using tendsto_const_mul_atBot_of_neg hr
state_before: ι : Type ?u.232588
ι' : Type ?u.232591
α : Type u_1
β : Type u_2
γ : Type ?u.232600
inst✝ : LinearOrderedField α
l : Filter β
f : β → α
r : α
hr : r < 0
⊢ Tendsto (fun x => f x * r) l atBot ↔ Tendsto f l atTop
Theorem: Mathlib.Tactic.Ring.toProd_pf
File: Mathlib/Tactic/Ring/Basic.lean

tactic: simp [*]
state_before: u : Lean.Level
R : Type u_1
α : Q(Type u)
sα : Q(CommSemiring «$α»)
inst✝ : CommSemiring R
a a' : R
p : a = a'
⊢ a = a' ^ Nat.rawCast 1 * Nat.rawCast 1
Theorem: MeasureTheory.Measure.toSignedMeasure_zero
File: Mathlib/MeasureTheory/Measure/VectorMeasure.lean

tactic: ext i
state_before: α : Type u_1
β : Type ?u.135956
m : MeasurableSpace α
⊢ toSignedMeasure 0 = 0

tactic: simp
state_before: case h
α : Type u_1
β : Type ?u.135956
m : MeasurableSpace α
i : Set α
⊢ MeasurableSet i → ↑(toSignedMeasure 0) i = ↑0 i
Theorem: Module.End.ker_pow_constant
File: Mathlib/LinearAlgebra/FiniteDimensional.lean

tactic: simp
state_before: K : Type u
V : Type v
inst✝² : DivisionRing K
inst✝¹ : AddCommGroup V
inst✝ : Module K V
f : End K V
k : ℕ
h : LinearMap.ker (f ^ k) = LinearMap.ker (f ^ Nat.succ k)
⊢ LinearMap.ker (f ^ k) = LinearMap.ker (f ^ (k + 0))

tactic: apply le_antisymm
state_before: K : Type u
V : Type v
inst✝² : DivisionRing K
inst✝¹ : AddCommGroup V
inst✝ : Module K V
f : End K V
k : ℕ
h : LinearMap.ker (f ^ k) = LinearMap.ker (f ^ Nat.succ k)
m : ℕ
⊢ LinearMap.ker (f ^ k) = LinearMap.ker (f ^ (k + (m + 1)))

tactic: rw [add_comm, pow_add]
state_before: case a
K : Type u
V : Type v
inst✝² : DivisionRing K
inst✝¹ : AddCommGroup V
inst✝ : Module K V
f : End K V
k : ℕ
h : LinearMap.ker (f ^ k) = LinearMap.ker (f ^ Nat.succ k)
m : ℕ
⊢ LinearMap.ker (f ^ k) ≤ LinearMap.ker (f ^ (k + (m + 1)))

tactic: apply LinearMap.ker_le_ker_comp
state_before: case a
K : Type u
V : Type v
inst✝² : DivisionRing K
inst✝¹ : AddCommGroup V
inst✝ : Module K V
f : End K V
k : ℕ
h : LinearMap.ker (f ^ k) = LinearMap.ker (f ^ Nat.succ k)
m : ℕ
⊢ LinearMap.ker (f ^ k) ≤ LinearMap.ker (f ^ (m + 1) * f ^ k)

tactic: rw [ker_pow_constant h m, add_comm m 1, ← add_assoc, pow_add, pow_add f k m,
  LinearMap.mul_eq_comp, LinearMap.mul_eq_comp, LinearMap.ker_comp, LinearMap.ker_comp, h,
  Nat.add_one]
state_before: case a
K : Type u
V : Type v
inst✝² : DivisionRing K
inst✝¹ : AddCommGroup V
inst✝ : Module K V
f : End K V
k : ℕ
h : LinearMap.ker (f ^ k) = LinearMap.ker (f ^ Nat.succ k)
m : ℕ
⊢ LinearMap.ker (f ^ (k + (m + 1))) ≤ LinearMap.ker (f ^ k)
Theorem: TrivSqZeroExt.inr_mul_inr
File: Mathlib/Algebra/TrivSqZeroExt.lean

tactic: rw [zero_smul, zero_add, zero_smul]
state_before: R : Type u
M : Type v
inst✝³ : Semiring R
inst✝² : AddCommMonoid M
inst✝¹ : Module R M
inst✝ : Module Rᵐᵒᵖ M
m₁ m₂ : M
⊢ 0 • m₂ + 0 • m₁ = 0
Theorem: Complex.inv_one_add_tan_sq
File: Mathlib/Data/Complex/Exponential.lean

tactic: have : cos x ^ 2 ≠ 0 := pow_ne_zero 2 hx
state_before: x✝ y x : ℂ
hx : cos x ≠ 0
⊢ (1 + tan x ^ 2)⁻¹ = cos x ^ 2

tactic: rw [tan_eq_sin_div_cos, div_pow]
state_before: x✝ y x : ℂ
hx : cos x ≠ 0
this : cos x ^ 2 ≠ 0
⊢ (1 + tan x ^ 2)⁻¹ = cos x ^ 2

tactic: field_simp [this]
state_before: x✝ y x : ℂ
hx : cos x ≠ 0
this : cos x ^ 2 ≠ 0
⊢ (1 + sin x ^ 2 / cos x ^ 2)⁻¹ = cos x ^ 2
Theorem: CategoryTheory.Limits.spanExt_app_right
File: Mathlib/CategoryTheory/Limits/Shapes/Pullbacks.lean

tactic: dsimp [spanExt]
state_before: C : Type u
inst✝¹ : Category C
D : Type u₂
inst✝ : Category D
X Y Z X' Y' Z' : C
iX : X ≅ X'
iY : Y ≅ Y'
iZ : Z ≅ Z'
f : X ⟶ Y
g : X ⟶ Z
f' : X' ⟶ Y'
g' : X' ⟶ Z'
wf : iX.hom ≫ f' = f ≫ iY.hom
wg : iX.hom ≫ g' = g ≫ iZ.hom
⊢ (spanExt iX iY iZ wf wg).app WalkingSpan.right = iZ
Theorem: Convex.openSegment_closure_interior_subset_interior
File: Mathlib/Analysis/Convex/Topology.lean

tactic: rintro _ ⟨a, b, ha, hb, hab, rfl⟩
state_before: ι : Type ?u.106301
𝕜 : Type u_2
E : Type u_1
inst✝⁵ : LinearOrderedField 𝕜
inst✝⁴ : AddCommGroup E
inst✝³ : Module 𝕜 E
inst✝² : TopologicalSpace E
inst✝¹ : TopologicalAddGroup E
inst✝ : ContinuousConstSMul 𝕜 E
s : Set E
hs : Convex 𝕜 s
x y : E
hx : x ∈ closure s
hy : y ∈ interior s
⊢ openSegment 𝕜 x y ⊆ interior s

tactic: exact hs.combo_closure_interior_mem_interior hx hy ha.le hb hab
state_before: case intro.intro.intro.intro.intro
ι : Type ?u.106301
𝕜 : Type u_2
E : Type u_1
inst✝⁵ : LinearOrderedField 𝕜
inst✝⁴ : AddCommGroup E
inst✝³ : Module 𝕜 E
inst✝² : TopologicalSpace E
inst✝¹ : TopologicalAddGroup E
inst✝ : ContinuousConstSMul 𝕜 E
s : Set E
hs : Convex 𝕜 s
x y : E
hx : x ∈ closure s
hy : y ∈ interior s
a b : 𝕜
ha : 0 < a
hb : 0 < b
hab : a + b = 1
⊢ a • x + b • y ∈ interior s
Theorem: SimpleGraph.degree_compl
File: Mathlib/Combinatorics/SimpleGraph/Basic.lean

tactic: classical
  rw [← card_neighborSet_union_compl_neighborSet G v, Set.toFinset_union]
  simp [card_disjoint_union (Set.disjoint_toFinset.mpr (compl_neighborSet_disjoint G v))]
state_before: ι : Sort ?u.269926
𝕜 : Type ?u.269929
V : Type u
W : Type v
X : Type w
G : SimpleGraph V
G' : SimpleGraph W
a b c u v w : V
e : Sym2 V
inst✝² : Fintype ↑(neighborSet G v)
inst✝¹ : Fintype ↑(neighborSet (Gᶜ) v)
inst✝ : Fintype V
⊢ degree (Gᶜ) v = Fintype.card V - 1 - degree G v

tactic: rw [← card_neighborSet_union_compl_neighborSet G v, Set.toFinset_union]
state_before: ι : Sort ?u.269926
𝕜 : Type ?u.269929
V : Type u
W : Type v
X : Type w
G : SimpleGraph V
G' : SimpleGraph W
a b c u v w : V
e : Sym2 V
inst✝² : Fintype ↑(neighborSet G v)
inst✝¹ : Fintype ↑(neighborSet (Gᶜ) v)
inst✝ : Fintype V
⊢ degree (Gᶜ) v = Fintype.card V - 1 - degree G v

tactic: simp [card_disjoint_union (Set.disjoint_toFinset.mpr (compl_neighborSet_disjoint G v))]
state_before: ι : Sort ?u.269926
𝕜 : Type ?u.269929
V : Type u
W : Type v
X : Type w
G : SimpleGraph V
G' : SimpleGraph W
a b c u v w : V
e : Sym2 V
inst✝² : Fintype ↑(neighborSet G v)
inst✝¹ : Fintype ↑(neighborSet (Gᶜ) v)
inst✝ : Fintype V
⊢ degree (Gᶜ) v = card (Set.toFinset (neighborSet G v) ∪ Set.toFinset (neighborSet (Gᶜ) v)) - degree G v
Theorem: TypeVec.toSubtype'_of_subtype'
File: Mathlib/Data/TypeVec.lean

tactic: ext (i x)
state_before: n : ℕ
α : TypeVec n
r : α ⊗ α ⟹ repeat n Prop
⊢ toSubtype' r ⊚ ofSubtype' r = id

tactic: induction i
<;> dsimp only [id, toSubtype', comp, ofSubtype'] at *
<;> simp [Subtype.eta, *]
state_before: case a.h
n : ℕ
α : TypeVec n
r : α ⊗ α ⟹ repeat n Prop
i : Fin2 n
x : Subtype_ r i
⊢ (toSubtype' r ⊚ ofSubtype' r) i x = id i x
Theorem: Ideal.mul_eq_bot
File: Mathlib/RingTheory/Ideal/Operations.lean

tactic: cases' h with h h <;> rw [← Ideal.mul_bot, h, Ideal.mul_comm]
state_before: R✝ : Type u
ι : Type ?u.297281
inst✝² : CommSemiring R✝
I✝ J✝ K L : Ideal R✝
R : Type u_1
inst✝¹ : CommSemiring R
inst✝ : NoZeroDivisors R
I J : Ideal R
h : I = ⊥ ∨ J = ⊥
⊢ I * J = ⊥
Theorem: LinearPMap.mem_graph_iff'
File: Mathlib/LinearAlgebra/LinearPMap.lean

tactic: simp [graph]
state_before: R : Type u_1
inst✝⁶ : Ring R
E : Type u_2
inst✝⁵ : AddCommGroup E
inst✝⁴ : Module R E
F : Type u_3
inst✝³ : AddCommGroup F
inst✝² : Module R F
G : Type ?u.457298
inst✝¹ : AddCommGroup G
inst✝ : Module R G
f : E →ₗ.[R] F
x : E × F
⊢ x ∈ graph f ↔ ∃ y, (↑y, ↑f y) = x
Theorem: Filter.mem_of_pi_mem_pi
File: Mathlib/Order/Filter/Pi.lean

tactic: rcases mem_pi.1 h with ⟨I', -, t, htf, hts⟩
state_before: ι : Type u_2
α : ι → Type u_1
f f₁ f₂ : (i : ι) → Filter (α i)
s : (i : ι) → Set (α i)
inst✝ : ∀ (i : ι), NeBot (f i)
I : Set ι
h : Set.pi I s ∈ pi f
i : ι
hi : i ∈ I
⊢ s i ∈ f i

tactic: refine' mem_of_superset (htf i) fun x hx => _
state_before: case intro.intro.intro.intro
ι : Type u_2
α : ι → Type u_1
f f₁ f₂ : (i : ι) → Filter (α i)
s : (i : ι) → Set (α i)
inst✝ : ∀ (i : ι), NeBot (f i)
I : Set ι
h : Set.pi I s ∈ pi f
i : ι
hi : i ∈ I
I' : Set ι
t : (i : ι) → Set (α i)
htf : ∀ (i : ι), t i ∈ f i
hts : Set.pi I' t ⊆ Set.pi I s
⊢ s i ∈ f i

tactic: have : ∀ i, (t i).Nonempty := fun i => nonempty_of_mem (htf i)
state_before: case intro.intro.intro.intro
ι : Type u_2
α : ι → Type u_1
f f₁ f₂ : (i : ι) → Filter (α i)
s : (i : ι) → Set (α i)
inst✝ : ∀ (i : ι), NeBot (f i)
I : Set ι
h : Set.pi I s ∈ pi f
i : ι
hi : i ∈ I
I' : Set ι
t : (i : ι) → Set (α i)
htf : ∀ (i : ι), t i ∈ f i
hts : Set.pi I' t ⊆ Set.pi I s
x : α i
hx : x ∈ t i
⊢ x ∈ s i

tactic: choose g hg using this
state_before: case intro.intro.intro.intro
ι : Type u_2
α : ι → Type u_1
f f₁ f₂ : (i : ι) → Filter (α i)
s : (i : ι) → Set (α i)
inst✝ : ∀ (i : ι), NeBot (f i)
I : Set ι
h : Set.pi I s ∈ pi f
i : ι
hi : i ∈ I
I' : Set ι
t : (i : ι) → Set (α i)
htf : ∀ (i : ι), t i ∈ f i
hts : Set.pi I' t ⊆ Set.pi I s
x : α i
hx : x ∈ t i
this : ∀ (i : ι), Set.Nonempty (t i)
⊢ x ∈ s i

tactic: have : update g i x ∈ I'.pi t := fun j _ => by
  rcases eq_or_ne j i with (rfl | hne) <;> simp [*]
state_before: case intro.intro.intro.intro
ι : Type u_2
α : ι → Type u_1
f f₁ f₂ : (i : ι) → Filter (α i)
s : (i : ι) → Set (α i)
inst✝ : ∀ (i : ι), NeBot (f i)
I : Set ι
h : Set.pi I s ∈ pi f
i : ι
hi : i ∈ I
I' : Set ι
t : (i : ι) → Set (α i)
htf : ∀ (i : ι), t i ∈ f i
hts : Set.pi I' t ⊆ Set.pi I s
x : α i
hx : x ∈ t i
g : (i : ι) → α i
hg : ∀ (i : ι), g i ∈ t i
⊢ x ∈ s i

tactic: simpa using hts this i hi
state_before: case intro.intro.intro.intro
ι : Type u_2
α : ι → Type u_1
f f₁ f₂ : (i : ι) → Filter (α i)
s : (i : ι) → Set (α i)
inst✝ : ∀ (i : ι), NeBot (f i)
I : Set ι
h : Set.pi I s ∈ pi f
i : ι
hi : i ∈ I
I' : Set ι
t : (i : ι) → Set (α i)
htf : ∀ (i : ι), t i ∈ f i
hts : Set.pi I' t ⊆ Set.pi I s
x : α i
hx : x ∈ t i
g : (i : ι) → α i
hg : ∀ (i : ι), g i ∈ t i
this : update g i x ∈ Set.pi I' t
⊢ x ∈ s i

tactic: rcases eq_or_ne j i with (rfl | hne) <;> simp [*]
state_before: ι : Type u_2
α : ι → Type u_1
f f₁ f₂ : (i : ι) → Filter (α i)
s : (i : ι) → Set (α i)
inst✝ : ∀ (i : ι), NeBot (f i)
I : Set ι
h : Set.pi I s ∈ pi f
i : ι
hi : i ∈ I
I' : Set ι
t : (i : ι) → Set (α i)
htf : ∀ (i : ι), t i ∈ f i
hts : Set.pi I' t ⊆ Set.pi I s
x : α i
hx : x ∈ t i
g : (i : ι) → α i
hg : ∀ (i : ι), g i ∈ t i
j : ι
x✝ : j ∈ I'
⊢ update g i x j ∈ t j
Theorem: List.Func.length_pointwise
File: Mathlib/Data/List/Func.lean

tactic: simp only [pointwise, length, length_map, max_eq_right (Nat.zero_le (length bs + 1))]
state_before: α : Type u
β : Type v
γ : Type w
inst✝¹ : Inhabited α
inst✝ : Inhabited β
f : α → β → γ
head✝ : β
bs : List β
⊢ length (pointwise f [] (head✝ :: bs)) = max (length []) (length (head✝ :: bs))

tactic: simp only [pointwise, length, length_map, max_eq_left (Nat.zero_le (length as + 1))]
state_before: α : Type u
β : Type v
γ : Type w
inst✝¹ : Inhabited α
inst✝ : Inhabited β
f : α → β → γ
head✝ : α
as : List α
⊢ length (pointwise f (head✝ :: as) []) = max (length (head✝ :: as)) (length [])

tactic: simp only [pointwise, length, Nat.max_succ_succ, @length_pointwise _ as bs]
state_before: α : Type u
β : Type v
γ : Type w
inst✝¹ : Inhabited α
inst✝ : Inhabited β
f : α → β → γ
head✝¹ : α
as : List α
head✝ : β
bs : List β
⊢ length (pointwise f (head✝¹ :: as) (head✝ :: bs)) = max (length (head✝¹ :: as)) (length (head✝ :: bs))
Theorem: List.mem_replicate
File: Std/Data/List/Lemmas.lean

tactic: simp
state_before: α : Type u_1
a b : α
⊢ b ∈ replicate 0 a ↔ 0 ≠ 0 ∧ b = a

tactic: simp [mem_replicate, Nat.succ_ne_zero]
state_before: α : Type u_1
a b : α
n : Nat
⊢ b ∈ replicate (n + 1) a ↔ n + 1 ≠ 0 ∧ b = a
Theorem: Num.cast_add
File: Mathlib/Data/Num/Lemmas.lean

tactic: rw [← cast_to_nat, add_to_nat, Nat.cast_add, cast_to_nat, cast_to_nat]
state_before: α : Type u_1
inst✝ : Semiring α
m n : Num
⊢ ↑(m + n) = ↑m + ↑n
Theorem: Dense.interior_compl
File: Mathlib/Topology/Basic.lean

tactic: rwa [compl_compl]
state_before: α : Type u
β : Type v
ι : Sort w
a : α
s✝ s₁ s₂ t : Set α
p p₁ p₂ : α → Prop
inst✝ : TopologicalSpace α
s : Set α
h : Dense s
⊢ Dense (sᶜᶜ)
Theorem: Pmf.toOuterMeasure_map_apply
File: Mathlib/Probability/ProbabilityMassFunction/Constructions.lean

tactic: simp [map, Set.indicator, toOuterMeasure_apply p (f ⁻¹' s)]
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.41419
f : α → β
p : Pmf α
b : β
s : Set β
⊢ ↑(toOuterMeasure (map f p)) s = ↑(toOuterMeasure p) (f ⁻¹' s)
Theorem: List.length_pos_of_mem_splitWrtComposition
File: Mathlib/Combinatorics/Composition.lean

tactic: have : l'.length ∈ (l.splitWrtComposition c).map List.length :=
  List.mem_map_of_mem List.length h
state_before: n : ℕ
α : Type u_1
l l' : List α
c : Composition (length l)
h : l' ∈ splitWrtComposition l c
⊢ 0 < length l'

tactic: rw [map_length_splitWrtComposition] at this
state_before: n : ℕ
α : Type u_1
l l' : List α
c : Composition (length l)
h : l' ∈ splitWrtComposition l c
this : length l' ∈ map length (splitWrtComposition l c)
⊢ 0 < length l'

tactic: exact c.blocks_pos this
state_before: n : ℕ
α : Type u_1
l l' : List α
c : Composition (length l)
h : l' ∈ splitWrtComposition l c
this : length l' ∈ c.blocks
⊢ 0 < length l'
Theorem: Real.tan_zero
File: Mathlib/Data/Complex/Exponential.lean

tactic: simp [tan]
state_before: x y : ℝ
⊢ tan 0 = 0
Theorem: round_intCast
File: Mathlib/Algebra/Order/Floor.lean

tactic: simp [round]
state_before: F : Type ?u.253236
α : Type u_1
β : Type ?u.253242
inst✝¹ : LinearOrderedRing α
inst✝ : FloorRing α
n : ℤ
⊢ round ↑n = n
Theorem: Summable.trans_sub
File: Mathlib/Topology/Algebra/InfiniteSum/Basic.lean

tactic: simpa only [sub_add_cancel] using hfg.add hg
state_before: α : Type u_1
β : Type u_2
γ : Type ?u.405214
δ : Type ?u.405217
inst✝² : AddCommGroup α
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalAddGroup α
f g : β → α
a a₁ a₂ : α
hg : Summable g
hfg : Summable fun b => f b - g b
⊢ Summable f
Theorem: Relation.cutExpand_add_left
File: Mathlib/Logic/Hydra.lean

tactic: rw [add_assoc, add_assoc, add_left_cancel_iff]
state_before: α : Type u_1
r : α → α → Prop
t u s x✝¹ : Multiset α
x✝ : α
⊢ s + t + {x✝} = s + u + x✝¹ ↔ t + {x✝} = u + x✝¹
Theorem: List.formPerm_apply_mem_ne_self_iff
File: Mathlib/GroupTheory/Perm/List.lean

tactic: rw [Ne.def, formPerm_apply_mem_eq_self_iff _ hl x hx, not_le]
state_before: α : Type u_1
β : Type ?u.815557
inst✝ : DecidableEq α
l : List α
x✝ : α
hl : Nodup l
x : α
hx : x ∈ l
⊢ ↑(formPerm l) x ≠ x ↔ 2 ≤ length l

tactic: exact ⟨Nat.succ_le_of_lt, Nat.lt_of_succ_le⟩
state_before: α : Type u_1
β : Type ?u.815557
inst✝ : DecidableEq α
l : List α
x✝ : α
hl : Nodup l
x : α
hx : x ∈ l
⊢ 1 < length l ↔ 2 ≤ length l