[petsc-users] DOF projection after dmforest adaption

Preda Silvia silvia.preda at uninsubria.it
Fri Mar 14 13:02:38 CDT 2025


On Fri, Mar 14, 2025 at 12:15 PM Preda Silvia via petsc-users <petsc-users at mcs.anl.gov<mailto:petsc-users at mcs.anl.gov>> wrote:
Hi,

We are having a hard time understanding how the degrees of freedom are projected after a dmforest adaption. Having used before the P4EST library directly, we recall that there, a index mapping from quadrants present in the grid before and after adaption (1 to 1, 1 to many, many to 1, for unaltered, refined, coarsened quadrants, respectively) was available. Would it be possible to access the same information for a dmforest?

Thank you for all the suggestion!

I do not understand exactly what you want yet.

Let’s make an explicit example. I have an old mesh and a new adapted one. Between the two meshes, the following correspondences hold:

  *   The quadrant indexed as 1 in the old mesh has been refined and has originated the quadrants indexed as 3, 4, 5, 6 in the new mesh
  *   The quadrants 10, 11, 12, 13 (old indexing) have been coarsened and correspond to the quadrant 7 in the new mesh indexing
  *   The quadrant 15 (old indexing) has been left unchanged, but in the new mesh is indexed as 17.

We would like to have access to this mapping between the sets of old and new indices.

A projection of the dofs would necessarily depend on the function space you are using to represent the field.

So you might instead be asking, can I get the  refinement pattern like the parent of a given cell. You can get this

  https://urldefense.us/v3/__https://petsc.org/main/manualpages/DMPlex/DMPlexGetTreeParent/__;!!G_uCfscf7eWS!eEQKDGx261iREJkDLwioeVGv-9jkXQ_Vgn15eYSfh30mRtmoRCucEcrPvKIaxQr6T7hZqGq6Ifpj6ZNrOkOmjsFquTJsi3eFPg$ 

It is not clear to me if the function you suggested is apt to our aim.

Thanks,

Silvia

There are few users (except us), so we would be happy to listen to interface suggestions. I will also note that Toby is
the expert, and I am an amateur.

  Thanks,

     Matt

Silvia


--
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://urldefense.us/v3/__https://www.cse.buffalo.edu/*knepley/__;fg!!G_uCfscf7eWS!eEQKDGx261iREJkDLwioeVGv-9jkXQ_Vgn15eYSfh30mRtmoRCucEcrPvKIaxQr6T7hZqGq6Ifpj6ZNrOkOmjsFquTJetwsp_A$ <https://urldefense.us/v3/__http://www.cse.buffalo.edu/*knepley/__;fg!!G_uCfscf7eWS!eEQKDGx261iREJkDLwioeVGv-9jkXQ_Vgn15eYSfh30mRtmoRCucEcrPvKIaxQr6T7hZqGq6Ifpj6ZNrOkOmjsFquTLrtCQ1Yw$ >
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20250314/8ea8d167/attachment.html>


More information about the petsc-users mailing list