outer_product

pyapprox.util.outer_product(input_sets, axis=0)[source]

Construct the outer product of an arbitary number of sets.

Parameters:
input_sets

The sets to be used in the outer product

Returns:
resultnp.ndarray(np.prod(sizes))

The outer product of the sets. result.dtype will be set to the first entry of the first input_set

Examples

\[\{1,2\}\times\{3,4\}=\{1\times3, 2\times3, 1\times4, 2\times4\} = \{3, 6, 4, 8\}\]