26package umontreal.ssj.hups;
28import cern.colt.list.*;
29import umontreal.ssj.util.PrintfFormat;
65 public F2wCycleBasedLFSR(
int w,
int r,
int modQ,
int step,
int nbcoeff,
int coeff[],
int nocoeff[])
80 param =
new F2wStructure(w, r, modQ, step, nbcoeff, coeff, nocoeff);
96 param.initParamLFSR();
97 normFactor = param.normFactor;
99 numBits = param.numBits;
105 return s + param.toString();
108 private void fillCyclesLFSR() {
113 boolean stateVisited[] =
new boolean[n];
116 for (i = 0; i < n; i++)
117 stateVisited[i] =
false;
120 while (startState < n) {
121 stateVisited[startState] =
true;
122 c =
new IntArrayList();
123 param.state = startState;
128 while (param.state != startState) {
129 stateVisited[param.state] =
true;
134 for (i = startState + 1; i < n; i++)
135 if (stateVisited[i] ==
false)
Similar to CycleBasedPointSet, except that the successive values in the cycles are stored as integers...
void addCycle(AbstractList c)
Adds the cycle c to the list of all cycles.
F2wCycleBasedLFSR(int w, int r, int modQ, int step, int nbcoeff, int coeff[], int nocoeff[])
Constructs a point set with points.
F2wCycleBasedLFSR(String filename, int no)
Constructs a point set after reading its parameters from file filename; the parameters are located at...
String toString()
Formats a string that contains information about the point set.
This class implements methods and fields needed by the classes.
int getLog2N()
This method returns the product .
int numPoints
Number of points.
double EpsilonHalf
To avoid 0 for nextCoordinate when random shifting, we add this to each coordinate.