How to get a Mapping of Surface Mesh DoF and Volume Boundary DoF?

25 views
Skip to first unread message

cd

unread,
May 9, 2020, 5:55:27 AM5/9/20
to deal.II User Group
Dear deal.II community,

I would like to compare solutions of std fem and a mesh-free fem method. 

To start with I have a  Triangulation<dim> volume_mesh and from this, I use GridGenerator::extract_boundary_mesh to generate Triangulation<dim - 1, dim> surface_mesh. 

Then I solve a std fem elasticity problem and compute volume_solution vector. 

Further, I also solve a meshfree problem using only the surface_mesh information and from this, I have a surface_solution. 

Now I need a dof map to compare the two solution vectors. How can I get this dof map?

Thank You.

Wolfgang Bangerth

unread,
May 12, 2020, 11:54:59 AM5/12/20
to dea...@googlegroups.com
On 5/9/20 3:55 AM, cd wrote:
>
> To start with I have a  Triangulation<dim> volume_mesh and from this, I
> use GridGenerator::extract_boundary_mesh to generate Triangulation<dim - 1,
> dim> surface_mesh.
>
> Then I solve a std fem elasticity problem and compute volume_solution vector.
>
> Further, I also solve a meshfree problem using only the surface_mesh
> information and from this, I have a surface_solution.
>
> Now I need a dof map to compare the two solution vectors. How can I get this
> dof map?

The GridGenerator::extract_boundary_mesh() function returns this kind of map
that connects the cells of the volume and the boundary mesh. If you call the
function with two DoFHandler objects (one of which is based on an empty
triangulation), then you will return a map between DoFHandler iterators that
you can at a later point use to call
cell->get_dof_indices()
to see which degrees of freedom are associated with each volume or surface cell.

Best
W.


--
------------------------------------------------------------------------
Wolfgang Bangerth email: bang...@colostate.edu
www: http://www.math.colostate.edu/~bangerth/

Reply all
Reply to author
Forward
0 new messages