← Back to team overview

dolfin team mailing list archive

Re: Function input

 

> I suggest that we update the interface for Function input so it works
> the same as for other objects, so we change from
>
>     File file("function.xml");
>     Function f;
>     functionfile.parse(f, element);
>
> to
>
>     File file("function.xml");
>     file >> f;
>
> While reading the Function, the input checks the type of finite
> element and attaches it appropriately if found (only P1 for now).
> Otherwise, it generates a warning that the element could not be found
> so it needs to be supplied by the user by
>
>     f.attach(element);
>
> For this to work (automatically creating and attaching an element
> while reading), we need to let a Function keep a local FiniteElement
> in the same way as it can keep a local Vector (element_local == true,
> same as vector_local == true in DiscreteFunction).
>
> Any objections?

Sounds good.

/Johan


>
> /Anders
>
> _______________________________________________
> DOLFIN-dev mailing list
> DOLFIN-dev@xxxxxxxxxx
> http://www.fenics.org/cgi-bin/mailman/listinfo/dolfin-dev
>





References