Open MPI logo

Open MPI User's Mailing List Archives

  |   Home   |   Support   |   FAQ   |  

This web mail archive is frozen.

This page is part of a frozen web archive of this mailing list.

You can still navigate around this archive, but know that no new mails have been added to it since July of 2016.

Click here to be taken to the new web archives of this list; it includes all the mails that are in this frozen archive plus all new mails that have been sent to the list since it was migrated to the new archives.

Subject: [OMPI users] Communication between objects on different nodes
From: Alexandru Blidaru (alexsb92_at_[hidden])
Date: 2010-07-23 11:48:10

Hey guys,

I need to write an implementation of a 4D array with a variable 4th
dimension based on where in 3D you are. So it's basically like a normal
rectangular prism, except for each unit it might have a variable number of
values. The program is also supposed to communicate by sending ghost nodes
between each slice, in order for the actual data-modifying code to work. The
data-modifying code is to be added by others depending on what they need to
do with this 4d array.

 So what I am really asking is how does MPI work when you have different
objects on different computers and you try sending stuff between the

Just some explanations for my code, which is attached, in case you can give
some code-specific tips:

   - Nx2, Nz2, Ny2 are the lengths of the big prism
   - DOFArr holds how many values there will be for each space in 3D, by
   transforming the 3D coordinates into 1D this way: index of
   - So the way i was thinking of doing is for the master to get the big
   array, and split into relatively equal parts and send each part to a node.
   The node would then do whatever it had to do, send ghost nodes to its
   neighbors, maybe do whatever it had to do again and in the end it would send
   everything back to the master node, which would take the pieces of array and
   put them together.

I am also a bit confused with when do you have to call MPI_Finaliza(). I
mean, for it to run, the program required me to put it into the constructor,
and if I call print() at the and of the constructor, it would tell me this:

job aborted:

rank: node: exit code[: error message]

0: C7June2010: 123

1: C7June2010: -1073740777: process 1 exited without calling finalize

2: C7June2010: -1073740777: process 2 exited without calling finalize

If i would place it after Finalize() nothing would show when i run the exe.

I just finished grade 12, and got a summer job at a research lab, and this
is my project. Thanks a lot for your help.


  • application/octet-stream attachment: main.cpp