ufl team mailing list archive
-
ufl team
-
Mailing list archive
-
Message #01591
Re: conditionals
On 30 January 2010 11:56, Garth N. Wells <gnw20@xxxxxxxxx> wrote:
In the UFL manual, there is a section on 'conditionals' (sec 2.11) but
I'm unsure of the what the intention is. Is the idea that they can be
used in forms? It would be really useful if I could do something like:
un = dot(u, n)
cond = lt(un, 0.0)
and use 'cond' (= 0 or 1) in a form.
As I recall it, we (you and I) thought it would be nice to have conditionals so we could use it to determine if a facet was an outflow facet or not at runtime in the generated C++ code. I think the idea was to simply translate the conditionals in a form into
if ( condition )
{
do something
}
blocks in the generated code.
However, due to other improvements in the UFL language we can now determine the outflow facets in a more elegant way, in my opinion, so we didn't look further into the conditionals. That being said, there might be other cases where it will still be useful.
Kristian
Garth
_______________________________________________
Mailing list: https://launchpad.net/~ufl
Post to : ufl@xxxxxxxxxxxxxxxxxxx
Unsubscribe : https://launchpad.net/~ufl
More help : https://help.launchpad.net/ListHelp
Attachment:
signature.asc
Description: OpenPGP digital signature
Follow ups
References