On Tue, 29 Nov 2016, Michael Povolotskyi wrote: > in libmesh one can set communicator in the LibMeshInit and in the Mesh > constructor. > > Imagine, that my Mesh is serial, defined on MPI_COMM_SELF, exists on > every MPI process. > > I want to solve the system only on one MPI process, then I will > broadcast solution. > > Which communicator should I use for LibMeshInit? Will it be any difference?
You're handling MPI setup and teardown yourself. If you also do the broadcast with your own MPI code, it definitely shouldn't make a difference. An application code which works this way was the motivation for adding an MPI communicator argument to LibMeshInit in the first place. If you want to use the libMesh Parallel:: utilities then you'll need to construct a libMesh::Parallel::Communicator from MPI_COMM_WORLD, which people usually do by just grabbing LibMeshInit::comm()... But in theory, there should be no requirement to do so. If you're not using any of our legacy API options then there shouldn't be anything internal to the library now which depends on what you hand to the LibMeshInit object. You can just hand MPI_COMM_WORLD to the Communicator constructor. --- Roy ------------------------------------------------------------------------------ _______________________________________________ Libmesh-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/libmesh-users
