Derivative of a dot product with respect to vector

44 Views Asked by At

I'd like to get the derivative of the following expression, $$A=\vec{r_1} \cdot \vec{r_2} $$ with respect to $\vec{r_2 }$ where $\vec{r_1}$ is constant. $$\frac{\partial A}{\partial \vec{r_2}}=\vec{r_1} \cdot \frac{\partial \vec{r_2}}{\partial \vec{r_2}}$$ So, Will this be equivalent to the following ? $$\frac{\partial A}{\partial \vec{r_2}}= I \: \vec{r_1}$$ where I is the identity matrix