[petsc-users] Sparse matrix partitioning in PETSc
Junchao Zhang
junchao.zhang at gmail.com
Sat Jan 14 12:32:19 CST 2012
My matrices are from Florida matrix collection. I want to use them to test
MatMult()
Now I know I have to compute the partitioning myself.
Thanks.
On Sat, Jan 14, 2012 at 12:10 PM, Shri <abhyshr at mcs.anl.gov> wrote:
> Does your matrix come from an unstructured grid?
> If so, then you'll need to use a partitioning package such as permits.
> Read section 3.5 of the manual
> http://www.mcs.anl.gov/petsc/petsc-current/docs/manual.pdf
> and also see the example
>
> http://www.mcs.anl.gov/petsc/petsc-current/src/mat/examples/tutorials/ex15.c.html
>
>
>
> ------------------------------
>
> I want to load a sparse matrix from a file (in PETSc binary format). The
> matrix will be in MPIAIJ format.
> I want it is a balanced load: each processor will have nearly equal number
> of nonzeros.
> I don't come up with a sequence of PETSc calls to do that.
>
> On Sat, Jan 14, 2012 at 11:41 AM, Jed Brown <jedbrown at mcs.anl.gov> wrote:
>
>> On Sat, Jan 14, 2012 at 12:38, Junchao Zhang <junchao.zhang at gmail.com>wrote:
>>
>>> Does PETSc provide convenient functions to compute this layout( i.e.,#
>>> rows on each processor), or I have to do it myself?
>>> I browsed PETSc document and did not find them.
>>>
>>
>> MatSetSizes() lets you specify local and/or global sizes. If you specify
>> both, it checks that they are compatible. The implementation uses
>>
>>
>> http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscSplitOwnership.html
>>
>>
>> If these are not suitable for your purposes, can you be more specific
>> about what you would like to do?
>>
>
>
>
> --
> Junchao Zhang
>
>
>
--
Junchao Zhang
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20120114/21655125/attachment.htm>
More information about the petsc-users
mailing list