improve Product._derivative
improve Product._derivative

This patch reimplements Product's derivative using insertaxis and diagonalize
rather than stack, improving efficiency and fixing products of non-constant
axes.

wijnandhoitinga/nutils