public static double[][] transpose(double[][] matrix) {
        int m = matrix.length;
        int n = matrix[0].length;

        double[][] t = new double[n][m];
        for (int i = 0; i < m; i++) {
            for (int j = 0; j < n; j++) {
                t[j][i] = matrix[i][j];
            }
        }

        return t;
    }
@Test
    public void testTranspose() {
        System.out.println("transpose");
        double[][] A = {
                {0.7220180, 0.07121225, 0.6881997},
                {-0.2648886, -0.89044952, 0.3700456},
                {-0.6391588, 0.44947578, 0.6240573}
        };
        double[][] B = {
                {0.72201800, -0.2648886, -0.6391588},
                {0.07121225, -0.8904495, 0.4494758},
                {0.68819970, 0.3700456, 0.6240573}
        };
        assertTrue(MathEx.equals(MathEx.transpose(A), B, 1E-7));
    }