← Back to team overview

ffc team mailing list archive

Re: [Ufl] tests failing

 


Anders Logg wrote:
> On Thu, Dec 03, 2009 at 11:27:05AM +0000, Garth N. Wells wrote:
>>
>> Garth N. Wells wrote:
>>> Anders Logg wrote:
>>>> On Thu, Dec 03, 2009 at 10:37:19AM +0000, Garth N. Wells wrote:
>>>>> Anders Logg wrote:
>>>>>> On Thu, Dec 03, 2009 at 10:20:06AM +0000, Garth N. Wells wrote:
>>>>>>> The test for
>>>>>>>
>>>>>>>   estimate_max_polynomial_degree
>>>>>>>
>>>>>>> is failing. For
>>>>>>>
>>>>>>>         V2 = FiniteElement("CG", triangle, 2)
>>>>>>>         VV = VectorElement("CG", triangle, 3)
>>>>>>>         v2 = BasisFunction(V2)
>>>>>>>         vv = BasisFunction(VV)
>>>>>>>         print "****Degree ", estimate_max_polynomial_degree(v2*vv[0])
>>>>>>>
>>>>>>> UFL computes a max degree of 3, when it should obviously be 5.
>>>>>>>
>>>>>>> Anders: is this related the changes that you recently made?
>>>>>> Yes. The unit test should be changed.
>>>>>>
>>>>>>   estimate_max_polynominal_degree
>>>>>>
>>>>>> now actually returns the maximum polynomial degree which is 3.
>>>>>>
>>>>>> I have added a new function
>>>>>>
>>>>>>   estimate_total_polynomial_degree
>>>>>>
>>>>>> which does what estimate_max_polynomial_degree used to do.
>>>>>> That function will return 5.
>>>>>>
>>>>> OK. Which one do we want FFC to use?
>>>> Both.
>>>>
>>>> It uses estimate_max to know which degree to choose for unspecified
>>>> elements.
>>>>
>>> It looks to me that FFC is now using too few quadrature points which is
>>> why the FFC tests are failing.
>>>
>> This look ok with the latest changes to compiler.py.
>>
>> The tests are failing because various strings have changed with the
>> change in the definition of grad. I'll go ahead and update the reference
>> code.
> 
> Yes, I thought this was the case (the changed grad).
> 
> Did you confirm that was the case for the change in the generated
> code, or should I have a look?
>

I checked a few somewhat superficially.

We just need to sort out the QuadratureFunction. We can set the Lagrange
element to k=1 and it works (it's presently k=2 which is failing).

Garth

> --
> Anders
> 
> 
>> Garth
>>
>>> Garth
>>>
>>>> Then estimate_total is used to get the total degree for exact
>>>> integration in the tensor representation. The quadrature scheme will
>>>> use estimate_max here also.
>>>>
>>>> Also note that estimate_max does not subtract for derivatives.
>>>>
>>>
>>>
>>> _______________________________________________
>>> Mailing list: https://launchpad.net/~ufl
>>> Post to     : ufl@xxxxxxxxxxxxxxxxxxx
>>> Unsubscribe : https://launchpad.net/~ufl
>>> More help   : https://help.launchpad.net/ListHelp





References