[petsc-users] How to reorder the local part of the parallel mat?

Fande Kong fd.kong at siat.ac.cn
Wed Jan 16 15:51:20 CST 2013


Thanks, Jed,

Could I directly extract a local sub matrix from the parallel matrix? The
local part should be a sequential matrix.

On Wed, Jan 16, 2013 at 2:32 PM, Jed Brown <jedbrown at mcs.anl.gov> wrote:

> 1. Partition the mesh
> 2. Create a sequential matrix representing local mesh adjacency
> 3. Use MATORDERINGRCM to get a new ordering for that sequential matrix
> 4. Broadcast the new global indices to neighbors
>
>
> On Wed, Jan 16, 2013 at 2:26 PM, Fande Kong <fd.kong at siat.ac.cn> wrote:
>
>> Barry, Thank you very much.
>>
>> What I want to do is to order the original mesh.  I have partitioned the
>> mesh. But I want to reorder the vertices. Thus I create a matrix that
>> represent the relationships of the vertices, and then I want to use the
>> ordering methods in petsc to reorder the vertices by using matgetordering.
>>
>> What should I do if I want to use the ordering methods
>> (e.g. MATORDERINGRCM ) in petsc to reorder the mesh vertices?
>>
>> On Wed, Jan 16, 2013 at 1:10 PM, Barry Smith <bsmith at mcs.anl.gov> wrote:
>>
>>>
>>> On Jan 16, 2013, at 1:53 PM, Fande Kong <fd.kong at siat.ac.cn> wrote:
>>>
>>> > Hi all,
>>> >
>>> > I create a parallel mat with type MATMPIAIJ, and use the
>>> MatGetOrdering to reorder it. But it doesn't work. Who can tell me how to
>>> do that? I just want to reorder the local part of the matrix.
>>>
>>>    We don't have code in place for this type of thing. Maybe if you
>>> explain why you would like it we could suggest alternatives.
>>>
>>>     Generally we recommend ordering the original mesh appropriately so
>>> that the resulting matrices have good orderings and don't recommend
>>> reordering the matrices directly (except for direct solvers).
>>>
>>>    Barry
>>>
>>> >
>>> > Thanks,
>>> >
>>> > --
>>> > Fande Kong
>>> > ShenZhen Institutes of Advanced Technology
>>> > Chinese Academy of Sciences
>>>
>>>
>>>
>>
>>
>> --
>> Fande Kong
>> ShenZhen Institutes of Advanced Technology
>> Chinese Academy of Sciences
>>
>
>


-- 
Fande Kong
ShenZhen Institutes of Advanced Technology
Chinese Academy of Sciences
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20130116/c945b337/attachment.html>


More information about the petsc-users mailing list