Rank of a square matrix of order $7$. Hi, This question is related to rank of a square matrix. In case there are any additional details needed, kindly let me know.

Consider the following matrix:
$A=\begin{bmatrix}
a & b & c& d& e& f& g\\
a+1& b-1& 0 & 0 & e& 0 & g \\
a+1& 0 & c-1& 0 & e& f& 0\\
a+1& 0 & 0& d-1& 0& f & g\\
a+1& b& c& 0&  e-1& 0& 0\\
a+1& 0 & c& d& 0& f-1& 0\\
a+1& b& 0 & d& 0 &0 & g-1
\end{bmatrix}$.
Find the rank of $A$.

Since $\text{Rank}(A)=\text{Rank}(A+I)$, I considered $A+I$.
Now $A+I=\begin{bmatrix}
a+1 & b & c& d& e& f& g\\
a+1& b& 0 & 0 & e& 0 & g \\
a+1& 0 & c& 0 & e& f& 0\\
a+1& 0 & 0& d& 0& f & g\\
a+1& b& c& 0&  e& 0& 0\\
a+1& 0 & c& d& 0& f& 0\\
a+1& b& 0 & d& 0 &0 & g
\end{bmatrix}$.
Consider the row operations, $R_i\to R_i-R_1$ for $2\le i\le 7$ on $A+I$, we obtain the matrix
$B=\begin{bmatrix}
a+1 & b & c& d& e& f& g\\
0& 0& -c & -d & 0& -f & 0 \\
0& -b & 0& -d & 0& 0& -g\\
0& -b & -c& 0& -e& 0 & 0\\
0& 0& 0& -d&  0& -f& -g\\
0& -b & 0& 0& -e& 0& -g\\
0& 0& -c & 0& -e &-f & 0
\end{bmatrix}$.
Now $\text{Rank}(A)=\text{Rank}(B)$.
Also $\text{Rank}(B)=n$ if and only if $\det(B)\neq 0$.
On expanding $B$ along the first column, we get
$\det B=\det\begin{bmatrix}
a+1 & b & c& d& e& f& g\\
0& 0& -c & -d & 0& -f & 0 \\
0& -b & 0& -d & 0& 0& -g\\
0& -b & -c& 0& -e& 0 & 0\\
0& 0& 0& -d&  0& -f& -g\\
0& -b & 0& 0& -e& 0& -g\\
0& 0& -c & 0& -e &-f & 0
\end{bmatrix}
=\det\begin{bmatrix}
 0& -c & -d & 0& -f & 0 \\
 -b & 0& -d & 0& 0& -g\\
 -b & -c& 0& -e& 0 & 0\\
 0& 0& -d&  0& -f& -g\\
 -b & 0& 0& -e& 0& -g\\
 0& -c & 0& -e &-f & 0
\end{bmatrix}
$.
I am stuck here. Can someone please help me out?
I would be grateful if anyone out here can show me the next steps to anyhow calculate $\text{Rank}(A)$.
 A: What are you looking for exactly—a detailed analysis of how the rank depends on the parameters $a,b,c,d,e,f,g$? You tag your post "eigenvalues-eigenvectors". Where does the problem come from? Is there some hint that you should use eigenvalue methods? (Not that I see how that simplifies things.) Brauer Suzuki has pointed out that adding $I$ can change the rank, so you might want to revise your question, or justify why that step is valid in your context.
My suggestions:

*

*subtract row $1$ from rows $2$–$7$;

*subtract row $2$ from rows $3$–$7$ and a suitable multiple of row $2$ from row $1$.

You now have a pivot of $1$ in row $2$, column $1$. By similar means you can obtain pivots of $1$ in columns $2$, $3$, and $6$ without ever dividing by anything that might be zero. So the rank is at least $4$, no matter what values $a,b,c,d,e,f,g$ take. Deleting the rows and columns containing the pivots leaves a $3\times3$ matrix. A detailed analysis of this matrix will tell you where the rank falls between $4$ and $7$.
For example, if you want to try to minimize the rank, you can set $b=c=d$ and $e=f=g=1-b$, which makes the rank at most $5$. Then if $b\in\{\gamma,-\gamma^{-1}\}$, where $\gamma$ is the golden ratio, the rank is exactly $5$. Otherwise there is one choice of $a$ so that the rank is $4$ and the rank is $5$ for all other values of $a$. One set of parameters that gives rank $4$ is $a=-1$, $b=c=d=1$, $e=f=g=0$.
Another case: if $a=-2$ then the rank is at least $5$. To achieve rank exactly $5$, you need $g=1-c$, $f=1-b$ and $e=1-d$. Otherwise the rank is at least $6$.
Clearly you can achieve full rank, for example by setting $b=c=d=e=f=g=0$ and $a$ equal to anything nonzero. If you choose $a,b,c,d,e,f,g$ randomly, the matrix will almost certainly have full rank. I don't have the patience to do a full analysis, but this may give you some ideas.
