Construct real matrix for given complex eigenvalues and given complex eigenvectors where algebraic multiplicity < geometric multiplicity My goal is to construct a real-valued matrix $M\in \mathbb{R}^{4\times 4} $ that has a given eigenvalue $\lambda_1 \in \mathbb{C}$ (and thus eigenvalue $\lambda_2 = \bar{\lambda}_1$) with algebraic multiplicity $s_1=2 \,$ (and thus $s_2=2$) and geometric multiplicity $m_1=1$ (and thus $m_2=1$) where the eigenvector $v_1 \in \mathbb{C}^4$ for eigenvalue $\lambda_1$ (and thus $v_2=\bar{v}_1$ for eigenvalue $\lambda_2$) is also given. My questions:


*

*Is $M$ in this case uniquely determined?

*How do I construct the matrix $M$?


My thoughts on the construction so far:


*

*The Matrix $M$ must fulfill the following conditions: 


*

*entries $m_{ij} \in \mathbb{R} \quad \forall i,j\in\{1,2,3,4\}$

*$M v_1 = \lambda_1 v_1$

*$\det(M-\lambda_1 I) = 0$

*$\operatorname{rank}(M-\lambda_1 I) = 1$


I wrote out these conditions in several equations of $m_{ij}$ and tried solving the system of (partly nonlinear) equations with MATLAB using the solve function. However, I did not manage to get a solution this way. Am I missing a condition? Should this approach generally work, implying I probably have a mistake in my MATLAB code?

*Is there a way to use the Jordan canonical form for this problem? I have read this: Constructing a matrix with given eigenvalues and given algebraic and geometric multiplicities but how do I find a generalised eigenvector when I know the eigenvector but not the matrix itself?
 A: Each Jordan block of a matrix in Jordan canonical form looks like
$$
\begin{pmatrix}
\lambda & 1\\
0 & \lambda
\end{pmatrix}
$$
where the number of Jordan blocks for a given eigenvalue is the geometric multiplicity. So we want one such Jordan block for each eigenvalue.
Thus the Jordan form for your desired matrix is
$$
\begin{pmatrix}
\lambda & 1 & 0 & 0\\
0 & \lambda & 0 & 0\\
0 & 0 & \bar{\lambda} & 1\\
0 & 0 & 0 & \bar{\lambda}\\
\end{pmatrix}.
$$
The matrix is not unique, of course, but it is unique up to similarity. This means that the matrix $M$, expressed in a basis of its generalized eigenvectors, takes the above form.
Here $v_1$ and $\bar{v_1}$ are eigenvectors with eigenvalue $\lambda,\bar{\lambda}$, respectively, while $v_2$ is a generalized eigenvalue with $Av_2=v_1+\lambda v_2,$ and complex conjugate.
Now if we want a real matrix, we just need to change to a real basis. Let $\lambda = a+bi$. Using the basis $(v_1+\bar{v_1})/2,(v_1-\bar{v_1})/2i,(v_2+\bar{v_2})/2,(v_2-\bar{v_2})/2i$, we have
$$
\begin{pmatrix}
a & b & 1 & 0\\
-b & a & 0 & 1\\
0 & 0 & a & b\\
0 & 0 & -b & a
\end{pmatrix}
$$
