Curved elements and MPI

Dear NGSolve team,

Are curved elements with MPI currently only supported if the mesh is generated on rank 0, distributed and the geometry is assigned on all other ranks?
Or is it also possible to generate a mesh in a separate script, load the mesh from a file and then curve it?

Thanks for your help.


You can load from file, but you have to set the geometry on all ranks before coarsening.
For example, for an OCC geometry loaded from a separate file:

[code][code][code]geo = netgen.occ.OCCGeometry(geo_file) mesh.ngmesh.SetGeometry(geo) mesh.Curve(3)[/code][/code][/code]

If you are using for example a CSG geometry, you can generate it on all ranks and then set it.

Thank you very much for the clarification. Your solution works very well :slight_smile: