I have a homogeneous system of linear equations $Ax = 0$. The matrix $A$ is of size $N$. For $\det(A) = 0$, the rank of the matrix $A$ is $N - 1$. I am interested in the case $\det(A) = 0$ and want to find $x$.
The matrix $A$ is given by
\begin{equation} A = \begin{pmatrix} b & c & & & & d \\ a & b & c & & & \\ & a & b & c & & \\ & & \ddots & \ddots & \ddots & \\ & & &a & b & c \\ e & & & & a & b \end{pmatrix}, \end{equation}
with all unspecified elements equal to zero. The parameters $a, \ldots,e$ depend on some common model parameters. Thus, the system of linear equations $Ax = 0$ reads
\begin{align} b x(1) + c x(2) + d x(N) &= 0, \quad (1)\\ a x(i-1) + b x(i) + c x(i+1) &= 0, \quad i = 2,3,\ldots,N-1, \quad (2)\\ e x(1) + a x(N-1) + b x(N) &= 0. \quad (3) \end{align}
What is the approach to solving this system of equations?
My approach is the following. Substitute $x(i) = r^i$ in $(2)$ and divide by $r^{i-1}$ and find two roots that satisfy this equation and label them $r_1$ and $r_2$. Since the rank of $A$ is $N-1$ we have one free variable, which we can use to scale the eigenvector. Let us choose $x(1)$ to be the free variable. Should I now set
\begin{equation} x(i) = (c_1 r_1^{i-1} + c_2 r_2^{i-1}) x(1) \end{equation}
and find $c_1$ and $c_2$ from $(1)$ and $(3)$? However, setting $x(i)$ as above seems to make no sense for $i = 1$. What am I doing wrong?