I need to manipulate the vertex values of a CG 1 function in parallel with a distributed mesh. My single threaded code iterates over the vertices and does some calculations which require global connectivity information. Afterwards, I use the dofmap to update the .vector() of the function.
In parallel, every dof seems to be uniquely assigned to a processor, but the same vertex can be present on different processors.
So, I would either need
a) A simple way to gather the complete distributed mesh into a serial mesh on processor 0 so I can use my single threaded code or
b) An easy methodology to broadcast (and sum the components of) my array, which is bigger than the local_range to all processors
Thanks!