[SciPy-user] ode/programming question
Mon Apr 30 12:38:51 CDT 2007
When using one of the ODE solvers, you can pass it a list of arguments.
These arguments are used in the function that defines the system of
linear equations that you're solving. What if I want to modify an
argument every iteration and re-pass this modified argument to the
helper function in the next iteration? In Matlab (what I'm most familiar
with), this is easy to do, using "nested" functions, because they share
the same scope/namespace as the function they're nested in. This is not
the case in Python, however, so I'm curious what the best way of doing
this would be. I assume I define a global variable, but I'm wondering
if there's another, perhaps better, way of doing it.
Postdoctoral Research Assoc.
Department of Physics
University of Ilinois
1110 W. Green St.
Urbana, IL 61801
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the SciPy-user