public static Matrix.EVD eigen(IMatrix A, int k) {
        return eigen(A, k, 1.0E-8, 10 * A.nrow());
    }
@Test
    public void testLanczos() {
        System.out.println("eigen");
        Matrix a = Matrix.of(A);
        a.uplo(UPLO.LOWER);
        Matrix.EVD result = Lanczos.eigen(a, 3);
        assertTrue(MathEx.equals(eigenValues, result.wr, 1E-7));

        assertEquals(eigenVectors.length,    result.Vr.nrow());
        assertEquals(eigenVectors[0].length, result.Vr.ncol());
        for (int i = 0; i < eigenVectors.length; i++) {
            for (int j = 0; j < eigenVectors[i].length; j++) {
                assertEquals(Math.abs(eigenVectors[i][j]), Math.abs(result.Vr.get(i, j)), 1E-7);
            }
        }
    }