docs.rs failed to build diffusionx-0.4.9
Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
Visit the last successful build:
diffusionx-0.11.2
Implemented
Random Number Generation
- Normal distribution
- Uniform distribution
- Exponential distribution
- Poisson distribution
- $\alpha$-stable distribution
Stochastic Processes Simulation
- Brownian motion
- $\alpha$-stable Lévy process
- Cauchy process
- $\alpha$-stable subordinator
- Inverse $\alpha$-stable subordinator
- Poisson process
- Fractional Brownian motion
- Continuous-time random walk
- Ornstein-Uhlenbeck process
- Langevin equation
- Generalized Langevin equation
- Subordinated Langevin equation
- Lévy walk
- Birth-death process
- Random walk
- Brownian excursion
- Brownian meander
- Gamma process
- Geometric Brownian motion
- Brownian yet non-Gaussian process
Usage
Random Number Generation
use ;
Stochastic Process Simulation
use ;
Visualization Example
use ;
Architecture and Extensibility
DiffusionX is designed with a trait-based system for high extensibility and performance:
Core Traits
ContinuousProcess: Base trait for continuous stochastic processesPointProcess: Base trait for point processesDiscreteProcess: Base trait for discrete stochastic processesMoment: Trait for statistical moments calculation, including raw and central momentsVisualize: Trait for plotting process trajectories
Extending with Custom Processes
-
Adding a New Continuous Process:
-
Implementing
ContinuousProcesstrait automatically provides- mean
mean - msd
msd - raw moment
raw_moment - central moment
central_moment - first passage time
fpt - occupation time
occupation_time - TAMSD
tamsd - visualization
plot
- mean
Example:
use ;
/// CIR
Result:
mean: 0.9957644815350275
MSD: 0.7441251895881059
FPT: 0.38
Occupation Time: 4.719999999999995
EATAMSD: 0.6085042089895467
Benchmark
Performance benchmarks comparing Rust, C++, Julia, and Python implementations are available here.
License
Licensed under either of:
- Apache License, Version 2.0, (LICENSE-APACHE or https://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or https://opensource.org/licenses/MIT)
at your option.
Contribution
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.