tasksource/leandojo huggingface dataset:
Theorem: Std.PairingHeapImp.Heap.noSibling_tail?
File: Std/Data/PairingHeap.lean

tactic: simp only [Heap.tail?]
state_before: α : Type u_1
le : α → α → Bool
s' s : Heap α
⊢ tail? le s = some s' → NoSibling s'

tactic: intro eq
state_before: α : Type u_1
le : α → α → Bool
s' s : Heap α
⊢ Option.map (fun x => x.snd) (deleteMin le s) = some s' → NoSibling s'

tactic: match eq₂ : s.deleteMin le, eq with
| some (a, tl), rfl => exact noSibling_deleteMin eq₂
state_before: α : Type u_1
le : α → α → Bool
s' s : Heap α
eq : Option.map (fun x => x.snd) (deleteMin le s) = some s'
⊢ NoSibling s'

tactic: exact noSibling_deleteMin eq₂
state_before: α : Type u_1
le : α → α → Bool
s' s : Heap α
eq : Option.map (fun x => x.snd) (deleteMin le s) = some s'
a : α
tl : Heap α
eq₂ : deleteMin le s = some (a, tl)
⊢ NoSibling ((fun x => x.snd) (a, tl))
Theorem: biInter_basis_nhds
File: Mathlib/Topology/Separation.lean

tactic: simp only [eq_singleton_iff_unique_mem, mem_iInter]
state_before: α : Type u
β : Type v
inst✝¹ : TopologicalSpace α
inst✝ : T1Space α
ι : Sort u_1
p : ι → Prop
s : ι → Set α
x : α
h : HasBasis (𝓝 x) p s
⊢ (⋂ (i : ι) (_ : p i), s i) = {x}

tactic: refine' ⟨fun i hi => mem_of_mem_nhds <| h.mem_of_mem hi, fun y hy => _⟩
state_before: α : Type u
β : Type v
inst✝¹ : TopologicalSpace α
inst✝ : T1Space α
ι : Sort u_1
p : ι → Prop
s : ι → Set α
x : α
h : HasBasis (𝓝 x) p s
⊢ (∀ (i : ι), p i → x ∈ s i) ∧ ∀ (x_1 : α), (∀ (i : ι), p i → x_1 ∈ s i) → x_1 = x

tactic: contrapose! hy
state_before: α : Type u
β : Type v
inst✝¹ : TopologicalSpace α
inst✝ : T1Space α
ι : Sort u_1
p : ι → Prop
s : ι → Set α
x : α
h : HasBasis (𝓝 x) p s
y : α
hy : ∀ (i : ι), p i → y ∈ s i
⊢ y = x

tactic: rcases h.mem_iff.1 (compl_singleton_mem_nhds hy.symm) with ⟨i, hi, hsub⟩
state_before: α : Type u
β : Type v
inst✝¹ : TopologicalSpace α
inst✝ : T1Space α
ι : Sort u_1
p : ι → Prop
s : ι → Set α
x : α
h : HasBasis (𝓝 x) p s
y : α
hy : y ≠ x
⊢ ∃ i, p i ∧ ¬y ∈ s i

tactic: exact ⟨i, hi, fun h => hsub h rfl⟩
state_before: case intro.intro
α : Type u
β : Type v
inst✝¹ : TopologicalSpace α
inst✝ : T1Space α
ι : Sort u_1
p : ι → Prop
s : ι → Set α
x : α
h : HasBasis (𝓝 x) p s
y : α
hy : y ≠ x
i : ι
hi : p i
hsub : s i ⊆ {y}ᶜ
⊢ ∃ i, p i ∧ ¬y ∈ s i
Theorem: Set.image_neg_uIcc
File: Mathlib/Data/Set/Pointwise/Interval.lean

tactic: simp
state_before: α : Type u_1
inst✝ : LinearOrderedAddCommGroup α
a b c d : α
⊢ Neg.neg '' [[a, b]] = [[-a, -b]]
Theorem: dvd_sub_comm
File: Mathlib/Algebra/Ring/Divisibility.lean

tactic: rw [← dvd_neg (α := α), neg_sub]
state_before: α : Type u_1
β : Type ?u.11880
inst✝ : NonUnitalRing α
a b c : α
⊢ a ∣ b - c ↔ a ∣ c - b
Theorem: Fin.natAdd_zero
File: Mathlib/Data/Fin/Basic.lean

tactic: ext
state_before: n✝ m n : ℕ
⊢ natAdd 0 = RelIso.toRelEmbedding (cast (_ : n = 0 + n))

tactic: simp
state_before: case h.h
n✝ m n : ℕ
x✝ : Fin n
⊢ ↑(↑(natAdd 0) x✝) = ↑(↑(RelIso.toRelEmbedding (cast (_ : n = 0 + n))) x✝)
Theorem: List.filter_filter
File: Std/Data/List/Lemmas.lean

tactic: by_cases hp : p a <;> by_cases hq : q a <;> simp [hp, hq, filter_filter _ l]
state_before: α✝ : Type u_1
p q : α✝ → Bool
a : α✝
l : List α✝
⊢ filter p (filter q (a :: l)) = filter (fun a => decide (p a = true ∧ q a = true)) (a :: l)
Theorem: CompactSpace.elim_nhds_subcover
File: Mathlib/Topology/SubsetProperties.lean

tactic: obtain ⟨t, -, s⟩ := IsCompact.elim_nhds_subcover isCompact_univ U fun x _ => hU x
state_before: α : Type u
β : Type v
ι : Type ?u.75608
π : ι → Type ?u.75613
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
s t : Set α
inst✝ : CompactSpace α
U : α → Set α
hU : ∀ (x : α), U x ∈ 𝓝 x
⊢ ∃ t, (⋃ (x : α) (_ : x ∈ t), U x) = ⊤

tactic: exact ⟨t, top_unique s⟩
state_before: case intro.intro
α : Type u
β : Type v
ι : Type ?u.75608
π : ι → Type ?u.75613
inst✝² : TopologicalSpace α
inst✝¹ : TopologicalSpace β
s✝ t✝ : Set α
inst✝ : CompactSpace α
U : α → Set α
hU : ∀ (x : α), U x ∈ 𝓝 x
t : Finset α
s : univ ⊆ ⋃ (x : α) (_ : x ∈ t), U x
⊢ ∃ t, (⋃ (x : α) (_ : x ∈ t), U x) = ⊤
Theorem: MeasureTheory.quasiMeasurePreserving_div_of_right_invariant
File: Mathlib/MeasureTheory/Group/Prod.lean

tactic: refine' QuasiMeasurePreserving.prod_of_left measurable_div (eventually_of_forall fun y => _)
state_before: G : Type u_1
inst✝⁶ : MeasurableSpace G
inst✝⁵ : Group G
inst✝⁴ : MeasurableMul₂ G
μ ν : Measure G
inst✝³ : SigmaFinite ν
inst✝² : SigmaFinite μ
s : Set G
inst✝¹ : MeasurableInv G
inst✝ : IsMulRightInvariant μ
⊢ QuasiMeasurePreserving fun p => p.fst / p.snd

tactic: exact (measurePreserving_div_right μ y).quasiMeasurePreserving
state_before: G : Type u_1
inst✝⁶ : MeasurableSpace G
inst✝⁵ : Group G
inst✝⁴ : MeasurableMul₂ G
μ ν : Measure G
inst✝³ : SigmaFinite ν
inst✝² : SigmaFinite μ
s : Set G
inst✝¹ : MeasurableInv G
inst✝ : IsMulRightInvariant μ
y : G
⊢ QuasiMeasurePreserving fun x => (x, y).fst / (x, y).snd
Theorem: Metric.emetric_closedBall_nnreal
File: Mathlib/Topology/MetricSpace/Basic.lean

tactic: rw [← Metric.emetric_closedBall ε.coe_nonneg, ENNReal.ofReal_coe_nnreal]
state_before: α : Type u
β : Type v
X : Type ?u.165907
ι : Type ?u.165910
inst✝ : PseudoMetricSpace α
x : α
ε : ℝ≥0
⊢ EMetric.closedBall x ↑ε = closedBall x ↑ε
Theorem: imageToKernel_comp_left
File: Mathlib/Algebra/Homology/ImageToKernel.lean

tactic: simp [w]
state_before: ι : Type ?u.13034
V : Type u
inst✝³ : Category V
inst✝² : HasZeroMorphisms V
A B C : V
f : A ⟶ B
g : B ⟶ C
inst✝¹ : HasKernels V
inst✝ : HasImages V
Z : V
h : Z ⟶ A
w : f ≫ g = 0
⊢ (h ≫ f) ≫ g = 0

tactic: ext
state_before: ι : Type ?u.13034
V : Type u
inst✝³ : Category V
inst✝² : HasZeroMorphisms V
A B C : V
f : A ⟶ B
g : B ⟶ C
inst✝¹ : HasKernels V
inst✝ : HasImages V
Z : V
h : Z ⟶ A
w : f ≫ g = 0
⊢ imageToKernel (h ≫ f) g (_ : (h ≫ f) ≫ g = 0) =
    Subobject.ofLE (imageSubobject (h ≫ f)) (imageSubobject f) (_ : imageSubobject (h ≫ f) ≤ imageSubobject f) ≫
      imageToKernel f g w

tactic: simp
state_before: case h
ι : Type ?u.13034
V : Type u
inst✝³ : Category V
inst✝² : HasZeroMorphisms V
A B C : V
f : A ⟶ B
g : B ⟶ C
inst✝¹ : HasKernels V
inst✝ : HasImages V
Z : V
h : Z ⟶ A
w : f ≫ g = 0
⊢ imageToKernel (h ≫ f) g (_ : (h ≫ f) ≫ g = 0) ≫ Subobject.arrow (kernelSubobject g) =
    (Subobject.ofLE (imageSubobject (h ≫ f)) (imageSubobject f) (_ : imageSubobject (h ≫ f) ≤ imageSubobject f) ≫
        imageToKernel f g w) ≫
      Subobject.arrow (kernelSubobject g)
Theorem: Nat.gcd_mul_left_add_left
File: Mathlib/Data/Nat/GCD/Basic.lean

tactic: rw [gcd_comm, gcd_mul_left_add_right, gcd_comm]
state_before: m n k : ℕ
⊢ gcd (n * k + m) n = gcd m n
Theorem: inv_mul_cancel_right₀
File: Mathlib/Algebra/GroupWithZero/Basic.lean

tactic: simp [h]
state_before: α : Type ?u.19210
M₀ : Type ?u.19213
G₀ : Type u_1
M₀' : Type ?u.19219
G₀' : Type ?u.19222
F : Type ?u.19225
F' : Type ?u.19228
inst✝ : GroupWithZero G₀
a✝ b c g h✝ x : G₀
h : b ≠ 0
a : G₀
⊢ a * (b⁻¹ * b) = a
Theorem: AddSubmonoid.iSup_eq_mrange_dfinsupp_sumAddHom
File: Mathlib/Data/Dfinsupp/Basic.lean

tactic: apply le_antisymm
state_before: ι : Type u
γ : Type w
β : ι → Type v
β₁ : ι → Type v₁
β₂ : ι → Type v₂
dec : DecidableEq ι
inst✝ : AddCommMonoid γ
S : ι → AddSubmonoid γ
⊢ iSup S = AddMonoidHom.mrange (sumAddHom fun i => AddSubmonoid.subtype (S i))

tactic: apply iSup_le _
state_before: case a
ι : Type u
γ : Type w
β : ι → Type v
β₁ : ι → Type v₁
β₂ : ι → Type v₂
dec : DecidableEq ι
inst✝ : AddCommMonoid γ
S : ι → AddSubmonoid γ
⊢ iSup S ≤ AddMonoidHom.mrange (sumAddHom fun i => AddSubmonoid.subtype (S i))

tactic: intro i y hy
state_before: ι : Type u
γ : Type w
β : ι → Type v
β₁ : ι → Type v₁
β₂ : ι → Type v₂
dec : DecidableEq ι
inst✝ : AddCommMonoid γ
S : ι → AddSubmonoid γ
⊢ ∀ (i : ι), S i ≤ AddMonoidHom.mrange (sumAddHom fun i => AddSubmonoid.subtype (S i))

tactic: exact ⟨Dfinsupp.single i ⟨y, hy⟩, Dfinsupp.sumAddHom_single _ _ _⟩
state_before: ι : Type u
γ : Type w
β : ι → Type v
β₁ : ι → Type v₁
β₂ : ι → Type v₂
dec : DecidableEq ι
inst✝ : AddCommMonoid γ
S : ι → AddSubmonoid γ
i : ι
y : γ
hy : y ∈ S i
⊢ y ∈ AddMonoidHom.mrange (sumAddHom fun i => AddSubmonoid.subtype (S i))

tactic: rintro x ⟨v, rfl⟩
state_before: case a
ι : Type u
γ : Type w
β : ι → Type v
β₁ : ι → Type v₁
β₂ : ι → Type v₂
dec : DecidableEq ι
inst✝ : AddCommMonoid γ
S : ι → AddSubmonoid γ
⊢ AddMonoidHom.mrange (sumAddHom fun i => AddSubmonoid.subtype (S i)) ≤ iSup S

tactic: exact dfinsupp_sumAddHom_mem _ v _ fun i _ => (le_iSup S i : S i ≤ _) (v i).prop
state_before: case a.intro
ι : Type u
γ : Type w
β : ι → Type v
β₁ : ι → Type v₁
β₂ : ι → Type v₂
dec : DecidableEq ι
inst✝ : AddCommMonoid γ
S : ι → AddSubmonoid γ
v : Π₀ (i : ι), { x // x ∈ S i }
⊢ ↑(sumAddHom fun i => AddSubmonoid.subtype (S i)) v ∈ iSup S
Theorem: SimpleGraph.boxProd_adj_left
File: Mathlib/Combinatorics/SimpleGraph/Prod.lean

tactic: simp only [boxProd_adj, and_true, SimpleGraph.irrefl, false_and, or_false]
state_before: α : Type u_1
β : Type u_2
γ : Type ?u.9064
G : SimpleGraph α
H : SimpleGraph β
a₁ : α
b : β
a₂ : α
⊢ Adj (G □ H) (a₁, b) (a₂, b) ↔ Adj G a₁ a₂
Theorem: PythagoreanTriple.isClassified_of_isPrimitiveClassified
File: Mathlib/NumberTheory/PythagoreanTriples.lean

tactic: obtain ⟨m, n, H⟩ := hp
state_before: x y z : ℤ
h : PythagoreanTriple x y z
hp : IsPrimitiveClassified h
⊢ IsClassified h

tactic: use 1, m, n
state_before: case intro.intro
x y z : ℤ
h : PythagoreanTriple x y z
m n : ℤ
H :
  (x = m ^ 2 - n ^ 2 ∧ y = 2 * m * n ∨ x = 2 * m * n ∧ y = m ^ 2 - n ^ 2) ∧
    Int.gcd m n = 1 ∧ (m % 2 = 0 ∧ n % 2 = 1 ∨ m % 2 = 1 ∧ n % 2 = 0)
⊢ IsClassified h

tactic: rcases H with ⟨t, co, _⟩
state_before: case intro.intro
x y z : ℤ
h : PythagoreanTriple x y z
m n : ℤ
H :
  (x = m ^ 2 - n ^ 2 ∧ y = 2 * m * n ∨ x = 2 * m * n ∧ y = m ^ 2 - n ^ 2) ∧
    Int.gcd m n = 1 ∧ (m % 2 = 0 ∧ n % 2 = 1 ∨ m % 2 = 1 ∧ n % 2 = 0)
⊢ (x = 1 * (m ^ 2 - n ^ 2) ∧ y = 1 * (2 * m * n) ∨ x = 1 * (2 * m * n) ∧ y = 1 * (m ^ 2 - n ^ 2)) ∧ Int.gcd m n = 1

tactic: rw [one_mul, one_mul]
state_before: case intro.intro.intro.intro
x y z : ℤ
h : PythagoreanTriple x y z
m n : ℤ
t : x = m ^ 2 - n ^ 2 ∧ y = 2 * m * n ∨ x = 2 * m * n ∧ y = m ^ 2 - n ^ 2
co : Int.gcd m n = 1
right✝ : m % 2 = 0 ∧ n % 2 = 1 ∨ m % 2 = 1 ∧ n % 2 = 0
⊢ (x = 1 * (m ^ 2 - n ^ 2) ∧ y = 1 * (2 * m * n) ∨ x = 1 * (2 * m * n) ∧ y = 1 * (m ^ 2 - n ^ 2)) ∧ Int.gcd m n = 1

tactic: exact ⟨t, co⟩
state_before: case intro.intro.intro.intro
x y z : ℤ
h : PythagoreanTriple x y z
m n : ℤ
t : x = m ^ 2 - n ^ 2 ∧ y = 2 * m * n ∨ x = 2 * m * n ∧ y = m ^ 2 - n ^ 2
co : Int.gcd m n = 1
right✝ : m % 2 = 0 ∧ n % 2 = 1 ∨ m % 2 = 1 ∧ n % 2 = 0
⊢ (x = m ^ 2 - n ^ 2 ∧ y = 2 * m * n ∨ x = 2 * m * n ∧ y = m ^ 2 - n ^ 2) ∧ Int.gcd m n = 1
Theorem: Matrix.rank_eq_finrank_span_row
File: Mathlib/Data/Matrix/Rank.lean

tactic: cases nonempty_fintype m
state_before: l : Type ?u.285266
m : Type u_2
n : Type u_3
o : Type ?u.285275
R : Type u_1
m_fin : Fintype m
inst✝³ : Fintype n
inst✝² : Fintype o
inst✝¹ : LinearOrderedField R
inst✝ : Finite m
A : Matrix m n R
⊢ rank A = finrank R { x // x ∈ Submodule.span R (Set.range A) }

tactic: rw [← rank_transpose, rank_eq_finrank_span_cols, transpose_transpose]
state_before: case intro
l : Type ?u.285266
m : Type u_2
n : Type u_3
o : Type ?u.285275
R : Type u_1
m_fin : Fintype m
inst✝³ : Fintype n
inst✝² : Fintype o
inst✝¹ : LinearOrderedField R
inst✝ : Finite m
A : Matrix m n R
val✝ : Fintype m
⊢ rank A = finrank R { x // x ∈ Submodule.span R (Set.range A) }
Theorem: Basis.orientation_eq_iff_det_pos
File: Mathlib/LinearAlgebra/Orientation.lean

tactic: rw [← e₁.det.eq_smul_basis_det e₂]
state_before: R : Type u_2
inst✝⁴ : LinearOrderedCommRing R
M : Type u_3
inst✝³ : AddCommGroup M
inst✝² : Module R M
ι : Type u_1
inst✝¹ : Fintype ι
inst✝ : DecidableEq ι
e₁ e₂ : Basis ι R M
⊢ SameRay R (det e₁) (det e₂) ↔ SameRay R (↑(det e₁) ↑e₂ • det e₂) (det e₂)
Theorem: Polynomial.degree_quadratic
File: Mathlib/Data/Polynomial/Degree/Definitions.lean

tactic: rw [add_assoc, degree_add_eq_left_of_degree_lt <| degree_linear_lt_degree_C_mul_X_sq ha,
  degree_C_mul_X_pow 2 ha]
state_before: R : Type u
S : Type v
a b c d : R
n m : ℕ
inst✝ : Semiring R
p q : R[X]
ι : Type ?u.1058825
ha : a ≠ 0
⊢ degree (↑C a * X ^ 2 + ↑C b * X + ↑C c) = 2

tactic: rfl
state_before: R : Type u
S : Type v
a b c d : R
n m : ℕ
inst✝ : Semiring R
p q : R[X]
ι : Type ?u.1058825
ha : a ≠ 0
⊢ ↑2 = 2
Theorem: εNFA.mem_stepSet_iff
File: Mathlib/Computability/EpsilonNFA.lean

tactic: simp_rw [stepSet, mem_iUnion₂, exists_prop]
state_before: α : Type u
σ σ' : Type v
M : εNFA α σ
S : Set σ
x : List α
s : σ
a : α
⊢ s ∈ stepSet M S a ↔ ∃ t, t ∈ S ∧ s ∈ εClosure M (step M t (some a))
Theorem: List.Perm.filter
File: Mathlib/Data/List/Perm.lean

tactic: rw [← filterMap_eq_filter]
state_before: α : Type uu
β : Type vv
l₁✝ l₂✝ : List α
p : α → Bool
l₁ l₂ : List α
s : l₁ ~ l₂
⊢ List.filter p l₁ ~ List.filter p l₂

tactic: apply s.filterMap _
state_before: α : Type uu
β : Type vv
l₁✝ l₂✝ : List α
p : α → Bool
l₁ l₂ : List α
s : l₁ ~ l₂
⊢ List.filterMap (Option.guard fun x => p x = true) l₁ ~ List.filterMap (Option.guard fun x => p x = true) l₂
Theorem: PiNat.dist_comm
File: Mathlib/Topology/MetricSpace/PiNat.lean

tactic: simp [dist, @eq_comm _ x y, firstDiff_comm]
state_before: E : ℕ → Type u_1
x y : (n : ℕ) → E n
⊢ dist x y = dist y x
Theorem: tendsto_atTop_isLUB
File: Mathlib/Topology/Algebra/Order/MonotoneConvergence.lean

tactic: suffices : Tendsto (rangeFactorization f) atTop atTop
state_before: α : Type u_2
β : Type ?u.5253
ι : Type u_1
inst✝³ : Preorder ι
inst✝² : TopologicalSpace α
inst✝¹ : Preorder α
inst✝ : SupConvergenceClass α
f : ι → α
a : α
h_mono : Monotone f
ha : IsLUB (range f) a
⊢ Tendsto f atTop (𝓝 a)

tactic: exact (SupConvergenceClass.tendsto_coe_atTop_isLUB _ _ ha).comp this
state_before: α : Type u_2
β : Type ?u.5253
ι : Type u_1
inst✝³ : Preorder ι
inst✝² : TopologicalSpace α
inst✝¹ : Preorder α
inst✝ : SupConvergenceClass α
f : ι → α
a : α
h_mono : Monotone f
ha : IsLUB (range f) a
this : Tendsto (rangeFactorization f) atTop atTop
⊢ Tendsto f atTop (𝓝 a)

case this
α : Type u_2
β : Type ?u.5253
ι : Type u_1
inst✝³ : Preorder ι
inst✝² : TopologicalSpace α
inst✝¹ : Preorder α
inst✝ : SupConvergenceClass α
f : ι → α
a : α
h_mono : Monotone f
ha : IsLUB (range f) a
⊢ Tendsto (rangeFactorization f) atTop atTop

tactic: exact h_mono.rangeFactorization.tendsto_atTop_atTop fun b => b.2.imp fun a ha => ha.ge
state_before: case this
α : Type u_2
β : Type ?u.5253
ι : Type u_1
inst✝³ : Preorder ι
inst✝² : TopologicalSpace α
inst✝¹ : Preorder α
inst✝ : SupConvergenceClass α
f : ι → α
a : α
h_mono : Monotone f
ha : IsLUB (range f) a
⊢ Tendsto (rangeFactorization f) atTop atTop
Theorem: hammingDist_comm
File: Mathlib/InformationTheory/Hamming.lean

tactic: simp_rw [hammingDist, ne_comm]
state_before: α : Type ?u.2207
ι : Type u_1
β : ι → Type u_2
inst✝² : Fintype ι
inst✝¹ : (i : ι) → DecidableEq (β i)
γ : ι → Type ?u.2239
inst✝ : (i : ι) → DecidableEq (γ i)
x y : (i : ι) → β i
⊢ hammingDist x y = hammingDist y x
Theorem: RingHom.map_dotProduct
File: Mathlib/Data/Matrix/Basic.lean

tactic: simp only [Matrix.dotProduct, f.map_sum, f.map_mul, Function.comp]
state_before: l : Type ?u.1289823
m : Type ?u.1289826
n : Type u_3
o : Type ?u.1289832
m' : o → Type ?u.1289837
n' : o → Type ?u.1289842
R : Type u_1
S : Type u_2
α : Type v
β : Type w
γ : Type ?u.1289855
inst✝⁴ : Fintype n
inst✝³ : NonAssocSemiring α
inst✝² : NonAssocSemiring β
inst✝¹ : NonAssocSemiring R
inst✝ : NonAssocSemiring S
f : R →+* S
v w : n → R
⊢ ↑f (v ⬝ᵥ w) = ↑f ∘ v ⬝ᵥ ↑f ∘ w
Theorem: List.append_eq_appendTR
File: src/lean/Init/Data/List/Basic.lean

tactic: apply funext
state_before: α : Type u
β : Type v
γ : Type w
⊢ @List.append = @appendTR

tactic: intro α
state_before: case h
α : Type u
β : Type v
γ : Type w
⊢ ∀ (x : Type u_1), List.append = appendTR

tactic: apply funext
state_before: case h
α✝ : Type u
β : Type v
γ : Type w
α : Type u_1
⊢ List.append = appendTR

tactic: intro as
state_before: case h.h
α✝ : Type u
β : Type v
γ : Type w
α : Type u_1
⊢ ∀ (x : List α), List.append x = appendTR x

tactic: apply funext
state_before: case h.h
α✝ : Type u
β : Type v
γ : Type w
α : Type u_1
as : List α
⊢ List.append as = appendTR as

tactic: intro bs
state_before: case h.h.h
α✝ : Type u
β : Type v
γ : Type w
α : Type u_1
as : List α
⊢ ∀ (x : List α), List.append as x = appendTR as x

tactic: simp [appendTR, reverse]
state_before: case h.h.h
α✝ : Type u
β : Type v
γ : Type w
α : Type u_1
as bs : List α
⊢ List.append as bs = appendTR as bs

tactic: induction as with
| nil  => rfl
| cons a as ih =>
  simp [reverseAux, List.append, ih, reverseAux_reverseAux]
state_before: case h.h.h
α✝ : Type u
β : Type v
γ : Type w
α : Type u_1
as bs : List α
⊢ List.append as bs = reverseAux (reverseAux as nil) bs

tactic: rfl
state_before: case h.h.h.nil
α✝ : Type u
β : Type v
γ : Type w
α : Type u_1
bs : List α
⊢ List.append nil bs = reverseAux (reverseAux nil nil) bs

tactic: simp [reverseAux, List.append, ih, reverseAux_reverseAux]
state_before: case h.h.h.cons
α✝ : Type u
β : Type v
γ : Type w
α : Type u_1
bs : List α
a : α
as : List α
ih : List.append as bs = reverseAux (reverseAux as nil) bs
⊢ List.append (a :: as) bs = reverseAux (reverseAux (a :: as) nil) bs
Theorem: Ordnode.dual_balanceR
File: Mathlib/Data/Ordmap/Ordset.lean

tactic: rw [← dual_dual (balanceL _ _ _), dual_balanceL, dual_dual, dual_dual]
state_before: α : Type u_1
l : Ordnode α
x : α
r : Ordnode α
⊢ dual (balanceR l x r) = balanceL (dual r) x (dual l)
Theorem: Monotone.map_ciSup_of_continuousAt
File: Mathlib/Topology/Order/Basic.lean

tactic: rw [iSup, Mf.map_csSup_of_continuousAt Cf (range_nonempty _) H, ← range_comp, iSup]
state_before: α : Type u
β : Type v
γ : Type w
inst✝⁶ : ConditionallyCompleteLinearOrder α
inst✝⁵ : TopologicalSpace α
inst✝⁴ : OrderTopology α
inst✝³ : ConditionallyCompleteLinearOrder β
inst✝² : TopologicalSpace β
inst✝¹ : OrderClosedTopology β
inst✝ : Nonempty γ
f : α → β
g : γ → α
Cf : ContinuousAt f (⨆ (i : γ), g i)
Mf : Monotone f
H : BddAbove (range g)
⊢ f (⨆ (i : γ), g i) = ⨆ (i : γ), f (g i)

tactic: rfl
state_before: α : Type u
β : Type v
γ : Type w
inst✝⁶ : ConditionallyCompleteLinearOrder α
inst✝⁵ : TopologicalSpace α
inst✝⁴ : OrderTopology α
inst✝³ : ConditionallyCompleteLinearOrder β
inst✝² : TopologicalSpace β
inst✝¹ : OrderClosedTopology β
inst✝ : Nonempty γ
f : α → β
g : γ → α
Cf : ContinuousAt f (⨆ (i : γ), g i)
Mf : Monotone f
H : BddAbove (range g)
⊢ sSup (range (f ∘ fun i => g i)) = sSup (range fun i => f (g i))
Theorem: self_sub_toIcoMod
File: Mathlib/Algebra/Order/ToIntervalMod.lean

tactic: rw [toIcoMod, sub_sub_cancel]
state_before: α : Type u_1
inst✝ : LinearOrderedAddCommGroup α
hα : Archimedean α
p : α
hp : 0 < p
a✝ b✝ c : α
n : ℤ
a b : α
⊢ b - toIcoMod hp a b = toIcoDiv hp a b • p
Theorem: Int.card_Ioo_of_lt
File: Mathlib/Data/Int/Interval.lean

tactic: rw [card_Ioo, sub_sub, toNat_sub_of_le h]
state_before: a b : ℤ
h : a < b
⊢ ↑(card (Ioo a b)) = b - a - 1
Theorem: CategoryTheory.Limits.HasEqualizersOfHasPullbacksAndBinaryProducts.pullbackFst_eq_pullback_snd
File: Mathlib/CategoryTheory/Limits/Constructions/Equalizers.lean

tactic: convert (eq_whisker pullback.condition Limits.prod.fst :
 (_ : constructEqualizer F ⟶  F.obj WalkingParallelPair.zero) = _) <;> simp
state_before: C : Type u
inst✝³ : Category C
D : Type u'
inst✝² : Category D
G : C ⥤ D
inst✝¹ : HasBinaryProducts C
inst✝ : HasPullbacks C
F : WalkingParallelPair ⥤ C
⊢ pullbackFst F = pullback.snd
Theorem: Complex.card_primitiveRoots
File: Mathlib/RingTheory/RootsOfUnity/Complex.lean

tactic: by_cases h : k = 0
state_before: k : ℕ
⊢ Finset.card (primitiveRoots k ℂ) = φ k

tactic: exact (isPrimitiveRoot_exp k h).card_primitiveRoots
state_before: case neg
k : ℕ
h : ¬k = 0
⊢ Finset.card (primitiveRoots k ℂ) = φ k

tactic: simp [h]
state_before: case pos
k : ℕ
h : k = 0
⊢ Finset.card (primitiveRoots k ℂ) = φ k
Theorem: pythagoreanTriple_comm
File: Mathlib/NumberTheory/PythagoreanTriples.lean

tactic: delta PythagoreanTriple
state_before: x y z : ℤ
⊢ PythagoreanTriple x y z ↔ PythagoreanTriple y x z

tactic: rw [add_comm]
state_before: x y z : ℤ
⊢ x * x + y * y = z * z ↔ y * y + x * x = z * z
Theorem: SymAlg.sym_mul_self
File: Mathlib/Algebra/Symmetrized.lean

tactic: rw [sym_mul_sym, ← two_mul, invOf_mul_self_assoc]
state_before: α : Type u_1
inst✝¹ : Semiring α
inst✝ : Invertible 2
a : α
⊢ ↑sym (a * a) = ↑sym a * ↑sym a
Theorem: List.DecEq_eq
File: Mathlib/Data/List/Perm.lean

tactic: funext l₁ l₂
state_before: α✝ : Type uu
β : Type vv
l₁ l₂ : List α✝
α : Type u_1
inst✝ : DecidableEq α
⊢ List.beq = fun a b => decide (a = b)

tactic: show (l₁ == l₂) = _
state_before: case h.h
α✝ : Type uu
β : Type vv
l₁✝ l₂✝ : List α✝
α : Type u_1
inst✝ : DecidableEq α
l₁ l₂ : List α
⊢ List.beq l₁ l₂ = decide (l₁ = l₂)

tactic: rw [Bool.eq_iff_eq_true_iff, @beq_iff_eq _ (_), decide_eq_true_iff]
state_before: case h.h
α✝ : Type uu
β : Type vv
l₁✝ l₂✝ : List α✝
α : Type u_1
inst✝ : DecidableEq α
l₁ l₂ : List α
⊢ (l₁ == l₂) = decide (l₁ = l₂)
Theorem: NormedField.tendsto_zero_smul_of_tendsto_zero_of_bounded
File: Mathlib/Analysis/SpecificLimits/Normed.lean

tactic: rw [← isLittleO_one_iff 𝕜] at hε⊢
state_before: α : Type ?u.57289
β : Type ?u.57292
ι✝ : Type ?u.57295
ι : Type u_1
𝕜 : Type u_2
𝔸 : Type u_3
inst✝² : NormedField 𝕜
inst✝¹ : NormedAddCommGroup 𝔸
inst✝ : NormedSpace 𝕜 𝔸
l : Filter ι
ε : ι → 𝕜
f : ι → 𝔸
hε : Tendsto ε l (𝓝 0)
hf : IsBoundedUnder (fun x x_1 => x ≤ x_1) l (norm ∘ f)
⊢ Tendsto (ε • f) l (𝓝 0)

tactic: simpa using IsLittleO.smul_isBigO hε (hf.isBigO_const (one_ne_zero : (1 : 𝕜) ≠ 0))
state_before: α : Type ?u.57289
β : Type ?u.57292
ι✝ : Type ?u.57295
ι : Type u_1
𝕜 : Type u_2
𝔸 : Type u_3
inst✝² : NormedField 𝕜
inst✝¹ : NormedAddCommGroup 𝔸
inst✝ : NormedSpace 𝕜 𝔸
l : Filter ι
ε : ι → 𝕜
f : ι → 𝔸
hε : ε =o[l] fun _x => 1
hf : IsBoundedUnder (fun x x_1 => x ≤ x_1) l (norm ∘ f)
⊢ (ε • f) =o[l] fun _x => 1