tasksource/leandojo huggingface dataset:
Theorem: Finset.disjiUnion_map
File: Mathlib/Data/Finset/Image.lean

tactic: obtain ⟨xa, hfa, rfl⟩ := mem_map.mp hxa
state_before: α : Type ?u.54766
β : Type ?u.54769
γ : Type ?u.54772
f✝ : α ↪ β
s✝ s : Finset α
t : α → Finset β
f : β ↪ γ
h : Set.PairwiseDisjoint (↑s) t
a : α
ha : a ∈ ↑s
b : α
hb : b ∈ ↑s
hab : a ≠ b
x : γ
hxa : x ∈ (fun a => map f (t a)) a
hxb : x ∈ (fun a => map f (t a)) b
⊢ False

tactic: obtain ⟨xb, hfb, hfab⟩ := mem_map.mp hxb
state_before: case intro.intro
α : Type ?u.54766
β : Type ?u.54769
γ : Type ?u.54772
f✝ : α ↪ β
s✝ s : Finset α
t : α → Finset β
f : β ↪ γ
h : Set.PairwiseDisjoint (↑s) t
a : α
ha : a ∈ ↑s
b : α
hb : b ∈ ↑s
hab : a ≠ b
xa : β
hfa : xa ∈ t a
hxa : ↑f xa ∈ (fun a => map f (t a)) a
hxb : ↑f xa ∈ (fun a => map f (t a)) b
⊢ False

tactic: obtain rfl := f.injective hfab
state_before: case intro.intro.intro.intro
α : Type ?u.54766
β : Type ?u.54769
γ : Type ?u.54772
f✝ : α ↪ β
s✝ s : Finset α
t : α → Finset β
f : β ↪ γ
h : Set.PairwiseDisjoint (↑s) t
a : α
ha : a ∈ ↑s
b : α
hb : b ∈ ↑s
hab : a ≠ b
xa : β
hfa : xa ∈ t a
hxa : ↑f xa ∈ (fun a => map f (t a)) a
hxb : ↑f xa ∈ (fun a => map f (t a)) b
xb : β
hfb : xb ∈ t b
hfab : ↑f xb = ↑f xa
⊢ False

tactic: exact disjoint_left.mp (h ha hb hab) hfa hfb
state_before: case intro.intro.intro.intro
α : Type ?u.54766
β : Type ?u.54769
γ : Type ?u.54772
f✝ : α ↪ β
s✝ s : Finset α
t : α → Finset β
f : β ↪ γ
h : Set.PairwiseDisjoint (↑s) t
a : α
ha : a ∈ ↑s
b : α
hb : b ∈ ↑s
hab : a ≠ b
xb : β
hfb : xb ∈ t b
hfa : xb ∈ t a
hxa : ↑f xb ∈ (fun a => map f (t a)) a
hxb : ↑f xb ∈ (fun a => map f (t a)) b
hfab : ↑f xb = ↑f xb
⊢ False
Theorem: Action.rightUnitor_inv_hom
File: Mathlib/RepresentationTheory/Action.lean

tactic: dsimp [Monoidal.transport_rightUnitor]
state_before: V : Type (u + 1)
inst✝¹ : LargeCategory V
G : MonCat
inst✝ : MonoidalCategory V
X : Action V G
⊢ (ρ_ X).inv.hom = (ρ_ X.V).inv

tactic: simp
state_before: V : Type (u + 1)
inst✝¹ : LargeCategory V
G : MonCat
inst✝ : MonoidalCategory V
X : Action V G
⊢ 𝟙 X.V ≫ (ρ_ X.V).inv ≫ (𝟙 X.V ⊗ 𝟙 (𝟙_ V)) = (ρ_ X.V).inv
Theorem: intervalIntegral.integral_indicator
File: Mathlib/MeasureTheory/Integral/IntervalIntegral.lean

tactic: have : {x | x ≤ a₂} ∩ Ioc a₁ a₃ = Ioc a₁ a₂ := Iic_inter_Ioc_of_le h.2
state_before: ι : Type ?u.16911495
𝕜 : Type ?u.16911498
E : Type u_1
F : Type ?u.16911504
A : Type ?u.16911507
inst✝² : NormedAddCommGroup E
inst✝¹ : CompleteSpace E
inst✝ : NormedSpace ℝ E
a b c d : ℝ
f g : ℝ → E
μ : MeasureTheory.Measure ℝ
a₁ a₂ a₃ : ℝ
h : a₂ ∈ Icc a₁ a₃
⊢ (∫ (x : ℝ) in a₁..a₃, indicator {x | x ≤ a₂} f x ∂μ) = ∫ (x : ℝ) in a₁..a₂, f x ∂μ

tactic: rw [integral_of_le h.1, integral_of_le (h.1.trans h.2), integral_indicator,
  Measure.restrict_restrict, this]
state_before: ι : Type ?u.16911495
𝕜 : Type ?u.16911498
E : Type u_1
F : Type ?u.16911504
A : Type ?u.16911507
inst✝² : NormedAddCommGroup E
inst✝¹ : CompleteSpace E
inst✝ : NormedSpace ℝ E
a b c d : ℝ
f g : ℝ → E
μ : MeasureTheory.Measure ℝ
a₁ a₂ a₃ : ℝ
h : a₂ ∈ Icc a₁ a₃
this : {x | x ≤ a₂} ∩ Ioc a₁ a₃ = Ioc a₁ a₂
⊢ (∫ (x : ℝ) in a₁..a₃, indicator {x | x ≤ a₂} f x ∂μ) = ∫ (x : ℝ) in a₁..a₂, f x ∂μ

tactic: exact measurableSet_Iic
state_before: ι : Type ?u.16911495
𝕜 : Type ?u.16911498
E : Type u_1
F : Type ?u.16911504
A : Type ?u.16911507
inst✝² : NormedAddCommGroup E
inst✝¹ : CompleteSpace E
inst✝ : NormedSpace ℝ E
a b c d : ℝ
f g : ℝ → E
μ : MeasureTheory.Measure ℝ
a₁ a₂ a₃ : ℝ
h : a₂ ∈ Icc a₁ a₃
this : {x | x ≤ a₂} ∩ Ioc a₁ a₃ = Ioc a₁ a₂
⊢ MeasurableSet {x | x ≤ a₂}

ι : Type ?u.16911495
𝕜 : Type ?u.16911498
E : Type u_1
F : Type ?u.16911504
A : Type ?u.16911507
inst✝² : NormedAddCommGroup E
inst✝¹ : CompleteSpace E
inst✝ : NormedSpace ℝ E
a b c d : ℝ
f g : ℝ → E
μ : MeasureTheory.Measure ℝ
a₁ a₂ a₃ : ℝ
h : a₂ ∈ Icc a₁ a₃
this : {x | x ≤ a₂} ∩ Ioc a₁ a₃ = Ioc a₁ a₂
⊢ MeasurableSet {x | x ≤ a₂}

tactic: all_goals apply measurableSet_Iic
state_before: ι : Type ?u.16911495
𝕜 : Type ?u.16911498
E : Type u_1
F : Type ?u.16911504
A : Type ?u.16911507
inst✝² : NormedAddCommGroup E
inst✝¹ : CompleteSpace E
inst✝ : NormedSpace ℝ E
a b c d : ℝ
f g : ℝ → E
μ : MeasureTheory.Measure ℝ
a₁ a₂ a₃ : ℝ
h : a₂ ∈ Icc a₁ a₃
this : {x | x ≤ a₂} ∩ Ioc a₁ a₃ = Ioc a₁ a₂
⊢ MeasurableSet {x | x ≤ a₂}

tactic: apply measurableSet_Iic
state_before: ι : Type ?u.16911495
𝕜 : Type ?u.16911498
E : Type u_1
F : Type ?u.16911504
A : Type ?u.16911507
inst✝² : NormedAddCommGroup E
inst✝¹ : CompleteSpace E
inst✝ : NormedSpace ℝ E
a b c d : ℝ
f g : ℝ → E
μ : MeasureTheory.Measure ℝ
a₁ a₂ a₃ : ℝ
h : a₂ ∈ Icc a₁ a₃
this : {x | x ≤ a₂} ∩ Ioc a₁ a₃ = Ioc a₁ a₂
⊢ MeasurableSet {x | x ≤ a₂}
Theorem: PNat.factorMultiset_gcd
File: Mathlib/Data/PNat/Factors.lean

tactic: apply le_antisymm
state_before: m n : ℕ+
⊢ factorMultiset (gcd m n) = factorMultiset m ⊓ factorMultiset n

tactic: apply le_inf_iff.mpr
state_before: case a
m n : ℕ+
⊢ factorMultiset (gcd m n) ≤ factorMultiset m ⊓ factorMultiset n

tactic: constructor <;> apply factorMultiset_le_iff.mpr
state_before: case a
m n : ℕ+
⊢ factorMultiset (gcd m n) ≤ factorMultiset m ∧ factorMultiset (gcd m n) ≤ factorMultiset n

tactic: exact gcd_dvd_left m n
state_before: case a.left
m n : ℕ+
⊢ gcd m n ∣ m

case a.right
m n : ℕ+
⊢ gcd m n ∣ n

tactic: exact gcd_dvd_right m n
state_before: case a.right
m n : ℕ+
⊢ gcd m n ∣ n

tactic: rw [← PrimeMultiset.prod_dvd_iff, prod_factorMultiset]
state_before: case a
m n : ℕ+
⊢ factorMultiset m ⊓ factorMultiset n ≤ factorMultiset (gcd m n)

tactic: apply dvd_gcd <;> rw [PrimeMultiset.prod_dvd_iff']
state_before: case a
m n : ℕ+
⊢ PrimeMultiset.prod (factorMultiset m ⊓ factorMultiset n) ∣ gcd m n

tactic: exact inf_le_left
state_before: case a.hm
m n : ℕ+
⊢ factorMultiset m ⊓ factorMultiset n ≤ factorMultiset m

case a.hn
m n : ℕ+
⊢ factorMultiset m ⊓ factorMultiset n ≤ factorMultiset n

tactic: exact inf_le_right
state_before: case a.hn
m n : ℕ+
⊢ factorMultiset m ⊓ factorMultiset n ≤ factorMultiset n
Theorem: AddCommGroup.int_cast_modEq_int_cast
File: Mathlib/Algebra/ModEq.lean

tactic: simp_rw [ModEq, ← Int.cast_mul_eq_zsmul_cast]
state_before: α : Type u_1
inst✝¹ : AddCommGroupWithOne α
inst✝ : CharZero α
a b z : ℤ
⊢ ↑a ≡ ↑b [PMOD ↑z] ↔ a ≡ b [PMOD z]

tactic: norm_cast
state_before: α : Type u_1
inst✝¹ : AddCommGroupWithOne α
inst✝ : CharZero α
a b z : ℤ
⊢ (∃ z_1, ↑b - ↑a = ↑(z_1 * z)) ↔ ∃ z_1, b - a = z_1 • z
Theorem: Complex.sin_sq_add_cos_sq
File: Mathlib/Data/Complex/Exponential.lean

tactic: rw [cosh_mul_I, sinh_mul_I, mul_pow, I_sq, mul_neg_one, sub_neg_eq_add, add_comm]
state_before: x y : ℂ
⊢ sin x ^ 2 + cos x ^ 2 = cosh (x * I) ^ 2 - sinh (x * I) ^ 2
Theorem: Submodule.Quotient.mk_eq_zero
File: Mathlib/LinearAlgebra/Quotient.lean

tactic: simpa using (Quotient.eq' p : mk x = 0 ↔ _)
state_before: R : Type u_2
M : Type u_1
r : R
x y : M
inst✝² : Ring R
inst✝¹ : AddCommGroup M
inst✝ : Module R M
p p' : Submodule R M
⊢ mk x = 0 ↔ x ∈ p
Theorem: Nat.coprime.mul_add_mul_ne_mul
File: Mathlib/Data/Nat/GCD/Basic.lean

tactic: intro h
state_before: m n a b : ℕ
cop : coprime m n
ha : a ≠ 0
hb : b ≠ 0
⊢ a * m + b * n ≠ m * n

tactic: obtain ⟨x, rfl⟩ : n ∣ a :=
  cop.symm.dvd_of_dvd_mul_right
    ((Nat.dvd_add_iff_left (Nat.dvd_mul_left n b)).mpr
      ((congr_arg _ h).mpr (Nat.dvd_mul_left n m)))
state_before: m n a b : ℕ
cop : coprime m n
ha : a ≠ 0
hb : b ≠ 0
h : a * m + b * n = m * n
⊢ False

tactic: obtain ⟨y, rfl⟩ : m ∣ b :=
  cop.dvd_of_dvd_mul_right
    ((Nat.dvd_add_iff_right (Nat.dvd_mul_left m (n * x))).mpr
      ((congr_arg _ h).mpr (Nat.dvd_mul_right m n)))
state_before: case intro
m n b : ℕ
cop : coprime m n
hb : b ≠ 0
x : ℕ
ha : n * x ≠ 0
h : n * x * m + b * n = m * n
⊢ False

tactic: rw [mul_comm, mul_ne_zero_iff, ← one_le_iff_ne_zero] at ha hb
state_before: case intro.intro
m n : ℕ
cop : coprime m n
x : ℕ
ha : n * x ≠ 0
y : ℕ
hb : m * y ≠ 0
h : n * x * m + m * y * n = m * n
⊢ False

tactic: refine' mul_ne_zero hb.2 ha.2 (eq_zero_of_mul_eq_self_left (ne_of_gt (add_le_add ha.1 hb.1)) _)
state_before: case intro.intro
m n : ℕ
cop : coprime m n
x : ℕ
ha : 1 ≤ x ∧ n ≠ 0
y : ℕ
hb : 1 ≤ y ∧ m ≠ 0
h : n * x * m + m * y * n = m * n
⊢ False

tactic: rw [← mul_assoc, ← h, add_mul, add_mul, mul_comm _ n, ← mul_assoc, mul_comm y]
state_before: case intro.intro
m n : ℕ
cop : coprime m n
x : ℕ
ha : 1 ≤ x ∧ n ≠ 0
y : ℕ
hb : 1 ≤ y ∧ m ≠ 0
h : n * x * m + m * y * n = m * n
⊢ (x + y) * (m * n) = m * n
Theorem: pow_div_pow_eventuallyEq_atBot
File: Mathlib/Analysis/Asymptotics/SpecificAsymptotics.lean

tactic: apply (eventually_lt_atBot (0 : 𝕜)).mono fun x hx => _
state_before: 𝕜 : Type u_1
inst✝ : LinearOrderedField 𝕜
p q : ℕ
⊢ (fun x => x ^ p / x ^ q) =ᶠ[atBot] fun x => x ^ (↑p - ↑q)

tactic: intro x hx
state_before: 𝕜 : Type u_1
inst✝ : LinearOrderedField 𝕜
p q : ℕ
⊢ ∀ (x : 𝕜), x < 0 → (fun x => x ^ p / x ^ q) x = (fun x => x ^ (↑p - ↑q)) x

tactic: simp [zpow_sub₀ hx.ne]
state_before: 𝕜 : Type u_1
inst✝ : LinearOrderedField 𝕜
p q : ℕ
x : 𝕜
hx : x < 0
⊢ (fun x => x ^ p / x ^ q) x = (fun x => x ^ (↑p - ↑q)) x
Theorem: Filter.Eventually.and_frequently
File: Mathlib/Order/Filter/Basic.lean

tactic: simpa only [and_comm] using hq.and_eventually hp
state_before: α : Type u
β : Type v
γ : Type w
δ : Type ?u.160111
ι : Sort x
p q : α → Prop
f : Filter α
hp : ∀ᶠ (x : α) in f, p x
hq : ∃ᶠ (x : α) in f, q x
⊢ ∃ᶠ (x : α) in f, p x ∧ q x
Theorem: IsROrC.inv_I
File: Mathlib/Data/IsROrC/Basic.lean

tactic: by_cases h : (I : K) = 0
state_before: K : Type u_1
E : Type ?u.6057953
inst✝ : IsROrC K
⊢ I⁻¹ = -I

tactic: simp [h]
state_before: case pos
K : Type u_1
E : Type ?u.6057953
inst✝ : IsROrC K
h : I = 0
⊢ I⁻¹ = -I

tactic: field_simp [I_mul_I_of_nonzero h]
state_before: case neg
K : Type u_1
E : Type ?u.6057953
inst✝ : IsROrC K
h : ¬I = 0
⊢ I⁻¹ = -I
Theorem: CategoryTheory.Bicategory.associator_naturality_middle
File: Mathlib/CategoryTheory/Bicategory/Basic.lean

tactic: simp
state_before: B : Type u
inst✝ : Bicategory B
a b c d e : B
f : a ⟶ b
g g' : b ⟶ c
η : g ⟶ g'
h : c ⟶ d
⊢ (f ◁ η) ▷ h ≫ (α_ f g' h).hom = (α_ f g h).hom ≫ f ◁ η ▷ h
Theorem: ball_div_one
File: Mathlib/Analysis/Normed/Group/Pointwise.lean

tactic: simp [div_eq_mul_inv, ball_mul_one]
state_before: E : Type u_1
inst✝ : SeminormedCommGroup E
ε δ : ℝ
s t : Set E
x y : E
⊢ ball 1 δ / s = thickening δ s⁻¹
Theorem: Real.exists_rat_pow_btwn_rat_aux
File: Mathlib/Analysis/SpecialFunctions/Pow/Real.lean

tactic: have hn' : 0 < (n : ℝ) := by exact_mod_cast hn.bot_lt
state_before: z x✝ y✝ : ℝ
n : ℕ
hn : n ≠ 0
x y : ℝ
h : x < y
hy : 0 < y
⊢ ∃ q, 0 < q ∧ x < ↑q ^ n ∧ ↑q ^ n < y

tactic: obtain ⟨q, hxq, hqy⟩ :=
  exists_rat_btwn (rpow_lt_rpow (le_max_left 0 x) (max_lt hy h) <| inv_pos.mpr hn')
state_before: z x✝ y✝ : ℝ
n : ℕ
hn : n ≠ 0
x y : ℝ
h : x < y
hy : 0 < y
hn' : 0 < ↑n
⊢ ∃ q, 0 < q ∧ x < ↑q ^ n ∧ ↑q ^ n < y

tactic: have := rpow_nonneg_of_nonneg (le_max_left 0 x) n⁻¹
state_before: case intro.intro
z x✝ y✝ : ℝ
n : ℕ
hn : n ≠ 0
x y : ℝ
h : x < y
hy : 0 < y
hn' : 0 < ↑n
q : ℚ
hxq : max 0 x ^ (↑n)⁻¹ < ↑q
hqy : ↑q < y ^ (↑n)⁻¹
⊢ ∃ q, 0 < q ∧ x < ↑q ^ n ∧ ↑q ^ n < y

tactic: have hq := this.trans_lt hxq
state_before: case intro.intro
z x✝ y✝ : ℝ
n : ℕ
hn : n ≠ 0
x y : ℝ
h : x < y
hy : 0 < y
hn' : 0 < ↑n
q : ℚ
hxq : max 0 x ^ (↑n)⁻¹ < ↑q
hqy : ↑q < y ^ (↑n)⁻¹
this : 0 ≤ max 0 x ^ (↑n)⁻¹
⊢ ∃ q, 0 < q ∧ x < ↑q ^ n ∧ ↑q ^ n < y

tactic: replace hxq := rpow_lt_rpow this hxq hn'
state_before: case intro.intro
z x✝ y✝ : ℝ
n : ℕ
hn : n ≠ 0
x y : ℝ
h : x < y
hy : 0 < y
hn' : 0 < ↑n
q : ℚ
hxq : max 0 x ^ (↑n)⁻¹ < ↑q
hqy : ↑q < y ^ (↑n)⁻¹
this : 0 ≤ max 0 x ^ (↑n)⁻¹
hq : 0 < ↑q
⊢ ∃ q, 0 < q ∧ x < ↑q ^ n ∧ ↑q ^ n < y

tactic: replace hqy := rpow_lt_rpow hq.le hqy hn'
state_before: case intro.intro
z x✝ y✝ : ℝ
n : ℕ
hn : n ≠ 0
x y : ℝ
h : x < y
hy : 0 < y
hn' : 0 < ↑n
q : ℚ
hqy : ↑q < y ^ (↑n)⁻¹
this : 0 ≤ max 0 x ^ (↑n)⁻¹
hq : 0 < ↑q
hxq : (max 0 x ^ (↑n)⁻¹) ^ ↑n < ↑q ^ ↑n
⊢ ∃ q, 0 < q ∧ x < ↑q ^ n ∧ ↑q ^ n < y

tactic: rw [rpow_nat_cast, rpow_nat_cast, rpow_nat_inv_pow_nat _ hn] at hxq hqy
state_before: case intro.intro
z x✝ y✝ : ℝ
n : ℕ
hn : n ≠ 0
x y : ℝ
h : x < y
hy : 0 < y
hn' : 0 < ↑n
q : ℚ
this : 0 ≤ max 0 x ^ (↑n)⁻¹
hq : 0 < ↑q
hxq : (max 0 x ^ (↑n)⁻¹) ^ ↑n < ↑q ^ ↑n
hqy : ↑q ^ ↑n < (y ^ (↑n)⁻¹) ^ ↑n
⊢ ∃ q, 0 < q ∧ x < ↑q ^ n ∧ ↑q ^ n < y

tactic: exact_mod_cast hn.bot_lt
state_before: z x✝ y✝ : ℝ
n : ℕ
hn : n ≠ 0
x y : ℝ
h : x < y
hy : 0 < y
⊢ 0 < ↑n

tactic: exact ⟨q, by exact_mod_cast hq, (le_max_right _ _).trans_lt hxq, hqy⟩
state_before: case intro.intro
z x✝ y✝ : ℝ
n : ℕ
hn : n ≠ 0
x y : ℝ
h : x < y
hy : 0 < y
hn' : 0 < ↑n
q : ℚ
this : 0 ≤ max 0 x ^ (↑n)⁻¹
hq : 0 < ↑q
hxq : max 0 x < ↑q ^ n
hqy : ↑q ^ n < y
⊢ ∃ q, 0 < q ∧ x < ↑q ^ n ∧ ↑q ^ n < y

tactic: exact_mod_cast hq
state_before: z x✝ y✝ : ℝ
n : ℕ
hn : n ≠ 0
x y : ℝ
h : x < y
hy : 0 < y
hn' : 0 < ↑n
q : ℚ
this : 0 ≤ max 0 x ^ (↑n)⁻¹
hq : 0 < ↑q
hxq : max 0 x < ↑q ^ n
hqy : ↑q ^ n < y
⊢ 0 < q

tactic: exact hy.le
state_before: z x✝ y✝ : ℝ
n : ℕ
hn : n ≠ 0
x y : ℝ
h : x < y
hy : 0 < y
hn' : 0 < ↑n
q : ℚ
this : 0 ≤ max 0 x ^ (↑n)⁻¹
hq : 0 < ↑q
hxq : max 0 x < ↑q ^ n
hqy : ↑q ^ n < (y ^ (↑n)⁻¹) ^ n
⊢ 0 ≤ y

tactic: exact le_max_left _ _
state_before: z x✝ y✝ : ℝ
n : ℕ
hn : n ≠ 0
x y : ℝ
h : x < y
hy : 0 < y
hn' : 0 < ↑n
q : ℚ
this : 0 ≤ max 0 x ^ (↑n)⁻¹
hq : 0 < ↑q
hxq : (max 0 x ^ (↑n)⁻¹) ^ n < ↑q ^ n
hqy : ↑q ^ n < (y ^ (↑n)⁻¹) ^ n
⊢ 0 ≤ max 0 x
Theorem: List.foldr_permutationsAux2
File: Mathlib/Data/List/Permutation.lean

tactic: induction' L with l L ih
state_before: α : Type u_1
β : Type ?u.20781
t : α
ts : List α
r L : List (List α)
⊢ foldr (fun y r => (permutationsAux2 t ts r y id).snd) r L =
    (List.bind L fun y => (permutationsAux2 t ts [] y id).snd) ++ r

tactic: rfl
state_before: case nil
α : Type u_1
β : Type ?u.20781
t : α
ts : List α
r : List (List α)
⊢ foldr (fun y r => (permutationsAux2 t ts r y id).snd) r [] =
    (List.bind [] fun y => (permutationsAux2 t ts [] y id).snd) ++ r

tactic: simp [ih]
state_before: case cons
α : Type u_1
β : Type ?u.20781
t : α
ts : List α
r : List (List α)
l : List α
L : List (List α)
ih :
  foldr (fun y r => (permutationsAux2 t ts r y id).snd) r L =
    (List.bind L fun y => (permutationsAux2 t ts [] y id).snd) ++ r
⊢ foldr (fun y r => (permutationsAux2 t ts r y id).snd) r (l :: L) =
    (List.bind (l :: L) fun y => (permutationsAux2 t ts [] y id).snd) ++ r

tactic: rw [← permutationsAux2_append]
state_before: case cons
α : Type u_1
β : Type ?u.20781
t : α
ts : List α
r : List (List α)
l : List α
L : List (List α)
ih :
  foldr (fun y r => (permutationsAux2 t ts r y id).snd) r L =
    (List.bind L fun y => (permutationsAux2 t ts [] y id).snd) ++ r
⊢ (permutationsAux2 t ts ((List.bind L fun y => (permutationsAux2 t ts [] y id).snd) ++ r) l id).snd =
    (permutationsAux2 t ts [] l id).snd ++ ((List.bind L fun y => (permutationsAux2 t ts [] y id).snd) ++ r)
Theorem: CategoryTheory.IsPushout.zero_left
File: Mathlib/CategoryTheory/Limits/Shapes/CommSq.lean

tactic: simp
state_before: C : Type u₁
inst✝² : Category C
Z X✝ Y P : C
f : Z ⟶ X✝
g : Z ⟶ Y
inl : X✝ ⟶ P
inr : Y ⟶ P
inst✝¹ : HasZeroObject C
inst✝ : HasZeroMorphisms C
X : C
⊢ CommSq 0 0 (𝟙 X) 0

tactic: simp
state_before: C : Type u₁
inst✝² : Category C
Z X✝ Y P : C
f : Z ⟶ X✝
g : Z ⟶ Y
inl : X✝ ⟶ P
inr : Y ⟶ P
inst✝¹ : HasZeroObject C
inst✝ : HasZeroMorphisms C
X : C
⊢ 𝟙 X ≫ ((coprodZeroIso X).symm ≪≫ (pushoutZeroZeroIso X 0).symm).hom = pushout.inl

tactic: simp
state_before: C : Type u₁
inst✝² : Category C
Z X✝ Y P : C
f : Z ⟶ X✝
g : Z ⟶ Y
inl : X✝ ⟶ P
inr : Y ⟶ P
inst✝¹ : HasZeroObject C
inst✝ : HasZeroMorphisms C
X : C
⊢ 0 ≫ ((coprodZeroIso X).symm ≪≫ (pushoutZeroZeroIso X 0).symm).hom = pushout.inr
Theorem: MeasureTheory.VectorMeasure.restrict_add
File: Mathlib/MeasureTheory/Measure/VectorMeasure.lean

tactic: by_cases hi : MeasurableSet i
state_before: α : Type u_1
β : Type ?u.487868
m inst✝⁴ : MeasurableSpace α
inst✝³ : MeasurableSpace β
M : Type u_2
inst✝² : AddCommMonoid M
inst✝¹ : TopologicalSpace M
v✝ : VectorMeasure α M
inst✝ : ContinuousAdd M
v w : VectorMeasure α M
i : Set α
⊢ restrict (v + w) i = restrict v i + restrict w i

tactic: ext j
state_before: case pos
α : Type u_1
β : Type ?u.487868
m inst✝⁴ : MeasurableSpace α
inst✝³ : MeasurableSpace β
M : Type u_2
inst✝² : AddCommMonoid M
inst✝¹ : TopologicalSpace M
v✝ : VectorMeasure α M
inst✝ : ContinuousAdd M
v w : VectorMeasure α M
i : Set α
hi : MeasurableSet i
⊢ restrict (v + w) i = restrict v i + restrict w i

tactic: intro hj
state_before: case pos.h
α : Type u_1
β : Type ?u.487868
m inst✝⁴ : MeasurableSpace α
inst✝³ : MeasurableSpace β
M : Type u_2
inst✝² : AddCommMonoid M
inst✝¹ : TopologicalSpace M
v✝ : VectorMeasure α M
inst✝ : ContinuousAdd M
v w : VectorMeasure α M
i : Set α
hi : MeasurableSet i
j : Set α
⊢ MeasurableSet j → ↑(restrict (v + w) i) j = ↑(restrict v i + restrict w i) j

tactic: simp [restrict_apply _ hi hj]
state_before: case pos.h
α : Type u_1
β : Type ?u.487868
m inst✝⁴ : MeasurableSpace α
inst✝³ : MeasurableSpace β
M : Type u_2
inst✝² : AddCommMonoid M
inst✝¹ : TopologicalSpace M
v✝ : VectorMeasure α M
inst✝ : ContinuousAdd M
v w : VectorMeasure α M
i : Set α
hi : MeasurableSet i
j : Set α
hj : MeasurableSet j
⊢ ↑(restrict (v + w) i) j = ↑(restrict v i + restrict w i) j

tactic: simp [restrict_not_measurable _ hi]
state_before: case neg
α : Type u_1
β : Type ?u.487868
m inst✝⁴ : MeasurableSpace α
inst✝³ : MeasurableSpace β
M : Type u_2
inst✝² : AddCommMonoid M
inst✝¹ : TopologicalSpace M
v✝ : VectorMeasure α M
inst✝ : ContinuousAdd M
v w : VectorMeasure α M
i : Set α
hi : ¬MeasurableSet i
⊢ restrict (v + w) i = restrict v i + restrict w i
Theorem: NeZero.nat_of_injective
File: Mathlib/Data/Nat/Cast/Basic.lean

tactic: simpa only [map_natCast, map_zero f]
state_before: α : Type ?u.60026
β : Type ?u.60029
R : Type u_1
S : Type u_3
F : Type u_2
inst✝² : NonAssocSemiring R
inst✝¹ : NonAssocSemiring S
n : ℕ
h✝ : NeZero ↑n
inst✝ : RingHomClass F R S
f : F
hf : Function.Injective ↑f
h : ↑n = 0
⊢ ↑f ↑n = ↑f 0
Theorem: List.take_left'
File: Mathlib/Data/List/Basic.lean

tactic: rw [← h]
state_before: ι : Type ?u.158941
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁✝ l₂✝ l₁ l₂ : List α
n : ℕ
h : length l₁ = n
⊢ take n (l₁ ++ l₂) = l₁

tactic: apply take_left
state_before: ι : Type ?u.158941
α : Type u
β : Type v
γ : Type w
δ : Type x
l₁✝ l₂✝ l₁ l₂ : List α
n : ℕ
h : length l₁ = n
⊢ take (length l₁) (l₁ ++ l₂) = l₁
Theorem: QuaternionAlgebra.coe_neg
File: Mathlib/Algebra/Quaternion.lean

tactic: ext <;> simp
state_before: S : Type ?u.27269
T : Type ?u.27272
R : Type u_1
inst✝ : CommRing R
c₁ c₂ r x y z : R
a b c : ℍ[R,c₁,c₂]
⊢ ↑(-x) = -↑x
Theorem: SimpleGraph.Walk.toDeleteEdges_copy
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 u' v' : V
s : Set (Sym2 V)
p : Walk G u v
hu : u = u'
hv : v = v'
h : ∀ (e : Sym2 V), e ∈ edges (Walk.copy p hu hv) → ¬e ∈ s
⊢ ∀ (e : Sym2 V), e ∈ edges p → ¬e ∈ s

tactic: exact h
state_before: V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
u' v' : V
s : Set (Sym2 V)
p : Walk G u' v'
h : ∀ (e : Sym2 V), e ∈ edges (Walk.copy p (_ : u' = u') (_ : v' = v')) → ¬e ∈ s
⊢ ∀ (e : Sym2 V), e ∈ edges p → ¬e ∈ s

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 u' v' : V
s : Set (Sym2 V)
p : Walk G u v
hu : u = u'
hv : v = v'
h : ∀ (e : Sym2 V), e ∈ edges (Walk.copy p hu hv) → ¬e ∈ s
⊢ toDeleteEdges s (Walk.copy p hu hv) h = Walk.copy (toDeleteEdges s p (_ : ∀ (e : Sym2 V), e ∈ edges p → ¬e ∈ s)) hu hv

tactic: rfl
state_before: V : Type u
V' : Type v
V'' : Type w
G : SimpleGraph V
G' : SimpleGraph V'
G'' : SimpleGraph V''
u' v' : V
s : Set (Sym2 V)
p : Walk G u' v'
h : ∀ (e : Sym2 V), e ∈ edges (Walk.copy p (_ : u' = u') (_ : v' = v')) → ¬e ∈ s
⊢ toDeleteEdges s (Walk.copy p (_ : u' = u') (_ : v' = v')) h =
    Walk.copy (toDeleteEdges s p (_ : ∀ (e : Sym2 V), e ∈ edges p → ¬e ∈ s)) (_ : u' = u') (_ : v' = v')
Theorem: Nat.add_succ_lt_add
File: Mathlib/Data/Nat/Order/Basic.lean

tactic: rw [add_assoc]
state_before: m n k l : ℕ
hab : m < n
hcd : k < l
⊢ m + k + 1 < n + l

tactic: exact add_lt_add_of_lt_of_le hab (Nat.succ_le_iff.2 hcd)
state_before: m n k l : ℕ
hab : m < n
hcd : k < l
⊢ m + (k + 1) < n + l
Theorem: Equiv.Perm.sum_cycleType
File: Mathlib/GroupTheory/Perm/Cycle/Type.lean

tactic: induction σ using cycle_induction_on with
| base_one => simp
| base_cycles σ hσ => rw [hσ.cycleType, coe_sum, List.sum_singleton]
| induction_disjoint σ τ hd _ hσ hτ => rw [hd.cycleType, sum_add, hσ, hτ, hd.card_support_mul]
state_before: α : Type u_1
inst✝¹ : Fintype α
inst✝ : DecidableEq α
σ : Perm α
⊢ sum (cycleType σ) = Finset.card (support σ)

tactic: simp
state_before: case base_one
α : Type u_1
inst✝¹ : Fintype α
inst✝ : DecidableEq α
⊢ sum (cycleType 1) = Finset.card (support 1)

tactic: rw [hσ.cycleType, coe_sum, List.sum_singleton]
state_before: case base_cycles
α : Type u_1
inst✝¹ : Fintype α
inst✝ : DecidableEq α
σ : Perm α
hσ : IsCycle σ
⊢ sum (cycleType σ) = Finset.card (support σ)

tactic: rw [hd.cycleType, sum_add, hσ, hτ, hd.card_support_mul]
state_before: case induction_disjoint
α : Type u_1
inst✝¹ : Fintype α
inst✝ : DecidableEq α
σ τ : Perm α
hd : Disjoint σ τ
a✝ : IsCycle σ
hσ : sum (cycleType σ) = Finset.card (support σ)
hτ : sum (cycleType τ) = Finset.card (support τ)
⊢ sum (cycleType (σ * τ)) = Finset.card (support (σ * τ))
Theorem: Set.Icc_union_Icc'
File: Mathlib/Data/Set/Intervals/Basic.lean

tactic: ext1 x
state_before: α : Type u_1
β : Type ?u.149086
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
h₁ : c ≤ b
h₂ : a ≤ d
⊢ Icc a b ∪ Icc c d = Icc (min a c) (max b d)

tactic: simp_rw [mem_union, mem_Icc, min_le_iff, le_max_iff]
state_before: case h
α : Type u_1
β : Type ?u.149086
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
h₁ : c ≤ b
h₂ : a ≤ d
x : α
⊢ x ∈ Icc a b ∪ Icc c d ↔ x ∈ Icc (min a c) (max b d)

tactic: by_cases hc : c ≤ x <;> by_cases hd : x ≤ d
state_before: case h
α : Type u_1
β : Type ?u.149086
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
h₁ : c ≤ b
h₂ : a ≤ d
x : α
⊢ a ≤ x ∧ x ≤ b ∨ c ≤ x ∧ x ≤ d ↔ (a ≤ x ∨ c ≤ x) ∧ (x ≤ b ∨ x ≤ d)

tactic: simp only [hc, hd, and_self, or_true]
state_before: case pos
α : Type u_1
β : Type ?u.149086
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
h₁ : c ≤ b
h₂ : a ≤ d
x : α
hc : c ≤ x
hd : x ≤ d
⊢ a ≤ x ∧ x ≤ b ∨ c ≤ x ∧ x ≤ d ↔ (a ≤ x ∨ c ≤ x) ∧ (x ≤ b ∨ x ≤ d)

tactic: have hax : a ≤ x := h₂.trans (le_of_not_ge hd)
state_before: case neg
α : Type u_1
β : Type ?u.149086
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
h₁ : c ≤ b
h₂ : a ≤ d
x : α
hc : c ≤ x
hd : ¬x ≤ d
⊢ a ≤ x ∧ x ≤ b ∨ c ≤ x ∧ x ≤ d ↔ (a ≤ x ∨ c ≤ x) ∧ (x ≤ b ∨ x ≤ d)

tactic: simp only [hax, true_and, hc, or_self]
state_before: case neg
α : Type u_1
β : Type ?u.149086
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
h₁ : c ≤ b
h₂ : a ≤ d
x : α
hc : c ≤ x
hd : ¬x ≤ d
hax : a ≤ x
⊢ a ≤ x ∧ x ≤ b ∨ c ≤ x ∧ x ≤ d ↔ (a ≤ x ∨ c ≤ x) ∧ (x ≤ b ∨ x ≤ d)

tactic: have hxb : x ≤ b := (le_of_not_ge hc).trans h₁
state_before: case pos
α : Type u_1
β : Type ?u.149086
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
h₁ : c ≤ b
h₂ : a ≤ d
x : α
hc : ¬c ≤ x
hd : x ≤ d
⊢ a ≤ x ∧ x ≤ b ∨ c ≤ x ∧ x ≤ d ↔ (a ≤ x ∨ c ≤ x) ∧ (x ≤ b ∨ x ≤ d)

tactic: simp only [hxb, and_true, hc, false_and, or_false, true_or]
state_before: case pos
α : Type u_1
β : Type ?u.149086
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
h₁ : c ≤ b
h₂ : a ≤ d
x : α
hc : ¬c ≤ x
hd : x ≤ d
hxb : x ≤ b
⊢ a ≤ x ∧ x ≤ b ∨ c ≤ x ∧ x ≤ d ↔ (a ≤ x ∨ c ≤ x) ∧ (x ≤ b ∨ x ≤ d)

tactic: simp only [hc, hd, and_self, or_false]
state_before: case neg
α : Type u_1
β : Type ?u.149086
inst✝ : LinearOrder α
a a₁ a₂ b b₁ b₂ c d : α
h₁ : c ≤ b
h₂ : a ≤ d
x : α
hc : ¬c ≤ x
hd : ¬x ≤ d
⊢ a ≤ x ∧ x ≤ b ∨ c ≤ x ∧ x ≤ d ↔ (a ≤ x ∨ c ≤ x) ∧ (x ≤ b ∨ x ≤ d)
Theorem: Function.Involutive.iterate_eq_id
File: Mathlib/Data/Nat/Parity.lean

tactic: rwa [hf.iterate_odd hn] at H
state_before: α : Type u_1
f : α → α
n : ℕ
hf : Involutive f
hne : f ≠ id
H : f^[n] = id
hn : Odd n
⊢ f = id