ffc team mailing list archive
-
ffc team
-
Mailing list archive
-
Message #01910
Re: How to determine the order of function parameters in the Linear/BiLinear form?
I'm glad that I asked, and got rewarded with some new tricks :-)
L.alpha = alpha seems very convenient to me, and I'm looking forward to this way of assigning constants.
Best,
Chong Luo
________________________________
From: Anders Logg <logg@xxxxxxxxx>
To: ffc-dev@xxxxxxxxxx
Sent: Thursday, October 30, 2008 2:29:41 AM
Subject: Re: [FFC-dev] How to determine the order of function parameters in the Linear/BiLinear form?
On Wed, Oct 29, 2008 at 03:45:23PM -0700, Chong Luo wrote:
> Hi,
>
> I found the Constant function very convenient, so that we don't have to
> recompile the form file every time we change a constant. However, this adds
> many more function parameters to linear/bilinear forms L(v) and a(u,v), and
> it's a pain to determine the correct order of the function parameters. For
> example, I spent a lot of time, but still couldn't figure out my linear form
> should be L(c10, u, alpha, beta, g) or L(c10, alpha, beta, u, g) or something
> else (the total number of possibilities is 5!=120).
>
> Is there any easy way to figure out the correct order of the function
> parameters in the linear/bilinear forms?
>
> Thank you!
>
> Best,
> Chong Luo
Funny you should ask... In fact, this was added to FFC and DOLFIN
just two minutes ago. :-)
We're currently doing some major work on the DOLFIN Function classes
and introducing a new FunctionSpace class. As part of this, it is now
possible to have a form and do
L.alpha = alpha;
in C++.
This only works in the development version which may have some other
bugs but is starting to work again.
--
Anders