xesn.SparseRandomMatrix.normalize#
- SparseRandomMatrix.normalize(A)#
Rescale a random matrix either through simple multiplication, or by first normalizing by the matrix’s spectral radius or induced 2 norm. Given the matrix \(A\) with eigenvalues \(\{ {\lambda}_1, {\lambda}_2, ..., {\lambda}_n\}\), and singular values \(\{ {\sigma}_1, {\sigma}_2, ..., {\sigma}_n\}\), the normalization options return the following:
normaliation=”multiply”:
\[factor * A\]normalization=”eig”:
\[\dfrac{factor}{\rho(A)} A\]where \({ \rho(A) = \max \{ | \lambda_1 | , | \lambda_2 |, ..., | \lambda_n | \} }\) is the spectral radius of \(A\).
normalization=”svd”:
\[\dfrac{factor}{\sigma(A)} A\]where \(\sigma(A) = \max \{\sigma_1, \sigma_2, ..., \sigma_n\}\) is the largest singular value, a.k.a. the induced 2-norm of \(A\).
- Parameters:
A (array_like) – random matrix
- Returns:
A (array_like) – rescaled matrix, based on class attributes