I want to find:
$$ \frac{\partial H }{\partial a_{i,j}} = \frac{\partial }{\partial a_{i,j}} \mathbf{c}^{T} (s^{\ast} \mathbf{I} - \mathbf{A})^{-1} \mathbf{b} \mathbf{c}^{T} (s \mathbf{I} - \mathbf{A})^{-1} \mathbf{b} $$
where $s^{\ast}$ is the complex conjugate of $s$, $s$ being a constant, $\mathbf{c}, \mathbf{b}, \mathbf{A}$ are all real and $\mathbf{c},\mathbf{b}$ do not depend on $\mathbf{A}$.
Attempt at an answer:
Since $H()$ us a scalar function, we know from the matrix cookbook that:
$$ \frac{\partial H }{\partial a_{i,j}} = \text{tr}\left( \left[ \frac{ \partial H}{\partial \mathbf{A}} \right]^{H} \frac{ \partial \mathbf{A}}{\partial a_{i,j}} \right) $$
However, I am not sure how to find $\frac{\partial H}{\partial \mathbf{A}}$. Can I get some help here? I have a heap of computations, but I don't seem to be getting anywhere...
Let $f(A)=c^T(sI-A)^{-1}b$. Using $dX^{-1}=-X^{-1}(dX)X^{-1}$, we get \begin{aligned} df(A) &=c^T\left[d(zI-A)^{-1}\right]b\\ &=-c^T(sI-A)^{-1}\left[d(sI-A)\right](sI-A)^{-1}b\\ &=c^T(sI-A)^{-1}(dA)(sI-A)^{-1}b. \end{aligned} Since $A$ is real, $\overline{df(A)}=d\overline{f(A)}$. Therefore \begin{aligned} dH=d\left(\overline{f(A)}f(A)\right) &=d\overline{f(A)}f(A)+\overline{f(A)}df(A)\\ &=\overline{df(A)}f(A)+\overline{f(A)}df(A)\\ &=2\operatorname{Re}\left(\overline{f(A)}df(A)\right)\\ &=2\operatorname{Re}\left(c^T(s^\ast I-A)^{-1}b\ c^T(sI-A)^{-1}(dA)(sI-A)^{-1}b\right).\\ \end{aligned} Let $\{e_1,e_2,\ldots,e_n\}$ be the standard basis of $\mathbb C^n$. It follows that \begin{aligned} \frac{\partial H}{\partial a_{ij}} &=2\operatorname{Re}\left[ c^T(s^\ast I-A)^{-1}b \ c^T(sI-A)^{-1}e_i \ e_j^T(sI-A)^{-1}b\right]\\ &=2\operatorname{Re}\left[e_j^T(sI-A)^{-1}b\ c^T(s^\ast I-A)^{-1}b\ c^T(sI-A)^{-1}e_i\right]\\ &=g_{ij}\\ \end{aligned} where $g_{ij}$ is the $(i,j)$-th entry of the matrix $$ G=2\operatorname{Re}\left[(sI-A)^{-1}b\ c^T(s^\ast I-A)^{-1}b\ c^T(sI-A)^{-1}\right]^{\ T}. $$