# Is the trace of a Lyaponov transform of a semistable matrix always nonpositive?

Let $A$ be a semistable real matrix (i.e. the real parts of all the eigenvalues of $A$ are nonnegative). Let $P$ be a positive definite matrix.

Is it always true that $\text{trace}{A^{T}P+PA} \leq 0$?

P.S. In fact, slightly more is known about $A$: that $A+A^{T}$ is negative semidefinite.

-

Here is a counterexample. Notice that $tr(A^TP)=tr(PA)$, so it suffices to calculate $tr(PA)$. Suppose $n=2$ and $A$ triangular: $$P=\begin{pmatrix} x & y \\\\ y & z \end{pmatrix},\qquad A=\begin{pmatrix} a & b \\\\ 0 & c \end{pmatrix},$$ where $x,z,xz-y^2$ positive, and $a,c\le0$. We have $tr(PA)=ax+by+cz$. Suppose that $y\ne0$. Then you may chose $b$ so that $tr(PA)>0$.