1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: AlgebraicGeometry.Scheme.OpenCover.hom_ext
File: Mathlib/AlgebraicGeometry/Gluing.lean

tactic: rw [← cancel_epi 𝒰.fromGlued]
state_before: X : Scheme
𝒰 : X.OpenCover
Y : Scheme
f₁ f₂ : X ⟶ Y
h : ∀ (x : 𝒰.J), 𝒰.map x ≫ f₁ = 𝒰.map x ≫ f₂
⊢ f₁ = f₂
state_after: X : Scheme
𝒰 : X.OpenCover
Y : Scheme
f₁ f₂ : X ⟶ Y
h : ∀ (x : 𝒰.J), 𝒰.map x ≫ f₁ = 𝒰.map x ≫ f₂
⊢ 𝒰.fromGlued ≫ f₁ = 𝒰.fromGlued ≫ f₂

tactic: apply Multicoequalizer.hom_ext
state_before: X : Scheme
𝒰 : X.OpenCover
Y : Scheme
f₁ f₂ : X ⟶ Y
h : ∀ (x : 𝒰.J), 𝒰.map x ≫ f₁ = 𝒰.map x ≫ f₂
⊢ 𝒰.fromGlued ≫ f₁ = 𝒰.fromGlued ≫ f₂
state_after: case h
X : Scheme
𝒰 : X.OpenCover
Y : Scheme
f₁ f₂ : X ⟶ Y
h : ∀ (x : 𝒰.J), 𝒰.map x ≫ f₁ = 𝒰.map x ≫ f₂
⊢ ∀ (b : 𝒰.gluedCover.diagram.R),
    Multicoequalizer.π 𝒰.gluedCover.diagram b ≫ 𝒰.fromGlued ≫ f₁ =
      Multicoequalizer.π 𝒰.gluedCover.diagram b ≫ 𝒰.fromGlued ≫ f₂

tactic: intro x
state_before: case h
X : Scheme
𝒰 : X.OpenCover
Y : Scheme
f₁ f₂ : X ⟶ Y
h : ∀ (x : 𝒰.J), 𝒰.map x ≫ f₁ = 𝒰.map x ≫ f₂
⊢ ∀ (b : 𝒰.gluedCover.diagram.R),
    Multicoequalizer.π 𝒰.gluedCover.diagram b ≫ 𝒰.fromGlued ≫ f₁ =
      Multicoequalizer.π 𝒰.gluedCover.diagram b ≫ 𝒰.fromGlued ≫ f₂
state_after: case h
X : Scheme
𝒰 : X.OpenCover
Y : Scheme
f₁ f₂ : X ⟶ Y
h : ∀ (x : 𝒰.J), 𝒰.map x ≫ f₁ = 𝒰.map x ≫ f₂
x : 𝒰.gluedCover.diagram.R
⊢ Multicoequalizer.π 𝒰.gluedCover.diagram x ≫ 𝒰.fromGlued ≫ f₁ =
    Multicoequalizer.π 𝒰.gluedCover.diagram x ≫ 𝒰.fromGlued ≫ f₂

tactic: erw [Multicoequalizer.π_desc_assoc]
state_before: case h
X : Scheme
𝒰 : X.OpenCover
Y : Scheme
f₁ f₂ : X ⟶ Y
h : ∀ (x : 𝒰.J), 𝒰.map x ≫ f₁ = 𝒰.map x ≫ f₂
x : 𝒰.gluedCover.diagram.R
⊢ Multicoequalizer.π 𝒰.gluedCover.diagram x ≫ 𝒰.fromGlued ≫ f₁ =
    Multicoequalizer.π 𝒰.gluedCover.diagram x ≫ 𝒰.fromGlued ≫ f₂
state_after: case h
X : Scheme
𝒰 : X.OpenCover
Y : Scheme
f₁ f₂ : X ⟶ Y
h : ∀ (x : 𝒰.J), 𝒰.map x ≫ f₁ = 𝒰.map x ≫ f₂
x : 𝒰.gluedCover.diagram.R
⊢ 𝒰.map x ≫ f₁ = Multicoequalizer.π 𝒰.gluedCover.diagram x ≫ 𝒰.fromGlued ≫ f₂

tactic: erw [Multicoequalizer.π_desc_assoc]
state_before: case h
X : Scheme
𝒰 : X.OpenCover
Y : Scheme
f₁ f₂ : X ⟶ Y
h : ∀ (x : 𝒰.J), 𝒰.map x ≫ f₁ = 𝒰.map x ≫ f₂
x : 𝒰.gluedCover.diagram.R
⊢ 𝒰.map x ≫ f₁ = Multicoequalizer.π 𝒰.gluedCover.diagram x ≫ 𝒰.fromGlued ≫ f₂
state_after: case h
X : Scheme
𝒰 : X.OpenCover
Y : Scheme
f₁ f₂ : X ⟶ Y
h : ∀ (x : 𝒰.J), 𝒰.map x ≫ f₁ = 𝒰.map x ≫ f₂
x : 𝒰.gluedCover.diagram.R
⊢ 𝒰.map x ≫ f₁ = 𝒰.map x ≫ f₂

tactic: exact h x
state_before: case h
X : Scheme
𝒰 : X.OpenCover
Y : Scheme
f₁ f₂ : X ⟶ Y
h : ∀ (x : 𝒰.J), 𝒰.map x ≫ f₁ = 𝒰.map x ≫ f₂
x : 𝒰.gluedCover.diagram.R
⊢ 𝒰.map x ≫ f₁ = 𝒰.map x ≫ f₂
state_after: no goals
Theorem: IsUnit.mul_eq_mul_of_div_eq_div
File: Mathlib/Algebra/Group/Units.lean

tactic: rw [← mul_one a, ← hb.div_self, ← mul_comm_div, h, div_mul_eq_mul_div, hd.div_mul_cancel]
state_before: α : Type u
M : Type u_1
N : Type u_2
inst✝ : DivisionCommMonoid α
a✝ b c✝ d : α
hb : IsUnit b
hd : IsUnit d
a c : α
h : a / b = c / d
⊢ a * d = c * b
state_after: no goals
Theorem: CochainComplex.HomComplex.Cochain.comp_id
File: Mathlib/Algebra/Homology/HomotopyCategory/HomComplex.lean

tactic: ext p q hpq
state_before: C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
R : Type u_1
inst✝¹ : Ring R
inst✝ : Linear R C
F G K L : CochainComplex C ℤ
n✝ m n : ℤ
z₁ : Cochain F G n
⊢ z₁.comp (ofHom (𝟙 G)) ⋯ = z₁
state_after: case h
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
R : Type u_1
inst✝¹ : Ring R
inst✝ : Linear R C
F G K L : CochainComplex C ℤ
n✝ m n : ℤ
z₁ : Cochain F G n
p q : ℤ
hpq : p + n = q
⊢ (z₁.comp (ofHom (𝟙 G)) ⋯).v p q hpq = z₁.v p q hpq

tactic: simp only [comp_zero_cochain_v, ofHom_v, HomologicalComplex.id_f, comp_id]
state_before: case h
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
R : Type u_1
inst✝¹ : Ring R
inst✝ : Linear R C
F G K L : CochainComplex C ℤ
n✝ m n : ℤ
z₁ : Cochain F G n
p q : ℤ
hpq : p + n = q
⊢ (z₁.comp (ofHom (𝟙 G)) ⋯).v p q hpq = z₁.v p q hpq
state_after: no goals
Theorem: Set.ite_empty_right
File: Mathlib/Data/Set/Basic.lean

tactic: simp [Set.ite]
state_before: α : Type u
β : Type v
γ : Type w
ι : Sort x
a b : α
s✝ s₁ s₂ t✝ t₁ t₂ u t s : Set α
⊢ t.ite s ∅ = s ∩ t
state_after: no goals
Theorem: List.perm_append_singleton
File: .lake/packages/batteries/Batteries/Data/List/Perm.lean

tactic: rw [append_nil]
state_before: α : Type u_1
a : α
l : List α
⊢ a :: (l ++ []) ~ a :: l
state_after: no goals
Theorem: Turing.PartrecToTM2.contSupp_fix
File: Mathlib/Computability/TMToPartrec.lean

tactic: simp (config := { contextual := true }) [codeSupp, codeSupp', contSupp, Finset.union_assoc,
  Finset.subset_iff]
state_before: f : Code
k : Cont'
⊢ contSupp (Cont'.fix f k) = codeSupp f (Cont'.fix f k)
state_after: no goals
Theorem: PadicInt.denseRange_intCast
File: Mathlib/NumberTheory/Padics/RingHoms.lean

tactic: intro x
state_before: p : ℕ
hp_prime : Fact (Nat.Prime p)
r : ℚ
x : ℤ_[p]
⊢ DenseRange Int.cast
state_after: p : ℕ
hp_prime : Fact (Nat.Prime p)
r : ℚ
x✝ x : ℤ_[p]
⊢ x ∈ closure (Set.range Int.cast)

tactic: refine DenseRange.induction_on denseRange_natCast x ?_ ?_
state_before: p : ℕ
hp_prime : Fact (Nat.Prime p)
r : ℚ
x✝ x : ℤ_[p]
⊢ x ∈ closure (Set.range Int.cast)
state_after: case refine_1
p : ℕ
hp_prime : Fact (Nat.Prime p)
r : ℚ
x✝ x : ℤ_[p]
⊢ IsClosed {b | b ∈ closure (Set.range Int.cast)}

case refine_2
p : ℕ
hp_prime : Fact (Nat.Prime p)
r : ℚ
x✝ x : ℤ_[p]
⊢ ∀ (a : ℕ), ↑a ∈ closure (Set.range Int.cast)

tactic: exact isClosed_closure
state_before: case refine_1
p : ℕ
hp_prime : Fact (Nat.Prime p)
r : ℚ
x✝ x : ℤ_[p]
⊢ IsClosed {b | b ∈ closure (Set.range Int.cast)}
state_after: no goals

tactic: intro a
state_before: case refine_2
p : ℕ
hp_prime : Fact (Nat.Prime p)
r : ℚ
x✝ x : ℤ_[p]
⊢ ∀ (a : ℕ), ↑a ∈ closure (Set.range Int.cast)
state_after: case refine_2
p : ℕ
hp_prime : Fact (Nat.Prime p)
r : ℚ
x✝ x : ℤ_[p]
a : ℕ
⊢ ↑a ∈ closure (Set.range Int.cast)

tactic: apply subset_closure
state_before: case refine_2
p : ℕ
hp_prime : Fact (Nat.Prime p)
r : ℚ
x✝ x : ℤ_[p]
a : ℕ
⊢ ↑a ∈ closure (Set.range Int.cast)
state_after: case refine_2.a
p : ℕ
hp_prime : Fact (Nat.Prime p)
r : ℚ
x✝ x : ℤ_[p]
a : ℕ
⊢ ↑a ∈ Set.range Int.cast

tactic: exact Set.mem_range_self _
state_before: case refine_2.a
p : ℕ
hp_prime : Fact (Nat.Prime p)
r : ℚ
x✝ x : ℤ_[p]
a : ℕ
⊢ ↑a ∈ Set.range Int.cast
state_after: no goals
Theorem: Submodule.torsionBy_one
File: Mathlib/Algebra/Module/Torsion.lean

tactic: rw [mem_torsionBy_iff, one_smul] at h
state_before: R : Type u_1
M : Type u_2
inst✝² : CommSemiring R
inst✝¹ : AddCommMonoid M
inst✝ : Module R M
s : Set R
a : R
x✝ : M
h : x✝ ∈ torsionBy R M 1
⊢ x✝ ∈ ⊥
state_after: R : Type u_1
M : Type u_2
inst✝² : CommSemiring R
inst✝¹ : AddCommMonoid M
inst✝ : Module R M
s : Set R
a : R
x✝ : M
h : x✝ = 0
⊢ x✝ ∈ ⊥

tactic: exact h
state_before: R : Type u_1
M : Type u_2
inst✝² : CommSemiring R
inst✝¹ : AddCommMonoid M
inst✝ : Module R M
s : Set R
a : R
x✝ : M
h : x✝ = 0
⊢ x✝ ∈ ⊥
state_after: no goals
Theorem: Finset.powersetCard_empty_subsingleton
File: Mathlib/Data/Finset/Powerset.lean

tactic: simp [Set.Subsingleton, subset_empty]
state_before: α : Type u_1
s✝ t✝ : Finset α
n✝ : ?m.14806
s t : Finset α
n : ℕ
⊢ (↑(powersetCard n ∅)).Subsingleton
state_after: no goals
Theorem: Even.isSquare_zpow
File: Mathlib/Algebra/Group/Even.lean

tactic: rintro ⟨n, rfl⟩ a
state_before: F : Type u_1
α : Type u_2
β : Type u_3
R : Type u_4
inst✝ : Group α
n : ℤ
⊢ Even n → ∀ (a : α), IsSquare (a ^ n)
state_after: case intro
F : Type u_1
α : Type u_2
β : Type u_3
R : Type u_4
inst✝ : Group α
n : ℤ
a : α
⊢ IsSquare (a ^ (n + n))

tactic: exact ⟨a ^ n, zpow_add _ _ _⟩
state_before: case intro
F : Type u_1
α : Type u_2
β : Type u_3
R : Type u_4
inst✝ : Group α
n : ℤ
a : α
⊢ IsSquare (a ^ (n + n))
state_after: no goals
Theorem: CochainComplex.shiftFunctorAdd'_eq
File: Mathlib/Algebra/Homology/HomotopyCategory/Shift.lean

tactic: ext
state_before: C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
D : Type u'
inst✝¹ : Category.{v', u'} D
inst✝ : Preadditive D
a b c : ℤ
h : a + b = c
⊢ CategoryTheory.shiftFunctorAdd' (CochainComplex C ℤ) a b c h = shiftFunctorAdd' C a b c h
state_after: case w.w.h.h
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
D : Type u'
inst✝¹ : Category.{v', u'} D
inst✝ : Preadditive D
a b c : ℤ
h : a + b = c
x✝ : CochainComplex C ℤ
i✝ : ℤ
⊢ ((CategoryTheory.shiftFunctorAdd' (CochainComplex C ℤ) a b c h).hom.app x✝).f i✝ =
    ((shiftFunctorAdd' C a b c h).hom.app x✝).f i✝

tactic: simp only [shiftFunctorAdd'_hom_app_f', XIsoOfEq, eqToIso.hom, shiftFunctorAdd'_hom_app_f]
state_before: case w.w.h.h
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
D : Type u'
inst✝¹ : Category.{v', u'} D
inst✝ : Preadditive D
a b c : ℤ
h : a + b = c
x✝ : CochainComplex C ℤ
i✝ : ℤ
⊢ ((CategoryTheory.shiftFunctorAdd' (CochainComplex C ℤ) a b c h).hom.app x✝).f i✝ =
    ((shiftFunctorAdd' C a b c h).hom.app x✝).f i✝
state_after: no goals
Theorem: Polynomial.IsUnitTrinomial.ne_zero
File: Mathlib/Algebra/Polynomial/UnitTrinomial.lean

tactic: rintro rfl
state_before: p q : ℤ[X]
hp : p.IsUnitTrinomial
⊢ p ≠ 0
state_after: q : ℤ[X]
hp : IsUnitTrinomial 0
⊢ False

tactic: exact Nat.zero_ne_bit1 1 hp.card_support_eq_three
state_before: q : ℤ[X]
hp : IsUnitTrinomial 0
⊢ False
state_after: no goals
Theorem: Submonoid.LocalizationMap.lift_mul_left
File: Mathlib/GroupTheory/MonoidLocalization.lean

tactic: rw [mul_comm, lift_mul_right]
state_before: M : Type u_1
inst✝² : CommMonoid M
S : Submonoid M
N : Type u_2
inst✝¹ : CommMonoid N
P : Type u_3
inst✝ : CommMonoid P
f : S.LocalizationMap N
g : M →* P
hg : ∀ (y : ↥S), IsUnit (g ↑y)
z : N
⊢ g ↑(f.sec z).2 * (f.lift hg) z = g (f.sec z).1
state_after: no goals
Theorem: CliffordAlgebra.range_ι_le_evenOdd_one
File: Mathlib/LinearAlgebra/CliffordAlgebra/Grading.lean

tactic: refine le_trans ?_ (le_iSup _ ⟨1, Nat.cast_one⟩)
state_before: R : Type u_1
M : Type u_2
inst✝² : CommRing R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
Q : QuadraticForm R M
⊢ LinearMap.range (ι Q) ≤ evenOdd Q 1
state_after: R : Type u_1
M : Type u_2
inst✝² : CommRing R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
Q : QuadraticForm R M
⊢ LinearMap.range (ι Q) ≤ LinearMap.range (ι Q) ^ ↑⟨1, ⋯⟩

tactic: exact (pow_one _).ge
state_before: R : Type u_1
M : Type u_2
inst✝² : CommRing R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
Q : QuadraticForm R M
⊢ LinearMap.range (ι Q) ≤ LinearMap.range (ι Q) ^ ↑⟨1, ⋯⟩
state_after: no goals
Theorem: Matrix.conjTranspose_zero
File: Mathlib/Data/Matrix/Basic.lean

tactic: simp
state_before: l : Type u_1
m : Type u_2
n : Type u_3
o : Type u_4
m' : o → Type u_5
n' : o → Type u_6
R : Type u_7
S : Type u_8
α : Type v
β : Type w
γ : Type u_9
inst✝¹ : AddMonoid α
inst✝ : StarAddMonoid α
⊢ ∀ (i : n) (j : m), 0ᴴ i j = 0 i j
state_after: no goals
Theorem: thickenedIndicatorAux_le_one
File: Mathlib/Topology/MetricSpace/ThickenedIndicator.lean

tactic: apply @tsub_le_self _ _ _ _ (1 : ℝ≥0∞)
state_before: α : Type u_1
inst✝ : PseudoEMetricSpace α
δ : ℝ
E : Set α
x : α
⊢ thickenedIndicatorAux δ E x ≤ 1
state_after: no goals
Theorem: Subalgebra.toSubring_injective
File: Mathlib/Algebra/Algebra/Subalgebra/Basic.lean

tactic: rw [← mem_toSubring, ← mem_toSubring, h]
state_before: R' : Type u'
R✝ : Type u
A✝ : Type v
B : Type w
C : Type w'
inst✝⁹ : CommSemiring R✝
inst✝⁸ : Semiring A✝
inst✝⁷ : Algebra R✝ A✝
inst✝⁶ : Semiring B
inst✝⁵ : Algebra R✝ B
inst✝⁴ : Semiring C
inst✝³ : Algebra R✝ C
S✝ : Subalgebra R✝ A✝
R : Type u
A : Type v
inst✝² : CommRing R
inst✝¹ : Ring A
inst✝ : Algebra R A
S T : Subalgebra R A
h : S.toSubring = T.toSubring
x : A
⊢ x ∈ S ↔ x ∈ T
state_after: no goals
Theorem: Submonoid.LocalizationMap.mk'_mul_cancel_right
File: Mathlib/GroupTheory/MonoidLocalization.lean

tactic: rw [← mul_mk'_one_eq_mk', f.toMap.map_mul, mul_assoc, mul_mk'_one_eq_mk', mk'_self', mul_one]
state_before: M : Type u_1
inst✝² : CommMonoid M
S : Submonoid M
N : Type u_2
inst✝¹ : CommMonoid N
P : Type u_3
inst✝ : CommMonoid P
f : S.LocalizationMap N
x : M
y : ↥S
⊢ f.mk' (x * ↑y) y = f.toMap x
state_after: no goals
Theorem: SemiconjBy.one_right
File: Mathlib/Algebra/Group/Semiconj/Defs.lean

tactic: rw [SemiconjBy, mul_one, one_mul]
state_before: S : Type u_1
M : Type u_2
G : Type u_3
inst✝ : MulOneClass M
a : M
⊢ SemiconjBy a 1 1
state_after: no goals
Theorem: DirectSum.coe_mul_of_apply
File: Mathlib/Algebra/DirectSum/Internal.lean

tactic: split_ifs with h
state_before: ι : Type u_1
σ : Type u_2
S : Type u_3
R : Type u_4
inst✝⁹ : DecidableEq ι
inst✝⁸ : Semiring R
inst✝⁷ : SetLike σ R
inst✝⁶ : AddSubmonoidClass σ R
A : ι → σ
inst✝⁵ : CanonicallyOrderedAddCommMonoid ι
inst✝⁴ : SetLike.GradedMonoid A
inst✝³ : Sub ι
inst✝² : OrderedSub ι
inst✝¹ : ContravariantClass ι ι (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
r : ⨁ (i : ι), ↥(A i)
i : ι
r' : ↥(A i)
n : ι
inst✝ : Decidable (i ≤ n)
⊢ ↑((r * (of (fun i => ↥(A i)) i) r') n) = if i ≤ n then ↑(r (n - i)) * ↑r' else 0
state_after: case pos
ι : Type u_1
σ : Type u_2
S : Type u_3
R : Type u_4
inst✝⁹ : DecidableEq ι
inst✝⁸ : Semiring R
inst✝⁷ : SetLike σ R
inst✝⁶ : AddSubmonoidClass σ R
A : ι → σ
inst✝⁵ : CanonicallyOrderedAddCommMonoid ι
inst✝⁴ : SetLike.GradedMonoid A
inst✝³ : Sub ι
inst✝² : OrderedSub ι
inst✝¹ : ContravariantClass ι ι (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
r : ⨁ (i : ι), ↥(A i)
i : ι
r' : ↥(A i)
n : ι
inst✝ : Decidable (i ≤ n)
h : i ≤ n
⊢ ↑((r * (of (fun i => ↥(A i)) i) r') n) = ↑(r (n - i)) * ↑r'

case neg
ι : Type u_1
σ : Type u_2
S : Type u_3
R : Type u_4
inst✝⁹ : DecidableEq ι
inst✝⁸ : Semiring R
inst✝⁷ : SetLike σ R
inst✝⁶ : AddSubmonoidClass σ R
A : ι → σ
inst✝⁵ : CanonicallyOrderedAddCommMonoid ι
inst✝⁴ : SetLike.GradedMonoid A
inst✝³ : Sub ι
inst✝² : OrderedSub ι
inst✝¹ : ContravariantClass ι ι (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
r : ⨁ (i : ι), ↥(A i)
i : ι
r' : ↥(A i)
n : ι
inst✝ : Decidable (i ≤ n)
h : ¬i ≤ n
⊢ ↑((r * (of (fun i => ↥(A i)) i) r') n) = 0

tactic: exacts [coe_mul_of_apply_of_le _ _ _ n h, coe_mul_of_apply_of_not_le _ _ _ n h]
state_before: case pos
ι : Type u_1
σ : Type u_2
S : Type u_3
R : Type u_4
inst✝⁹ : DecidableEq ι
inst✝⁸ : Semiring R
inst✝⁷ : SetLike σ R
inst✝⁶ : AddSubmonoidClass σ R
A : ι → σ
inst✝⁵ : CanonicallyOrderedAddCommMonoid ι
inst✝⁴ : SetLike.GradedMonoid A
inst✝³ : Sub ι
inst✝² : OrderedSub ι
inst✝¹ : ContravariantClass ι ι (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
r : ⨁ (i : ι), ↥(A i)
i : ι
r' : ↥(A i)
n : ι
inst✝ : Decidable (i ≤ n)
h : i ≤ n
⊢ ↑((r * (of (fun i => ↥(A i)) i) r') n) = ↑(r (n - i)) * ↑r'

case neg
ι : Type u_1
σ : Type u_2
S : Type u_3
R : Type u_4
inst✝⁹ : DecidableEq ι
inst✝⁸ : Semiring R
inst✝⁷ : SetLike σ R
inst✝⁶ : AddSubmonoidClass σ R
A : ι → σ
inst✝⁵ : CanonicallyOrderedAddCommMonoid ι
inst✝⁴ : SetLike.GradedMonoid A
inst✝³ : Sub ι
inst✝² : OrderedSub ι
inst✝¹ : ContravariantClass ι ι (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
r : ⨁ (i : ι), ↥(A i)
i : ι
r' : ↥(A i)
n : ι
inst✝ : Decidable (i ≤ n)
h : ¬i ≤ n
⊢ ↑((r * (of (fun i => ↥(A i)) i) r') n) = 0
state_after: no goals
Theorem: Matrix.mul_nonsing_inv
File: Mathlib/LinearAlgebra/Matrix/NonsingularInverse.lean

tactic: cases (A.isUnit_iff_isUnit_det.mpr h).nonempty_invertible
state_before: l : Type u_1
m : Type u
n : Type u'
α : Type v
inst✝² : Fintype n
inst✝¹ : DecidableEq n
inst✝ : CommRing α
A B : Matrix n n α
h : IsUnit A.det
⊢ A * A⁻¹ = 1
state_after: case intro
l : Type u_1
m : Type u
n : Type u'
α : Type v
inst✝² : Fintype n
inst✝¹ : DecidableEq n
inst✝ : CommRing α
A B : Matrix n n α
h : IsUnit A.det
val✝ : Invertible A
⊢ A * A⁻¹ = 1

tactic: rw [← invOf_eq_nonsing_inv, mul_invOf_self]
state_before: case intro
l : Type u_1
m : Type u
n : Type u'
α : Type v
inst✝² : Fintype n
inst✝¹ : DecidableEq n
inst✝ : CommRing α
A B : Matrix n n α
h : IsUnit A.det
val✝ : Invertible A
⊢ A * A⁻¹ = 1
state_after: no goals
Theorem: ppow_mul_comm
File: Mathlib/Algebra/Group/PNatPowAssoc.lean

tactic: simp only [← ppow_add, add_comm]
state_before: M : Type u_1
inst✝² : Mul M
inst✝¹ : Pow M ℕ+
inst✝ : PNatPowAssoc M
m n : ℕ+
x : M
⊢ x ^ m * x ^ n = x ^ n * x ^ m
state_after: no goals
Theorem: irrational_sqrt_ratCast_iff
File: Mathlib/Data/Real/Irrational.lean

tactic: obtain hq | hq := le_or_lt 0 q
state_before: q : ℚ
⊢ Irrational √↑q ↔ ¬IsSquare q ∧ 0 ≤ q
state_after: case inl
q : ℚ
hq : 0 ≤ q
⊢ Irrational √↑q ↔ ¬IsSquare q ∧ 0 ≤ q

case inr
q : ℚ
hq : q < 0
⊢ Irrational √↑q ↔ ¬IsSquare q ∧ 0 ≤ q

tactic: simp_rw [irrational_sqrt_ratCast_iff_of_nonneg hq, and_iff_left hq]
state_before: case inl
q : ℚ
hq : 0 ≤ q
⊢ Irrational √↑q ↔ ¬IsSquare q ∧ 0 ≤ q
state_after: no goals

tactic: rw [sqrt_eq_zero_of_nonpos (Rat.cast_nonpos.2 hq.le)]
state_before: case inr
q : ℚ
hq : q < 0
⊢ Irrational √↑q ↔ ¬IsSquare q ∧ 0 ≤ q
state_after: case inr
q : ℚ
hq : q < 0
⊢ Irrational 0 ↔ ¬IsSquare q ∧ 0 ≤ q

tactic: simp_rw [not_irrational_zero, false_iff, not_and, not_le, hq, implies_true]
state_before: case inr
q : ℚ
hq : q < 0
⊢ Irrational 0 ↔ ¬IsSquare q ∧ 0 ≤ q
state_after: no goals
Theorem: irrational_mul_int_iff
File: Mathlib/Data/Real/Irrational.lean

tactic: rw [← cast_intCast, irrational_mul_rat_iff, Int.cast_ne_zero]
state_before: q : ℚ
m : ℤ
n : ℕ
x : ℝ
⊢ Irrational (x * ↑m) ↔ m ≠ 0 ∧ Irrational x
state_after: no goals
Theorem: EReal.tendsto_toReal
File: Mathlib/Topology/Instances/EReal.lean

tactic: lift a to ℝ using ⟨ha, h'a⟩
state_before: α : Type u_1
inst✝ : TopologicalSpace α
a : EReal
ha : a ≠ ⊤
h'a : a ≠ ⊥
⊢ Tendsto toReal (𝓝 a) (𝓝 a.toReal)
state_after: case intro
α : Type u_1
inst✝ : TopologicalSpace α
a : ℝ
ha : ↑a ≠ ⊤
h'a : ↑a ≠ ⊥
⊢ Tendsto toReal (𝓝 ↑a) (𝓝 (↑a).toReal)

tactic: rw [nhds_coe, tendsto_map'_iff]
state_before: case intro
α : Type u_1
inst✝ : TopologicalSpace α
a : ℝ
ha : ↑a ≠ ⊤
h'a : ↑a ≠ ⊥
⊢ Tendsto toReal (𝓝 ↑a) (𝓝 (↑a).toReal)
state_after: case intro
α : Type u_1
inst✝ : TopologicalSpace α
a : ℝ
ha : ↑a ≠ ⊤
h'a : ↑a ≠ ⊥
⊢ Tendsto (toReal ∘ Real.toEReal) (𝓝 a) (𝓝 (↑a).toReal)

tactic: exact tendsto_id
state_before: case intro
α : Type u_1
inst✝ : TopologicalSpace α
a : ℝ
ha : ↑a ≠ ⊤
h'a : ↑a ≠ ⊥
⊢ Tendsto (toReal ∘ Real.toEReal) (𝓝 a) (𝓝 (↑a).toReal)
state_after: no goals
Theorem: UFModel.Models.push
File: Mathlib/Data/UnionFind.lean

tactic: intro H
state_before: case g
α : Type u_1
arr : Array (UFNode α)
n : ℕ
m : UFModel n
H : Models arr m
k : ℕ
hk : k = n + 1
x : α
⊢ (Agrees arr (fun x => x.rank) fun i => m.rank ↑i) →
    Agrees (arr.push { parent := n, value := x, rank := 0 }) (fun x => x.rank) fun i => (m.push k ⋯).rank ↑i
state_after: case g
α : Type u_1
arr : Array (UFNode α)
n : ℕ
m : UFModel n
H✝ : Models arr m
k : ℕ
hk : k = n + 1
x : α
H : Agrees arr (fun x => x.rank) fun i => m.rank ↑i
⊢ Agrees (arr.push { parent := n, value := x, rank := 0 }) (fun x => x.rank) fun i => (m.push k ⋯).rank ↑i

tactic: refine H.push _ hk _ _ (fun i h ↦ ?_) (fun h ↦ ?_) <;>
simp [UFModel.push, h, lt_irrefl]
state_before: case g
α : Type u_1
arr : Array (UFNode α)
n : ℕ
m : UFModel n
H✝ : Models arr m
k : ℕ
hk : k = n + 1
x : α
H : Agrees arr (fun x => x.rank) fun i => m.rank ↑i
⊢ Agrees (arr.push { parent := n, value := x, rank := 0 }) (fun x => x.rank) fun i => (m.push k ⋯).rank ↑i
state_after: no goals
Theorem: ZMod.neg_eq_self_mod_two
File: Mathlib/Data/ZMod/Basic.lean

tactic: fin_cases a <;> apply Fin.ext <;> simp [Fin.coe_neg, Int.natMod]
state_before: a : ZMod 2
⊢ -a = a
state_after: case tail.head.h

⊢ ↑(-1) = 1

tactic: rfl
state_before: case tail.head.h

⊢ ↑(-1) = 1
state_after: no goals
Theorem: MeasurableSet.const_smul₀
File: Mathlib/MeasureTheory/Group/Pointwise.lean

tactic: rcases eq_or_ne a 0 with (rfl | ha)
state_before: G₀ : Type u_1
α : Type u_2
inst✝⁶ : GroupWithZero G₀
inst✝⁵ : Zero α
inst✝⁴ : MulActionWithZero G₀ α
inst✝³ : MeasurableSpace G₀
inst✝² : MeasurableSpace α
inst✝¹ : MeasurableSMul G₀ α
inst✝ : MeasurableSingletonClass α
s : Set α
hs : MeasurableSet s
a : G₀
⊢ MeasurableSet (a • s)
state_after: case inl
G₀ : Type u_1
α : Type u_2
inst✝⁶ : GroupWithZero G₀
inst✝⁵ : Zero α
inst✝⁴ : MulActionWithZero G₀ α
inst✝³ : MeasurableSpace G₀
inst✝² : MeasurableSpace α
inst✝¹ : MeasurableSMul G₀ α
inst✝ : MeasurableSingletonClass α
s : Set α
hs : MeasurableSet s
⊢ MeasurableSet (0 • s)

case inr
G₀ : Type u_1
α : Type u_2
inst✝⁶ : GroupWithZero G₀
inst✝⁵ : Zero α
inst✝⁴ : MulActionWithZero G₀ α
inst✝³ : MeasurableSpace G₀
inst✝² : MeasurableSpace α
inst✝¹ : MeasurableSMul G₀ α
inst✝ : MeasurableSingletonClass α
s : Set α
hs : MeasurableSet s
a : G₀
ha : a ≠ 0
⊢ MeasurableSet (a • s)

tactic: exacts [(subsingleton_zero_smul_set s).measurableSet, hs.const_smul_of_ne_zero ha]
state_before: case inl
G₀ : Type u_1
α : Type u_2
inst✝⁶ : GroupWithZero G₀
inst✝⁵ : Zero α
inst✝⁴ : MulActionWithZero G₀ α
inst✝³ : MeasurableSpace G₀
inst✝² : MeasurableSpace α
inst✝¹ : MeasurableSMul G₀ α
inst✝ : MeasurableSingletonClass α
s : Set α
hs : MeasurableSet s
⊢ MeasurableSet (0 • s)

case inr
G₀ : Type u_1
α : Type u_2
inst✝⁶ : GroupWithZero G₀
inst✝⁵ : Zero α
inst✝⁴ : MulActionWithZero G₀ α
inst✝³ : MeasurableSpace G₀
inst✝² : MeasurableSpace α
inst✝¹ : MeasurableSMul G₀ α
inst✝ : MeasurableSingletonClass α
s : Set α
hs : MeasurableSet s
a : G₀
ha : a ≠ 0
⊢ MeasurableSet (a • s)
state_after: no goals
Theorem: squarefree_iff_irreducible_sq_not_dvd_of_exists_irreducible
File: Mathlib/Algebra/Squarefree/Basic.lean

tactic: rw [irreducible_sq_not_dvd_iff_eq_zero_and_no_irreducibles_or_squarefree, ← not_exists]
state_before: R : Type u_1
inst✝¹ : CommMonoidWithZero R
inst✝ : WfDvdMonoid R
r : R
hr : ∃ x, Irreducible x
⊢ Squarefree r ↔ ∀ (x : R), Irreducible x → ¬x * x ∣ r
state_after: R : Type u_1
inst✝¹ : CommMonoidWithZero R
inst✝ : WfDvdMonoid R
r : R
hr : ∃ x, Irreducible x
⊢ Squarefree r ↔ (r = 0 ∧ ¬∃ x, Irreducible x) ∨ Squarefree r

tactic: simp only [hr, not_true, false_or_iff, and_false_iff]
state_before: R : Type u_1
inst✝¹ : CommMonoidWithZero R
inst✝ : WfDvdMonoid R
r : R
hr : ∃ x, Irreducible x
⊢ Squarefree r ↔ (r = 0 ∧ ¬∃ x, Irreducible x) ∨ Squarefree r
state_after: no goals
Theorem: ClosedEmbedding.sigmaCompactSpace
File: Mathlib/Topology/Compactness/SigmaCompact.lean

tactic: rw [← preimage_iUnion, iUnion_compactCovering, preimage_univ]
state_before: X : Type u_1
Y : Type u_2
ι : Type u_3
inst✝² : TopologicalSpace X
inst✝¹ : TopologicalSpace Y
s t : Set X
inst✝ : SigmaCompactSpace X
e : Y → X
he : ClosedEmbedding e
⊢ ⋃ n, (fun n => e ⁻¹' compactCovering X n) n = univ
state_after: no goals
Theorem: ZNum.zneg_zneg
File: Mathlib/Data/Num/Lemmas.lean

tactic: cases n <;> rfl
state_before: α : Type u_1
n : ZNum
⊢ - -n = n
state_after: no goals