ffc team mailing list archive
-
ffc team
-
Mailing list archive
-
Message #00614
Projection - error?
Hi,
I'm trying to project a function defined on a continuous linear basis onto a
discontinuous constant basis.
I use the following form:
P0 = FiniteElement("Discontinuous vector Lagrange", "triangle", 0)
P1 = FiniteElement("Vector Lagrange", "triangle", 1)
v = TestFunction(P0)
u = Function(P1)
pi1 = Projection(P0)
L = dot(v,pi1(u))*dx
The projection matrix generated by FFC looks OK to me, and in Projection.h the
coefficients are:
const real c0_0 = 3.333333333333333e-01*c[0][0] +
3.333333333333334e-01*c[0][1] + 3.333333333333333e-01*c[0][2];
const real c0_1 = 3.333333333333333e-01*c[0][3] +
3.333333333333334e-01*c[0][4] + 3.333333333333333e-01*c[0][5];
What is strange is that in the element tensor a factor of 0.5 appears:
block[0] = 4.999999999999996e-01*G0_0;
block[1] = 4.999999999999996e-01*G0_1;
So the values of my projection are only half the size of the originals.
Note: In 3D, the factor is 1/6. (These factors appear in monomialintegration.py
as area an volume scaling)
Is there something wrong or am I using projection wrong??
/Kristian