α : Type u
β : Type v
inst✝² : DecidableEq α
inst✝¹ : Fintype α
f : Perm α
p : α → Prop
inst✝ : DecidablePred p
h₁ : ∀ (x : α), p x ↔ p (↑f x)
h₂ : ∀ (x : α), ↑f x ≠ x → p x
l : { l // List.prod l = subtypePerm f h₁ ∧ ∀ (g : Perm { x // p x }), g ∈ l → IsSwap g } :=
  Trunc.out (truncSwapFactors (subtypePerm f h₁))
⊢ ↑sign (subtypePerm f h₁) = ↑sign f
α : Type u
β : Type v
inst✝² : DecidableEq α
inst✝¹ : Fintype α
f : Perm α
p : α → Prop
inst✝ : DecidablePred p
h₁ : ∀ (x : α), p x ↔ p (↑f x)
h₂ : ∀ (x : α), ↑f x ≠ x → p x
⊢ ↑sign (subtypePerm f h₁) = ↑sign f
let l := (truncSwapFactors (subtypePerm f h₁)).out
α : Type u
β : Type v
inst✝² : DecidableEq α
inst✝¹ : Fintype α
f : Perm α
p : α → Prop
inst✝ : DecidablePred p
h₁ : ∀ (x : α), p x ↔ p (↑f x)
h₂ : ∀ (x : α), ↑f x ≠ x → p x
l : { l // List.prod l = subtypePerm f h₁ ∧ ∀ (g : Perm { x // p x }), g ∈ l → IsSwap g } :=
  Trunc.out (truncSwapFactors (subtypePerm f h₁))
hl' : ∀ (g' : Perm α), g' ∈ List.map ↑ofSubtype ↑l → IsSwap g'
⊢ ↑sign (subtypePerm f h₁) = ↑sign f
α : Type u
β : Type v
inst✝² : DecidableEq α
inst✝¹ : Fintype α
f : Perm α
p : α → Prop
inst✝ : DecidablePred p
h₁ : ∀ (x : α), p x ↔ p (↑f x)
h₂ : ∀ (x : α), ↑f x ≠ x → p x
l : { l // List.prod l = subtypePerm f h₁ ∧ ∀ (g : Perm { x // p x }), g ∈ l → IsSwap g } :=
  Trunc.out (truncSwapFactors (subtypePerm f h₁))
⊢ ↑sign (subtypePerm f h₁) = ↑sign f
have hl' : ∀ g' ∈ l.1.map ofSubtype, IsSwap g' := fun g' hg' =>
  let ⟨g, hg⟩ := List.mem_map.1 hg'
  hg.2 ▸ (l.2.2 _ hg.1).of_subtype_isSwap
α : Type u
β : Type v
inst✝² : DecidableEq α
inst✝¹ : Fintype α
f : Perm α
p : α → Prop
inst✝ : DecidablePred p
h₁ : ∀ (x : α), p x ↔ p (↑f x)
h₂ : ∀ (x : α), ↑f x ≠ x → p x
l : { l // List.prod l = subtypePerm f h₁ ∧ ∀ (g : Perm { x // p x }), g ∈ l → IsSwap g } :=
  Trunc.out (truncSwapFactors (subtypePerm f h₁))
hl' : ∀ (g' : Perm α), g' ∈ List.map ↑ofSubtype ↑l → IsSwap g'
hl'₂ : List.prod (List.map ↑ofSubtype ↑l) = f
⊢ ↑sign (subtypePerm f h₁) = ↑sign f
α : Type u
β : Type v
inst✝² : DecidableEq α
inst✝¹ : Fintype α
f : Perm α
p : α → Prop
inst✝ : DecidablePred p
h₁ : ∀ (x : α), p x ↔ p (↑f x)
h₂ : ∀ (x : α), ↑f x ≠ x → p x
l : { l // List.prod l = subtypePerm f h₁ ∧ ∀ (g : Perm { x // p x }), g ∈ l → IsSwap g } :=
  Trunc.out (truncSwapFactors (subtypePerm f h₁))
hl' : ∀ (g' : Perm α), g' ∈ List.map ↑ofSubtype ↑l → IsSwap g'
⊢ ↑sign (subtypePerm f h₁) = ↑sign f
have hl'₂ : (l.1.map ofSubtype).prod = f := by
  rw [l.1.prod_hom ofSubtype, l.2.1, ofSubtype_subtypePerm _ h₂]
α : Type u
β : Type v
inst✝² : DecidableEq α
inst✝¹ : Fintype α
f : Perm α
p : α → Prop
inst✝ : DecidablePred p
h₁ : ∀ (x : α), p x ↔ p (↑f x)
h₂ : ∀ (x : α), ↑f x ≠ x → p x
l : { l // List.prod l = subtypePerm f h₁ ∧ ∀ (g : Perm { x // p x }), g ∈ l → IsSwap g } :=
  Trunc.out (truncSwapFactors (subtypePerm f h₁))
hl' : ∀ (g' : Perm α), g' ∈ List.map ↑ofSubtype ↑l → IsSwap g'
hl'₂ : List.prod (List.map ↑ofSubtype ↑l) = f
⊢ ↑sign (List.prod ↑l) = ↑sign f
α : Type u
β : Type v
inst✝² : DecidableEq α
inst✝¹ : Fintype α
f : Perm α
p : α → Prop
inst✝ : DecidablePred p
h₁ : ∀ (x : α), p x ↔ p (↑f x)
h₂ : ∀ (x : α), ↑f x ≠ x → p x
l : { l // List.prod l = subtypePerm f h₁ ∧ ∀ (g : Perm { x // p x }), g ∈ l → IsSwap g } :=
  Trunc.out (truncSwapFactors (subtypePerm f h₁))
hl' : ∀ (g' : Perm α), g' ∈ List.map ↑ofSubtype ↑l → IsSwap g'
hl'₂ : List.prod (List.map ↑ofSubtype ↑l) = f
⊢ ↑sign (subtypePerm f h₁) = ↑sign f
conv =>
  congr
  rw [← l.2.1]
  skip
α : Type u
β : Type v
inst✝² : DecidableEq α
inst✝¹ : Fintype α
f : Perm α
p : α → Prop
inst✝ : DecidablePred p
h₁ : ∀ (x : α), p x ↔ p (↑f x)
h₂ : ∀ (x : α), ↑f x ≠ x → p x
l : { l // List.prod l = subtypePerm f h₁ ∧ ∀ (g : Perm { x // p x }), g ∈ l → IsSwap g } :=
  Trunc.out (truncSwapFactors (subtypePerm f h₁))
hl' : ∀ (g' : Perm α), g' ∈ List.map ↑ofSubtype ↑l → IsSwap g'
hl'₂ : List.prod (List.map ↑ofSubtype ↑l) = f
⊢ ↑sign (List.prod ↑(Trunc.out (truncSwapFactors (subtypePerm f h₁)))) =
    ↑sign (List.prod (List.map ↑ofSubtype ↑(Trunc.out (truncSwapFactors (subtypePerm f h₁)))))
α : Type u
β : Type v
inst✝² : DecidableEq α
inst✝¹ : Fintype α
f : Perm α
p : α → Prop
inst✝ : DecidablePred p
h₁ : ∀ (x : α), p x ↔ p (↑f x)
h₂ : ∀ (x : α), ↑f x ≠ x → p x
l : { l // List.prod l = subtypePerm f h₁ ∧ ∀ (g : Perm { x // p x }), g ∈ l → IsSwap g } :=
  Trunc.out (truncSwapFactors (subtypePerm f h₁))
hl' : ∀ (g' : Perm α), g' ∈ List.map ↑ofSubtype ↑l → IsSwap g'
hl'₂ : List.prod (List.map ↑ofSubtype ↑l) = f
⊢ ↑sign (List.prod ↑l) = ↑sign f
simp_rw [← hl'₂]
no goals
α : Type u
β : Type v
inst✝² : DecidableEq α
inst✝¹ : Fintype α
f : Perm α
p : α → Prop
inst✝ : DecidablePred p
h₁ : ∀ (x : α), p x ↔ p (↑f x)
h₂ : ∀ (x : α), ↑f x ≠ x → p x
l : { l // List.prod l = subtypePerm f h₁ ∧ ∀ (g : Perm { x // p x }), g ∈ l → IsSwap g } :=
  Trunc.out (truncSwapFactors (subtypePerm f h₁))
hl' : ∀ (g' : Perm α), g' ∈ List.map ↑ofSubtype ↑l → IsSwap g'
hl'₂ : List.prod (List.map ↑ofSubtype ↑l) = f
⊢ ↑sign (List.prod ↑(Trunc.out (truncSwapFactors (subtypePerm f h₁)))) =
    ↑sign (List.prod (List.map ↑ofSubtype ↑(Trunc.out (truncSwapFactors (subtypePerm f h₁)))))
rw [sign_prod_list_swap l.2.2, sign_prod_list_swap hl', List.length_map]
no goals
α : Type u
β : Type v
inst✝² : DecidableEq α
inst✝¹ : Fintype α
f : Perm α
p : α → Prop
inst✝ : DecidablePred p
h₁ : ∀ (x : α), p x ↔ p (↑f x)
h₂ : ∀ (x : α), ↑f x ≠ x → p x
l : { l // List.prod l = subtypePerm f h₁ ∧ ∀ (g : Perm { x // p x }), g ∈ l → IsSwap g } :=
  Trunc.out (truncSwapFactors (subtypePerm f h₁))
hl' : ∀ (g' : Perm α), g' ∈ List.map ↑ofSubtype ↑l → IsSwap g'
⊢ List.prod (List.map ↑ofSubtype ↑l) = f
rw [l.1.prod_hom ofSubtype, l.2.1, ofSubtype_subtypePerm _ h₂]