import org.apache.hadoop.io.*; import me.champeau.ld.*; public class MatrixMultiplicationExample { public static void main(String[] args) { DenseDoubleMatrix2D matrix1 = new DenseDoubleMatrix2D(new double[][]{{1, 2, 3}, {4, 5, 6}}); DenseDoubleMatrix2D matrix2 = new DenseDoubleMatrix2D(new double[][]{{7, 8}, {9, 10}, {11, 12}}); DenseDoubleMatrix2D result = matrix1.multiply(matrix2); System.out.println("Matrix1 * Matrix2 ="); System.out.println(result.toString()); } }


上一篇:
下一篇:
切换中文