tasksource/leandojo huggingface dataset:
Theorem: coevaluation_apply_one
File: Mathlib/LinearAlgebra/Coevaluation.lean

tactic: simp only [coevaluation, id]
state_before: K : Type u
inst✝³ : Field K
V : Type v
inst✝² : AddCommGroup V
inst✝¹ : Module K V
inst✝ : FiniteDimensional K V
⊢ ↑(coevaluation K V) 1 =
    let bV := Basis.ofVectorSpace K V;
    ∑ i : ↑(Basis.ofVectorSpaceIndex K V), ↑bV i ⊗ₜ[K] Basis.coord bV i

tactic: rw [(Basis.singleton Unit K).constr_apply_fintype K]
state_before: K : Type u
inst✝³ : Field K
V : Type v
inst✝² : AddCommGroup V
inst✝¹ : Module K V
inst✝ : FiniteDimensional K V
⊢ ↑(↑(Basis.constr (Basis.singleton Unit K) K) fun x =>
          ∑ x : ↑(Basis.ofVectorSpaceIndex K V),
            ↑(Basis.ofVectorSpace K V) x ⊗ₜ[K] Basis.coord (Basis.ofVectorSpace K V) x)
      1 =
    ∑ x : ↑(Basis.ofVectorSpaceIndex K V), ↑(Basis.ofVectorSpace K V) x ⊗ₜ[K] Basis.coord (Basis.ofVectorSpace K V) x

tactic: simp only [Fintype.univ_punit, Finset.sum_const, one_smul, Basis.singleton_repr,
  Basis.equivFun_apply, Basis.coe_ofVectorSpace, one_nsmul, Finset.card_singleton]
state_before: K : Type u
inst✝³ : Field K
V : Type v
inst✝² : AddCommGroup V
inst✝¹ : Module K V
inst✝ : FiniteDimensional K V
⊢ ∑ i : Unit,
      ↑(Basis.equivFun (Basis.singleton Unit K)) 1 i •
        ∑ x : ↑(Basis.ofVectorSpaceIndex K V),
          ↑(Basis.ofVectorSpace K V) x ⊗ₜ[K] Basis.coord (Basis.ofVectorSpace K V) x =
    ∑ x : ↑(Basis.ofVectorSpaceIndex K V), ↑(Basis.ofVectorSpace K V) x ⊗ₜ[K] Basis.coord (Basis.ofVectorSpace K V) x
Theorem: lt_iff_lt_of_cmp_eq_cmp
File: Mathlib/Order/Compare.lean

tactic: rw [← cmp_eq_lt_iff, ← cmp_eq_lt_iff, h]
state_before: α : Type u_1
β✝ : Type ?u.20071
inst✝¹ : LinearOrder α
x y : α
β : Type u_2
inst✝ : LinearOrder β
x' y' : β
h : cmp x y = cmp x' y'
⊢ x < y ↔ x' < y'
Theorem: Finsupp.embDomain_injective
File: Mathlib/Data/Finsupp/Defs.lean

tactic: simpa only [embDomain_apply] using FunLike.ext_iff.1 h (f a)
state_before: α : Type u_1
β : Type u_2
γ : Type ?u.227043
ι : Type ?u.227046
M : Type u_3
M' : Type ?u.227052
N : Type ?u.227055
P : Type ?u.227058
G : Type ?u.227061
H : Type ?u.227064
R : Type ?u.227067
S : Type ?u.227070
inst✝¹ : Zero M
inst✝ : Zero N
f : α ↪ β
l₁ l₂ : α →₀ M
h : embDomain f l₁ = embDomain f l₂
a : α
⊢ ↑l₁ a = ↑l₂ a
Theorem: toIcoMod_zsmul_add'
File: Mathlib/Algebra/Order/ToIntervalMod.lean

tactic: rw [add_comm, toIcoMod_add_zsmul', add_comm]
state_before: α : Type u_1
inst✝ : LinearOrderedAddCommGroup α
hα : Archimedean α
p : α
hp : 0 < p
a✝ b✝ c : α
n : ℤ
a b : α
m : ℤ
⊢ toIcoMod hp (m • p + a) b = m • p + toIcoMod hp a b
Theorem: TypeVec.dropFun_toSubtype
File: Mathlib/Data/TypeVec.lean

tactic: ext i
state_before: n : ℕ
α : TypeVec (n + 1)
p : α ⟹ repeat (n + 1) Prop
⊢ dropFun (toSubtype p) = toSubtype fun i x => p (Fin2.fs i) x

tactic: induction i <;> simp [dropFun, *] <;> rfl
state_before: case a.h
n : ℕ
α : TypeVec (n + 1)
p : α ⟹ repeat (n + 1) Prop
i : Fin2 n
x✝ : drop (fun i => { x // ofRepeat (p i x) }) i
⊢ dropFun (toSubtype p) i x✝ = toSubtype (fun i x => p (Fin2.fs i) x) i x✝
Theorem: Nat.totient_prime
File: Mathlib/Data/Nat/Totient.lean

tactic: rw [← pow_one p, totient_prime_pow hp] <;> simp
state_before: p : ℕ
hp : Prime p
⊢ φ p = p - 1
Theorem: Nat.factorial_mul_factorial_dvd_factorial_add
File: Mathlib/Data/Nat/Choose/Basic.lean

tactic: suffices : i ! * (i + j - i) ! ∣ (i + j)!
state_before: i j : ℕ
⊢ i ! * j ! ∣ (i + j)!

tactic: . rwa [add_tsub_cancel_left i j] at this
state_before: i j : ℕ
this : i ! * (i + j - i)! ∣ (i + j)!
⊢ i ! * j ! ∣ (i + j)!

case this
i j : ℕ
⊢ i ! * (i + j - i)! ∣ (i + j)!

tactic: exact factorial_mul_factorial_dvd_factorial (Nat.le_add_right _ _)
state_before: case this
i j : ℕ
⊢ i ! * (i + j - i)! ∣ (i + j)!

tactic: rwa [add_tsub_cancel_left i j] at this
state_before: i j : ℕ
this : i ! * (i + j - i)! ∣ (i + j)!
⊢ i ! * j ! ∣ (i + j)!
Theorem: Irrational.add_cases
File: Mathlib/Data/Real/Irrational.lean

tactic: delta Irrational
state_before: q : ℚ
x y : ℝ
⊢ Irrational (x + y) → Irrational x ∨ Irrational y

tactic: contrapose!
state_before: q : ℚ
x y : ℝ
⊢ ¬x + y ∈ Set.range Rat.cast → ¬x ∈ Set.range Rat.cast ∨ ¬y ∈ Set.range Rat.cast

tactic: rintro ⟨⟨rx, rfl⟩, ⟨ry, rfl⟩⟩
state_before: q : ℚ
x y : ℝ
⊢ x ∈ Set.range Rat.cast ∧ y ∈ Set.range Rat.cast → x + y ∈ Set.range Rat.cast

tactic: exact ⟨rx + ry, cast_add rx ry⟩
state_before: case intro.intro.intro
q rx ry : ℚ
⊢ ↑rx + ↑ry ∈ Set.range Rat.cast
Theorem: MeasureTheory.lintegral_biUnion₀
File: Mathlib/MeasureTheory/Integral/Lebesgue.lean

tactic: haveI := ht.toEncodable
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.1022236
δ : Type ?u.1022239
m : MeasurableSpace α
μ ν : Measure α
t : Set β
s : β → Set α
ht : Set.Countable t
hm : ∀ (i : β), i ∈ t → NullMeasurableSet (s i)
hd : Set.Pairwise t (AEDisjoint μ on s)
f : α → ℝ≥0∞
⊢ (∫⁻ (a : α) in ⋃ (i : β) (_ : i ∈ t), s i, f a ∂μ) = ∑' (i : ↑t), ∫⁻ (a : α) in s ↑i, f a ∂μ

tactic: rw [biUnion_eq_iUnion, lintegral_iUnion₀ (SetCoe.forall'.1 hm) (hd.subtype _ _)]
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.1022236
δ : Type ?u.1022239
m : MeasurableSpace α
μ ν : Measure α
t : Set β
s : β → Set α
ht : Set.Countable t
hm : ∀ (i : β), i ∈ t → NullMeasurableSet (s i)
hd : Set.Pairwise t (AEDisjoint μ on s)
f : α → ℝ≥0∞
this : Encodable ↑t
⊢ (∫⁻ (a : α) in ⋃ (i : β) (_ : i ∈ t), s i, f a ∂μ) = ∑' (i : ↑t), ∫⁻ (a : α) in s ↑i, f a ∂μ
Theorem: finsuppTensorFinsupp'_single_tmul_single
File: Mathlib/LinearAlgebra/DirectSum/Finsupp.lean

tactic: ext ⟨a', b'⟩
state_before: R : Type u
M : Type v
N : Type w
inst✝⁵ : Ring R
inst✝⁴ : AddCommGroup M
inst✝³ : Module R M
inst✝² : AddCommGroup N
inst✝¹ : Module R N
S : Type u_1
inst✝ : CommRing S
α : Type u_2
β : Type u_3
a : α
b : β
r₁ r₂ : S
⊢ ↑(finsuppTensorFinsupp' S α β) (Finsupp.single a r₁ ⊗ₜ[S] Finsupp.single b r₂) = Finsupp.single (a, b) (r₁ * r₂)

tactic: aesop (add norm [Finsupp.single_apply])
state_before: case h.mk
R : Type u
M : Type v
N : Type w
inst✝⁵ : Ring R
inst✝⁴ : AddCommGroup M
inst✝³ : Module R M
inst✝² : AddCommGroup N
inst✝¹ : Module R N
S : Type u_1
inst✝ : CommRing S
α : Type u_2
β : Type u_3
a : α
b : β
r₁ r₂ : S
a' : α
b' : β
⊢ ↑(↑(finsuppTensorFinsupp' S α β) (Finsupp.single a r₁ ⊗ₜ[S] Finsupp.single b r₂)) (a', b') =
    ↑(Finsupp.single (a, b) (r₁ * r₂)) (a', b')
Theorem: MeasureTheory.integrable_indicator_iff
File: Mathlib/MeasureTheory/Integral/IntegrableOn.lean

tactic: simp [IntegrableOn, Integrable, HasFiniteIntegral, nnnorm_indicator_eq_indicator_nnnorm,
  ENNReal.coe_indicator, lintegral_indicator _ hs, aestronglyMeasurable_indicator_iff hs]
state_before: α : Type u_1
β : Type ?u.1634475
E : Type u_2
F : Type ?u.1634481
inst✝¹ : MeasurableSpace α
inst✝ : NormedAddCommGroup E
f g : α → E
s t : Set α
μ ν : Measure α
hs : MeasurableSet s
⊢ Integrable (indicator s f) ↔ IntegrableOn f s
Theorem: pow_ite
File: Mathlib/Algebra/GroupPower/Basic.lean

tactic: split_ifs <;> rfl
state_before: α : Type ?u.44
M : Type u
N : Type v
G : Type w
H : Type x
A : Type y
B : Type z
R : Type u₁
S : Type u₂
inst✝¹ : Pow M ℕ
P : Prop
inst✝ : Decidable P
a : M
b c : ℕ
⊢ (a ^ if P then b else c) = if P then a ^ b else a ^ c
Theorem: IsCompact.disjoint_nhdsSet_left
File: Mathlib/Topology/SubsetProperties.lean

tactic: refine' ⟨fun h x hx => h.mono_left <| nhds_le_nhdsSet hx, fun H => _⟩
state_before: α : Type u
β : Type v
ι : Type ?u.16218
π : ι → Type ?u.16223
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace β
s t : Set α
l : Filter α
hs : IsCompact s
⊢ Disjoint (𝓝ˢ s) l ↔ ∀ (x : α), x ∈ s → Disjoint (𝓝 x) l

tactic: choose! U hxU hUl using fun x hx => (nhds_basis_opens x).disjoint_iff_left.1 (H x hx)
state_before: α : Type u
β : Type v
ι : Type ?u.16218
π : ι → Type ?u.16223
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace β
s t : Set α
l : Filter α
hs : IsCompact s
H : ∀ (x : α), x ∈ s → Disjoint (𝓝 x) l
⊢ Disjoint (𝓝ˢ s) l

tactic: choose hxU hUo using hxU
state_before: α : Type u
β : Type v
ι : Type ?u.16218
π : ι → Type ?u.16223
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace β
s t : Set α
l : Filter α
hs : IsCompact s
H : ∀ (x : α), x ∈ s → Disjoint (𝓝 x) l
U : α → Set α
hxU : ∀ (x : α), x ∈ s → x ∈ U x ∧ IsOpen (U x)
hUl : ∀ (x : α), x ∈ s → U xᶜ ∈ l
⊢ Disjoint (𝓝ˢ s) l

tactic: rcases hs.elim_nhds_subcover U fun x hx => (hUo x hx).mem_nhds (hxU x hx) with ⟨t, hts, hst⟩
state_before: α : Type u
β : Type v
ι : Type ?u.16218
π : ι → Type ?u.16223
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace β
s t : Set α
l : Filter α
hs : IsCompact s
H : ∀ (x : α), x ∈ s → Disjoint (𝓝 x) l
U : α → Set α
hUl : ∀ (x : α), x ∈ s → U xᶜ ∈ l
hxU : ∀ (x : α), x ∈ s → x ∈ U x
hUo : ∀ (x : α), x ∈ s → IsOpen (U x)
⊢ Disjoint (𝓝ˢ s) l

tactic: refine'
  (hasBasis_nhdsSet _).disjoint_iff_left.2
    ⟨⋃ x ∈ t, U x, ⟨isOpen_biUnion fun x hx => hUo x (hts x hx), hst⟩, _⟩
state_before: case intro.intro
α : Type u
β : Type v
ι : Type ?u.16218
π : ι → Type ?u.16223
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace β
s t✝ : Set α
l : Filter α
hs : IsCompact s
H : ∀ (x : α), x ∈ s → Disjoint (𝓝 x) l
U : α → Set α
hUl : ∀ (x : α), x ∈ s → U xᶜ ∈ l
hxU : ∀ (x : α), x ∈ s → x ∈ U x
hUo : ∀ (x : α), x ∈ s → IsOpen (U x)
t : Finset α
hts : ∀ (x : α), x ∈ t → x ∈ s
hst : s ⊆ ⋃ (x : α) (_ : x ∈ t), U x
⊢ Disjoint (𝓝ˢ s) l

tactic: rw [compl_iUnion₂, biInter_finset_mem]
state_before: case intro.intro
α : Type u
β : Type v
ι : Type ?u.16218
π : ι → Type ?u.16223
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace β
s t✝ : Set α
l : Filter α
hs : IsCompact s
H : ∀ (x : α), x ∈ s → Disjoint (𝓝 x) l
U : α → Set α
hUl : ∀ (x : α), x ∈ s → U xᶜ ∈ l
hxU : ∀ (x : α), x ∈ s → x ∈ U x
hUo : ∀ (x : α), x ∈ s → IsOpen (U x)
t : Finset α
hts : ∀ (x : α), x ∈ t → x ∈ s
hst : s ⊆ ⋃ (x : α) (_ : x ∈ t), U x
⊢ (⋃ (x : α) (_ : x ∈ t), U x)ᶜ ∈ l

tactic: exact fun x hx => hUl x (hts x hx)
state_before: case intro.intro
α : Type u
β : Type v
ι : Type ?u.16218
π : ι → Type ?u.16223
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace β
s t✝ : Set α
l : Filter α
hs : IsCompact s
H : ∀ (x : α), x ∈ s → Disjoint (𝓝 x) l
U : α → Set α
hUl : ∀ (x : α), x ∈ s → U xᶜ ∈ l
hxU : ∀ (x : α), x ∈ s → x ∈ U x
hUo : ∀ (x : α), x ∈ s → IsOpen (U x)
t : Finset α
hts : ∀ (x : α), x ∈ t → x ∈ s
hst : s ⊆ ⋃ (x : α) (_ : x ∈ t), U x
⊢ ∀ (i : α), i ∈ t → U iᶜ ∈ l
Theorem: Vector.not_empty_toList
File: Mathlib/Data/Vector/Basic.lean

tactic: simp only [empty_toList_eq_ff, Bool.coe_sort_false, not_false_iff]
state_before: n : ℕ
α : Type u_1
v : Vector α (n + 1)
⊢ ¬List.isEmpty (toList v) = true
Theorem: Real.rpow_lt_rpow
File: Mathlib/Analysis/SpecialFunctions/Pow/Real.lean

tactic: rw [le_iff_eq_or_lt] at hx
state_before: x y z : ℝ
hx : 0 ≤ x
hxy : x < y
hz : 0 < z
⊢ x ^ z < y ^ z

tactic: cases' hx with hx hx
state_before: x y z : ℝ
hx : 0 = x ∨ 0 < x
hxy : x < y
hz : 0 < z
⊢ x ^ z < y ^ z

tactic: rw [← hx, zero_rpow (ne_of_gt hz)]
state_before: case inl
x y z : ℝ
hxy : x < y
hz : 0 < z
hx : 0 = x
⊢ x ^ z < y ^ z

tactic: exact rpow_pos_of_pos (by rwa [← hx] at hxy) _
state_before: case inl
x y z : ℝ
hxy : x < y
hz : 0 < z
hx : 0 = x
⊢ 0 < y ^ z

tactic: rwa [← hx] at hxy
state_before: x y z : ℝ
hxy : x < y
hz : 0 < z
hx : 0 = x
⊢ 0 < y

tactic: rw [rpow_def_of_pos hx, rpow_def_of_pos (lt_trans hx hxy), exp_lt_exp]
state_before: case inr
x y z : ℝ
hxy : x < y
hz : 0 < z
hx : 0 < x
⊢ x ^ z < y ^ z

tactic: exact mul_lt_mul_of_pos_right (log_lt_log hx hxy) hz
state_before: case inr
x y z : ℝ
hxy : x < y
hz : 0 < z
hx : 0 < x
⊢ log x * z < log y * z
Theorem: Option.map₂_swap
File: Mathlib/Data/Option/NAry.lean

tactic: cases a <;> cases b <;> rfl
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
f✝ : α → β → γ
a✝ : Option α
b✝ : Option β
c : Option γ
f : α → β → γ
a : Option α
b : Option β
⊢ map₂ f a b = map₂ (fun a b => f b a) b a
Theorem: CategoryTheory.NonPreadditiveAbelian.add_comp
File: Mathlib/CategoryTheory/Abelian/NonPreadditive.lean

tactic: rw [add_def, sub_comp, neg_def, sub_comp, zero_comp, add_def, neg_def]
state_before: C : Type u
inst✝¹ : Category C
inst✝ : NonPreadditiveAbelian C
X Y Z : C
f g : X ⟶ Y
h : Y ⟶ Z
⊢ (f + g) ≫ h = f ≫ h + g ≫ h
Theorem: Subgroup.map_eq_bot_iff_of_injective
File: Mathlib/GroupTheory/Subgroup/Basic.lean

tactic: rw [map_eq_bot_iff, f.ker_eq_bot_iff.mpr hf, le_bot_iff]
state_before: G : Type u_1
G' : Type ?u.556305
inst✝³ : Group G
inst✝² : Group G'
A : Type ?u.556314
inst✝¹ : AddGroup A
N : Type u_2
inst✝ : Group N
H : Subgroup G
f : G →* N
hf : Injective ↑f
⊢ map f H = ⊥ ↔ H = ⊥
Theorem: CategoryTheory.Subobject.ofLEMk_comp_ofMkLE
File: Mathlib/CategoryTheory/Subobject/Basic.lean

tactic: simp only [ofMkLE, ofLEMk, ofLE, ← Functor.map_comp underlying, assoc, Iso.hom_inv_id_assoc]
state_before: C : Type u₁
inst✝² : Category C
X✝ Y✝ Z : C
D : Type u₂
inst✝¹ : Category D
B A : C
X : Subobject B
f : A ⟶ B
inst✝ : Mono f
Y : Subobject B
h₁ : X ≤ mk f
h₂ : mk f ≤ Y
⊢ ofLEMk X f h₁ ≫ ofMkLE f Y h₂ = ofLE X Y (_ : X ≤ Y)

tactic: congr 1
state_before: C : Type u₁
inst✝² : Category C
X✝ Y✝ Z : C
D : Type u₂
inst✝¹ : Category D
B A : C
X : Subobject B
f : A ⟶ B
inst✝ : Mono f
Y : Subobject B
h₁ : X ≤ mk f
h₂ : mk f ≤ Y
⊢ underlying.map (LE.le.hom h₁ ≫ LE.le.hom h₂) = underlying.map (LE.le.hom (_ : X ≤ Y))
Theorem: ENNReal.toNNReal_sum
File: Mathlib/Data/Real/ENNReal.lean

tactic: rw [← coe_eq_coe, coe_toNNReal, coe_finset_sum, sum_congr rfl]
state_before: α : Type u_1
β : Type ?u.202901
a b c d : ℝ≥0∞
r p q : ℝ≥0
s : Finset α
f : α → ℝ≥0∞
hf : ∀ (a : α), a ∈ s → f a ≠ ⊤
⊢ ENNReal.toNNReal (∑ a in s, f a) = ∑ a in s, ENNReal.toNNReal (f a)

tactic: intro x hx
state_before: α : Type u_1
β : Type ?u.202901
a b c d : ℝ≥0∞
r p q : ℝ≥0
s : Finset α
f : α → ℝ≥0∞
hf : ∀ (a : α), a ∈ s → f a ≠ ⊤
⊢ ∀ (x : α), x ∈ s → f x = ↑(ENNReal.toNNReal (f x))

tactic: exact (coe_toNNReal (hf x hx)).symm
state_before: α : Type u_1
β : Type ?u.202901
a b c d : ℝ≥0∞
r p q : ℝ≥0
s : Finset α
f : α → ℝ≥0∞
hf : ∀ (a : α), a ∈ s → f a ≠ ⊤
x : α
hx : x ∈ s
⊢ f x = ↑(ENNReal.toNNReal (f x))

tactic: exact (sum_lt_top hf).ne
state_before: α : Type u_1
β : Type ?u.202901
a b c d : ℝ≥0∞
r p q : ℝ≥0
s : Finset α
f : α → ℝ≥0∞
hf : ∀ (a : α), a ∈ s → f a ≠ ⊤
⊢ ∑ a in s, f a ≠ ⊤
Theorem: FirstOrder.Language.Theory.SemanticallyEquivalent.not
File: Mathlib/ModelTheory/Satisfiability.lean

tactic: simp_rw [SemanticallyEquivalent, ModelsBoundedFormula, BoundedFormula.realize_iff,
  BoundedFormula.realize_not]
state_before: L : Language
T : Theory L
α : Type w
n : ℕ
φ ψ : BoundedFormula L α n
h : SemanticallyEquivalent T φ ψ
⊢ SemanticallyEquivalent T (∼φ) ∼ψ

tactic: exact fun M v xs => not_congr h.realize_bd_iff
state_before: L : Language
T : Theory L
α : Type w
n : ℕ
φ ψ : BoundedFormula L α n
h : SemanticallyEquivalent T φ ψ
⊢ ∀ (M : ModelType T) (v : α → ↑M) (xs : Fin n → ↑M), ¬BoundedFormula.Realize φ v xs ↔ ¬BoundedFormula.Realize ψ v xs
Theorem: Polynomial.bernoulli_eq_sub_sum
File: Mathlib/NumberTheory/BernoulliPolynomials.lean

tactic: rw [Nat.cast_succ, ← sum_bernoulli n, sum_range_succ, add_sub_cancel', choose_succ_self_right,
  Nat.cast_succ]
state_before: n : ℕ
⊢ ↑(succ n) • bernoulli n = ↑(monomial n) ↑(succ n) - ∑ k in range n, ↑(Nat.choose (n + 1) k) • bernoulli k
Theorem: CategoryTheory.Limits.coprod.desc_comp_assoc
File: Mathlib/CategoryTheory/Limits/Shapes/BinaryProducts.lean

tactic: simp
state_before: C✝ : Type u
inst✝² : Category C✝
X✝ Y✝ : C✝
C : Type u
inst✝¹ : Category C
V W X Y : C
inst✝ : HasBinaryCoproduct X Y
f : V ⟶ W
g : X ⟶ V
h : Y ⟶ V
Z : C
l : W ⟶ Z
⊢ desc g h ≫ f ≫ l = desc (g ≫ f) (h ≫ f) ≫ l
Theorem: Submodule.card_quotient_mul_card_quotient
File: Mathlib/LinearAlgebra/Isomorphisms.lean

tactic: rw [Submodule.card_eq_card_quotient_mul_card (map T.mkQ S),
  Fintype.card_eq.mpr ⟨(quotientQuotientEquivQuotient T S hST).toEquiv⟩]
state_before: R : Type u_1
M : Type u_2
M₂ : Type ?u.157808
M₃ : Type ?u.157811
inst✝⁹ : Ring R
inst✝⁸ : AddCommGroup M
inst✝⁷ : AddCommGroup M₂
inst✝⁶ : AddCommGroup M₃
inst✝⁵ : Module R M
inst✝⁴ : Module R M₂
inst✝³ : Module R M₃
f : M →ₗ[R] M₂
S✝ T✝ : Submodule R M
h : S✝ ≤ T✝
S T : Submodule R M
hST : T ≤ S
inst✝² : DecidablePred fun x => x ∈ map (mkQ T) S
inst✝¹ : Fintype (M ⧸ S)
inst✝ : Fintype (M ⧸ T)
⊢ Fintype.card { x // x ∈ map (mkQ T) S } * Fintype.card (M ⧸ S) = Fintype.card (M ⧸ T)
Theorem: CategoryTheory.transferNatTransSelf_adjunction_id
File: Mathlib/CategoryTheory/Adjunction/Mates.lean

tactic: dsimp [transferNatTransSelf, transferNatTrans, Adjunction.id]
state_before: C : Type u₁
D : Type u₂
inst✝¹ : Category C
inst✝ : Category D
L₁ L₂ L₃ : C ⥤ D
R₁ R₂ R₃ : D ⥤ C
adj₁ : L₁ ⊣ R₁
adj₂ : L₂ ⊣ R₂
adj₃ : L₃ ⊣ R₃
L R : C ⥤ C
adj : L ⊣ R
f : 𝟭 C ⟶ L
X : C
⊢ (↑(transferNatTransSelf adj Adjunction.id) f).app X = f.app (R.obj X) ≫ adj.counit.app X

tactic: simp only [comp_id, id_comp]
state_before: C : Type u₁
D : Type u₂
inst✝¹ : Category C
inst✝ : Category D
L₁ L₂ L₃ : C ⥤ D
R₁ R₂ R₃ : D ⥤ C
adj₁ : L₁ ⊣ R₁
adj₂ : L₂ ⊣ R₂
adj₃ : L₃ ⊣ R₃
L R : C ⥤ C
adj : L ⊣ R
f : 𝟭 C ⟶ L
X : C
⊢ 𝟙 (R.obj X) ≫ (𝟙 (R.obj X) ≫ (𝟙 (R.obj X) ≫ f.app (R.obj X) ≫ 𝟙 (L.obj (R.obj X))) ≫ adj.counit.app X) ≫ 𝟙 X =
    f.app (R.obj X) ≫ adj.counit.app X
Theorem: Basis.sumCoords_reindex
File: Mathlib/LinearAlgebra/Basis.lean

tactic: ext x
state_before: ι : Type u_4
ι' : Type u_3
R : Type u_1
R₂ : Type ?u.370286
K : Type ?u.370289
M : Type u_2
M' : Type ?u.370295
M'' : Type ?u.370298
V : Type u
V' : Type ?u.370303
inst✝⁴ : Semiring R
inst✝³ : AddCommMonoid M
inst✝² : Module R M
inst✝¹ : AddCommMonoid M'
inst✝ : Module R M'
b b₁ : Basis ι R M
i : ι
c : R
x : M
b' : Basis ι' R M'
e : ι ≃ ι'
⊢ sumCoords (reindex b e) = sumCoords b

tactic: simp only [coe_sumCoords, repr_reindex]
state_before: case h
ι : Type u_4
ι' : Type u_3
R : Type u_1
R₂ : Type ?u.370286
K : Type ?u.370289
M : Type u_2
M' : Type ?u.370295
M'' : Type ?u.370298
V : Type u
V' : Type ?u.370303
inst✝⁴ : Semiring R
inst✝³ : AddCommMonoid M
inst✝² : Module R M
inst✝¹ : AddCommMonoid M'
inst✝ : Module R M'
b b₁ : Basis ι R M
i : ι
c : R
x✝ : M
b' : Basis ι' R M'
e : ι ≃ ι'
x : M
⊢ ↑(sumCoords (reindex b e)) x = ↑(sumCoords b) x

tactic: exact Finsupp.sum_mapDomain_index (fun _ => rfl) fun _ _ _ => rfl
state_before: case h
ι : Type u_4
ι' : Type u_3
R : Type u_1
R₂ : Type ?u.370286
K : Type ?u.370289
M : Type u_2
M' : Type ?u.370295
M'' : Type ?u.370298
V : Type u
V' : Type ?u.370303
inst✝⁴ : Semiring R
inst✝³ : AddCommMonoid M
inst✝² : Module R M
inst✝¹ : AddCommMonoid M'
inst✝ : Module R M'
b b₁ : Basis ι R M
i : ι
c : R
x✝ : M
b' : Basis ι' R M'
e : ι ≃ ι'
x : M
⊢ (Finsupp.sum (Finsupp.mapDomain (↑e) (↑b.repr x)) fun x => id) = Finsupp.sum (↑b.repr x) fun x => id
Theorem: InnerProductGeometry.norm_sub_eq_abs_sub_norm_of_angle_eq_zero
File: Mathlib/Geometry/Euclidean/Angle/Unoriented/Basic.lean

tactic: rw [← sq_eq_sq (norm_nonneg (x - y)) (abs_nonneg (‖x‖ - ‖y‖)), norm_sub_pow_two_real,
  inner_eq_mul_norm_of_angle_eq_zero h, sq_abs (‖x‖ - ‖y‖)]
state_before: V : Type u_1
inst✝¹ : NormedAddCommGroup V
inst✝ : InnerProductSpace ℝ V
x✝ y✝ x y : V
h : angle x y = 0
⊢ ‖x - y‖ = abs (‖x‖ - ‖y‖)

tactic: ring
state_before: V : Type u_1
inst✝¹ : NormedAddCommGroup V
inst✝ : InnerProductSpace ℝ V
x✝ y✝ x y : V
h : angle x y = 0
⊢ ‖x‖ ^ 2 - 2 * (‖x‖ * ‖y‖) + ‖y‖ ^ 2 = (‖x‖ - ‖y‖) ^ 2
Theorem: List.indexOf_le_length
File: Mathlib/Data/List/Basic.lean

tactic: induction' l with b l ih
state_before: ι : Type ?u.80422
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α
inst✝ : DecidableEq α
a : α
l : List α
⊢ indexOf a l ≤ length l

tactic: simp only [length, indexOf_cons]
state_before: case cons
ι : Type ?u.80422
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α
inst✝ : DecidableEq α
a b : α
l : List α
ih : indexOf a l ≤ length l
⊢ indexOf a (b :: l) ≤ length (b :: l)

tactic: by_cases h : a = b
state_before: case cons
ι : Type ?u.80422
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α
inst✝ : DecidableEq α
a b : α
l : List α
ih : indexOf a l ≤ length l
⊢ (if a = b then 0 else succ (indexOf a l)) ≤ length l + 1

tactic: rw [if_neg h]
state_before: case neg
ι : Type ?u.80422
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α
inst✝ : DecidableEq α
a b : α
l : List α
ih : indexOf a l ≤ length l
h : ¬a = b
⊢ (if a = b then 0 else succ (indexOf a l)) ≤ length l + 1

tactic: exact succ_le_succ ih
state_before: case neg
ι : Type ?u.80422
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α
inst✝ : DecidableEq α
a b : α
l : List α
ih : indexOf a l ≤ length l
h : ¬a = b
⊢ succ (indexOf a l) ≤ length l + 1

tactic: rfl
state_before: case nil
ι : Type ?u.80422
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α
inst✝ : DecidableEq α
a : α
⊢ indexOf a [] ≤ length []

tactic: rw [if_pos h]
state_before: case pos
ι : Type ?u.80422
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α
inst✝ : DecidableEq α
a b : α
l : List α
ih : indexOf a l ≤ length l
h : a = b
⊢ (if a = b then 0 else succ (indexOf a l)) ≤ length l + 1

tactic: exact Nat.zero_le _
state_before: case pos
ι : Type ?u.80422
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁ l₂ : List α
inst✝ : DecidableEq α
a b : α
l : List α
ih : indexOf a l ≤ length l
h : a = b
⊢ 0 ≤ length l + 1
Theorem: upperClosure_mul_distrib
File: Mathlib/Algebra/Order/UpperLower.lean

tactic: rw [UpperSet.coe_mul, mul_upperClosure, upperClosure_mul, UpperSet.upperClosure]
state_before: α : Type u_1
inst✝ : OrderedCommGroup α
s t : Set α
a : α
⊢ ↑(upperClosure (s * t)) = ↑(upperClosure s * upperClosure t)
Theorem: Function.mulSupport_one_sub'
File: Mathlib/Algebra/Support.lean

tactic: rw [sub_eq_add_neg, mulSupport_one_add', support_neg']
state_before: α : Type u_2
β : Type ?u.118394
A : Type ?u.118397
B : Type ?u.118400
M : Type ?u.118403
N : Type ?u.118406
P : Type ?u.118409
R : Type u_1
S : Type ?u.118415
G : Type ?u.118418
M₀ : Type ?u.118421
G₀ : Type ?u.118424
ι : Sort ?u.118427
inst✝¹ : One R
inst✝ : AddGroup R
f : α → R
⊢ mulSupport (1 - f) = support f
Theorem: Set.Intersecting.isUpperSet'
File: Mathlib/Combinatorics/SetFamily/Intersecting.lean

tactic: rintro a b hab ha
state_before: α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s✝ t : Set α
a b c : α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
⊢ IsUpperSet ↑s

tactic: rw [h (Insert.insert b s) _ (Finset.subset_insert _ _)]
state_before: α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s✝ t : Set α
a✝ b✝ c : α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
a b : α
hab : a ≤ b
ha : a ∈ ↑s
⊢ b ∈ ↑s

tactic: rw [coe_insert]
state_before: α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s✝ t : Set α
a✝ b✝ c : α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
a b : α
hab : a ≤ b
ha : a ∈ ↑s
⊢ Intersecting ↑(Insert.insert b s)

tactic: exact
  hs.insert (mt (eq_bot_mono hab) <| hs.ne_bot ha) fun c hc hbc => hs ha hc <| hbc.mono_left hab
state_before: α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s✝ t : Set α
a✝ b✝ c : α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
a b : α
hab : a ≤ b
ha : a ∈ ↑s
⊢ Intersecting (Insert.insert b ↑s)

tactic: exact mem_insert_self _ _
state_before: α : Type u_1
inst✝¹ : SemilatticeInf α
inst✝ : OrderBot α
s✝ t : Set α
a✝ b✝ c : α
s : Finset α
hs : Intersecting ↑s
h : ∀ (t : Finset α), Intersecting ↑t → s ⊆ t → s = t
a b : α
hab : a ≤ b
ha : a ∈ ↑s
⊢ b ∈ ↑(Insert.insert b s)
Theorem: CategoryTheory.Equivalence.inverse_counitInv_comp
File: Mathlib/CategoryTheory/Equivalence.lean

tactic: erw [Iso.inv_eq_inv (e.unitIso.app (e.inverse.obj Y) ≪≫ e.inverse.mapIso (e.counitIso.app Y))
    (Iso.refl _)]
state_before: C : Type u₁
inst✝¹ : Category C
D : Type u₂
inst✝ : Category D
e : C ≌ D
Y : D
⊢ e.inverse.map ((counitInv e).app Y) ≫ (unitInv e).app (e.inverse.obj Y) = 𝟙 (e.inverse.obj Y)

tactic: exact e.unit_inverse_comp Y
state_before: C : Type u₁
inst✝¹ : Category C
D : Type u₂
inst✝ : Category D
e : C ≌ D
Y : D
⊢ (e.unitIso.app (e.inverse.obj Y) ≪≫ e.inverse.mapIso (e.counitIso.app Y)).hom =
    (Iso.refl ((𝟭 C).obj (e.inverse.obj Y))).hom