octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [fem-fenics] Function evaluation


From: Marco Vassallo
Subject: Re: [fem-fenics] Function evaluation
Date: Thu, 26 Jun 2014 23:53:15 +0200




On Wed, Jun 25, 2014 at 1:06 PM, Eugenio Gianniti <address@hidden> wrote:
Dear Marco,

you can find on the hg repository [1] my latest work on the function evaluation feature and in my blog a post [2] about it. Note that the interface change highlighted in the post has already been implemented, later I will write a post to document it and show how it can be used.

Thanks, the two blogpost where really good.
 

My second doubt is related to the association of fem-fenics functions with function handles. I tried to go through the code base in order to understand what to do, but I cannot quite get it. I expect that the function class should inherit from octave_function, but it is not enough, because if I type "handle = @function" Octave complains about not finding a function or a method to attach to the handle. Basically I grasp that there is some preparation made when a regular function is loaded, probably meant to make it available in the symbol table, that the fem-fenics function class lacks. To be honest, I do not even know if it is possible for something to be at the same time both a function and a variable, which is what I try to accomplish. If you think it is something feasible, I would need an explanation, otherwise I look forward to suggestions on an alternative approach.

I'm not sure if I understand what you want to do.
In the script file you'd llke to have the possibility to do something like this:

.....
u = Function ('u', solution, 1);
....
U = @(x, y) u(x, y);

.....

f = u (1, 2);

Is it right? If yes, what is the code you have written right now for this case?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]