prodef 0.1.0

A simple Rust crate for handling probability distributions.
Documentation

ProDeF - Probability Density Functions

A simple Rust crate for handling probability distributions.

Core Traits

All probability density functions (PDFs) implement the [Density], providing common operations like:

  • Evaluation: Compute probability density (non-normalized) at a given point
  • Sampling: Generate random samples from the distribution
  • Domain queries: Checking valid input ranges

The Domain trait represents the valid input space for a PDF. A domain may be bounded, unbounded, or have a special structure.

Available domain types:

  • MDomain - Bounded multivariate domains (hypercubes)
  • UDomain - Unbounded multivariate domains
  • SDomain - Special univariate domains (for the use of uni dimensional PDFs)

Distribution Types

Multivariate Distributions

  • MultivariateDensity Combines multiple independent univariate distributions into a multivariate density. Use when dimensions are statistically independent.

  • MultiNormalDensity A full multivariate normal (Gaussian) distribution with arbitrary covariance. Use when modeling correlated multi-dimensional data.

  • ParticleDensity A non-parametric density represented by weighted particles/samples. Use for complex distributions that can't be expressed analytically or for particle filter applications.

Univariate Distributions

For one-dimensional cases, use these directly: