[petsc-dev] PCFieldSplitSetFields() API change
Barry Smith
bsmith at mcs.anl.gov
Fri Mar 23 17:48:57 CDT 2012
On Mar 23, 2012, at 5:41 PM, Jed Brown wrote:
> On Fri, Mar 23, 2012 at 17:14, Barry Smith <bsmith at mcs.anl.gov> wrote:
> But you are implicitly assuming that for example the first component of input space is "somehow" tied to the first component of the output space etc. I submit this is only true if the user has chosen first component of the input space and output space "correctly" and the user may not have done this. Giving this additional freedom to the PCFieldSplit allows the person defining the components (first etc in the input and output spaces) to not be concerned with how those definitions affect the solver, since the PCFiledSplit stage can correct for dumb choices.
>
> Suppose I have a permutation matrix P, P^T P = P P^T = I. The usual point of pivoting is
>
> A^{-1} = (P^T P A)^{-1} = (P A)^{-1} P^{-T} = (P A)^{-1} P
>
> A typical reason for this is that A has 0 in the first diagonal block, but P A is nice. Now you're telling me that you want to inject the permutation into the original definition of the problem.
I'm confused. I am NOT injecting it into the original definition, I am injecting it into the PCFieldSplit in the same way that your "permutation" would inject it just into the PCFieldSplit, it is just (in my opinion) a more user friendly way of the user providing this permutation. Note that this "two fields" business is NOT going in the DM (and hence into the original definition of the problem) and would normally only be used when the DM definition was "bad" (due to zero block for example) just like your permutation would only be used when things were bad.
Barry
> So I guess the user would only give B = P A and they would define their problem as B x = (P b), never telling me about P anywhere.
>
> Okay, but what needs to be written to change P? It sounds like I would need to change the way assembly is done and also the way residuals are evaluated. That just seems more intrusive and definitely less amenable to automatically detecting the need for pivoting. I wanted to be able to experiment with different elimination orders at run-time.
More information about the petsc-dev
mailing list