FIX: Don't expect the derivative to be already allocated