This Is the Moment for Probabilistic Loops

Marcel Moosbrugger, Miroslav Stankovič, Ezio Bartocci, Laura Kovács
4/14/2022
cs.PL

Official code: probing-lab/polar (22 stars, Python, MIT, last commit 2026-09-16).

Abstract

We present a novel static analysis technique to derive higher moments for program variables for a large class of probabilistic loops with potentially uncountable state spaces. Our approach is fully automatic, meaning it does not rely on externally provided invariants or templates.

Show full abstract

We employ algebraic techniques based on linear recurrences and introduce program transformations to simplify probabilistic programs while preserving their statistical properties. We develop power reduction techniques to further simplify the polynomial arithmetic of probabilistic programs and define the theory of moment-computable probabilistic loops for which higher moments can precisely be computed. Our work has applications towards recovering probability distributions of random variables and computing tail probabilities. The empirical evaluation of our results demonstrates the applicability of our work on many challenging examples.

View on arXivView PDF

Code Implementations(1)

probing-lab/polarOfficial100%
MIT
2210PythonApr 2, 20212 months agoMIT

Similar Papers

Cite this paper

@article{moosbrugger2022this,
  title  = {This Is the Moment for Probabilistic Loops},
  author = {Marcel Moosbrugger and Miroslav Stankovič and Ezio Bartocci and Laura Kovács},
  year   = {2022},
  eprint = {2204.07185},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2204.07185}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2204.07185.svg)](https://codeofpaper.com/paper/2204.07185)

Discussion