← Back to team overview

dolfin team mailing list archive

Re: No access any more to FiniteElement / ufc::finite_element from within UFC ?

 


On 17/01/11 15:27, Andre Massing wrote:
> Den 17.01.11 16.14, skrev Garth N. Wells:
>>
>>
>> On 17/01/11 15:11, Andre Massing wrote:
>>> Den 17.01.11 15.49, skrev Garth N. Wells:
>>>>
>>>>
>>>> On 17/01/11 14:46, Andre Massing wrote:
>>>>> Hi!
>>>>>
>>>>> I just realized that the previous member
>>>>>
>>>>> FiniteElement** coefficient_elements
>>>>> and
>>>>> std::vector<FiniteElement>   finite_elements
>>>>> , respectively were removed from the UFC class.
>>>>
>>>> The coefficient finite elements are still there.
>>>
>>> Yes, but I need the ones which correspond to the test and trial function
>>> spaces.
>>>
>>>>
>>>>> I need these ones or
>>>>> more precisely access to the underlying ufc::finite_element.
>>>>>
>>>>> Can anybody give me a quick hint how to achieve this in the newer
>>>>> DOLFIN
>>>>> versions? I already scanned through the code, but could not find a
>>>>> simple solution.
>>>>>
>>>>
>>>>>  From a FunctionSpace, you can extract a dolfin::FiniteElement,
>>>>> followed
>>>> by a ufc::finite_element.
>>>
>>> But not from within the UFC class since the dolfin::Form form member is
>>> private. Since the UFC class takes a dolfin::Form argument in the
>>> constructor and a reference to the Form is stored in the UFC class,
>>> would it not be meanful to make it accessible  by having a
>>> const Form&  form() const;
>>> member function in the UFC class?
>>>
>>
>> Just pass the Form and don't use UFC.
>>
>> The UFC class is just a convenience class for assembly, and shouldn't
>> generally be used. The less that is in UFC, the easy things are to
>> maintain (as I know from having made some recent changes).
> 
> Ok, I can changed that in my code, it was just convenient since I also
> need the UFCcell. To be honest, the code dependencies between UFC,
> ufc::form and dolfin::Form are sometimes a bit hard to follow and the
> overall reasoning/big picture behind the implementation is difficult to
> grasp for me :), so many thanks for the quick help!!
> 

We've tried to hide/wrap ufc::foo in most parts of the code because it
does get confusing mixing ufc::foo and dolfin::foo.

Garth

> -- 
> Andre
> 
>>
>> Garth
>>
>>> -- 
>>> Andre
>>>
>>>
>>>
>>>
>>>>
>>>> Garth
>>>>
>>>>> Kind regards,
>>>>> Andre
>>>>>
>>>>
>>>>
>>>> _______________________________________________
>>>> Mailing list: https://launchpad.net/~dolfin
>>>> Post to     : dolfin@xxxxxxxxxxxxxxxxxxx
>>>> Unsubscribe : https://launchpad.net/~dolfin
>>>> More help   : https://help.launchpad.net/ListHelp
>>>
>>>
>>
> 
> 



References