hi,
when i wrote the following program...
---
int main(int argc, char **argv )
{
char message2[100]="hello world";
char message3[100];
int i,rank, size, type=99,tag=66;
MPI_Status status;
MPI_Init(&argc, &argv);
MPI_Comm_size(MPI_COMM_WORLD,&size);
MPI_Comm_rank(MPI_COMM_WORLD, &rank);
if(rank!=0)
{
MPI_Send(message2, 100, MPI_CHAR,0,tag, MPI_COMM_WORLD);
}
MPI_Gather(message2, 100, MPI_CHAR,message3,100,MPI_CHAR ,0,
MPI_COMM_WORLD);
puts(message3);
MPI_Finalize();
return 0;
}
----
in output i m receiving only one " hello world" .... but i should recieve 2
" hello world" msgs from 2 nodes.... please help me in this regard.
thanx
Imran
_________________________________________________________________
Don't just search. Find. Check out the new MSN Search!
http://search.msn.com/
|