Hello<div>You task seems trivial enough, just go to /examples directory in mpich2 directory, and look at cpi.c. Alternatively, lookup monte carlo pi computations with pi on the net, </div><div>changing the code for your purposes wont be hard. You need no more then half a dozen MPI api calls (bcast, reduce, ...)</div>
<div><br></div><div><br></div><div>Eugene<br><br><div class="gmail_quote">2011/2/3 farooq farooq <span dir="ltr"><<a href="mailto:farooqnmd1220@gmail.com">farooqnmd1220@gmail.com</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
hai friends<br>
<br>
i am new user now<br>
i am working on parallel programs<br>
---------i want to devide the program such that<br>
p=26 is the integer<br>
stri[30][100] is the string empty array<br>
and i want to broadcast the p value to all the processes then to<br>
execute the following code<br>
for (k=myrank+1;k<=p;k+=size)<br>
{<br>
here i am doing some manipulations on the some string string say exstr[]<br>
and store the result in the stri[k][100]<br>
}<br>
at last i want to gather the result in<br>
stri[][] sequentially from all the processes<br>
and print the result of all processes sequentially from str[][]<br>
some one please help me in writing the code<br>
expecting the reply as early as possible<br>
<font color="#888888">--<br>
--------------------farooq<br>
_______________________________________________<br>
mpich-discuss mailing list<br>
<a href="mailto:mpich-discuss@mcs.anl.gov">mpich-discuss@mcs.anl.gov</a><br>
<a href="https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss" target="_blank">https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss</a><br>
</font></blockquote></div><br></div>