ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
Theorem: List.perm_lookmap
File: Mathlib/Data/List/Perm.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
l l₁✝ l₂✝ : List α
a : α
f : α → Option α
l₁ l₂ : List α
H : Pairwise (fun a b => ∀ c ∈ f a, ∀ d ∈ f b, a = b ∧ c = d) l₁
p : l₁ ~ l₂
⊢ lookmap f l₁ ~ lookmap f l₂
state_after: case nil
α : Type u_1
β : Type u_2
l l₁✝ l₂✝ : List α
a : α
f : α → Option α
l₁ l₂ : List α
H : Pairwise (fun a b => ∀ c ∈ f a, ∀ d ∈ f b, a = b ∧ c = d) []
⊢ lookmap f [] ~ lookmap f []

case cons
α : Type u_1
β : Type u_2
l l₁✝¹ l₂✝¹ : List α
a✝ : α
f : α → Option α
l₁✝ l₂✝ : List α
a : α
l₁ l₂ : List α
p : l₁ ~ l₂
IH : Pairwise (fun a b => ∀ c ∈ f a, ∀ d ∈ f b, a = b ∧ c = d) l₁ → lookmap f l₁ ~ lookmap f l₂
H : Pairwise (fun a b => ∀ c ∈ f a, ∀ d ∈ f b, a = b ∧ c = d) (a :: l₁)
⊢ lookmap f (a :: l₁) ~ lookmap f (a :: l₂)

case swap
α : Type u_1
β : Type u_2
l✝ l₁✝ l₂✝ : List α
a✝ : α
f : α → Option α
l₁ l₂ : List α
a b : α
l : List α
H : Pairwise (fun a b => ∀ c ∈ f a, ∀ d ∈ f b, a = b ∧ c = d) (b :: a :: l)
⊢ lookmap f (b :: a :: l) ~ lookmap f (a :: b :: l)

case trans
α : Type u_1
β : Type u_2
l l₁✝¹ l₂✝¹ : List α
a : α
f : α → Option α
l₁✝ l₂✝ l₁ l₂ l₃ : List α
p₁ : l₁ ~ l₂
a✝ : l₂ ~ l₃
IH₁ : Pairwise (fun a b => ∀ c ∈ f a, ∀ d ∈ f b, a = b ∧ c = d) l₁ → lookmap f l₁ ~ lookmap f l₂
IH₂ : Pairwise (fun a b => ∀ c ∈ f a, ∀ d ∈ f b, a = b ∧ c = d) l₂ → lookmap f l₂ ~ lookmap f l₃
H : Pairwise (fun a b => ∀ c ∈ f a, ∀ d ∈ f b, a = b ∧ c = d) l₁
⊢ lookmap f l₁ ~ lookmap f l₃
tactic: induction' p with a l₁ l₂ p IH a b l l₁ l₂ l₃ p₁ _ IH₁ IH₂
Theorem: SubMulAction.image_inclusion
File: Mathlib/GroupTheory/GroupAction/SubMulAction.lean

Proof steps:
state_before: S : Type u'
T : Type u''
R : Type u
M✝ : Type v
M : Type u_1
α : Type u_2
inst✝¹ : Monoid M
inst✝ : MulAction M α
s : SubMulAction M α
⊢ Set.range ⇑s.inclusion = s.carrier
state_after: S : Type u'
T : Type u''
R : Type u
M✝ : Type v
M : Type u_1
α : Type u_2
inst✝¹ : Monoid M
inst✝ : MulAction M α
s : SubMulAction M α
⊢ Set.range Subtype.val = s.carrier
tactic: rw [inclusion.coe_eq]
state_before: S : Type u'
T : Type u''
R : Type u
M✝ : Type v
M : Type u_1
α : Type u_2
inst✝¹ : Monoid M
inst✝ : MulAction M α
s : SubMulAction M α
⊢ Set.range Subtype.val = s.carrier
state_after: no goals
tactic: exact Subtype.range_coe
Theorem: CategoryTheory.ShortComplex.Splitting.unop_r
File: Mathlib/Algebra/Homology/ShortComplex/Exact.lean

Proof steps:
state_before: C : Type u_1
D : Type u_2
inst✝³ : Category.{?u.124213, u_1} C
inst✝² : Category.{?u.124217, u_2} D
inst✝¹ : Preadditive C
inst✝ : Preadditive D
S✝ : ShortComplex C
S : ShortComplex Cᵒᵖ
h : S.Splitting
⊢ (S.unop.f ≫ h.s.unop).op = (𝟙 S.unop.X₁).op
state_after: no goals
tactic: simp
state_before: C : Type u_1
D : Type u_2
inst✝³ : Category.{?u.124213, u_1} C
inst✝² : Category.{?u.124217, u_2} D
inst✝¹ : Preadditive C
inst✝ : Preadditive D
S✝ : ShortComplex C
S : ShortComplex Cᵒᵖ
h : S.Splitting
⊢ (h.r.unop ≫ S.unop.g).op = (𝟙 S.unop.X₃).op
state_after: no goals
tactic: simp
state_before: C : Type u_1
D : Type u_2
inst✝³ : Category.{?u.124213, u_1} C
inst✝² : Category.{?u.124217, u_2} D
inst✝¹ : Preadditive C
inst✝ : Preadditive D
S✝ : ShortComplex C
S : ShortComplex Cᵒᵖ
h : S.Splitting
⊢ (h.s.unop ≫ S.unop.f + S.unop.g ≫ h.r.unop).op = (𝟙 S.unop.X₂).op
state_after: C : Type u_1
D : Type u_2
inst✝³ : Category.{?u.124213, u_1} C
inst✝² : Category.{?u.124217, u_2} D
inst✝¹ : Preadditive C
inst✝ : Preadditive D
S✝ : ShortComplex C
S : ShortComplex Cᵒᵖ
h : S.Splitting
⊢ S.g ≫ h.s + h.r ≫ S.f = h.r ≫ S.f + S.g ≫ h.s
tactic: simp only [unop_X₂, Opposite.op_unop, unop_X₁, unop_f, unop_X₃, unop_g, op_add,
      op_comp, Quiver.Hom.op_unop, op_id, ← h.id]
state_before: C : Type u_1
D : Type u_2
inst✝³ : Category.{?u.124213, u_1} C
inst✝² : Category.{?u.124217, u_2} D
inst✝¹ : Preadditive C
inst✝ : Preadditive D
S✝ : ShortComplex C
S : ShortComplex Cᵒᵖ
h : S.Splitting
⊢ S.g ≫ h.s + h.r ≫ S.f = h.r ≫ S.f + S.g ≫ h.s
state_after: no goals
tactic: abel
Theorem: List.sublistsLenAux_append
File: Mathlib/Data/List/Sublists.lean

Proof steps:
state_before: α : Type u
β : Type v
γ : Type w
l : List α
f : List α → β
g : β → γ
r : List β
s : List γ
⊢ sublistsLenAux 0 l (g ∘ f) (map g r ++ s) = map g (sublistsLenAux 0 l f r) ++ s
state_after: α : Type u
β : Type v
γ : Type w
l : List α
f : List α → β
g : β → γ
r : List β
s : List γ
⊢ (g ∘ f) [] :: (map g r ++ s) = map g (f [] :: r) ++ s
tactic: unfold sublistsLenAux
state_before: α : Type u
β : Type v
γ : Type w
l : List α
f : List α → β
g : β → γ
r : List β
s : List γ
⊢ (g ∘ f) [] :: (map g r ++ s) = map g (f [] :: r) ++ s
state_after: no goals
tactic: simp
state_before: α : Type u
β : Type v
γ : Type w
n : ℕ
a : α
l : List α
f : List α → β
g : β → γ
r : List β
s : List γ
⊢ sublistsLenAux (n + 1) (a :: l) (g ∘ f) (map g r ++ s) = map g (sublistsLenAux (n + 1) (a :: l) f r) ++ s
state_after: α : Type u
β : Type v
γ : Type w
n : ℕ
a : α
l : List α
f : List α → β
g : β → γ
r : List β
s : List γ
⊢ sublistsLenAux (n + 1) l (g ∘ f) (sublistsLenAux n l ((g ∘ f) ∘ cons a) (map g r ++ s)) =
    map g (sublistsLenAux (n + 1) l f (sublistsLenAux n l (f ∘ cons a) r)) ++ s
tactic: unfold sublistsLenAux
state_before: α : Type u
β : Type v
γ : Type w
n : ℕ
a : α
l : List α
f : List α → β
g : β → γ
r : List β
s : List γ
⊢ sublistsLenAux (n + 1) l (g ∘ f) (sublistsLenAux n l ((g ∘ f) ∘ cons a) (map g r ++ s)) =
    map g (sublistsLenAux (n + 1) l f (sublistsLenAux n l (f ∘ cons a) r)) ++ s
state_after: no goals
tactic: simp only [show (g ∘ f) ∘ List.cons a = g ∘ f ∘ List.cons a by rfl, sublistsLenAux_append,
      sublistsLenAux_append]
Theorem: Finset.diag_card
File: Mathlib/Data/Finset/Prod.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : DecidableEq α
s t : Finset α
x : α × α
⊢ s.diag.card = s.card
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : DecidableEq α
s t : Finset α
x : α × α
⊢ s.diag = image (fun a => (a, a)) s
tactic: suffices diag s = s.image fun a => (a, a) by
    rw [this]
    apply card_image_of_injOn
    exact fun x1 _ x2 _ h3 => (Prod.mk.inj h3).1
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : DecidableEq α
s t : Finset α
x : α × α
⊢ s.diag = image (fun a => (a, a)) s
state_after: case a.mk
α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : DecidableEq α
s t : Finset α
x : α × α
a₁ a₂ : α
⊢ (a₁, a₂) ∈ s.diag ↔ (a₁, a₂) ∈ image (fun a => (a, a)) s
tactic: ext ⟨a₁, a₂⟩
state_before: case a.mk
α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : DecidableEq α
s t : Finset α
x : α × α
a₁ a₂ : α
⊢ (a₁, a₂) ∈ s.diag ↔ (a₁, a₂) ∈ image (fun a => (a, a)) s
state_after: case a.mk
α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : DecidableEq α
s t : Finset α
x : α × α
a₁ a₂ : α
⊢ (a₁, a₂).1 ∈ s ∧ (a₁, a₂).1 = (a₁, a₂).2 ↔ (a₁, a₂) ∈ image (fun a => (a, a)) s
tactic: rw [mem_diag]
state_before: case a.mk
α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : DecidableEq α
s t : Finset α
x : α × α
a₁ a₂ : α
⊢ (a₁, a₂).1 ∈ s ∧ (a₁, a₂).1 = (a₁, a₂).2 ↔ (a₁, a₂) ∈ image (fun a => (a, a)) s
state_after: case a.mk.mp
α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : DecidableEq α
s t : Finset α
x : α × α
a₁ a₂ : α
h : (a₁, a₂).1 ∈ s ∧ (a₁, a₂).1 = (a₁, a₂).2
⊢ ∃ a ∈ s, (a, a) = (a₁, a₂)

case a.mk.mpr
α : Type u_1
β : Type u_2
γ : Type u_3
inst✝ : DecidableEq α
s t : Finset α
x : α × α
a₁ a₂ : α
h : ∃ a ∈ s, (a, a) = (a₁, a₂)
⊢ (a₁, a₂).1 ∈ s ∧ (a₁, a₂).1 = (a₁, a₂).2
tactic: constructor <;> intro h <;> rw [Finset.mem_image] at *
Theorem: WeierstrassCurve.Affine.polynomial_ne_zero
File: Mathlib/AlgebraicGeometry/EllipticCurve/Affine.lean

Proof steps:
state_before: R : Type u
inst✝¹ : CommRing R
W : Affine R
inst✝ : Nontrivial R
⊢ W.polynomial ≠ 0
state_after: R : Type u
inst✝¹ : CommRing R
W : Affine R
inst✝ : Nontrivial R
⊢ { a := 0, b := 1, c := { a := 0, b := 0, c := W.a₁, d := W.a₃ }.toPoly,
        d := { a := -1, b := -W.a₂, c := -W.a₄, d := -W.a₆ }.toPoly }.toPoly ≠
    0
tactic: rw [polynomial_eq]
state_before: R : Type u
inst✝¹ : CommRing R
W : Affine R
inst✝ : Nontrivial R
⊢ { a := 0, b := 1, c := { a := 0, b := 0, c := W.a₁, d := W.a₃ }.toPoly,
        d := { a := -1, b := -W.a₂, c := -W.a₄, d := -W.a₆ }.toPoly }.toPoly ≠
    0
state_after: no goals
tactic: exact Cubic.ne_zero_of_b_ne_zero one_ne_zero
Theorem: unitInterval.one_minus_le_one
File: Mathlib/Topology/UnitInterval.lean

Proof steps:
state_before: x : ↑I
⊢ 1 - ↑x ≤ 1
state_after: no goals
tactic: simpa using x.2.1
Theorem: Equiv.semiconj₂_conj
File: Mathlib/Logic/Equiv/Basic.lean

Proof steps:
state_before: α₁ : Type u_1
β₁ : Type u_2
e : α₁ ≃ β₁
f : α₁ → α₁ → α₁
x y : α₁
⊢ e (f x y) = (e.arrowCongr e.conj) f (e x) (e y)
state_after: no goals
tactic: simp [arrowCongr]
Theorem: MeasurableSet.sUnion
File: Mathlib/MeasureTheory/MeasurableSpace/Defs.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
δ' : Type u_5
ι : Sort u_6
s✝ t u : Set α
m : MeasurableSpace α
s : Set (Set α)
hs : s.Countable
h : ∀ t ∈ s, MeasurableSet t
⊢ MeasurableSet (⋃₀ s)
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
δ' : Type u_5
ι : Sort u_6
s✝ t u : Set α
m : MeasurableSpace α
s : Set (Set α)
hs : s.Countable
h : ∀ t ∈ s, MeasurableSet t
⊢ MeasurableSet (⋃ i ∈ s, i)
tactic: rw [sUnion_eq_biUnion]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
δ' : Type u_5
ι : Sort u_6
s✝ t u : Set α
m : MeasurableSpace α
s : Set (Set α)
hs : s.Countable
h : ∀ t ∈ s, MeasurableSet t
⊢ MeasurableSet (⋃ i ∈ s, i)
state_after: no goals
tactic: exact .biUnion hs h
Theorem: Real.volume_le_diam
File: Mathlib/MeasureTheory/Measure/Lebesgue/Basic.lean

Proof steps:
state_before: ι : Type u_1
inst✝ : Fintype ι
s : Set ℝ
⊢ volume s ≤ EMetric.diam s
state_after: case pos
ι : Type u_1
inst✝ : Fintype ι
s : Set ℝ
hs : Bornology.IsBounded s
⊢ volume s ≤ EMetric.diam s

case neg
ι : Type u_1
inst✝ : Fintype ι
s : Set ℝ
hs : ¬Bornology.IsBounded s
⊢ volume s ≤ EMetric.diam s
tactic: by_cases hs : Bornology.IsBounded s
Theorem: spectrum.unit_smul_eq_smul
File: Mathlib/Algebra/Algebra/Spectrum.lean

Proof steps:
state_before: R : Type u
A : Type v
inst✝² : CommSemiring R
inst✝¹ : Ring A
inst✝ : Algebra R A
a : A
r : Rˣ
⊢ σ (r • a) = r • σ a
state_after: case h
R : Type u
A : Type v
inst✝² : CommSemiring R
inst✝¹ : Ring A
inst✝ : Algebra R A
a : A
r : Rˣ
x : R
⊢ x ∈ σ (r • a) ↔ x ∈ r • σ a
tactic: ext x
state_before: case h
R : Type u
A : Type v
inst✝² : CommSemiring R
inst✝¹ : Ring A
inst✝ : Algebra R A
a : A
r : Rˣ
x : R
⊢ x ∈ σ (r • a) ↔ x ∈ r • σ a
state_after: case h
R : Type u
A : Type v
inst✝² : CommSemiring R
inst✝¹ : Ring A
inst✝ : Algebra R A
a : A
r : Rˣ
x : R
x_eq : x = r • r⁻¹ • x
⊢ x ∈ σ (r • a) ↔ x ∈ r • σ a
tactic: have x_eq : x = r • r⁻¹ • x := by simp
state_before: case h
R : Type u
A : Type v
inst✝² : CommSemiring R
inst✝¹ : Ring A
inst✝ : Algebra R A
a : A
r : Rˣ
x : R
x_eq : x = r • r⁻¹ • x
⊢ x ∈ σ (r • a) ↔ x ∈ r • σ a
state_after: case h
R : Type u
A : Type v
inst✝² : CommSemiring R
inst✝¹ : Ring A
inst✝ : Algebra R A
a : A
r : Rˣ
x : R
x_eq : x = r • r⁻¹ • x
⊢ r • r⁻¹ • x ∈ σ (r • a) ↔ x ∈ r • σ a
tactic: nth_rw 1 [x_eq]
state_before: case h
R : Type u
A : Type v
inst✝² : CommSemiring R
inst✝¹ : Ring A
inst✝ : Algebra R A
a : A
r : Rˣ
x : R
x_eq : x = r • r⁻¹ • x
⊢ r • r⁻¹ • x ∈ σ (r • a) ↔ x ∈ r • σ a
state_after: case h
R : Type u
A : Type v
inst✝² : CommSemiring R
inst✝¹ : Ring A
inst✝ : Algebra R A
a : A
r : Rˣ
x : R
x_eq : x = r • r⁻¹ • x
⊢ r⁻¹ • x ∈ σ a ↔ x ∈ r • σ a
tactic: rw [smul_mem_smul_iff]
state_before: case h
R : Type u
A : Type v
inst✝² : CommSemiring R
inst✝¹ : Ring A
inst✝ : Algebra R A
a : A
r : Rˣ
x : R
x_eq : x = r • r⁻¹ • x
⊢ r⁻¹ • x ∈ σ a ↔ x ∈ r • σ a
state_after: case h.mp
R : Type u
A : Type v
inst✝² : CommSemiring R
inst✝¹ : Ring A
inst✝ : Algebra R A
a : A
r : Rˣ
x : R
x_eq : x = r • r⁻¹ • x
⊢ r⁻¹ • x ∈ σ a → x ∈ r • σ a

case h.mpr
R : Type u
A : Type v
inst✝² : CommSemiring R
inst✝¹ : Ring A
inst✝ : Algebra R A
a : A
r : Rˣ
x : R
x_eq : x = r • r⁻¹ • x
⊢ x ∈ r • σ a → r⁻¹ • x ∈ σ a
tactic: constructor
Theorem: Ideal.isPrime_ideal_prod_top'
File: Mathlib/RingTheory/Ideal/Prod.lean

Proof steps:
state_before: R : Type u
S : Type v
inst✝¹ : Semiring R
inst✝ : Semiring S
I✝ I' : Ideal R
J J' I : Ideal S
h : I.IsPrime
⊢ (⊤.prod I).IsPrime
state_after: R : Type u
S : Type v
inst✝¹ : Semiring R
inst✝ : Semiring S
I✝ I' : Ideal R
J J' I : Ideal S
h : I.IsPrime
this : (I.prod ⊤).IsPrime := isPrime_ideal_prod_top
⊢ (⊤.prod I).IsPrime
tactic: letI : IsPrime (prod I (⊤ : Ideal R)) := isPrime_ideal_prod_top
state_before: R : Type u
S : Type v
inst✝¹ : Semiring R
inst✝ : Semiring S
I✝ I' : Ideal R
J J' I : Ideal S
h : I.IsPrime
this : (I.prod ⊤).IsPrime := isPrime_ideal_prod_top
⊢ (⊤.prod I).IsPrime
state_after: R : Type u
S : Type v
inst✝¹ : Semiring R
inst✝ : Semiring S
I✝ I' : Ideal R
J J' I : Ideal S
h : I.IsPrime
this : (I.prod ⊤).IsPrime := isPrime_ideal_prod_top
⊢ (map (↑RingEquiv.prodComm) (I.prod ⊤)).IsPrime
tactic: rw [← map_prodComm_prod]
state_before: R : Type u
S : Type v
inst✝¹ : Semiring R
inst✝ : Semiring S
I✝ I' : Ideal R
J J' I : Ideal S
h : I.IsPrime
this : (I.prod ⊤).IsPrime := isPrime_ideal_prod_top
⊢ (map (↑RingEquiv.prodComm) (I.prod ⊤)).IsPrime
state_after: no goals
tactic: exact map_isPrime_of_equiv (RingEquiv.prodComm (R := S) (S := R))
Theorem: AddAction.stabilizer_finset_univ
File: Mathlib/Algebra/Pointwise/Stabilizer.lean

Proof steps:
state_before: G : Type u_1
H : Type u_2
α : Type u_3
inst✝⁴ : Group G
inst✝³ : Group H
inst✝² : MulAction G α
a : G
inst✝¹ : DecidableEq α
inst✝ : Fintype α
⊢ stabilizer G Finset.univ = ⊤
state_after: case h
G : Type u_1
H : Type u_2
α : Type u_3
inst✝⁴ : Group G
inst✝³ : Group H
inst✝² : MulAction G α
a : G
inst✝¹ : DecidableEq α
inst✝ : Fintype α
x✝ : G
⊢ x✝ ∈ stabilizer G Finset.univ ↔ x✝ ∈ ⊤
tactic: ext
state_before: case h
G : Type u_1
H : Type u_2
α : Type u_3
inst✝⁴ : Group G
inst✝³ : Group H
inst✝² : MulAction G α
a : G
inst✝¹ : DecidableEq α
inst✝ : Fintype α
x✝ : G
⊢ x✝ ∈ stabilizer G Finset.univ ↔ x✝ ∈ ⊤
state_after: no goals
tactic: simp
Theorem: PartialEquiv.trans'_target
File: Mathlib/Logic/Equiv/PartialEquiv.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
e : PartialEquiv α β
e'✝ e' : PartialEquiv β γ
h : e.target = e'.source
x : α
hx : x ∈ e.source
⊢ (↑e' ∘ ↑e) x ∈ e'.target
state_after: no goals
tactic: simp [← h, hx]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
e : PartialEquiv α β
e'✝ e' : PartialEquiv β γ
h : e.target = e'.source
y : γ
hy : y ∈ e'.target
⊢ (↑e.symm ∘ ↑e'.symm) y ∈ e.source
state_after: no goals
tactic: simp [h, hy]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
e : PartialEquiv α β
e'✝ e' : PartialEquiv β γ
h : e.target = e'.source
x : α
hx : x ∈ e.source
⊢ (↑e.symm ∘ ↑e'.symm) ((↑e' ∘ ↑e) x) = x
state_after: no goals
tactic: simp [hx, ← h]
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
δ : Type u_4
e : PartialEquiv α β
e'✝ e' : PartialEquiv β γ
h : e.target = e'.source
y : γ
hy : y ∈ e'.target
⊢ (↑e' ∘ ↑e) ((↑e.symm ∘ ↑e'.symm) y) = y
state_after: no goals
tactic: simp [hy, h]
Theorem: LinearMap.BilinForm.dualSubmodule_dualSubmodule_flip_of_basis
File: Mathlib/LinearAlgebra/BilinearForm/DualLattice.lean

Proof steps:
state_before: R : Type u_4
S : Type u_2
M : Type u_3
inst✝⁷ : CommRing R
inst✝⁶ : Field S
inst✝⁵ : AddCommGroup M
inst✝⁴ : Algebra R S
inst✝³ : Module R M
inst✝² : Module S M
inst✝¹ : IsScalarTower R S M
B : BilinForm S M
ι : Type u_1
inst✝ : Finite ι
hB : B.Nondegenerate
b : Basis ι S M
⊢ B.dualSubmodule (B.flip.dualSubmodule (Submodule.span R (Set.range ⇑b))) = Submodule.span R (Set.range ⇑b)
state_after: no goals
tactic: classical
  letI := FiniteDimensional.of_fintype_basis b
  rw [dualSubmodule_span_of_basis _ hB.flip, dualSubmodule_span_of_basis B hB,
    dualBasis_dualBasis_flip B hB]
Theorem: Finset.sum_range_diag_flip
File: Mathlib/Algebra/BigOperators/Intervals.lean

Proof steps:
state_before: α : Type u_1
M : Type u_2
inst✝ : CommMonoid M
s₂ s₁ s : Finset α
a : α
g f✝ : α → M
n : ℕ
f : ℕ → ℕ → M
⊢ ∏ m ∈ range n, ∏ k ∈ range (m + 1), f k (m - k) = ∏ m ∈ range n, ∏ k ∈ range (n - m), f m k
state_after: α : Type u_1
M : Type u_2
inst✝ : CommMonoid M
s₂ s₁ s : Finset α
a : α
g f✝ : α → M
n : ℕ
f : ℕ → ℕ → M
⊢ ∏ x ∈ (range n).sigma fun m => range (m + 1), f x.snd (x.fst - x.snd) =
    ∏ x ∈ (range n).sigma fun m => range (n - m), f x.fst x.snd
tactic: rw [prod_sigma', prod_sigma']
state_before: α : Type u_1
M : Type u_2
inst✝ : CommMonoid M
s₂ s₁ s : Finset α
a : α
g f✝ : α → M
n : ℕ
f : ℕ → ℕ → M
⊢ ∏ x ∈ (range n).sigma fun m => range (m + 1), f x.snd (x.fst - x.snd) =
    ∏ x ∈ (range n).sigma fun m => range (n - m), f x.fst x.snd
state_after: case refine_1
α : Type u_1
M : Type u_2
inst✝ : CommMonoid M
s₂ s₁ s : Finset α
a : α
g f✝ : α → M
n : ℕ
f : ℕ → ℕ → M
⊢ ∀ (a b : ℕ), a < n → b ≤ a → b < n
tactic: refine prod_nbij' (fun a ↦ ⟨a.2, a.1 - a.2⟩) (fun a ↦ ⟨a.1 + a.2, a.1⟩) ?_ ?_ ?_ ?_ ?_ <;>
    simp (config := { contextual := true }) only [mem_sigma, mem_range, lt_tsub_iff_left,
      Nat.lt_succ_iff, le_add_iff_nonneg_right, Nat.zero_le, and_true, and_imp, imp_self,
      implies_true, Sigma.forall, forall_const, add_tsub_cancel_of_le, Sigma.mk.inj_iff,
      add_tsub_cancel_left, heq_eq_eq]
state_before: case refine_1
α : Type u_1
M : Type u_2
inst✝ : CommMonoid M
s₂ s₁ s : Finset α
a : α
g f✝ : α → M
n : ℕ
f : ℕ → ℕ → M
⊢ ∀ (a b : ℕ), a < n → b ≤ a → b < n
state_after: no goals
tactic: exact fun a b han hba ↦ lt_of_le_of_lt hba han
Theorem: Finset.prod_sdiff
File: Mathlib/Algebra/BigOperators/Group/Finset.lean

Proof steps:
state_before: ι : Type u_1
κ : Type u_2
α : Type u_3
β : Type u_4
γ : Type u_5
s s₁ s₂ : Finset α
a : α
f g : α → β
inst✝¹ : CommMonoid β
inst✝ : DecidableEq α
h : s₁ ⊆ s₂
⊢ (∏ x ∈ s₂ \ s₁, f x) * ∏ x ∈ s₁, f x = ∏ x ∈ s₂, f x
state_after: no goals
tactic: rw [← prod_union sdiff_disjoint, sdiff_union_of_subset h]
Theorem: RingHom.surjective_respectsIso
File: Mathlib/RingTheory/RingHom/Surjective.lean

Proof steps:
state_before: ⊢ RespectsIso fun {X Y} [CommRing X] [CommRing Y] f => Function.Surjective ⇑f
state_after: ⊢ ∀ {R S : Type u_1} [inst : CommRing R] [inst_1 : CommRing S] (e : R ≃+* S), Function.Surjective ⇑e.toRingHom
tactic: apply surjective_stableUnderComposition.respectsIso
state_before: ⊢ ∀ {R S : Type u_1} [inst : CommRing R] [inst_1 : CommRing S] (e : R ≃+* S), Function.Surjective ⇑e.toRingHom
state_after: R✝ S✝ : Type u_1
inst✝¹ : CommRing R✝
inst✝ : CommRing S✝
e : R✝ ≃+* S✝
⊢ Function.Surjective ⇑e.toRingHom
tactic: intros _ _ _ _ e
state_before: R✝ S✝ : Type u_1
inst✝¹ : CommRing R✝
inst✝ : CommRing S✝
e : R✝ ≃+* S✝
⊢ Function.Surjective ⇑e.toRingHom
state_after: no goals
tactic: exact e.surjective
Theorem: isLUB_ciSup_set
File: Mathlib/Order/ConditionallyCompleteLattice/Basic.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
inst✝ : ConditionallyCompleteLattice α
s✝ t : Set α
a b : α
f : β → α
s : Set β
H : BddAbove (f '' s)
Hne : s.Nonempty
⊢ IsLUB (f '' s) (⨆ i, f ↑i)
state_after: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
inst✝ : ConditionallyCompleteLattice α
s✝ t : Set α
a b : α
f : β → α
s : Set β
H : BddAbove (f '' s)
Hne : s.Nonempty
⊢ IsLUB (f '' s) (sSup (f '' s))
tactic: rw [← sSup_image']
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Sort u_4
inst✝ : ConditionallyCompleteLattice α
s✝ t : Set α
a b : α
f : β → α
s : Set β
H : BddAbove (f '' s)
Hne : s.Nonempty
⊢ IsLUB (f '' s) (sSup (f '' s))
state_after: no goals
tactic: exact isLUB_csSup (Hne.image _) H
Theorem: Finsupp.sigma_sum
File: Mathlib/Data/Finsupp/Basic.lean

Proof steps:
state_before: α : Type u_1
β : Type u_2
γ : Type u_3
ι : Type u_4
M : Type u_5
M' : Type u_6
N : Type u_7
P : Type u_8
G : Type u_9
H : Type u_10
R : Type u_11
S : Type u_12
αs : ι → Type u_13
inst✝¹ : Zero M
l : (i : ι) × αs i →₀ M
inst✝ : AddCommMonoid N
f : (i : ι) × αs i → M → N
⊢ l.sum f = ∑ i ∈ l.splitSupport, (l.split i).sum fun a b => f ⟨i, a⟩ b
state_after: no goals
tactic: simp only [sum, sigma_support, sum_sigma, split_apply]
Theorem: Complex.sin_mul_I
File: Mathlib/Data/Complex/Exponential.lean

Proof steps:
state_before: x y : ℂ
⊢ sin (x * I) = sinh x * I
state_after: x y : ℂ
h : I * sin (x * I) = -sinh x
⊢ sin (x * I) = sinh x * I
tactic: have h : I * sin (x * I) = -sinh x := by
    rw [mul_comm, ← sinh_mul_I]
    ring_nf
    simp
state_before: x y : ℂ
h : I * sin (x * I) = -sinh x
⊢ sin (x * I) = sinh x * I
state_after: x y : ℂ
h : I * sin (x * I) = -sinh x
⊢ sin (x * I) = -(I * sin (x * I)) * I
tactic: rw [← neg_neg (sinh x), ← h]
state_before: x y : ℂ
h : I * sin (x * I) = -sinh x
⊢ sin (x * I) = -(I * sin (x * I)) * I
state_after: no goals
tactic: apply Complex.ext <;> simp
Theorem: HasDerivAt.const_mul
File: Mathlib/Analysis/Calculus/Deriv/Mul.lean

Proof steps:
state_before: 𝕜 : Type u
inst✝¹⁰ : NontriviallyNormedField 𝕜
F : Type v
inst✝⁹ : NormedAddCommGroup F
inst✝⁸ : NormedSpace 𝕜 F
E : Type w
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace 𝕜 E
G : Type u_1
inst✝⁵ : NormedAddCommGroup G
inst✝⁴ : NormedSpace 𝕜 G
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t : Set 𝕜
L L₁ L₂ : Filter 𝕜
𝕜' : Type u_2
𝔸 : Type u_3
inst✝³ : NormedField 𝕜'
inst✝² : NormedRing 𝔸
inst✝¹ : NormedAlgebra 𝕜 𝕜'
inst✝ : NormedAlgebra 𝕜 𝔸
c✝ d : 𝕜 → 𝔸
c' d' : 𝔸
u v : 𝕜 → 𝕜'
c : 𝔸
hd : HasDerivAt d d' x
⊢ HasDerivAt (fun y => c * d y) (c * d') 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
G : Type u_1
inst✝⁵ : NormedAddCommGroup G
inst✝⁴ : NormedSpace 𝕜 G
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t : Set 𝕜
L L₁ L₂ : Filter 𝕜
𝕜' : Type u_2
𝔸 : Type u_3
inst✝³ : NormedField 𝕜'
inst✝² : NormedRing 𝔸
inst✝¹ : NormedAlgebra 𝕜 𝕜'
inst✝ : NormedAlgebra 𝕜 𝔸
c✝ d : 𝕜 → 𝔸
c' d' : 𝔸
u v : 𝕜 → 𝕜'
c : 𝔸
hd : HasDerivWithinAt d d' univ x
⊢ HasDerivWithinAt (fun y => c * d y) (c * d') univ x
tactic: rw [← hasDerivWithinAt_univ] at *
state_before: 𝕜 : Type u
inst✝¹⁰ : NontriviallyNormedField 𝕜
F : Type v
inst✝⁹ : NormedAddCommGroup F
inst✝⁸ : NormedSpace 𝕜 F
E : Type w
inst✝⁷ : NormedAddCommGroup E
inst✝⁶ : NormedSpace 𝕜 E
G : Type u_1
inst✝⁵ : NormedAddCommGroup G
inst✝⁴ : NormedSpace 𝕜 G
f f₀ f₁ g : 𝕜 → F
f' f₀' f₁' g' : F
x : 𝕜
s t : Set 𝕜
L L₁ L₂ : Filter 𝕜
𝕜' : Type u_2
𝔸 : Type u_3
inst✝³ : NormedField 𝕜'
inst✝² : NormedRing 𝔸
inst✝¹ : NormedAlgebra 𝕜 𝕜'
inst✝ : NormedAlgebra 𝕜 𝔸
c✝ d : 𝕜 → 𝔸
c' d' : 𝔸
u v : 𝕜 → 𝕜'
c : 𝔸
hd : HasDerivWithinAt d d' univ x
⊢ HasDerivWithinAt (fun y => c * d y) (c * d') univ x
state_after: no goals
tactic: exact hd.const_mul c
Theorem: CategoryTheory.Limits.image.factorThruImage_preComp
File: Mathlib/CategoryTheory/Limits/Shapes/Images.lean

Proof steps:
state_before: C : Type u
inst✝² : Category.{v, u} C
X Y : C
f : X ⟶ Y
Z : C
g : Y ⟶ Z
inst✝¹ : HasImage g
inst✝ : HasImage (f ≫ g)
⊢ factorThruImage (f ≫ g) ≫ preComp f g = f ≫ factorThruImage g
state_after: no goals
tactic: simp [image.preComp]
Theorem: List.findIdx_cons
File: .lake/packages/batteries/Batteries/Data/List/Lemmas.lean

Proof steps:
state_before: α : Type u_1
p : α → Bool
b : α
l : List α
⊢ findIdx p (b :: l) = bif p b then 0 else findIdx p l + 1
state_after: no goals
tactic: cases H : p b with
  | true => simp [H, findIdx, findIdx.go]
  | false => simp [H, findIdx, findIdx.go, findIdx_go_succ]
state_before: α : Type u_1
p✝ : α → Bool
b : α
l✝ : List α
p : α → Bool
l : List α
n : Nat
⊢ findIdx.go p l (n + 1) = findIdx.go p l n + 1
state_after: no goals
tactic: cases l with
    | nil => unfold findIdx.go; exact Nat.succ_eq_add_one n
    | cons head tail =>
      unfold findIdx.go
      cases p head <;> simp only [cond_false, cond_true]
      exact findIdx_go_succ p tail (n + 1)