- #1
Guillaume F.
- 1
- 0
Homework Statement
Homework Equations
Create an algorithm to calculate
[tex] \frac{\partial\mathbf{ABA'}} {\partial\mathbf{B}} [/tex]
where [tex]\mathbf{B}[/tex] is a k x k symmetrical matrix.
The Attempt at a Solution
We know that
[tex] \frac{\partial\mathbf{ABA'}} {\partial\mathbf{B}} =
\mathbf{A} \frac{\partial\mathbf{B}} {\partial\mathbf{B}} \mathbf{A'}.
[/tex]
Hence, we need to calculate [tex] \frac{\partial\mathbf{B}} {\partial\mathbf{B}} [/tex].
This will result in a four dimensional k x k x k x k array, with each element (:,:,i,j) corresponding to the matrix of partial derivative [tex] \frac{\partial\mathbf{B}} {\partial {B_{i,j}}} [/tex].
Furthermore, we know that
[tex] \frac{\partial{B_{g,h}}}
{\partial {B_{i,j}}} [/tex] equals 1 if g = i and h = j, and 0 otherwise. Hence,
[tex] (\frac{\partial\mathbf{B}} {\partial\mathbf{B}})_{g,h,i,j}[/tex] will equal 1 when g = i and h = j, and 0 otherwise.
However, I am still not capable of finding a good way to build [tex] \frac{\partial\mathbf{B}} {\partial\mathbf{B}} [/tex]. Could you help me on this one, or point me in a good direction?
Thanks,
Guillaume