Specific Constructions of Probability Mass Functions #
This file gives a number of different PMF constructions for common probability distributions.
map and seq allow pushing a PMF α along a function f : α → β (or distribution of
functions f : PMF (α → β)) to get a PMF β.
ofFinset and ofFintype simplify the construction of a PMF α from a function f : α → ℝ≥0∞,
by allowing the "sum equals 1" constraint to be in terms of Finset.sum instead of tsum.
normalize constructs a PMF α by normalizing a function f : α → ℝ≥0∞ by its sum,
and filter uses this to filter the support of a PMF and re-normalize the new distribution.
@[simp]
@[simp]
theorem
PMF.toOuterMeasure_map_apply
{α : Type u_1}
{β : Type u_2}
(f : α → β)
(p : PMF α)
(s : Set β)
:
@[simp]
theorem
PMF.toMeasure_map_apply
{α : Type u_1}
{β : Type u_2}
(f : α → β)
(p : PMF α)
(s : Set β)
{mα : MeasurableSpace α}
{mβ : MeasurableSpace β}
(hf : Measurable f)
(hs : MeasurableSet s)
:
@[simp]
theorem
PMF.toMeasure_map
{α : Type u_1}
{β : Type u_2}
(f : α → β)
{mα : MeasurableSpace α}
{mβ : MeasurableSpace β}
(p : PMF α)
(hf : Measurable f)
:
@[deprecated PMF.ofFinset_apply_of_notMem (since := "2025-05-23")]
theorem
PMF.ofFinset_apply_of_not_mem
{α : Type u_1}
{f : α → ENNReal}
{s : Finset α}
(h : ∑ a ∈ s, f a = 1)
(h' : ∀ a ∉ s, f a = 0)
{a : α}
(ha : a ∉ s)
:
Alias of PMF.ofFinset_apply_of_notMem.
@[simp]
@[simp]
theorem
PMF.toMeasure_ofFintype_apply
{α : Type u_1}
[Fintype α]
{f : α → ENNReal}
(h : ∑ a : α, f a = 1)
(s : Set α)
[MeasurableSpace α]
(hs : MeasurableSet s)
:
@[deprecated PMF.filter_apply_eq_zero_of_notMem (since := "2025-05-23")]
theorem
PMF.filter_apply_eq_zero_of_not_mem
{α : Type u_1}
{p : PMF α}
{s : Set α}
(h : ∃ a ∈ s, a ∈ p.support)
{a : α}
(ha : a ∉ s)
:
Alias of PMF.filter_apply_eq_zero_of_notMem.