I have a challenging mpi_allgatherv to do because
1. The Fortran array is 2D.
2. Every node has a "2D subarray"
rather than a continugous section.
Here is a diagram of 2D array.
The numbers in the subarray denote
the *node* assigned to that subarray.....
----------------------------------------
| | | | |
| 0 | 4 | 8 | 12 |
| | | | |
| | | | |
----------------------------------------
| | | | |
| 1 | 5 | 9 | 13 |
| | | | |
----------------------------------------
| 2 | 6 | 10 | 14 |
| | | | |
----------------------------------------
| 3 | 7 | 11 | 15 |
| | | | |
----------------------------------------
============================================================
Node# SubArray Width SubArray Height
============================================================
0 6 4
1 6 3
2 6 2
3 6 2
4 7 4
5 7 3
6 7 2
7 7 2
8 10 4
9 10 3
10 10 2
11 10 2
12 12 4
13 12 3
14 12 2
15 12 2
============================================================
How get all of these "correctly calculated subarrays" from each node
and make a copy of a "completely correct main array"
for all nodes??
(in fortran COLUMNS are continugous right?)
The closest example I found was Example 3.8
in "MPI: The Complete Reference" (the checkerboard example)
here:
http://www.netlib.org/utk/papers/mpi-book/node76.html#SECTION00433000000000000000
The version was not exactly the same but mpi_vector and mpi_hvector look
promising.
I need help on this one. Sorry.
Chris
--
_______________________________________
Christian Seberino, Ph.D.
SPAWAR Systems Center San Diego
Code 2872
49258 Mills Street, Room 158
San Diego, CA 92152-5385
U.S.A.
Phone: (619) 553-9973
Fax : (619) 553-6521
Email: seberino_at_[hidden]
_______________________________________
|