Differentiation

D[f,x]partial derivative
D[f,x,y,]multiple derivative
D[f,{x,n}]n^(th) derivative
D[f,x,NonConstants->{v1,v2,}] with the taken to depend on x

Partial differentiation operations.

This gives .
In[1]:=
Click for copyable input
Out[1]=
This gives the third derivative.
In[2]:=
Click for copyable input
Out[2]=
You can differentiate with respect to any expression that does not involve explicit mathematical operations.
In[3]:=
Click for copyable input
Out[3]=
D does partial differentiation. It assumes here that is independent of .
In[4]:=
Click for copyable input
Out[4]=
If does in fact depend on , you can use the explicit functional form . "The Representation of Derivatives" describes how objects like work.
In[5]:=
Click for copyable input
Out[5]=
Instead of giving an explicit function , you can tell D that implicitly depends on . D[y,x,NonConstants->{y}] then represents , with implicitly depending on .
In[6]:=
Click for copyable input
Out[6]=
D[f,{{x1,x2,}}]the gradient of a scalar function
D[f,{{x1,x2,},2}]the Hessian matrix for f
D[f,{{x1,x2,},n}]the n^(th)-order Taylor series coefficient
D[{f1,f2,},{{x1,x2,}}]the Jacobian for a vector function f

Vector derivatives.

This gives the gradient of the function .
In[7]:=
Click for copyable input
Out[7]=
This gives the Hessian.
In[8]:=
Click for copyable input
Out[8]=
This gives the Jacobian for a vector function.
In[9]:=
Click for copyable input
Out[9]=