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