Question: How to avoid domain problem when using MatrixFunction

In the LinearAlgebra packet, I use the command MatrixFunction to calculate a function with respect to a matrix J as follow:

> restart; with(LinearAlgebra);

> J := Matrix(3, 3, {(1, 1) = 2, (1, 2) = 1, (1, 3) = 0, (2, 1) = 0,
 (2, 2) = 2, (2, 3) = 1, (3, 1) = 0, (3, 2) = 0, (3, 3) = 2});

> M := MatrixFunction(J, ln(1+x), x);

Then I got the answer:

Matrix(3, 3, {(1, 1) = ln(3), (1, 2) = 1/3, (1, 3) = -1/18, (2, 1) = 0, (2, 2) = ln(3),
 (2, 3) = 1/3, (3, 1) = 0, (3, 2) = 0, (3, 3) = ln(3)})

However, it may be not correct. The eigenvalue of J is 2, which is not in the convergence domain of ln(1+x).

Please Wait...