in reply to Re^2: Closures and undefined subs
in thread Closures and undefined subs

I am afraid use solved my problem but I am not happy for that :-)
RungeKutta needs \&in_2 in its own call.
I my opinion I need to write the closures as Rungekutta needs some equation in the differentiation sub. In this case the equation is too complex and needs variables that are imported into the outer sub of the package. So I guess I am in need of that much levels of complexity.
But what do you mean with lexicals? Could you give a "simple" example? Thank you.

Replies are listed 'Best First'.
Re^4: Closures and undefined subs
by ikegami (Patriarch) on Sep 26, 2007 at 14:46 UTC

    But what do you mean with lexicals? Could you give a "simple" example? Thank you.

    Short for "lexical variables".

    my $var;

    RungeKutta needs \&in_2 in its own call.

    Not a problem. See the solution I added to my original post in this thread.