public class RanNnep
extends AbstractRandGen
RandNnep is a random number generator proposed in
"Turbo C. Advance programming" Herbert Schildt.
Borland-Osborne/McGraw-Hill (1990).
Chapter 9.
ISBN:84-7615-508-5
Constructor and Description |
---|
RanNnep()
Empty constructor
|
RanNnep(int seed)
Default constructor (used by RandGenFactory)
|
Modifier and Type | Method and Description |
---|---|
void |
configure(Configuration settings)
Configuration settings for Randnnep random generator are:
a (int, default = 12345)
b (int, default = 67890
|
boolean |
equals(java.lang.Object other)
Compares if two random generators are equal
|
int |
hashCode()
Returns a hashcode identifier of the random generator
|
double |
raw()
Return a double value in the range [0,1].
|
protected double |
rawA()
Returns a random number between 0 and 1 using "a" property
|
protected double |
rawB()
Returns a random number between 0 and 1 using "b" property
|
java.lang.String |
toString()
Returns a String representation of the random generator
|
public RanNnep()
Empty constructor
public RanNnep(int seed)
Default constructor (used by RandGenFactory)
seed
- Value used to set-up this random generatorpublic final double raw()
Return a double value in the range [0,1]. This method will be defined to make a working IRandGen.
public void configure(Configuration settings)
Configuration settings for Randnnep random generator are:
a (int, default = 12345)
b (int, default = 67890
settings
- Configuration object to read the properties ofpublic java.lang.String toString()
Returns a String representation of the random generator
public int hashCode()
Returns a hashcode identifier of the random generator
public boolean equals(java.lang.Object other)
Compares if two random generators are equal
other
- object to compare with.protected double rawA()
Returns a random number between 0 and 1 using "a" property
protected double rawB()
Returns a random number between 0 and 1 using "b" property