SHARE
TWEET

Untitled

a guest Apr 23rd, 2019 67 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.         double localNorm = 0;
  2.         for (i = 1; i < mx1; i++)
  3.         {
  4.             for (j = 1; j < my1; j++)
  5.             {
  6.                 double df = fabs(newf[i][j] - f[i][j]);
  7.                 if (df > localNorm)
  8.                     localNorm = df;
  9.             }
  10.         }
  11.         double globalNorm = 0;
  12.         MPI_Allreduce(&localNorm, &globalNorm, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD);
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top