1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: CategoryTheory.Adjunction.he''
File: Mathlib/CategoryTheory/Adjunction/Basic.lean

tactic: rw [Equiv.eq_symm_apply, he]
state_before: C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
D : Type u₂
inst✝ : Category.{v₂, u₂} D
F : C ⥤ D
G : D ⥤ C
G_obj : D → C
e : (X : C) → (Y : D) → (F.obj X ⟶ Y) ≃ (X ⟶ G_obj Y)
he : ∀ (X' X : C) (Y : D) (f : X' ⟶ X) (g : F.obj X ⟶ Y), (e X' Y) (F.map f ≫ g) = f ≫ (e X Y) g
X' X : C
Y : D
f : X' ⟶ X
g : X ⟶ G_obj Y
⊢ F.map f ≫ (e X Y).symm g = (e X' Y).symm (f ≫ g)
state_after: C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
D : Type u₂
inst✝ : Category.{v₂, u₂} D
F : C ⥤ D
G : D ⥤ C
G_obj : D → C
e : (X : C) → (Y : D) → (F.obj X ⟶ Y) ≃ (X ⟶ G_obj Y)
he : ∀ (X' X : C) (Y : D) (f : X' ⟶ X) (g : F.obj X ⟶ Y), (e X' Y) (F.map f ≫ g) = f ≫ (e X Y) g
X' X : C
Y : D
f : X' ⟶ X
g : X ⟶ G_obj Y
⊢ f ≫ (e X Y) ((e X Y).symm g) = f ≫ g

tactic: simp
state_before: C : Type u₁
inst✝¹ : Category.{v₁, u₁} C
D : Type u₂
inst✝ : Category.{v₂, u₂} D
F : C ⥤ D
G : D ⥤ C
G_obj : D → C
e : (X : C) → (Y : D) → (F.obj X ⟶ Y) ≃ (X ⟶ G_obj Y)
he : ∀ (X' X : C) (Y : D) (f : X' ⟶ X) (g : F.obj X ⟶ Y), (e X' Y) (F.map f ≫ g) = f ≫ (e X Y) g
X' X : C
Y : D
f : X' ⟶ X
g : X ⟶ G_obj Y
⊢ f ≫ (e X Y) ((e X Y).symm g) = f ≫ g
state_after: no goals
Theorem: Primrec.option_get
File: Mathlib/Computability/Primrec.lean

tactic: intro hf
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
σ : Type u_4
inst✝³ : Primcodable α
inst✝² : Primcodable β
inst✝¹ : Primcodable γ
inst✝ : Primcodable σ
f : α → Option β
h : ∀ (a : α), (f a).isSome = true
⊢ Primrec f → Primrec fun a => (f a).get ⋯
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
σ : Type u_4
inst✝³ : Primcodable α
inst✝² : Primcodable β
inst✝¹ : Primcodable γ
inst✝ : Primcodable σ
f : α → Option β
h : ∀ (a : α), (f a).isSome = true
hf : Primrec f
⊢ Primrec fun a => (f a).get ⋯

tactic: refine (Nat.Primrec.pred.comp hf).of_eq fun n => ?_
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
σ : Type u_4
inst✝³ : Primcodable α
inst✝² : Primcodable β
inst✝¹ : Primcodable γ
inst✝ : Primcodable σ
f : α → Option β
h : ∀ (a : α), (f a).isSome = true
hf : Primrec f
⊢ Primrec fun a => (f a).get ⋯
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
σ : Type u_4
inst✝³ : Primcodable α
inst✝² : Primcodable β
inst✝¹ : Primcodable γ
inst✝ : Primcodable σ
f : α → Option β
h : ∀ (a : α), (f a).isSome = true
hf : Primrec f
n : ℕ
⊢ (encode (Option.map f (decode n))).pred = encode (Option.map (fun a => (f a).get ⋯) (decode n))

tactic: generalize hx : @decode α _ n = x
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
σ : Type u_4
inst✝³ : Primcodable α
inst✝² : Primcodable β
inst✝¹ : Primcodable γ
inst✝ : Primcodable σ
f : α → Option β
h : ∀ (a : α), (f a).isSome = true
hf : Primrec f
n : ℕ
⊢ (encode (Option.map f (decode n))).pred = encode (Option.map (fun a => (f a).get ⋯) (decode n))
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
σ : Type u_4
inst✝³ : Primcodable α
inst✝² : Primcodable β
inst✝¹ : Primcodable γ
inst✝ : Primcodable σ
f : α → Option β
h : ∀ (a : α), (f a).isSome = true
hf : Primrec f
n : ℕ
x : Option α
hx : decode n = x
⊢ (encode (Option.map f x)).pred = encode (Option.map (fun a => (f a).get ⋯) x)

tactic: cases x <;> simp
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
σ : Type u_4
inst✝³ : Primcodable α
inst✝² : Primcodable β
inst✝¹ : Primcodable γ
inst✝ : Primcodable σ
f : α → Option β
h : ∀ (a : α), (f a).isSome = true
hf : Primrec f
n : ℕ
x : Option α
hx : decode n = x
⊢ (encode (Option.map f x)).pred = encode (Option.map (fun a => (f a).get ⋯) x)
state_after: no goals
Theorem: Finset.mem_nonMemberSubfamily
File: Mathlib/Combinatorics/SetFamily/Compression/Down.lean

tactic: simp [nonMemberSubfamily]
state_before: α : Type u_1
inst✝ : DecidableEq α
𝒜 ℬ : Finset (Finset α)
s : Finset α
a : α
⊢ s ∈ nonMemberSubfamily a 𝒜 ↔ s ∈ 𝒜 ∧ a ∉ s
state_after: no goals
Theorem: isUpperSet_iff_Ici_subset
File: Mathlib/Order/UpperLower/Basic.lean

tactic: simp [IsUpperSet, subset_def, @forall_swap (_ ∈ s)]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
κ : ι → Sort u_5
inst✝¹ : Preorder α
inst✝ : Preorder β
s : Set α
p : α → Prop
a : α
⊢ IsUpperSet s ↔ ∀ ⦃a : α⦄, a ∈ s → Ici a ⊆ s
state_after: no goals
Theorem: Mathlib.Tactic.Group.zpow_trick
File: Mathlib/Tactic/Group.lean

tactic: rw [mul_assoc, ← zpow_add]
state_before: G : Type u_1
inst✝ : Group G
a b : G
n m : ℤ
⊢ a * b ^ n * b ^ m = a * b ^ (n + m)
state_after: no goals
Theorem: t0Space_iff_uniformity
File: Mathlib/Topology/UniformSpace/Separation.lean

tactic: simp only [t0Space_iff_inseparable, inseparable_iff_ker_uniformity, mem_ker, id]
state_before: α : Type u
β : Type v
γ : Type w
inst✝² : UniformSpace α
inst✝¹ : UniformSpace β
inst✝ : UniformSpace γ
⊢ T0Space α ↔ ∀ (x y : α), (∀ r ∈ 𝓤 α, (x, y) ∈ r) → x = y
state_after: no goals
Theorem: equicontinuousAt_iInf_rng
File: Mathlib/Topology/UniformSpace/Equicontinuity.lean

tactic: simp only [← equicontinuousWithinAt_univ (uα := _), equicontinuousWithinAt_iInf_rng]
state_before: ι : Type u_1
κ : Type u_2
X : Type u_3
X' : Type u_4
Y : Type u_5
Z : Type u_6
α : Type u_7
α' : Type u_8
β : Type u_9
β' : Type u_10
γ : Type u_11
𝓕 : Type u_12
tX : TopologicalSpace X
tY : TopologicalSpace Y
tZ : TopologicalSpace Z
uα : UniformSpace α
uβ : UniformSpace β
uγ : UniformSpace γ
u : κ → UniformSpace α'
F : ι → X → α'
x₀ : X
⊢ EquicontinuousAt F x₀ ↔ ∀ (k : κ), EquicontinuousAt F x₀
state_after: no goals
Theorem: Zsqrtd.norm_one
File: Mathlib/NumberTheory/Zsqrtd/Basic.lean

tactic: simp [norm]
state_before: d : ℤ
⊢ norm 1 = 1
state_after: no goals
Theorem: CategoryTheory.MonoidalCategory.associator_inv_naturality_middle
File: Mathlib/CategoryTheory/Monoidal/Category.lean

tactic: simp
state_before: C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z✝ X Y Y' : C
f : Y ⟶ Y'
Z : C
⊢ X ◁ f ▷ Z ≫ (α_ X Y' Z).inv = (α_ X Y Z).inv ≫ (X ◁ f) ▷ Z
state_after: no goals
Theorem: Stream'.Seq.not_mem_nil
File: Mathlib/Data/Seq/Seq.lean

tactic: injection h
state_before: α : Type u
β : Type v
γ : Type w
a : α
x✝ : a ∈ nil
w✝ : ℕ
h : some a = none
⊢ False
state_after: no goals
Theorem: Int.dvd_mul_of_div_dvd
File: Mathlib/Data/Int/Defs.lean

tactic: obtain ⟨e, rfl⟩ := hdiv
state_before: a b c d m n : ℤ
h : b ∣ a
hdiv : a / b ∣ c
⊢ a ∣ b * c
state_after: case intro
a b d m n : ℤ
h : b ∣ a
e : ℤ
⊢ a ∣ b * (a / b * e)

tactic: rw [← Int.mul_assoc, Int.mul_comm _ (a / b), Int.ediv_mul_cancel h]
state_before: case intro
a b d m n : ℤ
h : b ∣ a
e : ℤ
⊢ a ∣ b * (a / b * e)
state_after: case intro
a b d m n : ℤ
h : b ∣ a
e : ℤ
⊢ a ∣ a * e

tactic: exact Int.dvd_mul_right a e
state_before: case intro
a b d m n : ℤ
h : b ∣ a
e : ℤ
⊢ a ∣ a * e
state_after: no goals
Theorem: ProbabilityTheory.measurable_poissonPMFReal
File: Mathlib/Probability/Distributions/Poisson.lean

tactic: measurability
state_before: r : ℝ≥0
⊢ Measurable (poissonPMFReal r)
state_after: no goals
Theorem: RingQuot.mkAlgHom_coe
File: Mathlib/Algebra/RingQuot.lean

tactic: simp_rw [mkAlgHom_def, mkRingHom_def]
state_before: R : Type uR
inst✝⁴ : Semiring R
S : Type uS
inst✝³ : CommSemiring S
T : Type uT
A : Type uA
inst✝² : Semiring A
inst✝¹ : Algebra S A
r : R → R → Prop
inst✝ : Semiring T
s : A → A → Prop
⊢ ↑(mkAlgHom S s) = mkRingHom s
state_after: R : Type uR
inst✝⁴ : Semiring R
S : Type uS
inst✝³ : CommSemiring S
T : Type uT
A : Type uA
inst✝² : Semiring A
inst✝¹ : Algebra S A
r : R → R → Prop
inst✝ : Semiring T
s : A → A → Prop
⊢ ↑{ toFun := fun x => { toQuot := Quot.mk (Rel s) x }, map_one' := ⋯, map_mul' := ⋯, map_zero' := ⋯, map_add' := ⋯,
        commutes' := ⋯ } =
    { toFun := fun x => { toQuot := Quot.mk (Rel s) x }, map_one' := ⋯, map_mul' := ⋯, map_zero' := ⋯, map_add' := ⋯ }

tactic: rfl
state_before: R : Type uR
inst✝⁴ : Semiring R
S : Type uS
inst✝³ : CommSemiring S
T : Type uT
A : Type uA
inst✝² : Semiring A
inst✝¹ : Algebra S A
r : R → R → Prop
inst✝ : Semiring T
s : A → A → Prop
⊢ ↑{ toFun := fun x => { toQuot := Quot.mk (Rel s) x }, map_one' := ⋯, map_mul' := ⋯, map_zero' := ⋯, map_add' := ⋯,
        commutes' := ⋯ } =
    { toFun := fun x => { toQuot := Quot.mk (Rel s) x }, map_one' := ⋯, map_mul' := ⋯, map_zero' := ⋯, map_add' := ⋯ }
state_after: no goals
Theorem: LinearMap.BilinForm.smul_right_of_tower
File: Mathlib/LinearAlgebra/BilinearForm/Basic.lean

tactic: rw [← IsScalarTower.algebraMap_smul R r, smul_right, Algebra.smul_def]
state_before: R : Type u_1
M : Type u_2
inst✝¹² : CommSemiring R
inst✝¹¹ : AddCommMonoid M
inst✝¹⁰ : Module R M
S : Type u_3
inst✝⁹ : CommSemiring S
inst✝⁸ : Algebra S R
inst✝⁷ : Module S M
inst✝⁶ : IsScalarTower S R M
R₁ : Type u_4
M₁ : Type u_5
inst✝⁵ : CommRing R₁
inst✝⁴ : AddCommGroup M₁
inst✝³ : Module R₁ M₁
V : Type u_6
K : Type u_7
inst✝² : Field K
inst✝¹ : AddCommGroup V
inst✝ : Module K V
B : BilinForm R M
B₁ : BilinForm R₁ M₁
r : S
x y : M
⊢ (B x) (r • y) = r • (B x) y
state_after: no goals
Theorem: FDerivMeasurableAux.le_of_mem_A
File: Mathlib/Analysis/Calculus/FDeriv/Measurable.lean

tactic: rcases hx with ⟨r', r'mem, hr'⟩
state_before: 𝕜 : Type u_1
inst✝⁴ : NontriviallyNormedField 𝕜
E : Type u_2
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace 𝕜 E
F : Type u_3
inst✝¹ : NormedAddCommGroup F
inst✝ : NormedSpace 𝕜 F
f : E → F
K : Set (E →L[𝕜] F)
r ε : ℝ
L : E →L[𝕜] F
x : E
hx : x ∈ A f L r ε
y z : E
hy : y ∈ closedBall x (r / 2)
hz : z ∈ closedBall x (r / 2)
⊢ ‖f z - f y - L (z - y)‖ ≤ ε * r
state_after: case intro.intro
𝕜 : Type u_1
inst✝⁴ : NontriviallyNormedField 𝕜
E : Type u_2
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace 𝕜 E
F : Type u_3
inst✝¹ : NormedAddCommGroup F
inst✝ : NormedSpace 𝕜 F
f : E → F
K : Set (E →L[𝕜] F)
r ε : ℝ
L : E →L[𝕜] F
x y z : E
hy : y ∈ closedBall x (r / 2)
hz : z ∈ closedBall x (r / 2)
r' : ℝ
r'mem : r' ∈ Ioc (r / 2) r
hr' : ∀ y ∈ ball x r', ∀ z ∈ ball x r', ‖f z - f y - L (z - y)‖ < ε * r
⊢ ‖f z - f y - L (z - y)‖ ≤ ε * r

tactic: apply le_of_lt
state_before: case intro.intro
𝕜 : Type u_1
inst✝⁴ : NontriviallyNormedField 𝕜
E : Type u_2
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace 𝕜 E
F : Type u_3
inst✝¹ : NormedAddCommGroup F
inst✝ : NormedSpace 𝕜 F
f : E → F
K : Set (E →L[𝕜] F)
r ε : ℝ
L : E →L[𝕜] F
x y z : E
hy : y ∈ closedBall x (r / 2)
hz : z ∈ closedBall x (r / 2)
r' : ℝ
r'mem : r' ∈ Ioc (r / 2) r
hr' : ∀ y ∈ ball x r', ∀ z ∈ ball x r', ‖f z - f y - L (z - y)‖ < ε * r
⊢ ‖f z - f y - L (z - y)‖ ≤ ε * r
state_after: case intro.intro.a
𝕜 : Type u_1
inst✝⁴ : NontriviallyNormedField 𝕜
E : Type u_2
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace 𝕜 E
F : Type u_3
inst✝¹ : NormedAddCommGroup F
inst✝ : NormedSpace 𝕜 F
f : E → F
K : Set (E →L[𝕜] F)
r ε : ℝ
L : E →L[𝕜] F
x y z : E
hy : y ∈ closedBall x (r / 2)
hz : z ∈ closedBall x (r / 2)
r' : ℝ
r'mem : r' ∈ Ioc (r / 2) r
hr' : ∀ y ∈ ball x r', ∀ z ∈ ball x r', ‖f z - f y - L (z - y)‖ < ε * r
⊢ ‖f z - f y - L (z - y)‖ < ε * r

tactic: exact hr' _ ((mem_closedBall.1 hy).trans_lt r'mem.1) _ ((mem_closedBall.1 hz).trans_lt r'mem.1)
state_before: case intro.intro.a
𝕜 : Type u_1
inst✝⁴ : NontriviallyNormedField 𝕜
E : Type u_2
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace 𝕜 E
F : Type u_3
inst✝¹ : NormedAddCommGroup F
inst✝ : NormedSpace 𝕜 F
f : E → F
K : Set (E →L[𝕜] F)
r ε : ℝ
L : E →L[𝕜] F
x y z : E
hy : y ∈ closedBall x (r / 2)
hz : z ∈ closedBall x (r / 2)
r' : ℝ
r'mem : r' ∈ Ioc (r / 2) r
hr' : ∀ y ∈ ball x r', ∀ z ∈ ball x r', ‖f z - f y - L (z - y)‖ < ε * r
⊢ ‖f z - f y - L (z - y)‖ < ε * r
state_after: no goals
Theorem: AntitoneOn.map_sup
File: Mathlib/Order/Lattice.lean

tactic: cases le_total x y <;> have := hf ?_ ?_ ‹_› <;>
  first
  | assumption
  | simp only [*, sup_of_le_left, sup_of_le_right, inf_of_le_left, inf_of_le_right]
state_before: α : Type u
β : Type v
f : α → β
s : Set α
x y : α
inst✝¹ : LinearOrder α
inst✝ : SemilatticeInf β
hf : AntitoneOn f s
hx : x ∈ s
hy : y ∈ s
⊢ f (x ⊔ y) = f x ⊓ f y
state_after: no goals

tactic: assumption
state_before: case inr.refine_2
α : Type u
β : Type v
f : α → β
s : Set α
x y : α
inst✝¹ : LinearOrder α
inst✝ : SemilatticeInf β
hf : AntitoneOn f s
hx : x ∈ s
hy : y ∈ s
h✝ : y ≤ x
⊢ x ∈ s
state_after: no goals

tactic: simp only [*, sup_of_le_left, sup_of_le_right, inf_of_le_left, inf_of_le_right]
state_before: case inr.refine_3
α : Type u
β : Type v
f : α → β
s : Set α
x y : α
inst✝¹ : LinearOrder α
inst✝ : SemilatticeInf β
hf : AntitoneOn f s
hx : x ∈ s
hy : y ∈ s
h✝ : y ≤ x
this : f x ≤ f y
⊢ f (x ⊔ y) = f x ⊓ f y
state_after: no goals
Theorem: LinearMap.separatingRight_iff_flip_ker_eq_bot
File: Mathlib/LinearAlgebra/SesquilinearForm.lean

tactic: rw [← flip_separatingLeft, separatingLeft_iff_ker_eq_bot]
state_before: R : Type u_1
R₁ : Type u_2
R₂ : Type u_3
R₃ : Type u_4
M : Type u_5
M₁ : Type u_6
M₂ : Type u_7
M₃ : Type u_8
Mₗ₁ : Type u_9
Mₗ₁' : Type u_10
Mₗ₂ : Type u_11
Mₗ₂' : Type u_12
K : Type u_13
K₁ : Type u_14
K₂ : Type u_15
V : Type u_16
V₁ : Type u_17
V₂ : Type u_18
n : Type u_19
inst✝⁸ : CommSemiring R
inst✝⁷ : AddCommMonoid M
inst✝⁶ : Module R M
inst✝⁵ : CommSemiring R₁
inst✝⁴ : AddCommMonoid M₁
inst✝³ : Module R₁ M₁
inst✝² : CommSemiring R₂
inst✝¹ : AddCommMonoid M₂
inst✝ : Module R₂ M₂
I₁ : R₁ →+* R
I₂ : R₂ →+* R
I₁' : R₁ →+* R
B : M₁ →ₛₗ[I₁] M₂ →ₛₗ[I₂] M
⊢ B.SeparatingRight ↔ ker B.flip = ⊥
state_after: no goals
Theorem: Configuration.ProjectivePlane.two_lt_lineCount
File: Mathlib/Combinatorics/Configuration.lean

tactic: simpa only [lineCount_eq L p, Nat.succ_lt_succ_iff] using one_lt_order P L
state_before: P : Type u_1
L : Type u_2
inst✝³ : Membership P L
inst✝² : ProjectivePlane P L
inst✝¹ : Finite P
inst✝ : Finite L
p : P
⊢ 2 < lineCount L p
state_after: no goals
Theorem: Polynomial.Chebyshev.T_neg_two
File: Mathlib/RingTheory/Polynomial/Chebyshev.lean

tactic: simp [T_two]
state_before: R : Type u_1
S : Type u_2
inst✝¹ : CommRing R
inst✝ : CommRing S
⊢ T R (-2) = 2 * X ^ 2 - 1
state_after: no goals
Theorem: NonUnitalAlgebra.map_bot
File: Mathlib/Algebra/Algebra/NonUnitalSubalgebra.lean

tactic: simp [NonUnitalAlgebra.coe_bot, NonUnitalSubalgebra.coe_map]
state_before: F : Type u_1
R : Type u
A : Type v
B : Type w
inst✝¹⁰ : CommSemiring R
inst✝⁹ : NonUnitalNonAssocSemiring A
inst✝⁸ : Module R A
inst✝⁷ : IsScalarTower R A A
inst✝⁶ : SMulCommClass R A A
inst✝⁵ : NonUnitalNonAssocSemiring B
inst✝⁴ : Module R B
inst✝³ : IsScalarTower R B B
inst✝² : SMulCommClass R B B
inst✝¹ : FunLike F A B
inst✝ : NonUnitalAlgHomClass F R A B
f : A →ₙₐ[R] B
⊢ ↑(NonUnitalSubalgebra.map f ⊥) = ↑⊥
state_after: no goals
Theorem: AffineMap.hasDerivAtFilter
File: Mathlib/Analysis/Calculus/Deriv/AffineMap.lean

tactic: rw [f.decomp]
state_before: 𝕜 : Type u_1
inst✝² : NontriviallyNormedField 𝕜
E : Type u_2
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f : 𝕜 →ᵃ[𝕜] E
a b : E
L : Filter 𝕜
s : Set 𝕜
x : 𝕜
⊢ HasDerivAtFilter (⇑f) (f.linear 1) x L
state_after: 𝕜 : Type u_1
inst✝² : NontriviallyNormedField 𝕜
E : Type u_2
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f : 𝕜 →ᵃ[𝕜] E
a b : E
L : Filter 𝕜
s : Set 𝕜
x : 𝕜
⊢ HasDerivAtFilter (⇑f.linear + fun x => f 0) (f.linear 1) x L

tactic: exact f.linear.hasDerivAtFilter.add_const (f 0)
state_before: 𝕜 : Type u_1
inst✝² : NontriviallyNormedField 𝕜
E : Type u_2
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f : 𝕜 →ᵃ[𝕜] E
a b : E
L : Filter 𝕜
s : Set 𝕜
x : 𝕜
⊢ HasDerivAtFilter (⇑f.linear + fun x => f 0) (f.linear 1) x L
state_after: no goals
Theorem: Cardinal.card_le_of
File: Mathlib/SetTheory/Cardinal/Basic.lean

tactic: contrapose! H
state_before: α✝ β α : Type u
n : ℕ
H : ∀ (s : Finset α), s.card ≤ n
⊢ #α ≤ ↑n
state_after: α✝ β α : Type u
n : ℕ
H : ↑n < #α
⊢ ∃ s, n < s.card

tactic: apply exists_finset_le_card α (n+1)
state_before: α✝ β α : Type u
n : ℕ
H : ↑n < #α
⊢ ∃ s, n < s.card
state_after: α✝ β α : Type u
n : ℕ
H : ↑n < #α
⊢ ↑(n + 1) ≤ #α

tactic: simpa only [nat_succ, succ_le_iff] using H
state_before: α✝ β α : Type u
n : ℕ
H : ↑n < #α
⊢ ↑(n + 1) ≤ #α
state_after: no goals
Theorem: Equiv.ofInjective_symm_apply
File: Mathlib/Logic/Equiv/Set.lean

tactic: apply (ofInjective f hf).injective
state_before: α✝ : Sort u
β✝ : Sort v
γ : Sort w
α : Sort u_1
β : Type u_2
f : α → β
hf : Injective f
a : α
⊢ (ofInjective f hf).symm ⟨f a, ⋯⟩ = a
state_after: case a
α✝ : Sort u
β✝ : Sort v
γ : Sort w
α : Sort u_1
β : Type u_2
f : α → β
hf : Injective f
a : α
⊢ (ofInjective f hf) ((ofInjective f hf).symm ⟨f a, ⋯⟩) = (ofInjective f hf) a

tactic: simp [apply_ofInjective_symm hf]
state_before: case a
α✝ : Sort u
β✝ : Sort v
γ : Sort w
α : Sort u_1
β : Type u_2
f : α → β
hf : Injective f
a : α
⊢ (ofInjective f hf) ((ofInjective f hf).symm ⟨f a, ⋯⟩) = (ofInjective f hf) a
state_after: no goals
Theorem: pow_sub_of_lt
File: Mathlib/Algebra/GroupWithZero/Units/Basic.lean

tactic: obtain rfl | ha := eq_or_ne a 0
state_before: α : Type u_1
M₀ : Type u_2
G₀ : Type u_3
M₀' : Type u_4
G₀' : Type u_5
F : Type u_6
F' : Type u_7
inst✝¹ : MonoidWithZero M₀
inst✝ : GroupWithZero G₀
a✝ b c d : G₀
m n : ℕ
a : G₀
h : n < m
⊢ a ^ (m - n) = a ^ m * (a ^ n)⁻¹
state_after: case inl
α : Type u_1
M₀ : Type u_2
G₀ : Type u_3
M₀' : Type u_4
G₀' : Type u_5
F : Type u_6
F' : Type u_7
inst✝¹ : MonoidWithZero M₀
inst✝ : GroupWithZero G₀
a b c d : G₀
m n : ℕ
h : n < m
⊢ 0 ^ (m - n) = 0 ^ m * (0 ^ n)⁻¹

case inr
α : Type u_1
M₀ : Type u_2
G₀ : Type u_3
M₀' : Type u_4
G₀' : Type u_5
F : Type u_6
F' : Type u_7
inst✝¹ : MonoidWithZero M₀
inst✝ : GroupWithZero G₀
a✝ b c d : G₀
m n : ℕ
a : G₀
h : n < m
ha : a ≠ 0
⊢ a ^ (m - n) = a ^ m * (a ^ n)⁻¹

tactic: rw [zero_pow (Nat.ne_of_gt <| Nat.sub_pos_of_lt h), zero_pow (by omega), zero_mul]
state_before: case inl
α : Type u_1
M₀ : Type u_2
G₀ : Type u_3
M₀' : Type u_4
G₀' : Type u_5
F : Type u_6
F' : Type u_7
inst✝¹ : MonoidWithZero M₀
inst✝ : GroupWithZero G₀
a b c d : G₀
m n : ℕ
h : n < m
⊢ 0 ^ (m - n) = 0 ^ m * (0 ^ n)⁻¹
state_after: no goals

tactic: omega
state_before: α : Type u_1
M₀ : Type u_2
G₀ : Type u_3
M₀' : Type u_4
G₀' : Type u_5
F : Type u_6
F' : Type u_7
inst✝¹ : MonoidWithZero M₀
inst✝ : GroupWithZero G₀
a b c d : G₀
m n : ℕ
h : n < m
⊢ m ≠ 0
state_after: no goals

tactic: exact pow_sub₀ _ ha <| Nat.le_of_lt h
state_before: case inr
α : Type u_1
M₀ : Type u_2
G₀ : Type u_3
M₀' : Type u_4
G₀' : Type u_5
F : Type u_6
F' : Type u_7
inst✝¹ : MonoidWithZero M₀
inst✝ : GroupWithZero G₀
a✝ b c d : G₀
m n : ℕ
a : G₀
h : n < m
ha : a ≠ 0
⊢ a ^ (m - n) = a ^ m * (a ^ n)⁻¹
state_after: no goals
Theorem: QuaternionGroup.quaternionGroup_one_isCyclic
File: Mathlib/GroupTheory/SpecificGroups/Quaternion.lean

tactic: apply isCyclic_of_orderOf_eq_card
state_before: n : ℕ
⊢ IsCyclic (QuaternionGroup 1)
state_after: case hx
n : ℕ
⊢ orderOf ?x = Fintype.card (QuaternionGroup 1)

case x
n : ℕ
⊢ QuaternionGroup 1

tactic: rw [card, mul_one]
state_before: case hx
n : ℕ
⊢ orderOf ?x = Fintype.card (QuaternionGroup 1)
state_after: case hx
n : ℕ
⊢ orderOf ?x = 4

tactic: exact orderOf_xa 0
state_before: case hx
n : ℕ
⊢ orderOf ?x = 4
state_after: no goals
Theorem: swap_idRel
File: Mathlib/Topology/UniformSpace/Basic.lean

tactic: simpa [image_swap_eq_preimage_swap] using eq_comm
state_before: α : Type ua
β : Type ub
γ : Type uc
δ : Type ud
ι : Sort u_1
x✝ : α × α
a b : α
⊢ (a, b) ∈ Prod.swap '' idRel ↔ (a, b) ∈ idRel
state_after: no goals
Theorem: PartialHomeomorph.map_extend_nhds
File: Mathlib/Geometry/Manifold/SmoothManifoldWithCorners.lean

tactic: rwa [extend_coe, comp_apply, ← I.map_nhds_eq, ← f.map_nhds_eq, map_map]
state_before: 𝕜 : Type u_1
E : Type u_2
M : Type u_3
H : Type u_4
E' : Type u_5
M' : Type u_6
H' : Type u_7
inst✝⁸ : NontriviallyNormedField 𝕜
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace 𝕜 E
inst✝⁵ : TopologicalSpace H
inst✝⁴ : TopologicalSpace M
f f' : PartialHomeomorph M H
I : ModelWithCorners 𝕜 E H
inst✝³ : NormedAddCommGroup E'
inst✝² : NormedSpace 𝕜 E'
inst✝¹ : TopologicalSpace H'
inst✝ : TopologicalSpace M'
I' : ModelWithCorners 𝕜 E' H'
s t : Set M
x : M
hy : x ∈ f.source
⊢ map (↑(f.extend I)) (𝓝 x) = 𝓝[range ↑I] ↑(f.extend I) x
state_after: no goals
Theorem: EReal.add_top_of_ne_bot
File: Mathlib/Data/Real/EReal.lean

tactic: rw [add_comm, top_add_of_ne_bot h]
state_before: x : EReal
h : x ≠ ⊥
⊢ x + ⊤ = ⊤
state_after: no goals
Theorem: Nat.Primrec'.prec'
File: Mathlib/Computability/Primrec.lean

tactic: simpa using comp' (prec hg hh) (hf.cons idv)
state_before: n : ℕ
f g : Vector ℕ n → ℕ
h : Vector ℕ (n + 2) → ℕ
hf : Primrec' f
hg : Primrec' g
hh : Primrec' h
⊢ Primrec' fun v => Nat.rec (g v) (fun y IH => h (y ::ᵥ IH ::ᵥ v)) (f v)
state_after: no goals
Theorem: Fin.card_Ici
File: Mathlib/Order/Interval/Finset/Fin.lean

tactic: clear b
state_before: n : ℕ
a b : Fin n
⊢ (Ici a).card = n - ↑a
state_after: n : ℕ
a : Fin n
⊢ (Ici a).card = n - ↑a

tactic: cases n with
| zero => exact Fin.elim0 a
| succ =>
  rw [← card_map, map_valEmbedding_Ici, Nat.card_Icc, Nat.add_one_sub_one]
state_before: n : ℕ
a : Fin n
⊢ (Ici a).card = n - ↑a
state_after: no goals

tactic: exact Fin.elim0 a
state_before: case zero
a : Fin 0
⊢ (Ici a).card = 0 - ↑a
state_after: no goals

tactic: rw [← card_map, map_valEmbedding_Ici, Nat.card_Icc, Nat.add_one_sub_one]
state_before: case succ
n✝ : ℕ
a : Fin (n✝ + 1)
⊢ (Ici a).card = n✝ + 1 - ↑a
state_after: no goals
Theorem: hasProd_single
File: Mathlib/Topology/Algebra/InfiniteSum/Basic.lean

tactic: simpa using this
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝¹ : CommMonoid α
inst✝ : TopologicalSpace α
f✝ g : β → α
a b✝ : α
s : Finset β
f : β → α
b : β
hf : ∀ (b' : β), b' ≠ b → f b' = 1
this : HasProd f (∏ b' ∈ {b}, f b')
⊢ HasProd f (f b)
state_after: no goals

tactic: simpa [hf]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
inst✝¹ : CommMonoid α
inst✝ : TopologicalSpace α
f✝ g : β → α
a b✝ : α
s : Finset β
f : β → α
b : β
hf : ∀ (b' : β), b' ≠ b → f b' = 1
⊢ ∀ b_1 ∉ {b}, f b_1 = 1
state_after: no goals
Theorem: div_lt_div_left
File: Mathlib/Algebra/Order/Field/Basic.lean

tactic: simp only [div_eq_mul_inv, mul_lt_mul_left ha, inv_lt_inv hb hc]
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
inst✝ : LinearOrderedSemifield α
a b c d e : α
m n : ℤ
ha : 0 < a
hb : 0 < b
hc : 0 < c
⊢ a / b < a / c ↔ c < b
state_after: no goals
Theorem: MeasureTheory.setLIntegral_const
File: Mathlib/MeasureTheory/Integral/Lebesgue.lean

tactic: rw [lintegral_const, Measure.restrict_apply_univ]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
m : MeasurableSpace α
μ ν : Measure α
s : Set α
c : ℝ≥0∞
⊢ ∫⁻ (x : α) in s, c ∂μ = c * μ s
state_after: no goals
Theorem: List.indexOf_cons
File: .lake/packages/batteries/Batteries/Data/List/Lemmas.lean

tactic: dsimp [indexOf]
state_before: α : Type u_1
x : α
xs : List α
y : α
inst✝ : BEq α
⊢ indexOf y (x :: xs) = bif x == y then 0 else indexOf y xs + 1
state_after: α : Type u_1
x : α
xs : List α
y : α
inst✝ : BEq α
⊢ findIdx (fun x => x == y) (x :: xs) = bif x == y then 0 else findIdx (fun x => x == y) xs + 1

tactic: simp [findIdx_cons]
state_before: α : Type u_1
x : α
xs : List α
y : α
inst✝ : BEq α
⊢ findIdx (fun x => x == y) (x :: xs) = bif x == y then 0 else findIdx (fun x => x == y) xs + 1
state_after: no goals