Semantics of Probabilistic Programming: A Gentle Introduction
Fredrik Dahlqvist, Alexandra Soares da Silva, Dexter C. Kozen · Cambridge University Press eBooks · 2020
Reasoning about probabilistic programs is hard because it compounds the difficulty of classic program analysis with sometimes subtle questions of probability theory. Having precise mathematical models, or semantics, describing their behaviour is therefore particularly important. In this chapter, we review two probabilistic semantics. First, an operational semantics which models the local, step-by-step, behaviour of programs, then a denotational semantics describing global behaviour as an operator transforming probability distributions over memory states.