Theorem: alternatingGroup.isConj_swap_mul_swap_of_cycleType_two
File: Mathlib/GroupTheory/SpecificGroups/Alternating.lean

tactic: have h := g.support.card_le_univ
state_before: α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
ha : g ∈ alternatingGroup (Fin 5)
h1 : g ≠ 1
h2 : ∀ (n : ℕ), n ∈ cycleType g → n = 2
⊢ IsConj (swap 0 4 * swap 1 3) g

tactic: rw [← Multiset.eq_replicate_card] at h2
state_before: α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
ha : g ∈ alternatingGroup (Fin 5)
h1 : g ≠ 1
h2 : ∀ (n : ℕ), n ∈ cycleType g → n = 2
h : Finset.card (support g) ≤ card (Fin 5)
⊢ IsConj (swap 0 4 * swap 1 3) g

tactic: rw [← sum_cycleType, h2, Multiset.sum_replicate, smul_eq_mul] at h
state_before: α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
ha : g ∈ alternatingGroup (Fin 5)
h1 : g ≠ 1
h2 : cycleType g = Multiset.replicate (↑Multiset.card (cycleType g)) 2
h : Finset.card (support g) ≤ card (Fin 5)
⊢ IsConj (swap 0 4 * swap 1 3) g

tactic: have h : Multiset.card g.cycleType ≤ 3 :=
  le_of_mul_le_mul_right (le_trans h (by simp only [card_fin]; ring_nf)) (by simp)
state_before: α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
ha : g ∈ alternatingGroup (Fin 5)
h1 : g ≠ 1
h2 : cycleType g = Multiset.replicate (↑Multiset.card (cycleType g)) 2
h : ↑Multiset.card (cycleType g) * 2 ≤ card (Fin 5)
⊢ IsConj (swap 0 4 * swap 1 3) g

tactic: rw [mem_alternatingGroup, sign_of_cycleType, h2] at ha
state_before: α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
ha : g ∈ alternatingGroup (Fin 5)
h1 : g ≠ 1
h2 : cycleType g = Multiset.replicate (↑Multiset.card (cycleType g)) 2
h✝ : ↑Multiset.card (cycleType g) * 2 ≤ card (Fin 5)
h : ↑Multiset.card (cycleType g) ≤ 3
⊢ IsConj (swap 0 4 * swap 1 3) g

tactic: norm_num at ha
state_before: α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
ha :
  (-1) ^
      (Multiset.sum (Multiset.replicate (↑Multiset.card (cycleType g)) 2) +
        ↑Multiset.card (Multiset.replicate (↑Multiset.card (cycleType g)) 2)) =
    1
h1 : g ≠ 1
h2 : cycleType g = Multiset.replicate (↑Multiset.card (cycleType g)) 2
h✝ : ↑Multiset.card (cycleType g) * 2 ≤ card (Fin 5)
h : ↑Multiset.card (cycleType g) ≤ 3
⊢ IsConj (swap 0 4 * swap 1 3) g

tactic: rw [pow_add, pow_mul, Int.units_pow_two, one_mul, Units.ext_iff, Units.val_one,
  Units.val_pow_eq_pow_val, Units.coe_neg_one, neg_one_pow_eq_one_iff_even _] at ha
state_before: α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h2 : cycleType g = Multiset.replicate (↑Multiset.card (cycleType g)) 2
h✝ : ↑Multiset.card (cycleType g) * 2 ≤ card (Fin 5)
h : ↑Multiset.card (cycleType g) ≤ 3
ha : (-1) ^ (↑Multiset.card (cycleType g) * 2 + ↑Multiset.card (cycleType g)) = 1
⊢ IsConj (swap 0 4 * swap 1 3) g

tactic: swap
state_before: α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h2 : cycleType g = Multiset.replicate (↑Multiset.card (cycleType g)) 2
h✝ : ↑Multiset.card (cycleType g) * 2 ≤ card (Fin 5)
h : ↑Multiset.card (cycleType g) ≤ 3
ha : Even (↑Multiset.card (cycleType g))
⊢ IsConj (swap 0 4 * swap 1 3) g

α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h2 : cycleType g = Multiset.replicate (↑Multiset.card (cycleType g)) 2
h✝ : ↑Multiset.card (cycleType g) * 2 ≤ card (Fin 5)
h : ↑Multiset.card (cycleType g) ≤ 3
ha : (-1) ^ ↑Multiset.card (cycleType g) = 1
⊢ -1 ≠ 1

tactic: rw [isConj_iff_cycleType_eq, h2]
state_before: α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h2 : cycleType g = Multiset.replicate (↑Multiset.card (cycleType g)) 2
h✝ : ↑Multiset.card (cycleType g) * 2 ≤ card (Fin 5)
h : ↑Multiset.card (cycleType g) ≤ 3
ha : Even (↑Multiset.card (cycleType g))
⊢ IsConj (swap 0 4 * swap 1 3) g

tactic: interval_cases h_1 : Multiset.card g.cycleType
state_before: α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h2 : cycleType g = Multiset.replicate (↑Multiset.card (cycleType g)) 2
h✝ : ↑Multiset.card (cycleType g) * 2 ≤ card (Fin 5)
h : ↑Multiset.card (cycleType g) ≤ 3
ha : Even (↑Multiset.card (cycleType g))
⊢ cycleType (swap 0 4 * swap 1 3) = Multiset.replicate (↑Multiset.card (cycleType g)) 2

tactic: simp only [card_fin]
state_before: α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
ha : g ∈ alternatingGroup (Fin 5)
h1 : g ≠ 1
h2 : cycleType g = Multiset.replicate (↑Multiset.card (cycleType g)) 2
h : ↑Multiset.card (cycleType g) * 2 ≤ card (Fin 5)
⊢ card (Fin 5) ≤ 3 * 2

tactic: ring_nf
state_before: α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
ha : g ∈ alternatingGroup (Fin 5)
h1 : g ≠ 1
h2 : cycleType g = Multiset.replicate (↑Multiset.card (cycleType g)) 2
h : ↑Multiset.card (cycleType g) * 2 ≤ card (Fin 5)
⊢ 5 ≤ 3 * 2

tactic: simp
state_before: α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
ha : g ∈ alternatingGroup (Fin 5)
h1 : g ≠ 1
h2 : cycleType g = Multiset.replicate (↑Multiset.card (cycleType g)) 2
h : ↑Multiset.card (cycleType g) * 2 ≤ card (Fin 5)
⊢ 0 < 2

tactic: decide
state_before: α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h2 : cycleType g = Multiset.replicate (↑Multiset.card (cycleType g)) 2
h✝ : ↑Multiset.card (cycleType g) * 2 ≤ card (Fin 5)
h : ↑Multiset.card (cycleType g) ≤ 3
ha : (-1) ^ ↑Multiset.card (cycleType g) = 1
⊢ -1 ≠ 1

tactic: exact (h1 (card_cycleType_eq_zero.1 h_1)).elim
state_before: case «0»
α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h_1 : ↑Multiset.card (cycleType g) = 0
h2 : cycleType g = Multiset.replicate 0 2
h✝ : 0 * 2 ≤ card (Fin 5)
h : 0 ≤ 3
ha : Even 0
⊢ cycleType (swap 0 4 * swap 1 3) = Multiset.replicate 0 2

tactic: contrapose! ha
state_before: case «1»
α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h_1 : ↑Multiset.card (cycleType g) = 1
h2 : cycleType g = Multiset.replicate 1 2
h✝ : 1 * 2 ≤ card (Fin 5)
h : 1 ≤ 3
ha : Even 1
⊢ cycleType (swap 0 4 * swap 1 3) = Multiset.replicate 1 2

tactic: simp [h_1]
state_before: case «1»
α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h_1 : ↑Multiset.card (cycleType g) = 1
h2 : cycleType g = Multiset.replicate 1 2
h✝ : 1 * 2 ≤ card (Fin 5)
h : 1 ≤ 3
ha : cycleType (swap 0 4 * swap 1 3) ≠ Multiset.replicate 1 2
⊢ ¬Even 1

tactic: have h04 : (0 : Fin 5) ≠ 4 := by decide
state_before: case «2»
α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h_1 : ↑Multiset.card (cycleType g) = 2
h2 : cycleType g = Multiset.replicate 2 2
h✝ : 2 * 2 ≤ card (Fin 5)
h : 2 ≤ 3
ha : Even 2
⊢ cycleType (swap 0 4 * swap 1 3) = Multiset.replicate 2 2

tactic: have h13 : (1 : Fin 5) ≠ 3 := by decide
state_before: case «2»
α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h_1 : ↑Multiset.card (cycleType g) = 2
h2 : cycleType g = Multiset.replicate 2 2
h✝ : 2 * 2 ≤ card (Fin 5)
h : 2 ≤ 3
ha : Even 2
h04 : 0 ≠ 4
⊢ cycleType (swap 0 4 * swap 1 3) = Multiset.replicate 2 2

tactic: rw [Disjoint.cycleType, (isCycle_swap h04).cycleType, (isCycle_swap h13).cycleType,
  card_support_swap h04, card_support_swap h13]
state_before: case «2»
α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h_1 : ↑Multiset.card (cycleType g) = 2
h2 : cycleType g = Multiset.replicate 2 2
h✝ : 2 * 2 ≤ card (Fin 5)
h : 2 ≤ 3
ha : Even 2
h04 : 0 ≠ 4
h13 : 1 ≠ 3
⊢ cycleType (swap 0 4 * swap 1 3) = Multiset.replicate 2 2

tactic: decide
state_before: α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h_1 : ↑Multiset.card (cycleType g) = 2
h2 : cycleType g = Multiset.replicate 2 2
h✝ : 2 * 2 ≤ card (Fin 5)
h : 2 ≤ 3
ha : Even 2
⊢ 0 ≠ 4

tactic: decide
state_before: α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h_1 : ↑Multiset.card (cycleType g) = 2
h2 : cycleType g = Multiset.replicate 2 2
h✝ : 2 * 2 ≤ card (Fin 5)
h : 2 ≤ 3
ha : Even 2
h04 : 0 ≠ 4
⊢ 1 ≠ 3

tactic: rfl
state_before: case «2»
α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h_1 : ↑Multiset.card (cycleType g) = 2
h2 : cycleType g = Multiset.replicate 2 2
h✝ : 2 * 2 ≤ card (Fin 5)
h : 2 ≤ 3
ha : Even 2
h04 : 0 ≠ 4
h13 : 1 ≠ 3
⊢ ↑[2] + ↑[2] = Multiset.replicate 2 2

tactic: rw [disjoint_iff_disjoint_support, support_swap h04, support_swap h13]
state_before: case «2»
α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h_1 : ↑Multiset.card (cycleType g) = 2
h2 : cycleType g = Multiset.replicate 2 2
h✝ : 2 * 2 ≤ card (Fin 5)
h : 2 ≤ 3
ha : Even 2
h04 : 0 ≠ 4
h13 : 1 ≠ 3
⊢ Perm.Disjoint (swap 0 4) (swap 1 3)

tactic: decide
state_before: case «2»
α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h_1 : ↑Multiset.card (cycleType g) = 2
h2 : cycleType g = Multiset.replicate 2 2
h✝ : 2 * 2 ≤ card (Fin 5)
h : 2 ≤ 3
ha : Even 2
h04 : 0 ≠ 4
h13 : 1 ≠ 3
⊢ _root_.Disjoint {0, 4} {1, 3}

tactic: contrapose! ha
state_before: case «3»
α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h_1 : ↑Multiset.card (cycleType g) = 3
h2 : cycleType g = Multiset.replicate 3 2
h✝ : 3 * 2 ≤ card (Fin 5)
h : 3 ≤ 3
ha : Even 3
⊢ cycleType (swap 0 4 * swap 1 3) = Multiset.replicate 3 2

tactic: simp [h_1]
state_before: case «3»
α : Type ?u.175293
inst✝¹ : Fintype α
inst✝ : DecidableEq α
g : Perm (Fin 5)
h1 : g ≠ 1
h_1 : ↑Multiset.card (cycleType g) = 3
h2 : cycleType g = Multiset.replicate 3 2
h✝ : 3 * 2 ≤ card (Fin 5)
h : 3 ≤ 3
ha : cycleType (swap 0 4 * swap 1 3) ≠ Multiset.replicate 3 2
⊢ ¬Even 3