section3

section3 - January 21, 2011 Administrivia Expectations and...

Info iconThis preview shows pages 1–8. Sign up to view the full content.

View Full Document Right Arrow Icon
January 21, 2011
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Administrivia Expectations and Confidence Homework #1 Homework #2 Moving forward Read the materials provided. If you need help come work with me!
Background image of page 2
Hw1 MPI Communication void powerMethod(int dims[2], double** splitA, double* x, int my_rank, int iters) { int i; double r[dims[0]]; for (i = 0; i < iters; i++) { if (my_rank == 0) norm(x, dims[1]); MPI_Bcast(x, dims[1], MPI_DOUBLE, ROOT, MPI_COMM_WORLD); matVec(dims, splitA, x, r); MPI_Gather(r, dims[0], MPI_DOUBLE, x, dims[0], MPI_DOUBLE, ROOT, MPI_COMM_WORLD); } }
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Planet MGR 1. Send my planets 1. Rotate others
Background image of page 4
Planet MGR ! ! 3. When Cycle is complete update!
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Derived Data Types We can leverage the typedef struct in C to package data. MPI allows you to construct an MPI datatype this way. Through this discussion, think about what you would ideally send in a message in Hw3.
Background image of page 6
What do we need? Part 1/4 First define the structure: typedef struct { double a; double b; int n; } MY_TYPE;
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 8
This is the end of the preview. Sign up to access the rest of the document.

This document was uploaded on 02/22/2011.

Page1 / 12

section3 - January 21, 2011 Administrivia Expectations and...

This preview shows document pages 1 - 8. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online