/src/main/java/net/finmath/functions/LinearAlgebra.java
RealMatrix log = matrix.power( ) ;
RealMatrix log = m.copy ( ) ;
RealMatrix diag = eigenDecomposition.getD(); for(int i=0; i<diag.getRowDimension(); i++) diag.setEntry(i, i, Math.log(diag.getEntry(i, i))); return eigenDecomposition.getV().multiply(eigenDecomposition.getD()).multiply(eigenDecomposition.getVT()); } else { RealMatrix m = matrix.subtract(MatrixUtils.createRealIdentityMatrix(matrix.getRowDimension())); <extra_id_0> for(int k=2; k<15; k++) { log = log.add(m.power(k).scalarMultiply((k%2 == 0 ? -1.0 : 1.0)/k)); } return log; } }