Thanks Barry and Jed. <div><br></div><div>That definitely helps. </div><div><br></div><div>Best, </div><div>Mohamad</div><div><br><br><div class="gmail_quote">On Sat, Oct 8, 2011 at 6:32 AM, Jed Brown <span dir="ltr"><<a href="mailto:jedbrown@mcs.anl.gov">jedbrown@mcs.anl.gov</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div class="gmail_quote"><div class="im">On Sat, Oct 8, 2011 at 07:27, Mohamad M. Nasr-Azadani <span dir="ltr"><<a href="mailto:mmnasr@gmail.com" target="_blank">mmnasr@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Thanks Jed. I guess the whole point I am missing is in that "squarish". <div>I, for instance, use two processors for a domain of the global size:</div><div>nx=50</div><div>ny=40</div><div>nz=4</div><div><br></div>
<div>To my surprise, the way it was decomposed was in y-direction, i.e. </div><div>processor 0: </div><div>0-49</div><div>0-19</div><div>0-3</div><div><br></div><div>processor 1:</div><div>0-49</div><div>20-39</div><div>
0-3</div>
<div><br></div><div>and not x-direction which minimizes the surface area between the two processors. </div><div>Obviously "2" is a prime number. In that case, is PETSc biased to choose any of the directions? </div>
</blockquote><div><br></div></div><div>There is an order to which directions get tried, but it will never pick a split that is "too bad". If you run on four processes, it will split in both the X and Y directions. The complete code is here.</div>
<div><br></div><div><a href="http://www.mcs.anl.gov/petsc/petsc-as/snapshots/petsc-dev/src/dm/impls/da/da3.c.html#line231" target="_blank">http://www.mcs.anl.gov/petsc/petsc-as/snapshots/petsc-dev/src/dm/impls/da/da3.c.html#line231</a></div>
<div><br></div><div>I'm a little surprised it doesn't find the "best" split in this simple case.</div></div>
</blockquote></div><br></div>