Communication

Communication with traditional message-passing systems (like PVM or MPI) can be characterised as follows:

Typically, the above functionality is provided by a dozen functions.

Communication in the DP Model is characterised as follows:

The above functionality is provided by two functions.

Any kind of array can be sent to one or several DP instances (including the sender) with dpsend(array,dpids). If an array should be sent under a certain tag it can be provided as third parameter: dpsend(array,dpids,tag).

With dprecv arrays can be received selective (certain senders and/or certain tags) or non-selective. For detailed informations about dprecv see the online help or the reference guide.

Beside passing complete arrays, the DP-Toolbox supports also scattering and gathering of arrays. Scattering of arrays is possible with dpscatter(array,dpids,tag,dimension).

dpscatter divides the array along the specified dimension according to the number of destinations (dimension of dpids). That also works if the number of columns divided by the number of destinations gives a reminder. Scattered arrays may be received with dprecv.

The function A = dpgather(dpids,tag,dimension) receives an array from each source specified in dpids and builds them together into one array.

To test the functionality of dpsend/dprecv as well as dpscatter/dpgather functions two test applications are provided: dp_sendtest and dp_scattertest.

Rene Fink 2006-04-24