On 06/26/2013 05:32 AM, Stephen Ippolito wrote:
> Hi I'm brand new to maxima, and I hope it is okay to ask questions on
> this mailing list.
Hi,
welcome. Yes, this is the right place to ask your questions about Maxima.
>
> I'd like to use evolution2d
>
> ( see http://maxima.sourceforge.net/docs/manual/en/maxima_50.html)
>
> to look at iterations for a flow with a certain time step.
>
> or phi_t(phi_t(xo)) = phi_2t(xo) etc
>
> What I tried was integrating the ODE to the required time where x is
> my initial condition then picking out the last value. (Notice the
> apostrophe in front of last and rk)
>
> define(f(x),'last('rk(exp(-t) + u, u,x,[t,2,7,0.01]))[2]);
>
> If I type say f(-0.1),nouns I do get the answer I'm looking for
> but I've been unable to put this line into a functions. For instance
> I tried
>
> g(x) := nouns(f(x)) and define(g(x), (f(x),nouns)) but no success.
You should use:
g(x) := ev(f(x),nouns);
when you type "abc, def" in a Maxima input line, it is really a short
way of writing ev(abc, def)
In this case you should use := instead of define, because you do not
want the ev() function to be applied and then the function g(x) defined,
but you want the evaluation of ev() to be deferred until g(x) is used
with an input value.
>
> I'd appreciate any help and also if someone can think of a better way
> to approach this problem I'd appreciate it.
>
Sorry. I did not fully understand what you're attempting to do. What
variables will go in the two axes of the plot you want to produce with
evolution2d? (t and x?). And is your iteration going to be something
such as x0, x1=g(x0), x2=g(x1),...?
Regards,
Jaime
(author of rk and evolution2d)