logm
logm(A)
Input: A · Output: no output
What it is
Principal matrix logarithm of a dense real square matrix, the inverse of expm: expm(logm(A)) = A. Inverse scaling and squaring on the complex Schur form (repeated triangular square roots until the matrix is within 0.25 of the identity, then the degree-7 Padé approximant in Gauss-Legendre partial-fraction form, the diagonal taken from the exact logarithms of the eigenvalues); expm(logm(A)) reproduces A to about 1e-11 even with eigenvalues from 1e-3 to 1e3. A real Mat when A has no eigenvalue on the closed negative real axis; with a negative real eigenvalue the principal logarithm is complex and a complex matrix is returned (logm([-1 0; 0 1]) has pi*j in the corner). Errors: a singular matrix (a zero eigenvalue, where no logarithm exists), a non-square, empty or non-finite matrix, a complex matrix.
Overloads
One call shape — this function is not overloaded.
| Code | Input | Output | Description |
logm(A) | A matrix or Matnot documented yet | not documented yet | Errors: a singular matrix (a zero eigenvalue, where no logarithm exists), a non-square, empty or non-finite matrix, a complex matrix. |
Examples
No documentation example calls this form yet. The Core maths chapter is where one belongs.