
The result is given in terms of the differentials ( Dt, Dt, in this case) of the variables occurring in expr. To do this with D, you would explicitly make x, y, and z functions of t:įinally, the one-argument form Dt gives the total differential of the expression expr: For example, suppose you want the time derivative of x + y z given in terms of the time derivatives of x, y, and z. This can be useful in situations where you have variables that implicitly depend on some other variable.

Compare D and Dt in this short example:ĭ assumes a is a constant independent of x Dt does not, and Dt remains unevaluated. It works like D, except Dt does not assume zero derivative for parts of expr with no dependence on x. (You could also write the above in a single line as Derivative.)ĭt computes the total derivative of the expression expr with respect to x. As with D, generalizations like multiple derivatives and derivatives with respect to multiple variables are possible:ĭerivative specifies differentiation twice with respect to the first argument and once with respect to the second argument. The notation f ' is shorthand for Derivative, specifying differentiation once with respect to the first argument. Note that if you immediately evaluate this function at x, the result is exactly what you would have found by using D to differentiate the quantity Sqrt with respect to x: The result is a pure Function of one unnamed argument #1. To differentiate a function, you use Derivative, which has the standard shorthand notation ' (apostrophe): D takes the partial derivative to be zero for all subexpressions that don’t explicitly depend on x. D computes the derivative of an expression representing a quantity, such as Sin, not a function, such as Sin. There are two important properties of D that distinguish it from other functions for computing derivatives in Mathematica:ġ. The main function for computing derivatives in Mathematica is D, which computes the familiar partial derivative of an expression with respect to a variable:ĭ supports generalizations including multiple derivatives and derivatives with respect to multiple variables, such as differentiating twice with respect to x, then once with respect to y:Īnd vector and tensor derivatives, such as the gradient: What are the different functions for computing derivatives in Mathematica?


This week’s question comes from Bashir, a student: You can submit your question directly to the Q&A Team using this form.
