← Back to team overview

dolfin team mailing list archive

Re: Assembler clean up

 

On 7 February 2013 12:58, Johan Hake <hake.dev@xxxxxxxxx> wrote:
> We might loose a nice feature with this. Because we now attach
> MeshFunctions to the Mesasures (Integrals) in UFL and not the forms
> there are no good way of replacing a MeshFunction in a form in between
> assembles. One can do it but only on preprocessed forms.
>
> If we keep the foo_domains arguments in the Python version of assemble
> we can circumvent this problem. In Python there are no ambiguities and
> behind the scene we can attach the MeshFunctions to the preprocessed
> form within the constructor of dolfin.Form.
>

OK.

Garth


> JOhan
>
> On 02/07/2013 09:55 AM, Garth N. Wells wrote:
>> On 7 February 2013 08:48, Martin Sandve Alnæs <martinal@xxxxxxxxx> wrote:
>>> Fine by me. That matches well how I envision the domains attached to ufl
>>> forms as well.
>>>
>>
>> Great. I was thinking that it would tie up best with the multi-domain work.
>>
>> Garth
>>
>>> Martin
>>>
>>> Den 7. feb. 2013 09:17 skrev "Garth N. Wells" <gnw20@xxxxxxxxx> følgende:
>>>>
>>>> I'm about to start cleaning up the assemblers, and fixing some bugs
>>>> will necessitate some interface changes. For example we have:
>>>>
>>>>   /// Assemble tensor
>>>>   void assemble(GenericTensor& A,
>>>>                 const Form& a,
>>>>                 bool reset_sparsity=true,
>>>>                 bool add_values=false,
>>>>                 bool finalize_tensor=true,
>>>>                 bool keep_diagonal=false);
>>>>
>>>>   /// Assemble tensor on sub domains
>>>>   void assemble(GenericTensor& A,
>>>>                 const Form& a,
>>>>                 const MeshFunction<std::size_t>* cell_domains,
>>>>                 const MeshFunction<std::size_t>* exterior_facet_domains,
>>>>                 const MeshFunction<std::size_t>* interior_facet_domains,
>>>>                 bool reset_sparsity=true,
>>>>                 bool add_values=false,
>>>>                 bool finalize_tensor=true,
>>>>                 bool keep_diagonal=false);
>>>>
>>>> but calling
>>>>
>>>>   assemble(A, a, 0, 0, 0);
>>>>
>>>> is to me ambiguous in terms which function will be called. I think the
>>>> best solution, which we've discussed, it to always attach the domain
>>>> data to forms.
>>>>
>>>> Garth
>>>>
>>>> _______________________________________________
>>>> Mailing list: https://launchpad.net/~dolfin
>>>> Post to     : dolfin@xxxxxxxxxxxxxxxxxxx
>>>> Unsubscribe : https://launchpad.net/~dolfin
>>>> More help   : https://help.launchpad.net/ListHelp
>>
>> _______________________________________________
>> Mailing list: https://launchpad.net/~dolfin
>> Post to     : dolfin@xxxxxxxxxxxxxxxxxxx
>> Unsubscribe : https://launchpad.net/~dolfin
>> More help   : https://help.launchpad.net/ListHelp
>>
>


References