Class CombinationGenerator

java.lang.Object
edu.cmu.tetrad.util.CombinationGenerator

public final class CombinationGenerator extends Object
Generates (nonrecursively) all of the combinations of objects, where the number of objects in each dimension is specified. The sequence of choices is obtained by repeatedly calling the next() method. When the sequence is finished, null is returned.

A valid combination for the sequence of combinations for a choose b generated by this class is an array x[] of b integers i, 0 <= i < a, such that x[j] < x[j + 1] for each j from 0 to b - 1.

Version:
$Id: $Id
Author:
josephramsey