Hello!
I have the list of the global dof indices by doing the following*:
V = FunctionSpace(mesh, 'DG', 1)
dofs_0 = V.dofmap().dofs()
Now, I would like to access the coordinates of a given degree of freedom k in dofs_0. Is there a simple way to do that?
I saw that we can access the coordinates of all dofs by using thetabulate_all_coordinates() method of GenericDofMap but when I try this:
print V.dofmap().tabulate_all_coordinates()
I get the following error:
TypeError: GenericDofMap_tabulate_all_coordinates expected 2
arguments, got 1
which really confuses me since the documentation does not mention any argument for this method...
I also saw the dof_to_vertex_map method but I do not know if that would do it since it is said that it "only works for FunctionSpace with dofs exclusively on vertices. "
Any suggestions?
Thanks a lot in advance!
Vincent
*nicely provided by MiroK on this forum: see http://fenicsproject.org/qa/3865/updating-a-function-that-is-in-mixedfunctionspace if interested