<div class="gmail_quote">On Fri, Nov 18, 2011 at 07:02, Thomas Witkowski <span dir="ltr"><<a href="mailto:thomas.witkowski@tu-dresden.de">thomas.witkowski@tu-dresden.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
In my current FETI-DP implementation, the solution of the Schur complement on the primal variables is done by an iterative solver. This works quite good, but for small and mid size 2D problems I would like to test it with direct assembling and inverting the Schur complement matrix. In my notation, the matrix is defined by<br>
<br>
S_PiPi = K_PiPi - K_PiB inv(K_BB) K_BPi<br>
<br>
"Pi" are the primal and "B" the non-primal variables. K_BB is factorized with a (local) direct solver (umpfack or mumps). But how can I create a matrix from the last expression? Is there a way to do a matrix-matrix multiplication in PETSc, where the first matrix is the (implicit defined) dense inverse of a sparse matrix, and the second matrix is a sparse matrix? Or is it required to extract the rows of K_BPi in some way and to perform than a matrix-vector multiplication with inv(K_BB)?<br>
</blockquote><div><br></div><div>You should be able to construct the sparsity pattern of the resulting matrix, therefore you can color it and get the explicit operator by MatFDColoringApply() where the "base" vector is zero and the "function" is just MatMult().</div>
<div><br></div><div>There should probably be a Mat function that does this for you given a known sparsity pattern.</div></div>