fips.linalg.LinearOperator.diagonal#

LinearOperator.diagonal()[source]#

Return the main diagonal; a sparse or diagonal form reads it from its entries.

Returns:

A new 1D array of the entries A[i, i].

Return type:

ndarray