[petsc-users] DMPlex doubt
Mark Adams
mfadams at lbl.gov
Sun Jul 25 06:43:50 CDT 2021
This is a Matt question and I recall a question on getting the original
node ordering recently, but I am not finding it.
How is your Plex created? If you give it a mesh and don't distribute it the
node ordering does not change.
In that case you can use a simpler version Brandon's code:
ierr = DMGetCoordinatesLocal(dm, &coordinates);CHKERRQ(ierr);
Then use VecView.
However, I don't understand what you are trying to do exactly. Are you just
verifying that PLex has the correct coordinates?
Mark
On Sat, Jul 24, 2021 at 9:58 AM Miguel Angel Tapia <miguel.td19 at outlook.com>
wrote:
> Hello. I am a master's student in Mexico. I am currently working on a
> project in which we are implementing DMPlex in a code for electromagnetic
> modeling. Right now I am working on understanding the tool in C. But I'm
> stuck on something and that's why my next doubt:
>
> I am trying to get the coordinates of the nodes of a mesh in DMPlex. I
> already understood how the DAG is structured, how to obtain the nodes that
> make up some point. But the ordering of the nodes changes in DMPlex. So I
> need to know the coordinates of each node to compare them with my initial
> mesh and confirm that the same nodes form the same point in the software I
> am using as well as in the DMPlex DAG.
>
> It would be great if you could guide me a bit on how to do this or
> indicate which DMPlex examples would be good to review or which examples
> solve something similar to my situation.
>
> Thank you in advance. Regards.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20210725/fb7825c7/attachment.html>
More information about the petsc-users
mailing list