Hi, I'm gonna calculate the Jacobian matrix of the following function:

$\displaystyle f(r) = \frac{(r\cdot v)r}{r^2}$

where $\displaystyle r$ is the position. Since all variables in this expression are vectors I haven't bothered making them bold. I realized that the the Jacobian can be expressed as

$\displaystyle J_f(r) = (\nabla\otimes f(r))^{\text{T}},$

where $\displaystyle \otimes$ is the outer product, so we have

$\displaystyle (J_f(r))^{\text{T}} = \nabla\otimes f(r) = \nabla\otimes \frac{(r\cdot v)r}{r^2}$

I don't know how to simplify this without making really ugly expansions of all the elements in the vectors, but I've kind of already figured out (I think) that this is equals to

$\displaystyle \frac{r\cdot v}{r^2}\,I + \frac{r\otimes v}{r^2} - \frac{2(r\cdot v)r}{r^4}\otimes r$

where $\displaystyle I$ is the identity matrix. As I said, I think this is correct, but I don't know how to show it! Can anyone please help me to show that this is really the case? Which product rules should I use here?