tasksource/leandojo huggingface dataset:
Theorem: Submonoid.noncommProd_mem
File: Mathlib/GroupTheory/Submonoid/Membership.lean

tactic: apply multiset_noncommProd_mem
state_before: M : Type u_1
A : Type ?u.31592
B : Type ?u.31595
inst✝² : Monoid M
inst✝¹ : SetLike B M
inst✝ : SubmonoidClass B M
S✝ : B
s S : Submonoid M
ι : Type u_2
t : Finset ι
f : ι → M
comm : Set.Pairwise ↑t fun a b => Commute (f a) (f b)
h : ∀ (c : ι), c ∈ t → f c ∈ S
⊢ Finset.noncommProd t f comm ∈ S

tactic: intro y
state_before: case h
M : Type u_1
A : Type ?u.31592
B : Type ?u.31595
inst✝² : Monoid M
inst✝¹ : SetLike B M
inst✝ : SubmonoidClass B M
S✝ : B
s S : Submonoid M
ι : Type u_2
t : Finset ι
f : ι → M
comm : Set.Pairwise ↑t fun a b => Commute (f a) (f b)
h : ∀ (c : ι), c ∈ t → f c ∈ S
⊢ ∀ (x : M), x ∈ Multiset.map f t.val → x ∈ S

tactic: rw [Multiset.mem_map]
state_before: case h
M : Type u_1
A : Type ?u.31592
B : Type ?u.31595
inst✝² : Monoid M
inst✝¹ : SetLike B M
inst✝ : SubmonoidClass B M
S✝ : B
s S : Submonoid M
ι : Type u_2
t : Finset ι
f : ι → M
comm : Set.Pairwise ↑t fun a b => Commute (f a) (f b)
h : ∀ (c : ι), c ∈ t → f c ∈ S
y : M
⊢ y ∈ Multiset.map f t.val → y ∈ S

tactic: rintro ⟨x, ⟨hx, rfl⟩⟩
state_before: case h
M : Type u_1
A : Type ?u.31592
B : Type ?u.31595
inst✝² : Monoid M
inst✝¹ : SetLike B M
inst✝ : SubmonoidClass B M
S✝ : B
s S : Submonoid M
ι : Type u_2
t : Finset ι
f : ι → M
comm : Set.Pairwise ↑t fun a b => Commute (f a) (f b)
h : ∀ (c : ι), c ∈ t → f c ∈ S
y : M
⊢ (∃ a, a ∈ t.val ∧ f a = y) → y ∈ S

tactic: exact h x hx
state_before: case h.intro.intro
M : Type u_1
A : Type ?u.31592
B : Type ?u.31595
inst✝² : Monoid M
inst✝¹ : SetLike B M
inst✝ : SubmonoidClass B M
S✝ : B
s S : Submonoid M
ι : Type u_2
t : Finset ι
f : ι → M
comm : Set.Pairwise ↑t fun a b => Commute (f a) (f b)
h : ∀ (c : ι), c ∈ t → f c ∈ S
x : ι
hx : x ∈ t.val
⊢ f x ∈ S
Theorem: SimpleGraph.card_commonNeighbors_top
File: Mathlib/Combinatorics/SimpleGraph/Basic.lean

tactic: simp only [commonNeighbors_top_eq, ← Set.toFinset_card, Set.toFinset_diff]
state_before: ι : Sort ?u.303485
𝕜 : Type ?u.303488
V : Type u
W : Type v
X : Type w
G : SimpleGraph V
G' : SimpleGraph W
a b c u v✝ w✝ : V
e : Sym2 V
inst✝¹ : Fintype V
inst✝ : DecidableEq V
v w : V
h : v ≠ w
⊢ Fintype.card ↑(commonNeighbors ⊤ v w) = Fintype.card V - 2

tactic: rw [Finset.card_sdiff]
state_before: ι : Sort ?u.303485
𝕜 : Type ?u.303488
V : Type u
W : Type v
X : Type w
G : SimpleGraph V
G' : SimpleGraph W
a b c u v✝ w✝ : V
e : Sym2 V
inst✝¹ : Fintype V
inst✝ : DecidableEq V
v w : V
h : v ≠ w
⊢ card (Set.toFinset Set.univ \ Set.toFinset {v, w}) = Fintype.card V - 2

tactic: simp [Finset.card_univ, h]
state_before: ι : Sort ?u.303485
𝕜 : Type ?u.303488
V : Type u
W : Type v
X : Type w
G : SimpleGraph V
G' : SimpleGraph W
a b c u v✝ w✝ : V
e : Sym2 V
inst✝¹ : Fintype V
inst✝ : DecidableEq V
v w : V
h : v ≠ w
⊢ card (Set.toFinset Set.univ) - card (Set.toFinset {v, w}) = Fintype.card V - 2

tactic: simp only [Set.toFinset_subset_toFinset, Set.subset_univ]
state_before: ι : Sort ?u.303485
𝕜 : Type ?u.303488
V : Type u
W : Type v
X : Type w
G : SimpleGraph V
G' : SimpleGraph W
a b c u v✝ w✝ : V
e : Sym2 V
inst✝¹ : Fintype V
inst✝ : DecidableEq V
v w : V
h : v ≠ w
⊢ Set.toFinset {v, w} ⊆ Set.toFinset Set.univ
Theorem: MeasureTheory.VectorMeasure.nonpos_of_restrict_le_zero
File: Mathlib/MeasureTheory/Measure/VectorMeasure.lean

tactic: by_cases hi₁ : MeasurableSet i
state_before: α : Type u_1
β : Type ?u.585667
m : MeasurableSpace α
M : Type u_2
inst✝¹ : TopologicalSpace M
inst✝ : OrderedAddCommMonoid M
v w : VectorMeasure α M
i j : Set α
hi₂ : restrict v i ≤ restrict 0 i
⊢ ↑v i ≤ 0

tactic: exact (restrict_le_restrict_iff _ _ hi₁).1 hi₂ hi₁ Set.Subset.rfl
state_before: case pos
α : Type u_1
β : Type ?u.585667
m : MeasurableSpace α
M : Type u_2
inst✝¹ : TopologicalSpace M
inst✝ : OrderedAddCommMonoid M
v w : VectorMeasure α M
i j : Set α
hi₂ : restrict v i ≤ restrict 0 i
hi₁ : MeasurableSet i
⊢ ↑v i ≤ 0

tactic: rw [v.not_measurable hi₁]
state_before: case neg
α : Type u_1
β : Type ?u.585667
m : MeasurableSpace α
M : Type u_2
inst✝¹ : TopologicalSpace M
inst✝ : OrderedAddCommMonoid M
v w : VectorMeasure α M
i j : Set α
hi₂ : restrict v i ≤ restrict 0 i
hi₁ : ¬MeasurableSet i
⊢ ↑v i ≤ 0
Theorem: intervalIntegral.smul_integral_comp_sub_mul
File: Mathlib/MeasureTheory/Integral/IntervalIntegral.lean

tactic: by_cases hc : c = 0 <;> simp [hc, integral_comp_sub_mul]
state_before: ι : Type ?u.14928733
𝕜 : Type ?u.14928736
E : Type u_1
F : Type ?u.14928742
A : Type ?u.14928745
inst✝² : NormedAddCommGroup E
inst✝¹ : CompleteSpace E
inst✝ : NormedSpace ℝ E
a b c✝ d✝ : ℝ
f : ℝ → E
c d : ℝ
⊢ (c • ∫ (x : ℝ) in a..b, f (d - c * x)) = ∫ (x : ℝ) in d - c * b..d - c * a, f x
Theorem: edist_pos
File: Mathlib/Topology/MetricSpace/EMetricSpace.lean

tactic: simp [← not_le]
state_before: α : Type u
β : Type v
X : Type ?u.308656
inst✝¹ : PseudoEMetricSpace α
γ : Type w
inst✝ : EMetricSpace γ
x y : γ
⊢ 0 < edist x y ↔ x ≠ y
Theorem: Set.image_update_Ico
File: Mathlib/Data/Set/Intervals/Pi.lean

tactic: rw [← Icc_diff_right, ← Icc_diff_right, image_diff (update_injective _ _), image_singleton,
  image_update_Icc]
state_before: ι : Type u_1
α : ι → Type u_2
inst✝¹ : DecidableEq ι
inst✝ : (i : ι) → PartialOrder (α i)
f : (i : ι) → α i
i : ι
a b : α i
⊢ update f i '' Ico a b = Ico (update f i a) (update f i b)
Theorem: Finset.mulDysonEtransform.subset
File: Mathlib/Combinatorics/Additive/Etransform.lean

tactic: refine' union_mul_inter_subset_union.trans (union_subset Subset.rfl _)
state_before: α : Type u_1
inst✝¹ : DecidableEq α
inst✝ : CommGroup α
e : α
x : Finset α × Finset α
⊢ (mulDysonEtransform e x).fst * (mulDysonEtransform e x).snd ⊆ x.fst * x.snd

tactic: rw [mul_smul_comm, smul_mul_assoc, inv_smul_smul, mul_comm]
state_before: α : Type u_1
inst✝¹ : DecidableEq α
inst✝ : CommGroup α
e : α
x : Finset α × Finset α
⊢ e • x.snd * e⁻¹ • x.fst ⊆ x.fst * x.snd
Theorem: EuclideanGeometry.dist_sq_eq_dist_orthogonalProjection_sq_add_dist_orthogonalProjection_sq
File: Mathlib/Geometry/Euclidean/Basic.lean

tactic: rw [dist_comm p2 _, dist_eq_norm_vsub V p1 _, dist_eq_norm_vsub V p1 _, dist_eq_norm_vsub V _ p2,
  ← vsub_add_vsub_cancel p1 (orthogonalProjection s p2) p2,
  norm_add_sq_eq_norm_sq_add_norm_sq_iff_real_inner_eq_zero]
state_before: V : Type u_1
P : Type u_2
inst✝⁵ : NormedAddCommGroup V
inst✝⁴ : InnerProductSpace ℝ V
inst✝³ : MetricSpace P
inst✝² : NormedAddTorsor V P
s : AffineSubspace ℝ P
inst✝¹ : Nonempty { x // x ∈ s }
inst✝ : CompleteSpace { x // x ∈ direction s }
p1 p2 : P
hp1 : p1 ∈ s
⊢ dist p1 p2 * dist p1 p2 =
    dist p1 ↑(↑(orthogonalProjection s) p2) * dist p1 ↑(↑(orthogonalProjection s) p2) +
      dist p2 ↑(↑(orthogonalProjection s) p2) * dist p2 ↑(↑(orthogonalProjection s) p2)

tactic: exact Submodule.inner_right_of_mem_orthogonal (vsub_orthogonalProjection_mem_direction p2 hp1)
  (orthogonalProjection_vsub_mem_direction_orthogonal s p2)
state_before: V : Type u_1
P : Type u_2
inst✝⁵ : NormedAddCommGroup V
inst✝⁴ : InnerProductSpace ℝ V
inst✝³ : MetricSpace P
inst✝² : NormedAddTorsor V P
s : AffineSubspace ℝ P
inst✝¹ : Nonempty { x // x ∈ s }
inst✝ : CompleteSpace { x // x ∈ direction s }
p1 p2 : P
hp1 : p1 ∈ s
⊢ inner (p1 -ᵥ ↑(↑(orthogonalProjection s) p2)) (↑(↑(orthogonalProjection s) p2) -ᵥ p2) = 0
Theorem: List.map_rotate
File: Mathlib/Data/List/Rotate.lean

tactic: induction' n with n hn IH generalizing l
state_before: α : Type u
β : Type u_1
f : α → β
l : List α
n : ℕ
⊢ map f (rotate l n) = rotate (map f l) n

tactic: simp
state_before: case zero
α : Type u
β : Type u_1
f : α → β
l✝ l : List α
⊢ map f (rotate l zero) = rotate (map f l) zero

tactic: cases' l with hd tl
state_before: case succ
α : Type u
β : Type u_1
f : α → β
l✝ : List α
n : ℕ
hn : ∀ (l : List α), map f (rotate l n) = rotate (map f l) n
l : List α
⊢ map f (rotate l (succ n)) = rotate (map f l) (succ n)

tactic: simp
state_before: case succ.nil
α : Type u
β : Type u_1
f : α → β
l : List α
n : ℕ
hn : ∀ (l : List α), map f (rotate l n) = rotate (map f l) n
⊢ map f (rotate [] (succ n)) = rotate (map f []) (succ n)

tactic: simp [hn]
state_before: case succ.cons
α : Type u
β : Type u_1
f : α → β
l : List α
n : ℕ
hn : ∀ (l : List α), map f (rotate l n) = rotate (map f l) n
hd : α
tl : List α
⊢ map f (rotate (hd :: tl) (succ n)) = rotate (map f (hd :: tl)) (succ n)
Theorem: EuclideanGeometry.dist_eq_abs_sub_dist_of_angle_eq_zero
File: Mathlib/Geometry/Euclidean/Angle/Unoriented/Affine.lean

tactic: rw [dist_eq_norm_vsub V, dist_eq_norm_vsub V, dist_eq_norm_vsub V, ← vsub_sub_vsub_cancel_right]
state_before: V : Type u_1
P : Type u_2
inst✝³ : NormedAddCommGroup V
inst✝² : InnerProductSpace ℝ V
inst✝¹ : MetricSpace P
inst✝ : NormedAddTorsor V P
p1 p2 p3 : P
h : ∠ p1 p2 p3 = 0
⊢ dist p1 p3 = abs (dist p1 p2 - dist p3 p2)

tactic: exact norm_sub_eq_abs_sub_norm_of_angle_eq_zero h
state_before: V : Type u_1
P : Type u_2
inst✝³ : NormedAddCommGroup V
inst✝² : InnerProductSpace ℝ V
inst✝¹ : MetricSpace P
inst✝ : NormedAddTorsor V P
p1 p2 p3 : P
h : ∠ p1 p2 p3 = 0
⊢ ‖p1 -ᵥ ?p3 - (p3 -ᵥ ?p3)‖ = abs (‖p1 -ᵥ p2‖ - ‖p3 -ᵥ p2‖)

case p3
V : Type u_1
P : Type u_2
inst✝³ : NormedAddCommGroup V
inst✝² : InnerProductSpace ℝ V
inst✝¹ : MetricSpace P
inst✝ : NormedAddTorsor V P
p1 p2 p3 : P
h : ∠ p1 p2 p3 = 0
⊢ P
Theorem: Nat.perfect_iff_sum_divisors_eq_two_mul
File: Mathlib/NumberTheory/Divisors.lean

tactic: rw [perfect_iff_sum_properDivisors h, sum_divisors_eq_sum_properDivisors_add_self, two_mul]
state_before: n : ℕ
h : 0 < n
⊢ Perfect n ↔ ∑ i in divisors n, i = 2 * n

tactic: constructor <;> intro h
state_before: n : ℕ
h : 0 < n
⊢ ∑ i in properDivisors n, i = n ↔ ∑ i in properDivisors n, i + n = n + n

tactic: rw [h]
state_before: case mp
n : ℕ
h✝ : 0 < n
h : ∑ i in properDivisors n, i = n
⊢ ∑ i in properDivisors n, i + n = n + n

tactic: apply add_right_cancel h
state_before: case mpr
n : ℕ
h✝ : 0 < n
h : ∑ i in properDivisors n, i + n = n + n
⊢ ∑ i in properDivisors n, i = n
Theorem: Submodule.map₂_eq_span_image2
File: Mathlib/Algebra/Module/Submodule/Bilinear.lean

tactic: rw [← map₂_span_span, span_eq, span_eq]
state_before: ι : Sort uι
R : Type u_1
M : Type u_2
N : Type u_4
P : Type u_3
inst✝⁶ : CommSemiring R
inst✝⁵ : AddCommMonoid M
inst✝⁴ : AddCommMonoid N
inst✝³ : AddCommMonoid P
inst✝² : Module R M
inst✝¹ : Module R N
inst✝ : Module R P
f : M →ₗ[R] N →ₗ[R] P
p : Submodule R M
q : Submodule R N
⊢ map₂ f p q = span R (image2 (fun m n => ↑(↑f m) n) ↑p ↑q)
Theorem: RatFunc.mk_eq_div
File: Mathlib/FieldTheory/RatFunc.lean

tactic: simp only [mk_eq_div', ofFractionRing_div, ofFractionRing_algebraMap]
state_before: K : Type u
inst✝¹ : CommRing K
inst✝ : IsDomain K
p q : K[X]
⊢ RatFunc.mk p q = ↑(algebraMap K[X] (RatFunc K)) p / ↑(algebraMap K[X] (RatFunc K)) q
Theorem: div_div_self'
File: Mathlib/Algebra/Group/Basic.lean

tactic: simpa using mul_inv_cancel_left a b
state_before: α : Type ?u.68232
β : Type ?u.68235
G : Type u_1
inst✝ : CommGroup G
a✝ b✝ c d a b : G
⊢ a / (a / b) = b
Theorem: Finsupp.erase_same
File: Mathlib/Data/Finsupp/Defs.lean

tactic: classical simp only [erase, coe_mk, ite_true]
state_before: α : Type u_1
β : Type ?u.163190
γ : Type ?u.163193
ι : Type ?u.163196
M : Type u_2
M' : Type ?u.163202
N : Type ?u.163205
P : Type ?u.163208
G : Type ?u.163211
H : Type ?u.163214
R : Type ?u.163217
S : Type ?u.163220
inst✝ : Zero M
a : α
f : α →₀ M
⊢ ↑(erase a f) a = 0

tactic: simp only [erase, coe_mk, ite_true]
state_before: α : Type u_1
β : Type ?u.163190
γ : Type ?u.163193
ι : Type ?u.163196
M : Type u_2
M' : Type ?u.163202
N : Type ?u.163205
P : Type ?u.163208
G : Type ?u.163211
H : Type ?u.163214
R : Type ?u.163217
S : Type ?u.163220
inst✝ : Zero M
a : α
f : α →₀ M
⊢ ↑(erase a f) a = 0
Theorem: AddCircle.closedBall_eq_univ_of_half_period_le
File: Mathlib/Analysis/Normed/Group/AddCircle.lean

tactic: simpa only [mem_closedBall, dist_eq_norm] using (norm_le_half_period p hp).trans hε
state_before: p : ℝ
hp : p ≠ 0
x✝ : AddCircle p
ε : ℝ
hε : abs p / 2 ≤ ε
x : AddCircle p
⊢ x ∈ closedBall x✝ ε
Theorem: SimpleGraph.Walk.copy_cons
File: Mathlib/Combinatorics/SimpleGraph/Connectivity.lean

tactic: subst_vars
state_before: V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
u v w u' w' : V
h : Adj G u v
p : Walk G v w
hu : u = u'
hw : w = w'
⊢ Walk.copy (cons h p) hu hw = cons (_ : Adj G u' v) (Walk.copy p (_ : v = v) hw)

tactic: rfl
state_before: V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
v u' w' : V
h : Adj G u' v
p : Walk G v w'
⊢ Walk.copy (cons h p) (_ : u' = u') (_ : w' = w') = cons (_ : Adj G u' v) (Walk.copy p (_ : v = v) (_ : w' = w'))
Theorem: AlgebraicGeometry.StructureSheaf.germ_toOpen
File: Mathlib/AlgebraicGeometry/StructureSheaf.lean

tactic: rw [← toOpen_germ]
state_before: R : Type u
inst✝ : CommRing R
U : Opens ↑(PrimeSpectrum.Top R)
x : { x // x ∈ U }
f : R
⊢ ↑(germ (Sheaf.presheaf (structureSheaf R)) x) (↑(toOpen R U) f) = ↑(toStalk R ↑x) f

tactic: rfl
state_before: R : Type u
inst✝ : CommRing R
U : Opens ↑(PrimeSpectrum.Top R)
x : { x // x ∈ U }
f : R
⊢ ↑(germ (Sheaf.presheaf (structureSheaf R)) x) (↑(toOpen R U) f) =
    ↑(toOpen R U ≫ germ (Sheaf.presheaf (structureSheaf R)) x) f
Theorem: exists_nhds_ne_inf_principal_neBot
File: Mathlib/Topology/SubsetProperties.lean

tactic: by_contra' H
state_before: α : Type u
β : Type v
ι : Type ?u.95561
π : ι → Type ?u.95566
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace β
s✝ t s : Set α
hs : IsCompact s
hs' : Set.Infinite s
⊢ ∃ z, z ∈ s ∧ NeBot (𝓝[{z}ᶜ] z ⊓ 𝓟 s)

tactic: simp_rw [not_neBot] at H
state_before: α : Type u
β : Type v
ι : Type ?u.95561
π : ι → Type ?u.95566
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace β
s✝ t s : Set α
hs : IsCompact s
hs' : Set.Infinite s
H : ∀ (z : α), z ∈ s → ¬NeBot (𝓝[{z}ᶜ] z ⊓ 𝓟 s)
⊢ False

tactic: exact hs' (hs.finite <| discreteTopology_subtype_iff.mpr H)
state_before: α : Type u
β : Type v
ι : Type ?u.95561
π : ι → Type ?u.95566
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace β
s✝ t s : Set α
hs : IsCompact s
hs' : Set.Infinite s
H : ∀ (z : α), z ∈ s → 𝓝[{z}ᶜ] z ⊓ 𝓟 s = ⊥
⊢ False
Theorem: MvPolynomial.coeff_C_mul
File: Mathlib/Data/MvPolynomial/Basic.lean

tactic: rw [mul_def, sum_C]
state_before: R : Type u
S₁ : Type v
S₂ : Type w
S₃ : Type x
σ : Type u_1
a✝ a' a₁ a₂ : R
e : ℕ
n m✝ : σ
s : σ →₀ ℕ
inst✝¹ : CommSemiring R
inst✝ : CommSemiring S₁
p✝ q : MvPolynomial σ R
m : σ →₀ ℕ
a : R
p : MvPolynomial σ R
⊢ coeff m (↑C a * p) = a * coeff m p

tactic: simp
state_before: R : Type u
S₁ : Type v
S₂ : Type w
S₃ : Type x
σ : Type u_1
a✝ a' a₁ a₂ : R
e : ℕ
n m✝ : σ
s : σ →₀ ℕ
inst✝¹ : CommSemiring R
inst✝ : CommSemiring S₁
p✝ q : MvPolynomial σ R
m : σ →₀ ℕ
a : R
p : MvPolynomial σ R
⊢ (sum p fun n b => ↑(monomial (0 + n)) (0 * b)) = 0

tactic: simp (config := { contextual := true }) [sum_def, coeff_sum]
state_before: R : Type u
S₁ : Type v
S₂ : Type w
S₃ : Type x
σ : Type u_1
a✝ a' a₁ a₂ : R
e : ℕ
n m✝ : σ
s : σ →₀ ℕ
inst✝¹ : CommSemiring R
inst✝ : CommSemiring S₁
p✝ q : MvPolynomial σ R
m : σ →₀ ℕ
a : R
p : MvPolynomial σ R
⊢ coeff m (sum p fun n b => ↑(monomial (0 + n)) (a * b)) = a * coeff m p
Theorem: Finset.image₂_def
File: Mathlib/Data/Finset/Functor.lean

tactic: ext
state_before: α✝ β✝ : Type u
inst✝ : (P : Prop) → Decidable P
α β γ : Type u_1
f : α → β → γ
s : Finset α
t : Finset β
⊢ image₂ f s t = Seq.seq (f <$> s) fun x => t

tactic: simp [mem_sup]
state_before: case a
α✝ β✝ : Type u
inst✝ : (P : Prop) → Decidable P
α β γ : Type u_1
f : α → β → γ
s : Finset α
t : Finset β
a✝ : γ
⊢ a✝ ∈ image₂ f s t ↔ a✝ ∈ Seq.seq (f <$> s) fun x => t
Theorem: TopologicalSpace.Closeds.mem_iInf
File: Mathlib/Topology/Sets/Closeds.lean

tactic: simp [iInf]
state_before: ι✝ : Type ?u.13819
α : Type u_2
β : Type ?u.13825
inst✝¹ : TopologicalSpace α
inst✝ : TopologicalSpace β
ι : Sort u_1
x : α
s : ι → Closeds α
⊢ x ∈ iInf s ↔ ∀ (i : ι), x ∈ s i
Theorem: Convex.uniformContinuous_gauge
File: Mathlib/Analysis/Convex/Gauge.lean

tactic: obtain ⟨r, hr₀, hr⟩ := Metric.mem_nhds_iff.1 h₀
state_before: 𝕜 : Type ?u.302548
E : Type u_1
F : Type ?u.302554
inst✝¹ : SeminormedAddCommGroup E
inst✝ : NormedSpace ℝ E
s : Set E
r : ℝ
x : E
hc : Convex ℝ s
h₀ : s ∈ 𝓝 0
⊢ UniformContinuous (gauge s)

tactic: lift r to ℝ≥0 using le_of_lt hr₀
state_before: case intro.intro
𝕜 : Type ?u.302548
E : Type u_1
F : Type ?u.302554
inst✝¹ : SeminormedAddCommGroup E
inst✝ : NormedSpace ℝ E
s : Set E
r✝ : ℝ
x : E
hc : Convex ℝ s
h₀ : s ∈ 𝓝 0
r : ℝ
hr₀ : r > 0
hr : Metric.ball 0 r ⊆ s
⊢ UniformContinuous (gauge s)

tactic: exact (hc.lipschitzWith_gauge hr₀ hr).uniformContinuous
state_before: case intro.intro.intro
𝕜 : Type ?u.302548
E : Type u_1
F : Type ?u.302554
inst✝¹ : SeminormedAddCommGroup E
inst✝ : NormedSpace ℝ E
s : Set E
r✝ : ℝ
x : E
hc : Convex ℝ s
h₀ : s ∈ 𝓝 0
r : ℝ≥0
hr₀ : ↑r > 0
hr : Metric.ball 0 ↑r ⊆ s
⊢ UniformContinuous (gauge s)
Theorem: Filter.Tendsto.prod_mk_nhds
File: Mathlib/Topology/Constructions.lean

tactic: rw [nhds_prod_eq]
state_before: α : Type u
β : Type v
γ✝ : Type ?u.40052
δ : Type ?u.40055
ε : Type ?u.40058
ζ : Type ?u.40061
inst✝⁵ : TopologicalSpace α
inst✝⁴ : TopologicalSpace β
inst✝³ : TopologicalSpace γ✝
inst✝² : TopologicalSpace δ
inst✝¹ : TopologicalSpace ε
inst✝ : TopologicalSpace ζ
γ : Type u_1
a : α
b : β
f : Filter γ
ma : γ → α
mb : γ → β
ha : Tendsto ma f (𝓝 a)
hb : Tendsto mb f (𝓝 b)
⊢ Tendsto (fun c => (ma c, mb c)) f (𝓝 (a, b))

tactic: exact Filter.Tendsto.prod_mk ha hb
state_before: α : Type u
β : Type v
γ✝ : Type ?u.40052
δ : Type ?u.40055
ε : Type ?u.40058
ζ : Type ?u.40061
inst✝⁵ : TopologicalSpace α
inst✝⁴ : TopologicalSpace β
inst✝³ : TopologicalSpace γ✝
inst✝² : TopologicalSpace δ
inst✝¹ : TopologicalSpace ε
inst✝ : TopologicalSpace ζ
γ : Type u_1
a : α
b : β
f : Filter γ
ma : γ → α
mb : γ → β
ha : Tendsto ma f (𝓝 a)
hb : Tendsto mb f (𝓝 b)
⊢ Tendsto (fun c => (ma c, mb c)) f (𝓝 a ×ˢ 𝓝 b)
Theorem: Int.mul_comm
File: Std/Data/Int/Lemmas.lean

tactic: cases a <;> cases b <;> simp [Nat.mul_comm]
state_before: a b : Int
⊢ a * b = b * a
Theorem: Set.infinite_range_of_injective
File: Mathlib/Data/Set/Finite.lean

tactic: rw [← image_univ, infinite_image_iff (injOn_of_injective hi _)]
state_before: α : Type u
β : Type v
ι : Sort w
γ : Type x
inst✝ : Infinite α
f : α → β
hi : Injective f
⊢ Set.Infinite (range f)

tactic: exact infinite_univ
state_before: α : Type u
β : Type v
ι : Sort w
γ : Type x
inst✝ : Infinite α
f : α → β
hi : Injective f
⊢ Set.Infinite univ
Theorem: CochainComplex.from_single₀_ext
File: Mathlib/Algebra/Homology/Single.lean

tactic: ext
state_before: V : Type u
inst✝² : Category V
inst✝¹ : HasZeroMorphisms V
inst✝ : HasZeroObject V
C : CochainComplex V ℕ
X : V
f g : (single₀ V).obj X ⟶ C
h : Hom.f f 0 = Hom.f g 0
⊢ ↑(fromSingle₀Equiv C X) f = ↑(fromSingle₀Equiv C X) g

tactic: exact h
state_before: case a
V : Type u
inst✝² : Category V
inst✝¹ : HasZeroMorphisms V
inst✝ : HasZeroObject V
C : CochainComplex V ℕ
X : V
f g : (single₀ V).obj X ⟶ C
h : Hom.f f 0 = Hom.f g 0
⊢ ↑(↑(fromSingle₀Equiv C X) f) = ↑(↑(fromSingle₀Equiv C X) g)
Theorem: Finite.card_subtype_le
File: Mathlib/Data/Finite/Card.lean

tactic: haveI := Fintype.ofFinite α
state_before: α : Type u_1
β : Type ?u.6239
γ : Type ?u.6242
inst✝ : Finite α
p : α → Prop
⊢ Nat.card { x // p x } ≤ Nat.card α

tactic: simpa only [Nat.card_eq_fintype_card, ge_iff_le] using Fintype.card_subtype_le p
state_before: α : Type u_1
β : Type ?u.6239
γ : Type ?u.6242
inst✝ : Finite α
p : α → Prop
this : Fintype α
⊢ Nat.card { x // p x } ≤ Nat.card α
Theorem: Finset.Nat.antidiagonal_succ'
File: Mathlib/Data/Finset/NatAntidiagonal.lean

tactic: simp
state_before: n : ℕ
⊢ ¬(n + 1, 0) ∈
      map (Function.Embedding.prodMap (Function.Embedding.refl ℕ) { toFun := Nat.succ, inj' := Nat.succ_injective })
        (antidiagonal n)

tactic: apply eq_of_veq
state_before: n : ℕ
⊢ antidiagonal (n + 1) =
    cons (n + 1, 0)
      (map (Function.Embedding.prodMap (Function.Embedding.refl ℕ) { toFun := Nat.succ, inj' := Nat.succ_injective })
        (antidiagonal n))
      (_ :
        ¬(n + 1, 0) ∈
            map
              (Function.Embedding.prodMap (Function.Embedding.refl ℕ) { toFun := Nat.succ, inj' := Nat.succ_injective })
              (antidiagonal n))

tactic: rw [cons_val, map_val]
state_before: case a
n : ℕ
⊢ (antidiagonal (n + 1)).val =
    (cons (n + 1, 0)
        (map (Function.Embedding.prodMap (Function.Embedding.refl ℕ) { toFun := Nat.succ, inj' := Nat.succ_injective })
          (antidiagonal n))
        (_ :
          ¬(n + 1, 0) ∈
              map
                (Function.Embedding.prodMap (Function.Embedding.refl ℕ)
                  { toFun := Nat.succ, inj' := Nat.succ_injective })
                (antidiagonal n))).val

tactic: exact Multiset.Nat.antidiagonal_succ'
state_before: case a
n : ℕ
⊢ (antidiagonal (n + 1)).val =
    (n + 1, 0) ::ₘ
      Multiset.map
        (↑(Function.Embedding.prodMap (Function.Embedding.refl ℕ) { toFun := Nat.succ, inj' := Nat.succ_injective }))
        (antidiagonal n).val
Theorem: tendsto_cocompact_of_tendsto_dist_comp_atTop
File: Mathlib/Topology/MetricSpace/Basic.lean

tactic: refine' Tendsto.mono_right _ (comap_dist_right_atTop_le_cocompact x)
state_before: α : Type u
β : Type v
X : Type ?u.547230
ι : Type ?u.547233
inst✝ : PseudoMetricSpace α
f : β → α
l : Filter β
x : α
h : Tendsto (fun y => dist (f y) x) l atTop
⊢ Tendsto f l (cocompact α)

tactic: rwa [tendsto_comap_iff]
state_before: α : Type u
β : Type v
X : Type ?u.547230
ι : Type ?u.547233
inst✝ : PseudoMetricSpace α
f : β → α
l : Filter β
x : α
h : Tendsto (fun y => dist (f y) x) l atTop
⊢ Tendsto f l (comap (fun y => dist y x) atTop)
Theorem: Primrec.list_findIdx
File: Mathlib/Computability/Primrec.lean

tactic: dsimp
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.316436
σ : Type ?u.316439
inst✝³ : Primcodable α
inst✝² : Primcodable β
inst✝¹ : Primcodable γ
inst✝ : Primcodable σ
f : α → List β
p : α → β → Bool
hf : Primrec f
hp : Primrec₂ p
a : α
⊢ List.foldr (fun b s => bif p (a, b, s).fst (a, b, s).snd.fst then 0 else Nat.succ (a, b, s).snd.snd) 0 (f a) =
    List.findIdx (p a) (f a)

tactic: induction f a <;> simp [List.findIdx_cons, *]
state_before: α : Type u_2
β : Type u_1
γ : Type ?u.316436
σ : Type ?u.316439
inst✝³ : Primcodable α
inst✝² : Primcodable β
inst✝¹ : Primcodable γ
inst✝ : Primcodable σ
f : α → List β
p : α → β → Bool
hf : Primrec f
hp : Primrec₂ p
a : α
⊢ List.foldr (fun b s => bif p a b then 0 else Nat.succ s) 0 (f a) = List.findIdx (p a) (f a)
Theorem: nilpotent_of_surjective
File: Mathlib/GroupTheory/Nilpotent.lean

tactic: rcases h with ⟨n, hn⟩
state_before: G : Type u_2
inst✝² : Group G
H : Subgroup G
inst✝¹ : Normal H
G' : Type u_1
inst✝ : Group G'
h : Group.IsNilpotent G
f : G →* G'
hf : Function.Surjective ↑f
⊢ Group.IsNilpotent G'

tactic: use n
state_before: case mk.intro
G : Type u_2
inst✝² : Group G
H : Subgroup G
inst✝¹ : Normal H
G' : Type u_1
inst✝ : Group G'
f : G →* G'
hf : Function.Surjective ↑f
n : ℕ
hn : upperCentralSeries G n = ⊤
⊢ Group.IsNilpotent G'

tactic: apply eq_top_iff.mpr
state_before: case mk.intro
G : Type u_2
inst✝² : Group G
H : Subgroup G
inst✝¹ : Normal H
G' : Type u_1
inst✝ : Group G'
f : G →* G'
hf : Function.Surjective ↑f
n : ℕ
hn : upperCentralSeries G n = ⊤
⊢ upperCentralSeries G' n = ⊤

tactic: calc
  ⊤ = f.range := symm (f.range_top_of_surjective hf)
  _ = Subgroup.map f ⊤ := (MonoidHom.range_eq_map _)
  _ = Subgroup.map f (upperCentralSeries G n) := by rw [hn]
  _ ≤ upperCentralSeries G' n := upperCentralSeries.map hf n
state_before: case mk.intro
G : Type u_2
inst✝² : Group G
H : Subgroup G
inst✝¹ : Normal H
G' : Type u_1
inst✝ : Group G'
f : G →* G'
hf : Function.Surjective ↑f
n : ℕ
hn : upperCentralSeries G n = ⊤
⊢ ⊤ ≤ upperCentralSeries G' n

tactic: rw [hn]
state_before: G : Type u_2
inst✝² : Group G
H : Subgroup G
inst✝¹ : Normal H
G' : Type u_1
inst✝ : Group G'
f : G →* G'
hf : Function.Surjective ↑f
n : ℕ
hn : upperCentralSeries G n = ⊤
⊢ Subgroup.map f ⊤ = Subgroup.map f (upperCentralSeries G n)
Theorem: sdiff_le_iff'
File: Mathlib/Order/Heyting/Basic.lean

tactic: rw [sdiff_le_iff, sup_comm]
state_before: ι : Type ?u.88720
α : Type u_1
β : Type ?u.88726
inst✝ : GeneralizedCoheytingAlgebra α
a b c d : α
⊢ a \ b ≤ c ↔ a ≤ c ⊔ b