Rigid contact between two geometries having different materials

Hi all, I have two bodies having different materials which have rigid contact between them. I want to export it in xdmf format from gmsh using meshio. When I am performing the modal analysis of such geometries I am getting the rigid body modes that means that there is some contact issue between them. Is there any way with which we can simulate the contact between two bodies in gmsh or in fenics.

If you are meshing both bodies you should use BooleanFragments in Gmsh to merge the meshes But resolve the interface.
See for instance: Mesh generation and conversion with GMSH and PYGMSH | Jørgen S. Dokken

If you really want two meshes, consider:

Thanks Sir,
Can you also tell me how different material properties can be assigned in these two geometries.

See for instance:
https://jorgensd.github.io/dolfinx-tutorial/chapter3/subdomains.html

1 Like