nLab distribution monad

Contents

Context

Measure and probability theory

Functional analysis

Type theory

natural deduction metalanguage, practical foundations

  1. type formation rule
  2. term introduction rule
  3. term elimination rule
  4. computation rule

type theory (dependent, intensional, observational type theory, homotopy type theory)

syntax object language

computational trinitarianism =
propositions as types +programs as proofs +relation type theory/category theory

logicset theory (internal logic of)category theorytype theory
propositionsetobjecttype
predicatefamily of setsdisplay morphismdependent type
proofelementgeneralized elementterm/program
cut rulecomposition of classifying morphisms / pullback of display mapssubstitution
introduction rule for implicationcounit for hom-tensor adjunctionlambda
elimination rule for implicationunit for hom-tensor adjunctionapplication
cut elimination for implicationone of the zigzag identities for hom-tensor adjunctionbeta reduction
identity elimination for implicationthe other zigzag identity for hom-tensor adjunctioneta conversion
truesingletonterminal object/(-2)-truncated objecth-level 0-type/unit type
falseempty setinitial objectempty type
proposition, truth valuesubsingletonsubterminal object/(-1)-truncated objecth-proposition, mere proposition
logical conjunctioncartesian productproductproduct type
disjunctiondisjoint union (support of)coproduct ((-1)-truncation of)sum type (bracket type of)
implicationfunction set (into subsingleton)internal hom (into subterminal object)function type (into h-proposition)
negationfunction set into empty setinternal hom into initial objectfunction type into empty type
universal quantificationindexed cartesian product (of family of subsingletons)dependent product (of family of subterminal objects)dependent product type (of family of h-propositions)
existential quantificationindexed disjoint union (support of)dependent sum ((-1)-truncation of)dependent sum type (bracket type of)
logical equivalencebijection setobject of isomorphismsequivalence type
support setsupport object/(-1)-truncationpropositional truncation/bracket type
n-image of morphism into terminal object/n-truncationn-truncation modality
equalitydiagonal function/diagonal subset/diagonal relationpath space objectidentity type/path type
completely presented setsetdiscrete object/0-truncated objecth-level 2-type/set/h-set
setset with equivalence relationinternal 0-groupoidBishop set/setoid with its pseudo-equivalence relation an actual equivalence relation
equivalence class/quotient setquotientquotient type
inductioncolimitinductive type, W-type, M-type
higher inductionhigher colimithigher inductive type
-0-truncated higher colimitquotient inductive type
coinductionlimitcoinductive type
presettype without identity types
set of truth valuessubobject classifiertype of propositions
domain of discourseuniverseobject classifiertype universe
modalityclosure operator, (idempotent) monadmodal type theory, monad (in computer science)
linear logic(symmetric, closed) monoidal categorylinear type theory/quantum computation
proof netstring diagramquantum circuit
(absence of) contraction rule(absence of) diagonalno-cloning theorem
synthetic mathematicsdomain specific embedded programming language

homotopy levels

semantics

Contents

Idea

The distribution monad is a monad on Set, whose algebras are convex spaces.

It can be thought of as the finitary prototype of a probability monad.

Definition

Finite distributions

Let XX be a set. Define DXD X as the set whose elements are functions p:X[0,1]p:X\to[0,1] such that

  • p(x)0p(x)\ne 0 for only finitely many xx, and

  • xXp(x)=1\sum_{x\in X} p(x)=1.

Note that the sum above is finite if one excludes all the zero addenda.

The elements of DXD X are called finite distributions or finitely-supported probability measures over XX.

Pushforward

Given a function f:XYf:X\to Y, one defines the pushforward Df:DXDYD f:D X\to D Y as follows. Given pDXp\in D X, then (Df)(p)DY(D f)(p)\in D Y is the function

y xf 1(y)p(x). y \;\mapsto\; \sum_{x\in f^{-1}(y)} p(x) .

(Note that, up to zero addenda, the sum above is again finite.)

Compare with the pushforward of measures.

This makes DD into an endofunctor on Set.

Monad structure

The unit map δ:XDX\delta:X\to D X maps the element xXx\in X to the function δ x:X[0,1]\delta_x:X\to[0,1] given by

δ x(y)={1 y=x; 0 yx. \delta_x(y) \;=\; \begin{cases} 1 & y=x ;\\ 0 & y\ne x . \end{cases}

Compare with the Dirac measures and valuations.

The multiplication map E:DDXDXE:D D X\to D X maps ξDDX\xi\in D D X to the function EξDXE\xi\in D X given by

Eξ(x)= pDXp(x)ξ(p). E\xi(x) \;=\; \sum_{p\in D X} p(x) \, \xi(p).

(Note that, up to zero addenda, the sum above is once again finite.)

The maps EE and δ\delta satisfy the usual monad laws. The resulting monad (D,E,δ)(D,E,\delta) is known as distribution monad, or finitary Giry monad (in analogy with the Giry monad), or convex combination monad, since the elements of DXD X can be interpreted as formal convex combinations of elements of XX.

This can be seen as a discrete, finitary analogue of a probability monad, where one replaces integrals by sums.

Properties

(…)

See also

References

Last revised on May 17, 2020 at 00:32:33. See the history of this page for a list of all contributions to it.