Question: Consider the matrix * vector product problem ( A * * x = y ) . The following shows pseudo code for sequential version Assume
Consider the matrix vector product problem The following shows pseudo code
for sequential version
Assume the matrix is distributed using row striping and rows distributed to
each processor. Likewise, elements of the vector are distributed to each of the
processors.
When using MPI, we need to scatter A and to processors. To complete computation,
we need to perform alltoall broadcast where each processor broadcasts its elements
of to other processors. Finally, we need to perform a gather operation to collect the result
vector y elements.
a Write an outline of the MPI code to perform the above matrix vector product. You don't
have to be exact with the syntax but show what MPI features you would use.
b Assuming that you have a ring network, compute the execution time of the algorithm
that includes both communication and computation costs.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
