English
There is a natural equivalence between the product of a sum and a type and the sum of products: (α ⊕ β) × γ ≃ (α × γ) ⊕ (β × γ). The forward map sends ((inl a), c) to inl (a, c) and ((inr b), c) to inr (b, c); the inverse sends inl (a, c) to ((inl a), c) and inr (b, c) to ((inr b), c).
Русский
Существует естественная эквивалентность между произведением суммы и типа и суммой произведений: (α ⊕ β) × γ ≃ (α × γ) ⊕ (β × γ). Вперёдое отображение отправляет ((inl a), c) в inl (a, c) и ((inr b), c) в inr (b, c); обратное отправляет inl (a, c) ↦ ((inl a), c) и inr (b, c) ↦ ((inr b), c).
LaTeX
$$$(\\alpha \\oplus \\beta) \\times \\gamma \\cong (\\alpha \\times \\gamma) \\oplus (\\beta \\times \\gamma).$$$
Lean4
/-- Type product is right distributive with respect to type sum up to an equivalence. -/
def sumProdDistrib (α β γ) : (α ⊕ β) × γ ≃ α × γ ⊕ β × γ :=
⟨fun p => p.1.map (fun x => (x, p.2)) fun x => (x, p.2), fun s => s.elim (Prod.map inl id) (Prod.map inr id), by
rintro ⟨_ | _, _⟩ <;> rfl, by rintro (⟨_, _⟩ | ⟨_, _⟩) <;> rfl⟩