Struct random::XorshiftPlus [] [src]

pub struct XorshiftPlus {
    // some fields omitted
}

The Xorshift+ algorithm.

References

  1. Sebastiano Vigna, “Further Scramblings of Marsaglia’s Xorshift Generators,” CoRR, 2014.

  2. https://en.wikipedia.org/wiki/Xorshift

Methods

impl XorshiftPlus
[src]

fn new(seed: [u64; 2]) -> XorshiftPlus

Create an instance of the algorithm.

Trait Implementations

impl Source for XorshiftPlus
[src]

fn read(&mut self) -> u64

Return the next raw chunk.

fn take<T: Quantity>(&mut self) -> T where Self: Sized

Return the next quantity.

fn iter<'l, T: Quantity>(&'l mut self) -> Sequence<'l, Self, T> where Self: Sized

Return a sequence of quantities.