1337xyz1337xyz/leandojo-benchmark4-v10 huggingface dataset:
Theorem: IsAdjoinRootMonic.basis_apply
File: Mathlib/RingTheory/IsAdjoinRoot.lean

tactic: ext j
state_before: R : Type u
S : Type v
inst✝² : CommRing R
inst✝¹ : Ring S
f : R[X]
inst✝ : Algebra R S
h : IsAdjoinRootMonic S f
i : Fin f.natDegree
⊢ Finsupp.comapDomain Fin.val (h.modByMonicHom (h.root ^ ↑i)).toFinsupp ⋯ = Finsupp.single i 1
state_after: case h
R : Type u
S : Type v
inst✝² : CommRing R
inst✝¹ : Ring S
f : R[X]
inst✝ : Algebra R S
h : IsAdjoinRootMonic S f
i j : Fin f.natDegree
⊢ (Finsupp.comapDomain Fin.val (h.modByMonicHom (h.root ^ ↑i)).toFinsupp ⋯) j = (Finsupp.single i 1) j

tactic: rw [Finsupp.comapDomain_apply, modByMonicHom_root_pow]
state_before: case h
R : Type u
S : Type v
inst✝² : CommRing R
inst✝¹ : Ring S
f : R[X]
inst✝ : Algebra R S
h : IsAdjoinRootMonic S f
i j : Fin f.natDegree
⊢ (Finsupp.comapDomain Fin.val (h.modByMonicHom (h.root ^ ↑i)).toFinsupp ⋯) j = (Finsupp.single i 1) j
state_after: case h
R : Type u
S : Type v
inst✝² : CommRing R
inst✝¹ : Ring S
f : R[X]
inst✝ : Algebra R S
h : IsAdjoinRootMonic S f
i j : Fin f.natDegree
⊢ (X ^ ↑i).toFinsupp ↑j = (Finsupp.single i 1) j

case h.hdeg
R : Type u
S : Type v
inst✝² : CommRing R
inst✝¹ : Ring S
f : R[X]
inst✝ : Algebra R S
h : IsAdjoinRootMonic S f
i j : Fin f.natDegree
⊢ ↑i < f.natDegree

tactic: rw [X_pow_eq_monomial, toFinsupp_monomial, Finsupp.single_apply_left Fin.val_injective]
state_before: case h
R : Type u
S : Type v
inst✝² : CommRing R
inst✝¹ : Ring S
f : R[X]
inst✝ : Algebra R S
h : IsAdjoinRootMonic S f
i j : Fin f.natDegree
⊢ (X ^ ↑i).toFinsupp ↑j = (Finsupp.single i 1) j
state_after: no goals

tactic: exact i.is_lt
state_before: case h.hdeg
R : Type u
S : Type v
inst✝² : CommRing R
inst✝¹ : Ring S
f : R[X]
inst✝ : Algebra R S
h : IsAdjoinRootMonic S f
i j : Fin f.natDegree
⊢ ↑i < f.natDegree
state_after: no goals
Theorem: Filter.compl_mem_comk
File: Mathlib/Order/Filter/Basic.lean

tactic: simp
state_before: α : Type u_1
β : Type u_2
F : Filter α
G : Filter β
p : Set α → Prop
he : p ∅
hmono : ∀ (t : Set α), p t → ∀ s ⊆ t, p s
hunion : ∀ (s : Set α), p s → ∀ (t : Set α), p t → p (s ∪ t)
s : Set α
⊢ sᶜ ∈ comk p he hmono hunion ↔ p s
state_after: no goals
Theorem: AList.perm_insert
File: Mathlib/Data/List/AList.lean

tactic: simp only [insert_entries]
state_before: α : Type u
β : α → Type v
inst✝ : DecidableEq α
a : α
b : β a
s₁ s₂ : AList β
p : s₁.entries ~ s₂.entries
⊢ (insert a b s₁).entries ~ (insert a b s₂).entries
state_after: α : Type u
β : α → Type v
inst✝ : DecidableEq α
a : α
b : β a
s₁ s₂ : AList β
p : s₁.entries ~ s₂.entries
⊢ ⟨a, b⟩ :: kerase a s₁.entries ~ ⟨a, b⟩ :: kerase a s₂.entries

tactic: exact p.kinsert s₁.nodupKeys
state_before: α : Type u
β : α → Type v
inst✝ : DecidableEq α
a : α
b : β a
s₁ s₂ : AList β
p : s₁.entries ~ s₂.entries
⊢ ⟨a, b⟩ :: kerase a s₁.entries ~ ⟨a, b⟩ :: kerase a s₂.entries
state_after: no goals
Theorem: MeasureTheory.Measure.toSignedMeasure_toMeasureOfZeroLE
File: Mathlib/MeasureTheory/Measure/VectorMeasure.lean

tactic: refine Measure.ext fun i hi => ?_
state_before: α : Type u_1
β : Type u_2
m : MeasurableSpace α
μ : Measure α
inst✝ : IsFiniteMeasure μ
⊢ μ.toSignedMeasure.toMeasureOfZeroLE univ ⋯ ⋯ = μ
state_after: α : Type u_1
β : Type u_2
m : MeasurableSpace α
μ : Measure α
inst✝ : IsFiniteMeasure μ
i : Set α
hi : MeasurableSet i
⊢ (μ.toSignedMeasure.toMeasureOfZeroLE univ ⋯ ⋯) i = μ i

tactic: lift μ i to ℝ≥0 using (measure_lt_top _ _).ne with m hm
state_before: α : Type u_1
β : Type u_2
m : MeasurableSpace α
μ : Measure α
inst✝ : IsFiniteMeasure μ
i : Set α
hi : MeasurableSet i
⊢ (μ.toSignedMeasure.toMeasureOfZeroLE univ ⋯ ⋯) i = μ i
state_after: case intro
α : Type u_1
β : Type u_2
m✝ : MeasurableSpace α
μ : Measure α
inst✝ : IsFiniteMeasure μ
i : Set α
hi : MeasurableSet i
m : ℝ≥0
hm : ↑m = μ i
⊢ (μ.toSignedMeasure.toMeasureOfZeroLE univ ⋯ ⋯) i = ↑m

tactic: rw [SignedMeasure.toMeasureOfZeroLE_apply _ _ _ hi, ENNReal.coe_inj]
state_before: case intro
α : Type u_1
β : Type u_2
m✝ : MeasurableSpace α
μ : Measure α
inst✝ : IsFiniteMeasure μ
i : Set α
hi : MeasurableSet i
m : ℝ≥0
hm : ↑m = μ i
⊢ (μ.toSignedMeasure.toMeasureOfZeroLE univ ⋯ ⋯) i = ↑m
state_after: case intro
α : Type u_1
β : Type u_2
m✝ : MeasurableSpace α
μ : Measure α
inst✝ : IsFiniteMeasure μ
i : Set α
hi : MeasurableSet i
m : ℝ≥0
hm : ↑m = μ i
⊢ ⟨↑μ.toSignedMeasure (univ ∩ i), ⋯⟩ = m

tactic: congr
state_before: case intro
α : Type u_1
β : Type u_2
m✝ : MeasurableSpace α
μ : Measure α
inst✝ : IsFiniteMeasure μ
i : Set α
hi : MeasurableSet i
m : ℝ≥0
hm : ↑m = μ i
⊢ ⟨↑μ.toSignedMeasure (univ ∩ i), ⋯⟩ = m
state_after: case intro.e_val
α : Type u_1
β : Type u_2
m✝ : MeasurableSpace α
μ : Measure α
inst✝ : IsFiniteMeasure μ
i : Set α
hi : MeasurableSet i
m : ℝ≥0
hm : ↑m = μ i
⊢ ↑μ.toSignedMeasure (univ ∩ i) = ↑m

tactic: simp [hi, ← hm]
state_before: case intro.e_val
α : Type u_1
β : Type u_2
m✝ : MeasurableSpace α
μ : Measure α
inst✝ : IsFiniteMeasure μ
i : Set α
hi : MeasurableSet i
m : ℝ≥0
hm : ↑m = μ i
⊢ ↑μ.toSignedMeasure (univ ∩ i) = ↑m
state_after: no goals
Theorem: GeneralizedContinuedFraction.exists_rat_eq_of_terminates
File: Mathlib/Algebra/ContinuedFractions/Computation/TerminatesIffRat.lean

tactic: obtain ⟨n, v_eq_conv⟩ : ∃ n, v = (of v).convergents n :=
  of_correctness_of_terminates terminates
state_before: K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
n : ℕ
terminates : (of v).Terminates
⊢ ∃ q, v = ↑q
state_after: case intro
K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
n✝ : ℕ
terminates : (of v).Terminates
n : ℕ
v_eq_conv : v = (of v).convergents n
⊢ ∃ q, v = ↑q

tactic: obtain ⟨q, conv_eq_q⟩ : ∃ q : ℚ, (of v).convergents n = (↑q : K) :=
  exists_rat_eq_nth_convergent v n
state_before: case intro
K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
n✝ : ℕ
terminates : (of v).Terminates
n : ℕ
v_eq_conv : v = (of v).convergents n
⊢ ∃ q, v = ↑q
state_after: case intro.intro
K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
n✝ : ℕ
terminates : (of v).Terminates
n : ℕ
v_eq_conv : v = (of v).convergents n
q : ℚ
conv_eq_q : (of v).convergents n = ↑q
⊢ ∃ q, v = ↑q

tactic: have : v = (↑q : K) := Eq.trans v_eq_conv conv_eq_q
state_before: case intro.intro
K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
n✝ : ℕ
terminates : (of v).Terminates
n : ℕ
v_eq_conv : v = (of v).convergents n
q : ℚ
conv_eq_q : (of v).convergents n = ↑q
⊢ ∃ q, v = ↑q
state_after: case intro.intro
K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
n✝ : ℕ
terminates : (of v).Terminates
n : ℕ
v_eq_conv : v = (of v).convergents n
q : ℚ
conv_eq_q : (of v).convergents n = ↑q
this : v = ↑q
⊢ ∃ q, v = ↑q

tactic: use q, this
state_before: case intro.intro
K : Type u_1
inst✝¹ : LinearOrderedField K
inst✝ : FloorRing K
v : K
n✝ : ℕ
terminates : (of v).Terminates
n : ℕ
v_eq_conv : v = (of v).convergents n
q : ℚ
conv_eq_q : (of v).convergents n = ↑q
this : v = ↑q
⊢ ∃ q, v = ↑q
state_after: no goals
Theorem: ZMod.χ₈_nat_mod_eight
File: Mathlib/NumberTheory/LegendreSymbol/ZModChar.lean

tactic: rw [← ZMod.natCast_mod n 8]
state_before: n : ℕ
⊢ χ₈ ↑n = χ₈ ↑(n % 8)
state_after: no goals
Theorem: Finset.card_le_card_diffs
File: Mathlib/Combinatorics/SetFamily/FourFunctions.lean

tactic: simpa [← sq] using s.le_card_diffs_mul_card_diffs s
state_before: α : Type u_1
β : Type u_2
inst✝¹ : DecidableEq α
inst✝ : GeneralizedBooleanAlgebra α
s : Finset α
⊢ s.card ^ 2 ≤ (s \\ s).card ^ 2
state_after: no goals
Theorem: conformalAt_iff'
File: Mathlib/Analysis/Calculus/Conformal/InnerProduct.lean

tactic: rw [conformalAt_iff_isConformalMap_fderiv, isConformalMap_iff]
state_before: E : Type u_1
F : Type u_2
inst✝³ : NormedAddCommGroup E
inst✝² : NormedAddCommGroup F
inst✝¹ : InnerProductSpace ℝ E
inst✝ : InnerProductSpace ℝ F
f : E → F
x : E
⊢ ConformalAt f x ↔ ∃ c, 0 < c ∧ ∀ (u v : E), ⟪(fderiv ℝ f x) u, (fderiv ℝ f x) v⟫_ℝ = c * ⟪u, v⟫_ℝ
state_after: no goals
Theorem: Nat.dist_succ_succ
File: Mathlib/Data/Nat/Dist.lean

tactic: simp [dist, succ_sub_succ]
state_before: i j : ℕ
⊢ i.succ.dist j.succ = i.dist j
state_after: no goals
Theorem: derivWithin_univ
File: Mathlib/Analysis/Calculus/Deriv/Basic.lean

tactic: ext
state_before: 𝕜 : Type u
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type v
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type w
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t : Set 𝕜
L L₁ L₂ : Filter 𝕜
⊢ derivWithin f univ = deriv f
state_after: case h
𝕜 : Type u
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type v
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type w
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t : Set 𝕜
L L₁ L₂ : Filter 𝕜
x✝ : 𝕜
⊢ derivWithin f univ x✝ = deriv f x✝

tactic: unfold derivWithin deriv
state_before: case h
𝕜 : Type u
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type v
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type w
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t : Set 𝕜
L L₁ L₂ : Filter 𝕜
x✝ : 𝕜
⊢ derivWithin f univ x✝ = deriv f x✝
state_after: case h
𝕜 : Type u
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type v
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type w
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t : Set 𝕜
L L₁ L₂ : Filter 𝕜
x✝ : 𝕜
⊢ (fderivWithin 𝕜 f univ x✝) 1 = (fderiv 𝕜 f x✝) 1

tactic: rw [fderivWithin_univ]
state_before: case h
𝕜 : Type u
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type v
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type w
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t : Set 𝕜
L L₁ L₂ : Filter 𝕜
x✝ : 𝕜
⊢ (fderivWithin 𝕜 f univ x✝) 1 = (fderiv 𝕜 f x✝) 1
state_after: no goals
Theorem: SimpleGraph.edgeFinset_replaceVertex_of_not_adj
File: Mathlib/Combinatorics/SimpleGraph/Operations.lean

tactic: simp only [incidenceFinset, neighborFinset, ← Set.toFinset_diff, ← Set.toFinset_image,
  ← Set.toFinset_union]
state_before: V : Type u_1
inst✝² : DecidableEq V
G : SimpleGraph V
s t : V
inst✝¹ : Fintype V
inst✝ : DecidableRel G.Adj
hn : ¬G.Adj s t
⊢ (G.replaceVertex s t).edgeFinset = G.edgeFinset \ G.incidenceFinset t ∪ image (fun x => s(x, t)) (G.neighborFinset s)
state_after: V : Type u_1
inst✝² : DecidableEq V
G : SimpleGraph V
s t : V
inst✝¹ : Fintype V
inst✝ : DecidableRel G.Adj
hn : ¬G.Adj s t
⊢ (G.replaceVertex s t).edgeFinset = (G.edgeSet \ G.incidenceSet t ∪ (fun x => s(x, t)) '' G.neighborSet s).toFinset

tactic: exact Set.toFinset_congr (G.edgeSet_replaceVertex_of_not_adj hn)
state_before: V : Type u_1
inst✝² : DecidableEq V
G : SimpleGraph V
s t : V
inst✝¹ : Fintype V
inst✝ : DecidableRel G.Adj
hn : ¬G.Adj s t
⊢ (G.replaceVertex s t).edgeFinset = (G.edgeSet \ G.incidenceSet t ∪ (fun x => s(x, t)) '' G.neighborSet s).toFinset
state_after: no goals
Theorem: IsPrimitiveRoot.zmodEquivZPowers_symm_apply_zpow
File: Mathlib/RingTheory/RootsOfUnity/Basic.lean

tactic: rw [← h.zmodEquivZPowers.symm_apply_apply i, zmodEquivZPowers_apply_coe_int]
state_before: M : Type u_1
N : Type u_2
G : Type u_3
R : Type u_4
S : Type u_5
F : Type u_6
inst✝³ : CommMonoid M
inst✝² : CommMonoid N
inst✝¹ : DivisionCommMonoid G
k l : ℕ
inst✝ : CommRing R
ζ : Rˣ
h : IsPrimitiveRoot ζ k
i : ℤ
⊢ h.zmodEquivZPowers.symm (Additive.ofMul ⟨ζ ^ i, ⋯⟩) = ↑i
state_after: no goals
Theorem: Submodule.IsPrincipal.prime_generator_of_isPrime
File: Mathlib/RingTheory/PrincipalIdealDomain.lean

tactic: simpa only [← mem_iff_generator_dvd S] using is_prime.2
state_before: R : Type u
M : Type v
inst✝³ : AddCommGroup M
inst✝² : CommRing R
inst✝¹ : Module R M
S : Ideal R
inst✝ : IsPrincipal S
is_prime : S.IsPrime
ne_bot : S ≠ ⊥
x✝¹ x✝ : R
⊢ generator S ∣ x✝¹ * x✝ → generator S ∣ x✝¹ ∨ generator S ∣ x✝
state_after: no goals
Theorem: measurable_of_isOpen
File: Mathlib/MeasureTheory/Constructions/BorelSpace/Basic.lean

tactic: exact measurable_generateFrom hf
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
γ₂ : Type u_4
δ : Type u_5
ι : Sort y
s t u : Set α
inst✝¹² : TopologicalSpace α
inst✝¹¹ : MeasurableSpace α
inst✝¹⁰ : OpensMeasurableSpace α
inst✝⁹ : TopologicalSpace β
inst✝⁸ : MeasurableSpace β
inst✝⁷ : OpensMeasurableSpace β
inst✝⁶ : TopologicalSpace γ
inst✝⁵ : MeasurableSpace γ
inst✝⁴ : BorelSpace γ
inst✝³ : TopologicalSpace γ₂
inst✝² : MeasurableSpace γ₂
inst✝¹ : BorelSpace γ₂
inst✝ : MeasurableSpace δ
f : δ → γ
hf : ∀ (s : Set γ), IsOpen s → MeasurableSet (f ⁻¹' s)
⊢ Measurable f
state_after: no goals
Theorem: gaussSum_mulShift
File: Mathlib/NumberTheory/GaussSum.lean

tactic: simp only [gaussSum, mulShift_apply, Finset.mul_sum]
state_before: R : Type u
inst✝² : CommRing R
inst✝¹ : Fintype R
R' : Type v
inst✝ : CommRing R'
χ : MulChar R R'
ψ : AddChar R R'
a : Rˣ
⊢ χ ↑a * gaussSum χ (ψ.mulShift ↑a) = gaussSum χ ψ
state_after: R : Type u
inst✝² : CommRing R
inst✝¹ : Fintype R
R' : Type v
inst✝ : CommRing R'
χ : MulChar R R'
ψ : AddChar R R'
a : Rˣ
⊢ ∑ i : R, χ ↑a * (χ i * ψ (↑a * i)) = ∑ a : R, χ a * ψ a

tactic: simp_rw [← mul_assoc, ← map_mul]
state_before: R : Type u
inst✝² : CommRing R
inst✝¹ : Fintype R
R' : Type v
inst✝ : CommRing R'
χ : MulChar R R'
ψ : AddChar R R'
a : Rˣ
⊢ ∑ i : R, χ ↑a * (χ i * ψ (↑a * i)) = ∑ a : R, χ a * ψ a
state_after: R : Type u
inst✝² : CommRing R
inst✝¹ : Fintype R
R' : Type v
inst✝ : CommRing R'
χ : MulChar R R'
ψ : AddChar R R'
a : Rˣ
⊢ ∑ x : R, χ (↑a * x) * ψ (↑a * x) = ∑ a : R, χ a * ψ a

tactic: exact Fintype.sum_bijective _ a.mulLeft_bijective _ _ fun x ↦ rfl
state_before: R : Type u
inst✝² : CommRing R
inst✝¹ : Fintype R
R' : Type v
inst✝ : CommRing R'
χ : MulChar R R'
ψ : AddChar R R'
a : Rˣ
⊢ ∑ x : R, χ (↑a * x) * ψ (↑a * x) = ∑ a : R, χ a * ψ a
state_after: no goals
Theorem: Matrix.separatingLeft_toLinearMap₂_iff
File: Mathlib/LinearAlgebra/Matrix/SesquilinearForm.lean

tactic: rw [← Matrix.separatingLeft_toLinearMap₂'_iff_separatingLeft_toLinearMap₂,
  Matrix.separatingLeft_toLinearMap₂'_iff]
state_before: R : Type u_1
R₁ : Type u_2
R₂ : Type u_3
M✝ : Type u_4
M₁ : Type u_5
M₂ : Type u_6
M₁' : Type u_7
M₂' : Type u_8
n : Type u_9
m : Type u_10
n' : Type u_11
m' : Type u_12
ι : Type u_13
inst✝⁴ : CommRing R₁
inst✝³ : AddCommMonoid M₁
inst✝² : Module R₁ M₁
inst✝¹ : DecidableEq ι
inst✝ : Fintype ι
B : M₁ →ₗ[R₁] M₁ →ₗ[R₁] R₁
M : Matrix ι ι R₁
b : Basis ι R₁ M₁
⊢ ((toLinearMap₂ b b) M).SeparatingLeft ↔ M.Nondegenerate
state_after: no goals
Theorem: HasFDerivWithinAt.comp_hasDerivWithinAt_of_eq
File: Mathlib/Analysis/Calculus/Deriv/Comp.lean

tactic: rw [hy] at hl
state_before: 𝕜 : Type u
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type v
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type w
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t✝ : Set 𝕜
L L₁ L₂ : Filter 𝕜
l : F → E
l' : F →L[𝕜] E
y : F
t : Set F
hl : HasFDerivWithinAt l l' t y
hf : HasDerivWithinAt f f' s x
hst : MapsTo f s t
hy : y = f x
⊢ HasDerivWithinAt (l ∘ f) (l' f') 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
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t✝ : Set 𝕜
L L₁ L₂ : Filter 𝕜
l : F → E
l' : F →L[𝕜] E
y : F
t : Set F
hl : HasFDerivWithinAt l l' t (f x)
hf : HasDerivWithinAt f f' s x
hst : MapsTo f s t
hy : y = f x
⊢ HasDerivWithinAt (l ∘ f) (l' f') s x

tactic: exact hl.comp_hasDerivWithinAt x hf hst
state_before: 𝕜 : Type u
inst✝⁴ : NontriviallyNormedField 𝕜
F : Type v
inst✝³ : NormedAddCommGroup F
inst✝² : NormedSpace 𝕜 F
E : Type w
inst✝¹ : NormedAddCommGroup E
inst✝ : NormedSpace 𝕜 E
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t✝ : Set 𝕜
L L₁ L₂ : Filter 𝕜
l : F → E
l' : F →L[𝕜] E
y : F
t : Set F
hl : HasFDerivWithinAt l l' t (f x)
hf : HasDerivWithinAt f f' s x
hst : MapsTo f s t
hy : y = f x
⊢ HasDerivWithinAt (l ∘ f) (l' f') s x
state_after: no goals
Theorem: Matrix.one_zpow
File: Mathlib/LinearAlgebra/Matrix/ZPow.lean

tactic: rw [zpow_natCast, one_pow]
state_before: n' : Type u_1
inst✝² : DecidableEq n'
inst✝¹ : Fintype n'
R : Type u_2
inst✝ : CommRing R
n : ℕ
⊢ 1 ^ ↑n = 1
state_after: no goals

tactic: rw [zpow_negSucc, one_pow, inv_one]
state_before: n' : Type u_1
inst✝² : DecidableEq n'
inst✝¹ : Fintype n'
R : Type u_2
inst✝ : CommRing R
n : ℕ
⊢ 1 ^ -[n+1] = 1
state_after: no goals
Theorem: Finset.Ioo_subset_Ioi_self
File: Mathlib/Order/Interval/Finset/Basic.lean

tactic: simpa [← coe_subset] using Set.Ioo_subset_Ioi_self
state_before: ι : Type u_1
α : Type u_2
inst✝² : Preorder α
inst✝¹ : LocallyFiniteOrder α
a a₁ a₂ b b₁ b₂ c x : α
inst✝ : LocallyFiniteOrderTop α
⊢ Ioo a b ⊆ Ioi a
state_after: no goals
Theorem: EuclideanGeometry.circumsphere_eq_of_cospherical_subset
File: Mathlib/Geometry/Euclidean/Circumcenter.lean

tactic: rcases exists_circumsphere_eq_of_cospherical_subset h hd hc with ⟨r, hr⟩
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
ps : Set P
h : ps ⊆ ↑s
inst✝¹ : Nonempty ↥s
n : ℕ
inst✝ : FiniteDimensional ℝ ↥s.direction
hd : finrank ℝ ↥s.direction = n
hc : Cospherical ps
sx₁ sx₂ : Simplex ℝ P n
hsx₁ : Set.range sx₁.points ⊆ ps
hsx₂ : Set.range sx₂.points ⊆ ps
⊢ sx₁.circumsphere = sx₂.circumsphere
state_after: case intro
V : Type u_1
P : Type u_2
inst✝⁵ : NormedAddCommGroup V
inst✝⁴ : InnerProductSpace ℝ V
inst✝³ : MetricSpace P
inst✝² : NormedAddTorsor V P
s : AffineSubspace ℝ P
ps : Set P
h : ps ⊆ ↑s
inst✝¹ : Nonempty ↥s
n : ℕ
inst✝ : FiniteDimensional ℝ ↥s.direction
hd : finrank ℝ ↥s.direction = n
hc : Cospherical ps
sx₁ sx₂ : Simplex ℝ P n
hsx₁ : Set.range sx₁.points ⊆ ps
hsx₂ : Set.range sx₂.points ⊆ ps
r : Sphere P
hr : ∀ (sx : Simplex ℝ P n), Set.range sx.points ⊆ ps → sx.circumsphere = r
⊢ sx₁.circumsphere = sx₂.circumsphere

tactic: rw [hr sx₁ hsx₁, hr sx₂ hsx₂]
state_before: case intro
V : Type u_1
P : Type u_2
inst✝⁵ : NormedAddCommGroup V
inst✝⁴ : InnerProductSpace ℝ V
inst✝³ : MetricSpace P
inst✝² : NormedAddTorsor V P
s : AffineSubspace ℝ P
ps : Set P
h : ps ⊆ ↑s
inst✝¹ : Nonempty ↥s
n : ℕ
inst✝ : FiniteDimensional ℝ ↥s.direction
hd : finrank ℝ ↥s.direction = n
hc : Cospherical ps
sx₁ sx₂ : Simplex ℝ P n
hsx₁ : Set.range sx₁.points ⊆ ps
hsx₂ : Set.range sx₂.points ⊆ ps
r : Sphere P
hr : ∀ (sx : Simplex ℝ P n), Set.range sx.points ⊆ ps → sx.circumsphere = r
⊢ sx₁.circumsphere = sx₂.circumsphere
state_after: no goals
Theorem: ProbabilityTheory.condexp_prod_ae_eq_integral_condDistrib₀
File: Mathlib/Probability/Kernel/CondDistrib.lean

tactic: rwa [integrable_map_measure hf (hX.aemeasurable.prod_mk hY)]
state_before: α : Type u_1
β : Type u_2
Ω : Type u_3
F : Type u_4
inst✝⁶ : MeasurableSpace Ω
inst✝⁵ : StandardBorelSpace Ω
inst✝⁴ : Nonempty Ω
inst✝³ : NormedAddCommGroup F
mα : MeasurableSpace α
μ : Measure α
inst✝² : IsFiniteMeasure μ
X : α → β
Y : α → Ω
mβ : MeasurableSpace β
s : Set Ω
t : Set β
f : β × Ω → F
inst✝¹ : NormedSpace ℝ F
inst✝ : CompleteSpace F
hX : Measurable X
hY : AEMeasurable Y μ
hf : AEStronglyMeasurable f (Measure.map (fun a => (X a, Y a)) μ)
hf_int : Integrable (fun a => f (X a, Y a)) μ
⊢ Integrable f (Measure.map (fun a => (X a, Y a)) μ)
state_after: no goals
Theorem: Nat.count_add
File: Mathlib/Data/Nat/Count.lean

tactic: have : Disjoint ((range a).filter p) (((range b).map <| addLeftEmbedding a).filter p) := by
  apply disjoint_filter_filter
  rw [Finset.disjoint_left]
  simp_rw [mem_map, mem_range, addLeftEmbedding_apply]
  rintro x hx ⟨c, _, rfl⟩
  exact (self_le_add_right _ _).not_lt hx
state_before: p : ℕ → Prop
inst✝ : DecidablePred p
a b : ℕ
⊢ count p (a + b) = count p a + count (fun k => p (a + k)) b
state_after: p : ℕ → Prop
inst✝ : DecidablePred p
a b : ℕ
this : Disjoint (filter p (range a)) (filter p (map (addLeftEmbedding a) (range b)))
⊢ count p (a + b) = count p a + count (fun k => p (a + k)) b

tactic: simp_rw [count_eq_card_filter_range, range_add, filter_union, card_union_of_disjoint this,
  filter_map, addLeftEmbedding, card_map]
state_before: p : ℕ → Prop
inst✝ : DecidablePred p
a b : ℕ
this : Disjoint (filter p (range a)) (filter p (map (addLeftEmbedding a) (range b)))
⊢ count p (a + b) = count p a + count (fun k => p (a + k)) b
state_after: p : ℕ → Prop
inst✝ : DecidablePred p
a b : ℕ
this : Disjoint (filter p (range a)) (filter p (map (addLeftEmbedding a) (range b)))
⊢ (filter p (range a)).card + (filter (p ∘ ⇑{ toFun := fun h => a + h, inj' := ⋯ }) (range b)).card =
    (filter p (range a)).card + (filter (fun k => p (a + k)) (range b)).card

tactic: rfl
state_before: p : ℕ → Prop
inst✝ : DecidablePred p
a b : ℕ
this : Disjoint (filter p (range a)) (filter p (map (addLeftEmbedding a) (range b)))
⊢ (filter p (range a)).card + (filter (p ∘ ⇑{ toFun := fun h => a + h, inj' := ⋯ }) (range b)).card =
    (filter p (range a)).card + (filter (fun k => p (a + k)) (range b)).card
state_after: no goals

tactic: apply disjoint_filter_filter
state_before: p : ℕ → Prop
inst✝ : DecidablePred p
a b : ℕ
⊢ Disjoint (filter p (range a)) (filter p (map (addLeftEmbedding a) (range b)))
state_after: case a
p : ℕ → Prop
inst✝ : DecidablePred p
a b : ℕ
⊢ Disjoint (range a) (map (addLeftEmbedding a) (range b))

tactic: rw [Finset.disjoint_left]
state_before: case a
p : ℕ → Prop
inst✝ : DecidablePred p
a b : ℕ
⊢ Disjoint (range a) (map (addLeftEmbedding a) (range b))
state_after: case a
p : ℕ → Prop
inst✝ : DecidablePred p
a b : ℕ
⊢ ∀ ⦃a_1 : ℕ⦄, a_1 ∈ range a → a_1 ∉ map (addLeftEmbedding a) (range b)

tactic: simp_rw [mem_map, mem_range, addLeftEmbedding_apply]
state_before: case a
p : ℕ → Prop
inst✝ : DecidablePred p
a b : ℕ
⊢ ∀ ⦃a_1 : ℕ⦄, a_1 ∈ range a → a_1 ∉ map (addLeftEmbedding a) (range b)
state_after: case a
p : ℕ → Prop
inst✝ : DecidablePred p
a b : ℕ
⊢ ∀ ⦃a_1 : ℕ⦄, a_1 < a → ¬∃ a_3 < b, a + a_3 = a_1

tactic: rintro x hx ⟨c, _, rfl⟩
state_before: case a
p : ℕ → Prop
inst✝ : DecidablePred p
a b : ℕ
⊢ ∀ ⦃a_1 : ℕ⦄, a_1 < a → ¬∃ a_3 < b, a + a_3 = a_1
state_after: case a.intro.intro
p : ℕ → Prop
inst✝ : DecidablePred p
a b c : ℕ
left✝ : c < b
hx : a + c < a
⊢ False

tactic: exact (self_le_add_right _ _).not_lt hx
state_before: case a.intro.intro
p : ℕ → Prop
inst✝ : DecidablePred p
a b c : ℕ
left✝ : c < b
hx : a + c < a
⊢ False
state_after: no goals
Theorem: StrictConcaveOn.translate_left
File: Mathlib/Analysis/Convex/Function.lean

tactic: simpa only [add_comm] using hf.translate_right c
state_before: 𝕜 : Type u_1
E : Type u_2
F : Type u_3
α : Type u_4
β : Type u_5
ι : Type u_6
inst✝⁴ : OrderedSemiring 𝕜
inst✝³ : AddCancelCommMonoid E
inst✝² : OrderedAddCommMonoid β
inst✝¹ : Module 𝕜 E
inst✝ : SMul 𝕜 β
s : Set E
f : E → β
hf : StrictConcaveOn 𝕜 s f
c : E
⊢ StrictConcaveOn 𝕜 ((fun z => c + z) ⁻¹' s) (f ∘ fun z => z + c)
state_after: no goals