Hello,
I am trying to calculate the dotproduct of a vector (-1,-1) and an Expression at a point:
from dolfin import *
import numpy
r1=Expression(('-0.2+x[0]*0.2','0.4'))
n=Constant((-1,-1))
sol=dot(n,r1(0.3))
print sol
The value of the Expression at 0.3 is an array with two entrys, I assume the array-representation is the problem here.
The Errormessage I get is:
Invalid type conversion: can not be converted
to any UFL type. The representation of the object is: array([-0.14,
0.4 ])
How can I write it the right way? Thank you very much for your time!
I am using Fenics on Ubuntu with python.