tasksource/leandojo huggingface dataset:
Theorem: LinearMap.surjective_of_injective
File: Mathlib/LinearAlgebra/FiniteDimensional.lean

tactic: have h := rank_eq_of_injective _ hinj
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
f : V →ₗ[K] V
hinj : Injective ↑f
⊢ Surjective ↑f

tactic: rw [← finrank_eq_rank, ← finrank_eq_rank, natCast_inj] at h
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
f : V →ₗ[K] V
hinj : Injective ↑f
h : Module.rank K V = Module.rank K { x // x ∈ range f }
⊢ Surjective ↑f

tactic: exact range_eq_top.1 (eq_top_of_finrank_eq h.symm)
state_before: K : Type u
V : Type v
inst✝⁵ : DivisionRing K
inst✝⁴ : AddCommGroup V
inst✝³ : Module K V
V₂ : Type v'
inst✝² : AddCommGroup V₂
inst✝¹ : Module K V₂
inst✝ : FiniteDimensional K V
f : V →ₗ[K] V
hinj : Injective ↑f
h : finrank K V = finrank K { x // x ∈ range f }
⊢ Surjective ↑f
Theorem: Homotopy.nullHomotopicMap_f_of_not_rel_left
File: Mathlib/Algebra/Homology/Homotopy.lean

tactic: dsimp only [nullHomotopicMap]
state_before: ι : Type u_1
V : Type u
inst✝¹ : Category V
inst✝ : Preadditive V
c : ComplexShape ι
C D E : HomologicalComplex V c
f g : C ⟶ D
h k : D ⟶ E
i k₁ k₀ : ι
r₁₀ : ComplexShape.Rel c k₁ k₀
hk₀ : ∀ (l : ι), ¬ComplexShape.Rel c k₀ l
hom : (i j : ι) → X C i ⟶ X D j
⊢ Hom.f (nullHomotopicMap hom) k₀ = hom k₀ k₁ ≫ d D k₁ k₀

tactic: rw [prevD_eq hom r₁₀, dNext, AddMonoidHom.mk'_apply, C.shape, zero_comp, zero_add]
state_before: ι : Type u_1
V : Type u
inst✝¹ : Category V
inst✝ : Preadditive V
c : ComplexShape ι
C D E : HomologicalComplex V c
f g : C ⟶ D
h k : D ⟶ E
i k₁ k₀ : ι
r₁₀ : ComplexShape.Rel c k₁ k₀
hk₀ : ∀ (l : ι), ¬ComplexShape.Rel c k₀ l
hom : (i j : ι) → X C i ⟶ X D j
⊢ ↑(dNext k₀) hom + ↑(prevD k₀) hom = hom k₀ k₁ ≫ d D k₁ k₀

tactic: exact hk₀ _
state_before: case a
ι : Type u_1
V : Type u
inst✝¹ : Category V
inst✝ : Preadditive V
c : ComplexShape ι
C D E : HomologicalComplex V c
f g : C ⟶ D
h k : D ⟶ E
i k₁ k₀ : ι
r₁₀ : ComplexShape.Rel c k₁ k₀
hk₀ : ∀ (l : ι), ¬ComplexShape.Rel c k₀ l
hom : (i j : ι) → X C i ⟶ X D j
⊢ ¬ComplexShape.Rel c k₀ (ComplexShape.next c k₀)
Theorem: Real.log_rpow
File: Mathlib/Analysis/SpecialFunctions/Pow/Real.lean

tactic: apply exp_injective
state_before: x✝ y✝ z x : ℝ
hx : 0 < x
y : ℝ
⊢ log (x ^ y) = y * log x

tactic: rw [exp_log (rpow_pos_of_pos hx y), ← exp_log hx, mul_comm, rpow_def_of_pos (exp_pos (log x)) y]
state_before: case a
x✝ y✝ z x : ℝ
hx : 0 < x
y : ℝ
⊢ exp (log (x ^ y)) = exp (y * log x)
Theorem: Projectivization.Subspace.span_sup
File: Mathlib/LinearAlgebra/ProjectiveSpace/Subspace.lean

tactic: rw [span_union, span_coe]
state_before: K : Type u_2
V : Type u_1
inst✝² : Field K
inst✝¹ : AddCommGroup V
inst✝ : Module K V
S : Set (ℙ K V)
W : Subspace K V
⊢ span S ⊔ W = span (S ∪ ↑W)
Theorem: det_rotation
File: Mathlib/Analysis/Complex/Isometry.lean

tactic: rw [← LinearMap.det_toMatrix basisOneI, toMatrix_rotation, Matrix.det_fin_two]
state_before: a : { x // x ∈ circle }
⊢ ↑LinearMap.det ↑(↑rotation a).toLinearEquiv = 1

tactic: simp [← normSq_apply]
state_before: a : { x // x ∈ circle }
⊢ ↑(Matrix.planeConformalMatrix (↑a).re (↑a).im (_ : (↑a).re ^ 2 + (↑a).im ^ 2 ≠ 0)) 0 0 *
        ↑(Matrix.planeConformalMatrix (↑a).re (↑a).im (_ : (↑a).re ^ 2 + (↑a).im ^ 2 ≠ 0)) 1 1 -
      ↑(Matrix.planeConformalMatrix (↑a).re (↑a).im (_ : (↑a).re ^ 2 + (↑a).im ^ 2 ≠ 0)) 0 1 *
        ↑(Matrix.planeConformalMatrix (↑a).re (↑a).im (_ : (↑a).re ^ 2 + (↑a).im ^ 2 ≠ 0)) 1 0 =
    1
Theorem: SimpleGraph.Walk.exists_cons_eq_concat
File: Mathlib/Combinatorics/SimpleGraph/Connectivity.lean

tactic: induction p generalizing u with
| nil => exact ⟨_, nil, h, rfl⟩
| cons h' p ih =>
  obtain ⟨y, q, h'', hc⟩ := ih h'
  refine' ⟨y, cons h q, h'', _⟩
  rw [concat_cons, hc]
state_before: V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
u v w : V
h : Adj G u v
p : Walk G v w
⊢ ∃ x q h', cons h p = concat q h'

tactic: exact ⟨_, nil, h, rfl⟩
state_before: case nil
V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
v w u✝ u : V
h : Adj G u u✝
⊢ ∃ x q h', cons h nil = concat q h'

tactic: obtain ⟨y, q, h'', hc⟩ := ih h'
state_before: case cons
V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
v w u✝ v✝ w✝ : V
h' : Adj G u✝ v✝
p : Walk G v✝ w✝
ih : ∀ {u : V} (h : Adj G u v✝), ∃ x q h', cons h p = concat q h'
u : V
h : Adj G u u✝
⊢ ∃ x q h'_1, cons h (cons h' p) = concat q h'_1

tactic: refine' ⟨y, cons h q, h'', _⟩
state_before: case cons.intro.intro.intro
V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
v w u✝ v✝ w✝ : V
h' : Adj G u✝ v✝
p : Walk G v✝ w✝
ih : ∀ {u : V} (h : Adj G u v✝), ∃ x q h', cons h p = concat q h'
u : V
h : Adj G u u✝
y : V
q : Walk G u✝ y
h'' : Adj G y w✝
hc : cons h' p = concat q h''
⊢ ∃ x q h'_1, cons h (cons h' p) = concat q h'_1

tactic: rw [concat_cons, hc]
state_before: case cons.intro.intro.intro
V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
v w u✝ v✝ w✝ : V
h' : Adj G u✝ v✝
p : Walk G v✝ w✝
ih : ∀ {u : V} (h : Adj G u v✝), ∃ x q h', cons h p = concat q h'
u : V
h : Adj G u u✝
y : V
q : Walk G u✝ y
h'' : Adj G y w✝
hc : cons h' p = concat q h''
⊢ cons h (cons h' p) = concat (cons h q) h''
Theorem: MeasureTheory.OuterMeasure.trim_eq_iInf
File: Mathlib/MeasureTheory/Measure/OuterMeasure.lean

tactic: simp (config := { singlePass := true }) only [iInf_comm]
state_before: α : Type u_1
inst✝ : MeasurableSpace α
m : OuterMeasure α
s : Set α
⊢ ↑(trim m) s = ⨅ (t : Set α) (_ : s ⊆ t) (_ : MeasurableSet t), ↑m t

tactic: exact
  inducedOuterMeasure_eq_iInf MeasurableSet.iUnion (fun f _ => m.iUnion_nat f)
    (fun _ _ _ _ h => m.mono h) s
state_before: α : Type u_1
inst✝ : MeasurableSpace α
m : OuterMeasure α
s : Set α
⊢ ↑(trim m) s = ⨅ (t : Set α) (_ : MeasurableSet t) (_ : s ⊆ t), ↑m t
Theorem: DirectedOn.exists_mem_subset_of_finset_subset_biUnion
File: Mathlib/Data/Finset/Basic.lean

tactic: rw [Set.biUnion_eq_iUnion] at hs
state_before: α✝ : Type ?u.171200
β : Type ?u.171203
γ : Type ?u.171206
inst✝ : DecidableEq α✝
s✝ s₁ s₂ t t₁ t₂ u v : Finset α✝
a b : α✝
α : Type u_1
ι : Type u_2
f : ι → Set α
c : Set ι
hn : Set.Nonempty c
hc : DirectedOn (fun i j => f i ⊆ f j) c
s : Finset α
hs : ↑s ⊆ ⋃ (i : ι) (_ : i ∈ c), f i
⊢ ∃ i, i ∈ c ∧ ↑s ⊆ f i

tactic: haveI := hn.coe_sort
state_before: α✝ : Type ?u.171200
β : Type ?u.171203
γ : Type ?u.171206
inst✝ : DecidableEq α✝
s✝ s₁ s₂ t t₁ t₂ u v : Finset α✝
a b : α✝
α : Type u_1
ι : Type u_2
f : ι → Set α
c : Set ι
hn : Set.Nonempty c
hc : DirectedOn (fun i j => f i ⊆ f j) c
s : Finset α
hs : ↑s ⊆ ⋃ (x : ↑c), f ↑x
⊢ ∃ i, i ∈ c ∧ ↑s ⊆ f i

tactic: obtain ⟨⟨i, hic⟩, hi⟩ :=
  (directed_comp.2 hc.directed_val).exists_mem_subset_of_finset_subset_biUnion hs
state_before: α✝ : Type ?u.171200
β : Type ?u.171203
γ : Type ?u.171206
inst✝ : DecidableEq α✝
s✝ s₁ s₂ t t₁ t₂ u v : Finset α✝
a b : α✝
α : Type u_1
ι : Type u_2
f : ι → Set α
c : Set ι
hn : Set.Nonempty c
hc : DirectedOn (fun i j => f i ⊆ f j) c
s : Finset α
hs : ↑s ⊆ ⋃ (x : ↑c), f ↑x
this : Nonempty ↑c
⊢ ∃ i, i ∈ c ∧ ↑s ⊆ f i

tactic: exact ⟨i, hic, hi⟩
state_before: case intro.mk
α✝ : Type ?u.171200
β : Type ?u.171203
γ : Type ?u.171206
inst✝ : DecidableEq α✝
s✝ s₁ s₂ t t₁ t₂ u v : Finset α✝
a b : α✝
α : Type u_1
ι : Type u_2
f : ι → Set α
c : Set ι
hn : Set.Nonempty c
hc : DirectedOn (fun i j => f i ⊆ f j) c
s : Finset α
hs : ↑s ⊆ ⋃ (x : ↑c), f ↑x
this : Nonempty ↑c
i : ι
hic : i ∈ c
hi : ↑s ⊆ ((fun j => f j) ∘ Subtype.val) { val := i, property := hic }
⊢ ∃ i, i ∈ c ∧ ↑s ⊆ f i
Theorem: Homeomorph.isOpen_image
File: Mathlib/Topology/Homeomorph.lean

tactic: rw [← preimage_symm, isOpen_preimage]
state_before: α : Type u_1
β : Type u_2
γ : Type ?u.63524
δ : Type ?u.63527
inst✝³ : TopologicalSpace α
inst✝² : TopologicalSpace β
inst✝¹ : TopologicalSpace γ
inst✝ : TopologicalSpace δ
h : α ≃ₜ β
s : Set α
⊢ IsOpen (↑h '' s) ↔ IsOpen s
Theorem: Mathlib.Tactic.RingNF.rat_rawCast_2
File: Mathlib/Tactic/Ring/RingNF.lean

tactic: simp
state_before: R✝ : Type ?u.79693
inst✝¹ : CommSemiring R✝
n : ℤ
d : ℕ
R : Type u_1
inst✝ : DivisionRing R
⊢ Rat.rawCast n d = ↑n / ↑d
Theorem: LowerSet.compl_iSup₂
File: Mathlib/Order/UpperLower/Basic.lean

tactic: simp_rw [LowerSet.compl_iSup]
state_before: α : Type u_1
β : Type ?u.90446
γ : Type ?u.90449
ι : Sort u_2
κ : ι → Sort u_3
inst✝ : LE α
s t : LowerSet α
a : α
f : (i : ι) → κ i → LowerSet α
⊢ compl (⨆ (i : ι) (j : κ i), f i j) = ⨆ (i : ι) (j : κ i), compl (f i j)
Theorem: RatFunc.coe_C
File: Mathlib/FieldTheory/RatFunc.lean

tactic: rw [coe_num_denom, num_C, denom_C, Polynomial.coe_C, Polynomial.coe_one,
  PowerSeries.coe_one, div_one]
state_before: K F : Type u
inst✝ : Field F
p q : F[X]
f g : RatFunc F
r : F
⊢ ↑(↑C r) = ↑HahnSeries.C r

tactic: simp only [algebraMap_eq_C, ofPowerSeries_C, C_apply]
state_before: K F : Type u
inst✝ : Field F
p q : F[X]
f g : RatFunc F
r : F
⊢ ↑(ofPowerSeries ℤ F) (↑(PowerSeries.C F) r) = ↑HahnSeries.C r
Theorem: CategoryTheory.IsIso.inv_inv
File: Mathlib/CategoryTheory/Iso.lean

tactic: apply inv_eq_of_hom_inv_id
state_before: C : Type u
inst✝¹ : Category C
X Y Z : C
f g : X ⟶ Y
h : Y ⟶ Z
inst✝ : IsIso f
⊢ inv (inv f) = f

tactic: simp
state_before: case hom_inv_id
C : Type u
inst✝¹ : Category C
X Y Z : C
f g : X ⟶ Y
h : Y ⟶ Z
inst✝ : IsIso f
⊢ inv f ≫ f = 𝟙 Y
Theorem: Interval.subset_coe_map
File: Mathlib/Order/Interval.lean

tactic: simp
state_before: α : Type u_1
β : Type u_2
γ : Type ?u.28103
δ : Type ?u.28106
ι : Sort ?u.28109
κ : ι → Sort ?u.28114
inst✝¹ : PartialOrder α
inst✝ : PartialOrder β
s t : Interval α
a b : α
f : α →o β
⊢ ↑f '' ↑⊥ ⊆ ↑(map f ⊥)
Theorem: continuous_neg'
File: Mathlib/Analysis/Normed/Order/Lattice.lean

tactic: refine continuous_pos.comp <| @continuous_neg _ _ _ TopologicalAddGroup.toContinuousNeg
state_before: α : Type u_1
inst✝ : NormedLatticeAddCommGroup α
⊢ Continuous NegPart.neg
Theorem: ENNReal.iInter_Ici_coe_nat
File: Mathlib/Data/Real/ENNReal.lean

tactic: simp only [← compl_Iio, ← compl_iUnion, iUnion_Iio_coe_nat, compl_compl]
state_before: α : Type ?u.136805
β : Type ?u.136808
a b c d : ℝ≥0∞
r p q : ℝ≥0
⊢ (⋂ (n : ℕ), Ici ↑n) = {⊤}
Theorem: FreeAbelianGroup.not_mem_support_iff
File: Mathlib/GroupTheory/FreeAbelianGroupFinsupp.lean

tactic: rw [support, Finsupp.not_mem_support_iff]
state_before: X : Type u_1
x : X
a : FreeAbelianGroup X
⊢ ¬x ∈ support a ↔ ↑(coeff x) a = 0

tactic: exact Iff.rfl
state_before: X : Type u_1
x : X
a : FreeAbelianGroup X
⊢ ↑(↑toFinsupp a) x = 0 ↔ ↑(coeff x) a = 0
Theorem: Polynomial.orderOf_root_cyclotomic_dvd
File: Mathlib/RingTheory/Polynomial/Cyclotomic/Basic.lean

tactic: apply orderOf_dvd_of_pow_eq_one
state_before: n : ℕ
hpos : 0 < n
p : ℕ
inst✝ : Fact (Nat.Prime p)
a : ℕ
hroot : IsRoot (cyclotomic n (ZMod p)) (↑(Nat.castRingHom (ZMod p)) a)
⊢ orderOf (ZMod.unitOfCoprime a (_ : Nat.coprime a p)) ∣ n

tactic: suffices hpow : eval (Nat.castRingHom (ZMod p) a) (X ^ n - 1 : (ZMod p)[X]) = 0
state_before: case h
n : ℕ
hpos : 0 < n
p : ℕ
inst✝ : Fact (Nat.Prime p)
a : ℕ
hroot : IsRoot (cyclotomic n (ZMod p)) (↑(Nat.castRingHom (ZMod p)) a)
⊢ ZMod.unitOfCoprime a (_ : Nat.coprime a p) ^ n = 1

tactic: rw [IsRoot.def] at hroot
state_before: case hpow
n : ℕ
hpos : 0 < n
p : ℕ
inst✝ : Fact (Nat.Prime p)
a : ℕ
hroot : IsRoot (cyclotomic n (ZMod p)) (↑(Nat.castRingHom (ZMod p)) a)
⊢ eval (↑(Nat.castRingHom (ZMod p)) a) (X ^ n - 1) = 0

tactic: rw [← prod_cyclotomic_eq_X_pow_sub_one hpos (ZMod p), ← Nat.cons_self_properDivisors hpos.ne',
  Finset.prod_cons, eval_mul, hroot, MulZeroClass.zero_mul]
state_before: case hpow
n : ℕ
hpos : 0 < n
p : ℕ
inst✝ : Fact (Nat.Prime p)
a : ℕ
hroot : eval (↑(Nat.castRingHom (ZMod p)) a) (cyclotomic n (ZMod p)) = 0
⊢ eval (↑(Nat.castRingHom (ZMod p)) a) (X ^ n - 1) = 0

tactic: simp only [eval_X, eval_one, eval_pow, eval_sub, eq_natCast] at hpow
state_before: case h
n : ℕ
hpos : 0 < n
p : ℕ
inst✝ : Fact (Nat.Prime p)
a : ℕ
hroot : IsRoot (cyclotomic n (ZMod p)) (↑(Nat.castRingHom (ZMod p)) a)
hpow : eval (↑(Nat.castRingHom (ZMod p)) a) (X ^ n - 1) = 0
⊢ ZMod.unitOfCoprime a (_ : Nat.coprime a p) ^ n = 1

tactic: apply Units.val_eq_one.1
state_before: case h
n : ℕ
hpos : 0 < n
p : ℕ
inst✝ : Fact (Nat.Prime p)
a : ℕ
hroot : IsRoot (cyclotomic n (ZMod p)) (↑(Nat.castRingHom (ZMod p)) a)
hpow : ↑a ^ n - 1 = 0
⊢ ZMod.unitOfCoprime a (_ : Nat.coprime a p) ^ n = 1

tactic: simp only [sub_eq_zero.mp hpow, ZMod.coe_unitOfCoprime, Units.val_pow_eq_pow_val]
state_before: case h
n : ℕ
hpos : 0 < n
p : ℕ
inst✝ : Fact (Nat.Prime p)
a : ℕ
hroot : IsRoot (cyclotomic n (ZMod p)) (↑(Nat.castRingHom (ZMod p)) a)
hpow : ↑a ^ n - 1 = 0
⊢ ↑(ZMod.unitOfCoprime a (_ : Nat.coprime a p) ^ n) = 1
Theorem: inner_neg_left
File: Mathlib/Analysis/InnerProductSpace/Basic.lean

tactic: rw [← neg_one_smul 𝕜 x, inner_smul_left]
state_before: 𝕜 : Type u_1
E : Type u_2
F : Type ?u.1722446
inst✝⁴ : IsROrC 𝕜
inst✝³ : NormedAddCommGroup E
inst✝² : InnerProductSpace 𝕜 E
inst✝¹ : NormedAddCommGroup F
inst✝ : InnerProductSpace ℝ F
dec_E : DecidableEq E
x y : E
⊢ inner (-x) y = -inner x y

tactic: simp
state_before: 𝕜 : Type u_1
E : Type u_2
F : Type ?u.1722446
inst✝⁴ : IsROrC 𝕜
inst✝³ : NormedAddCommGroup E
inst✝² : InnerProductSpace 𝕜 E
inst✝¹ : NormedAddCommGroup F
inst✝ : InnerProductSpace ℝ F
dec_E : DecidableEq E
x y : E
⊢ ↑(starRingEnd 𝕜) (-1) * inner x y = -inner x y
Theorem: Subalgebra.isField_of_algebraic
File: Mathlib/RingTheory/Algebraic.lean

tactic: infer_instance
state_before: R : Type ?u.871187
S : Type ?u.871190
inst✝⁵ : CommRing R
inst✝⁴ : IsDomain R
inst✝³ : CommRing S
K : Type u_1
L : Type u_2
inst✝² : Field K
inst✝¹ : Field L
inst✝ : Algebra K L
A : Subalgebra K L
hKL : Algebra.IsAlgebraic K L
⊢ Nontrivial { x // x ∈ A }
Theorem: Part.map_none
File: Mathlib/Data/Part.lean

tactic: simp
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.14360
f : α → β
a : β
⊢ ¬a ∈ map f none
Theorem: AddLECancellable.eq_tsub_iff_add_eq_of_le
File: Mathlib/Algebra/Order/Sub/Canonical.lean

tactic: rintro rfl
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 : α
hc : AddLECancellable c
h : c ≤ b
⊢ a = b - c → a + c = b

tactic: exact 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 α
b c d : α
hc : AddLECancellable c
h : c ≤ b
⊢ b - c + c = b
Theorem: CategoryTheory.Abelian.cokernel.desc.inv
File: Mathlib/CategoryTheory/Abelian/Exact.lean

tactic: have := isIso_cokernel_desc_of_exact_of_epi _ _ ex
state_before: C : Type u₁
inst✝² : Category C
inst✝¹ : Abelian C
X Y Z : C
f : X ⟶ Y
g : Y ⟶ Z
inst✝ : Epi g
ex : Exact f g
⊢ let_fun this := (_ : IsIso (cokernel.desc f g (_ : f ≫ g = 0)));
  g ≫ CategoryTheory.inv (cokernel.desc f g (_ : f ≫ g = 0)) = cokernel.π f

tactic: simp
state_before: C : Type u₁
inst✝² : Category C
inst✝¹ : Abelian C
X Y Z : C
f : X ⟶ Y
g : Y ⟶ Z
inst✝ : Epi g
ex : Exact f g
this : IsIso (cokernel.desc f g (_ : f ≫ g = 0))
⊢ let_fun this := (_ : IsIso (cokernel.desc f g (_ : f ≫ g = 0)));
  g ≫ CategoryTheory.inv (cokernel.desc f g (_ : f ≫ g = 0)) = cokernel.π f
Theorem: Submodule.smul_sup_le_of_le_smul_of_le_jacobson_bot
File: Mathlib/RingTheory/Nakayama.lean

tactic: rw [← sup_eq_left, smul_sup_eq_smul_sup_of_le_smul_of_le_jacobson hN' hIJ hNN, bot_smul,
  sup_bot_eq]
state_before: R : Type u_1
M : Type u_2
inst✝² : CommRing R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
I : Ideal R
N N' : Submodule R M
hN' : FG N'
hIJ : I ≤ jacobson ⊥
hNN : N ⊔ N' ≤ N ⊔ I • N'
⊢ I • N' ≤ N
Theorem: Polynomial.cast_int_comp
File: Mathlib/Data/Polynomial/Eval.lean

tactic: cases i <;> simp
state_before: R : Type u
S : Type v
T : Type w
ι : Type y
a b : R
m n : ℕ
inst✝ : Ring R
p q r : R[X]
i : ℤ
⊢ comp (↑i) p = ↑i
Theorem: Subgroup.subgroupOf_eq_top
File: Mathlib/GroupTheory/Subgroup/Basic.lean

tactic: rw [← top_subgroupOf, subgroupOf_inj, top_inf_eq, inf_eq_right]
state_before: G : Type u_1
G' : Type ?u.293254
inst✝⁴ : Group G
inst✝³ : Group G'
A : Type ?u.293263
inst✝² : AddGroup A
H✝ K✝ : Subgroup G
k : Set G
N : Type ?u.293284
inst✝¹ : Group N
P : Type ?u.293290
inst✝ : Group P
H K : Subgroup G
⊢ subgroupOf H K = ⊤ ↔ K ≤ H
Theorem: Nat.fib_gcd
File: Mathlib/Data/Nat/Fib.lean

tactic: induction m, n using Nat.gcd.induction with
| H0 => simp
| H1 m n _ h' =>
  rw [← gcd_rec m n] at h'
  conv_rhs => rw [← mod_add_div' n m]
  rwa [gcd_fib_add_mul_self m (n % m) (n / m), gcd_comm (fib m) _]
state_before: m n : ℕ
⊢ fib (gcd m n) = gcd (fib m) (fib n)

tactic: simp
state_before: case H0
n✝ : ℕ
⊢ fib (gcd 0 n✝) = gcd (fib 0) (fib n✝)

tactic: rw [← gcd_rec m n] at h'
state_before: case H1
m n : ℕ
a✝ : 0 < m
h' : fib (gcd (n % m) m) = gcd (fib (n % m)) (fib m)
⊢ fib (gcd m n) = gcd (fib m) (fib n)

tactic: conv_rhs => rw [← mod_add_div' n m]
state_before: case H1
m n : ℕ
a✝ : 0 < m
h' : fib (gcd m n) = gcd (fib (n % m)) (fib m)
⊢ fib (gcd m n) = gcd (fib m) (fib n)

tactic: rwa [gcd_fib_add_mul_self m (n % m) (n / m), gcd_comm (fib m) _]
state_before: case H1
m n : ℕ
a✝ : 0 < m
h' : fib (gcd m n) = gcd (fib (n % m)) (fib m)
⊢ fib (gcd m n) = gcd (fib m) (fib (n % m + n / m * m))
Theorem: Set.image_iInter
File: Mathlib/Data/Set/Lattice.lean

tactic: cases isEmpty_or_nonempty ι
state_before: α : Type u_1
β : Type u_2
γ : Type ?u.190319
ι : Sort u_3
ι' : Sort ?u.190325
ι₂ : Sort ?u.190328
κ : ι → Sort ?u.190333
κ₁ : ι → Sort ?u.190338
κ₂ : ι → Sort ?u.190343
κ' : ι' → Sort ?u.190348
f : α → β
hf : Bijective f
s : ι → Set α
⊢ (f '' ⋂ (i : ι), s i) = ⋂ (i : ι), f '' s i

tactic: simp_rw [iInter_of_empty, image_univ_of_surjective hf.surjective]
state_before: case inl
α : Type u_1
β : Type u_2
γ : Type ?u.190319
ι : Sort u_3
ι' : Sort ?u.190325
ι₂ : Sort ?u.190328
κ : ι → Sort ?u.190333
κ₁ : ι → Sort ?u.190338
κ₂ : ι → Sort ?u.190343
κ' : ι' → Sort ?u.190348
f : α → β
hf : Bijective f
s : ι → Set α
h✝ : IsEmpty ι
⊢ (f '' ⋂ (i : ι), s i) = ⋂ (i : ι), f '' s i

tactic: exact (hf.injective.injOn _).image_iInter_eq
state_before: case inr
α : Type u_1
β : Type u_2
γ : Type ?u.190319
ι : Sort u_3
ι' : Sort ?u.190325
ι₂ : Sort ?u.190328
κ : ι → Sort ?u.190333
κ₁ : ι → Sort ?u.190338
κ₂ : ι → Sort ?u.190343
κ' : ι' → Sort ?u.190348
f : α → β
hf : Bijective f
s : ι → Set α
h✝ : Nonempty ι
⊢ (f '' ⋂ (i : ι), s i) = ⋂ (i : ι), f '' s i
Theorem: CategoryTheory.Limits.Types.colimit_sound
File: Mathlib/CategoryTheory/Limits/Types.lean

tactic: rw [← w, Colimit.w_apply.{v, u}]
state_before: J : Type v
inst✝ : SmallCategory J
F : J ⥤ TypeMax
j j' : J
x : F.obj j
x' : F.obj j'
f : j ⟶ j'
w : F.map f x = x'
⊢ colimit.ι F j x = colimit.ι F j' x'
Theorem: Filter.frequently_comap
File: Mathlib/Order/Filter/Basic.lean

tactic: simp only [Filter.Frequently, eventually_comap, not_exists, not_and]
state_before: α : Type u
β : Type v
γ : Type w
δ : Type ?u.226477
ι : Sort x
f : α → β
l : Filter β
p : α → Prop
s : Set α
⊢ (∃ᶠ (a : α) in comap f l, p a) ↔ ∃ᶠ (b : β) in l, ∃ a, f a = b ∧ p a
Theorem: edist_le_tsum_of_edist_le_of_tendsto₀
File: Mathlib/Topology/Instances/ENNReal.lean

tactic: simpa using edist_le_tsum_of_edist_le_of_tendsto d hf ha 0
state_before: α : Type u_1
β : Type ?u.569045
γ : Type ?u.569048
inst✝ : PseudoEMetricSpace α
f : ℕ → α
d : ℕ → ℝ≥0∞
hf : ∀ (n : ℕ), edist (f n) (f (Nat.succ n)) ≤ d n
a : α
ha : Tendsto f atTop (𝓝 a)
⊢ edist (f 0) a ≤ ∑' (m : ℕ), d m
Theorem: Zspan.fract_zspan_add
File: Mathlib/Algebra/Module/Zlattice.lean

tactic: classical
refine (Basis.ext_elem_iff b).mpr fun i => ?_
simp_rw [repr_fract_apply, Int.fract_eq_fract]
use (b.restrictScalars ℤ).repr ⟨v, h⟩ i
rw [map_add, Finsupp.coe_add, Pi.add_apply, add_tsub_cancel_right,
  ← eq_intCast (algebraMap ℤ K) _, Basis.restrictScalars_repr_apply, coe_mk]
state_before: E : Type u_1
ι : Type u_2
K : Type u_3
inst✝⁴ : NormedLinearOrderedField K
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace K E
b : Basis ι K E
inst✝¹ : FloorRing K
inst✝ : Fintype ι
m v : E
h : v ∈ span ℤ (Set.range ↑b)
⊢ fract b (v + m) = fract b m

tactic: refine (Basis.ext_elem_iff b).mpr fun i => ?_
state_before: E : Type u_1
ι : Type u_2
K : Type u_3
inst✝⁴ : NormedLinearOrderedField K
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace K E
b : Basis ι K E
inst✝¹ : FloorRing K
inst✝ : Fintype ι
m v : E
h : v ∈ span ℤ (Set.range ↑b)
⊢ fract b (v + m) = fract b m

tactic: simp_rw [repr_fract_apply, Int.fract_eq_fract]
state_before: E : Type u_1
ι : Type u_2
K : Type u_3
inst✝⁴ : NormedLinearOrderedField K
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace K E
b : Basis ι K E
inst✝¹ : FloorRing K
inst✝ : Fintype ι
m v : E
h : v ∈ span ℤ (Set.range ↑b)
i : ι
⊢ ↑(↑b.repr (fract b (v + m))) i = ↑(↑b.repr (fract b m)) i

tactic: use (b.restrictScalars ℤ).repr ⟨v, h⟩ i
state_before: E : Type u_1
ι : Type u_2
K : Type u_3
inst✝⁴ : NormedLinearOrderedField K
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace K E
b : Basis ι K E
inst✝¹ : FloorRing K
inst✝ : Fintype ι
m v : E
h : v ∈ span ℤ (Set.range ↑b)
i : ι
⊢ ∃ z, ↑(↑b.repr (v + m)) i - ↑(↑b.repr m) i = ↑z

tactic: rw [map_add, Finsupp.coe_add, Pi.add_apply, add_tsub_cancel_right,
  ← eq_intCast (algebraMap ℤ K) _, Basis.restrictScalars_repr_apply, coe_mk]
state_before: E : Type u_1
ι : Type u_2
K : Type u_3
inst✝⁴ : NormedLinearOrderedField K
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace K E
b : Basis ι K E
inst✝¹ : FloorRing K
inst✝ : Fintype ι
m v : E
h : v ∈ span ℤ (Set.range ↑b)
i : ι
⊢ ↑(↑b.repr (v + m)) i - ↑(↑b.repr m) i = ↑(↑(↑(Basis.restrictScalars ℤ b).repr { val := v, property := h }) i)
Theorem: MeasureTheory.VectorMeasure.of_nonneg_disjoint_union_eq_zero
File: Mathlib/MeasureTheory/Measure/VectorMeasure.lean

tactic: rw [of_union h hA₁ hB₁] at hAB
state_before: α : Type u_1
β : Type ?u.41414
m : MeasurableSpace α
M : Type ?u.41420
inst✝² : AddCommMonoid M
inst✝¹ : TopologicalSpace M
inst✝ : T2Space M
v : VectorMeasure α M
f : ℕ → Set α
s : SignedMeasure α
A B : Set α
h : Disjoint A B
hA₁ : MeasurableSet A
hB₁ : MeasurableSet B
hA₂ : 0 ≤ ↑s A
hB₂ : 0 ≤ ↑s B
hAB : ↑s (A ∪ B) = 0
⊢ ↑s A = 0

tactic: linarith
state_before: α : Type u_1
β : Type ?u.41414
m : MeasurableSpace α
M : Type ?u.41420
inst✝² : AddCommMonoid M
inst✝¹ : TopologicalSpace M
inst✝ : T2Space M
v : VectorMeasure α M
f : ℕ → Set α
s : SignedMeasure α
A B : Set α
h : Disjoint A B
hA₁ : MeasurableSet A
hB₁ : MeasurableSet B
hA₂ : 0 ≤ ↑s A
hB₂ : 0 ≤ ↑s B
hAB : ↑s A + ↑s B = 0
⊢ ↑s A = 0
Theorem: LeftCancelMonoid.toMonoid_injective
File: Mathlib/Algebra/Group/Ext.lean

tactic: rintro @⟨@⟨⟩⟩ @⟨@⟨⟩⟩ h
state_before: M : Type u
⊢ Function.Injective (@toMonoid M)

tactic: congr <;> injection h
state_before: case mk.mk.mk.mk
M : Type u
toOne✝¹ : One M
npow✝¹ : ℕ → M → M
npow_zero✝¹ : ∀ (x : M), npow✝¹ 0 x = 1
toSemigroup✝¹ : Semigroup M
mul_left_cancel✝¹ : ∀ (a b c : M), a * b = a * c → b = c
one_mul✝¹ : ∀ (a : M), 1 * a = a
mul_one✝¹ : ∀ (a : M), a * 1 = a
npow_succ✝¹ : ∀ (n : ℕ) (x : M), npow✝¹ (n + 1) x = x * npow✝¹ n x
toOne✝ : One M
npow✝ : ℕ → M → M
npow_zero✝ : ∀ (x : M), npow✝ 0 x = 1
toSemigroup✝ : Semigroup M
mul_left_cancel✝ : ∀ (a b c : M), a * b = a * c → b = c
one_mul✝ : ∀ (a : M), 1 * a = a
mul_one✝ : ∀ (a : M), a * 1 = a
npow_succ✝ : ∀ (n : ℕ) (x : M), npow✝ (n + 1) x = x * npow✝ n x
h : toMonoid = toMonoid
⊢ mk one_mul✝¹ mul_one✝¹ npow✝¹ = mk one_mul✝ mul_one✝ npow✝