[petsc-users] submatrix times subvector

Tabrez Ali stali at geology.wisc.edu
Tue Jan 15 12:09:46 CST 2013


Jed

The problem with MatGetSubMatrix is that iscol isn't available easily. I 
want to get all associated columns but according to the man page it is 
not possible in Fortran.

"If iscol is PETSC_NULL then all columns are obtained (not supported in 
Fortran)."

Is there a workaround?

Tabrez

On 01/14/2013 03:38 PM, Jed Brown wrote:
> On Mon, Jan 14, 2013 at 3:27 PM, Tabrez Ali <stali at geology.wisc.edu 
> <mailto:stali at geology.wisc.edu>> wrote:
>
>     Hello
>
>     I am solving a system of equations of the form:
>
>     |A C| |u1| = |f1|
>     |C'B| |u2|   |f2|
>
>     After each solve, I need to perform B*f2 before updating f. Should
>     I use MatGetSubMatrix/VecGetSubVector followed by MatMult or is
>     there something simpler.
>
>
> Yes, or let PCFIELDSPLIT do all the block solver stuff for you.


-- 
No one trusts a model except the one who wrote it; Everyone trusts an observation except the one who made it- Harlow Shapley

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20130115/e8f9b412/attachment.html>


More information about the petsc-users mailing list