On Tue, Sep 15, 2009 at 2:26 PM, Wilhelm Haager
<wilhelm.haager at htlstp.ac.at> wrote:
> 1) To enforce evaluation at the function definition, you can write:
> ? df(x):=''(diff(f(x),x))$
Another way to evaluate the right hand side is this:
define (df (x), diff (f (x), x));
which is not the same as df(x) := ''(...) because the ... in ''(...) is
evaluated just once (when it is parsed) while in define(df(x), ...)
the ... is evaluated every time the define expression is evaluated.
(So, for example, you could have define in a function and make
the ... depend on the function arguments.)
HTH
Robert Dodier