tasksource/leandojo huggingface dataset:
Theorem: LinearEquiv.ofEq_rfl
File: Mathlib/LinearAlgebra/Basic.lean

tactic: ext
state_before: R : Type u_2
R₁ : Type ?u.1814068
R₂ : Type ?u.1814071
R₃ : Type ?u.1814074
R₄ : Type ?u.1814077
S : Type ?u.1814080
K : Type ?u.1814083
K₂ : Type ?u.1814086
M : Type u_1
M' : Type ?u.1814092
M₁ : Type ?u.1814095
M₂ : Type ?u.1814098
M₃ : Type ?u.1814101
M₄ : Type ?u.1814104
N : Type ?u.1814107
N₂ : Type ?u.1814110
ι : Type ?u.1814113
V : Type ?u.1814116
V₂ : Type ?u.1814119
inst✝⁸ : Semiring R
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₃
σ₁₃ : R →+* R₃
inst✝ : RingHomCompTriple σ₁₂ σ₂₃ σ₁₃
σ₃₂ : R₃ →+* R₂
re₁₂ : RingHomInvPair σ₁₂ σ₂₁
re₂₁ : RingHomInvPair σ₂₁ σ₁₂
re₂₃ : RingHomInvPair σ₂₃ σ₃₂
re₃₂ : RingHomInvPair σ₃₂ σ₂₃
f : M →ₛₗ[σ₁₂] M₂
g : M₂ →ₛₗ[σ₂₁] M
e : M ≃ₛₗ[σ₁₂] M₂
h : M₂ →ₛₗ[σ₂₃] M₃
e'' : M₂ ≃ₛₗ[σ₂₃] M₃
p q : Submodule R M
⊢ ofEq p p (_ : p = p) = refl R { x // x ∈ p }

tactic: rfl
state_before: case h.a
R : Type u_2
R₁ : Type ?u.1814068
R₂ : Type ?u.1814071
R₃ : Type ?u.1814074
R₄ : Type ?u.1814077
S : Type ?u.1814080
K : Type ?u.1814083
K₂ : Type ?u.1814086
M : Type u_1
M' : Type ?u.1814092
M₁ : Type ?u.1814095
M₂ : Type ?u.1814098
M₃ : Type ?u.1814101
M₄ : Type ?u.1814104
N : Type ?u.1814107
N₂ : Type ?u.1814110
ι : Type ?u.1814113
V : Type ?u.1814116
V₂ : Type ?u.1814119
inst✝⁸ : Semiring R
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₃
σ₁₃ : R →+* R₃
inst✝ : RingHomCompTriple σ₁₂ σ₂₃ σ₁₃
σ₃₂ : R₃ →+* R₂
re₁₂ : RingHomInvPair σ₁₂ σ₂₁
re₂₁ : RingHomInvPair σ₂₁ σ₁₂
re₂₃ : RingHomInvPair σ₂₃ σ₃₂
re₃₂ : RingHomInvPair σ₃₂ σ₂₃
f : M →ₛₗ[σ₁₂] M₂
g : M₂ →ₛₗ[σ₂₁] M
e : M ≃ₛₗ[σ₁₂] M₂
h : M₂ →ₛₗ[σ₂₃] M₃
e'' : M₂ ≃ₛₗ[σ₂₃] M₃
p q : Submodule R M
x✝ : { x // x ∈ p }
⊢ ↑(↑(ofEq p p (_ : p = p)) x✝) = ↑(↑(refl R { x // x ∈ p }) x✝)
Theorem: ofDual_compares_ofDual
File: Mathlib/Order/Compare.lean

tactic: cases o
state_before: α : Type u_1
β : Type ?u.11173
inst✝ : LT α
a b : αᵒᵈ
o : Ordering
⊢ Compares o (↑ofDual a) (↑ofDual b) ↔ Compares o b a

tactic: exacts [Iff.rfl, eq_comm, Iff.rfl]
state_before: case lt
α : Type u_1
β : Type ?u.11173
inst✝ : LT α
a b : αᵒᵈ
⊢ Compares lt (↑ofDual a) (↑ofDual b) ↔ Compares lt b a

case eq
α : Type u_1
β : Type ?u.11173
inst✝ : LT α
a b : αᵒᵈ
⊢ Compares eq (↑ofDual a) (↑ofDual b) ↔ Compares eq b a

case gt
α : Type u_1
β : Type ?u.11173
inst✝ : LT α
a b : αᵒᵈ
⊢ Compares gt (↑ofDual a) (↑ofDual b) ↔ Compares gt b a
Theorem: Bool.not_not_eq
File: Mathlib/Data/Bool/Basic.lean

tactic: decide
state_before: ⊢ ∀ {a b : Bool}, ¬(!a) = b ↔ a = b
Theorem: Real.Angle.cos_sq_add_sin_sq
File: Mathlib/Analysis/SpecialFunctions/Trigonometric/Angle.lean

tactic: induction θ using Real.Angle.induction_on
state_before: θ : Angle
⊢ cos θ ^ 2 + sin θ ^ 2 = 1

tactic: exact Real.cos_sq_add_sin_sq _
state_before: case h
x✝ : ℝ
⊢ cos ↑x✝ ^ 2 + sin ↑x✝ ^ 2 = 1
Theorem: Filter.nhds_pure
File: Mathlib/Topology/Filter.lean

tactic: rw [← principal_singleton, nhds_principal, principal_singleton, Iic_pure]
state_before: ι : Sort ?u.9264
α : Type u_1
β : Type ?u.9270
X : Type ?u.9273
Y : Type ?u.9276
x : α
⊢ 𝓝 (pure x) = 𝓟 {⊥, pure x}
Theorem: Real.contDiffAt_arccos_iff
File: Mathlib/Analysis/SpecialFunctions/Trigonometric/InverseDeriv.lean

tactic: refine' Iff.trans ⟨fun h => _, fun h => _⟩ contDiffAt_arcsin_iff <;>
  simpa [arccos] using (@contDiffAt_const _ _ _ _ _ _ _ _ _ _ (π / 2)).sub h
state_before: x : ℝ
n : ℕ∞
⊢ ContDiffAt ℝ n arccos x ↔ n = 0 ∨ x ≠ -1 ∧ x ≠ 1
Theorem: MvPolynomial.quotient_mk_comp_C_injective
File: Mathlib/FieldTheory/MvPolynomial.lean

tactic: refine' (injective_iff_map_eq_zero _).2 fun x hx => _
state_before: σ : Type u
K : Type v
inst✝ : Field K
I : Ideal (MvPolynomial σ K)
hI : I ≠ ⊤
⊢ Function.Injective ↑(RingHom.comp (Ideal.Quotient.mk I) C)

tactic: rw [RingHom.comp_apply, Ideal.Quotient.eq_zero_iff_mem] at hx
state_before: σ : Type u
K : Type v
inst✝ : Field K
I : Ideal (MvPolynomial σ K)
hI : I ≠ ⊤
x : K
hx : ↑(RingHom.comp (Ideal.Quotient.mk I) C) x = 0
⊢ x = 0

tactic: refine' _root_.by_contradiction fun hx0 => absurd (I.eq_top_iff_one.2 _) hI
state_before: σ : Type u
K : Type v
inst✝ : Field K
I : Ideal (MvPolynomial σ K)
hI : I ≠ ⊤
x : K
hx : ↑C x ∈ I
⊢ x = 0

tactic: have := I.mul_mem_left (MvPolynomial.C x⁻¹) hx
state_before: σ : Type u
K : Type v
inst✝ : Field K
I : Ideal (MvPolynomial σ K)
hI : I ≠ ⊤
x : K
hx : ↑C x ∈ I
hx0 : ¬x = 0
⊢ 1 ∈ I

tactic: rwa [← MvPolynomial.C.map_mul, inv_mul_cancel hx0, MvPolynomial.C_1] at this
state_before: σ : Type u
K : Type v
inst✝ : Field K
I : Ideal (MvPolynomial σ K)
hI : I ≠ ⊤
x : K
hx : ↑C x ∈ I
hx0 : ¬x = 0
this : ↑C x⁻¹ * ↑C x ∈ I
⊢ 1 ∈ I
Theorem: HasStrictDerivAt.smul_const
File: Mathlib/Analysis/Calculus/Deriv/Mul.lean

tactic: have := hc.smul (hasStrictDerivAt_const x f)
state_before: 𝕜 : Type u
inst✝⁸ : NontriviallyNormedField 𝕜
F : Type v
inst✝⁷ : NormedAddCommGroup F
inst✝⁶ : NormedSpace 𝕜 F
E : Type w
inst✝⁵ : NormedAddCommGroup E
inst✝⁴ : NormedSpace 𝕜 E
f✝ f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t : Set 𝕜
L L₁ L₂ : Filter 𝕜
𝕜' : Type u_1
inst✝³ : NontriviallyNormedField 𝕜'
inst✝² : NormedAlgebra 𝕜 𝕜'
inst✝¹ : NormedSpace 𝕜' F
inst✝ : IsScalarTower 𝕜 𝕜' F
c : 𝕜 → 𝕜'
c' : 𝕜'
hc : HasStrictDerivAt c c' x
f : F
⊢ HasStrictDerivAt (fun y => c y • f) (c' • f) x

tactic: rwa [smul_zero, zero_add] at this
state_before: 𝕜 : Type u
inst✝⁸ : NontriviallyNormedField 𝕜
F : Type v
inst✝⁷ : NormedAddCommGroup F
inst✝⁶ : NormedSpace 𝕜 F
E : Type w
inst✝⁵ : NormedAddCommGroup E
inst✝⁴ : NormedSpace 𝕜 E
f✝ f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t : Set 𝕜
L L₁ L₂ : Filter 𝕜
𝕜' : Type u_1
inst✝³ : NontriviallyNormedField 𝕜'
inst✝² : NormedAlgebra 𝕜 𝕜'
inst✝¹ : NormedSpace 𝕜' F
inst✝ : IsScalarTower 𝕜 𝕜' F
c : 𝕜 → 𝕜'
c' : 𝕜'
hc : HasStrictDerivAt c c' x
f : F
this : HasStrictDerivAt (fun y => c y • f) (c x • 0 + c' • f) x
⊢ HasStrictDerivAt (fun y => c y • f) (c' • f) x
Theorem: Int.neg_dvd
File: Std/Data/Int/DivMod.lean

tactic: constructor <;> exact fun ⟨k, e⟩ =>
  ⟨-k, by simp [e, Int.neg_mul, Int.mul_neg, Int.neg_neg]⟩
state_before: a b : Int
⊢ -a ∣ b ↔ a ∣ b

tactic: simp [e, Int.neg_mul, Int.mul_neg, Int.neg_neg]
state_before: a b : Int
x✝ : a ∣ b
k : Int
e : b = a * k
⊢ b = -a * -k
Theorem: WithBot.image_coe_Ioi
File: Mathlib/Data/Set/Intervals/WithBotTop.lean

tactic: rw [← preimage_coe_Ioi, image_preimage_eq_inter_range, range_coe,
  inter_eq_self_of_subset_left (Ioi_subset_Ioi bot_le)]
state_before: α : Type u_1
inst✝ : PartialOrder α
a b : α
⊢ some '' Ioi a = Ioi ↑a
Theorem: Nat.factorization_prod_pow_eq_self
File: Mathlib/Data/Nat/Factorization/Basic.lean

tactic: rw [factorization_eq_factors_multiset n]
state_before: n : ℕ
hn : n ≠ 0
⊢ (Finsupp.prod (factorization n) fun x x_1 => x ^ x_1) = n

tactic: simp only [← prod_toMultiset, factorization, Multiset.coe_prod, Multiset.toFinsupp_toMultiset]
state_before: n : ℕ
hn : n ≠ 0
⊢ (Finsupp.prod (↑Multiset.toFinsupp ↑(factors n)) fun x x_1 => x ^ x_1) = n

tactic: exact prod_factors hn
state_before: n : ℕ
hn : n ≠ 0
⊢ List.prod (factors n) = n
Theorem: Representation.dualTensorHom_comm
File: Mathlib/RepresentationTheory/Basic.lean

tactic: ext
state_before: k : Type u_1
G : Type u_4
V : Type u_2
W : Type u_3
inst✝⁵ : CommSemiring k
inst✝⁴ : Group G
inst✝³ : AddCommMonoid V
inst✝² : Module k V
inst✝¹ : AddCommMonoid W
inst✝ : Module k W
ρV : Representation k G V
ρW : Representation k G W
g : G
⊢ comp (dualTensorHom k V W) (TensorProduct.map (↑(dual ρV) g) (↑ρW g)) = comp (↑(linHom ρV ρW) g) (dualTensorHom k V W)

tactic: simp [Module.Dual.transpose_apply]
state_before: case a.h.h.h
k : Type u_1
G : Type u_4
V : Type u_2
W : Type u_3
inst✝⁵ : CommSemiring k
inst✝⁴ : Group G
inst✝³ : AddCommMonoid V
inst✝² : Module k V
inst✝¹ : AddCommMonoid W
inst✝ : Module k W
ρV : Representation k G V
ρW : Representation k G W
g : G
x✝² : Module.Dual k V
x✝¹ : W
x✝ : V
⊢ ↑(↑(↑(TensorProduct.AlgebraTensorModule.curry (comp (dualTensorHom k V W) (TensorProduct.map (↑(dual ρV) g) (↑ρW g))))
              x✝²)
          x✝¹)
      x✝ =
    ↑(↑(↑(TensorProduct.AlgebraTensorModule.curry (comp (↑(linHom ρV ρW) g) (dualTensorHom k V W))) x✝²) x✝¹) x✝
Theorem: Nat.filter_multiset_Ico_card_eq_of_periodic
File: Mathlib/Data/Nat/Periodic.lean

tactic: rw [count_eq_card_filter_range, Finset.card, Finset.filter_val, Finset.range_val, ←
  multiset_Ico_map_mod n, ← map_count_True_eq_filter_card, ← map_count_True_eq_filter_card,
  map_map]
state_before: n a : ℕ
p : ℕ → Prop
inst✝ : DecidablePred p
pp : Periodic p a
⊢ ↑card (filter p (Ico n (n + a))) = count p a

tactic: congr
state_before: n a : ℕ
p : ℕ → Prop
inst✝ : DecidablePred p
pp : Periodic p a
⊢ Multiset.count True (map p (Ico n (n + a))) = Multiset.count True (map (p ∘ fun x => x % a) (Ico n (n + a)))

tactic: funext n
state_before: case e_a.e_f
n a : ℕ
p : ℕ → Prop
inst✝ : DecidablePred p
pp : Periodic p a
⊢ p = p ∘ fun x => x % a

tactic: exact (Function.Periodic.map_mod_nat pp n).symm
state_before: case e_a.e_f.h
n✝ a : ℕ
p : ℕ → Prop
inst✝ : DecidablePred p
pp : Periodic p a
n : ℕ
⊢ p n = (p ∘ fun x => x % a) n
Theorem: OpenEmbedding.singleton_smoothManifoldWithCorners
File: Mathlib/Geometry/Manifold/SmoothManifoldWithCorners.lean

tactic: simp
state_before: 𝕜 : Type u_1
inst✝⁵ : NontriviallyNormedField 𝕜
E : Type u_2
inst✝⁴ : NormedAddCommGroup E
inst✝³ : NormedSpace 𝕜 E
H : Type u_3
inst✝² : TopologicalSpace H
I : ModelWithCorners 𝕜 E H
M : Type u_4
inst✝¹ : TopologicalSpace M
inst✝ : Nonempty M
f : M → H
h : OpenEmbedding f
⊢ (toLocalHomeomorph f h).toLocalEquiv.source = univ
Theorem: Filter.tendsto_atBot_diagonal
File: Mathlib/Order/Filter/AtTopBot.lean

tactic: rw [← prod_atBot_atBot_eq]
state_before: ι : Type ?u.281006
ι' : Type ?u.281009
α : Type u_1
β : Type ?u.281015
γ : Type ?u.281018
inst✝ : SemilatticeInf α
⊢ Tendsto (fun a => (a, a)) atBot atBot

tactic: exact tendsto_id.prod_mk tendsto_id
state_before: ι : Type ?u.281006
ι' : Type ?u.281009
α : Type u_1
β : Type ?u.281015
γ : Type ?u.281018
inst✝ : SemilatticeInf α
⊢ Tendsto (fun a => (a, a)) atBot (atBot ×ˢ atBot)
Theorem: Finite.exists_ne_map_eq_of_infinite
File: Mathlib/Data/Fintype/Card.lean

tactic: simpa only [Injective, not_forall, not_imp, and_comm] using not_injective_infinite_finite f
state_before: α✝ : Type ?u.81981
β✝ : Type ?u.81984
γ : Type ?u.81987
α : Sort u_1
β : Sort u_2
inst✝¹ : Infinite α
inst✝ : Finite β
f : α → β
⊢ ∃ x y, x ≠ y ∧ f x = f y
Theorem: rightCoset_assoc
File: Mathlib/GroupTheory/Coset.lean

tactic: simp [leftCoset, rightCoset, (image_comp _ _ _).symm, Function.comp, mul_assoc]
state_before: α : Type u_1
inst✝ : Semigroup α
s : Set α
a b : α
⊢ s *r a *r b = s *r (a * b)
Theorem: Finset.Icc_eq_singleton_iff
File: Mathlib/Data/Finset/LocallyFinite.lean

tactic: rw [← coe_eq_singleton, coe_Icc, Set.Icc_eq_singleton_iff]
state_before: ι : Type ?u.71894
α : Type u_1
inst✝¹ : PartialOrder α
inst✝ : LocallyFiniteOrder α
a b c : α
⊢ Icc a b = {c} ↔ a = c ∧ b = c
Theorem: LocalHomeomorph.ofSet_trans_ofSet
File: Mathlib/Topology/LocalHomeomorph.lean

tactic: rw [(ofSet s hs).trans_ofSet hs']
state_before: α : Type u_1
β : Type ?u.73860
γ : Type ?u.73863
δ : Type ?u.73866
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
e : LocalHomeomorph α β
e' : LocalHomeomorph β γ
s : Set α
hs : IsOpen s
s' : Set α
hs' : IsOpen s'
⊢ LocalHomeomorph.trans (ofSet s hs) (ofSet s' hs') = ofSet (s ∩ s') (_ : IsOpen (s ∩ s'))

tactic: ext <;> simp [hs'.interior_eq]
state_before: α : Type u_1
β : Type ?u.73860
γ : Type ?u.73863
δ : Type ?u.73866
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
e : LocalHomeomorph α β
e' : LocalHomeomorph β γ
s : Set α
hs : IsOpen s
s' : Set α
hs' : IsOpen s'
⊢ LocalHomeomorph.restr (ofSet s hs) (↑(ofSet s hs) ⁻¹' s') = ofSet (s ∩ s') (_ : IsOpen (s ∩ s'))
Theorem: orthonormal_sUnion_of_directed
File: Mathlib/Analysis/InnerProductSpace/Basic.lean

tactic: rw [Set.sUnion_eq_iUnion]
state_before: 𝕜 : Type u_2
E : Type u_1
F : Type ?u.2158643
inst✝⁴ : IsROrC 𝕜
inst✝³ : NormedAddCommGroup E
inst✝² : InnerProductSpace 𝕜 E
inst✝¹ : NormedAddCommGroup F
inst✝ : InnerProductSpace ℝ F
dec_E : DecidableEq E
ι : Type ?u.2158692
dec_ι : DecidableEq ι
s : Set (Set E)
hs : DirectedOn (fun x x_1 => x ⊆ x_1) s
h : ∀ (a : Set E), a ∈ s → Orthonormal 𝕜 fun x => ↑x
⊢ Orthonormal 𝕜 fun x => ↑x

tactic: exact orthonormal_iUnion_of_directed hs.directed_val (by simpa using h)
state_before: 𝕜 : Type u_2
E : Type u_1
F : Type ?u.2158643
inst✝⁴ : IsROrC 𝕜
inst✝³ : NormedAddCommGroup E
inst✝² : InnerProductSpace 𝕜 E
inst✝¹ : NormedAddCommGroup F
inst✝ : InnerProductSpace ℝ F
dec_E : DecidableEq E
ι : Type ?u.2158692
dec_ι : DecidableEq ι
s : Set (Set E)
hs : DirectedOn (fun x x_1 => x ⊆ x_1) s
h : ∀ (a : Set E), a ∈ s → Orthonormal 𝕜 fun x => ↑x
⊢ Orthonormal 𝕜 fun x => ↑x

tactic: simpa using h
state_before: 𝕜 : Type u_2
E : Type u_1
F : Type ?u.2158643
inst✝⁴ : IsROrC 𝕜
inst✝³ : NormedAddCommGroup E
inst✝² : InnerProductSpace 𝕜 E
inst✝¹ : NormedAddCommGroup F
inst✝ : InnerProductSpace ℝ F
dec_E : DecidableEq E
ι : Type ?u.2158692
dec_ι : DecidableEq ι
s : Set (Set E)
hs : DirectedOn (fun x x_1 => x ⊆ x_1) s
h : ∀ (a : Set E), a ∈ s → Orthonormal 𝕜 fun x => ↑x
⊢ ∀ (i : ↑s), Orthonormal 𝕜 fun x => ↑x
Theorem: Polynomial.coeff_one_reverse
File: Mathlib/Data/Polynomial/Reverse.lean

tactic: rw [coeff_reverse, nextCoeff]
state_before: R : Type u_1
inst✝ : Semiring R
f✝ f : R[X]
⊢ coeff (reverse f) 1 = nextCoeff f

tactic: split_ifs with hf
state_before: R : Type u_1
inst✝ : Semiring R
f✝ f : R[X]
⊢ coeff f (↑(revAt (natDegree f)) 1) = if natDegree f = 0 then 0 else coeff f (natDegree f - 1)

tactic: have : coeff f 1 = 0 := coeff_eq_zero_of_natDegree_lt (by simp only [hf, zero_lt_one])
state_before: case inl
R : Type u_1
inst✝ : Semiring R
f✝ f : R[X]
hf : natDegree f = 0
⊢ coeff f (↑(revAt (natDegree f)) 1) = 0

tactic: simp [*, revAt]
state_before: case inl
R : Type u_1
inst✝ : Semiring R
f✝ f : R[X]
hf : natDegree f = 0
this : coeff f 1 = 0
⊢ coeff f (↑(revAt (natDegree f)) 1) = 0

tactic: simp only [hf, zero_lt_one]
state_before: R : Type u_1
inst✝ : Semiring R
f✝ f : R[X]
hf : natDegree f = 0
⊢ natDegree f < 1

tactic: rw [revAt_le]
state_before: case inr
R : Type u_1
inst✝ : Semiring R
f✝ f : R[X]
hf : ¬natDegree f = 0
⊢ coeff f (↑(revAt (natDegree f)) 1) = coeff f (natDegree f - 1)

tactic: exact Nat.succ_le_iff.2 (pos_iff_ne_zero.2 hf)
state_before: case inr
R : Type u_1
inst✝ : Semiring R
f✝ f : R[X]
hf : ¬natDegree f = 0
⊢ 1 ≤ natDegree f
Theorem: Matrix.smul_mat_cons
File: Mathlib/Data/Matrix/Notation.lean

tactic: ext i
state_before: α : Type u
o n m : ℕ
m' : Type uₘ
n' : Type uₙ
o' : Type uₒ
a b : ℕ
inst✝ : Semiring α
x : α
v : n' → α
A : Fin m → n' → α
⊢ x • vecCons v A = vecCons (x • v) (x • A)

tactic: refine' Fin.cases _ _ i <;> simp
state_before: case h.h
α : Type u
o n m : ℕ
m' : Type uₘ
n' : Type uₙ
o' : Type uₒ
a b : ℕ
inst✝ : Semiring α
x : α
v : n' → α
A : Fin m → n' → α
i : Fin (Nat.succ m)
x✝ : n'
⊢ (x • vecCons v A) i x✝ = vecCons (x • v) (x • A) i x✝
Theorem: Polynomial.natDegree_C_mul_eq_of_mul_ne_zero
File: Mathlib/Data/Polynomial/Degree/Lemmas.lean

tactic: refine' eq_natDegree_of_le_mem_support (natDegree_C_mul_le a p) _
state_before: R : Type u
S : Type v
ι : Type w
a b : R
m n : ℕ
inst✝ : Semiring R
p q r : R[X]
h : a * leadingCoeff p ≠ 0
⊢ natDegree (↑C a * p) = natDegree p

tactic: refine' mem_support_iff.mpr _
state_before: R : Type u
S : Type v
ι : Type w
a b : R
m n : ℕ
inst✝ : Semiring R
p q r : R[X]
h : a * leadingCoeff p ≠ 0
⊢ natDegree p ∈ support (↑C a * p)

tactic: rwa [coeff_C_mul]
state_before: R : Type u
S : Type v
ι : Type w
a b : R
m n : ℕ
inst✝ : Semiring R
p q r : R[X]
h : a * leadingCoeff p ≠ 0
⊢ coeff (↑C a * p) (natDegree p) ≠ 0
Theorem: MeasureTheory.OuterMeasure.smul_ofFunction
File: Mathlib/MeasureTheory/Measure/OuterMeasure.lean

tactic: simp [m_empty]
state_before: α : Type ?u.159032
m : Set α → ℝ≥0∞
m_empty : m ∅ = 0
c : ℝ≥0∞
hc : c ≠ ⊤
⊢ (c • m) ∅ = 0

tactic: ext1 s
state_before: α : Type u_1
m : Set α → ℝ≥0∞
m_empty : m ∅ = 0
c : ℝ≥0∞
hc : c ≠ ⊤
⊢ c • OuterMeasure.ofFunction m m_empty = OuterMeasure.ofFunction (c • m) (_ : c • m ∅ = 0)

tactic: haveI : Nonempty { t : ℕ → Set α // s ⊆ ⋃ i, t i } := ⟨⟨fun _ => s, subset_iUnion (fun _ => s) 0⟩⟩
state_before: case h
α : Type u_1
m : Set α → ℝ≥0∞
m_empty : m ∅ = 0
c : ℝ≥0∞
hc : c ≠ ⊤
s : Set α
⊢ ↑(c • OuterMeasure.ofFunction m m_empty) s = ↑(OuterMeasure.ofFunction (c • m) (_ : c • m ∅ = 0)) s

tactic: simp only [smul_apply, ofFunction_apply, ENNReal.tsum_mul_left, Pi.smul_apply, smul_eq_mul,
iInf_subtype']
state_before: case h
α : Type u_1
m : Set α → ℝ≥0∞
m_empty : m ∅ = 0
c : ℝ≥0∞
hc : c ≠ ⊤
s : Set α
this : Nonempty { t // s ⊆ ⋃ (i : ℕ), t i }
⊢ ↑(c • OuterMeasure.ofFunction m m_empty) s = ↑(OuterMeasure.ofFunction (c • m) (_ : c • m ∅ = 0)) s

tactic: rw [ENNReal.iInf_mul_left fun h => (hc h).elim]
state_before: case h
α : Type u_1
m : Set α → ℝ≥0∞
m_empty : m ∅ = 0
c : ℝ≥0∞
hc : c ≠ ⊤
s : Set α
this : Nonempty { t // s ⊆ ⋃ (i : ℕ), t i }
⊢ (c * ⨅ (x : { i // s ⊆ iUnion i }), ∑' (n : ℕ), m (↑x n)) = ⨅ (x : { i // s ⊆ iUnion i }), c * ∑' (i : ℕ), m (↑x i)
Theorem: Nat.lcm_one_right
File: Std/Data/Nat/Gcd.lean

tactic: simp [lcm]
state_before: m : Nat
⊢ lcm m 1 = m
Theorem: Finset.exists_mem_eq_sup'
File: Mathlib/Data/Finset/Lattice.lean

tactic: refine' H.cons_induction (fun c => _) fun c s hc hs ih => _
state_before: F : Type ?u.307909
α : Type u_2
β : Type ?u.307915
γ : Type ?u.307918
ι : Type u_1
κ : Type ?u.307924
inst✝ : LinearOrder α
s : Finset ι
H : Finset.Nonempty s
f✝ : ι → α
a : α
f : ι → α
⊢ ∃ i, i ∈ s ∧ sup' s H f = f i

tactic: exact ⟨c, mem_singleton_self c, rfl⟩
state_before: case refine'_1
F : Type ?u.307909
α : Type u_2
β : Type ?u.307915
γ : Type ?u.307918
ι : Type u_1
κ : Type ?u.307924
inst✝ : LinearOrder α
s : Finset ι
H : Finset.Nonempty s
f✝ : ι → α
a : α
f : ι → α
c : ι
⊢ ∃ i, i ∈ {c} ∧ sup' {c} (_ : Finset.Nonempty {c}) f = f i

tactic: rcases ih with ⟨b, hb, h'⟩
state_before: case refine'_2
F : Type ?u.307909
α : Type u_2
β : Type ?u.307915
γ : Type ?u.307918
ι : Type u_1
κ : Type ?u.307924
inst✝ : LinearOrder α
s✝ : Finset ι
H : Finset.Nonempty s✝
f✝ : ι → α
a : α
f : ι → α
c : ι
s : Finset ι
hc : ¬c ∈ s
hs : Finset.Nonempty s
ih : ∃ i, i ∈ s ∧ sup' s hs f = f i
⊢ ∃ i, i ∈ cons c s hc ∧ sup' (cons c s hc) (_ : Finset.Nonempty (cons c s hc)) f = f i

tactic: rw [sup'_cons hs, h']
state_before: case refine'_2.intro.intro
F : Type ?u.307909
α : Type u_2
β : Type ?u.307915
γ : Type ?u.307918
ι : Type u_1
κ : Type ?u.307924
inst✝ : LinearOrder α
s✝ : Finset ι
H : Finset.Nonempty s✝
f✝ : ι → α
a : α
f : ι → α
c : ι
s : Finset ι
hc : ¬c ∈ s
hs : Finset.Nonempty s
b : ι
hb : b ∈ s
h' : sup' s hs f = f b
⊢ ∃ i, i ∈ cons c s hc ∧ sup' (cons c s hc) (_ : Finset.Nonempty (cons c s hc)) f = f i

tactic: cases le_total (f b) (f c) with
| inl h => exact ⟨c, mem_cons.2 (Or.inl rfl), sup_eq_left.2 h⟩
| inr h => exact ⟨b, mem_cons.2 (Or.inr hb), sup_eq_right.2 h⟩
state_before: case refine'_2.intro.intro
F : Type ?u.307909
α : Type u_2
β : Type ?u.307915
γ : Type ?u.307918
ι : Type u_1
κ : Type ?u.307924
inst✝ : LinearOrder α
s✝ : Finset ι
H : Finset.Nonempty s✝
f✝ : ι → α
a : α
f : ι → α
c : ι
s : Finset ι
hc : ¬c ∈ s
hs : Finset.Nonempty s
b : ι
hb : b ∈ s
h' : sup' s hs f = f b
⊢ ∃ i, i ∈ cons c s hc ∧ f c ⊔ f b = f i

tactic: exact ⟨c, mem_cons.2 (Or.inl rfl), sup_eq_left.2 h⟩
state_before: case refine'_2.intro.intro.inl
F : Type ?u.307909
α : Type u_2
β : Type ?u.307915
γ : Type ?u.307918
ι : Type u_1
κ : Type ?u.307924
inst✝ : LinearOrder α
s✝ : Finset ι
H : Finset.Nonempty s✝
f✝ : ι → α
a : α
f : ι → α
c : ι
s : Finset ι
hc : ¬c ∈ s
hs : Finset.Nonempty s
b : ι
hb : b ∈ s
h' : sup' s hs f = f b
h : f b ≤ f c
⊢ ∃ i, i ∈ cons c s hc ∧ f c ⊔ f b = f i

tactic: exact ⟨b, mem_cons.2 (Or.inr hb), sup_eq_right.2 h⟩
state_before: case refine'_2.intro.intro.inr
F : Type ?u.307909
α : Type u_2
β : Type ?u.307915
γ : Type ?u.307918
ι : Type u_1
κ : Type ?u.307924
inst✝ : LinearOrder α
s✝ : Finset ι
H : Finset.Nonempty s✝
f✝ : ι → α
a : α
f : ι → α
c : ι
s : Finset ι
hc : ¬c ∈ s
hs : Finset.Nonempty s
b : ι
hb : b ∈ s
h' : sup' s hs f = f b
h : f c ≤ f b
⊢ ∃ i, i ∈ cons c s hc ∧ f c ⊔ f b = f i
Theorem: LinearMap.toMatrix₂_mul
File: Mathlib/LinearAlgebra/Matrix/SesquilinearForm.lean

tactic: rw [LinearMap.toMatrix₂_compl₂ b₁ b₂, toMatrix_toLin]
state_before: R : Type u_1
R₁ : Type ?u.1890648
R₂ : Type ?u.1890651
M✝ : Type ?u.1890654
M₁ : Type u_2
M₂ : Type u_3
M₁' : Type ?u.1890663
M₂' : Type u_7
n : Type u_6
m : Type u_4
n' : Type ?u.1890675
m' : Type u_5
ι : Type ?u.1890681
inst✝¹⁶ : CommRing R
inst✝¹⁵ : AddCommMonoid M₁
inst✝¹⁴ : Module R M₁
inst✝¹³ : AddCommMonoid M₂
inst✝¹² : Module R M₂
inst✝¹¹ : DecidableEq n
inst✝¹⁰ : Fintype n
inst✝⁹ : DecidableEq m
inst✝⁸ : Fintype m
b₁ : Basis n R M₁
b₂ : Basis m R M₂
inst✝⁷ : AddCommMonoid M₁'
inst✝⁶ : Module R M₁'
inst✝⁵ : AddCommMonoid M₂'
inst✝⁴ : Module R M₂'
b₁' : Basis n' R M₁'
b₂' : Basis m' R M₂'
inst✝³ : Fintype n'
inst✝² : Fintype m'
inst✝¹ : DecidableEq n'
inst✝ : DecidableEq m'
B : M₁ →ₗ[R] M₂ →ₗ[R] R
M : Matrix m m' R
⊢ ↑(toMatrix₂ b₁ b₂) B ⬝ M = ↑(toMatrix₂ b₁ b₂') (compl₂ B (↑(toLin b₂' b₂) M))
Theorem: IsLocalization.mk'_add
File: Mathlib/RingTheory/Localization/Basic.lean

tactic: rw [mul_comm (_ + _), mul_add, mul_mk'_eq_mk'_of_mul, mk'_add_eq_iff_add_mul_eq_mul,
  mul_comm (_ * _), ← mul_assoc, add_comm, ← map_mul, mul_mk'_eq_mk'_of_mul,
  add_comm _ (mk' _ _ _), mk'_add_eq_iff_add_mul_eq_mul]
state_before: R : Type u_1
inst✝⁴ : CommSemiring R
M : Submonoid R
S : Type u_2
inst✝³ : CommSemiring S
inst✝² : Algebra R S
P : Type ?u.894644
inst✝¹ : CommSemiring P
inst✝ : IsLocalization M S
x₁ x₂ : R
y₁ y₂ : { x // x ∈ M }
⊢ (mk' S x₁ y₁ + mk' S x₂ y₂) * ↑(algebraMap R S) ↑(y₁ * y₂) = ↑(algebraMap R S) (x₁ * ↑y₂ + x₂ * ↑y₁)

tactic: simp only [map_add, Submonoid.coe_mul, map_mul]
state_before: R : Type u_1
inst✝⁴ : CommSemiring R
M : Submonoid R
S : Type u_2
inst✝³ : CommSemiring S
inst✝² : Algebra R S
P : Type ?u.894644
inst✝¹ : CommSemiring P
inst✝ : IsLocalization M S
x₁ x₂ : R
y₁ y₂ : { x // x ∈ M }
⊢ ↑(algebraMap R ((fun x => (fun x => S) (x₂ * ↑y₁ + x₁ * ↑y₂)) (↑(y₁ * y₂) * x₁))) (↑y₁ * ↑(y₁ * y₂) * x₂) +
      ↑(algebraMap R ((fun x => S) (x₂ * ↑y₁ + x₁ * ↑y₂))) (↑(y₁ * y₂) * x₁) *
        ↑(algebraMap R ((fun x => (fun x => S) (x₂ * ↑y₁ + x₁ * ↑y₂)) (↑(y₁ * y₂) * x₁))) ↑y₂ =
    ↑(algebraMap R S) (x₂ * ↑y₁ + x₁ * ↑y₂) * ↑(algebraMap R ((fun x => S) (x₂ * ↑y₁ + x₁ * ↑y₂))) ↑y₁ *
      ↑(algebraMap R ((fun x => (fun x => S) (x₂ * ↑y₁ + x₁ * ↑y₂)) (↑(y₁ * y₂) * x₁))) ↑y₂

tactic: ring
state_before: R : Type u_1
inst✝⁴ : CommSemiring R
M : Submonoid R
S : Type u_2
inst✝³ : CommSemiring S
inst✝² : Algebra R S
P : Type ?u.894644
inst✝¹ : CommSemiring P
inst✝ : IsLocalization M S
x₁ x₂ : R
y₁ y₂ : { x // x ∈ M }
⊢ ↑(algebraMap R S) ↑y₁ * (↑(algebraMap R S) ↑y₁ * ↑(algebraMap R S) ↑y₂) * ↑(algebraMap R S) x₂ +
      ↑(algebraMap R S) ↑y₁ * ↑(algebraMap R S) ↑y₂ * ↑(algebraMap R S) x₁ * ↑(algebraMap R S) ↑y₂ =
    (↑(algebraMap R S) x₂ * ↑(algebraMap R S) ↑y₁ + ↑(algebraMap R S) x₁ * ↑(algebraMap R S) ↑y₂) *
        ↑(algebraMap R S) ↑y₁ *
      ↑(algebraMap R S) ↑y₂
Theorem: cmp_eq_cmp_symm
File: Mathlib/Order/Compare.lean

tactic: rwa [← cmp_swap x', ← cmp_swap, swap_inj]
state_before: α : Type u_1
β✝ : Type ?u.19348
inst✝¹ : LinearOrder α
x y : α
β : Type u_2
inst✝ : LinearOrder β
x' y' : β
h : cmp x y = cmp x' y'
⊢ cmp y x = cmp y' x'

tactic: rwa [← cmp_swap y', ← cmp_swap, swap_inj]
state_before: α : Type u_1
β✝ : Type ?u.19348
inst✝¹ : LinearOrder α
x y : α
β : Type u_2
inst✝ : LinearOrder β
x' y' : β
h : cmp y x = cmp y' x'
⊢ cmp x y = cmp x' y'