[petsc-users] Global matrix from global sub-matrices

Xujun Zhao xzhao99 at gmail.com
Tue May 5 15:40:07 CDT 2015


Hi Bikash,

I think you can use nested matrix. See MatCreateNest and the example
src/snes/examples/tutorials/ex70.c.html
<http://www.mcs.anl.gov/petsc/petsc-current/src/snes/examples/tutorials/ex70.c.html>

Xujun

On Tue, May 5, 2015 at 3:34 PM, Bikash Kanungo <bikash at umich.edu> wrote:

> Hi,
>
> I have four global matrices: A (mxm), B (mxn), C (nxm) and D (nxn). All of
> these are of type MATMPIAIJ (sparse parallel matrix) created using number
> of global rows and columns. I want to construct an (m+n)x(m+n) global
> matrix called M which would have A, B, C and D as its sub-matrices in
> clockwise fashion starting from A at the upper-left. What can be the best
> way to construct M from A, B, C and D sub-matrices?
>
> Thanks,
> Bikash
>
> --
> Bikash S. Kanungo
> PhD Student
> Computational Materials Physics Group
> Mechanical Engineering
> University of Michigan
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20150505/ed42d1b0/attachment.html>


More information about the petsc-users mailing list