cartesian_product will be equivalent for some problems.
But it works on sets, so you would have to convert
from sets to lists, if you want lists. The
sets will be put in a canonical order and the same
element cannot occur more than once within a set,
which may not be what you want (and is different from
Mma Tuples)
FWIW
On Tuesday 18 May 2010 16:17:10 Mario Rodriguez wrote:
> El mar, 18-05-2010 a las 15:33 +0200, pslomski escribi?:
> > In Mathematica there is a Tuples function:
> > "Tuples[list, n] - generates a list of all possible n-tuples of elements from list."
> > e.g. all possible 2-tuples of 0 and 1:
> > In[1]:= Tuples[{0, 1}, 2]
> > Out[1]= {{0,0}, {0,1}, {1, 0}, {1,1}}
>
> ? cartesian_product