I do not understand why I receive the error message in the title when I try to run the following code
from dolfin import *
mesh = UnitCubeMesh(10, 10, 10)
V = FunctionSpace(mesh, 'CG', 1)
W = V*V
x = Expression('x[0]', cell='triangle')
y = Expression('x[1]', cell='triangle')
z = Expression('x[2]', cell='triangle')
Ar11 = x*x
Ar12 = x*y
Ar13 = x*z
Ar22 = y*y
Ar23 = y*z
Ar33 = z*z
Ar = as_matrix(((Ar11, Ar12, Ar13), (Ar12, Ar22, Ar23), (Ar13, Ar23, Ar33)))
(u_r, u_i) = TrialFunctions(W)
(v_r, v_i) = TestFunctions(W)
a_r = inner(Ar*grad(u_r), grad(v_r))*dx