[][src]Crate oars


The oars crate is a Rust library designed to faciliate the construction, verification, and usage of orthogonal arrays, as well as strong orthogonal arrays for statistical experiments and Monte Carlo simulations.

There is an OAConstructor trait which marks whether a struct has a method that can construct an orthogonal array. The structs generally take the parameters necessary for configuring the construction method.

There is also a ParOAConstructor trait which demarcates whether a struct has a method that can construct an orthogonal array utilizing parallelization. In order to use this trait, you must enable the parallel feature for the crate.

There are also general methods available to verify that a point set matches up with the orthogonal array parameters, and convert points from an orthogonal array to a point set and back. These verification utilities are also provided for strong orthogonal arrays, though this crate does not yet provide an efficient constructor for strong orthogonal arrays.

Many of the techniques used in this library were either taken from or inspired by Art Owen's currently unpublished book about Monte Carlo integration. This library was also developed through the Dartmouth Visual Computing Lab under the tutelage of Dr. Wojciech Jarosz.

Example Usage

use oars::prelude::*;
use oars::constructors::{Bose, BoseChecked};
use oars::oa::{normalize, verify};

// Configure the parameters for the Bose construction, using the checked variant so we can make
// sure that the supplied parameters are valid.
let bose = BoseChecked {
    prime_base: 3,
    dimensions: 3,

// Use the OAConstructor method to generate the orthogonal array
let oa = bose.verify()?.gen()?;

// Verify that the orthogonal array is correct according to its parameters

// Convert the orthogonal array into a point set usable for Monte Carlo, without jittering
let points = normalize(&oa, 0.0, true)?;



Implementations of different orthogonal array construction techniques.


Generic interfaces and definitions for orthogonal arrays (OAs).


Exports the necessary traits, structs, and error types to work with oars.


Generic interfaces and definitions for strong orthogonal arrays (SOAs).



The general categories of errors for OarsError


An error indicating that there was some error constructing the orthogonal array.



A generic floating point type.


A generic integer type.

Type Definitions


A generic type for anything that can return an OarsError.