Mixed quadrature fails when number of points for different degrees coincide

Issue #77 new
Martin Sandve Alnæs created an issue

This works in tensor representation but not in quadrature (or uflacs, but that's the same code path):

from dolfin import *
#parameters['form_compiler']['representation'] = 'uflacs'
parameters['form_compiler']['representation'] = 'quadrature'

mesh = UnitSquareMesh(1, 1)
V = FunctionSpace(mesh, 'CG', 3)
f = interpolate(Expression("x[0]*x[0]*x[0]"), V)

M = [f*dx(degree=i) for i in range(4)]
print assemble(M[3] - M[2])
print assemble(M[1] - M[0])

Trying to fix this might be easy or it might be messy. It would be preferrable with a cleanup of the approach instead of another hack, maybe considered in relation to making degree a native property of integrals in ufl.

A workaround for users is to stick to odd or even quadrature degrees.

Comments (5)

  1. Log in to comment