Semidefinite solutions to Lyapunov equation I'm trying to find conditions for the solution of semidefinite Lyapunov equations (actually, inequalities, but that's not the problem). I would like to know what are the conditions on $A$ for the equation
$$A^TP + PA = Q$$
with $Q = Q^T \preceq 0$ to admit a solution $P = P^T \succeq 0$. I looked through some inertia theorems from Horn and Johnsson's "Topics in Matrix Analysis", but I could only find results requiring $A$ to be nonsingular. Are there any results concerning semistable matrices $A$?
 A: You should exploit that the Sylvester matrix equation 
\begin{equation}
A X + X B^T = C
\end{equation}
is equivalent to a linear system 
\begin{equation}
(I \otimes A + B \otimes I) \text{vec}(X) = \text{vec}(C)
\end{equation}
where $\otimes$ denotes the Kronecker product $\text{vec}(C)$ is obtained by stacking the columns for $C$ on top of each other, see Horn and Johnsson's text for further information. The eigenvalues of the new coefficient matrix are of the form $\lambda_i + \mu_j$ where $\lambda_j$ is an eigenvalue for $A$ and $\mu_j$ is an eigenvalue for $B$. You verify this by bringing $A$ and $B$ to upper triangular Schur form using unitary transformations.
In the case of the Lyapunov matrix equation
\begin{equation}
A^T P +  P A = Q
\end{equation}
there is a unique solution $P$ if and only if $\lambda + \mu \not = 0$ for all eigenvalues $\lambda$ and $\mu$. In particular, if $A$ is semistable, rather than (asymptotically) stable, then the condition is violated by any purely imaginary eigenvalue $\lambda$ as $\mu = \overline{\lambda} = - \lambda$ is also an eigenvalue of $A$.
