SSJ
V. labo.

umontreal.iro.lecuyer.hups
Class ContainerPointSet

java.lang.Object
  extended by umontreal.iro.lecuyer.hups.PointSet
      extended by umontreal.iro.lecuyer.hups.ContainerPointSet
Direct Known Subclasses:
AntitheticPointSet, BakerTransformedPointSet, RandShiftedPointSet

public abstract class ContainerPointSet
extends PointSet

This acts as a generic base class for all container classes that contain a point set and apply some kind of transformation to the coordinates to define a new point set. One example of such transformation is the antithetic map, applied by the container class AntitheticPointSet, where each output coordinate ui, j is transformed into 1 - ui, j. Another example is RandShiftedPointSet.

The class implements a specialized type of iterator for container point sets. This type of iterator contains itself an iterator for the contained point set and uses it to access the points and coordinates internally, instead of maintaining itself indices for the current point and current coordinate.


Constructor Summary
ContainerPointSet()
           
 
Method Summary
 void addRandomShift(int d1, int d2, RandomStream stream)
          Calls addRandomShift(d1, d2, stream) of the contained point set.
 void addRandomShift(RandomStream stream)
          Calls addRandomShift(stream) of the contained point set.
 void clearRandomShift()
          Calls clearRandomShift() of the contained point set.
 double getCoordinate(int i, int j)
          .
 int getDimension()
          Returns the dimension of the contained point set.
 int getNumPoints()
          Returns the number of points of the contained point set.
 PointSet getOriginalPointSet()
          Returns the (untransformed) point set inside this container.
 PointSetIterator iterator()
          .
 void randomize(PointSetRandomization rand)
          Randomizes the contained point set using rand.
 String toString()
          .
 
Methods inherited from class umontreal.iro.lecuyer.hups.PointSet
addRandomShift, addRandomShift, formatPoints, formatPoints, formatPoints, formatPoints, formatPointsBase, formatPointsBase, formatPointsBase, formatPointsBase, formatPointsNumbered, formatPointsNumbered, getStream, randomize, randomize, randomize, randomize, setStream, unrandomize
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ContainerPointSet

public ContainerPointSet()
Method Detail

getOriginalPointSet

public PointSet getOriginalPointSet()
Returns the (untransformed) point set inside this container.

Returns:
the point set inside this container

getDimension

public int getDimension()
Returns the dimension of the contained point set.

Overrides:
getDimension in class PointSet
Returns:
the dimension of the contained point set

getNumPoints

public int getNumPoints()
Returns the number of points of the contained point set.

Overrides:
getNumPoints in class PointSet
Returns:
the number of points of the contained point set

getCoordinate

public double getCoordinate(int i,
                            int j)
Description copied from class: PointSet
. \begin{tabb}
 Returns $u_{i,j}$, the coordinate $j$\ of the point $i$.
 \richard{...
 ...xttt{getCoordinate} impl\'ementent le random shift
 quand il existe?}
 \end{tabb}
iindex of the point to look for jindex of the coordinate to look for the value of ui, j

Specified by:
getCoordinate in class PointSet

iterator

public PointSetIterator iterator()
Description copied from class: PointSet
. \begin{tabb}
 Constructs and returns a point set iterator.
 The default implemen...
 ...oordinates, but subclasses can reimplement it
 for better efficiency.
 \end{tabb}
point set iterator for the point set

Overrides:
iterator in class PointSet

randomize

public void randomize(PointSetRandomization rand)
Randomizes the contained point set using rand.

Overrides:
randomize in class PointSet
Parameters:
rand - PointSetRandomization to use

addRandomShift

public void addRandomShift(int d1,
                           int d2,
                           RandomStream stream)
Calls addRandomShift(d1, d2, stream) of the contained point set.

Overrides:
addRandomShift in class PointSet
Parameters:
d1 - lower dimension of the random shift
d2 - upper dimension of the random shift
stream - the random stream

addRandomShift

public void addRandomShift(RandomStream stream)
Calls addRandomShift(stream) of the contained point set.

Overrides:
addRandomShift in class PointSet
Parameters:
stream - the random stream

clearRandomShift

public void clearRandomShift()
Calls clearRandomShift() of the contained point set.

Overrides:
clearRandomShift in class PointSet

toString

public String toString()
Description copied from class: PointSet
. \begin{tabb}
 Formats a string that contains information about the point set.
 \end{tabb}
string representation of the point set information

Overrides:
toString in class PointSet

SSJ
V. labo.

To submit a bug or ask questions, send an e-mail to Pierre L'Ecuyer.