Why i plot displacement arrow graph rather than cloud graph?

You need to pass the cmap into the plotting instruction, as in this MWE:

from dolfin import *

mesh = UnitSquareMesh(10,10)
V = FunctionSpace(mesh, "CG", 1)
v = Function(V)
v.vector()[0] = 1

import matplotlib.pyplot as plt

surf = plot(v, cmap=plt.cm.jet)
plt.colorbar(surf)
plt.savefig("u.png")

This is also easy to achieve in Paraview, which offers a large variety of colormaps.

2 Likes