[petsc-users] Problem when getting matrix values owned by other processor

Hong hzhang at mcs.anl.gov
Wed Apr 13 10:36:32 CDT 2016


Yaoyu :
MatGetSubMatrices() returns sequential matrices.
IS must be sequential, created with PETSC_COMM_SELF.
See petsc/src/mat/examples/tests/ex42.c

Check your submatrices.

Hong

Hi everyone,
>
> I am trying to get values owned by other processors of a parallel matrix.
>
> I tried to create a sub-matrix by using MatGetSubMatrices(), and then
> MatGetRow() on the sub-matrix. But MatGetRow() give me the following
> error message:
>
> ===== Error message begins =====
>
> No support for this operation for this object type
> only local rows
>
> ===== Error message ends =====
>
> The parallel matrix is a parallel dense matrix. The ISs for
> MatGetSubMatrices() are created using ISCreateGeneral() and
> PETSC_COMM_WORLD. The row IS is sorted by ISSort().
>
> What did I mistake while using the above functions? Is there a better
> way to get access to matrix values owned by other processor?
>
> Thanks!
>
> HU Yaoyu
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20160413/6be45909/attachment-0001.html>


More information about the petsc-users mailing list