MPI - Parallel “Hello World”

MPI - Parallel “Hello World”

#include

#include "mpi.h"

int main(int argc, char* argv []) {

int rank ;

MPI_Init(&argc, &argv) ;

MPI_Comm_rank(MPI_COMM_WORLD, &rank) ;

printf("hello from procesor %d\n", rank) ;

MPI_Finalize() ;

}

Previous slide Next slide Back to the first slide View Graphic Version