Finite Probability Mass Functions #
FinitePMF W bundles a rational-valued mass function with non-negativity and
normalization proofs, eliminating the need to thread hNN/hNorm hypotheses
through probabilistic theorems.
Relationship to Other Distribution Types #
| Type | Number system | Normalized? | Usage |
|---|---|---|---|
FinitePMF W | ℚ | Yes (bundled) | Probabilistic answerhood, questions, Bayesian semantics |
RSAConfigData | ℚ | No | RSA unnormalized weights |
RSAConfig | ℝ | No | RSA mathematical proofs |
W → ℝ | ℝ | Hypothesized | Entropy / information theory |
FinitePMF is the canonical type for probabilistic semantics where exact
normalized distributions are needed. RSA priors are deliberately unnormalized
and should NOT use FinitePMF.
A normalized, non-negative probability distribution over a finite type, using exact rational arithmetic.
- mass : W → ℚ
Probability mass function
All masses are non-negative
Masses sum to 1
Instances For
Equations
- Core.FinitePMF.instCoeFunForallRat = { coe := fun (d : Core.FinitePMF W) => d.mass }
Coercion to bare function type, for passing to modules that take W → ℚ
(e.g., DTS's condProb, bayesFactor).
Equations
- Core.FinitePMF.instCoeForallRat = { coe := fun (d : Core.FinitePMF W) => d.mass }
Uniform distribution over a nonempty finite type.
Equations
- Core.FinitePMF.uniform = { mass := fun (x : W) => 1 / ↑(Fintype.card W), mass_nonneg := ⋯, mass_sum_one := ⋯ }
Instances For
Point mass at a single value
Equations
Instances For
Expected value of pure distribution is the value at that point