<s>[INST] Riccati & Lyapunov equations We know that
Lyapunov equation: $A^TP + PA + Q = 0$
Algebraic Riccati equation: $A^TP + PA + Q + PBR^{-1}B^TP= 0$
It seems that the difference between the two lies in $B = 0$ (zero input) in Lyapunov Eq
and both are infinite horizon in the case above. 
Is there any other engineering-sense difference (not mathematics) between the two Eqs?
Thanks!
 [/INST] As mentioned in @bersou's answer, here is how to go from the continuous-time Algebraic Riccati equation $$A^T P + P A - P B R^{-1} B^T P + Q = 0$$ to the continuous-time Lyapunov equation $$(A - BK)^T P + P(A - BK) + Q = 0$$ where $A - BK$ is stable (all of its eigenvalues have negative real part):
\begin{align}
A^T P + P A - P B R^{-1} B^T P + Q &= 0 \\
A^T P + P A - \frac{1}{2}P B R^{-1} B^T P - \frac{1}{2}P B R^{-1} B^T P + Q &= 0 \\
A^T P - \frac{1}{2}P B R^{-1} B^T P + PA - \frac{1}{2}P B R^{-1} B^T P + Q &= 0 \\
\left(A^T - \frac{1}{2}PBR^{-1}B^T\right)P + P\left(A - \frac{1}{2} B R^{-1} B^T P\right) + Q &= 0
\end{align}
Let $K = \frac{1}{2}R^{-1}B^TP$. Then,
\begin{align}
\left(A^T - \frac{1}{2}PBR^{-1}B^T\right)P + P\left(A - \frac{1}{2} B R^{-1} B^T P\right) + Q &= 0 \\
\left(A^T - K^TB^T\right)P + P\left(A - B K\right) + Q &= 0 \\
\left(A - BK\right)^TP + P\left(A - B K\right) + Q &= 0
\end{align}
</s>