for (int i = 0; i < n_elem; i++) { MPI_Bcast((int **)&(connectivity[i][0]), 4, MPI_INT, 0, MPI_COMM_WORLD); } for (int i = 0; i < n_node; i++) { MPI_Bcast((double **)&(coordinate[i][0]), 4, MPI_DOUBLE, 0, MPI_COMM_WORLD); } MPI_Barrier(MPI_COMM_WORLD); printf("process %d prainting connectivity:\n", myrank); for (int i = 0; i < n_node; i++) { for (int j = 0; j < col; j++) printf("%d \t", connectivity[i][j], myrank); printf("\n"); } printf("process %d prainting coordinate:\n", myrank); for (int i = 0; i < n_node; i++) { for (int j = 0; j < col; j++) printf("%g \t", coordinate[i][j], myrank); printf("\n"); } MPI_Barrier(MPI_COMM_WORLD);
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)