Given this system
$$\begin{align} \ddot{y_1} & = -y_1 + y_2 + 1 - a \\ \ddot{y_2} & = y_1 - 2 y_2 + y_3 + 1 \\ \ddot{y_3} & = y_2 - y_3 + 1 + a \\ \end{align} $$
putting this into matrix form gives $\ddot{\textbf{y}} = A \textbf{y} + \textbf{g}$ wherein $\textbf{y}, \textbf{g}$ are the appropriate $3\times1$ matrices for the system and $A$ is the corresponding coefficient matrix. One problem that I am having is that when the eigenvalues are computed ($\lambda_1 = 0 \, (\text{multiplicity of 2}), \lambda_2 = \pm i, \lambda_3 = \pm i \sqrt{3}$), one of the corresponding eigenvectors for $\lambda_1$ doesn't exist. As an illustration:
$$\left(\begin{matrix} -1 & 1 & 0 \\ 1 & -2 & 1 \\ 0 & 1 & -1 \\ \end{matrix} \right) \left(\begin{matrix} v_1 \\ v_2 \\ v_3 \\ \end{matrix} \right) = \left(\begin{matrix} 0 \\ 0 \\ 0 \end{matrix} \right)$$
gives $\textbf{v} = \left(1 \quad 1 \quad 1 \right)^T$ as the first eigenvector. Solving for the other eigenvector:
$$\left(\begin{matrix} -1 & 1 & 0 \\ 1 & -2 & 1 \\ 0 & 1 & -1 \\ \end{matrix} \right) \left(\begin{matrix} p_1 \\ p_2 \\ p_3 \\ \end{matrix} \right) = \left(\begin{matrix} 1 \\ 1 \\ 1 \end{matrix} \right)$$
Which leads to this
$$\left(\begin{matrix} -1 & 1 & 0 \\ 0 & -1 & 1 \\ 0 & 0 & 0 \\ \end{matrix} \right) \left(\begin{matrix} p_1 \\ p_2 \\ p_3 \\ \end{matrix} \right) = \left(\begin{matrix} 1 \\ 2 \\ 3 \end{matrix} \right)$$
which does not make sense. Does this mean that the second eigenvector for $\lambda_1$ does not exist? Also as an aside, after solving the homogeneous case, how do I solve for the inhomogeneous case?
Given $$\begin{align} \ddot{y_1} & = -y_1 + y_2 + 1 - a \\ \ddot{y_2} & = y_1 - 2 y_2 + y_3 + 1 \\ \ddot{y_3} & = y_2 - y_3 + 1 + a \\ \end{align} $$
Writing this as first order equations yields
$$X' = \left(\begin{matrix} x_1' \\ x_2' \\ x_3' \\ x_4' \\x_5'\\x_6' \end{matrix} \right) = AX + g = \left(\begin{matrix} 0 & 1 & 0 & 0 & 0 & 0 \\ -1 & 0 & 1 &0&0&0\\ 0 & 0 & 0 & 1 & 0 & 0 \\ 1 & 0 & -2 & 0 & 1 & 0 \\ 0 & 0 & 0 & 1 & 0 & 1 \\ 0 & 0 & 1 & 0 & -1 & 0 \end{matrix} \right) \left(\begin{matrix} x_1 \\ x_2 \\ x_3 \\ x_4 \\x_5\\x_6 \end{matrix} \right)+ \left(\begin{matrix} 0 \\ 1-a \\ 0 \\ 1 \\ 0\\1+a \end{matrix} \right)$$
The eigenvalues of $A$ are
$$\lambda_{1, 2} = \pm~i~\sqrt{3}, ~~\lambda_{3, 4} = \pm~ i, ~~\lambda_{5,6} = 0$$
We have a deficient matrix and need to find a generalized eigenvector for $\lambda = 0$. Using Wiki Example $1$ as a possible approach, we have
$$[A - \lambda I]v_6 = [A]v_6 = v_5$$
This leads to the augmented matrix $$ RREF \left(\begin{array}{rrrrrr|r} 0 & 1 & 0 & 0 & 0 & 0 & 1 \\ -1 & 0 & 1 & 0 & 0 & 0 & 0 \\ 0 & 0 & 0 & 1 & 0 & 0 & 1 \\ 1 & 0 & -2 & 0 & 1 & 0 & 0 \\ 0 & 0 & 0 & 0 & 0 & 1 & 1 \\ 0 & 0 & 1 & 0 & -1 & 0 & 0 \\ \end{array}\right) = \left( \begin{array}{rrrrrr|r} 1 & 0 & 0 & 0 & -1 & 0 & 0 \\ 0 & 1 & 0 & 0 & 0 & 0 & 1 \\ 0 & 0 & 1 & 0 & -1 & 0 & 0 \\ 0 & 0 & 0 & 1 & 0 & 0 & 1 \\ 0 & 0 & 0 & 0 & 0 & 1 & 1 \\ 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ \end{array} \right) $$
From this, we have the generalized eigenvector
$$v_6 = \left(\begin{matrix} 0 \\ 1 \\ 0 \\ 1 \\0\\1 \end{matrix} \right) $$
For the other four eigenvalues, we can use the typical methods to find linearly independent eigenvectors.
Next, to solve the nonhomogeneous system, refer to the various methods here.