I’m trying to use HDF5 output from FEniCS parallel runs and am trying to figure out how the solution values/degrees of freedom are sorted (with respect to the mesh). My test example is a basic Poisson equation on a 1D line with 5 cells and linear elements, this results in
cells = [0 1 2 3 4 5]
cell_dofs = [1 0 0 5 5 4 4 3 3 2]
vector_0 = [0.08 0 0 0.08 0.12 0.12]
x_cell_dofs = [0 2 4 6 8 10 ]
I had thought “x_cell_dofs” maps the values in “vector_0” to “cell_dofs”, but “cell_dofs” only has 10 entries. I just can’t seem to figure out the ordering. Maybe I’m doing this wrong or there is some utility function, otherwise how can I sort back vector_0 to correspond to the global (serial) dofs/mesh?