Maybe you should to do this to export:
np.savetxt("stiffnessmatrix.txt", A.array())
and this to print:
print("stiffness_matrix: "), A.array()
(*) It is perhaps a good idea to reduce (considerably) the number of nodes in the mesh to see if what you are printing it's o.k., e.g, run the code with this mesh:
Mesh = BoxMesh(o, l, 1, 1, 1)