1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: Nat.totient_even
File: Mathlib/Data/Nat/Totient.lean

tactic: haveI : Fact (1 < n) := ⟨one_lt_two.trans hn⟩
state_before: n : ℕ
hn : 2 < n
⊢ Even (φ n)
state_after: n : ℕ
hn : 2 < n
this : Fact (1 < n)
⊢ Even (φ n)

tactic: haveI : NeZero n := NeZero.of_gt hn
state_before: n : ℕ
hn : 2 < n
this : Fact (1 < n)
⊢ Even (φ n)
state_after: n : ℕ
hn : 2 < n
this✝ : Fact (1 < n)
this : NeZero n
⊢ Even (φ n)

tactic: suffices 2 = orderOf (-1 : (ZMod n)ˣ) by
  rw [← ZMod.card_units_eq_totient, even_iff_two_dvd, this]
  exact orderOf_dvd_card
state_before: n : ℕ
hn : 2 < n
this✝ : Fact (1 < n)
this : NeZero n
⊢ Even (φ n)
state_after: n : ℕ
hn : 2 < n
this✝ : Fact (1 < n)
this : NeZero n
⊢ 2 = orderOf (-1)

tactic: rw [← orderOf_units, Units.coe_neg_one, orderOf_neg_one, ringChar.eq (ZMod n) n, if_neg hn.ne']
state_before: n : ℕ
hn : 2 < n
this✝ : Fact (1 < n)
this : NeZero n
⊢ 2 = orderOf (-1)
state_after: no goals

tactic: rw [← ZMod.card_units_eq_totient, even_iff_two_dvd, this]
state_before: n : ℕ
hn : 2 < n
this✝¹ : Fact (1 < n)
this✝ : NeZero n
this : 2 = orderOf (-1)
⊢ Even (φ n)
state_after: n : ℕ
hn : 2 < n
this✝¹ : Fact (1 < n)
this✝ : NeZero n
this : 2 = orderOf (-1)
⊢ orderOf (-1) ∣ Fintype.card (ZMod n)ˣ

tactic: exact orderOf_dvd_card
state_before: n : ℕ
hn : 2 < n
this✝¹ : Fact (1 < n)
this✝ : NeZero n
this : 2 = orderOf (-1)
⊢ orderOf (-1) ∣ Fintype.card (ZMod n)ˣ
state_after: no goals
Theorem: AffineMap.lineMap_apply_module
File: Mathlib/LinearAlgebra/AffineSpace/AffineMap.lean

tactic: simp [lineMap_apply_module', smul_sub, sub_smul]
state_before: k : Type u_1
V1 : Type u_2
P1 : Type u_3
V2 : Type u_4
P2 : Type u_5
V3 : Type u_6
P3 : Type u_7
V4 : Type u_8
P4 : Type u_9
inst✝¹² : Ring k
inst✝¹¹ : AddCommGroup V1
inst✝¹⁰ : Module k V1
inst✝⁹ : AffineSpace V1 P1
inst✝⁸ : AddCommGroup V2
inst✝⁷ : Module k V2
inst✝⁶ : AffineSpace V2 P2
inst✝⁵ : AddCommGroup V3
inst✝⁴ : Module k V3
inst✝³ : AffineSpace V3 P3
inst✝² : AddCommGroup V4
inst✝¹ : Module k V4
inst✝ : AffineSpace V4 P4
p₀ p₁ : V1
c : k
⊢ (lineMap p₀ p₁) c = (1 - c) • p₀ + c • p₁
state_after: k : Type u_1
V1 : Type u_2
P1 : Type u_3
V2 : Type u_4
P2 : Type u_5
V3 : Type u_6
P3 : Type u_7
V4 : Type u_8
P4 : Type u_9
inst✝¹² : Ring k
inst✝¹¹ : AddCommGroup V1
inst✝¹⁰ : Module k V1
inst✝⁹ : AffineSpace V1 P1
inst✝⁸ : AddCommGroup V2
inst✝⁷ : Module k V2
inst✝⁶ : AffineSpace V2 P2
inst✝⁵ : AddCommGroup V3
inst✝⁴ : Module k V3
inst✝³ : AffineSpace V3 P3
inst✝² : AddCommGroup V4
inst✝¹ : Module k V4
inst✝ : AffineSpace V4 P4
p₀ p₁ : V1
c : k
⊢ c • p₁ - c • p₀ + p₀ = p₀ - c • p₀ + c • p₁

tactic: abel
state_before: k : Type u_1
V1 : Type u_2
P1 : Type u_3
V2 : Type u_4
P2 : Type u_5
V3 : Type u_6
P3 : Type u_7
V4 : Type u_8
P4 : Type u_9
inst✝¹² : Ring k
inst✝¹¹ : AddCommGroup V1
inst✝¹⁰ : Module k V1
inst✝⁹ : AffineSpace V1 P1
inst✝⁸ : AddCommGroup V2
inst✝⁷ : Module k V2
inst✝⁶ : AffineSpace V2 P2
inst✝⁵ : AddCommGroup V3
inst✝⁴ : Module k V3
inst✝³ : AffineSpace V3 P3
inst✝² : AddCommGroup V4
inst✝¹ : Module k V4
inst✝ : AffineSpace V4 P4
p₀ p₁ : V1
c : k
⊢ c • p₁ - c • p₀ + p₀ = p₀ - c • p₀ + c • p₁
state_after: no goals
Theorem: Urysohns.CU.lim_of_nmem_U
File: Mathlib/Topology/UrysohnsLemma.lean

tactic: simp only [CU.lim, approx_of_nmem_U c _ h, ciSup_const]
state_before: X : Type u_1
inst✝ : TopologicalSpace X
P : Set X → Prop
c : CU P
x : X
h : x ∉ c.U
⊢ c.lim x = 1
state_after: no goals
Theorem: Finset.coe_powerset
File: Mathlib/Data/Finset/Powerset.lean

tactic: ext
state_before: α : Type u_1
s✝ t s : Finset α
⊢ ↑s.powerset = toSet ⁻¹' 𝒫↑s
state_after: case h
α : Type u_1
s✝ t s x✝ : Finset α
⊢ x✝ ∈ ↑s.powerset ↔ x✝ ∈ toSet ⁻¹' 𝒫↑s

tactic: simp
state_before: case h
α : Type u_1
s✝ t s x✝ : Finset α
⊢ x✝ ∈ ↑s.powerset ↔ x✝ ∈ toSet ⁻¹' 𝒫↑s
state_after: no goals
Theorem: Subalgebra.equivOfEq_rfl
File: Mathlib/Algebra/Algebra/Subalgebra/Basic.lean

tactic: ext
state_before: R : Type u
A : Type v
B : Type w
inst✝⁴ : CommSemiring R
inst✝³ : Semiring A
inst✝² : Algebra R A
inst✝¹ : Semiring B
inst✝ : Algebra R B
S✝ S : Subalgebra R A
⊢ S.equivOfEq S ⋯ = AlgEquiv.refl
state_after: case h.a
R : Type u
A : Type v
B : Type w
inst✝⁴ : CommSemiring R
inst✝³ : Semiring A
inst✝² : Algebra R A
inst✝¹ : Semiring B
inst✝ : Algebra R B
S✝ S : Subalgebra R A
a✝ : ↥S
⊢ ↑((S.equivOfEq S ⋯) a✝) = ↑(AlgEquiv.refl a✝)

tactic: rfl
state_before: case h.a
R : Type u
A : Type v
B : Type w
inst✝⁴ : CommSemiring R
inst✝³ : Semiring A
inst✝² : Algebra R A
inst✝¹ : Semiring B
inst✝ : Algebra R B
S✝ S : Subalgebra R A
a✝ : ↥S
⊢ ↑((S.equivOfEq S ⋯) a✝) = ↑(AlgEquiv.refl a✝)
state_after: no goals
Theorem: Nat.ofDigits_eq_sum_mapIdx
File: Mathlib/Data/Nat/Digits.lean

tactic: rw [List.mapIdx_eq_enum_map, List.enum_eq_zip_range, List.map_uncurry_zip_eq_zipWith,
  ofDigits_eq_foldr]
state_before: n b : ℕ
L : List ℕ
⊢ ofDigits b L = (List.mapIdx (fun i a => a * b ^ i) L).sum
state_after: n b : ℕ
L : List ℕ
⊢ List.foldr (fun x y => ↑x + b * y) 0 L = (List.zipWith (fun i a => a * b ^ i) (List.range L.length) L).sum

tactic: induction' L with hd tl hl
state_before: n b : ℕ
L : List ℕ
⊢ List.foldr (fun x y => ↑x + b * y) 0 L = (List.zipWith (fun i a => a * b ^ i) (List.range L.length) L).sum
state_after: case nil
n b : ℕ
⊢ List.foldr (fun x y => ↑x + b * y) 0 [] = (List.zipWith (fun i a => a * b ^ i) (List.range [].length) []).sum

case cons
n b hd : ℕ
tl : List ℕ
hl : List.foldr (fun x y => ↑x + b * y) 0 tl = (List.zipWith (fun i a => a * b ^ i) (List.range tl.length) tl).sum
⊢ List.foldr (fun x y => ↑x + b * y) 0 (hd :: tl) =
    (List.zipWith (fun i a => a * b ^ i) (List.range (hd :: tl).length) (hd :: tl)).sum

tactic: simp
state_before: case nil
n b : ℕ
⊢ List.foldr (fun x y => ↑x + b * y) 0 [] = (List.zipWith (fun i a => a * b ^ i) (List.range [].length) []).sum
state_after: no goals

tactic: simpa [List.range_succ_eq_map, List.zipWith_map_left, ofDigits_eq_sum_map_with_index_aux] using
  Or.inl hl
state_before: case cons
n b hd : ℕ
tl : List ℕ
hl : List.foldr (fun x y => ↑x + b * y) 0 tl = (List.zipWith (fun i a => a * b ^ i) (List.range tl.length) tl).sum
⊢ List.foldr (fun x y => ↑x + b * y) 0 (hd :: tl) =
    (List.zipWith (fun i a => a * b ^ i) (List.range (hd :: tl).length) (hd :: tl)).sum
state_after: no goals
Theorem: Traversable.map_traverse'
File: Mathlib/Control/Traversable/Lemmas.lean

tactic: ext
state_before: t : Type u → Type u
inst✝⁵ : Traversable t
inst✝⁴ : LawfulTraversable t
F G : Type u → Type u
inst✝³ : Applicative F
inst✝² : LawfulApplicative F
inst✝¹ : Applicative G
inst✝ : LawfulApplicative G
α β γ : Type u
g✝ : α → F β
h✝ : β → G γ
f : β → γ
x : t β
g : α → G β
h : β → γ
⊢ traverse (map h ∘ g) = map (map h) ∘ traverse g
state_after: case h
t : Type u → Type u
inst✝⁵ : Traversable t
inst✝⁴ : LawfulTraversable t
F G : Type u → Type u
inst✝³ : Applicative F
inst✝² : LawfulApplicative F
inst✝¹ : Applicative G
inst✝ : LawfulApplicative G
α β γ : Type u
g✝ : α → F β
h✝ : β → G γ
f : β → γ
x : t β
g : α → G β
h : β → γ
x✝ : t α
⊢ traverse (map h ∘ g) x✝ = (map (map h) ∘ traverse g) x✝

tactic: rw [comp_apply, map_traverse]
state_before: case h
t : Type u → Type u
inst✝⁵ : Traversable t
inst✝⁴ : LawfulTraversable t
F G : Type u → Type u
inst✝³ : Applicative F
inst✝² : LawfulApplicative F
inst✝¹ : Applicative G
inst✝ : LawfulApplicative G
α β γ : Type u
g✝ : α → F β
h✝ : β → G γ
f : β → γ
x : t β
g : α → G β
h : β → γ
x✝ : t α
⊢ traverse (map h ∘ g) x✝ = (map (map h) ∘ traverse g) x✝
state_after: no goals
Theorem: Orientation.normSq_kahler
File: Mathlib/Analysis/InnerProductSpace/TwoDim.lean

tactic: simpa [kahler_apply_apply, Complex.normSq, sq] using o.inner_sq_add_areaForm_sq x y
state_before: E : Type u_1
inst✝² : NormedAddCommGroup E
inst✝¹ : InnerProductSpace ℝ E
inst✝ : Fact (finrank ℝ E = 2)
o : Orientation ℝ E (Fin 2)
x y : E
⊢ Complex.normSq ((o.kahler x) y) = ‖x‖ ^ 2 * ‖y‖ ^ 2
state_after: no goals
Theorem: Homotopy.map_eq_of_inverts_homotopyEquivalences
File: Mathlib/Algebra/Homology/HomotopyCofiber.lean

tactic: simp only [← cylinder.ι₀_desc _ _ h, ← cylinder.ι₁_desc _ _ h, H.map_comp,
  cylinder.map_ι₀_eq_map_ι₁ _ hc _ hH]
state_before: C : Type u_1
inst✝⁸ : Category.{u_4, u_1} C
inst✝⁷ : Preadditive C
ι : Type u_2
c : ComplexShape ι
F G K : HomologicalComplex C c
φ : F ⟶ G
inst✝⁶ : HasHomotopyCofiber φ
inst✝⁵ : DecidableRel c.Rel
inst✝⁴ : ∀ (i : ι), HasBinaryBiproduct (K.X i) (K.X i)
inst✝³ : HasHomotopyCofiber (biprod.lift (𝟙 K) (-𝟙 K))
φ₀ φ₁ : F ⟶ G
h : Homotopy φ₀ φ₁
hc : ∀ (j : ι), ∃ i, c.Rel i j
inst✝² : ∀ (i : ι), HasBinaryBiproduct (F.X i) (F.X i)
inst✝¹ : HasHomotopyCofiber (biprod.lift (𝟙 F) (-𝟙 F))
D : Type u_3
inst✝ : Category.{u_5, u_3} D
H : HomologicalComplex C c ⥤ D
hH : (homotopyEquivalences C c).IsInvertedBy H
⊢ H.map φ₀ = H.map φ₁
state_after: no goals
Theorem: Quaternion.re_exp
File: Mathlib/Analysis/NormedSpace/QuaternionExponential.lean

tactic: simp [exp_eq]
state_before: q : ℍ
⊢ (exp ℝ q).re = exp ℝ q.re * Real.cos ‖q - ↑q.re‖
state_after: no goals
Theorem: Submodule.ker_inl
File: Mathlib/LinearAlgebra/Prod.lean

tactic: rw [ker, ← prod_bot, prod_comap_inl]
state_before: R : Type u
K : Type u'
M : Type v
V : Type v'
M₂ : Type w
V₂ : Type w'
M₃ : Type y
V₃ : Type y'
M₄ : Type z
ι : Type x
M₅ : Type u_1
M₆ : Type u_2
inst✝⁴ : Semiring R
inst✝³ : AddCommMonoid M
inst✝² : AddCommMonoid M₂
inst✝¹ : Module R M
inst✝ : Module R M₂
p : Submodule R M
q : Submodule R M₂
⊢ ker (inl R M M₂) = ⊥
state_after: no goals
Theorem: Set.encard_le_card
File: Mathlib/Data/Set/Card.lean

tactic: rw [← union_diff_cancel h, encard_union_eq disjoint_sdiff_right]
state_before: α : Type u_1
β : Type u_2
s t : Set α
h : s ⊆ t
⊢ s.encard ≤ t.encard
state_after: α : Type u_1
β : Type u_2
s t : Set α
h : s ⊆ t
⊢ s.encard ≤ s.encard + (t \ s).encard

tactic: exact le_self_add
state_before: α : Type u_1
β : Type u_2
s t : Set α
h : s ⊆ t
⊢ s.encard ≤ s.encard + (t \ s).encard
state_after: no goals
Theorem: TendstoLocallyUniformly.comp
File: Mathlib/Topology/UniformSpace/UniformConvergence.lean

tactic: rw [← tendstoLocallyUniformlyOn_univ] at h ⊢
state_before: α : Type u
β : Type v
γ : Type w
ι : Type x
inst✝² : UniformSpace β
F : ι → α → β
f : α → β
s s' : Set α
x : α
p : Filter ι
p' : Filter α
g✝ : ι → α
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace γ
h : TendstoLocallyUniformly F f p
g : γ → α
cg : Continuous g
⊢ TendstoLocallyUniformly (fun n => F n ∘ g) (f ∘ g) p
state_after: α : Type u
β : Type v
γ : Type w
ι : Type x
inst✝² : UniformSpace β
F : ι → α → β
f : α → β
s s' : Set α
x : α
p : Filter ι
p' : Filter α
g✝ : ι → α
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace γ
h : TendstoLocallyUniformlyOn F f p univ
g : γ → α
cg : Continuous g
⊢ TendstoLocallyUniformlyOn (fun n => F n ∘ g) (f ∘ g) p univ

tactic: rw [continuous_iff_continuousOn_univ] at cg
state_before: α : Type u
β : Type v
γ : Type w
ι : Type x
inst✝² : UniformSpace β
F : ι → α → β
f : α → β
s s' : Set α
x : α
p : Filter ι
p' : Filter α
g✝ : ι → α
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace γ
h : TendstoLocallyUniformlyOn F f p univ
g : γ → α
cg : Continuous g
⊢ TendstoLocallyUniformlyOn (fun n => F n ∘ g) (f ∘ g) p univ
state_after: α : Type u
β : Type v
γ : Type w
ι : Type x
inst✝² : UniformSpace β
F : ι → α → β
f : α → β
s s' : Set α
x : α
p : Filter ι
p' : Filter α
g✝ : ι → α
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace γ
h : TendstoLocallyUniformlyOn F f p univ
g : γ → α
cg : ContinuousOn g univ
⊢ TendstoLocallyUniformlyOn (fun n => F n ∘ g) (f ∘ g) p univ

tactic: exact h.comp _ (mapsTo_univ _ _) cg
state_before: α : Type u
β : Type v
γ : Type w
ι : Type x
inst✝² : UniformSpace β
F : ι → α → β
f : α → β
s s' : Set α
x : α
p : Filter ι
p' : Filter α
g✝ : ι → α
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace γ
h : TendstoLocallyUniformlyOn F f p univ
g : γ → α
cg : ContinuousOn g univ
⊢ TendstoLocallyUniformlyOn (fun n => F n ∘ g) (f ∘ g) p univ
state_after: no goals
Theorem: Polynomial.natDegree_eq_of_degree_eq_some
File: Mathlib/Algebra/Polynomial/Degree/Definitions.lean

tactic: rw [natDegree, h, Nat.cast_withBot, WithBot.unbot'_coe]
state_before: R : Type u
S : Type v
a b c d : R
n✝ m : ℕ
inst✝ : Semiring R
p✝ q r p : R[X]
n : ℕ
h : p.degree = ↑n
⊢ p.natDegree = n
state_after: no goals
Theorem: MeasureTheory.IsStoppingTime.add_const
File: Mathlib/Probability/Process/Stopping.lean

tactic: intro j
state_before: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝³ : AddGroup ι
inst✝² : Preorder ι
inst✝¹ : CovariantClass ι ι (Function.swap fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
inst✝ : CovariantClass ι ι (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
f : Filtration ι m
τ : Ω → ι
hτ : IsStoppingTime f τ
i : ι
hi : 0 ≤ i
⊢ IsStoppingTime f fun ω => τ ω + i
state_after: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝³ : AddGroup ι
inst✝² : Preorder ι
inst✝¹ : CovariantClass ι ι (Function.swap fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
inst✝ : CovariantClass ι ι (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
f : Filtration ι m
τ : Ω → ι
hτ : IsStoppingTime f τ
i : ι
hi : 0 ≤ i
j : ι
⊢ MeasurableSet {ω | (fun ω => τ ω + i) ω ≤ j}

tactic: simp_rw [← le_sub_iff_add_le]
state_before: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝³ : AddGroup ι
inst✝² : Preorder ι
inst✝¹ : CovariantClass ι ι (Function.swap fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
inst✝ : CovariantClass ι ι (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
f : Filtration ι m
τ : Ω → ι
hτ : IsStoppingTime f τ
i : ι
hi : 0 ≤ i
j : ι
⊢ MeasurableSet {ω | (fun ω => τ ω + i) ω ≤ j}
state_after: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝³ : AddGroup ι
inst✝² : Preorder ι
inst✝¹ : CovariantClass ι ι (Function.swap fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
inst✝ : CovariantClass ι ι (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
f : Filtration ι m
τ : Ω → ι
hτ : IsStoppingTime f τ
i : ι
hi : 0 ≤ i
j : ι
⊢ MeasurableSet {ω | τ ω ≤ j - i}

tactic: exact f.mono (sub_le_self j hi) _ (hτ (j - i))
state_before: Ω : Type u_1
β : Type u_2
ι : Type u_3
m : MeasurableSpace Ω
inst✝³ : AddGroup ι
inst✝² : Preorder ι
inst✝¹ : CovariantClass ι ι (Function.swap fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
inst✝ : CovariantClass ι ι (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
f : Filtration ι m
τ : Ω → ι
hτ : IsStoppingTime f τ
i : ι
hi : 0 ≤ i
j : ι
⊢ MeasurableSet {ω | τ ω ≤ j - i}
state_after: no goals
Theorem: odd_iff_exists_bit1
File: Mathlib/Algebra/Ring/Parity.lean

tactic: rw [two_mul]
state_before: F : Type u_1
α : Type u_2
β : Type u_3
R : Type u_4
inst✝¹ : Semiring α
inst✝ : Semiring β
a b✝ : α
m n : ℕ
b : α
⊢ a = 2 * b + 1 ↔ a = bit1 b
state_after: F : Type u_1
α : Type u_2
β : Type u_3
R : Type u_4
inst✝¹ : Semiring α
inst✝ : Semiring β
a b✝ : α
m n : ℕ
b : α
⊢ a = b + b + 1 ↔ a = bit1 b

tactic: rfl
state_before: F : Type u_1
α : Type u_2
β : Type u_3
R : Type u_4
inst✝¹ : Semiring α
inst✝ : Semiring β
a b✝ : α
m n : ℕ
b : α
⊢ a = b + b + 1 ↔ a = bit1 b
state_after: no goals
Theorem: NormedRing.inverse_add_norm
File: Mathlib/Analysis/NormedSpace/Units.lean

tactic: refine EventuallyEq.trans_isBigO (inverse_add x) (one_mul (1 : ℝ) ▸ ?_)
state_before: R : Type u_1
inst✝¹ : NormedRing R
inst✝ : CompleteSpace R
x : Rˣ
⊢ (fun t => inverse (↑x + t)) =O[𝓝 0] fun _t => 1
state_after: R : Type u_1
inst✝¹ : NormedRing R
inst✝ : CompleteSpace R
x : Rˣ
⊢ (fun x_1 => inverse (1 + ↑x⁻¹ * x_1) * ↑x⁻¹) =O[𝓝 0] fun _t => 1 * 1

tactic: simp only [← sub_neg_eq_add, ← neg_mul]
state_before: R : Type u_1
inst✝¹ : NormedRing R
inst✝ : CompleteSpace R
x : Rˣ
⊢ (fun x_1 => inverse (1 + ↑x⁻¹ * x_1) * ↑x⁻¹) =O[𝓝 0] fun _t => 1 * 1
state_after: R : Type u_1
inst✝¹ : NormedRing R
inst✝ : CompleteSpace R
x : Rˣ
⊢ (fun x_1 => inverse (1 - -↑x⁻¹ * x_1) * ↑x⁻¹) =O[𝓝 0] fun _t => 1 * 1

tactic: exact (inverse_one_sub_norm.comp_tendsto hzero).mul (isBigO_const_const _ one_ne_zero _)
state_before: R : Type u_1
inst✝¹ : NormedRing R
inst✝ : CompleteSpace R
x : Rˣ
hzero : Tendsto (fun x_1 => -↑x⁻¹ * x_1) (𝓝 0) (𝓝 0)
⊢ (fun x_1 => inverse (1 - -↑x⁻¹ * x_1) * ↑x⁻¹) =O[𝓝 0] fun _t => 1 * 1
state_after: no goals
Theorem: div_right_comm
File: Mathlib/Algebra/Group/Basic.lean

tactic: simp
state_before: α : Type u_1
β : Type u_2
G : Type u_3
M : Type u_4
inst✝ : DivisionCommMonoid α
a b c d : α
⊢ a / b / c = a / c / b
state_after: no goals
Theorem: antivaryOn_inv₀
File: Mathlib/Algebra/Order/Monovary.lean

tactic: rw [antivaryOn_inv_left₀ hf, monovaryOn_inv_right₀ hg]
state_before: ι : Type u_1
α : Type u_2
β : Type u_3
inst✝¹ : LinearOrderedSemifield α
inst✝ : LinearOrderedSemifield β
s : Set ι
f f₁ f₂ : ι → α
g g₁ g₂ : ι → β
hf : ∀ i ∈ s, 0 < f i
hg : ∀ i ∈ s, 0 < g i
⊢ AntivaryOn f⁻¹ g⁻¹ s ↔ AntivaryOn f g s
state_after: no goals
Theorem: Multiset.mem_sub_of_nodup
File: Mathlib/Data/Multiset/Nodup.lean

tactic: refine count_eq_zero.1 ?_ h
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
r : α → α → Prop
s✝ t✝ : Multiset α
a✝ : α
inst✝ : DecidableEq α
a : α
s t : Multiset α
d : s.Nodup
h : a ∈ s - t
h' : a ∈ t
⊢ False
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
r : α → α → Prop
s✝ t✝ : Multiset α
a✝ : α
inst✝ : DecidableEq α
a : α
s t : Multiset α
d : s.Nodup
h : a ∈ s - t
h' : a ∈ t
⊢ count a (s - t) = 0

tactic: rw [count_sub a s t, Nat.sub_eq_zero_iff_le]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
r : α → α → Prop
s✝ t✝ : Multiset α
a✝ : α
inst✝ : DecidableEq α
a : α
s t : Multiset α
d : s.Nodup
h : a ∈ s - t
h' : a ∈ t
⊢ count a (s - t) = 0
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
r : α → α → Prop
s✝ t✝ : Multiset α
a✝ : α
inst✝ : DecidableEq α
a : α
s t : Multiset α
d : s.Nodup
h : a ∈ s - t
h' : a ∈ t
⊢ count a s ≤ count a t

tactic: exact le_trans (nodup_iff_count_le_one.1 d _) (count_pos.2 h')
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
r : α → α → Prop
s✝ t✝ : Multiset α
a✝ : α
inst✝ : DecidableEq α
a : α
s t : Multiset α
d : s.Nodup
h : a ∈ s - t
h' : a ∈ t
⊢ count a s ≤ count a t
state_after: no goals
Theorem: MvPolynomial.killCompl_comp_rename
File: Mathlib/Algebra/MvPolynomial/Rename.lean

tactic: dsimp
state_before: σ : Type u_1
τ : Type u_2
α : Type u_3
R : Type u_4
S : Type u_5
inst✝¹ : CommSemiring R
inst✝ : CommSemiring S
f : σ → τ
hf : Injective f
i : σ
⊢ ((killCompl hf).comp (rename f)) (X i) = (AlgHom.id R (MvPolynomial σ R)) (X i)
state_after: σ : Type u_1
τ : Type u_2
α : Type u_3
R : Type u_4
S : Type u_5
inst✝¹ : CommSemiring R
inst✝ : CommSemiring S
f : σ → τ
hf : Injective f
i : σ
⊢ (killCompl hf) ((rename f) (X i)) = X i

tactic: rw [rename, killCompl, aeval_X, comp_apply, aeval_X, dif_pos, Equiv.ofInjective_symm_apply]
state_before: σ : Type u_1
τ : Type u_2
α : Type u_3
R : Type u_4
S : Type u_5
inst✝¹ : CommSemiring R
inst✝ : CommSemiring S
f : σ → τ
hf : Injective f
i : σ
⊢ (killCompl hf) ((rename f) (X i)) = X i
state_after: no goals
Theorem: List.mk_mem_enum_iff_get?
File: Mathlib/Data/List/Enum.lean

tactic: simp [enum, mk_mem_enumFrom_iff_le_and_get?_sub]
state_before: α : Type u_1
β : Type u_2
i : ℕ
x : α
l : List α
⊢ (i, x) ∈ l.enum ↔ l.get? i = some x
state_after: no goals
Theorem: Nat.Partrec'.comp'
File: Mathlib/Computability/Halting.lean

tactic: simp
state_before: n m : ℕ
f : Vector ℕ m →. ℕ
g : Vector ℕ n → Vector ℕ m
hf : Partrec' f
hg : Vec g
v : Vector ℕ n
⊢ (mOfFn fun i => ↑(some ((g v).get i))) >>= f = f (g v)
state_after: no goals
Theorem: HomotopyCategory.respectsIso_quasiIso
File: Mathlib/Algebra/Homology/Localization.lean

tactic: apply MorphismProperty.RespectsIso.of_respects_arrow_iso
state_before: C : Type u_1
inst✝³ : Category.{u_3, u_1} C
ι : Type u_2
c : ComplexShape ι
inst✝² : Preadditive C
inst✝¹ : CategoryWithHomology C
inst✝ : (HomologicalComplex.quasiIso C c).HasLocalization
⊢ (quasiIso C c).RespectsIso
state_after: case hP
C : Type u_1
inst✝³ : Category.{u_3, u_1} C
ι : Type u_2
c : ComplexShape ι
inst✝² : Preadditive C
inst✝¹ : CategoryWithHomology C
inst✝ : (HomologicalComplex.quasiIso C c).HasLocalization
⊢ ∀ (f g : Arrow (HomotopyCategory C c)), (f ≅ g) → quasiIso C c f.hom → quasiIso C c g.hom

tactic: intro f g e hf i
state_before: case hP
C : Type u_1
inst✝³ : Category.{u_3, u_1} C
ι : Type u_2
c : ComplexShape ι
inst✝² : Preadditive C
inst✝¹ : CategoryWithHomology C
inst✝ : (HomologicalComplex.quasiIso C c).HasLocalization
⊢ ∀ (f g : Arrow (HomotopyCategory C c)), (f ≅ g) → quasiIso C c f.hom → quasiIso C c g.hom
state_after: case hP
C : Type u_1
inst✝³ : Category.{u_3, u_1} C
ι : Type u_2
c : ComplexShape ι
inst✝² : Preadditive C
inst✝¹ : CategoryWithHomology C
inst✝ : (HomologicalComplex.quasiIso C c).HasLocalization
f g : Arrow (HomotopyCategory C c)
e : f ≅ g
hf : quasiIso C c f.hom
i : ι
⊢ IsIso ((homologyFunctor C c i).map g.hom)

tactic: exact ((MorphismProperty.RespectsIso.isomorphisms C).arrow_mk_iso_iff
  ((homologyFunctor C c i).mapArrow.mapIso e)).1 (hf i)
state_before: case hP
C : Type u_1
inst✝³ : Category.{u_3, u_1} C
ι : Type u_2
c : ComplexShape ι
inst✝² : Preadditive C
inst✝¹ : CategoryWithHomology C
inst✝ : (HomologicalComplex.quasiIso C c).HasLocalization
f g : Arrow (HomotopyCategory C c)
e : f ≅ g
hf : quasiIso C c f.hom
i : ι
⊢ IsIso ((homologyFunctor C c i).map g.hom)
state_after: no goals
Theorem: Sum.swap_swap
File: .lake/packages/batteries/Batteries/Data/Sum/Lemmas.lean

tactic: cases x <;> rfl
state_before: α : Type u_1
β : Type u_2
x : α ⊕ β
⊢ x.swap.swap = x
state_after: no goals
Theorem: WeierstrassCurve.Jacobian.addXYZ_neg
File: Mathlib/AlgebraicGeometry/EllipticCurve/Jacobian.lean

tactic: erw [addXYZ, addX_neg hP, addY_neg hP, addZ_neg, smul_fin3, neg_sq, mul_one,
  Odd.neg_pow <| by decide, mul_one, mul_zero]
state_before: R : Type u
inst✝¹ : CommRing R
W' : Jacobian R
F : Type v
inst✝ : Field F
W : Jacobian F
P : Fin 3 → R
hP : W'.Equation P
⊢ W'.addXYZ P (W'.neg P) = -W'.dblZ P • ![1, 1, 0]
state_after: no goals

tactic: decide
state_before: R : Type u
inst✝¹ : CommRing R
W' : Jacobian R
F : Type v
inst✝ : Field F
W : Jacobian F
P : Fin 3 → R
hP : W'.Equation P
⊢ Odd 3
state_after: no goals
Theorem: Vector.mapAccumr₂_mapAccumr₂_right_left
File: Mathlib/Data/Vector/MapLemmas.lean

tactic: induction xs, ys using Vector.revInductionOn₂ generalizing s₁ s₂ <;> simp_all
state_before: α : Type
n : ℕ
β : Type
xs : Vector α n
ys : Vector β n
γ σ₁ φ σ₂ : Type
s₂ : σ₂
s₁ : σ₁
f₁ : α → γ → σ₁ → σ₁ × φ
f₂ : α → β → σ₂ → σ₂ × γ
⊢ mapAccumr₂ f₁ xs (mapAccumr₂ f₂ xs ys s₂).2 s₁ =
    let m :=
      mapAccumr₂
        (fun x y x_1 =>
          match x_1 with
          | (s₁, s₂) =>
            let r₂ := f₂ x y s₂;
            let r₁ := f₁ x r₂.2 s₁;
            ((r₁.1, r₂.1), r₁.2))
        xs ys (s₁, s₂);
    (m.1.1, m.2)
state_after: no goals
Theorem: Subgroup.subgroup_mul_singleton
File: Mathlib/Algebra/Group/Subgroup/Pointwise.lean

tactic: simpa [preimage, mul_mem_cancel_right (inv_mem hh)]
state_before: α : Type u_1
G : Type u_2
A : Type u_3
S : Type u_4
inst✝³ : Group G
inst✝² : AddGroup A
s : Set G
inst✝¹ : Group α
inst✝ : MulDistribMulAction α G
H : Subgroup G
h : G
hh : h ∈ H
this : {x | x ∈ H} = ↑H
⊢ ↑H * {h} = ↑H
state_after: no goals
Theorem: inv_mem_nhds_one
File: Mathlib/Topology/Algebra/Group/Basic.lean

tactic: rwa [← nhds_one_symm'] at hS
state_before: G : Type w
H : Type x
α : Type u
β : Type v
inst✝³ : TopologicalSpace G
inst✝² : Group G
inst✝¹ : TopologicalGroup G
inst✝ : TopologicalSpace α
f : α → G
s : Set α
x : α
S : Set G
hS : S ∈ 𝓝 1
⊢ S⁻¹ ∈ 𝓝 1
state_after: no goals
Theorem: minpoly.one
File: Mathlib/FieldTheory/Minpoly/Field.lean

tactic: simpa only [RingHom.map_one, C_1, sub_eq_add_neg] using eq_X_sub_C B (1 : A)
state_before: A : Type u_1
B : Type u_2
inst✝³ : Field A
inst✝² : Ring B
inst✝¹ : Algebra A B
x : B
inst✝ : Nontrivial B
⊢ minpoly A 1 = X - 1
state_after: no goals
Theorem: mem_sphere_iff_norm'
File: Mathlib/Analysis/Normed/Group/Basic.lean

tactic: simp [dist_eq_norm_div]
state_before: 𝓕 : Type u_1
𝕜 : Type u_2
α : Type u_3
ι : Type u_4
κ : Type u_5
E : Type u_6
F : Type u_7
G : Type u_8
inst✝² : SeminormedGroup E
inst✝¹ : SeminormedGroup F
inst✝ : SeminormedGroup G
s : Set E
a a₁ a₂ b b₁ b₂ : E
r r₁ r₂ : ℝ
⊢ b ∈ sphere a r ↔ ‖b / a‖ = r
state_after: no goals