I saw from this link how to calculate the gradient of the function f(x)=$x^TPx$:
How to calculate gradient of $x^TAx$
Does this proof still hold true when the inverse of the P-matrix is used? My assumption is that it should, as I could just let a matrix $A=P^{-1}$, and then follow the steps outlined in the link to arrive at $f'(x)=\nabla f=x^T(A+A^T)$ or for my specific question $f'(x)=\nabla f=x^T(P^{-1}+(P^{-1})^T)$
Are there any holes in this logic?