Mpi communications, Computer Engineering

We have to use 3 MPI communications: Plz the code in C++  
 
1.  MPI_Scatter

2.  MPI_Alltoall

3.  MPI_Gather
 
  **The length of the array will be determined by the user First we create an array in the master processors and fill it by random numbers.
  
  Then we divide the the length of the array by the number of the slave processors.
 
In each slave processor we create  to buckets(arrays).

The first one is n/p (n= length of big array, p= number of processor) and the second array is n length.

Then we use MPI_Scatter to send each part of the big array to each first bucket of slave processor.

Then we use any sort functions to sort the the buckets.

Then we divide the small buckets by number of slave processors.

After that we use MPI_Alltoall   to send all the first parts of small buckets to array 2 in processor 1 and so on for all second parts to array 2 in processor 2.

Posted Date: 2/23/2013 2:37:46 AM | Location : United States







Related Discussions:- Mpi communications, Assignment Help, Ask Question on Mpi communications, Get Answer, Expert's Help, Mpi communications Discussions

Write discussion on Mpi communications
Your posts are moderated
Related Questions
In a particular exchange during busy hour 1200 calls were offered to a group of trunks, during this time 6 calls were lost. The average call duration being 3 minutes Calculate

Q. Illustrate working of Synchronous Counters? The main drawback of ripple counter is delay in changing the value. How? To understand this let's take a case when state of rippl

In a subscriber loop that contains a series resistance of 300 ohms to protect the batteries in the exchange, a normalized telephone draws 10 mA and its standard input d.c. resistan

Add +25 to -15 by using 2's complement ? Ans. Firstly convert the numbers 25 and 15 in its 8-bit binary equivalent and determine the 2's complement of 15, after that add +25 to -

Q. What is typical storage hierarchy? A typical storage hierarchy is displayed in Figure above. Though Figure shows only block diagram however it includes storage hierarchy:

how to solve pebble merchant problem.? coding for it..!

I''m seeking a challenging professional working position in the field of Information Technology,where I’ll be given the chance to enhance & expand the skills & experience

Goals of this assignment: understanding networking and client server systems. In this assignment, you will write a simple http web server that handles conjunctive search queries (l

Explain LRU Page replacement algorithm. LRU policy: It expands to least recently use. This policy proposes that we remove a page that last usage is farthest from present time

System Software System software is a group of programs written to service another programs. Some system software (e.g., compilers editors and file management utilities) proc