### 5.21 Diff

• Diff( <name>, <expression>, <variable> [, param1,..., paramN] )
• Description: that function create a macro called <name>, if it already existed then the old macro will be overwritten unless it is a predefined macro then there will be no effect. The created macro body corresponds to the derivative of the <expression> with respect to <variable>. Optional parameters are variable names. The variable name <param1> is replaced in the derivative’s expression with the parameter %1, the name <param2> is replaced with %2 ... etc. That function returns Nil.
• Exemple(s): after the command execution (in the command line at the bottom of the window): Diff(df, sin(3*t), t), a macro called df is created and its content is: 3*cos(3*t), This is a macro without parameter that contain a local variable $t$, it will have to be used with immediate development (ie: preceded by the symbol: $\$) 2. On the contrary, after the command Diff(df,sin(3*t),t,t), the content of the macro df is: 3*cos(3*%1) that is a one parameter macro.