1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: CategoryTheory.finallySmall_iff_exists_small_weakly_terminal_set
File: Mathlib/CategoryTheory/Limits/FinallySmall.lean

tactic: refine ⟨fun _ => FinallySmall.exists_small_weakly_terminal_set _, fun h => ?_⟩
state_before: J : Type u
inst✝¹ : Category.{v, u} J
inst✝ : IsFilteredOrEmpty J
⊢ FinallySmall J ↔ ∃ s, ∃ (_ : Small.{v, u} ↑s), ∀ (i : J), ∃ j ∈ s, Nonempty (i ⟶ j)
state_after: J : Type u
inst✝¹ : Category.{v, u} J
inst✝ : IsFilteredOrEmpty J
h : ∃ s, ∃ (_ : Small.{v, u} ↑s), ∀ (i : J), ∃ j ∈ s, Nonempty (i ⟶ j)
⊢ FinallySmall J

tactic: rcases h with ⟨s, hs, hs'⟩
state_before: J : Type u
inst✝¹ : Category.{v, u} J
inst✝ : IsFilteredOrEmpty J
h : ∃ s, ∃ (_ : Small.{v, u} ↑s), ∀ (i : J), ∃ j ∈ s, Nonempty (i ⟶ j)
⊢ FinallySmall J
state_after: case intro.intro
J : Type u
inst✝¹ : Category.{v, u} J
inst✝ : IsFilteredOrEmpty J
s : Set J
hs : Small.{v, u} ↑s
hs' : ∀ (i : J), ∃ j ∈ s, Nonempty (i ⟶ j)
⊢ FinallySmall J

tactic: exact finallySmall_of_small_weakly_terminal_set s hs'
state_before: case intro.intro
J : Type u
inst✝¹ : Category.{v, u} J
inst✝ : IsFilteredOrEmpty J
s : Set J
hs : Small.{v, u} ↑s
hs' : ∀ (i : J), ∃ j ∈ s, Nonempty (i ⟶ j)
⊢ FinallySmall J
state_after: no goals
Theorem: Complex.Gamma_one_half_eq
File: Mathlib/Analysis/SpecialFunctions/Gaussian/GaussianIntegral.lean

tactic: convert congr_arg ((↑) : ℝ → ℂ) Real.Gamma_one_half_eq
state_before: ⊢ Gamma (1 / 2) = ↑π ^ (1 / 2)
state_after: case h.e'_2

⊢ Gamma (1 / 2) = ↑(Real.Gamma (1 / 2))

case h.e'_3

⊢ ↑π ^ (1 / 2) = ↑√π

tactic: simpa only [one_div, ofReal_inv, ofReal_ofNat] using Gamma_ofReal (1 / 2)
state_before: case h.e'_2

⊢ Gamma (1 / 2) = ↑(Real.Gamma (1 / 2))
state_after: no goals

tactic: rw [sqrt_eq_rpow, ofReal_cpow pi_pos.le, ofReal_div, ofReal_ofNat, ofReal_one]
state_before: case h.e'_3

⊢ ↑π ^ (1 / 2) = ↑√π
state_after: no goals
Theorem: IntermediateField.finSepDegree_adjoin_simple_dvd_finrank
File: Mathlib/FieldTheory/SeparableDegree.lean

tactic: by_cases halg : IsAlgebraic F α
state_before: F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
α : E
⊢ finSepDegree F ↥F⟮α⟯ ∣ finrank F ↥F⟮α⟯
state_after: case pos
F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
α : E
halg : IsAlgebraic F α
⊢ finSepDegree F ↥F⟮α⟯ ∣ finrank F ↥F⟮α⟯

case neg
F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
α : E
halg : ¬IsAlgebraic F α
⊢ finSepDegree F ↥F⟮α⟯ ∣ finrank F ↥F⟮α⟯

tactic: have : finrank F F⟮α⟯ = 0 := finrank_of_infinite_dimensional fun _ ↦
  halg ((AdjoinSimple.isIntegral_gen F α).1 (IsIntegral.of_finite F _)).isAlgebraic
state_before: case neg
F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
α : E
halg : ¬IsAlgebraic F α
⊢ finSepDegree F ↥F⟮α⟯ ∣ finrank F ↥F⟮α⟯
state_after: case neg
F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
α : E
halg : ¬IsAlgebraic F α
this : finrank F ↥F⟮α⟯ = 0
⊢ finSepDegree F ↥F⟮α⟯ ∣ finrank F ↥F⟮α⟯

tactic: rw [this]
state_before: case neg
F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
α : E
halg : ¬IsAlgebraic F α
this : finrank F ↥F⟮α⟯ = 0
⊢ finSepDegree F ↥F⟮α⟯ ∣ finrank F ↥F⟮α⟯
state_after: case neg
F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
α : E
halg : ¬IsAlgebraic F α
this : finrank F ↥F⟮α⟯ = 0
⊢ finSepDegree F ↥F⟮α⟯ ∣ 0

tactic: exact dvd_zero _
state_before: case neg
F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
α : E
halg : ¬IsAlgebraic F α
this : finrank F ↥F⟮α⟯ = 0
⊢ finSepDegree F ↥F⟮α⟯ ∣ 0
state_after: no goals

tactic: rw [finSepDegree_adjoin_simple_eq_natSepDegree F E halg, adjoin.finrank halg.isIntegral]
state_before: case pos
F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
α : E
halg : IsAlgebraic F α
⊢ finSepDegree F ↥F⟮α⟯ ∣ finrank F ↥F⟮α⟯
state_after: case pos
F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
α : E
halg : IsAlgebraic F α
⊢ (minpoly F α).natSepDegree ∣ (minpoly F α).natDegree

tactic: exact (minpoly.irreducible halg.isIntegral).natSepDegree_dvd_natDegree
state_before: case pos
F : Type u
E : Type v
inst✝⁴ : Field F
inst✝³ : Field E
inst✝² : Algebra F E
K : Type w
inst✝¹ : Field K
inst✝ : Algebra F K
α : E
halg : IsAlgebraic F α
⊢ (minpoly F α).natSepDegree ∣ (minpoly F α).natDegree
state_after: no goals
Theorem: Complex.sin_eq_one_iff
File: Mathlib/Analysis/SpecialFunctions/Trigonometric/Complex.lean

tactic: rw [← cos_sub_pi_div_two, cos_eq_one_iff]
state_before: x : ℂ
⊢ sin x = 1 ↔ ∃ k, ↑π / 2 + ↑k * (2 * ↑π) = x
state_after: x : ℂ
⊢ (∃ k, ↑k * (2 * ↑π) = x - ↑π / 2) ↔ ∃ k, ↑π / 2 + ↑k * (2 * ↑π) = x

tactic: simp only [eq_sub_iff_add_eq']
state_before: x : ℂ
⊢ (∃ k, ↑k * (2 * ↑π) = x - ↑π / 2) ↔ ∃ k, ↑π / 2 + ↑k * (2 * ↑π) = x
state_after: no goals
Theorem: Polynomial.roots_X_pow_char_pow_sub_C_pow
File: Mathlib/FieldTheory/Perfect.lean

tactic: rw [roots_pow, roots_X_pow_char_pow_sub_C, mul_smul]
state_before: R : Type u_1
inst✝³ : CommRing R
inst✝² : IsDomain R
p n : ℕ
inst✝¹ : ExpChar R p
f : R[X]
inst✝ : PerfectRing R p
y : R
m : ℕ
⊢ ((X ^ p ^ n - C y) ^ m).roots = (m * p ^ n) • {(iterateFrobeniusEquiv R p n).symm y}
state_after: no goals
Theorem: PowerSeries.constantCoeff_exp
File: Mathlib/RingTheory/PowerSeries/WellKnown.lean

tactic: rw [← coeff_zero_eq_constantCoeff_apply, coeff_exp]
state_before: A : Type u_1
A' : Type u_2
inst✝⁷ : Ring A
inst✝⁶ : Ring A'
inst✝⁵ : Algebra ℚ A
inst✝⁴ : Algebra ℚ A'
inst✝³ : Ring A
inst✝² : Ring A'
inst✝¹ : Algebra ℚ A
inst✝ : Algebra ℚ A'
n : ℕ
f : A →+* A'
⊢ (constantCoeff A) (exp A) = 1
state_after: A : Type u_1
A' : Type u_2
inst✝⁷ : Ring A
inst✝⁶ : Ring A'
inst✝⁵ : Algebra ℚ A
inst✝⁴ : Algebra ℚ A'
inst✝³ : Ring A
inst✝² : Ring A'
inst✝¹ : Algebra ℚ A
inst✝ : Algebra ℚ A'
n : ℕ
f : A →+* A'
⊢ (algebraMap ℚ A) (1 / ↑0!) = 1

tactic: simp
state_before: A : Type u_1
A' : Type u_2
inst✝⁷ : Ring A
inst✝⁶ : Ring A'
inst✝⁵ : Algebra ℚ A
inst✝⁴ : Algebra ℚ A'
inst✝³ : Ring A
inst✝² : Ring A'
inst✝¹ : Algebra ℚ A
inst✝ : Algebra ℚ A'
n : ℕ
f : A →+* A'
⊢ (algebraMap ℚ A) (1 / ↑0!) = 1
state_after: no goals
Theorem: HasDerivWithinAt.mul
File: Mathlib/Analysis/Calculus/Deriv/Mul.lean

tactic: have := (HasFDerivWithinAt.mul' hc hd).hasDerivWithinAt
state_before: 𝕜 : Type u
inst✝¹⁰ : NontriviallyNormedField 𝕜
F : Type v
inst✝⁹ : NormedAddCommGroup F
inst✝⁸ : NormedSpace 𝕜 F
E : Type w
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace 𝕜 E
G : Type u_1
inst✝⁵ : NormedAddCommGroup G
inst✝⁴ : NormedSpace 𝕜 G
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t : Set 𝕜
L L₁ L₂ : Filter 𝕜
𝕜' : Type u_2
𝔸 : Type u_3
inst✝³ : NormedField 𝕜'
inst✝² : NormedRing 𝔸
inst✝¹ : NormedAlgebra 𝕜 𝕜'
inst✝ : NormedAlgebra 𝕜 𝔸
c d : 𝕜 → 𝔸
c' d' : 𝔸
u v : 𝕜 → 𝕜'
hc : HasDerivWithinAt c c' s x
hd : HasDerivWithinAt d d' s x
⊢ HasDerivWithinAt (fun y => c y * d y) (c' * d x + c x * d') s x
state_after: 𝕜 : Type u
inst✝¹⁰ : NontriviallyNormedField 𝕜
F : Type v
inst✝⁹ : NormedAddCommGroup F
inst✝⁸ : NormedSpace 𝕜 F
E : Type w
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace 𝕜 E
G : Type u_1
inst✝⁵ : NormedAddCommGroup G
inst✝⁴ : NormedSpace 𝕜 G
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t : Set 𝕜
L L₁ L₂ : Filter 𝕜
𝕜' : Type u_2
𝔸 : Type u_3
inst✝³ : NormedField 𝕜'
inst✝² : NormedRing 𝔸
inst✝¹ : NormedAlgebra 𝕜 𝕜'
inst✝ : NormedAlgebra 𝕜 𝔸
c d : 𝕜 → 𝔸
c' d' : 𝔸
u v : 𝕜 → 𝕜'
hc : HasDerivWithinAt c c' s x
hd : HasDerivWithinAt d d' s x
this : HasDerivWithinAt (fun y => c y * d y) ((c x • smulRight 1 d' + (smulRight 1 c').smulRight (d x)) 1) s x
⊢ HasDerivWithinAt (fun y => c y * d y) (c' * d x + c x * d') s x

tactic: rwa [ContinuousLinearMap.add_apply, ContinuousLinearMap.smul_apply,
  ContinuousLinearMap.smulRight_apply, ContinuousLinearMap.smulRight_apply,
  ContinuousLinearMap.smulRight_apply, ContinuousLinearMap.one_apply, one_smul, one_smul,
  add_comm] 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
G : Type u_1
inst✝⁵ : NormedAddCommGroup G
inst✝⁴ : NormedSpace 𝕜 G
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t : Set 𝕜
L L₁ L₂ : Filter 𝕜
𝕜' : Type u_2
𝔸 : Type u_3
inst✝³ : NormedField 𝕜'
inst✝² : NormedRing 𝔸
inst✝¹ : NormedAlgebra 𝕜 𝕜'
inst✝ : NormedAlgebra 𝕜 𝔸
c d : 𝕜 → 𝔸
c' d' : 𝔸
u v : 𝕜 → 𝕜'
hc : HasDerivWithinAt c c' s x
hd : HasDerivWithinAt d d' s x
this : HasDerivWithinAt (fun y => c y * d y) ((c x • smulRight 1 d' + (smulRight 1 c').smulRight (d x)) 1) s x
⊢ HasDerivWithinAt (fun y => c y * d y) (c' * d x + c x * d') s x
state_after: no goals
Theorem: PMF.toPMF_dirac
File: Mathlib/Probability/ProbabilityMassFunction/Monad.lean

tactic: rw [toPMF_eq_iff_toMeasure_eq, toMeasure_pure]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
a a' : α
s : Set α
inst✝¹ : MeasurableSpace α
inst✝ : Countable α
h : MeasurableSingletonClass α
⊢ (Measure.dirac a).toPMF = pure a
state_after: no goals
Theorem: exists_open_nhds_one_mul_subset
File: Mathlib/Topology/Algebra/Monoid.lean

tactic: simpa only [mul_subset_iff] using exists_open_nhds_one_split hU
state_before: ι : Type u_1
α : Type u_2
M : Type u_3
N : Type u_4
X : Type u_5
inst✝³ : TopologicalSpace X
inst✝² : TopologicalSpace M
inst✝¹ : MulOneClass M
inst✝ : ContinuousMul M
U : Set M
hU : U ∈ 𝓝 1
⊢ ∃ V, IsOpen V ∧ 1 ∈ V ∧ V * V ⊆ U
state_after: no goals
Theorem: Submodule.comap_liftQ
File: Mathlib/LinearAlgebra/Quotient.lean

tactic: rintro ⟨x⟩ hx
state_before: R : Type u_1
M : Type u_2
r : R
x y : M
inst✝⁵ : Ring R
inst✝⁴ : AddCommGroup M
inst✝³ : Module R M
p p' : Submodule R M
R₂ : Type u_3
M₂ : Type u_4
inst✝² : Ring R₂
inst✝¹ : AddCommGroup M₂
inst✝ : Module R₂ M₂
τ₁₂ : R →+* R₂
q : Submodule R₂ M₂
f : M →ₛₗ[τ₁₂] M₂
h : p ≤ ker f
⊢ comap (p.liftQ f h) q ≤ map p.mkQ (comap f q)
state_after: case mk
R : Type u_1
M : Type u_2
r : R
x✝¹ y : M
inst✝⁵ : Ring R
inst✝⁴ : AddCommGroup M
inst✝³ : Module R M
p p' : Submodule R M
R₂ : Type u_3
M₂ : Type u_4
inst✝² : Ring R₂
inst✝¹ : AddCommGroup M₂
inst✝ : Module R₂ M₂
τ₁₂ : R →+* R₂
q : Submodule R₂ M₂
f : M →ₛₗ[τ₁₂] M₂
h : p ≤ ker f
x✝ : M ⧸ p
x : M
hx : Quot.mk Setoid.r x ∈ comap (p.liftQ f h) q
⊢ Quot.mk Setoid.r x ∈ map p.mkQ (comap f q)

tactic: exact ⟨_, hx, rfl⟩
state_before: case mk
R : Type u_1
M : Type u_2
r : R
x✝¹ y : M
inst✝⁵ : Ring R
inst✝⁴ : AddCommGroup M
inst✝³ : Module R M
p p' : Submodule R M
R₂ : Type u_3
M₂ : Type u_4
inst✝² : Ring R₂
inst✝¹ : AddCommGroup M₂
inst✝ : Module R₂ M₂
τ₁₂ : R →+* R₂
q : Submodule R₂ M₂
f : M →ₛₗ[τ₁₂] M₂
h : p ≤ ker f
x✝ : M ⧸ p
x : M
hx : Quot.mk Setoid.r x ∈ comap (p.liftQ f h) q
⊢ Quot.mk Setoid.r x ∈ map p.mkQ (comap f q)
state_after: no goals

tactic: rw [map_le_iff_le_comap, ← comap_comp, liftQ_mkQ]
state_before: R : Type u_1
M : Type u_2
r : R
x y : M
inst✝⁵ : Ring R
inst✝⁴ : AddCommGroup M
inst✝³ : Module R M
p p' : Submodule R M
R₂ : Type u_3
M₂ : Type u_4
inst✝² : Ring R₂
inst✝¹ : AddCommGroup M₂
inst✝ : Module R₂ M₂
τ₁₂ : R →+* R₂
q : Submodule R₂ M₂
f : M →ₛₗ[τ₁₂] M₂
h : p ≤ ker f
⊢ map p.mkQ (comap f q) ≤ comap (p.liftQ f h) q
state_after: no goals
Theorem: CategoryTheory.MonoidalCategory.tensor_hom_inv_id'
File: Mathlib/CategoryTheory/Monoidal/Category.lean

tactic: rw [← tensor_comp, IsIso.hom_inv_id]
state_before: C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝³ : MonoidalCategory C✝
C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : MonoidalCategory C
U V✝ W✝ X✝ Y✝ Z✝ V W X Y Z : C
f : V ⟶ W
inst✝ : IsIso f
g : X ⟶ Y
h : Y ⟶ Z
⊢ (g ⊗ f) ≫ (h ⊗ inv f) = (g ⊗ 𝟙 V) ≫ (h ⊗ 𝟙 V)
state_after: C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝³ : MonoidalCategory C✝
C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : MonoidalCategory C
U V✝ W✝ X✝ Y✝ Z✝ V W X Y Z : C
f : V ⟶ W
inst✝ : IsIso f
g : X ⟶ Y
h : Y ⟶ Z
⊢ g ≫ h ⊗ 𝟙 V = (g ⊗ 𝟙 V) ≫ (h ⊗ 𝟙 V)

tactic: simp [tensorHom_id]
state_before: C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝³ : MonoidalCategory C✝
C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : MonoidalCategory C
U V✝ W✝ X✝ Y✝ Z✝ V W X Y Z : C
f : V ⟶ W
inst✝ : IsIso f
g : X ⟶ Y
h : Y ⟶ Z
⊢ g ≫ h ⊗ 𝟙 V = (g ⊗ 𝟙 V) ≫ (h ⊗ 𝟙 V)
state_after: no goals
Theorem: unitInterval.qRight_zero_left
File: Mathlib/Topology/Homotopy/HSpaces.lean

tactic: simp only [coe_zero, mul_zero, zero_div, le_refl]
state_before: θ : ↑I
⊢ 2 * ↑(0, θ).1 / (1 + ↑(0, θ).2) ≤ 0
state_after: no goals
Theorem: IsSMulRegular.not_zero_iff
File: Mathlib/Algebra/Regular/SMul.lean

tactic: rw [nontrivial_iff, not_iff_comm, zero_iff_subsingleton, subsingleton_iff]
state_before: R : Type u_1
S : Type u_2
M : Type u_3
a b : R
s : S
inst✝⁶ : MonoidWithZero R
inst✝⁵ : MonoidWithZero S
inst✝⁴ : Zero M
inst✝³ : MulActionWithZero R M
inst✝² : MulActionWithZero R S
inst✝¹ : MulActionWithZero S M
inst✝ : IsScalarTower R S M
⊢ ¬IsSMulRegular M 0 ↔ Nontrivial M
state_after: R : Type u_1
S : Type u_2
M : Type u_3
a b : R
s : S
inst✝⁶ : MonoidWithZero R
inst✝⁵ : MonoidWithZero S
inst✝⁴ : Zero M
inst✝³ : MulActionWithZero R M
inst✝² : MulActionWithZero R S
inst✝¹ : MulActionWithZero S M
inst✝ : IsScalarTower R S M
⊢ (¬∃ x y, x ≠ y) ↔ ∀ (x y : M), x = y

tactic: push_neg
state_before: R : Type u_1
S : Type u_2
M : Type u_3
a b : R
s : S
inst✝⁶ : MonoidWithZero R
inst✝⁵ : MonoidWithZero S
inst✝⁴ : Zero M
inst✝³ : MulActionWithZero R M
inst✝² : MulActionWithZero R S
inst✝¹ : MulActionWithZero S M
inst✝ : IsScalarTower R S M
⊢ (¬∃ x y, x ≠ y) ↔ ∀ (x y : M), x = y
state_after: R : Type u_1
S : Type u_2
M : Type u_3
a b : R
s : S
inst✝⁶ : MonoidWithZero R
inst✝⁵ : MonoidWithZero S
inst✝⁴ : Zero M
inst✝³ : MulActionWithZero R M
inst✝² : MulActionWithZero R S
inst✝¹ : MulActionWithZero S M
inst✝ : IsScalarTower R S M
⊢ (∀ (x y : M), x = y) ↔ ∀ (x y : M), x = y

tactic: exact Iff.rfl
state_before: R : Type u_1
S : Type u_2
M : Type u_3
a b : R
s : S
inst✝⁶ : MonoidWithZero R
inst✝⁵ : MonoidWithZero S
inst✝⁴ : Zero M
inst✝³ : MulActionWithZero R M
inst✝² : MulActionWithZero R S
inst✝¹ : MulActionWithZero S M
inst✝ : IsScalarTower R S M
⊢ (∀ (x y : M), x = y) ↔ ∀ (x y : M), x = y
state_after: no goals
Theorem: Submodule.mulLeftMap_eq_mulRightMap_of_commute
File: Mathlib/LinearAlgebra/Finsupp.lean

tactic: ext i n
state_before: R : Type u_1
M✝ : Type u_2
N✝ : Type u_3
inst✝⁹ : Semiring R
inst✝⁸ : AddCommMonoid M✝
inst✝⁷ : Module R M✝
inst✝⁶ : AddCommMonoid N✝
inst✝⁵ : Module R N✝
S : Type u_4
inst✝⁴ : Semiring S
inst✝³ : Module R S
inst✝² : SMulCommClass R R S
inst✝¹ : SMulCommClass R S S
inst✝ : IsScalarTower R S S
M N : Submodule R S
ι : Type u_5
m : ι → ↥M
hc : ∀ (i : ι) (n : ↥N), Commute ↑(m i) ↑n
⊢ mulLeftMap N m = N.mulRightMap m
state_after: case h.h
R : Type u_1
M✝ : Type u_2
N✝ : Type u_3
inst✝⁹ : Semiring R
inst✝⁸ : AddCommMonoid M✝
inst✝⁷ : Module R M✝
inst✝⁶ : AddCommMonoid N✝
inst✝⁵ : Module R N✝
S : Type u_4
inst✝⁴ : Semiring S
inst✝³ : Module R S
inst✝² : SMulCommClass R R S
inst✝¹ : SMulCommClass R S S
inst✝ : IsScalarTower R S S
M N : Submodule R S
ι : Type u_5
m : ι → ↥M
hc : ∀ (i : ι) (n : ↥N), Commute ↑(m i) ↑n
i : ι
n : ↥N
⊢ (mulLeftMap N m ∘ₗ Finsupp.lsingle i) n = (N.mulRightMap m ∘ₗ Finsupp.lsingle i) n

tactic: simp [(hc i n).eq]
state_before: case h.h
R : Type u_1
M✝ : Type u_2
N✝ : Type u_3
inst✝⁹ : Semiring R
inst✝⁸ : AddCommMonoid M✝
inst✝⁷ : Module R M✝
inst✝⁶ : AddCommMonoid N✝
inst✝⁵ : Module R N✝
S : Type u_4
inst✝⁴ : Semiring S
inst✝³ : Module R S
inst✝² : SMulCommClass R R S
inst✝¹ : SMulCommClass R S S
inst✝ : IsScalarTower R S S
M N : Submodule R S
ι : Type u_5
m : ι → ↥M
hc : ∀ (i : ι) (n : ↥N), Commute ↑(m i) ↑n
i : ι
n : ↥N
⊢ (mulLeftMap N m ∘ₗ Finsupp.lsingle i) n = (N.mulRightMap m ∘ₗ Finsupp.lsingle i) n
state_after: no goals
Theorem: max_le
File: Mathlib/Init/Order/LinearOrder.lean

tactic: if h : a ≤ b
then simp [max_def, if_pos h]; exact h₂
else simp [max_def, if_neg h]; exact h₁
state_before: α : Type u
inst✝ : LinearOrder α
a b c : α
h₁ : a ≤ c
h₂ : b ≤ c
⊢ max a b ≤ c
state_after: no goals

tactic: simp [max_def, if_pos h]
state_before: α : Type u
inst✝ : LinearOrder α
a b c : α
h₁ : a ≤ c
h₂ : b ≤ c
h : a ≤ b
⊢ max a b ≤ c
state_after: α : Type u
inst✝ : LinearOrder α
a b c : α
h₁ : a ≤ c
h₂ : b ≤ c
h : a ≤ b
⊢ b ≤ c

tactic: exact h₂
state_before: α : Type u
inst✝ : LinearOrder α
a b c : α
h₁ : a ≤ c
h₂ : b ≤ c
h : a ≤ b
⊢ b ≤ c
state_after: no goals

tactic: simp [max_def, if_neg h]
state_before: α : Type u
inst✝ : LinearOrder α
a b c : α
h₁ : a ≤ c
h₂ : b ≤ c
h : ¬a ≤ b
⊢ max a b ≤ c
state_after: α : Type u
inst✝ : LinearOrder α
a b c : α
h₁ : a ≤ c
h₂ : b ≤ c
h : ¬a ≤ b
⊢ a ≤ c

tactic: exact h₁
state_before: α : Type u
inst✝ : LinearOrder α
a b c : α
h₁ : a ≤ c
h₂ : b ≤ c
h : ¬a ≤ b
⊢ a ≤ c
state_after: no goals
Theorem: SimpleGraph.Iso.symm_apply_reachable
File: Mathlib/Combinatorics/SimpleGraph/Connectivity.lean

tactic: rw [← Iso.reachable_iff, RelIso.apply_symm_apply]
state_before: V : Type u
V' : Type v
V'' : Type w
G✝ : SimpleGraph V
G'✝ : SimpleGraph V'
G'' : SimpleGraph V''
G : SimpleGraph V
G' : SimpleGraph V'
φ : G ≃g G'
u : V
v : V'
⊢ G.Reachable (φ.symm v) u ↔ G'.Reachable v (φ u)
state_after: no goals
Theorem: List.unzip_swap
File: Mathlib/Data/List/Zip.lean

tactic: simp only [unzip_eq_map, map_map]
state_before: α : Type u
β : Type u_1
γ : Type u_2
δ : Type u_3
ε : Type u_4
l : List (α × β)
⊢ (map Prod.swap l).unzip = l.unzip.swap
state_after: α : Type u
β : Type u_1
γ : Type u_2
δ : Type u_3
ε : Type u_4
l : List (α × β)
⊢ (map (Prod.fst ∘ Prod.swap) l, map (Prod.snd ∘ Prod.swap) l) = (map Prod.fst l, map Prod.snd l).swap

tactic: rfl
state_before: α : Type u
β : Type u_1
γ : Type u_2
δ : Type u_3
ε : Type u_4
l : List (α × β)
⊢ (map (Prod.fst ∘ Prod.swap) l, map (Prod.snd ∘ Prod.swap) l) = (map Prod.fst l, map Prod.snd l).swap
state_after: no goals
Theorem: Function.Injective.swap_apply
File: Mathlib/Logic/Equiv/Basic.lean

tactic: by_cases hx:z = x
state_before: α : Sort u_1
β : Sort u_2
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
f : α → β
hf : Injective f
x y z : α
⊢ (Equiv.swap (f x) (f y)) (f z) = f ((Equiv.swap x y) z)
state_after: case pos
α : Sort u_1
β : Sort u_2
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
f : α → β
hf : Injective f
x y z : α
hx : z = x
⊢ (Equiv.swap (f x) (f y)) (f z) = f ((Equiv.swap x y) z)

case neg
α : Sort u_1
β : Sort u_2
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
f : α → β
hf : Injective f
x y z : α
hx : ¬z = x
⊢ (Equiv.swap (f x) (f y)) (f z) = f ((Equiv.swap x y) z)

tactic: by_cases hy:z = y
state_before: case neg
α : Sort u_1
β : Sort u_2
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
f : α → β
hf : Injective f
x y z : α
hx : ¬z = x
⊢ (Equiv.swap (f x) (f y)) (f z) = f ((Equiv.swap x y) z)
state_after: case pos
α : Sort u_1
β : Sort u_2
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
f : α → β
hf : Injective f
x y z : α
hx : ¬z = x
hy : z = y
⊢ (Equiv.swap (f x) (f y)) (f z) = f ((Equiv.swap x y) z)

case neg
α : Sort u_1
β : Sort u_2
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
f : α → β
hf : Injective f
x y z : α
hx : ¬z = x
hy : ¬z = y
⊢ (Equiv.swap (f x) (f y)) (f z) = f ((Equiv.swap x y) z)

tactic: rw [Equiv.swap_apply_of_ne_of_ne hx hy, Equiv.swap_apply_of_ne_of_ne (hf.ne hx) (hf.ne hy)]
state_before: case neg
α : Sort u_1
β : Sort u_2
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
f : α → β
hf : Injective f
x y z : α
hx : ¬z = x
hy : ¬z = y
⊢ (Equiv.swap (f x) (f y)) (f z) = f ((Equiv.swap x y) z)
state_after: no goals

tactic: simp [hx]
state_before: case pos
α : Sort u_1
β : Sort u_2
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
f : α → β
hf : Injective f
x y z : α
hx : z = x
⊢ (Equiv.swap (f x) (f y)) (f z) = f ((Equiv.swap x y) z)
state_after: no goals

tactic: simp [hy]
state_before: case pos
α : Sort u_1
β : Sort u_2
inst✝¹ : DecidableEq α
inst✝ : DecidableEq β
f : α → β
hf : Injective f
x y z : α
hx : ¬z = x
hy : z = y
⊢ (Equiv.swap (f x) (f y)) (f z) = f ((Equiv.swap x y) z)
state_after: no goals
Theorem: Function.Embedding.exists_of_card_le_finset
File: Mathlib/Data/Fintype/Card.lean

tactic: rw [← Fintype.card_coe] at h
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : Fintype α
s : Finset β
h : Fintype.card α ≤ s.card
⊢ ∃ f, Set.range ⇑f ⊆ ↑s
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : Fintype α
s : Finset β
h : Fintype.card α ≤ Fintype.card { x // x ∈ s }
⊢ ∃ f, Set.range ⇑f ⊆ ↑s

tactic: rcases nonempty_of_card_le h with ⟨f⟩
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : Fintype α
s : Finset β
h : Fintype.card α ≤ Fintype.card { x // x ∈ s }
⊢ ∃ f, Set.range ⇑f ⊆ ↑s
state_after: case intro
α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : Fintype α
s : Finset β
h : Fintype.card α ≤ Fintype.card { x // x ∈ s }
f : α ↪ { x // x ∈ s }
⊢ ∃ f, Set.range ⇑f ⊆ ↑s

tactic: exact ⟨f.trans (Embedding.subtype _), by simp [Set.range_subset_iff]⟩
state_before: case intro
α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : Fintype α
s : Finset β
h : Fintype.card α ≤ Fintype.card { x // x ∈ s }
f : α ↪ { x // x ∈ s }
⊢ ∃ f, Set.range ⇑f ⊆ ↑s
state_after: no goals

tactic: simp [Set.range_subset_iff]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : Fintype α
s : Finset β
h : Fintype.card α ≤ Fintype.card { x // x ∈ s }
f : α ↪ { x // x ∈ s }
⊢ Set.range ⇑(f.trans (subtype fun x => x ∈ s)) ⊆ ↑s
state_after: no goals
Theorem: Ordinal.cof_lsub_le
File: Mathlib/SetTheory/Cardinal/Cofinality.lean

tactic: rw [cof_eq_sInf_lsub]
state_before: α : Type u_1
r : α → α → Prop
ι : Type u
f : ι → Ordinal.{u}
⊢ (lsub f).cof ≤ #ι
state_after: α : Type u_1
r : α → α → Prop
ι : Type u
f : ι → Ordinal.{u}
⊢ sInf {a | ∃ ι_1 f_1, lsub f_1 = lsub f ∧ #ι_1 = a} ≤ #ι

tactic: exact csInf_le' ⟨ι, f, rfl, rfl⟩
state_before: α : Type u_1
r : α → α → Prop
ι : Type u
f : ι → Ordinal.{u}
⊢ sInf {a | ∃ ι_1 f_1, lsub f_1 = lsub f ∧ #ι_1 = a} ≤ #ι
state_after: no goals
Theorem: GeneralizedContinuedFraction.compExactValue_correctness_of_stream_eq_some_aux_comp
File: Mathlib/Algebra/ContinuedFractions/Computation/CorrectnessTerminating.lean

tactic: field_simp [fract_a_ne_zero]
state_before: K : Type u_1
inst✝¹ : LinearOrderedField K
v : K
n : ℕ
inst✝ : FloorRing K
a b c : K
fract_a_ne_zero : Int.fract a ≠ 0
⊢ (↑⌊a⌋ * b + c) / Int.fract a + b = (b * a + c) / Int.fract a
state_after: K : Type u_1
inst✝¹ : LinearOrderedField K
v : K
n : ℕ
inst✝ : FloorRing K
a b c : K
fract_a_ne_zero : Int.fract a ≠ 0
⊢ ↑⌊a⌋ * b + c + b * Int.fract a = b * a + c

tactic: rw [Int.fract]
state_before: K : Type u_1
inst✝¹ : LinearOrderedField K
v : K
n : ℕ
inst✝ : FloorRing K
a b c : K
fract_a_ne_zero : Int.fract a ≠ 0
⊢ ↑⌊a⌋ * b + c + b * Int.fract a = b * a + c
state_after: K : Type u_1
inst✝¹ : LinearOrderedField K
v : K
n : ℕ
inst✝ : FloorRing K
a b c : K
fract_a_ne_zero : Int.fract a ≠ 0
⊢ ↑⌊a⌋ * b + c + b * (a - ↑⌊a⌋) = b * a + c

tactic: ring
state_before: K : Type u_1
inst✝¹ : LinearOrderedField K
v : K
n : ℕ
inst✝ : FloorRing K
a b c : K
fract_a_ne_zero : Int.fract a ≠ 0
⊢ ↑⌊a⌋ * b + c + b * (a - ↑⌊a⌋) = b * a + c
state_after: no goals