tasksource/leandojo huggingface dataset:
Theorem: Nat.disjoint_divisors_filter_isPrimePow
File: Mathlib/Algebra/IsPrimePow.lean

tactic: simp only [Finset.disjoint_left, Finset.mem_filter, and_imp, Nat.mem_divisors, not_and]
state_before: R : Type ?u.84416
inst✝ : CommMonoidWithZero R
n p : R
k a b : ℕ
hab : coprime a b
⊢ Disjoint (Finset.filter IsPrimePow (divisors a)) (Finset.filter IsPrimePow (divisors b))

tactic: rintro n han _ha hn hbn _hb -
state_before: R : Type ?u.84416
inst✝ : CommMonoidWithZero R
n p : R
k a b : ℕ
hab : coprime a b
⊢ ∀ ⦃a_1 : ℕ⦄, a_1 ∣ a → a ≠ 0 → IsPrimePow a_1 → a_1 ∣ b → b ≠ 0 → ¬IsPrimePow a_1

tactic: exact hn.ne_one (Nat.eq_one_of_dvd_coprimes hab han hbn)
state_before: R : Type ?u.84416
inst✝ : CommMonoidWithZero R
n✝ p : R
k a b : ℕ
hab : coprime a b
n : ℕ
han : n ∣ a
_ha : a ≠ 0
hn : IsPrimePow n
hbn : n ∣ b
_hb : b ≠ 0
⊢ False
Theorem: Submonoid.LocalizationMap.mk'_eq_iff_eq
File: Mathlib/GroupTheory/MonoidLocalization.lean

tactic: rw [f.toMap.map_mul, f.toMap.map_mul, f.mk'_eq_iff_eq_mul.1 H,← mul_assoc, mk'_spec',
  mul_comm ((toMap f) x₂) _]
state_before: M : Type u_1
inst✝² : CommMonoid M
S : Submonoid M
N : Type u_2
inst✝¹ : CommMonoid N
P : Type ?u.817224
inst✝ : CommMonoid P
f : LocalizationMap S N
x₁ x₂ : M
y₁ y₂ : { x // x ∈ S }
H : mk' f x₁ y₁ = mk' f x₂ y₂
⊢ ↑(toMap f) (↑y₂ * x₁) = ↑(toMap f) (↑y₁ * x₂)

tactic: rw [mk'_eq_iff_eq_mul, mk', mul_assoc, mul_comm _ (f.toMap y₁), ← mul_assoc, ←
  f.toMap.map_mul, mul_comm x₂, ← H, ← mul_comm x₁, f.toMap.map_mul,
  mul_inv_right f.map_units]
state_before: M : Type u_1
inst✝² : CommMonoid M
S : Submonoid M
N : Type u_2
inst✝¹ : CommMonoid N
P : Type ?u.817224
inst✝ : CommMonoid P
f : LocalizationMap S N
x₁ x₂ : M
y₁ y₂ : { x // x ∈ S }
H : ↑(toMap f) (↑y₂ * x₁) = ↑(toMap f) (↑y₁ * x₂)
⊢ mk' f x₁ y₁ = mk' f x₂ y₂
Theorem: NNReal.rpow_two
File: Mathlib/Analysis/SpecialFunctions/Pow/NNReal.lean

tactic: rw [← rpow_nat_cast]
state_before: x : ℝ≥0
⊢ x ^ 2 = x ^ 2

tactic: simp only [Nat.cast_ofNat]
state_before: x : ℝ≥0
⊢ x ^ 2 = x ^ ↑2
Theorem: integral_log
File: Mathlib/Analysis/SpecialFunctions/Integrals.lean

tactic: have h' := fun x (hx : x ∈ [[a, b]]) => ne_of_mem_of_not_mem hx h
state_before: a b : ℝ
n : ℕ
h : ¬0 ∈ [[a, b]]
⊢ (∫ (x : ℝ) in a..b, Real.log x) = b * Real.log b - a * Real.log a - b + a

tactic: have heq := fun x hx => mul_inv_cancel (h' x hx)
state_before: a b : ℝ
n : ℕ
h : ¬0 ∈ [[a, b]]
h' : ∀ (x : ℝ), x ∈ [[a, b]] → x ≠ 0
⊢ (∫ (x : ℝ) in a..b, Real.log x) = b * Real.log b - a * Real.log a - b + a

tactic: convert integral_mul_deriv_eq_deriv_mul (fun x hx => hasDerivAt_log (h' x hx))
  (fun x _ => hasDerivAt_id x) (continuousOn_inv₀.mono <|
    subset_compl_singleton_iff.mpr h).intervalIntegrable
      continuousOn_const.intervalIntegrable using 1 <;>
simp [integral_congr heq, mul_comm, ← sub_add]
state_before: a b : ℝ
n : ℕ
h : ¬0 ∈ [[a, b]]
h' : ∀ (x : ℝ), x ∈ [[a, b]] → x ≠ 0
heq : ∀ (x : ℝ), x ∈ [[a, b]] → x * x⁻¹ = 1
⊢ (∫ (x : ℝ) in a..b, Real.log x) = b * Real.log b - a * Real.log a - b + a
Theorem: Finset.preimage_inv
File: Mathlib/Data/Finset/Pointwise.lean

tactic: rw [coe_preimage, Set.inv_preimage, coe_inv]
state_before: F : Type ?u.40275
α : Type u_1
β : Type ?u.40281
γ : Type ?u.40284
inst✝¹ : DecidableEq α
inst✝ : InvolutiveInv α
s : Finset α
⊢ ↑(preimage s Inv.inv (_ : Set.InjOn Inv.inv (Inv.inv ⁻¹' ↑s))) = ↑s⁻¹
Theorem: norm_sub_mul_self_real
File: Mathlib/Analysis/InnerProductSpace/Basic.lean

tactic: have h := @norm_sub_mul_self ℝ _ _ _ _ x y
state_before: 𝕜 : Type ?u.2475426
E : Type ?u.2475429
F : Type u_1
inst✝⁴ : IsROrC 𝕜
inst✝³ : NormedAddCommGroup E
inst✝² : InnerProductSpace 𝕜 E
inst✝¹ : NormedAddCommGroup F
inst✝ : InnerProductSpace ℝ F
dec_E : DecidableEq E
x y : F
⊢ ‖x - y‖ * ‖x - y‖ = ‖x‖ * ‖x‖ - 2 * inner x y + ‖y‖ * ‖y‖

tactic: simpa using h
state_before: 𝕜 : Type ?u.2475426
E : Type ?u.2475429
F : Type u_1
inst✝⁴ : IsROrC 𝕜
inst✝³ : NormedAddCommGroup E
inst✝² : InnerProductSpace 𝕜 E
inst✝¹ : NormedAddCommGroup F
inst✝ : InnerProductSpace ℝ F
dec_E : DecidableEq E
x y : F
h : ‖x - y‖ * ‖x - y‖ = ‖x‖ * ‖x‖ - 2 * ↑re (inner x y) + ‖y‖ * ‖y‖
⊢ ‖x - y‖ * ‖x - y‖ = ‖x‖ * ‖x‖ - 2 * inner x y + ‖y‖ * ‖y‖
Theorem: Int.eq_zero_of_div_eq_zero
File: Std/Data/Int/DivMod.lean

tactic: rw [← Int.mul_div_cancel' h, H, Int.mul_zero]
state_before: d n : Int
h : d ∣ n
H : div n d = 0
⊢ n = 0
Theorem: IsOpen.ite
File: Mathlib/Topology/ContinuousOn.lean

tactic: simpa [hx] using ext_iff.1 ht x
state_before: α : Type u_1
β : Type ?u.397946
γ : Type ?u.397949
δ : Type ?u.397952
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
s s' t : Set α
hs : IsOpen s
hs' : IsOpen s'
ht : s ∩ frontier t = s' ∩ frontier t
x : α
hx : x ∈ frontier t
⊢ x ∈ s ↔ x ∈ s'
Theorem: Real.Angle.two_nsmul_coe_div_two
File: Mathlib/Analysis/SpecialFunctions/Trigonometric/Angle.lean

tactic: rw [← coe_nsmul, two_nsmul, add_halves]
state_before: θ : ℝ
⊢ 2 • ↑(θ / 2) = ↑θ
Theorem: List.Ico.filter_le
File: Mathlib/Data/List/Intervals.lean

tactic: cases' le_total n l with hnl hln
state_before: n m l : ℕ
⊢ filter (fun x => decide (l ≤ x)) (Ico n m) = Ico (max n l) m

tactic: rw [max_eq_right hnl, filter_le_of_le hnl]
state_before: case inl
n m l : ℕ
hnl : n ≤ l
⊢ filter (fun x => decide (l ≤ x)) (Ico n m) = Ico (max n l) m

tactic: rw [max_eq_left hln, filter_le_of_le_bot hln]
state_before: case inr
n m l : ℕ
hln : l ≤ n
⊢ filter (fun x => decide (l ≤ x)) (Ico n m) = Ico (max n l) m
Theorem: Prod.fst_natCast
File: Mathlib/Data/Nat/Cast/Prod.lean

tactic: induction n <;> simp [*]
state_before: α : Type u_1
β : Type u_2
inst✝¹ : AddMonoidWithOne α
inst✝ : AddMonoidWithOne β
n : ℕ
⊢ (↑n).fst = ↑n
Theorem: tsum_div_const
File: Mathlib/Topology/Algebra/InfiniteSum/Ring.lean

tactic: simpa only [div_eq_mul_inv] using tsum_mul_right
state_before: ι : Type u_2
κ : Type ?u.21514
R : Type ?u.21517
α : Type u_1
inst✝³ : DivisionSemiring α
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSemiring α
f g : ι → α
a a₁ a₂ : α
inst✝ : T2Space α
⊢ (∑' (x : ι), f x / a) = (∑' (x : ι), f x) / a
Theorem: MeasurableSpace.iUnion_mem_generateMeasurableRec
File: Mathlib/MeasureTheory/CardMeasurableSpace.lean

tactic: unfold generateMeasurableRec
state_before: α : Type u
s : Set (Set α)
i : (Quotient.out (ord (aleph 1))).α
f : ℕ → Set α
hf : ∀ (n : ℕ), ∃ j, j < i ∧ f n ∈ generateMeasurableRec s j
⊢ (⋃ (n : ℕ), f n) ∈ generateMeasurableRec s i

tactic: exact mem_union_right _ ⟨fun n => ⟨f n, let ⟨j, hj, hf⟩ := hf n; mem_iUnion.2 ⟨⟨j, hj⟩, hf⟩⟩, rfl⟩
state_before: α : Type u
s : Set (Set α)
i : (Quotient.out (ord (aleph 1))).α
f : ℕ → Set α
hf : ∀ (n : ℕ), ∃ j, j < i ∧ f n ∈ generateMeasurableRec s j
⊢ (⋃ (n : ℕ), f n) ∈
    let i := i;
    let S := ⋃ (j : ↑(Iio i)), generateMeasurableRec s ↑j;
    s ∪ {∅} ∪ compl '' S ∪ range fun f => ⋃ (n : ℕ), ↑(f n)
Theorem: Multiset.filterMap_eq_filter
File: Mathlib/Data/Multiset/Basic.lean

tactic: rw [← List.filterMap_eq_filter]
state_before: α : Type u_1
β : Type ?u.277023
γ : Type ?u.277026
p : α → Prop
inst✝ : DecidablePred p
s : Multiset α
l : List α
⊢ List.filterMap (Option.guard p) l = List.filter (fun b => decide (p b)) l

tactic: congr
state_before: α : Type u_1
β : Type ?u.277023
γ : Type ?u.277026
p : α → Prop
inst✝ : DecidablePred p
s : Multiset α
l : List α
⊢ List.filterMap (Option.guard p) l = List.filterMap (Option.guard fun x => decide (p x) = true) l

tactic: funext a
state_before: case e_f
α : Type u_1
β : Type ?u.277023
γ : Type ?u.277026
p : α → Prop
inst✝ : DecidablePred p
s : Multiset α
l : List α
⊢ Option.guard p = Option.guard fun x => decide (p x) = true

tactic: simp
state_before: case e_f.h
α : Type u_1
β : Type ?u.277023
γ : Type ?u.277026
p : α → Prop
inst✝ : DecidablePred p
s : Multiset α
l : List α
a : α
⊢ Option.guard p a = Option.guard (fun x => decide (p x) = true) a
Theorem: Finsupp.single_apply_eq_zero
File: Mathlib/Data/Finsupp/Defs.lean

tactic: simp [single_eq_set_indicator]
state_before: α : Type u_2
β : Type ?u.49894
γ : Type ?u.49897
ι : Type ?u.49900
M : Type u_1
M' : Type ?u.49906
N : Type ?u.49909
P : Type ?u.49912
G : Type ?u.49915
H : Type ?u.49918
R : Type ?u.49921
S : Type ?u.49924
inst✝ : Zero M
a✝ a' : α
b✝ : M
a x : α
b : M
⊢ ↑(single a b) x = 0 ↔ x = a → b = 0
Theorem: Multiset.count_nsmul
File: Mathlib/Data/Multiset/Basic.lean

tactic: induction n <;> simp [*, succ_nsmul', succ_mul, zero_nsmul]
state_before: α : Type u_1
β : Type ?u.355480
γ : Type ?u.355483
inst✝ : DecidableEq α
a : α
n : ℕ
s : Multiset α
⊢ count a (n • s) = n * count a s
Theorem: Std.RBNode.Balanced.insert
File: Std/Data/RBMap/WF.lean

tactic: unfold insert
state_before: α : Type u_1
c : RBColor
n : Nat
cmp : α → α → Ordering
v : α
t : RBNode α
h : Balanced t c n
⊢ ∃ c' n', Balanced (RBNode.insert cmp t v) c' n'

tactic: match ins cmp v t, h.ins cmp v with
| _, .balanced h => split <;> [exact ⟨_, h.setBlack⟩; exact ⟨_, _, h⟩]
| _, .redred _ ha hb => have .node red .. := t; exact ⟨_, _, .black ha hb⟩
state_before: α : Type u_1
c : RBColor
n : Nat
cmp : α → α → Ordering
v : α
t : RBNode α
h : Balanced t c n
⊢ ∃ c' n',
    Balanced
      (match isRed t with
      | red => setBlack (ins cmp v t)
      | black => ins cmp v t)
      c' n'

tactic: split <;> [exact ⟨_, h.setBlack⟩; exact ⟨_, _, h⟩]
state_before: α : Type u_1
c : RBColor
n : Nat
cmp : α → α → Ordering
v : α
t : RBNode α
h✝ : Balanced t c n
x✝ : RBNode α
c✝ : RBColor
h : Balanced x✝ c✝ n
⊢ ∃ c' n',
    Balanced
      (match isRed t with
      | red => setBlack x✝
      | black => x✝)
      c' n'

tactic: have .node red .. := t
state_before: α : Type u_1
c : RBColor
n : Nat
cmp : α → α → Ordering
v : α
t : RBNode α
h : Balanced t c n
a✝¹ : RBNode α
c₁✝ : RBColor
b✝ : RBNode α
c₂✝ : RBColor
x✝ : α
a✝ : isRed t = red
ha : Balanced a✝¹ c₁✝ n
hb : Balanced b✝ c₂✝ n
⊢ ∃ c' n',
    Balanced
      (match isRed t with
      | red => setBlack (node red a✝¹ x✝ b✝)
      | black => node red a✝¹ x✝ b✝)
      c' n'

tactic: exact ⟨_, _, .black ha hb⟩
state_before: α : Type u_1
c : RBColor
n : Nat
cmp : α → α → Ordering
v : α
t a✝¹ : RBNode α
c₁✝ : RBColor
b✝ : RBNode α
c₂✝ : RBColor
x✝ : α
ha : Balanced a✝¹ c₁✝ n
hb : Balanced b✝ c₂✝ n
l✝ : RBNode α
v✝ : α
r✝ : RBNode α
h : Balanced (node red l✝ v✝ r✝) c n
a✝ : isRed (node red l✝ v✝ r✝) = red
⊢ ∃ c' n',
    Balanced
      (match isRed (node red l✝ v✝ r✝) with
      | red => setBlack (node red a✝¹ x✝ b✝)
      | black => node red a✝¹ x✝ b✝)
      c' n'
Theorem: prod_induced_induced
File: Mathlib/Topology/Constructions.lean

tactic: delta instTopologicalSpaceProd
state_before: α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type ?u.49234
ζ : Type ?u.49237
inst✝⁵ : TopologicalSpace α
inst✝⁴ : TopologicalSpace β
inst✝³ : TopologicalSpace γ
inst✝² : TopologicalSpace δ
inst✝¹ : TopologicalSpace ε
inst✝ : TopologicalSpace ζ
f : α → β
g : γ → δ
⊢ instTopologicalSpaceProd = induced (fun p => (f p.fst, g p.snd)) instTopologicalSpaceProd

tactic: simp_rw [induced_inf, induced_compose]
state_before: α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type ?u.49234
ζ : Type ?u.49237
inst✝⁵ : TopologicalSpace α
inst✝⁴ : TopologicalSpace β
inst✝³ : TopologicalSpace γ
inst✝² : TopologicalSpace δ
inst✝¹ : TopologicalSpace ε
inst✝ : TopologicalSpace ζ
f : α → β
g : γ → δ
⊢ induced Prod.fst (induced f inst✝⁴) ⊓ induced Prod.snd (induced g inst✝²) =
    induced (fun p => (f p.fst, g p.snd)) (induced Prod.fst inst✝⁴ ⊓ induced Prod.snd inst✝²)

tactic: rfl
state_before: α : Type u
β : Type v
γ : Type u_1
δ : Type u_2
ε : Type ?u.49234
ζ : Type ?u.49237
inst✝⁵ : TopologicalSpace α
inst✝⁴ : TopologicalSpace β
inst✝³ : TopologicalSpace γ
inst✝² : TopologicalSpace δ
inst✝¹ : TopologicalSpace ε
inst✝ : TopologicalSpace ζ
f : α → β
g : γ → δ
⊢ induced (f ∘ Prod.fst) inst✝⁴ ⊓ induced (g ∘ Prod.snd) inst✝² =
    induced (Prod.fst ∘ fun p => (f p.fst, g p.snd)) inst✝⁴ ⊓ induced (Prod.snd ∘ fun p => (f p.fst, g p.snd)) inst✝²
Theorem: countable_cover_nhds_of_sigma_compact
File: Mathlib/Topology/SubsetProperties.lean

tactic: simp only [← nhdsWithin_univ] at hf
state_before: α : Type u
β : Type v
ι : Type ?u.165278
π : ι → Type ?u.165283
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
s t : Set α
inst✝ : SigmaCompactSpace α
f : α → Set α
hf : ∀ (x : α), f x ∈ 𝓝 x
⊢ ∃ s, Set.Countable s ∧ (⋃ (x : α) (_ : x ∈ s), f x) = univ

tactic: rcases countable_cover_nhdsWithin_of_sigma_compact isClosed_univ fun x _ => hf x with
  ⟨s, -, hsc, hsU⟩
state_before: α : Type u
β : Type v
ι : Type ?u.165278
π : ι → Type ?u.165283
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
s t : Set α
inst✝ : SigmaCompactSpace α
f : α → Set α
hf : ∀ (x : α), f x ∈ 𝓝[univ] x
⊢ ∃ s, Set.Countable s ∧ (⋃ (x : α) (_ : x ∈ s), f x) = univ

tactic: exact ⟨s, hsc, univ_subset_iff.1 hsU⟩
state_before: case intro.intro.intro
α : Type u
β : Type v
ι : Type ?u.165278
π : ι → Type ?u.165283
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
s✝ t : Set α
inst✝ : SigmaCompactSpace α
f : α → Set α
hf : ∀ (x : α), f x ∈ 𝓝[univ] x
s : Set α
hsc : Set.Countable s
hsU : univ ⊆ ⋃ (x : α) (_ : x ∈ s), f x
⊢ ∃ s, Set.Countable s ∧ (⋃ (x : α) (_ : x ∈ s), f x) = univ
Theorem: Ordinal.fp_iff_derivBFamily
File: Mathlib/SetTheory/Ordinal/FixedPoint.lean

tactic: rw [← le_iff_derivBFamily H]
state_before: o : Ordinal
f : (b : Ordinal) → b < o → Ordinal → Ordinal
H : ∀ (i : Ordinal) (hi : i < o), IsNormal (f i hi)
a : Ordinal
⊢ (∀ (i : Ordinal) (hi : i < o), f i hi a = a) ↔ ∃ b, derivBFamily o f b = a

tactic: refine' ⟨fun h i hi => le_of_eq (h i hi), fun h i hi => _⟩
state_before: o : Ordinal
f : (b : Ordinal) → b < o → Ordinal → Ordinal
H : ∀ (i : Ordinal) (hi : i < o), IsNormal (f i hi)
a : Ordinal
⊢ (∀ (i : Ordinal) (hi : i < o), f i hi a = a) ↔ ∀ (i : Ordinal) (hi : i < o), f i hi a ≤ a

tactic: rw [← (H i hi).le_iff_eq]
state_before: o : Ordinal
f : (b : Ordinal) → b < o → Ordinal → Ordinal
H : ∀ (i : Ordinal) (hi : i < o), IsNormal (f i hi)
a : Ordinal
h : ∀ (i : Ordinal) (hi : i < o), f i hi a ≤ a
i : Ordinal
hi : i < o
⊢ f i hi a = a

tactic: exact h i hi
state_before: o : Ordinal
f : (b : Ordinal) → b < o → Ordinal → Ordinal
H : ∀ (i : Ordinal) (hi : i < o), IsNormal (f i hi)
a : Ordinal
h : ∀ (i : Ordinal) (hi : i < o), f i hi a ≤ a
i : Ordinal
hi : i < o
⊢ f i hi a ≤ a
Theorem: MvPolynomial.C_eq_smul_one
File: Mathlib/Data/MvPolynomial/Basic.lean

tactic: rw [← C_mul', mul_one]
state_before: R : Type u
S₁ : Type v
S₂ : Type w
S₃ : Type x
σ : Type u_1
a a' a₁ a₂ : R
e : ℕ
n m : σ
s : σ →₀ ℕ
inst✝¹ : CommSemiring R
inst✝ : CommSemiring S₁
p q : MvPolynomial σ R
⊢ ↑C a = a • 1
Theorem: lt_or_le_of_mul_le_mul
File: Mathlib/Algebra/Order/Monoid/MinMax.lean

tactic: contrapose!
state_before: α : Type u_1
β : Type ?u.5366
inst✝³ : LinearOrder α
inst✝² : Mul α
inst✝¹ : CovariantClass α α (fun x x_1 => x * x_1) fun x x_1 => x < x_1
inst✝ : CovariantClass α α (swap fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a₁ a₂ b₁ b₂ : α
⊢ a₁ * b₁ ≤ a₂ * b₂ → a₁ < a₂ ∨ b₁ ≤ b₂

tactic: exact fun h => mul_lt_mul_of_le_of_lt h.1 h.2
state_before: α : Type u_1
β : Type ?u.5366
inst✝³ : LinearOrder α
inst✝² : Mul α
inst✝¹ : CovariantClass α α (fun x x_1 => x * x_1) fun x x_1 => x < x_1
inst✝ : CovariantClass α α (swap fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a₁ a₂ b₁ b₂ : α
⊢ a₂ ≤ a₁ ∧ b₂ < b₁ → a₂ * b₂ < a₁ * b₁
Theorem: zpow_le_of_le
File: Mathlib/Algebra/Order/Field/Power.lean

tactic: have ha₀ : 0 < a := one_pos.trans_le ha
state_before: α : Type u_1
inst✝ : LinearOrderedSemifield α
a b c d e : α
m n : ℤ
ha : 1 ≤ a
h : m ≤ n
⊢ a ^ m ≤ a ^ n

tactic: lift n - m to ℕ using sub_nonneg.2 h with k hk
state_before: α : Type u_1
inst✝ : LinearOrderedSemifield α
a b c d e : α
m n : ℤ
ha : 1 ≤ a
h : m ≤ n
ha₀ : 0 < a
⊢ a ^ m ≤ a ^ n

tactic: calc
  a ^ m = a ^ m * 1 := (mul_one _).symm
  _ ≤ a ^ m * a ^ k :=
    mul_le_mul_of_nonneg_left (one_le_pow_of_one_le ha _) (zpow_nonneg ha₀.le _)
  _ = a ^ n := by rw [← zpow_ofNat, ← zpow_add₀ ha₀.ne', hk, add_sub_cancel'_right]
state_before: case intro
α : Type u_1
inst✝ : LinearOrderedSemifield α
a b c d e : α
m n : ℤ
ha : 1 ≤ a
h : m ≤ n
ha₀ : 0 < a
k : ℕ
hk : ↑k = n - m
⊢ a ^ m ≤ a ^ n

tactic: rw [← zpow_ofNat, ← zpow_add₀ ha₀.ne', hk, add_sub_cancel'_right]
state_before: α : Type u_1
inst✝ : LinearOrderedSemifield α
a b c d e : α
m n : ℤ
ha : 1 ≤ a
h : m ≤ n
ha₀ : 0 < a
k : ℕ
hk : ↑k = n - m
⊢ a ^ m * a ^ k = a ^ n
Theorem: MonoidHom.transfer_def
File: Mathlib/GroupTheory/Transfer.lean

tactic: rw [transfer, ← diff_mul_diff, ← smul_diff_smul, mul_comm, diff_mul_diff] <;> rfl
state_before: G : Type u_1
inst✝² : Group G
H : Subgroup G
A : Type u_2
inst✝¹ : CommGroup A
ϕ : { x // x ∈ H } →* A
T : ↑(leftTransversals ↑H)
inst✝ : FiniteIndex H
g : G
⊢ ↑(transfer ϕ) g = diff ϕ T (g • T)
Theorem: Cardinal.cantorFunctionAux_succ
File: Mathlib/Data/Real/Cardinality.lean

tactic: ext n
state_before: c : ℝ
f✝ g : ℕ → Bool
n : ℕ
f : ℕ → Bool
⊢ (fun n => cantorFunctionAux c f (n + 1)) = fun n => c * cantorFunctionAux c (fun n => f (n + 1)) n

tactic: cases h : f (n + 1) <;> simp [h, _root_.pow_succ]
state_before: case h
c : ℝ
f✝ g : ℕ → Bool
n✝ : ℕ
f : ℕ → Bool
n : ℕ
⊢ cantorFunctionAux c f (n + 1) = c * cantorFunctionAux c (fun n => f (n + 1)) n
Theorem: Ordinal.lsub_le_of_range_subset
File: Mathlib/SetTheory/Ordinal/Arithmetic.lean

tactic: convert Set.image_subset succ h <;> apply Set.range_comp
state_before: α : Type ?u.328469
β : Type ?u.328472
γ : Type ?u.328475
r : α → α → Prop
s : β → β → Prop
t : γ → γ → Prop
ι : Type u
ι' : Type v
f : ι → Ordinal
g : ι' → Ordinal
h : range f ⊆ range g
⊢ range (succ ∘ f) ⊆ range (succ ∘ g)
Theorem: AffineSubspace.affineSpan_eq_top_iff_vectorSpan_eq_top_of_nontrivial
File: Mathlib/LinearAlgebra/AffineSpace/AffineSubspace.lean

tactic: cases' s.eq_empty_or_nonempty with hs hs
state_before: k : Type u_2
V : Type u_3
P : Type u_1
inst✝³ : Ring k
inst✝² : AddCommGroup V
inst✝¹ : Module k V
S : AffineSpace V P
p₁ p₂ : P
s : Set P
inst✝ : Nontrivial P
⊢ affineSpan k s = ⊤ ↔ vectorSpan k s = ⊤

tactic: simp [hs, subsingleton_iff_bot_eq_top, AddTorsor.subsingleton_iff V P, not_subsingleton]
state_before: case inl
k : Type u_2
V : Type u_3
P : Type u_1
inst✝³ : Ring k
inst✝² : AddCommGroup V
inst✝¹ : Module k V
S : AffineSpace V P
p₁ p₂ : P
s : Set P
inst✝ : Nontrivial P
hs : s = ∅
⊢ affineSpan k s = ⊤ ↔ vectorSpan k s = ⊤

tactic: rw [affineSpan_eq_top_iff_vectorSpan_eq_top_of_nonempty k V P hs]
state_before: case inr
k : Type u_2
V : Type u_3
P : Type u_1
inst✝³ : Ring k
inst✝² : AddCommGroup V
inst✝¹ : Module k V
S : AffineSpace V P
p₁ p₂ : P
s : Set P
inst✝ : Nontrivial P
hs : Set.Nonempty s
⊢ affineSpan k s = ⊤ ↔ vectorSpan k s = ⊤
Theorem: Nat.ArithmeticFunction.vonMangoldt_le_log
File: Mathlib/NumberTheory/VonMangoldt.lean

tactic: simp
state_before: ⊢ ↑Λ 0 ≤ Real.log ↑0

tactic: rw [← vonMangoldt_sum]
state_before: n : ℕ
⊢ ↑Λ (n + 1) ≤ Real.log ↑(n + 1)

tactic: exact single_le_sum (by exact fun _ _ => vonMangoldt_nonneg)
  (mem_divisors_self _ n.succ_ne_zero)
state_before: n : ℕ
⊢ ↑Λ (n + 1) ≤ ∑ i in divisors (n + 1), ↑Λ i

tactic: exact fun _ _ => vonMangoldt_nonneg
state_before: n : ℕ
⊢ ∀ (i : ℕ), i ∈ divisors (n + 1) → 0 ≤ ↑Λ i
Theorem: Seminorm.closedBall_eq_biInter_ball
File: Mathlib/Analysis/Seminorm.lean

tactic: ext y
state_before: R : Type ?u.824078
R' : Type ?u.824081
𝕜 : Type u_2
𝕜₂ : Type ?u.824087
𝕜₃ : Type ?u.824090
𝕝 : Type ?u.824093
E : Type u_1
E₂ : Type ?u.824099
E₃ : Type ?u.824102
F : Type ?u.824105
G : Type ?u.824108
ι : Type ?u.824111
inst✝² : SeminormedRing 𝕜
inst✝¹ : AddCommGroup E
inst✝ : SMul 𝕜 E
p : Seminorm 𝕜 E
x✝ y : E
r✝ : ℝ
x : E
r : ℝ
⊢ closedBall p x r = ⋂ (ρ : ℝ) (_ : ρ > r), ball p x ρ

tactic: simp_rw [mem_closedBall, mem_iInter₂, mem_ball, ← forall_lt_iff_le']
state_before: case h
R : Type ?u.824078
R' : Type ?u.824081
𝕜 : Type u_2
𝕜₂ : Type ?u.824087
𝕜₃ : Type ?u.824090
𝕝 : Type ?u.824093
E : Type u_1
E₂ : Type ?u.824099
E₃ : Type ?u.824102
F : Type ?u.824105
G : Type ?u.824108
ι : Type ?u.824111
inst✝² : SeminormedRing 𝕜
inst✝¹ : AddCommGroup E
inst✝ : SMul 𝕜 E
p : Seminorm 𝕜 E
x✝ y✝ : E
r✝ : ℝ
x : E
r : ℝ
y : E
⊢ y ∈ closedBall p x r ↔ y ∈ ⋂ (ρ : ℝ) (_ : ρ > r), ball p x ρ
Theorem: Function.Surjective.isLieAbelian
File: Mathlib/Algebra/Lie/Abelian.lean

tactic: obtain ⟨u, rfl⟩ := h₁ x
state_before: R : Type u
L₁ : Type v
L₂ : Type w
inst✝⁴ : CommRing R
inst✝³ : LieRing L₁
inst✝² : LieRing L₂
inst✝¹ : LieAlgebra R L₁
inst✝ : LieAlgebra R L₂
f : L₁ →ₗ⁅R⁆ L₂
h₁ : Surjective ↑f
h₂ : IsLieAbelian L₁
x y : L₂
⊢ ⁅x, y⁆ = 0

tactic: obtain ⟨v, rfl⟩ := h₁ y
state_before: case intro
R : Type u
L₁ : Type v
L₂ : Type w
inst✝⁴ : CommRing R
inst✝³ : LieRing L₁
inst✝² : LieRing L₂
inst✝¹ : LieAlgebra R L₁
inst✝ : LieAlgebra R L₂
f : L₁ →ₗ⁅R⁆ L₂
h₁ : Surjective ↑f
h₂ : IsLieAbelian L₁
y : L₂
u : L₁
⊢ ⁅↑f u, y⁆ = 0

tactic: rw [← LieHom.map_lie, trivial_lie_zero, LieHom.map_zero]
state_before: case intro.intro
R : Type u
L₁ : Type v
L₂ : Type w
inst✝⁴ : CommRing R
inst✝³ : LieRing L₁
inst✝² : LieRing L₂
inst✝¹ : LieAlgebra R L₁
inst✝ : LieAlgebra R L₂
f : L₁ →ₗ⁅R⁆ L₂
h₁ : Surjective ↑f
h₂ : IsLieAbelian L₁
u v : L₁
⊢ ⁅↑f u, ↑f v⁆ = 0
Theorem: TypeVec.repeat_eq_nil
File: Mathlib/Data/TypeVec.lean

tactic: ext i
state_before: n : ℕ
α : TypeVec 0
⊢ repeatEq α = nilFun

tactic: cases i
state_before: case a.h
n : ℕ
α : TypeVec 0
i : Fin2 0
x✝ : (α ⊗ α) i
⊢ repeatEq α i x✝ = nilFun i x✝
Theorem: IsPGroup.of_injective
File: Mathlib/GroupTheory/PGroup.lean

tactic: simp_rw [IsPGroup, ← hϕ.eq_iff, ϕ.map_pow, ϕ.map_one]
state_before: p : ℕ
G : Type u_2
inst✝¹ : Group G
hG : IsPGroup p G
H : Type u_1
inst✝ : Group H
ϕ : H →* G
hϕ : Function.Injective ↑ϕ
⊢ IsPGroup p H

tactic: exact fun h => hG (ϕ h)
state_before: p : ℕ
G : Type u_2
inst✝¹ : Group G
hG : IsPGroup p G
H : Type u_1
inst✝ : Group H
ϕ : H →* G
hϕ : Function.Injective ↑ϕ
⊢ ∀ (g : H), ∃ k, ↑ϕ g ^ p ^ k = 1
Theorem: AddLECancellable.tsub_tsub_assoc
File: Mathlib/Algebra/Order/Sub/Canonical.lean

tactic: rw [add_assoc, add_tsub_cancel_of_le h₂, tsub_add_cancel_of_le h₁]
state_before: α : Type u_1
inst✝⁵ : AddCommSemigroup α
inst✝⁴ : PartialOrder α
inst✝³ : ExistsAddOfLE α
inst✝² : CovariantClass α α (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
inst✝¹ : Sub α
inst✝ : OrderedSub α
a b c d : α
hbc : AddLECancellable (b - c)
h₁ : b ≤ a
h₂ : c ≤ b
⊢ a = a - b + c + (b - c)
Theorem: LinearMap.detAux_def'
File: Mathlib/LinearAlgebra/Determinant.lean

tactic: rw [detAux]
state_before: R : Type ?u.99440
inst✝⁹ : CommRing R
M : Type u_3
inst✝⁸ : AddCommGroup M
inst✝⁷ : Module R M
M' : Type ?u.100031
inst✝⁶ : AddCommGroup M'
inst✝⁵ : Module R M'
ι : Type u_1
inst✝⁴ : DecidableEq ι
inst✝³ : Fintype ι
e : Basis ι R M
A : Type u_2
inst✝² : CommRing A
inst✝¹ : Module A M
κ : Type ?u.101549
inst✝ : Fintype κ
b : Basis ι A M
f : M →ₗ[A] M
⊢ ↑(detAux (Trunc.mk b)) f = det (↑(toMatrix b b) f)

tactic: rfl
state_before: R : Type ?u.99440
inst✝⁹ : CommRing R
M : Type u_3
inst✝⁸ : AddCommGroup M
inst✝⁷ : Module R M
M' : Type ?u.100031
inst✝⁶ : AddCommGroup M'
inst✝⁵ : Module R M'
ι : Type u_1
inst✝⁴ : DecidableEq ι
inst✝³ : Fintype ι
e : Basis ι R M
A : Type u_2
inst✝² : CommRing A
inst✝¹ : Module A M
κ : Type ?u.101549
inst✝ : Fintype κ
b : Basis ι A M
f : M →ₗ[A] M
⊢ ↑(Trunc.lift (fun b => MonoidHom.comp detMonoidHom ↑(toMatrixAlgEquiv b))
          (_ :
            ∀ (b c : Basis ι A M),
              (fun b => MonoidHom.comp detMonoidHom ↑(toMatrixAlgEquiv b)) b =
                (fun b => MonoidHom.comp detMonoidHom ↑(toMatrixAlgEquiv b)) c)
          (Trunc.mk b))
      f =
    det (↑(toMatrix b b) f)
Theorem: Polynomial.Separable.squarefree
File: Mathlib/FieldTheory/Separable.lean

tactic: rw [multiplicity.squarefree_iff_multiplicity_le_one p]
state_before: R : Type u
inst✝¹ : CommSemiring R
S : Type v
inst✝ : CommSemiring S
p✝ q : ℕ
p : R[X]
hsep : Separable p
⊢ Squarefree p

tactic: exact fun f => or_iff_not_imp_right.mpr fun hunit => multiplicity_le_one_of_separable hunit hsep
state_before: R : Type u
inst✝¹ : CommSemiring R
S : Type v
inst✝ : CommSemiring S
p✝ q : ℕ
p : R[X]
hsep : Separable p
⊢ ∀ (x : R[X]), multiplicity x p ≤ 1 ∨ IsUnit x