<div class="gmail_quote">On Wed, Jun 6, 2012 at 4:21 PM, TAY wee-beng <span dir="ltr"><<a href="mailto:zonexo@gmail.com" target="_blank">zonexo@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<b>call PCMGSetLevels(pc,mg_lvl,MPI_COMM_WORLD,ierr)</b></blockquote><div><br></div><div>The third arguments is an array of length mg_lvl, not a single communicator. You can pass PETSC_NULL_OBJECT just like the man page says to use the default.</div>
<div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
<br>
However, I get the error:<br>
<br>
Caught signal number 11 SEGV: Segmentation Violation, probably
memory access out of range<br>
<br>
after calling <b>PCMGSetLevels</b><br>
<br>
What's the problem? Is there any examples which I can follow?<br></blockquote></div><br><div>I believe the other examples that use this routine are in C or just tests (not tutorial-style) examples.</div>