[petsc-users] Is it possible to keep track of original elements # after a call to DMPlexDistribute ?

Matthew Knepley knepley at gmail.com
Wed Jul 21 14:07:51 CDT 2021


On Wed, Jul 21, 2021 at 2:54 PM Eric Chamberland <
Eric.Chamberland at giref.ulaval.ca> wrote:

> Hi Matthew,
>
> we did it with PetscSFCreateInverseSF !
>
> It is working well without overlap, so we can go forward with this and
> compute the overlap afterward with DMPlexDistributeOverlap.
>
> That works. I think you can also do what you want with


https://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/PetscSF/PetscSFComputeDegreeBegin.html

This is how I usually make the 2-sided information, unless I really need
the inverse SF.

  Thanks,

     Matt

> Thanks,
>
> Eric
>
>
> On 2021-07-20 10:39 p.m., Eric Chamberland wrote:
>
>
> On 2021-07-14 6:42 p.m., Matthew Knepley wrote:
>
>
> Ah, there was a confusion of intent. GlobalToNatural() is for people that
> want data transformed back into the original
> order. I thought that was what you wanted. If you just want mesh points in
> the original order, we give you the
> transformation as part of the output of DMPlexDistribute(). The
> migrationSF that is output maps the original point to
> the distributed point. You run it backwards to get the original ordering.
>
>   Thanks,
>
>      Matt
>
> Hi,
>
> that seems to work better!  However, if I understand well the migrationSF
> is giving information on the originating process where the elements have
> been migrated from.
>
> Is there a PETSc way to either:
>
> 1) send back the information to the originating process (somewhat
> "inverting" the migrationSF) ?  So I can retrieve the "partitioning array"
> (just like the "part" parameter in ParMETIS_V3_PartMeshKway) on the sender
> process.
>
> or
>
> 2) Have the pre-migrationSF: I mean I would like to extract the "where are
> the elements going to be sent?" (again like "part" parameter)
>
> If not, I can always build the communication myself...
>
> Thanks,
>
> Eric
>
>
>
>
> --
> Eric Chamberland, ing., M. Ing
> Professionnel de recherche
> GIREF/Université Laval
> (418) 656-2131 poste 41 22 42
>
>

-- 
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

https://www.cse.buffalo.edu/~knepley/ <http://www.cse.buffalo.edu/~knepley/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20210721/092ff9e2/attachment.html>


More information about the petsc-users mailing list