#variables #random #moment #uniform #calculate #exponential #distributions

tri_poly_moment

Calculate moments of random variables. The distributions of the random variables are normal, uniform, and exponential.

2 releases

0.1.1 Sep 3, 2023
0.1.0 Sep 3, 2023

#1153 in Algorithms

Download history 9/week @ 2024-02-24 1/week @ 2024-03-02 30/week @ 2024-03-30 4/week @ 2024-04-06 69/week @ 2024-04-13

103 downloads per month

MIT license

12KB
220 lines

GitHub crate

Calculate mixed-trigonometric-polynomial moment of random variables

reference method: Moment-Based Exact Uncertainty Propagation Through Nonlinear Stochastic Autonomous Systems

The distributions of the random variables are normal, uniform, and exponential.

[dependencies]
tri_poly_moment = "0.1.0"

Example

if calculate moment of Gaussian distribusions

use tri_poly_moment::Gaussian;
let arg = Gaussian::new(-2.1, 0.4 * 0.4);
arg.x(); //if calc E[x], arg.x() = -2.1

lib.rs:

GitHub crate

Calculate mixed-trigonometric-polynomial moment of random variables

reference method: Moment-Based Exact Uncertainty Propagation Through Nonlinear Stochastic Autonomous Systems

The distributions of the random variables are normal, uniform, and exponential.

[dependencies]
tri_poly_moment = "0.1.1"

Example

if calculate moment of Gaussian distribusions

use tri_poly_moment::Gaussian;
let arg = Gaussian::new(-2.1, 0.4 * 0.4);
arg.x(); //if calc E[x], arg.x() = -2.1

No runtime deps