Subject: [FFC-dev] [Bug 472942] [NEW] QuadratureElement crashes mixed formulation

From: oelgaard <[email-masked]>
Date: Tue, 03 Nov 2009 16:37:45 -0000

Public bug reported:

The following simple form will crash when compiled:

CG = FiniteElement("CG", triangle, 1)
quad = VectorElement("Quadrature", triangle, 2)
element = CG + quad
v, Q = TestFunctions(element)
P = Function(CG)
L = inner(grad(v), grad(P))*dx

*** FFC: Points must be equal to coordinates of quadrature points

This is because the form is integrated using only 1 integration point, but the 'quad' element is 2nd order.
If I do:

quad = VectorElement("Quadrature", triangle, 2)

or

P = Function(quad)
L = inner(grad(v), P)*dx

the form compiles fine.

In all cases the compiler also issues the following warning:

*** WARNING: Derivatives are not defined on a QuadratureElement,
             returning values of basisfunction.

even though no derivatives of any functions defined on a QE is used in
the form.

** Affects: ffc
     Importance: Low
         Status: New

-- 
QuadratureElement crashes mixed formulation
https://bugs.launchpad.net/bugs/472942
You received this bug notification because you are subscribed to FFC.

Status in FEniCS Form Compiler: New

Bug description:
The following simple form will crash when compiled:

CG = FiniteElement("CG", triangle, 1)
quad = VectorElement("Quadrature", triangle, 2)
element = CG + quad
v, Q = TestFunctions(element)
P = Function(CG)
L = inner(grad(v), grad(P))*dx

*** FFC: Points must be equal to coordinates of quadrature points

This is because the form is integrated using only 1 integration point, but the 'quad' element is 2nd order.
If I do:

quad = VectorElement("Quadrature", triangle, 2)

or

P = Function(quad)
L = inner(grad(v), P)*dx

the form compiles fine.

In all cases the compiler also issues the following warning:

*** WARNING: Derivatives are not defined on a QuadratureElement,
             returning values of basisfunction.

even though no derivatives of any functions defined on a QE is used in the form.