I am quite new with FEniCS so probably my problem is standard but I did not find a solution anywhere else. I am working on a tetrahedral mesh which is stored as a dolfin mesh file mesh.xml.gz. I have another file potential.xml.gz with the dof values derived from a “previous solution” and externally processed, defined on the mesh from a “CR” function space. These are scalar values defined at the barycenter of each facet of the tetrahedron. I would like to visualize the corresponding “gradient” as vector field defined in each Tet in Paraview. I am stuck with the following:
- How to import potential.xml.gz? Do I need to create a Function and map the corresponding values per dof? (something like vertex_to_dof_map)
- How to derive the corresponding gradient vector field?
Exporting the mesh with the vector field to ParaView is fine. Any help will be welcome
Thank you very much