My old code using vertex_to_dof_map for output doesn't work anymore.
vertex_to_dof_map seems to return only a nondeterministic garbage result.
A little piece of code that reproducably yields garbage for m0, m1.
from dolfin import *
mesh = UnitSquareMesh(2,2)
VV = FunctionSpace(mesh,'CG',1)
m0 = vertex_to_dof_map(VV)
n0 = dof_to_vertex_map(VV)
print(m0)
print(n0)
m1 = vertex_to_dof_map(VV)
n1 = dof_to_vertex_map(VV)
print(m1)
print(n1)
with m0,m1 giving different results and wrong indices.
[25769803779 4294967304 30064771076 8589934592 5 3 1 3 2]
[6 3 7 0 4 8 1 5 2]
[25769803779 4294967304 30064771076 8589934592 5 0 0 0 0]
[6 3 7 0 4 8 1 5 2]
Problem showed up for me after upgrade from 1.6 to lastest 2017.1.0dev0.