1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: PNat.Coprime.factor_eq_gcd_left
File: Mathlib/Data/PNat/Prime.lean

tactic: rw [gcd_eq_left_iff_dvd] at am
state_before: a b m n : ℕ+
cop : m.Coprime n
am : a ∣ m
bn : b ∣ n
⊢ a = (a * b).gcd m
state_after: a b m n : ℕ+
cop : m.Coprime n
am : a.gcd m = a
bn : b ∣ n
⊢ a = (a * b).gcd m

tactic: conv_lhs => rw [← am]
state_before: a b m n : ℕ+
cop : m.Coprime n
am : a.gcd m = a
bn : b ∣ n
⊢ a = (a * b).gcd m
state_after: a b m n : ℕ+
cop : m.Coprime n
am : a.gcd m = a
bn : b ∣ n
⊢ a.gcd m = (a * b).gcd m

tactic: rw [eq_comm]
state_before: a b m n : ℕ+
cop : m.Coprime n
am : a.gcd m = a
bn : b ∣ n
⊢ a.gcd m = (a * b).gcd m
state_after: a b m n : ℕ+
cop : m.Coprime n
am : a.gcd m = a
bn : b ∣ n
⊢ (a * b).gcd m = a.gcd m

tactic: apply Coprime.gcd_mul_right_cancel a
state_before: a b m n : ℕ+
cop : m.Coprime n
am : a.gcd m = a
bn : b ∣ n
⊢ (a * b).gcd m = a.gcd m
state_after: a b m n : ℕ+
cop : m.Coprime n
am : a.gcd m = a
bn : b ∣ n
⊢ b.Coprime m

tactic: apply Coprime.coprime_dvd_left bn cop.symm
state_before: a b m n : ℕ+
cop : m.Coprime n
am : a.gcd m = a
bn : b ∣ n
⊢ b.Coprime m
state_after: no goals
Theorem: UniformEquicontinuousOn.mono
File: Mathlib/Topology/UniformSpace/Equicontinuity.lean

tactic: gcongr
state_before: ι : Type u_1
κ : Type u_2
X : Type u_3
X' : Type u_4
Y : Type u_5
Z : Type u_6
α : Type u_7
α' : Type u_8
β : Type u_9
β' : Type u_10
γ : Type u_11
𝓕 : Type u_12
tX : TopologicalSpace X
tY : TopologicalSpace Y
tZ : TopologicalSpace Z
uα : UniformSpace α
uβ : UniformSpace β
uγ : UniformSpace γ
F : ι → β → α
S T : Set β
H : UniformEquicontinuousOn F T
hST : S ⊆ T
U : Set (α × α)
hU : U ∈ 𝓤 α
⊢ 𝓤 β ⊓ 𝓟 (S ×ˢ S) ≤ 𝓤 β ⊓ 𝓟 (T ×ˢ T)
state_after: no goals
Theorem: CauSeq.le_inf
File: Mathlib/Algebra/Order/CauSeq/Basic.lean

tactic: cases' hb with hb hb
state_before: α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hb : a ≤ b
hc : a ≤ c
⊢ a ≤ b ⊓ c
state_after: case inl
α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hc : a ≤ c
hb : a < b
⊢ a ≤ b ⊓ c

case inr
α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hc : a ≤ c
hb : a ≈ b
⊢ a ≤ b ⊓ c

tactic: cases' hc with hc hc
state_before: case inl
α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hc : a ≤ c
hb : a < b
⊢ a ≤ b ⊓ c
state_after: case inl.inl
α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hb : a < b
hc : a < c
⊢ a ≤ b ⊓ c

case inl.inr
α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hb : a < b
hc : a ≈ c
⊢ a ≤ b ⊓ c

tactic: exact Or.inl (CauSeq.lt_inf hb hc)
state_before: case inl.inl
α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hb : a < b
hc : a < c
⊢ a ≤ b ⊓ c
state_after: no goals

tactic: replace hb := le_of_eq_of_le (Setoid.symm hc) hb.le
state_before: case inl.inr
α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hb : a < b
hc : a ≈ c
⊢ a ≤ b ⊓ c
state_after: case inl.inr
α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hc : a ≈ c
hb : c ≤ b
⊢ a ≤ b ⊓ c

tactic: refine le_of_eq_of_le hc (Or.inr ?_)
state_before: case inl.inr
α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hc : a ≈ c
hb : c ≤ b
⊢ a ≤ b ⊓ c
state_after: case inl.inr
α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hc : a ≈ c
hb : c ≤ b
⊢ c ≈ b ⊓ c

tactic: exact Setoid.symm (CauSeq.inf_eq_right hb)
state_before: case inl.inr
α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hc : a ≈ c
hb : c ≤ b
⊢ c ≈ b ⊓ c
state_after: no goals

tactic: replace hc := le_of_eq_of_le (Setoid.symm hb) hc
state_before: case inr
α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hc : a ≤ c
hb : a ≈ b
⊢ a ≤ b ⊓ c
state_after: case inr
α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hb : a ≈ b
hc : b ≤ c
⊢ a ≤ b ⊓ c

tactic: refine le_of_eq_of_le hb (Or.inr ?_)
state_before: case inr
α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hb : a ≈ b
hc : b ≤ c
⊢ a ≤ b ⊓ c
state_after: case inr
α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hb : a ≈ b
hc : b ≤ c
⊢ b ≈ b ⊓ c

tactic: exact Setoid.symm (CauSeq.inf_eq_left hc)
state_before: case inr
α : Type u_1
β : Type u_2
inst✝ : LinearOrderedField α
a b c : CauSeq α abs
hb : a ≈ b
hc : b ≤ c
⊢ b ≈ b ⊓ c
state_after: no goals
Theorem: Nat.factorization_le_factorization_mul_left
File: Mathlib/Data/Nat/Factorization/Basic.lean

tactic: rcases eq_or_ne a 0 with (rfl | ha)
state_before: a✝ b✝ m n p a b : ℕ
hb : b ≠ 0
⊢ a.factorization ≤ (a * b).factorization
state_after: case inl
a b✝ m n p b : ℕ
hb : b ≠ 0
⊢ factorization 0 ≤ (0 * b).factorization

case inr
a✝ b✝ m n p a b : ℕ
hb : b ≠ 0
ha : a ≠ 0
⊢ a.factorization ≤ (a * b).factorization

tactic: rw [factorization_le_iff_dvd ha <| mul_ne_zero ha hb]
state_before: case inr
a✝ b✝ m n p a b : ℕ
hb : b ≠ 0
ha : a ≠ 0
⊢ a.factorization ≤ (a * b).factorization
state_after: case inr
a✝ b✝ m n p a b : ℕ
hb : b ≠ 0
ha : a ≠ 0
⊢ a ∣ a * b

tactic: exact Dvd.intro b rfl
state_before: case inr
a✝ b✝ m n p a b : ℕ
hb : b ≠ 0
ha : a ≠ 0
⊢ a ∣ a * b
state_after: no goals

tactic: simp
state_before: case inl
a b✝ m n p b : ℕ
hb : b ≠ 0
⊢ factorization 0 ≤ (0 * b).factorization
state_after: no goals
Theorem: exists_hasDerivAt_eq_slope
File: Mathlib/Analysis/Calculus/MeanValue.lean

tactic: obtain ⟨c, cmem, hc⟩ : ∃ c ∈ Ioo a b, (b - a) * f' c = (f b - f a) * 1 :=
  exists_ratio_hasDerivAt_eq_ratio_slope f f' hab hfc hff' id 1 continuousOn_id
    fun x _ => hasDerivAt_id x
state_before: E : Type u_1
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace ℝ E
F : Type u_2
inst✝¹ : NormedAddCommGroup F
inst✝ : NormedSpace ℝ F
f f' : ℝ → ℝ
a b : ℝ
hab : a < b
hfc : ContinuousOn f (Icc a b)
hff' : ∀ x ∈ Ioo a b, HasDerivAt f (f' x) x
hfd : DifferentiableOn ℝ f (Ioo a b)
g g' : ℝ → ℝ
hgc : ContinuousOn g (Icc a b)
hgg' : ∀ x ∈ Ioo a b, HasDerivAt g (g' x) x
hgd : DifferentiableOn ℝ g (Ioo a b)
⊢ ∃ c ∈ Ioo a b, f' c = (f b - f a) / (b - a)
state_after: case intro.intro
E : Type u_1
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace ℝ E
F : Type u_2
inst✝¹ : NormedAddCommGroup F
inst✝ : NormedSpace ℝ F
f f' : ℝ → ℝ
a b : ℝ
hab : a < b
hfc : ContinuousOn f (Icc a b)
hff' : ∀ x ∈ Ioo a b, HasDerivAt f (f' x) x
hfd : DifferentiableOn ℝ f (Ioo a b)
g g' : ℝ → ℝ
hgc : ContinuousOn g (Icc a b)
hgg' : ∀ x ∈ Ioo a b, HasDerivAt g (g' x) x
hgd : DifferentiableOn ℝ g (Ioo a b)
c : ℝ
cmem : c ∈ Ioo a b
hc : (b - a) * f' c = (f b - f a) * 1
⊢ ∃ c ∈ Ioo a b, f' c = (f b - f a) / (b - a)

tactic: use c, cmem
state_before: case intro.intro
E : Type u_1
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace ℝ E
F : Type u_2
inst✝¹ : NormedAddCommGroup F
inst✝ : NormedSpace ℝ F
f f' : ℝ → ℝ
a b : ℝ
hab : a < b
hfc : ContinuousOn f (Icc a b)
hff' : ∀ x ∈ Ioo a b, HasDerivAt f (f' x) x
hfd : DifferentiableOn ℝ f (Ioo a b)
g g' : ℝ → ℝ
hgc : ContinuousOn g (Icc a b)
hgg' : ∀ x ∈ Ioo a b, HasDerivAt g (g' x) x
hgd : DifferentiableOn ℝ g (Ioo a b)
c : ℝ
cmem : c ∈ Ioo a b
hc : (b - a) * f' c = (f b - f a) * 1
⊢ ∃ c ∈ Ioo a b, f' c = (f b - f a) / (b - a)
state_after: case right
E : Type u_1
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace ℝ E
F : Type u_2
inst✝¹ : NormedAddCommGroup F
inst✝ : NormedSpace ℝ F
f f' : ℝ → ℝ
a b : ℝ
hab : a < b
hfc : ContinuousOn f (Icc a b)
hff' : ∀ x ∈ Ioo a b, HasDerivAt f (f' x) x
hfd : DifferentiableOn ℝ f (Ioo a b)
g g' : ℝ → ℝ
hgc : ContinuousOn g (Icc a b)
hgg' : ∀ x ∈ Ioo a b, HasDerivAt g (g' x) x
hgd : DifferentiableOn ℝ g (Ioo a b)
c : ℝ
cmem : c ∈ Ioo a b
hc : (b - a) * f' c = (f b - f a) * 1
⊢ f' c = (f b - f a) / (b - a)

tactic: rwa [mul_one, mul_comm, ← eq_div_iff (sub_ne_zero.2 hab.ne')] at hc
state_before: case right
E : Type u_1
inst✝³ : NormedAddCommGroup E
inst✝² : NormedSpace ℝ E
F : Type u_2
inst✝¹ : NormedAddCommGroup F
inst✝ : NormedSpace ℝ F
f f' : ℝ → ℝ
a b : ℝ
hab : a < b
hfc : ContinuousOn f (Icc a b)
hff' : ∀ x ∈ Ioo a b, HasDerivAt f (f' x) x
hfd : DifferentiableOn ℝ f (Ioo a b)
g g' : ℝ → ℝ
hgc : ContinuousOn g (Icc a b)
hgg' : ∀ x ∈ Ioo a b, HasDerivAt g (g' x) x
hgd : DifferentiableOn ℝ g (Ioo a b)
c : ℝ
cmem : c ∈ Ioo a b
hc : (b - a) * f' c = (f b - f a) * 1
⊢ f' c = (f b - f a) / (b - a)
state_after: no goals
Theorem: Prod.covBy_iff
File: Mathlib/Order/Cover.lean

tactic: cases x
state_before: α : Type u_1
β : Type u_2
inst✝¹ : PartialOrder α
inst✝ : PartialOrder β
a a₁ a₂ : α
b b₁ b₂ : β
x y : α × β
⊢ x ⋖ y ↔ x.1 ⋖ y.1 ∧ x.2 = y.2 ∨ x.2 ⋖ y.2 ∧ x.1 = y.1
state_after: case mk
α : Type u_1
β : Type u_2
inst✝¹ : PartialOrder α
inst✝ : PartialOrder β
a a₁ a₂ : α
b b₁ b₂ : β
y : α × β
fst✝ : α
snd✝ : β
⊢ (fst✝, snd✝) ⋖ y ↔ (fst✝, snd✝).1 ⋖ y.1 ∧ (fst✝, snd✝).2 = y.2 ∨ (fst✝, snd✝).2 ⋖ y.2 ∧ (fst✝, snd✝).1 = y.1

tactic: cases y
state_before: case mk
α : Type u_1
β : Type u_2
inst✝¹ : PartialOrder α
inst✝ : PartialOrder β
a a₁ a₂ : α
b b₁ b₂ : β
y : α × β
fst✝ : α
snd✝ : β
⊢ (fst✝, snd✝) ⋖ y ↔ (fst✝, snd✝).1 ⋖ y.1 ∧ (fst✝, snd✝).2 = y.2 ∨ (fst✝, snd✝).2 ⋖ y.2 ∧ (fst✝, snd✝).1 = y.1
state_after: case mk.mk
α : Type u_1
β : Type u_2
inst✝¹ : PartialOrder α
inst✝ : PartialOrder β
a a₁ a₂ : α
b b₁ b₂ : β
fst✝¹ : α
snd✝¹ : β
fst✝ : α
snd✝ : β
⊢ (fst✝¹, snd✝¹) ⋖ (fst✝, snd✝) ↔
    (fst✝¹, snd✝¹).1 ⋖ (fst✝, snd✝).1 ∧ (fst✝¹, snd✝¹).2 = (fst✝, snd✝).2 ∨
      (fst✝¹, snd✝¹).2 ⋖ (fst✝, snd✝).2 ∧ (fst✝¹, snd✝¹).1 = (fst✝, snd✝).1

tactic: exact mk_covBy_mk_iff
state_before: case mk.mk
α : Type u_1
β : Type u_2
inst✝¹ : PartialOrder α
inst✝ : PartialOrder β
a a₁ a₂ : α
b b₁ b₂ : β
fst✝¹ : α
snd✝¹ : β
fst✝ : α
snd✝ : β
⊢ (fst✝¹, snd✝¹) ⋖ (fst✝, snd✝) ↔
    (fst✝¹, snd✝¹).1 ⋖ (fst✝, snd✝).1 ∧ (fst✝¹, snd✝¹).2 = (fst✝, snd✝).2 ∨
      (fst✝¹, snd✝¹).2 ⋖ (fst✝, snd✝).2 ∧ (fst✝¹, snd✝¹).1 = (fst✝, snd✝).1
state_after: no goals
Theorem: Nat.div2_succ
File: Mathlib/Data/Nat/Bits.lean

tactic: simp only [bodd, boddDiv2, div2]
state_before: m n✝ n : ℕ
⊢ n.succ.div2 = bif n.bodd then n.div2.succ else n.div2
state_after: m n✝ n : ℕ
⊢ (match n.boddDiv2 with
      | (false, m) => (true, m)
      | (true, m) => (false, m.succ)).2 =
    bif n.boddDiv2.1 then n.boddDiv2.2.succ else n.boddDiv2.2

tactic: rcases boddDiv2 n with ⟨_|_, _⟩ <;> simp
state_before: m n✝ n : ℕ
⊢ (match n.boddDiv2 with
      | (false, m) => (true, m)
      | (true, m) => (false, m.succ)).2 =
    bif n.boddDiv2.1 then n.boddDiv2.2.succ else n.boddDiv2.2
state_after: no goals
Theorem: LinearMap.equivariantProjection_condition
File: Mathlib/RepresentationTheory/Maschke.lean

tactic: rw [equivariantProjection_apply]
state_before: k : Type u
inst✝¹¹ : CommRing k
G : Type u
inst✝¹⁰ : Group G
V : Type v
inst✝⁹ : AddCommGroup V
inst✝⁸ : Module k V
inst✝⁷ : Module (MonoidAlgebra k G) V
inst✝⁶ : IsScalarTower k (MonoidAlgebra k G) V
W : Type w
inst✝⁵ : AddCommGroup W
inst✝⁴ : Module k W
inst✝³ : Module (MonoidAlgebra k G) W
inst✝² : IsScalarTower k (MonoidAlgebra k G) W
π : W →ₗ[k] V
i : V →ₗ[MonoidAlgebra k G] W
h : ∀ (v : V), π (i v) = v
inst✝¹ : Fintype G
inst✝ : Invertible ↑(Fintype.card G)
v : V
⊢ (equivariantProjection G π) (i v) = v
state_after: k : Type u
inst✝¹¹ : CommRing k
G : Type u
inst✝¹⁰ : Group G
V : Type v
inst✝⁹ : AddCommGroup V
inst✝⁸ : Module k V
inst✝⁷ : Module (MonoidAlgebra k G) V
inst✝⁶ : IsScalarTower k (MonoidAlgebra k G) V
W : Type w
inst✝⁵ : AddCommGroup W
inst✝⁴ : Module k W
inst✝³ : Module (MonoidAlgebra k G) W
inst✝² : IsScalarTower k (MonoidAlgebra k G) W
π : W →ₗ[k] V
i : V →ₗ[MonoidAlgebra k G] W
h : ∀ (v : V), π (i v) = v
inst✝¹ : Fintype G
inst✝ : Invertible ↑(Fintype.card G)
v : V
⊢ ⅟↑(Fintype.card G) • ∑ g : G, (π.conjugate g) (i v) = v

tactic: simp only [conjugate_i π i h]
state_before: k : Type u
inst✝¹¹ : CommRing k
G : Type u
inst✝¹⁰ : Group G
V : Type v
inst✝⁹ : AddCommGroup V
inst✝⁸ : Module k V
inst✝⁷ : Module (MonoidAlgebra k G) V
inst✝⁶ : IsScalarTower k (MonoidAlgebra k G) V
W : Type w
inst✝⁵ : AddCommGroup W
inst✝⁴ : Module k W
inst✝³ : Module (MonoidAlgebra k G) W
inst✝² : IsScalarTower k (MonoidAlgebra k G) W
π : W →ₗ[k] V
i : V →ₗ[MonoidAlgebra k G] W
h : ∀ (v : V), π (i v) = v
inst✝¹ : Fintype G
inst✝ : Invertible ↑(Fintype.card G)
v : V
⊢ ⅟↑(Fintype.card G) • ∑ g : G, (π.conjugate g) (i v) = v
state_after: k : Type u
inst✝¹¹ : CommRing k
G : Type u
inst✝¹⁰ : Group G
V : Type v
inst✝⁹ : AddCommGroup V
inst✝⁸ : Module k V
inst✝⁷ : Module (MonoidAlgebra k G) V
inst✝⁶ : IsScalarTower k (MonoidAlgebra k G) V
W : Type w
inst✝⁵ : AddCommGroup W
inst✝⁴ : Module k W
inst✝³ : Module (MonoidAlgebra k G) W
inst✝² : IsScalarTower k (MonoidAlgebra k G) W
π : W →ₗ[k] V
i : V →ₗ[MonoidAlgebra k G] W
h : ∀ (v : V), π (i v) = v
inst✝¹ : Fintype G
inst✝ : Invertible ↑(Fintype.card G)
v : V
⊢ ⅟↑(Fintype.card G) • ∑ x : G, v = v

tactic: rw [Finset.sum_const, Finset.card_univ, nsmul_eq_smul_cast k, smul_smul,
  Invertible.invOf_mul_self, one_smul]
state_before: k : Type u
inst✝¹¹ : CommRing k
G : Type u
inst✝¹⁰ : Group G
V : Type v
inst✝⁹ : AddCommGroup V
inst✝⁸ : Module k V
inst✝⁷ : Module (MonoidAlgebra k G) V
inst✝⁶ : IsScalarTower k (MonoidAlgebra k G) V
W : Type w
inst✝⁵ : AddCommGroup W
inst✝⁴ : Module k W
inst✝³ : Module (MonoidAlgebra k G) W
inst✝² : IsScalarTower k (MonoidAlgebra k G) W
π : W →ₗ[k] V
i : V →ₗ[MonoidAlgebra k G] W
h : ∀ (v : V), π (i v) = v
inst✝¹ : Fintype G
inst✝ : Invertible ↑(Fintype.card G)
v : V
⊢ ⅟↑(Fintype.card G) • ∑ x : G, v = v
state_after: no goals
Theorem: Basis.equivFun_self
File: Mathlib/LinearAlgebra/Basis.lean

tactic: rw [b.equivFun_apply, b.repr_self_apply]
state_before: ι : Type u_1
ι' : Type u_2
R : Type u_3
R₂ : Type u_4
K : Type u_5
M : Type u_6
M' : Type u_7
M'' : Type u_8
V : Type u
V' : Type u_9
inst✝⁶ : Semiring R
inst✝⁵ : AddCommMonoid M
inst✝⁴ : Module R M
inst✝³ : AddCommMonoid M'
inst✝² : Module R M'
inst✝¹ : Finite ι
inst✝ : DecidableEq ι
b : Basis ι R M
i j : ι
⊢ b.equivFun (b i) j = if i = j then 1 else 0
state_after: no goals
Theorem: Set.elim_preimage_pi
File: Mathlib/Data/Prod/TProd.lean

tactic: have h2 : { i | i ∈ l } = univ := by
  ext i
  simp [h]
state_before: ι : Type u
α : ι → Type v
i j : ι
l✝ : List ι
f : (i : ι) → α i
inst✝ : DecidableEq ι
l : List ι
hnd : l.Nodup
h : ∀ (i : ι), i ∈ l
t : (i : ι) → Set (α i)
⊢ TProd.elim' h ⁻¹' univ.pi t = Set.tprod l t
state_after: ι : Type u
α : ι → Type v
i j : ι
l✝ : List ι
f : (i : ι) → α i
inst✝ : DecidableEq ι
l : List ι
hnd : l.Nodup
h : ∀ (i : ι), i ∈ l
t : (i : ι) → Set (α i)
h2 : {i | i ∈ l} = univ
⊢ TProd.elim' h ⁻¹' univ.pi t = Set.tprod l t

tactic: rw [← h2, ← mk_preimage_tprod, preimage_preimage]
state_before: ι : Type u
α : ι → Type v
i j : ι
l✝ : List ι
f : (i : ι) → α i
inst✝ : DecidableEq ι
l : List ι
hnd : l.Nodup
h : ∀ (i : ι), i ∈ l
t : (i : ι) → Set (α i)
h2 : {i | i ∈ l} = univ
⊢ TProd.elim' h ⁻¹' univ.pi t = Set.tprod l t
state_after: ι : Type u
α : ι → Type v
i j : ι
l✝ : List ι
f : (i : ι) → α i
inst✝ : DecidableEq ι
l : List ι
hnd : l.Nodup
h : ∀ (i : ι), i ∈ l
t : (i : ι) → Set (α i)
h2 : {i | i ∈ l} = univ
⊢ (fun x => TProd.mk l (TProd.elim' h x)) ⁻¹' Set.tprod l t = Set.tprod l t

tactic: simp only [TProd.mk_elim hnd h]
state_before: ι : Type u
α : ι → Type v
i j : ι
l✝ : List ι
f : (i : ι) → α i
inst✝ : DecidableEq ι
l : List ι
hnd : l.Nodup
h : ∀ (i : ι), i ∈ l
t : (i : ι) → Set (α i)
h2 : {i | i ∈ l} = univ
⊢ (fun x => TProd.mk l (TProd.elim' h x)) ⁻¹' Set.tprod l t = Set.tprod l t
state_after: ι : Type u
α : ι → Type v
i j : ι
l✝ : List ι
f : (i : ι) → α i
inst✝ : DecidableEq ι
l : List ι
hnd : l.Nodup
h : ∀ (i : ι), i ∈ l
t : (i : ι) → Set (α i)
h2 : {i | i ∈ l} = univ
⊢ (fun x => x) ⁻¹' Set.tprod l t = Set.tprod l t

tactic: dsimp
state_before: ι : Type u
α : ι → Type v
i j : ι
l✝ : List ι
f : (i : ι) → α i
inst✝ : DecidableEq ι
l : List ι
hnd : l.Nodup
h : ∀ (i : ι), i ∈ l
t : (i : ι) → Set (α i)
h2 : {i | i ∈ l} = univ
⊢ (fun x => x) ⁻¹' Set.tprod l t = Set.tprod l t
state_after: no goals

tactic: ext i
state_before: ι : Type u
α : ι → Type v
i j : ι
l✝ : List ι
f : (i : ι) → α i
inst✝ : DecidableEq ι
l : List ι
hnd : l.Nodup
h : ∀ (i : ι), i ∈ l
t : (i : ι) → Set (α i)
⊢ {i | i ∈ l} = univ
state_after: case h
ι : Type u
α : ι → Type v
i✝ j : ι
l✝ : List ι
f : (i : ι) → α i
inst✝ : DecidableEq ι
l : List ι
hnd : l.Nodup
h : ∀ (i : ι), i ∈ l
t : (i : ι) → Set (α i)
i : ι
⊢ i ∈ {i | i ∈ l} ↔ i ∈ univ

tactic: simp [h]
state_before: case h
ι : Type u
α : ι → Type v
i✝ j : ι
l✝ : List ι
f : (i : ι) → α i
inst✝ : DecidableEq ι
l : List ι
hnd : l.Nodup
h : ∀ (i : ι), i ∈ l
t : (i : ι) → Set (α i)
i : ι
⊢ i ∈ {i | i ∈ l} ↔ i ∈ univ
state_after: no goals
Theorem: List.foldl_eq_foldr'
File: Mathlib/Data/List/Basic.lean

tactic: rw [foldl_eq_of_comm' hf, foldr, foldl_eq_foldr' ..]
state_before: ι : Type u_1
α : Type u
β : Type v
γ : Type w
l₁ l₂ : List α
f : α → β → α
hf : ∀ (a : α) (b c : β), f (f a b) c = f (f a c) b
a : α
b : β
l : List β
⊢ foldl f a (b :: l) = foldr (flip f) a (b :: l)
state_after: ι : Type u_1
α : Type u
β : Type v
γ : Type w
l₁ l₂ : List α
f : α → β → α
hf : ∀ (a : α) (b c : β), f (f a b) c = f (f a c) b
a : α
b : β
l : List β
⊢ f (foldr (flip f) a l) b = flip f b (foldr (flip f) a l)

tactic: rfl
state_before: ι : Type u_1
α : Type u
β : Type v
γ : Type w
l₁ l₂ : List α
f : α → β → α
hf : ∀ (a : α) (b c : β), f (f a b) c = f (f a c) b
a : α
b : β
l : List β
⊢ f (foldr (flip f) a l) b = flip f b (foldr (flip f) a l)
state_after: no goals
Theorem: OnePoint.hasBasis_nhds_infty
File: Mathlib/Topology/Compactification/OnePoint.lean

tactic: rw [nhds_infty_eq]
state_before: X : Type u_1
inst✝ : TopologicalSpace X
s : Set (OnePoint X)
t : Set X
⊢ (𝓝 ∞).HasBasis (fun s => IsClosed s ∧ IsCompact s) fun s => some '' sᶜ ∪ {∞}
state_after: X : Type u_1
inst✝ : TopologicalSpace X
s : Set (OnePoint X)
t : Set X
⊢ (map some (coclosedCompact X) ⊔ pure ∞).HasBasis (fun s => IsClosed s ∧ IsCompact s) fun s => some '' sᶜ ∪ {∞}

tactic: exact (hasBasis_coclosedCompact.map _).sup_pure _
state_before: X : Type u_1
inst✝ : TopologicalSpace X
s : Set (OnePoint X)
t : Set X
⊢ (map some (coclosedCompact X) ⊔ pure ∞).HasBasis (fun s => IsClosed s ∧ IsCompact s) fun s => some '' sᶜ ∪ {∞}
state_after: no goals
Theorem: MvPolynomial.map_comp_C
File: Mathlib/Algebra/MvPolynomial/Monad.lean

tactic: ext1
state_before: σ : Type u_1
τ : Type u_2
R : Type u_3
S : Type u_4
T : Type u_5
inst✝² : CommSemiring R
inst✝¹ : CommSemiring S
inst✝ : CommSemiring T
f✝ : σ → MvPolynomial τ R
f : R →+* S
⊢ (map f).comp C = C.comp f
state_after: case a
σ : Type u_1
τ : Type u_2
R : Type u_3
S : Type u_4
T : Type u_5
inst✝² : CommSemiring R
inst✝¹ : CommSemiring S
inst✝ : CommSemiring T
f✝ : σ → MvPolynomial τ R
f : R →+* S
x✝ : R
⊢ ((map f).comp C) x✝ = (C.comp f) x✝

tactic: apply map_C
state_before: case a
σ : Type u_1
τ : Type u_2
R : Type u_3
S : Type u_4
T : Type u_5
inst✝² : CommSemiring R
inst✝¹ : CommSemiring S
inst✝ : CommSemiring T
f✝ : σ → MvPolynomial τ R
f : R →+* S
x✝ : R
⊢ ((map f).comp C) x✝ = (C.comp f) x✝
state_after: no goals
Theorem: AlgHom.FinitePresentation.of_surjective
File: Mathlib/RingTheory/FinitePresentation.lean

tactic: convert RingHom.FinitePresentation.of_surjective f hf hker
state_before: R : Type u_1
A : Type u_2
B : Type u_3
C : Type u_4
inst✝⁶ : CommRing R
inst✝⁵ : CommRing A
inst✝⁴ : CommRing B
inst✝³ : CommRing C
inst✝² : Algebra R A
inst✝¹ : Algebra R B
inst✝ : Algebra R C
f : A →ₐ[R] B
hf : Surjective ⇑f
hker : (RingHom.ker f.toRingHom).FG
⊢ f.FinitePresentation
state_after: no goals
Theorem: List.cons_merge_cons_pos
File: .lake/packages/batteries/Batteries/Data/List/Lemmas.lean

tactic: rw [cons_merge_cons, if_pos h]
state_before: α : Type u_1
a b : α
s : α → α → Bool
l r : List α
h : s a b = true
⊢ merge s (a :: l) (b :: r) = a :: merge s l (b :: r)
state_after: no goals
Theorem: Matrix.PosSemidef.fromBlocks₂₂
File: Mathlib/LinearAlgebra/Matrix/SchurComplement.lean

tactic: rw [← posSemidef_submatrix_equiv (Equiv.sumComm n m), Equiv.sumComm_apply,
  fromBlocks_submatrix_sum_swap_sum_swap]
state_before: l : Type u_1
m : Type u_2
n : Type u_3
α : Type u_4
𝕜 : Type u_5
inst✝⁷ : CommRing 𝕜
inst✝⁶ : PartialOrder 𝕜
inst✝⁵ : StarRing 𝕜
inst✝⁴ : StarOrderedRing 𝕜
inst✝³ : Fintype m
inst✝² : Fintype n
inst✝¹ : DecidableEq n
A : Matrix m m 𝕜
B : Matrix m n 𝕜
D : Matrix n n 𝕜
hD : D.PosDef
inst✝ : Invertible D
⊢ (fromBlocks A B Bᴴ D).PosSemidef ↔ (A - B * D⁻¹ * Bᴴ).PosSemidef
state_after: l : Type u_1
m : Type u_2
n : Type u_3
α : Type u_4
𝕜 : Type u_5
inst✝⁷ : CommRing 𝕜
inst✝⁶ : PartialOrder 𝕜
inst✝⁵ : StarRing 𝕜
inst✝⁴ : StarOrderedRing 𝕜
inst✝³ : Fintype m
inst✝² : Fintype n
inst✝¹ : DecidableEq n
A : Matrix m m 𝕜
B : Matrix m n 𝕜
D : Matrix n n 𝕜
hD : D.PosDef
inst✝ : Invertible D
⊢ (fromBlocks D Bᴴ B A).PosSemidef ↔ (A - B * D⁻¹ * Bᴴ).PosSemidef

tactic: convert PosSemidef.fromBlocks₁₁ Bᴴ A hD <;>
  simp
state_before: l : Type u_1
m : Type u_2
n : Type u_3
α : Type u_4
𝕜 : Type u_5
inst✝⁷ : CommRing 𝕜
inst✝⁶ : PartialOrder 𝕜
inst✝⁵ : StarRing 𝕜
inst✝⁴ : StarOrderedRing 𝕜
inst✝³ : Fintype m
inst✝² : Fintype n
inst✝¹ : DecidableEq n
A : Matrix m m 𝕜
B : Matrix m n 𝕜
D : Matrix n n 𝕜
hD : D.PosDef
inst✝ : Invertible D
⊢ (fromBlocks D Bᴴ B A).PosSemidef ↔ (A - B * D⁻¹ * Bᴴ).PosSemidef
state_after: no goals
Theorem: AlgebraicTopology.AlternatingCofaceMapComplex.d_squared
File: Mathlib/AlgebraicTopology/AlternatingFaceMapComplex.lean

tactic: simp only [d_eq_unop_d, ← unop_comp, AlternatingFaceMapComplex.d_squared, unop_zero]
state_before: C : Type u_1
inst✝³ : Category.{u_3, u_1} C
inst✝² : Preadditive C
A : Type u_2
inst✝¹ : Category.{?u.77881, u_2} A
inst✝ : Abelian A
X Y : CosimplicialObject C
n : ℕ
⊢ objD X n ≫ objD X (n + 1) = 0
state_after: no goals
Theorem: NNRat.addSubmonoid_closure_range_pow
File: Mathlib/Data/Rat/Star.lean

tactic: refine (eq_top_iff' _).2 fun x ↦ ?_
state_before: n : ℕ
hn₀ : n ≠ 0
⊢ closure (range fun x => x ^ n) = ⊤
state_after: n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
⊢ x ∈ closure (range fun x => x ^ n)

tactic: suffices x = (x.num * x.den ^ (n - 1)) • (x.den : ℚ≥0)⁻¹ ^ n by
  rw [this]
  exact nsmul_mem (subset_closure <| mem_range_self _) _
state_before: n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
⊢ x ∈ closure (range fun x => x ^ n)
state_after: n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
⊢ x = (x.num * x.den ^ (n - 1)) • (↑x.den)⁻¹ ^ n

tactic: rw [nsmul_eq_mul]
state_before: n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
⊢ x = (x.num * x.den ^ (n - 1)) • (↑x.den)⁻¹ ^ n
state_after: n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
⊢ x = ↑(x.num * x.den ^ (n - 1)) * (↑x.den)⁻¹ ^ n

tactic: push_cast
state_before: n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
⊢ x = ↑(x.num * x.den ^ (n - 1)) * (↑x.den)⁻¹ ^ n
state_after: n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
⊢ x = ↑x.num * ↑x.den ^ (n - 1) * (↑x.den)⁻¹ ^ n

tactic: rw [mul_assoc, pow_sub₀, pow_one, mul_right_comm, ← mul_pow, mul_inv_cancel, one_pow, one_mul,
  ← div_eq_mul_inv, num_div_den]
state_before: n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
⊢ x = ↑x.num * ↑x.den ^ (n - 1) * (↑x.den)⁻¹ ^ n
state_after: n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
⊢ ↑x.den ≠ 0

case ha
n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
⊢ ↑x.den ≠ 0

case h
n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
⊢ 1 ≤ n

tactic: all_goals simp [x.den_pos.ne', Nat.one_le_iff_ne_zero, *]
state_before: n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
⊢ ↑x.den ≠ 0

case ha
n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
⊢ ↑x.den ≠ 0

case h
n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
⊢ 1 ≤ n
state_after: no goals

tactic: rw [this]
state_before: n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
this : x = (x.num * x.den ^ (n - 1)) • (↑x.den)⁻¹ ^ n
⊢ x ∈ closure (range fun x => x ^ n)
state_after: n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
this : x = (x.num * x.den ^ (n - 1)) • (↑x.den)⁻¹ ^ n
⊢ (x.num * x.den ^ (n - 1)) • (↑x.den)⁻¹ ^ n ∈ closure (range fun x => x ^ n)

tactic: exact nsmul_mem (subset_closure <| mem_range_self _) _
state_before: n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
this : x = (x.num * x.den ^ (n - 1)) • (↑x.den)⁻¹ ^ n
⊢ (x.num * x.den ^ (n - 1)) • (↑x.den)⁻¹ ^ n ∈ closure (range fun x => x ^ n)
state_after: no goals

tactic: simp [x.den_pos.ne', Nat.one_le_iff_ne_zero, *]
state_before: case h
n : ℕ
hn₀ : n ≠ 0
x : ℚ≥0
⊢ 1 ≤ n
state_after: no goals