On Thu, Feb 23, 2012 at 1:05 PM, Jungho Lee <span dir="ltr"><<a href="mailto:julee@mcs.anl.gov">julee@mcs.anl.gov</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
I'd like to solve a system with a block structure with PCFieldSplit:<br>
<br>
[A B;C D][x;y] = [v;w]<br>
<br>
(I wrote it this way to simplify notation but x and y are in fact<br>
interlaced, i.e., I'm solving a permuted version of the system above,<br>
where the variables are laid out as x_1 y_1 x_2 y_2 ...., so the<br>
system is fieldsplit-friendly)<br>
<br>
Applying PCFieldSplit to the equivalent system<br>
<br>
[D C;B A][y;x] = [w;v]<br>
<br>
can be done with command line options (-pc_fieldsplit_0_fields 1<br>
-pc_fieldsplit_1_fields 0), but I'm also interested in solving<br>
<br>
[C D;A B][x;y] = [v;w] (to be able to explore different<br>
preconditioning strategies), which currently doesn't seem to be<br>
supported. At first glance it seems like this can be easily solved by<br>
adding extra IS (is) and PetscInt* (fields) objects in<br>
_PC_FieldSplitLink, read in integer arrays for rows and columns (the<br>
symmetric case where the rows and columns have the same indices is<br>
already handled by -pc_fieldsplit_%d_fields), fill in the extra IS<br>
object, and allow the user to use these two different IS's in the<br>
MatGetSubMatrix calls in PCSetUp_FieldSplit. Is it really as simple as<br>
that, or am I missing something here?<br></blockquote><div><br></div><div>No, I think that should definitely be available. However, I also think FS needs a</div><div>complete rewrite. There is way to much crud in there specific to co-located</div>
<div>discretizations on structured grids which should be moved to the DA. FS should</div><div>only takes ISes, which would make the code a LOT simpler. Then the DA has all</div><div>the nice routines for easily creating ISes for it. I am putting in the code for</div>
<div>DMComplex now, and it seems clear the interface for all DMs should be the same.</div><div><br></div><div> Matt</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Thanks,<br>
Jungho</blockquote></div>-- <br>What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>-- Norbert Wiener<br>