#### 6.59 assign the result of dsolve (27.10.95)

##### 6.59.1 Burkhard Wald

May be you have a result of dsolve and want to plot it. For example:

> res:={a(t)=exp(t),b(t)=exp(-t)}:
> assign(res);
> plot({a(t),b(t)},t=-5..5);



Nice! It works!

But! Look at a(0), a(t[1]-t[2]) ! What is "a" ? "a" ist a procedure with a(t)=exp(t) in its remember table. Nothing more! This is not what I want. What I want, can I get by:

> map(x->map(unapply,x,t),res);

{ a = exp, b = t -> exp(- t) }

> assign(%);



And now think you are in a physics course and want to explain how easy it is with maple to solve problems and come to a visualization.

Is there anybody who know what I can do instead of this map(x->map(unapply,x,t),res) ?

##### 6.59.2 Bhairav Joshi

I am also interested in the question you raise. An awkward method that I have used in such situations is this:

            af := unapply( rhs(res[1]), t);
bf := unapply( rhs(res[2]), t);



$$af(t)$$ and $$bf(t)$$ can now be used in the usual manner.

##### 6.59.3 Neil E. Berger 312-413-2139

well you could always do...

> plot({seq(rhs(res[i]),i=1..nops(res))},t=0..1);



or even set up a little proc...

> plot_sol_set := proc(x,range) plot({seq(rhs(x[i]),i=1..nops(x))},t=range)end;
> plot_sol_set(res,0..2);



this has the advantage of having no side eﬀects, but of course the solutions must all depend on t.