Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #3304 > unrolled thread

MPI-style message passing in pure Mathematica

Started byOleksandr Rasputinov <oleksandr_rasputinov@hmamail.com>
First post2011-06-26 10:26 +0000
Last post2011-06-26 10:26 +0000
Articles 1 — 1 participant

Back to article view | Back to comp.soft-sys.math.mathematica


Contents

  MPI-style message passing in pure Mathematica Oleksandr Rasputinov <oleksandr_rasputinov@hmamail.com> - 2011-06-26 10:26 +0000

#3304 — MPI-style message passing in pure Mathematica

FromOleksandr Rasputinov <oleksandr_rasputinov@hmamail.com>
Date2011-06-26 10:26 +0000
SubjectMPI-style message passing in pure Mathematica
Message-ID<iu71gi$19g$1@smc.vnet.net>
Dear group,

Some time ago I thought I would try implementing MPI-style message
passing between kernels using MathLink. In contrast to the Parallel`
package, which currently offers only the master/slave or map/reduce
paradigm with its quite limited expressivity, the message passing
approach can be helpful when constructing more complex parallel
algorithms. It turns out that, despite some suggestions in the
Parallel`
documentation that slave kernels are not capable of direct
communication with one another, the implementation is actually
fairly easy (though it does rely on undocumented behaviour of the
MathLink functions).

Having satisfied my curiosity about whether or not it is possible, I
have not been motivated to develop this beyond a proof-of-concept,
so it seemed like a good idea to comment on this here in case it is
of interest to others. To be useful, a receive queue would probably
need to be implemented and higher-level collective communication
functions written to wrap LinkSend and LinkReceive, although this
would not be very difficult to achieve.

Also, now that Mathematica 7 and 8 integrate the Parallel` package,
there would seem to be no remaining limitation on its using
undocumented functions, so possibly WRI may like to take this as
a suggestion for future improvements to Mathematica's parallel
computing capabilities.

A notebook containing the code (which, to be clear, I am releasing into
the public domain for anyone to do with as they wish) is available from
the following address:

https://rapidshare.com/files/1923999609/Message_passing_in_Mathematica.nb

Best,

O. R.

[toc] | [standalone]


Back to top | Article view | comp.soft-sys.math.mathematica


csiph-web