tasksource/leandojo huggingface dataset:
Theorem: MeasureTheory.L1.SimpleFunc.setToL1SCLM_congr_left
File: Mathlib/MeasureTheory/Integral/SetToL1.lean

tactic: rw [h]
state_before: α : Type u_1
E : Type u_2
F : Type u_3
F' : Type ?u.794201
G : Type ?u.794204
𝕜 : Type ?u.794207
p : ℝ≥0∞
inst✝⁹ : NormedAddCommGroup E
inst✝⁸ : NormedSpace ℝ E
inst✝⁷ : NormedAddCommGroup F
inst✝⁶ : NormedSpace ℝ F
inst✝⁵ : NormedAddCommGroup F'
inst✝⁴ : NormedSpace ℝ F'
inst✝³ : NormedAddCommGroup G
m : MeasurableSpace α
μ : Measure α
inst✝² : NormedField 𝕜
inst✝¹ : NormedSpace 𝕜 E
inst✝ : NormedSpace 𝕜 F
T T' T'' : Set α → E →L[ℝ] F
C C' C'' : ℝ
hT : DominatedFinMeasAdditive μ T C
hT' : DominatedFinMeasAdditive μ T' C'
h : T = T'
f : { x // x ∈ simpleFunc E 1 μ }
x✝² : Set α
x✝¹ : MeasurableSet x✝²
x✝ : ↑↑μ x✝² < ⊤
⊢ T x✝² = T' x✝²
Theorem: Filter.map_add_atTop_eq_nat
File: Mathlib/Order/Filter/AtTopBot.lean

tactic: rw [tsub_add_cancel_of_le h]
state_before: ι : Type ?u.342691
ι' : Type ?u.342694
α : Type ?u.342697
β : Type ?u.342700
γ : Type ?u.342703
k a : ℕ
h : a ≥ k
⊢ a ≤ (fun a => a - k) a + k
Theorem: add_div
File: Mathlib/Algebra/Field/Basic.lean

tactic: simp_rw [div_eq_mul_inv, add_mul]
state_before: α : Type u_1
β : Type ?u.34
K : Type ?u.37
inst✝ : DivisionSemiring α
a✝ b✝ c✝ d a b c : α
⊢ (a + b) / c = a / c + b / c
Theorem: Computation.LiftRelAux.swap
File: Mathlib/Data/Seq/Computation.lean

tactic: cases' a with a ca <;> cases' b with b cb <;> simp only [LiftRelAux]
state_before: α : Type u
β : Type v
γ : Type w
R : α → β → Prop
C : Computation α → Computation β → Prop
a : α ⊕ Computation α
b : β ⊕ Computation β
⊢ LiftRelAux (Function.swap R) (Function.swap C) b a = LiftRelAux R C a b
Theorem: EuclideanGeometry.dist_inversion_inversion
File: Mathlib/Geometry/Euclidean/Inversion.lean

tactic: dsimp only [inversion]
state_before: V : Type u_2
P : Type u_1
inst✝³ : NormedAddCommGroup V
inst✝² : InnerProductSpace ℝ V
inst✝¹ : MetricSpace P
inst✝ : NormedAddTorsor V P
a b c d x y z : P
R✝ : ℝ
hx : x ≠ c
hy : y ≠ c
R : ℝ
⊢ dist (inversion c R x) (inversion c R y) = R ^ 2 / (dist x c * dist y c) * dist x y

tactic: simp_rw [dist_vadd_cancel_right, dist_eq_norm_vsub V _ c]
state_before: V : Type u_2
P : Type u_1
inst✝³ : NormedAddCommGroup V
inst✝² : InnerProductSpace ℝ V
inst✝¹ : MetricSpace P
inst✝ : NormedAddTorsor V P
a b c d x y z : P
R✝ : ℝ
hx : x ≠ c
hy : y ≠ c
R : ℝ
⊢ dist ((R / dist x c) ^ 2 • (x -ᵥ c) +ᵥ c) ((R / dist y c) ^ 2 • (y -ᵥ c) +ᵥ c) =
    R ^ 2 / (dist x c * dist y c) * dist x y

tactic: simpa only [dist_vsub_cancel_right] using
  dist_div_norm_sq_smul (vsub_ne_zero.2 hx) (vsub_ne_zero.2 hy) R
state_before: V : Type u_2
P : Type u_1
inst✝³ : NormedAddCommGroup V
inst✝² : InnerProductSpace ℝ V
inst✝¹ : MetricSpace P
inst✝ : NormedAddTorsor V P
a b c d x y z : P
R✝ : ℝ
hx : x ≠ c
hy : y ≠ c
R : ℝ
⊢ dist ((R / ‖x -ᵥ c‖) ^ 2 • (x -ᵥ c)) ((R / ‖y -ᵥ c‖) ^ 2 • (y -ᵥ c)) = R ^ 2 / (‖x -ᵥ c‖ * ‖y -ᵥ c‖) * dist x y
Theorem: List.join_filter_ne_nil
File: Mathlib/Data/List/Join.lean

tactic: simp [join_filter_isEmpty_eq_false, ← isEmpty_iff_eq_nil]
state_before: α : Type u_1
β : Type ?u.2829
inst✝ : DecidablePred fun l => l ≠ []
L : List (List α)
⊢ join (filter (fun l => decide (l ≠ [])) L) = join L
Theorem: Complex.cos_neg
File: Mathlib/Data/Complex/Exponential.lean

tactic: simp [cos, sub_eq_add_neg, exp_neg, add_comm]
state_before: x y : ℂ
⊢ cos (-x) = cos x
Theorem: Left.inv_le_one_iff
File: Mathlib/Algebra/Order/Group/Defs.lean

tactic: rw [← mul_le_mul_iff_left a]
state_before: α : Type u
inst✝² : Group α
inst✝¹ : LE α
inst✝ : CovariantClass α α (fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a b c d : α
⊢ a⁻¹ ≤ 1 ↔ 1 ≤ a

tactic: simp
state_before: α : Type u
inst✝² : Group α
inst✝¹ : LE α
inst✝ : CovariantClass α α (fun x x_1 => x * x_1) fun x x_1 => x ≤ x_1
a b c d : α
⊢ a * a⁻¹ ≤ a * 1 ↔ 1 ≤ a
Theorem: ZMod.eq_zero_iff_gcd_ne_one
File: Mathlib/Data/ZMod/Coprime.lean

tactic: rw [Ne, Int.gcd_comm, Int.gcd_eq_one_iff_coprime,
  (Nat.prime_iff_prime_int.1 pp.1).coprime_iff_not_dvd, Classical.not_not,
  int_cast_zmod_eq_zero_iff_dvd]
state_before: a : ℤ
p : ℕ
pp : Fact (Nat.Prime p)
⊢ ↑a = 0 ↔ Int.gcd a ↑p ≠ 1
Theorem: FreeAlgebra.ι_comp_lift
File: Mathlib/Algebra/FreeAlgebra.lean

tactic: ext
state_before: R : Type u_3
inst✝² : CommSemiring R
X : Type u_1
A : Type u_2
inst✝¹ : Semiring A
inst✝ : Algebra R A
f : X → A
⊢ ↑(↑(lift R) f) ∘ ι R = f

tactic: rw [Function.comp_apply, ι_def, lift]
state_before: case h
R : Type u_3
inst✝² : CommSemiring R
X : Type u_1
A : Type u_2
inst✝¹ : Semiring A
inst✝ : Algebra R A
f : X → A
x✝ : X
⊢ (↑(↑(lift R) f) ∘ ι R) x✝ = f x✝

tactic: rfl
state_before: case h
R : Type u_3
inst✝² : CommSemiring R
X : Type u_1
A : Type u_2
inst✝¹ : Semiring A
inst✝ : Algebra R A
f : X → A
x✝ : X
⊢ ↑(↑{ toFun := FreeAlgebra.liftAux R, invFun := fun F => ↑F ∘ ι R,
              left_inv := (_ : ∀ (f : X → A), (fun F => ↑F ∘ ι R) (FreeAlgebra.liftAux R f) = f),
              right_inv := (_ : ∀ (F : FreeAlgebra R X →ₐ[R] A), FreeAlgebra.liftAux R ((fun F => ↑F ∘ ι R) F) = F) }
          f)
      (Quot.mk (Rel R X) (Pre.of x✝)) =
    f x✝
Theorem: Option.eq_none_iff_forall_not_mem
File: Std/Data/Option/Lemmas.lean

tactic: rw [e] at h
state_before: α✝ : Type u_1
o : Option α✝
e : o = none
a : α✝
h : a ∈ o
⊢ False

tactic: (cases h)
state_before: α✝ : Type u_1
o : Option α✝
e : o = none
a : α✝
h : a ∈ none
⊢ False

tactic: cases h
state_before: α✝ : Type u_1
o : Option α✝
e : o = none
a : α✝
h : a ∈ none
⊢ False

tactic: simp
state_before: α✝ : Type u_1
o : Option α✝
h : ∀ (a : α✝), ¬a ∈ o
⊢ ∀ (a : α✝), a ∈ o ↔ a ∈ none

tactic: exact h
state_before: α✝ : Type u_1
o : Option α✝
h : ∀ (a : α✝), ¬a ∈ o
⊢ ∀ (a : α✝), ¬o = some a
Theorem: intervalIntegral.intervalIntegrable_inv
File: Mathlib/Analysis/SpecialFunctions/Integrals.lean

tactic: simpa only [one_div] using intervalIntegrable_one_div h hf
state_before: a b : ℝ
n : ℕ
f : ℝ → ℝ
μ ν : MeasureTheory.Measure ℝ
inst✝ : IsLocallyFiniteMeasure μ
c d : ℝ
h : ∀ (x : ℝ), x ∈ [[a, b]] → f x ≠ 0
hf : ContinuousOn f [[a, b]]
⊢ IntervalIntegrable (fun x => (f x)⁻¹) μ a b
Theorem: EMetric.exists_continuous_real_forall_closedBall_subset
File: Mathlib/Topology/MetricSpace/PartitionOfUnity.lean

tactic: simpa only [mem_inter_iff, forall_and, mem_preimage, mem_iInter, @forall_swap ι X] using
  exists_continuous_forall_mem_convex_of_local_const exists_forall_closedBall_subset_aux₂
    (exists_forall_closedBall_subset_aux₁ hK hU hKU hfin)
state_before: ι : Type u_2
X : Type u_1
inst✝ : EMetricSpace X
K U : ι → Set X
hK : ∀ (i : ι), IsClosed (K i)
hU : ∀ (i : ι), IsOpen (U i)
hKU : ∀ (i : ι), K i ⊆ U i
hfin : LocallyFinite K
⊢ ∃ δ, (∀ (x : X), 0 < ↑δ x) ∧ ∀ (i : ι) (x : X), x ∈ K i → closedBall x (ENNReal.ofReal (↑δ x)) ⊆ U i
Theorem: Trivialization.mem_source
File: Mathlib/Topology/FiberBundle/Trivialization.lean

tactic: rw [e.source_eq, mem_preimage]
state_before: ι : Type ?u.23235
B : Type u_2
F : Type u_3
E : B → Type ?u.23246
Z : Type u_1
inst✝³ : TopologicalSpace B
inst✝² : TopologicalSpace F
proj : Z → B
inst✝¹ : TopologicalSpace Z
inst✝ : TopologicalSpace (TotalSpace E)
e : Trivialization F proj
x : Z
⊢ x ∈ e.source ↔ proj x ∈ e.baseSet
Theorem: smul_add_smul_le_smul_add_smul
File: Mathlib/Algebra/Order/Module.lean

tactic: obtain ⟨b, rfl⟩ := exists_add_of_le hab
state_before: k : Type u_2
M : Type u_1
N : Type ?u.53981
inst✝⁴ : OrderedRing k
inst✝³ : OrderedAddCommGroup M
inst✝² : Module k M
inst✝¹ : OrderedSMul k M
a✝ b✝ : M
c✝ : k
inst✝ : ContravariantClass M M (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
a b : k
c d : M
hab : a ≤ b
hcd : c ≤ d
⊢ a • d + b • c ≤ a • c + b • d

tactic: obtain ⟨d, rfl⟩ := exists_add_of_le hcd
state_before: case intro
k : Type u_2
M : Type u_1
N : Type ?u.53981
inst✝⁴ : OrderedRing k
inst✝³ : OrderedAddCommGroup M
inst✝² : Module k M
inst✝¹ : OrderedSMul k M
a✝ b✝ : M
c✝ : k
inst✝ : ContravariantClass M M (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
a : k
c d : M
hcd : c ≤ d
b : k
hab : a ≤ a + b
⊢ a • d + (a + b) • c ≤ a • c + (a + b) • d

tactic: rw [smul_add, add_right_comm, smul_add, ← add_assoc, add_smul _ _ d]
state_before: case intro.intro
k : Type u_2
M : Type u_1
N : Type ?u.53981
inst✝⁴ : OrderedRing k
inst✝³ : OrderedAddCommGroup M
inst✝² : Module k M
inst✝¹ : OrderedSMul k M
a✝ b✝ : M
c✝ : k
inst✝ : ContravariantClass M M (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
a : k
c : M
b : k
hab : a ≤ a + b
d : M
hcd : c ≤ c + d
⊢ a • (c + d) + (a + b) • c ≤ a • c + (a + b) • (c + d)

tactic: rw [le_add_iff_nonneg_right] at hab hcd
state_before: case intro.intro
k : Type u_2
M : Type u_1
N : Type ?u.53981
inst✝⁴ : OrderedRing k
inst✝³ : OrderedAddCommGroup M
inst✝² : Module k M
inst✝¹ : OrderedSMul k M
a✝ b✝ : M
c✝ : k
inst✝ : ContravariantClass M M (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
a : k
c : M
b : k
hab : a ≤ a + b
d : M
hcd : c ≤ c + d
⊢ a • c + (a + b) • c + a • d ≤ a • c + (a + b) • c + (a • d + b • d)

tactic: exact add_le_add_left (le_add_of_nonneg_right <| smul_nonneg hab hcd) _
state_before: case intro.intro
k : Type u_2
M : Type u_1
N : Type ?u.53981
inst✝⁴ : OrderedRing k
inst✝³ : OrderedAddCommGroup M
inst✝² : Module k M
inst✝¹ : OrderedSMul k M
a✝ b✝ : M
c✝ : k
inst✝ : ContravariantClass M M (fun x x_1 => x + x_1) fun x x_1 => x ≤ x_1
a : k
c : M
b : k
hab : 0 ≤ b
d : M
hcd : 0 ≤ d
⊢ a • c + (a + b) • c + a • d ≤ a • c + (a + b) • c + (a • d + b • d)
Theorem: Int.even_iff_not_odd
File: Mathlib/Data/Int/Parity.lean

tactic: rw [not_odd_iff, even_iff]
state_before: m n : ℤ
⊢ Even n ↔ ¬Odd n
Theorem: Matrix.J_inv
File: Mathlib/LinearAlgebra/SymplecticGroup.lean

tactic: refine' Matrix.inv_eq_right_inv _
state_before: l : Type u_1
R : Type u_2
inst✝² : DecidableEq l
inst✝¹ : CommRing R
inst✝ : Fintype l
⊢ (J l R)⁻¹ = -J l R

tactic: rw [Matrix.mul_neg, J_squared]
state_before: l : Type u_1
R : Type u_2
inst✝² : DecidableEq l
inst✝¹ : CommRing R
inst✝ : Fintype l
⊢ J l R ⬝ (-J l R) = 1

tactic: exact neg_neg 1
state_before: l : Type u_1
R : Type u_2
inst✝² : DecidableEq l
inst✝¹ : CommRing R
inst✝ : Fintype l
⊢ - -1 = 1
Theorem: coplanar_iff_finrank_le_two
File: Mathlib/LinearAlgebra/AffineSpace/FiniteDimensional.lean

tactic: have h : Coplanar k s ↔ Module.rank k (vectorSpan k s) ≤ 2 := Iff.rfl
state_before: k : Type u_2
V : Type u_3
P : Type u_1
ι : Type ?u.343704
inst✝⁴ : DivisionRing k
inst✝³ : AddCommGroup V
inst✝² : Module k V
inst✝¹ : AffineSpace V P
s : Set P
inst✝ : FiniteDimensional k { x // x ∈ vectorSpan k s }
⊢ Coplanar k s ↔ finrank k { x // x ∈ vectorSpan k s } ≤ 2

tactic: rw [← finrank_eq_rank] at h
state_before: k : Type u_2
V : Type u_3
P : Type u_1
ι : Type ?u.343704
inst✝⁴ : DivisionRing k
inst✝³ : AddCommGroup V
inst✝² : Module k V
inst✝¹ : AffineSpace V P
s : Set P
inst✝ : FiniteDimensional k { x // x ∈ vectorSpan k s }
h : Coplanar k s ↔ Module.rank k { x // x ∈ vectorSpan k s } ≤ 2
⊢ Coplanar k s ↔ finrank k { x // x ∈ vectorSpan k s } ≤ 2

tactic: exact_mod_cast h
state_before: k : Type u_2
V : Type u_3
P : Type u_1
ι : Type ?u.343704
inst✝⁴ : DivisionRing k
inst✝³ : AddCommGroup V
inst✝² : Module k V
inst✝¹ : AffineSpace V P
s : Set P
inst✝ : FiniteDimensional k { x // x ∈ vectorSpan k s }
h : Coplanar k s ↔ ↑(finrank k { x // x ∈ vectorSpan k s }) ≤ 2
⊢ Coplanar k s ↔ finrank k { x // x ∈ vectorSpan k s } ≤ 2
Theorem: TopCat.Sheaf.hom_ext
File: Mathlib/Topology/Sheaves/SheafCondition/Sites.lean

tactic: apply (restrictHomEquivHom F F' h).symm.injective
state_before: C : Type u
inst✝ : Category C
X : TopCat
ι : Type ?u.35577
B : ι → Opens ↑X
F : Presheaf C X
F' : Sheaf C X
h : Opens.IsBasis (Set.range B)
α β : F ⟶ F'.val
he : ∀ (i : ι), α.app (B i).op = β.app (B i).op
⊢ α = β

tactic: ext i
state_before: case a
C : Type u
inst✝ : Category C
X : TopCat
ι : Type ?u.35577
B : ι → Opens ↑X
F : Presheaf C X
F' : Sheaf C X
h : Opens.IsBasis (Set.range B)
α β : F ⟶ F'.val
he : ∀ (i : ι), α.app (B i).op = β.app (B i).op
⊢ ↑(restrictHomEquivHom F F' h).symm α = ↑(restrictHomEquivHom F F' h).symm β

tactic: exact he i.unop
state_before: case a.w.h
C : Type u
inst✝ : Category C
X : TopCat
ι : Type ?u.35577
B : ι → Opens ↑X
F : Presheaf C X
F' : Sheaf C X
h : Opens.IsBasis (Set.range B)
α β : F ⟶ F'.val
he : ∀ (i : ι), α.app (B i).op = β.app (B i).op
i : (InducedCategory (Opens ↑X) B)ᵒᵖ
⊢ (↑(restrictHomEquivHom F F' h).symm α).app i = (↑(restrictHomEquivHom F F' h).symm β).app i
Theorem: MeasureTheory.OuterMeasure.map_comap_of_surjective
File: Mathlib/MeasureTheory/Measure/OuterMeasure.lean

tactic: rw [map_apply, comap_apply, hf.image_preimage]
state_before: α : Type u_2
β✝ : Type ?u.121899
R : Type ?u.121902
R' : Type ?u.121905
ms : Set (OuterMeasure α)
m✝ : OuterMeasure α
β : Type u_1
f : α → β
hf : Surjective f
m : OuterMeasure β
s : Set β
⊢ ↑(↑(map f) (↑(comap f) m)) s = ↑m s
Theorem: IsBaseChange.iff_lift_unique
File: Mathlib/RingTheory/IsTensorProduct.lean

tactic: intros Q _ _ _ _ g
state_before: R : Type u_1
M : Type v₁
N : Type v₂
S : Type v₃
inst✝¹² : AddCommMonoid M
inst✝¹¹ : AddCommMonoid N
inst✝¹⁰ : CommRing R
inst✝⁹ : CommRing S
inst✝⁸ : Algebra R S
inst✝⁷ : Module R M
inst✝⁶ : Module R N
inst✝⁵ : Module S N
inst✝⁴ : IsScalarTower R S N
f : M →ₗ[R] N
h✝ : IsBaseChange S f
P : Type ?u.487928
Q : Type ?u.487931
inst✝³ : AddCommMonoid P
inst✝² : Module R P
inst✝¹ : AddCommMonoid Q
inst✝ : Module S Q
h : IsBaseChange S f
⊢ ∀ (Q : Type (max v₁ v₂ v₃)) [inst : AddCommMonoid Q] [inst_1 : Module R Q] [inst_2 : Module S Q]
    [inst_3 : IsScalarTower R S Q] (g : M →ₗ[R] Q), ∃! g', LinearMap.comp (↑R g') f = g

tactic: exact ⟨h.lift g, h.lift_comp g, fun g' e => h.alg_hom_ext' _ _ (e.trans (h.lift_comp g).symm)⟩
state_before: R : Type u_1
M : Type v₁
N : Type v₂
S : Type v₃
inst✝¹⁶ : AddCommMonoid M
inst✝¹⁵ : AddCommMonoid N
inst✝¹⁴ : CommRing R
inst✝¹³ : CommRing S
inst✝¹² : Algebra R S
inst✝¹¹ : Module R M
inst✝¹⁰ : Module R N
inst✝⁹ : Module S N
inst✝⁸ : IsScalarTower R S N
f : M →ₗ[R] N
h✝ : IsBaseChange S f
P : Type ?u.487928
Q✝ : Type ?u.487931
inst✝⁷ : AddCommMonoid P
inst✝⁶ : Module R P
inst✝⁵ : AddCommMonoid Q✝
inst✝⁴ : Module S Q✝
h : IsBaseChange S f
Q : Type (max v₁ v₂ v₃)
inst✝³ : AddCommMonoid Q
inst✝² : Module R Q
inst✝¹ : Module S Q
inst✝ : IsScalarTower R S Q
g : M →ₗ[R] Q
⊢ ∃! g', LinearMap.comp (↑R g') f = g
Theorem: Ordinal.cof_cof
File: Mathlib/SetTheory/Cardinal/Cofinality.lean

tactic: cases' exists_fundamental_sequence a with f hf
state_before: α : Type ?u.94563
r : α → α → Prop
a : Ordinal
⊢ cof (ord (cof a)) = cof a

tactic: cases' exists_fundamental_sequence a.cof.ord with g hg
state_before: case intro
α : Type ?u.94563
r : α → α → Prop
a : Ordinal
f : (b : Ordinal) → b < ord (cof a) → Ordinal
hf : IsFundamentalSequence a (ord (cof a)) f
⊢ cof (ord (cof a)) = cof a

tactic: exact ord_injective (hf.trans hg).cof_eq.symm
state_before: case intro.intro
α : Type ?u.94563
r : α → α → Prop
a : Ordinal
f : (b : Ordinal) → b < ord (cof a) → Ordinal
hf : IsFundamentalSequence a (ord (cof a)) f
g : (b : Ordinal) → b < ord (cof (ord (cof a))) → Ordinal
hg : IsFundamentalSequence (ord (cof a)) (ord (cof (ord (cof a)))) g
⊢ cof (ord (cof a)) = cof a
Theorem: LocallyFinite.continuousOn_iUnion'
File: Mathlib/Topology/LocallyFinite.lean

tactic: rintro x -
state_before: ι : Type u_1
ι' : Type ?u.4835
α : Type ?u.4838
X : Type u_2
Y : Type u_3
inst✝¹ : TopologicalSpace X
inst✝ : TopologicalSpace Y
f g✝ : ι → Set X
g : X → Y
hf : LocallyFinite f
hc : ∀ (i : ι) (x : X), x ∈ closure (f i) → ContinuousWithinAt g (f i) x
⊢ ContinuousOn g (⋃ (i : ι), f i)

tactic: rw [ContinuousWithinAt, hf.nhdsWithin_iUnion, tendsto_iSup]
state_before: ι : Type u_1
ι' : Type ?u.4835
α : Type ?u.4838
X : Type u_2
Y : Type u_3
inst✝¹ : TopologicalSpace X
inst✝ : TopologicalSpace Y
f g✝ : ι → Set X
g : X → Y
hf : LocallyFinite f
hc : ∀ (i : ι) (x : X), x ∈ closure (f i) → ContinuousWithinAt g (f i) x
x : X
⊢ ContinuousWithinAt g (⋃ (i : ι), f i) x

tactic: intro i
state_before: ι : Type u_1
ι' : Type ?u.4835
α : Type ?u.4838
X : Type u_2
Y : Type u_3
inst✝¹ : TopologicalSpace X
inst✝ : TopologicalSpace Y
f g✝ : ι → Set X
g : X → Y
hf : LocallyFinite f
hc : ∀ (i : ι) (x : X), x ∈ closure (f i) → ContinuousWithinAt g (f i) x
x : X
⊢ ∀ (i : ι), Tendsto g (𝓝[f i] x) (𝓝 (g x))

tactic: by_cases hx : x ∈ closure (f i)
state_before: ι : Type u_1
ι' : Type ?u.4835
α : Type ?u.4838
X : Type u_2
Y : Type u_3
inst✝¹ : TopologicalSpace X
inst✝ : TopologicalSpace Y
f g✝ : ι → Set X
g : X → Y
hf : LocallyFinite f
hc : ∀ (i : ι) (x : X), x ∈ closure (f i) → ContinuousWithinAt g (f i) x
x : X
i : ι
⊢ Tendsto g (𝓝[f i] x) (𝓝 (g x))

tactic: exact hc i _ hx
state_before: case pos
ι : Type u_1
ι' : Type ?u.4835
α : Type ?u.4838
X : Type u_2
Y : Type u_3
inst✝¹ : TopologicalSpace X
inst✝ : TopologicalSpace Y
f g✝ : ι → Set X
g : X → Y
hf : LocallyFinite f
hc : ∀ (i : ι) (x : X), x ∈ closure (f i) → ContinuousWithinAt g (f i) x
x : X
i : ι
hx : x ∈ closure (f i)
⊢ Tendsto g (𝓝[f i] x) (𝓝 (g x))

tactic: rw [mem_closure_iff_nhdsWithin_neBot, not_neBot] at hx
state_before: case neg
ι : Type u_1
ι' : Type ?u.4835
α : Type ?u.4838
X : Type u_2
Y : Type u_3
inst✝¹ : TopologicalSpace X
inst✝ : TopologicalSpace Y
f g✝ : ι → Set X
g : X → Y
hf : LocallyFinite f
hc : ∀ (i : ι) (x : X), x ∈ closure (f i) → ContinuousWithinAt g (f i) x
x : X
i : ι
hx : ¬x ∈ closure (f i)
⊢ Tendsto g (𝓝[f i] x) (𝓝 (g x))

tactic: rw [hx]
state_before: case neg
ι : Type u_1
ι' : Type ?u.4835
α : Type ?u.4838
X : Type u_2
Y : Type u_3
inst✝¹ : TopologicalSpace X
inst✝ : TopologicalSpace Y
f g✝ : ι → Set X
g : X → Y
hf : LocallyFinite f
hc : ∀ (i : ι) (x : X), x ∈ closure (f i) → ContinuousWithinAt g (f i) x
x : X
i : ι
hx : 𝓝[f i] x = ⊥
⊢ Tendsto g (𝓝[f i] x) (𝓝 (g x))

tactic: exact tendsto_bot
state_before: case neg
ι : Type u_1
ι' : Type ?u.4835
α : Type ?u.4838
X : Type u_2
Y : Type u_3
inst✝¹ : TopologicalSpace X
inst✝ : TopologicalSpace Y
f g✝ : ι → Set X
g : X → Y
hf : LocallyFinite f
hc : ∀ (i : ι) (x : X), x ∈ closure (f i) → ContinuousWithinAt g (f i) x
x : X
i : ι
hx : 𝓝[f i] x = ⊥
⊢ Tendsto g ⊥ (𝓝 (g x))
Theorem: List.Ico.length
File: Mathlib/Data/List/Intervals.lean

tactic: dsimp [Ico]
state_before: n m : ℕ
⊢ List.length (Ico n m) = m - n

tactic: simp only [length_range']
state_before: n m : ℕ
⊢ List.length (range' n (m - n)) = m - n
Theorem: Int.alternating_sum_range_choose
File: Mathlib/Data/Nat/Choose/Sum.lean

tactic: cases n
state_before: R : Type ?u.168155
n : ℕ
⊢ ∑ m in range (n + 1), (-1) ^ m * ↑(Nat.choose n m) = if n = 0 then 1 else 0

tactic: case succ n =>
  have h := add_pow (-1 : ℤ) 1 n.succ
  simp only [one_pow, mul_one, add_left_neg] at h
  rw [← h, zero_pow (Nat.succ_pos n), if_neg (Nat.succ_ne_zero n)]
state_before: case succ
R : Type ?u.168155
n✝ : ℕ
⊢ ∑ m in range (Nat.succ n✝ + 1), (-1) ^ m * ↑(Nat.choose (Nat.succ n✝) m) = if Nat.succ n✝ = 0 then 1 else 0

tactic: simp
state_before: case zero
R : Type ?u.168155
⊢ ∑ m in range (zero + 1), (-1) ^ m * ↑(Nat.choose zero m) = if zero = 0 then 1 else 0

tactic: have h := add_pow (-1 : ℤ) 1 n.succ
state_before: R : Type ?u.168155
n : ℕ
⊢ ∑ m in range (Nat.succ n + 1), (-1) ^ m * ↑(Nat.choose (Nat.succ n) m) = if Nat.succ n = 0 then 1 else 0

tactic: simp only [one_pow, mul_one, add_left_neg] at h
state_before: R : Type ?u.168155
n : ℕ
h :
  (-1 + 1) ^ Nat.succ n = ∑ m in range (Nat.succ n + 1), (-1) ^ m * 1 ^ (Nat.succ n - m) * ↑(Nat.choose (Nat.succ n) m)
⊢ ∑ m in range (Nat.succ n + 1), (-1) ^ m * ↑(Nat.choose (Nat.succ n) m) = if Nat.succ n = 0 then 1 else 0

tactic: rw [← h, zero_pow (Nat.succ_pos n), if_neg (Nat.succ_ne_zero n)]
state_before: R : Type ?u.168155
n : ℕ
h : 0 ^ Nat.succ n = ∑ x in range (Nat.succ n + 1), (-1) ^ x * ↑(Nat.choose (Nat.succ n) x)
⊢ ∑ m in range (Nat.succ n + 1), (-1) ^ m * ↑(Nat.choose (Nat.succ n) m) = if Nat.succ n = 0 then 1 else 0
Theorem: AffineSubspace.vsub_right_mem_direction_iff_mem
File: Mathlib/LinearAlgebra/AffineSpace/AffineSubspace.lean

tactic: rw [mem_direction_iff_eq_vsub_right hp]
state_before: k : Type u_1
V : Type u_2
P : Type u_3
inst✝³ : Ring k
inst✝² : AddCommGroup V
inst✝¹ : Module k V
inst✝ : AffineSpace V P
s : AffineSubspace k P
p : P
hp : p ∈ s
p2 : P
⊢ p2 -ᵥ p ∈ direction s ↔ p2 ∈ s

tactic: simp
state_before: k : Type u_1
V : Type u_2
P : Type u_3
inst✝³ : Ring k
inst✝² : AddCommGroup V
inst✝¹ : Module k V
inst✝ : AffineSpace V P
s : AffineSubspace k P
p : P
hp : p ∈ s
p2 : P
⊢ (∃ p2_1, p2_1 ∈ s ∧ p2 -ᵥ p = p2_1 -ᵥ p) ↔ p2 ∈ s
Theorem: Multiset.Nat.card_antidiagonal
File: Mathlib/Data/Multiset/NatAntidiagonal.lean

tactic: rw [antidiagonal, coe_card, List.Nat.length_antidiagonal]
state_before: n : ℕ
⊢ ↑card (antidiagonal n) = n + 1
Theorem: Subgroup.closure_closure_coe_preimage
File: Mathlib/GroupTheory/Subgroup/Basic.lean

tactic: refine' closure_induction' (fun g hg => _) _ (fun g₁ g₂ hg₁ hg₂ => _) (fun g hg => _) hx
state_before: G : Type u_1
G' : Type ?u.207006
inst✝² : Group G
inst✝¹ : Group G'
A : Type ?u.207015
inst✝ : AddGroup A
H K : Subgroup G
k✝ k : Set G
x✝¹ : { x // x ∈ ↑(closure k) }
x : G
hx : x ∈ ↑(closure k)
x✝ : { val := x, property := hx } ∈ ⊤
⊢ { val := x, property := hx } ∈ closure (Subtype.val ⁻¹' k)

tactic: exact subset_closure hg
state_before: case refine'_1
G : Type u_1
G' : Type ?u.207006
inst✝² : Group G
inst✝¹ : Group G'
A : Type ?u.207015
inst✝ : AddGroup A
H K : Subgroup G
k✝ k : Set G
x✝¹ : { x // x ∈ ↑(closure k) }
x : G
hx : x ∈ ↑(closure k)
x✝ : { val := x, property := hx } ∈ ⊤
g : G
hg : g ∈ k
⊢ { val := g, property := (_ : g ∈ ↑(closure k)) } ∈ closure (Subtype.val ⁻¹' k)

tactic: exact one_mem _
state_before: case refine'_2
G : Type u_1
G' : Type ?u.207006
inst✝² : Group G
inst✝¹ : Group G'
A : Type ?u.207015
inst✝ : AddGroup A
H K : Subgroup G
k✝ k : Set G
x✝¹ : { x // x ∈ ↑(closure k) }
x : G
hx : x ∈ ↑(closure k)
x✝ : { val := x, property := hx } ∈ ⊤
⊢ { val := 1, property := (_ : 1 ∈ closure k) } ∈ closure (Subtype.val ⁻¹' k)

tactic: exact mul_mem
state_before: case refine'_3
G : Type u_1
G' : Type ?u.207006
inst✝² : Group G
inst✝¹ : Group G'
A : Type ?u.207015
inst✝ : AddGroup A
H K : Subgroup G
k✝ k : Set G
x✝¹ : { x // x ∈ ↑(closure k) }
x : G
hx : x ∈ ↑(closure k)
x✝ : { val := x, property := hx } ∈ ⊤
g₁ : G
g₂ : g₁ ∈ closure k
hg₁ : G
hg₂ : hg₁ ∈ closure k
⊢ { val := g₁, property := g₂ } ∈ closure (Subtype.val ⁻¹' k) →
    { val := hg₁, property := hg₂ } ∈ closure (Subtype.val ⁻¹' k) →
      { val := g₁ * hg₁, property := (_ : g₁ * hg₁ ∈ closure k) } ∈ closure (Subtype.val ⁻¹' k)

tactic: exact inv_mem
state_before: case refine'_4
G : Type u_1
G' : Type ?u.207006
inst✝² : Group G
inst✝¹ : Group G'
A : Type ?u.207015
inst✝ : AddGroup A
H K : Subgroup G
k✝ k : Set G
x✝¹ : { x // x ∈ ↑(closure k) }
x : G
hx : x ∈ ↑(closure k)
x✝ : { val := x, property := hx } ∈ ⊤
g : G
hg : g ∈ closure k
⊢ { val := g, property := hg } ∈ closure (Subtype.val ⁻¹' k) →
    { val := g⁻¹, property := (_ : g⁻¹ ∈ closure k) } ∈ closure (Subtype.val ⁻¹' k)