Hi,
I am trying to incorporate a vector field that is read in from an xml file to solve a problem. Say for a 3D conduction problem, the isotropic conductivity tensor (Dmat) was prescribed in the past using:
Dconst = 1e2
Dmat = Constant(((Dconst, 0.0, 0.0), (0.0,Dconst, 0.0), (0.0, 0.0, Dconst)))
Now, I have an anisotropic conduction field based on the material coordinate vectors that I read in from an xml file at the quadrature points of a mesh i.e.
Vq = VectorFunctionSpace(mesh, "Quadrature", 4)
x1 = Function(Vq)
File(vectorfilename_x1) >> x1
x2 = Function(Vq)
File(vectorfilename_x2) >> x2
x3 = Function(Vq)
File(vectorfilename_x3) >> x3
and I want to make use of them to transform the conductivity tensor in material coordinates to that in cartesian coordinates using the following (which is not working) (with D11, D22 and D33 prescribed):
Dmat = Constant(((D11, 0.0, 0.0), (0.0,D22, 0.0), (0.0, 0.0, D33)))
Q = ((fiber_f0, fiber_s0, fiber_n0))
D = transpose(Q)DmatQ
How should I go about doing it?
Thanks a lot!