Compute the exact derivative.