ffc team mailing list archive
-
ffc team
-
Mailing list archive
-
Message #01316
Re: Getting NoneType from dot
2007/10/12, Martin Sandve Alnæs <martinal@xxxxxxxxx>:
> 1) What is wrong with this form?
> 2) If it's a user mistake and not an ffc bug, ffc should raise an
> exception and not return None
>
>
> from ffc import *
>
> fe = FiniteElement("Lagrange", "triangle", 1)
This should be:
fe = VectorElement("Lagrange", "triangle", 1)
but it doesn't change the None returned from dot.
>
> v = TestFunction(fe)
> u = TrialFunction(fe)
> w = Function(fe)
>
> Dw = grad(w)
> Du = grad(u)
>
> uDw = dot(u, Dw)
>
> print u
> print Dw
> print uDw # None!
Output:
vi-1
[[w0_a9(dXa11/dx0) | ((d/dXa11)va9[0]), w0_a12(dXa14/dx1) |
((d/dXa14)va12[0])], [w0_a15(dXa17/dx0) | ((d/dXa17)va15[1]),
w0_a18(dXa20/dx1) | ((d/dXa20)va18[1])]]
None
> wDu = dot(w, Du)
>
> a = dot(v, uDw+wDu) * dx
>
>
>
> --
> Martin
>
--
Martin
Follow ups
References