Is it possible to control the partitioning mesh when we solve a problem in parallel

Hi!

When we solve a problem in parallel, FEniCS usually seperate our mesh into several parts, each process will have one of them and do their work on the submesh, and I find that the mesh is usually divided randomly.
My problem is that can we divide the mesh manually? for example, if I have a rectangular mesh, I want to spilt it in half and have two processes such that each process have one half of the mesh.

Thanks in advance.

In doflinx, yes. See the test at dolfinx/test_mesh_partitioners.py at 7f42277b0bae5e6aeb5dc74eee94c85b616d3625 · FEniCS/dolfinx · GitHub for an example.

3 Likes

Thanks for quick reply! I will read it. But is it only works in dofinx?

Unlikely to work in legacy DOLFIN because the design is different, but I haven’t looked for many years.