All Packages Class Hierarchy This Package Previous Next Index
Class Jampack.Rand
java.lang.Object
|
+----Jampack.Rand
- public class Rand
- extends Object
The rand suite generates random objects with elements
distributed randomly on [0,1] or normally with mean zero
and standard deviation one.
-
Rand()
-
-
nd()
- Generates a normal random double.
-
ndary(int)
- Generates a one-dimensional array of
normal random doubles.
-
ndary(int, int)
- Generates a two-dimensional array of
normal random doubles.
-
nz()
- Generates a normal random complex number, i.e., a complex
number whose real and imaginary parts are random.
-
nz1(int)
- Generates a normal random Z1.
-
nzmat(int, int)
- Generates a normal random Zmat.
-
setSeed(long)
- Sets the seed for the random number generator.
-
ud()
- Generates a random uniform double.
-
udary(int)
- Generates a one-dimensional array of
uniform random doubles.
-
udary(int, int)
- Generates a two-dimensional array of
uniform random doubles.
-
uz()
- Generates a uniform random complex number, i.e., a complex
number whose real and imaginary parts are random.
-
uz1(int)
- Generates a uniform random Z1.
-
uzmat(int, int)
- Generates a uniform random Zmat.
Rand
public Rand()
setSeed
public static void setSeed(long seed)
- Sets the seed for the random number generator.
- Parameters:
- seed - The seed
ud
public static double ud()
- Generates a random uniform double.
- Returns:
- a uniform random double
udary
public static double[] udary(int n)
- Generates a one-dimensional array of
uniform random doubles.
- Parameters:
- n - The length of the array.
- Returns:
- The array of uniform doubles.
udary
public static double[][] udary(int m,
int n)
- Generates a two-dimensional array of
uniform random doubles.
- Parameters:
- m - The number of rows in the array.
- n - The number of columns in the array.
- Returns:
- The array of uniform doubles.
uz
public static Z uz()
- Generates a uniform random complex number, i.e., a complex
number whose real and imaginary parts are random.
- Returns:
- The uniform random Z
uz1
public static Z1 uz1(int n) throws JampackException
- Generates a uniform random Z1.
- Parameters:
- n - The length of the Z1
- Returns:
- The uniform random Z1
- Throws: JampackException
- Passed from below.
uzmat
public static Zmat uzmat(int m,
int n) throws JampackException
- Generates a uniform random Zmat.
- Parameters:
- m - The number of rows in the Zmat
- n - The number of columns in the Zmat
- Returns:
- The uniform random Zmat
- Throws: JampackException
- Passed from below.
nd
public static double nd()
- Generates a normal random double.
- Returns:
- a normal random double
ndary
public static double[] ndary(int n)
- Generates a one-dimensional array of
normal random doubles.
- Parameters:
- n - The length of the array.
- Returns:
- The array of normal doubles.
ndary
public static double[][] ndary(int m,
int n)
- Generates a two-dimensional array of
normal random doubles.
- Parameters:
- m - The number of rows in the array.
- n - The number of columns in the array.
- Returns:
- The array of normal doubles.
nz
public static Z nz()
- Generates a normal random complex number, i.e., a complex
number whose real and imaginary parts are random.
- Returns:
- The normal random Z
nz1
public static Z1 nz1(int n) throws JampackException
- Generates a normal random Z1.
- Parameters:
- n - The length of the Z1
- Returns:
- The normal random Z1
- Throws: JampackException
- Passed from below.
nzmat
public static Zmat nzmat(int m,
int n) throws JampackException
- Generates a normal random Zmat.
- Parameters:
- m - The number of rows in the Zmat
- n - The number of columns in the Zmat
- Returns:
- The normal random Zmat
- Throws: JampackException
- Passed from below.
All Packages Class Hierarchy This Package Previous Next Index