[petsc-users] How to get number of local nonzeros of a matrix?

Matthew Knepley knepley at gmail.com
Thu Dec 29 13:32:24 CST 2011

On Thu, Dec 29, 2011 at 1:28 PM, Junchao Zhang <junchao.zhang at gmail.com>wrote:

> Hello,
>   I create a MPIAIJ matrix.  How can I know the # of nonzeros stored
> locally?
>   Furthermore, in case it is needed, how can I get access to the Compress
> Sparse Row(CSR) data structure of the local matrix, i.e., the row pointer
> array, column index array, value array?

We do nto recommend it, but you can use


>   Thank you!
> -- Junchao Zhang

What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20111229/5838f9f0/attachment.htm>

More information about the petsc-users mailing list