This is a read only copy of the old FEniCS QA forum. Please visit the new QA forum to ask questions

Scalar within vector innner product Shape mismatch how to calculate

–3 votes

Hi
I have VectorFucntionSpace in RT, FunctionSpace in CG likes this

X = VectorFunctionSpace(mesh, "RT", 2)
Y = FunctionSpace(mesh, "CG", 1)
W = MixedFunctionSpace([X,Y,Y,Y,X,Y,Y])

then i use TrailFunction, TestFucntion likes this

(p,y,p0,p1,p2,p3,z) = TriaFunction(W)
pt,yt,p0t,p1t,p2t,p3t,zt) = TestFunction(W)

After that i have inner product some thing like

a =  inner(div(p),p1t)*dx + inner(y, div(p2))*dx

Error occur: shape mismatch it

Can anybody clarify this to me?

asked Jan 19, 2014 by Manickam FEniCS Novice (450 points)
edited Jan 21, 2014 by Manickam

Try to phrase your query as a question. It's not clear what you're asking.

1 Answer

0 votes

do

y*div(p2)*dx
answered Jan 20, 2014 by Kent-Andre Mardal FEniCS Expert (14,380 points)
edited Jan 20, 2014 by Jan Blechta
Error on UFL Exception
...