On Wed, Dec 18, 2013 at 11:53 AM, Ricardo JF <rcrdjf at hotmail.com> wrote:
> f(x):= x^2;
> i(y):= rhs(last( solve(f(x)=y,x)));
> i(2);i(3);i(4);
>
I'm not entirely sure I understand what you're asking. In particular,
saying "doesn't work as expected" isn't very explicit: what were you
expecting?
But if I'm understanding your question correctly...
In your first example, the variable 'y' is bound by the function. In the
second it isn't. Here is a simpler example:
q(w):=w$
q(2) => 2
val: w$
r(w):= val$
r(2) => val (not 2)