(Multilevel) Circulant Class

class fastmat.Circulant

Bases: fastmat.Partial.Partial

This class provides a very general implementation of circulant matrices, which essentially realize a (possibly multidimensional) circular convolution.

This type of matrix is highly structured. A two-level circulant Matrix looks like:

>>> c_00 c_02 c_01   c_20 c_22 c_21   c_10 c_12 c_11
>>> c_01 c_00 c_02   c_21 c_20 c_22   c_11 c_10 c_12
>>> c_02 c_01 c_00   c_22 c_21 c_20   c_12 c_11 c_10
>>>
>>> c_10 c_12 c_11   c_00 c_02 c_01   c_20 c_22 c_21
>>> c_11 c_10 c_12   c_01 c_00 c_02   c_21 c_20 c_22
>>> c_12 c_11 c_10   c_02 c_01 c_00   c_22 c_21 c_20
>>>
>>> c_20 c_22 c_21   c_10 c_12 c_11   c_00 c_02 c_01
>>> c_21 c_20 c_22   c_11 c_10 c_12   c_01 c_00 c_02
>>> c_22 c_21 c_20   c_12 c_11 c_10   c_02 c_01 c_00

This shows that one can define an L-level Circulant matrix by a tensor of order L. By design circulant matrices are always square matrices.

__init__

Initialize Multilevel Circulant matrix instance.

Also see the special options of fastmat.Fourier, which are also supported by this matrix and the general options offered by fastmat.Matrix.__init__.

Parameters:
tenC : numpy.ndarray

The generating nd-array tensor defining the circulant matrix. The matrix data type is determined by the data type of this array.

**options : optional

Additional keyworded arguments. Supports all optional arguments supported by fastmat.Matrix and fastmat.Fourier.

tenC

Return the matrix-defining column vector of the circulant matrix