tasksource/leandojo huggingface dataset:
Theorem: Lean.Data.AC.Context.sort_loop_nonEmpty
File: src/lean/Init/Data/AC.lean

tactic: induction ys generalizing xs with
| nil => simp [sort.loop]; assumption
| cons y _  ih => simp [sort.loop]; apply ih; apply insert_nonEmpty
state_before: ys xs : List Nat
h : xs ≠ []
⊢ sort.loop xs ys ≠ []

tactic: simp [sort.loop]
state_before: case nil
xs : List Nat
h : xs ≠ []
⊢ sort.loop xs [] ≠ []

tactic: assumption
state_before: case nil
xs : List Nat
h : xs ≠ []
⊢ ¬xs = []

tactic: simp [sort.loop]
state_before: case cons
y : Nat
tail✝ : List Nat
ih : ∀ (xs : List Nat), xs ≠ [] → sort.loop xs tail✝ ≠ []
xs : List Nat
h : xs ≠ []
⊢ sort.loop xs (y :: tail✝) ≠ []

tactic: apply ih
state_before: case cons
y : Nat
tail✝ : List Nat
ih : ∀ (xs : List Nat), xs ≠ [] → sort.loop xs tail✝ ≠ []
xs : List Nat
h : xs ≠ []
⊢ ¬sort.loop (insert y xs) tail✝ = []

tactic: apply insert_nonEmpty
state_before: case cons.h
y : Nat
tail✝ : List Nat
ih : ∀ (xs : List Nat), xs ≠ [] → sort.loop xs tail✝ ≠ []
xs : List Nat
h : xs ≠ []
⊢ insert y xs ≠ []
Theorem: ContinuousLinearEquiv.hasSum
File: Mathlib/Topology/Algebra/InfiniteSum/Module.lean

tactic: simpa only [e.symm.coe_coe, e.symm_apply_apply] using h.mapL (e.symm : M₂ →SL[σ'] M)
state_before: ι : Type u_5
R : Type u_1
R₂ : Type u_2
M : Type u_3
M₂ : Type u_4
inst✝⁹ : Semiring R
inst✝⁸ : Semiring R₂
inst✝⁷ : AddCommMonoid M
inst✝⁶ : Module R M
inst✝⁵ : AddCommMonoid M₂
inst✝⁴ : Module R₂ M₂
inst✝³ : TopologicalSpace M
inst✝² : TopologicalSpace M₂
σ : R →+* R₂
σ' : R₂ →+* R
inst✝¹ : RingHomInvPair σ σ'
inst✝ : RingHomInvPair σ' σ
f : ι → M
e : M ≃SL[σ] M₂
y : M₂
h : HasSum (fun b => ↑e (f b)) y
⊢ HasSum f (↑(ContinuousLinearEquiv.symm e) y)

tactic: simpa only [e.coe_coe, e.apply_symm_apply] using (e : M →SL[σ] M₂).hasSum h
state_before: ι : Type u_5
R : Type u_1
R₂ : Type u_2
M : Type u_3
M₂ : Type u_4
inst✝⁹ : Semiring R
inst✝⁸ : Semiring R₂
inst✝⁷ : AddCommMonoid M
inst✝⁶ : Module R M
inst✝⁵ : AddCommMonoid M₂
inst✝⁴ : Module R₂ M₂
inst✝³ : TopologicalSpace M
inst✝² : TopologicalSpace M₂
σ : R →+* R₂
σ' : R₂ →+* R
inst✝¹ : RingHomInvPair σ σ'
inst✝ : RingHomInvPair σ' σ
f : ι → M
e : M ≃SL[σ] M₂
y : M₂
h : HasSum f (↑(ContinuousLinearEquiv.symm e) y)
⊢ HasSum (fun b => ↑e (f b)) y
Theorem: id_compRel
File: Mathlib/Topology/UniformSpace/Basic.lean

tactic: simp
state_before: α : Type ua
β : Type ub
γ : Type uc
δ : Type ud
ι : Sort ?u.11388
r : Set (α × α)
x✝ : α × α
a b : α
⊢ (a, b) ∈ idRel ○ r ↔ (a, b) ∈ r
Theorem: Finset.offDiag_singleton
File: Mathlib/Data/Finset/Prod.lean

tactic: simp [← Finset.card_eq_zero]
state_before: α : Type u_1
β : Type ?u.127340
γ : Type ?u.127343
inst✝ : DecidableEq α
s t : Finset α
x : α × α
a : α
⊢ offDiag {a} = ∅
Theorem: tendsto_dist_left_cocompact_atTop
File: Mathlib/Topology/MetricSpace/Basic.lean

tactic: simpa only [dist_comm] using tendsto_dist_right_cocompact_atTop x
state_before: α : Type u
β : Type v
X : Type ?u.432936
ι : Type ?u.432939
inst✝¹ : PseudoMetricSpace α
inst✝ : ProperSpace α
x : α
⊢ Tendsto (dist x) (cocompact α) atTop
Theorem: Finset.image₂_singleton_inter
File: Mathlib/Data/Finset/NAry.lean

tactic: simp_rw [image₂_singleton_left, image_inter _ _ hf]
state_before: α : Type u_3
α' : Type ?u.52126
β : Type u_1
β' : Type ?u.52132
γ : Type u_2
γ' : Type ?u.52138
δ : Type ?u.52141
δ' : Type ?u.52144
ε : Type ?u.52147
ε' : Type ?u.52150
ζ : Type ?u.52153
ζ' : Type ?u.52156
ν : Type ?u.52159
inst✝⁸ : DecidableEq α'
inst✝⁷ : DecidableEq β'
inst✝⁶ : DecidableEq γ
inst✝⁵ : DecidableEq γ'
inst✝⁴ : DecidableEq δ
inst✝³ : DecidableEq δ'
inst✝² : DecidableEq ε
inst✝¹ : DecidableEq ε'
f f' : α → β → γ
g g' : α → β → γ → δ
s s' : Finset α
t t' : Finset β
u u' : Finset γ
a a' : α
b b' : β
c : γ
inst✝ : DecidableEq β
t₁ t₂ : Finset β
hf : Injective (f a)
⊢ image₂ f {a} (t₁ ∩ t₂) = image₂ f {a} t₁ ∩ image₂ f {a} t₂
Theorem: List.nthLe_cons_aux
File: Mathlib/Data/List/Basic.lean

tactic: contrapose! h
state_before: ι : Type ?u.46927
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ l : List α
a : α
n : ℕ
hn : n ≠ 0
h : n < length (a :: l)
⊢ n - 1 < length l

tactic: rw [length_cons]
state_before: ι : Type ?u.46927
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ l : List α
a : α
n : ℕ
hn : n ≠ 0
h : length l ≤ n - 1
⊢ length (a :: l) ≤ n

tactic: convert succ_le_succ h
state_before: ι : Type ?u.46927
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ l : List α
a : α
n : ℕ
hn : n ≠ 0
h : length l ≤ n - 1
⊢ succ (length l) ≤ n

tactic: exact (Nat.succ_pred_eq_of_pos hn.bot_lt).symm
state_before: case h.e'_4
ι : Type ?u.46927
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ l : List α
a : α
n : ℕ
hn : n ≠ 0
h : length l ≤ n - 1
⊢ n = succ (n - 1)
Theorem: split_by_characteristic_localRing
File: Mathlib/Algebra/CharP/MixedCharZero.lean

tactic: refine' split_by_characteristic R _ h_equal h_mixed
state_before: R : Type u_1
inst✝¹ : CommRing R
P : Prop
inst✝ : LocalRing R
h_pos : ∀ (p : ℕ), IsPrimePow p → CharP R p → P
h_equal : Algebra ℚ R → P
h_mixed : ∀ (p : ℕ), Nat.Prime p → MixedCharZero R p → P
⊢ P

tactic: intro p p_pos p_char
state_before: R : Type u_1
inst✝¹ : CommRing R
P : Prop
inst✝ : LocalRing R
h_pos : ∀ (p : ℕ), IsPrimePow p → CharP R p → P
h_equal : Algebra ℚ R → P
h_mixed : ∀ (p : ℕ), Nat.Prime p → MixedCharZero R p → P
⊢ ∀ (p : ℕ), p ≠ 0 → CharP R p → P

tactic: have p_ppow : IsPrimePow (p : ℕ) := or_iff_not_imp_left.mp (charP_zero_or_prime_power R p) p_pos
state_before: R : Type u_1
inst✝¹ : CommRing R
P : Prop
inst✝ : LocalRing R
h_pos : ∀ (p : ℕ), IsPrimePow p → CharP R p → P
h_equal : Algebra ℚ R → P
h_mixed : ∀ (p : ℕ), Nat.Prime p → MixedCharZero R p → P
p : ℕ
p_pos : p ≠ 0
p_char : CharP R p
⊢ P

tactic: exact h_pos p p_ppow p_char
state_before: R : Type u_1
inst✝¹ : CommRing R
P : Prop
inst✝ : LocalRing R
h_pos : ∀ (p : ℕ), IsPrimePow p → CharP R p → P
h_equal : Algebra ℚ R → P
h_mixed : ∀ (p : ℕ), Nat.Prime p → MixedCharZero R p → P
p : ℕ
p_pos : p ≠ 0
p_char : CharP R p
p_ppow : IsPrimePow p
⊢ P
Theorem: Polynomial.coe_eq_zero_iff
File: Mathlib/RingTheory/PowerSeries/Basic.lean

tactic: rw [← coe_zero, coe_inj]
state_before: σ : Type ?u.4374249
R : Type u_1
inst✝ : CommSemiring R
φ ψ : R[X]
⊢ ↑φ = 0 ↔ φ = 0
Theorem: mem_normalizedFactors_factor_orderIso_of_mem_normalizedFactors
File: Mathlib/RingTheory/ChainOfDivisors.lean

tactic: obtain ⟨q, hq, hq'⟩ :=
  exists_mem_normalizedFactors_of_dvd hn (map_prime_of_factor_orderIso hn hp d).irreducible
    (d ⟨p, dvd_of_mem_normalizedFactors hp⟩).prop
state_before: M : Type u_1
inst✝⁵ : CancelCommMonoidWithZero M
N : Type u_2
inst✝⁴ : CancelCommMonoidWithZero N
inst✝³ : UniqueFactorizationMonoid N
inst✝² : UniqueFactorizationMonoid M
inst✝¹ : DecidableEq (Associates M)
inst✝ : DecidableEq (Associates N)
m p : Associates M
n : Associates N
hn : n ≠ 0
hp : p ∈ normalizedFactors m
d : ↑(Set.Iic m) ≃o ↑(Set.Iic n)
⊢ ↑(↑d { val := p, property := (_ : p ∣ m) }) ∈ normalizedFactors n

tactic: rw [associated_iff_eq] at hq'
state_before: case intro.intro
M : Type u_1
inst✝⁵ : CancelCommMonoidWithZero M
N : Type u_2
inst✝⁴ : CancelCommMonoidWithZero N
inst✝³ : UniqueFactorizationMonoid N
inst✝² : UniqueFactorizationMonoid M
inst✝¹ : DecidableEq (Associates M)
inst✝ : DecidableEq (Associates N)
m p : Associates M
n : Associates N
hn : n ≠ 0
hp : p ∈ normalizedFactors m
d : ↑(Set.Iic m) ≃o ↑(Set.Iic n)
q : Associates N
hq : q ∈ normalizedFactors n
hq' : Associated (↑(↑d { val := p, property := (_ : p ∣ m) })) q
⊢ ↑(↑d { val := p, property := (_ : p ∣ m) }) ∈ normalizedFactors n

tactic: rwa [hq']
state_before: case intro.intro
M : Type u_1
inst✝⁵ : CancelCommMonoidWithZero M
N : Type u_2
inst✝⁴ : CancelCommMonoidWithZero N
inst✝³ : UniqueFactorizationMonoid N
inst✝² : UniqueFactorizationMonoid M
inst✝¹ : DecidableEq (Associates M)
inst✝ : DecidableEq (Associates N)
m p : Associates M
n : Associates N
hn : n ≠ 0
hp : p ∈ normalizedFactors m
d : ↑(Set.Iic m) ≃o ↑(Set.Iic n)
q : Associates N
hq : q ∈ normalizedFactors n
hq' : ↑(↑d { val := p, property := (_ : p ∣ m) }) = q
⊢ ↑(↑d { val := p, property := (_ : p ∣ m) }) ∈ normalizedFactors n
Theorem: Homeomorph.isCompact_preimage
File: Mathlib/Topology/Homeomorph.lean

tactic: rw [← image_symm]
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.61159
δ : Type ?u.61162
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
s : Set β
h : α ≃ₜ β
⊢ IsCompact (↑h ⁻¹' s) ↔ IsCompact s

tactic: exact h.symm.isCompact_image
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.61159
δ : Type ?u.61162
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
s : Set β
h : α ≃ₜ β
⊢ IsCompact (↑(Homeomorph.symm h) '' s) ↔ IsCompact s
Theorem: MeasureTheory.FiniteMeasure.apply_mono
File: Mathlib/MeasureTheory/Measure/FiniteMeasure.lean

tactic: change ((μ : Measure Ω) s₁).toNNReal ≤ ((μ : Measure Ω) s₂).toNNReal
state_before: Ω : Type u_1
inst✝ : MeasurableSpace Ω
μ : FiniteMeasure Ω
s₁ s₂ : Set Ω
h : s₁ ⊆ s₂
⊢ (fun s => ENNReal.toNNReal (↑↑↑μ s)) s₁ ≤ (fun s => ENNReal.toNNReal (↑↑↑μ s)) s₂

tactic: have key : (μ : Measure Ω) s₁ ≤ (μ : Measure Ω) s₂ := (μ : Measure Ω).mono h
state_before: Ω : Type u_1
inst✝ : MeasurableSpace Ω
μ : FiniteMeasure Ω
s₁ s₂ : Set Ω
h : s₁ ⊆ s₂
⊢ ENNReal.toNNReal (↑↑↑μ s₁) ≤ ENNReal.toNNReal (↑↑↑μ s₂)

tactic: apply (ENNReal.toNNReal_le_toNNReal (measure_ne_top _ s₁) (measure_ne_top _ s₂)).mpr key
state_before: Ω : Type u_1
inst✝ : MeasurableSpace Ω
μ : FiniteMeasure Ω
s₁ s₂ : Set Ω
h : s₁ ⊆ s₂
key : ↑↑↑μ s₁ ≤ ↑↑↑μ s₂
⊢ ENNReal.toNNReal (↑↑↑μ s₁) ≤ ENNReal.toNNReal (↑↑↑μ s₂)
Theorem: Nat.clog_of_right_le_one
File: Mathlib/Data/Nat/Log.lean

tactic: rw [clog, dif_neg fun h : 1 < b ∧ 1 < n => h.2.not_le hn]
state_before: n : ℕ
hn : n ≤ 1
b : ℕ
⊢ clog b n = 0
Theorem: Real.sinh_nonneg_iff
File: Mathlib/Analysis/SpecialFunctions/Trigonometric/Deriv.lean

tactic: simpa only [sinh_zero] using @sinh_le_sinh 0 x
state_before: x y z : ℝ
⊢ 0 ≤ sinh x ↔ 0 ≤ x
Theorem: Dvd.intro_left
File: Mathlib/Algebra/Divisibility/Basic.lean

tactic: rw [mul_comm] at h
state_before: α : Type u_1
inst✝ : CommSemigroup α
a b c✝ c : α
h : c * a = b
⊢ a * ?m.8324 c h = b

tactic: apply h
state_before: α : Type u_1
inst✝ : CommSemigroup α
a b c✝ c : α
h✝ : c * a = b
h : a * c = b
⊢ a * ?m.8324 c h✝ = b
Theorem: Polynomial.C_mul'
File: Mathlib/Data/Polynomial/Coeff.lean

tactic: ext
state_before: R : Type u
S : Type v
a✝ b : R
n m : ℕ
inst✝ : Semiring R
p q r : R[X]
a : R
f : R[X]
⊢ ↑C a * f = a • f

tactic: rw [coeff_C_mul, coeff_smul, smul_eq_mul]
state_before: case a
R : Type u
S : Type v
a✝ b : R
n m : ℕ
inst✝ : Semiring R
p q r : R[X]
a : R
f : R[X]
n✝ : ℕ
⊢ coeff (↑C a * f) n✝ = coeff (a • f) n✝
Theorem: arg_expMapCircle
File: Mathlib/Analysis/SpecialFunctions/Complex/Circle.lean

tactic: rw [expMapCircle_apply, exp_mul_I, arg_cos_add_sin_mul_I ⟨h₁, h₂⟩]
state_before: x : ℝ
h₁ : -π < x
h₂ : x ≤ π
⊢ arg ↑(↑expMapCircle x) = x
Theorem: Submodule.mem_span_insert'
File: Mathlib/LinearAlgebra/Span.lean

tactic: rw [mem_span_insert]
state_before: R : Type u_2
R₂ : Type ?u.280792
K : Type ?u.280795
M : Type u_1
M₂ : Type ?u.280801
V : Type ?u.280804
S : Type ?u.280807
inst✝² : Ring R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
x y : M
s : Set M
⊢ x ∈ span R (insert y s) ↔ ∃ a, x + a • y ∈ span R s

tactic: constructor
state_before: R : Type u_2
R₂ : Type ?u.280792
K : Type ?u.280795
M : Type u_1
M₂ : Type ?u.280801
V : Type ?u.280804
S : Type ?u.280807
inst✝² : Ring R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
x y : M
s : Set M
⊢ (∃ a z, z ∈ span R s ∧ x = a • y + z) ↔ ∃ a, x + a • y ∈ span R s

tactic: rintro ⟨a, z, hz, rfl⟩
state_before: case mp
R : Type u_2
R₂ : Type ?u.280792
K : Type ?u.280795
M : Type u_1
M₂ : Type ?u.280801
V : Type ?u.280804
S : Type ?u.280807
inst✝² : Ring R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
x y : M
s : Set M
⊢ (∃ a z, z ∈ span R s ∧ x = a • y + z) → ∃ a, x + a • y ∈ span R s

tactic: exact ⟨-a, by simp [hz, add_assoc]⟩
state_before: case mp.intro.intro.intro
R : Type u_2
R₂ : Type ?u.280792
K : Type ?u.280795
M : Type u_1
M₂ : Type ?u.280801
V : Type ?u.280804
S : Type ?u.280807
inst✝² : Ring R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
y : M
s : Set M
a : R
z : M
hz : z ∈ span R s
⊢ ∃ a_1, a • y + z + a_1 • y ∈ span R s

tactic: simp [hz, add_assoc]
state_before: R : Type u_2
R₂ : Type ?u.280792
K : Type ?u.280795
M : Type u_1
M₂ : Type ?u.280801
V : Type ?u.280804
S : Type ?u.280807
inst✝² : Ring R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
y : M
s : Set M
a : R
z : M
hz : z ∈ span R s
⊢ a • y + z + -a • y ∈ span R s

tactic: rintro ⟨a, h⟩
state_before: case mpr
R : Type u_2
R₂ : Type ?u.280792
K : Type ?u.280795
M : Type u_1
M₂ : Type ?u.280801
V : Type ?u.280804
S : Type ?u.280807
inst✝² : Ring R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
x y : M
s : Set M
⊢ (∃ a, x + a • y ∈ span R s) → ∃ a z, z ∈ span R s ∧ x = a • y + z

tactic: exact ⟨-a, _, h, by simp [add_comm, add_left_comm]⟩
state_before: case mpr.intro
R : Type u_2
R₂ : Type ?u.280792
K : Type ?u.280795
M : Type u_1
M₂ : Type ?u.280801
V : Type ?u.280804
S : Type ?u.280807
inst✝² : Ring R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
x y : M
s : Set M
a : R
h : x + a • y ∈ span R s
⊢ ∃ a z, z ∈ span R s ∧ x = a • y + z

tactic: simp [add_comm, add_left_comm]
state_before: R : Type u_2
R₂ : Type ?u.280792
K : Type ?u.280795
M : Type u_1
M₂ : Type ?u.280801
V : Type ?u.280804
S : Type ?u.280807
inst✝² : Ring R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
x y : M
s : Set M
a : R
h : x + a • y ∈ span R s
⊢ x = -a • y + (x + a • y)
Theorem: extract_gcd
File: Mathlib/Algebra/GCDMonoid/Basic.lean

tactic: by_cases h : gcd x y = 0
state_before: α✝ : Type ?u.200688
inst✝² : CancelCommMonoidWithZero α✝
α : Type u_1
inst✝¹ : CancelCommMonoidWithZero α
inst✝ : GCDMonoid α
x y : α
⊢ ∃ x' y', x = gcd x y * x' ∧ y = gcd x y * y' ∧ IsUnit (gcd x' y')

tactic: obtain ⟨x', ex⟩ := gcd_dvd_left x y
state_before: case neg
α✝ : Type ?u.200688
inst✝² : CancelCommMonoidWithZero α✝
α : Type u_1
inst✝¹ : CancelCommMonoidWithZero α
inst✝ : GCDMonoid α
x y : α
h : ¬gcd x y = 0
⊢ ∃ x' y', x = gcd x y * x' ∧ y = gcd x y * y' ∧ IsUnit (gcd x' y')

tactic: obtain ⟨y', ey⟩ := gcd_dvd_right x y
state_before: case neg.intro
α✝ : Type ?u.200688
inst✝² : CancelCommMonoidWithZero α✝
α : Type u_1
inst✝¹ : CancelCommMonoidWithZero α
inst✝ : GCDMonoid α
x y : α
h : ¬gcd x y = 0
x' : α
ex : x = gcd x y * x'
⊢ ∃ x' y', x = gcd x y * x' ∧ y = gcd x y * y' ∧ IsUnit (gcd x' y')

tactic: exact ⟨x', y', ex, ey, isUnit_gcd_of_eq_mul_gcd ex ey h⟩
state_before: case neg.intro.intro
α✝ : Type ?u.200688
inst✝² : CancelCommMonoidWithZero α✝
α : Type u_1
inst✝¹ : CancelCommMonoidWithZero α
inst✝ : GCDMonoid α
x y : α
h : ¬gcd x y = 0
x' : α
ex : x = gcd x y * x'
y' : α
ey : y = gcd x y * y'
⊢ ∃ x' y', x = gcd x y * x' ∧ y = gcd x y * y' ∧ IsUnit (gcd x' y')

tactic: obtain ⟨rfl, rfl⟩ := (gcd_eq_zero_iff x y).1 h
state_before: case pos
α✝ : Type ?u.200688
inst✝² : CancelCommMonoidWithZero α✝
α : Type u_1
inst✝¹ : CancelCommMonoidWithZero α
inst✝ : GCDMonoid α
x y : α
h : gcd x y = 0
⊢ ∃ x' y', x = gcd x y * x' ∧ y = gcd x y * y' ∧ IsUnit (gcd x' y')

tactic: simp_rw [← associated_one_iff_isUnit]
state_before: case pos.intro
α✝ : Type ?u.200688
inst✝² : CancelCommMonoidWithZero α✝
α : Type u_1
inst✝¹ : CancelCommMonoidWithZero α
inst✝ : GCDMonoid α
h : gcd 0 0 = 0
⊢ ∃ x' y', 0 = gcd 0 0 * x' ∧ 0 = gcd 0 0 * y' ∧ IsUnit (gcd x' y')

tactic: exact ⟨1, 1, by rw [h, zero_mul], by rw [h, zero_mul], gcd_one_left' 1⟩
state_before: case pos.intro
α✝ : Type ?u.200688
inst✝² : CancelCommMonoidWithZero α✝
α : Type u_1
inst✝¹ : CancelCommMonoidWithZero α
inst✝ : GCDMonoid α
h : gcd 0 0 = 0
⊢ ∃ x' y', 0 = gcd 0 0 * x' ∧ 0 = gcd 0 0 * y' ∧ Associated (gcd x' y') 1

tactic: rw [h, zero_mul]
state_before: α✝ : Type ?u.200688
inst✝² : CancelCommMonoidWithZero α✝
α : Type u_1
inst✝¹ : CancelCommMonoidWithZero α
inst✝ : GCDMonoid α
h : gcd 0 0 = 0
⊢ 0 = gcd 0 0 * 1

tactic: rw [h, zero_mul]
state_before: α✝ : Type ?u.200688
inst✝² : CancelCommMonoidWithZero α✝
α : Type u_1
inst✝¹ : CancelCommMonoidWithZero α
inst✝ : GCDMonoid α
h : gcd 0 0 = 0
⊢ 0 = gcd 0 0 * 1
Theorem: Real.Angle.toReal_coe_eq_self_iff
File: Mathlib/Analysis/SpecialFunctions/Trigonometric/Angle.lean

tactic: rw [toReal_coe, toIocMod_eq_self two_pi_pos]
state_before: θ : ℝ
⊢ toReal ↑θ = θ ↔ -π < θ ∧ θ ≤ π

tactic: ring_nf
state_before: θ : ℝ
⊢ θ ∈ Set.Ioc (-π) (-π + 2 * π) ↔ -π < θ ∧ θ ≤ π

tactic: rfl
state_before: θ : ℝ
⊢ θ ∈ Set.Ioc (-π) π ↔ -π < θ ∧ θ ≤ π
Theorem: unitInterval.symm_symm
File: Mathlib/Topology/UnitInterval.lean

tactic: simp [symm]
state_before: x : ↑I
⊢ ↑(σ (σ x)) = ↑x
Theorem: Int.eq_natAbs_iff_mul_eq_zero
File: Std/Data/Int/Lemmas.lean

tactic: rw [natAbs_eq_iff, Int.mul_eq_zero, ← Int.sub_neg, Int.sub_eq_zero, Int.sub_eq_zero]
state_before: a : Int
n : Nat
⊢ natAbs a = n ↔ (a - ↑n) * (a + ↑n) = 0
Theorem: LinearMap.cancel_left
File: Mathlib/Algebra/Module/LinearMap.lean

tactic: rw [← comp_apply, h, comp_apply]
state_before: R : Type ?u.248225
R₁ : Type u_6
R₂ : Type u_3
R₃ : Type u_4
k : Type ?u.248237
S : Type ?u.248240
S₃ : Type ?u.248243
T : Type ?u.248246
M : Type ?u.248249
M₁ : Type u_5
M₂ : Type u_1
M₃ : Type u_2
N₁ : Type ?u.248261
N₂ : Type ?u.248264
N₃ : Type ?u.248267
ι : Type ?u.248270
inst✝⁹ : Semiring R
inst✝⁸ : Semiring S
inst✝⁷ : Semiring R₁
inst✝⁶ : Semiring R₂
inst✝⁵ : Semiring R₃
inst✝⁴ : AddCommMonoid M
inst✝³ : AddCommMonoid M₁
inst✝² : AddCommMonoid M₂
inst✝¹ : AddCommMonoid M₃
module_M₁ : Module R₁ M₁
module_M₂ : Module R₂ M₂
module_M₃ : Module R₃ M₃
σ₁₂ : R₁ →+* R₂
σ₂₃ : R₂ →+* R₃
σ₁₃ : R₁ →+* R₃
inst✝ : RingHomCompTriple σ₁₂ σ₂₃ σ₁₃
f : M₂ →ₛₗ[σ₂₃] M₃
g : M₁ →ₛₗ[σ₁₂] M₂
f' : M₂ →ₛₗ[σ₂₃] M₃
g' : M₁ →ₛₗ[σ₁₂] M₂
hf : Injective ↑f
h : comp f g = comp f g'
x : M₁
⊢ ↑f (↑g x) = ↑f (↑g' x)
Theorem: CategoryTheory.Limits.HasCoequalizersOfHasPushoutsAndBinaryCoproducts.pushoutInl_eq_pushout_inr
File: Mathlib/CategoryTheory/Limits/Constructions/Equalizers.lean

tactic: convert (whisker_eq Limits.coprod.inl pushout.condition :
  (_ : F.obj _ ⟶  constructCoequalizer _) = _) <;> simp
state_before: C : Type u
inst✝³ : Category C
D : Type u'
inst✝² : Category D
G : C ⥤ D
inst✝¹ : HasBinaryCoproducts C
inst✝ : HasPushouts C
F : WalkingParallelPair ⥤ C
⊢ pushoutInl F = pushout.inr
Theorem: BoxIntegral.Prepartition.splitMany_insert
File: Mathlib/Analysis/BoxIntegral/Partition/Split.lean

tactic: rw [splitMany, Finset.inf_insert, inf_comm, splitMany]
state_before: ι : Type u_1
M : Type ?u.43250
n : ℕ
I✝ J : Box ι
i : ι
x : ℝ
I : Box ι
s : Finset (ι × ℝ)
p : ι × ℝ
⊢ splitMany I (insert p s) = splitMany I s ⊓ split I p.fst p.snd
Theorem: Fintype.card_lt_of_injective_of_not_mem
File: Mathlib/Data/Fintype/Card.lean

tactic: rwa [← mem_coe, coe_map, coe_univ, Set.image_univ]
state_before: α : Type u_1
β : Type u_2
γ : Type ?u.15344
inst✝¹ : Fintype α
inst✝ : Fintype β
f : α → β
h : Injective f
b : β
w : ¬b ∈ Set.range f
⊢ ¬?m.15633 f h w ∈ map { toFun := f, inj' := h } univ
Theorem: Ideal.Filtration.Stable.bounded_difference
File: Mathlib/RingTheory/Filtration.lean

tactic: obtain ⟨n₁, h₁⟩ := h.exists_forall_le (le_of_eq e)
state_before: R M : Type u
inst✝² : CommRing R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
I : Ideal R
F F' : Filtration I M
h✝ h : Stable F
h' : Stable F'
e : N F 0 = N F' 0
⊢ ∃ n₀, ∀ (n : ℕ), N F (n + n₀) ≤ N F' n ∧ N F' (n + n₀) ≤ N F n

tactic: obtain ⟨n₂, h₂⟩ := h'.exists_forall_le (le_of_eq e.symm)
state_before: case intro
R M : Type u
inst✝² : CommRing R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
I : Ideal R
F F' : Filtration I M
h✝ h : Stable F
h' : Stable F'
e : N F 0 = N F' 0
n₁ : ℕ
h₁ : ∀ (n : ℕ), N F (n + n₁) ≤ N F' n
⊢ ∃ n₀, ∀ (n : ℕ), N F (n + n₀) ≤ N F' n ∧ N F' (n + n₀) ≤ N F n

tactic: use max n₁ n₂
state_before: case intro.intro
R M : Type u
inst✝² : CommRing R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
I : Ideal R
F F' : Filtration I M
h✝ h : Stable F
h' : Stable F'
e : N F 0 = N F' 0
n₁ : ℕ
h₁ : ∀ (n : ℕ), N F (n + n₁) ≤ N F' n
n₂ : ℕ
h₂ : ∀ (n : ℕ), N F' (n + n₂) ≤ N F n
⊢ ∃ n₀, ∀ (n : ℕ), N F (n + n₀) ≤ N F' n ∧ N F' (n + n₀) ≤ N F n

tactic: intro n
state_before: case intro.intro
R M : Type u
inst✝² : CommRing R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
I : Ideal R
F F' : Filtration I M
h✝ h : Stable F
h' : Stable F'
e : N F 0 = N F' 0
n₁ : ℕ
h₁ : ∀ (n : ℕ), N F (n + n₁) ≤ N F' n
n₂ : ℕ
h₂ : ∀ (n : ℕ), N F' (n + n₂) ≤ N F n
⊢ ∀ (n : ℕ), N F (n + max n₁ n₂) ≤ N F' n ∧ N F' (n + max n₁ n₂) ≤ N F n

tactic: refine' ⟨(F.antitone _).trans (h₁ n), (F'.antitone _).trans (h₂ n)⟩ <;> simp
state_before: case intro.intro
R M : Type u
inst✝² : CommRing R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
I : Ideal R
F F' : Filtration I M
h✝ h : Stable F
h' : Stable F'
e : N F 0 = N F' 0
n₁ : ℕ
h₁ : ∀ (n : ℕ), N F (n + n₁) ≤ N F' n
n₂ : ℕ
h₂ : ∀ (n : ℕ), N F' (n + n₂) ≤ N F n
n : ℕ
⊢ N F (n + max n₁ n₂) ≤ N F' n ∧ N F' (n + max n₁ n₂) ≤ N F n
Theorem: CategoryTheory.Limits.biproduct.isoProduct_inv
File: Mathlib/CategoryTheory/Limits/Shapes/Biproducts.lean

tactic: simp [Iso.inv_comp_eq]
state_before: J : Type w
C : Type u
inst✝² : Category C
inst✝¹ : HasZeroMorphisms C
f : J → C
inst✝ : HasBiproduct f
j : J
⊢ (isoProduct f).inv ≫ π f j = lift (Pi.π f) ≫ π f j
Theorem: Submonoid.mem_sup
File: Mathlib/GroupTheory/Submonoid/Membership.lean

tactic: simp only [ge_iff_le, sup_eq_range, mem_mrange, coprod_apply, coe_subtype, Prod.exists,
  Subtype.exists, exists_prop]
state_before: M : Type ?u.246783
A : Type ?u.246786
B : Type ?u.246789
N : Type u_1
inst✝ : CommMonoid N
s t : Submonoid N
x : N
⊢ x ∈ s ⊔ t ↔ ∃ y, y ∈ s ∧ ∃ z, z ∈ t ∧ y * z = x
Theorem: pochhammer_succ_left
File: Mathlib/RingTheory/Polynomial/Pochhammer.lean

tactic: rw [pochhammer]
state_before: S : Type u
inst✝ : Semiring S
n : ℕ
⊢ pochhammer S (n + 1) = X * comp (pochhammer S n) (X + 1)
Theorem: Vector.scanl_cons
File: Mathlib/Data/Vector/Basic.lean

tactic: simp only [scanl, toList_cons, List.scanl]
state_before: n : ℕ
α : Type u_2
β : Type u_1
f : β → α → β
b : β
v : Vector α n
x : α
⊢ scanl f b (x ::ᵥ v) = b ::ᵥ scanl f (f b x) v

tactic: dsimp
state_before: n : ℕ
α : Type u_2
β : Type u_1
f : β → α → β
b : β
v : Vector α n
x : α
⊢ { val := b :: List.scanl f (f b x) ↑v,
      property := (_ : (fun l => List.length l = Nat.succ n + 1) (b :: List.scanl f (f b x) ↑v)) } =
    b ::ᵥ
      { val := List.scanl f (f b x) (toList v),
        property := (_ : List.length (List.scanl f (f b x) (toList v)) = n + 1) }

tactic: simp only [cons]
state_before: n : ℕ
α : Type u_2
β : Type u_1
f : β → α → β
b : β
v : Vector α n
x : α
⊢ { val := b :: List.scanl f (f b x) ↑v,
      property := (_ : List.length (List.scanl f b (toList (x ::ᵥ v))) = Nat.succ n + 1) } =
    b ::ᵥ
      { val := List.scanl f (f b x) (toList v),
        property := (_ : List.length (List.scanl f (f b x) (toList v)) = n + 1) }

tactic: rfl
state_before: n : ℕ
α : Type u_2
β : Type u_1
f : β → α → β
b : β
v : Vector α n
x : α
⊢ { val := b :: List.scanl f (f b x) ↑v,
      property := (_ : List.length (List.scanl f b (toList (x ::ᵥ v))) = Nat.succ n + 1) } =
    { val := b :: List.scanl f (f b x) (toList v),
      property := (_ : Nat.succ (List.length (List.scanl f (f b x) (toList v))) = Nat.succ (n + 1)) }
Theorem: CategoryTheory.Limits.pullbackDiagonalMapIdIso_inv_snd_fst
File: Mathlib/CategoryTheory/Limits/Shapes/Diagonal.lean

tactic: rw [Iso.inv_comp_eq]
state_before: C : Type u_2
inst✝⁵ : Category C
X Y Z : C
inst✝⁴ : HasPullbacks C
S T : C
f : X ⟶ T
g : Y ⟶ T
i : T ⟶ S
inst✝³ : HasPullback i i
inst✝² : HasPullback f g
inst✝¹ : HasPullback (f ≫ i) (g ≫ i)
inst✝ :
  HasPullback (diagonal i) (map (f ≫ i) (g ≫ i) i i f g (𝟙 S) (_ : (f ≫ i) ≫ 𝟙 S = f ≫ i) (_ : (g ≫ i) ≫ 𝟙 S = g ≫ i))
⊢ (pullbackDiagonalMapIdIso f g i).inv ≫ snd ≫ fst = fst

tactic: simp
state_before: C : Type u_2
inst✝⁵ : Category C
X Y Z : C
inst✝⁴ : HasPullbacks C
S T : C
f : X ⟶ T
g : Y ⟶ T
i : T ⟶ S
inst✝³ : HasPullback i i
inst✝² : HasPullback f g
inst✝¹ : HasPullback (f ≫ i) (g ≫ i)
inst✝ :
  HasPullback (diagonal i) (map (f ≫ i) (g ≫ i) i i f g (𝟙 S) (_ : (f ≫ i) ≫ 𝟙 S = f ≫ i) (_ : (g ≫ i) ≫ 𝟙 S = g ≫ i))
⊢ snd ≫ fst = (pullbackDiagonalMapIdIso f g i).hom ≫ fst