-- File: FoML/FoML/Symmetrization.lean
Theorem statement:
theorem extracted_formal_statement_22.{u} {Ω : Type u} [inst : MeasurableSpace Ω] {μ : Measure Ω}
  [inst_1 : IsProbabilityMeasure μ] {n : ℕ} (s : Fin (n + 1) → Set Ω) (hs : ∀ (i : Fin (n + 1)), MeasurableSet (s i))
  (this : (fun f x => Fin.snoc f.2 f.1 x) ⁻¹' Set.univ.pi s = s (Fin.last n) ×ˢ Set.univ.pi (s ∘ Fin.castSucc))
  (h_original_goal :
    μ (s (Fin.last n)) * ∏ i, μ ((s ∘ Fin.castSucc) i) = ∏ i, Fin.snoc (⇑μ ∘ s ∘ Fin.castSucc) (μ (s ↑n)) i) :
  (∏ i, μ ((s ∘ Fin.castSucc) i)) * μ (s (Fin.last n)) = (∏ i, (⇑μ ∘ s ∘ Fin.castSucc) i) * μ (s ↑n) := sorry

Tactic state before:
Ω : Type u
inst✝¹ : MeasurableSpace Ω
μ : Measure Ω
inst✝ : IsProbabilityMeasure μ
n : ℕ
s : Fin (n + 1) → Set Ω
hs : ∀ (i : Fin (n + 1)), MeasurableSet (s i)
this : (fun f x => Fin.snoc f.2 f.1 x) ⁻¹' Set.univ.pi s = s (Fin.last n) ×ˢ Set.univ.pi (s ∘ Fin.castSucc)
⊢ μ (s (Fin.last n)) * ∏ i, μ ((s ∘ Fin.castSucc) i) = ∏ i, Fin.snoc (⇑μ ∘ s ∘ Fin.castSucc) (μ (s ↑n)) i

Tactic: rw [mul_comm, Fin.prod_snoc]

Tactic state after:
[Ω : Type u
 inst✝¹ : MeasurableSpace Ω
 μ : Measure Ω
 inst✝ : IsProbabilityMeasure μ
 n : ℕ
 s : Fin (n + 1) → Set Ω
 hs : ∀ (i : Fin (n + 1)), MeasurableSet (s i)
 this : (fun f x => Fin.snoc f.2 f.1 x) ⁻¹' Set.univ.pi s = s (Fin.last n) ×ˢ Set.univ.pi (s ∘ Fin.castSucc)
 ⊢ (∏ i, μ ((s ∘ Fin.castSucc) i)) * μ (s (Fin.last n)) = (∏ i, (⇑μ ∘ s ∘ Fin.castSucc) i) * μ (s ↑n)]

Premises used:
mul_comm : ∀ {G : Type u_1} [inst : CommMagma G] (a b : G), a * b = b * a
Fin.prod_snoc : ∀ {β : Type u_2} [inst : CommMonoid β] {n : ℕ} (x : β) (f : Fin n → β),
  ∏ i, Fin.snoc f x i = (∏ i, f i) * x