Maybe not...
I do not remember how Java treats 2dims array (e.g. matrix or array of
array)
at first, you can try
int[][]m = new int [2][3];
and print m.length
it could be 2, 3 or 6 ...
bottom line, you might have to use one send per row, or use a datatype, or
pack and send
Cheers,
Gilles
On Thu
Thanks for the answer.
Isn't that the same thing by the 2-dim arrays?
I mean m1.length*m1.length, for example:
MPI.COMM_WORLD.send(m1, m1.length*m1.length , MPI.INT, 1, tag);
But I get this exception: ArrayIndexOutOfBoundsException.
What should I write to avoid this exception?
Best r
Ibrahim,
if you want to send the full array, then please replace
MPI.COMM_WORLD.send(m1, 1, MPI.INT, 1, tag);
with
MPI.COMM_WORLD.send(m1, m1.length, MPI.INT, 1, tag);
and do similar changes in recv
Cheers,
Gilles
On 11/5/2015 2:57 AM, Ibrahim Ikhlawi wrote:
Hello,
I want