final class Well512a extends IntBasedGenerator
This is a Scala implementation of the Well512a PRNG based on WELL512a.c.
The acronym WELL stands for Well Equidistributed Long-period Linear.
Reference: François Panneton, Pierre L'Ecuyer and Makoto Matsumoto: "Improved Long-Period Generators Based on Linear Recurrences Modulo 2", ACM Transactions on Mathematical Software, Vol. 32, No. 1, January 2006, pp 1--16.
- Alphabetic
- By Inheritance
- Well512a
- IntBasedGenerator
- Generator
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
-
new
Well512a(state: Array[Int], i0: Int)
- Attributes
- protected[spire.random]
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
chooseFromArray[A](arr: Array[A])(implicit gen: Generator): A
- Definition Classes
- Generator
-
def
chooseFromIterable[A](as: Iterable[A])(implicit gen: Generator): A
- Definition Classes
- Generator
-
def
chooseFromSeq[A](seq: Seq[A])(implicit gen: Generator): A
- Definition Classes
- Generator
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
def
copy: Generator
- Definition Classes
- Generator
- def copyInit: Well512a
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
var
extra: Boolean
- Attributes
- protected
- Definition Classes
- Generator
-
def
fillArray[A](arr: Array[A])(implicit arg0: Dist[A]): Unit
Fill an Array[A] using the given Dist[A] instance.
Fill an Array[A] using the given Dist[A] instance.
- Definition Classes
- Generator
-
def
fillBytes(arr: Array[Byte]): Unit
Fill an array with random Bytes.
Fill an array with random Bytes.
- Definition Classes
- Generator
-
def
fillGaussians(arr: Array[Double], mean: Double, stddev: Double): Unit
- Definition Classes
- Generator
-
def
fillGaussians(arr: Array[Double]): Unit
- Definition Classes
- Generator
-
def
fillInts(arr: Array[Int]): Unit
Fill an array with random Ints.
Fill an array with random Ints.
- Definition Classes
- Generator
-
def
fillLongs(arr: Array[Long]): Unit
Fill an array with random Longs.
Fill an array with random Longs.
- Definition Classes
- Generator
-
def
fillShorts(arr: Array[Short]): Unit
Fill an array with random Shorts.
Fill an array with random Shorts.
- Definition Classes
- Generator
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
def
generateArray[A](n: Int)(implicit arg0: Dist[A], arg1: ClassTag[A]): Array[A]
Generate an Array[A] using the given Dist[A] instance.
Generate an Array[A] using the given Dist[A] instance.
- Definition Classes
- Generator
-
def
generateBytes(n: Int): Array[Byte]
Generate an array of n random Bytes.
Generate an array of n random Bytes.
- Definition Classes
- Generator
-
def
generateGaussians(n: Int, mean: Double, stddev: Double): Array[Double]
- Definition Classes
- Generator
-
def
generateGaussians(n: Int): Array[Double]
- Definition Classes
- Generator
-
def
generateInts(n: Int): Array[Int]
Generate an array of n random Ints.
Generate an array of n random Ints.
- Definition Classes
- Generator
-
def
generateLongs(n: Int): Array[Long]
Generate an array of n random Longs.
Generate an array of n random Longs.
- Definition Classes
- Generator
-
def
generateShorts(n: Int): Array[Short]
Generate an array of n random Shorts.
Generate an array of n random Shorts.
- Definition Classes
- Generator
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- def getSeedBytes(): Array[Byte]
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
def
iterator[A](implicit next: Dist[A]): Iterator[A]
Generate an infinite iterator of random values using Dist[A].
Generate an infinite iterator of random values using Dist[A].
- Definition Classes
- Generator
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
next[A](implicit next: Dist[A]): A
Generate a random value using a Dist[A] type class instance.
Generate a random value using a Dist[A] type class instance.
Implicit Dist[A] instances are provided for the AnyVal types as well as UByte through ULong. More complex Dist instances can be created from these.
- Definition Classes
- Generator
-
def
nextBits(n: Int): Int
Generates a random integer using n bits of state (0 <= n <= 32).
Generates a random integer using n bits of state (0 <= n <= 32).
- Definition Classes
- Generator
-
def
nextBoolean(): Boolean
Generates a random Boolean.
Generates a random Boolean.
- Definition Classes
- Generator
-
def
nextDouble(from: Double, until: Double): Double
Generates a random double in [from, until).
Generates a random double in [from, until).
- Definition Classes
- Generator
-
def
nextDouble(n: Double): Double
Generates a random double in [0.0, n).
Generates a random double in [0.0, n).
- Definition Classes
- Generator
-
def
nextDouble(): Double
Generates a random double in [0.0, 1.0).
Generates a random double in [0.0, 1.0).
- Definition Classes
- Generator
-
def
nextFloat(from: Float, until: Float): Float
Generates a random float in [from, until).
Generates a random float in [from, until).
- Definition Classes
- Generator
-
def
nextFloat(n: Float): Float
Generates a random float in [0.0, n).
Generates a random float in [0.0, n).
- Definition Classes
- Generator
-
def
nextFloat(): Float
Generates a random float in [0.0, 1.0).
Generates a random float in [0.0, 1.0).
- Definition Classes
- Generator
-
def
nextGaussian(mean: Double, stddev: Double): Double
- Definition Classes
- Generator
-
def
nextGaussian(): Double
- Definition Classes
- Generator
-
def
nextInt(): Int
Generate an equally-distributed random Int.
-
def
nextInt(from: Int, to: Int): Int
Return an Int in [from, to].
Return an Int in [from, to].
- Definition Classes
- Generator
-
def
nextInt(n: Int): Int
Generates a random int between 0 (inclusive) and n (exclusive).
Generates a random int between 0 (inclusive) and n (exclusive).
- Definition Classes
- Generator
-
def
nextLong(): Long
Generates a random long.
Generates a random long. All 64-bit long values are equally likely.
- Definition Classes
- IntBasedGenerator → Generator
-
def
nextLong(from: Long, to: Long): Long
Return an Long in [from, to].
Return an Long in [from, to].
- Definition Classes
- Generator
-
def
nextLong(n: Long): Long
Generates a random int between 0 (inclusive) and n (exclusive).
Generates a random int between 0 (inclusive) and n (exclusive).
- Definition Classes
- Generator
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
-
def
oneOf[A](as: A*): A
- Definition Classes
- Generator
-
def
sampleFromArray[A](as: Array[A], size: Int)(implicit arg0: ClassTag[A], gen: Generator): Array[A]
- Definition Classes
- Generator
-
def
sampleFromTraversable[A](as: Traversable[A], size: Int)(implicit arg0: ClassTag[A], gen: Generator): Array[A]
- Definition Classes
- Generator
- def setSeedBytes(bytes: Array[Byte]): Unit
-
def
shuffle[A](as: Array[A])(implicit gen: Generator): Unit
- Definition Classes
- Generator
-
def
sync: SyncGenerator
- Definition Classes
- Generator
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
var
value: Double
- Attributes
- protected
- Definition Classes
- Generator
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )