# [Maxima] How to assign a derivative of a function to a new function?

Philippe Boeraeve p.boeraeve at hemes.be
Fri May 9 05:01:59 CDT 2008

```Hello,

I am trying to assign a derivative to a new function, in order to know
the value of the derivative of the function at one point.
In the example below, I first assign a third degree polynomial to y(x).
Then I assign the derivative of that function to another function (dy(x)).
When I check, dy(x) shows well the derivative of the function y(x).
When I want to know the value of dy(x) in x=0, I get an error message.

Does anyone have a solution to my problem?

Thanks

Philippe

(%i1) y(x):=a*x^3+b*x^2+c*x+d;
(%o1) y(x):=a*x^3+b*x^2+c*x+d
(%i2) dy(x):=diff(y(x),x);
(%o2) dy(x):=diff(y(x),x)
(%i3) dy(x);
(%o3) 3*a*x^2+2*b*x+c
(%i4) dy(0);
Non-variable 2nd argument to diff:
0
#0: dy(x=0)
-- an error.  To debug this try debugmode(true);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: p_boeraeve.vcf
Type: text/x-vcard
Size: 318 bytes
Desc: not available
Url : http://www.math.utexas.edu/pipermail/maxima/attachments/20080509/f02c4fb2/attachment-0001.vcf
```