cyjax.ml.cholesky_decode#
- cyjax.ml.cholesky_decode(diag, upper)#
Construct hermitian matrix from Cholesky decomposition.
From
diagandupper, first a matrix \(M\) is initialized as\[\begin{split}M = \begin{bmatrix} \mathrm{diag}_1 & & \text{upper}_{ij}\\ & \ddots & \\ 0 & & \mathrm{diag}_n \end{bmatrix}\end{split}\]The output of this function is then \(M M^\dagger\), which is Hermitian and positive-definite. Indexing of the 1d diag array with respect to the upper triangular is done as in
np.triu_indices()(i.e. row-major).- Parameters:
diag (
Union[Array,ndarray,bool_,number]) – Real 1d-array of diagonal entries.upper (
Union[Array,ndarray,bool_,number]) – Complex 1d-array of upper diagonal entries.
- Returns:
Hermitian, positive-definite matrix constructed by the Cholesky decomposition.