Difficulties with periodic boundary conditions
Dear Professor Geuzaine, I am currently trying to build a periodic mesh, on which a FE solver (MFEM) solves a PDE. The difficulty is the following : the periodic surfaces under consideration, that are drawn on the 3D torus, are not flat at all (with a geometry somewhat close to the plugin of gmsh VoroMetal, or CGAL periodic mesh generator). Until now, the coupling between these codes is not stable at all. It might be due to MFEM, but I am also facing huge instabilities in gmsh. Could you please explain the following things (my scripts are automatically generated, and thus quite long, but I am describing here the last lines of the attached example Maillage.geo) :
- In the .geo script describing the periodic surfaces, gmsh may work with the command l 308
Periodic Surface {2 }={140} Translate {1,-8.3266726846886741e-17,-1.6653345369377348e-16};
but not with the (intuitively equivalent)Periodic Surface {140}={2} Translate {-1,8.3266726846886741e-17,1.6653345369377348e-16};
for which it raises the mysterious "Error : The 1D mesh seems not to be forming a closed loop (2 boundary nodes are considered once)" - Yet, the order of some other surfaces, for example 75 and 68 at line 323, can be inverted without any bug (comparing the outputs, it seems that it just changes the ordering of vertices of the mesh).
Here comes additional questions :
- Is there a criterion to decide in which order to put these boundary conditions?
- In general, are there good examples to get inspiration from for dealing with nontrivial periodic boundaries? (I have read the tutorial 18, as well as studied the plugin VoroMetal, but I am lacking tools and principles for avoiding miscoding ; I just remarked that using "Coherence" in that context is error-prone, for sometimes points of the periodic faces are merged.) Thanks for your help! With kind regards,
Marc Josien
Edited by M J