edu.emory.mathcs.csparsej.tdouble
Class Dcs_randperm
- java.lang.Object
-
- edu.emory.mathcs.csparsej.tdouble.Dcs_randperm
-
public class Dcs_randperm extends java.lang.ObjectRandom permutation.
-
-
Constructor Summary
Constructors Constructor and Description Dcs_randperm()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method and Description static int[]cs_randperm(int n, int seed)Returns a random permutation vector, the identity perm, or p = n-1:-1:0.
-
-
-
Method Detail
-
cs_randperm
public static int[] cs_randperm(int n, int seed)Returns a random permutation vector, the identity perm, or p = n-1:-1:0. seed = -1 means p = n-1:-1:0. seed = 0 means p = identity. otherwise p = random permutation.- Parameters:
n- length of pseed- 0: natural, -1: reverse, random p oterwise- Returns:
- p, null on error or for natural order
-
-
DMelt 3.0 © DataMelt by jWork.ORG