gftool.matrix.UDecomposition.reconstruct

UDecomposition.reconstruct(eig=None, kind='full')

Get matrix back from Decomposition.

If the reciprocal of self.eig was taken, this corresponds to the inverse of the original matrix.

Parameters
eig(…, N) np.ndarray, optional

Alternative value used for self.eig. This argument can be used instead of modifying self.eig.

kind{‘diag’, ‘full’} or str

Defines how to reconstruct the matrix. If kind is ‘diag’, only the diagonal elements are computed, if it is ‘full’ the complete matrix is returned. Alternatively a str used for subscript of numpy.einsum can be given.

Returns
reconstruct(…, N, N) or (…, N) np.ndarray

The reconstructed matrix. If a subscript string is given as kind, the shape of the output might differ.