« View all new features in
Mathematica
9
◄
previous
|
next
►
New in
Mathematica
9
›
Enhanced Core Algorithms
Compute the Logarithm of a Matrix
The matrix logarithm is effectively the inverse of the matrix exponential.
In[1]:=
X
im = ImageCrop[ Binarize[Image[Graphics[Text[Style["log", "FontSize" -> 75]]]]]]; {dx, dy} = ImageDimensions[im]; If[dx > dy, imp = ImagePad[ im, {{0, 0}, {Floor[(dx - dy)/2], Ceiling[(dx - dy)/2]}}, 1], imp = ImagePad[ im, {{Floor[(dy - dx)/2], Ceiling[(dy - dx)/2]}, {0, 0}}, 1]]; m = MatrixExp[1. - ImageData[imp]];
Out[14]=