Determinant of block matrices. $$
X = \begin{pmatrix}
1+b_1 & 1 & 0 & 0 & 0 & \frac{1}{a_{6}} \\
1+b_2 & 1 & 1 & 0 & 0 & -\frac{a_1}{a_6} \\
b_3 & 1 & 1 & 1 & 0 &  -\frac{a_2}{a_6} \\
b_4 & 0 & 1 & 1 & 1 &  -\frac{a_3}{a_6} \\
b_5 & 0 & 0 & 1 & 1 &  1-\frac{a_4}{a_6} \\
b_6 & 0 & 0 & 0 & 1 &  1-\frac{a_5}{a_6} 
\end{pmatrix}$$
The Schur complement w.r.t. the first and last row/column gives
$$S = \begin{pmatrix}
 1+b_1 & \frac{1}{a_6}\\
 b_6 & 1 - \frac{a_5}{a_6}
\end{pmatrix} 
-\begin{pmatrix} 1 & 0 & 0 & 0\\ 0 & 0 & 0 &1 \end{pmatrix} \begin{pmatrix} 1 & 1 & 0 & 0\\ 1 & 1 & 1 & 0\\ 0 &1 &1&1\\0&0&1&1 \end{pmatrix}^{-1} 
\begin{pmatrix}1+b_2 & -\frac{a_1}{a_6} \\ b_3 & -\frac{a_2}{a_6}\\ b_4 & -\frac{a_3}{a_6}\\ b_5 & 1-\frac{a_4}{a_6}\end{pmatrix}.$$
$$S = \begin{pmatrix} b_1 - b_2 + b_4 - b_5 & - \frac{-1-a_1+a_3-a_4+a_6}{a_6}\\-1-b_2+b_3-b_5+b_6 & \frac{a_1-a_2 + a_4 - a_5}{a_6}\end{pmatrix}$$
Then $\det(X) = \det\Biggr(\begin{pmatrix} 1 & 1 & 0 & 0\\ 1 & 1 & 1 & 0\\ 0 &1 &1&1\\0&0&1&1 \end{pmatrix}\Biggl). \det(S)$.
How matrix $S$ is obtained? I am not sure why and how to take the blocks here. How $S$ is derived? I can see that in matrix $M$ but how to approach it in matrix $X$?
Suppose $M = \begin{pmatrix} A & B \\ C & D\end{pmatrix}$. The Schur complement of $D
$ w.r.t $M$ is given by $M/D = A - B D^{-1} C$. It is easy to see when there are contiguous blocks. But when they are not contiguous, how we apply the formula? Like how we get matrix $S$. But I am not sure how to connect this with matrix $X$.
How matrix $X$ will be different from $Y$ below, by clubbing the blocks together the blocks used to construct matrix $S$.
$$
Y = \begin{pmatrix}
1+b_1 & \frac{1}{a_6} & 1 & 0 & 0 & 0 \\
b_6 & 1-\frac{a_5}{a_6} & 0 & 0 & 0 & 1 \\
1+b_2 & -\frac{a_1}{a_6} & 1 & 1 & 0 & 0 \\
b_3 & -\frac{a_2}{a_6} & 1 & 1 & 1 & 0 \\
b_4 & -\frac{a_3}{a_6} & 0 & 1 & 1 &  1\\
b_6 & 1-\frac{a_4}{a_6} & 0 & 0 & 1 &  1 
\end{pmatrix}$$

I think you have a partition as follows
$$ X=\left(\begin{array}{c|cccc|c}
1+b_{1} & 1 & 0 & 0 & 0 & \frac{1}{a_{6}}\\
\hline 1+b_{2} & 1 & 1 & 0 & 0 & -\frac{a_{1}}{a_{6}}\\
b_{3} & 1 & 1 & 1 & 0 & -\frac{a_{2}}{a_{6}}\\
b_{4} & 0 & 1 & 1 & 1 & -\frac{a_{3}}{a_{6}}\\
b_{5} & 0 & 0 & 1 & 1 & 1-\frac{a_{4}}{a_{6}}\\
\hline b_{6} & 0 & 0 & 0 & 1 & 1-\frac{a_{5}}{a_{6}}
\end{array}\right) $$
Consider these two projection matrics, $P$ a 6×2 matrix, and its orthogonal $Q$ a 6×4 matrix.
$$\begin{aligned}P & =\left(\begin{array}{cc}
1\\
\hline \\
\\
\\
\\
\hline  & 1
\end{array}\right) & Q & =\left(\begin{array}{cccc}
\\
\hline 1\\
 & 1\\
 &  & 1\\
 &  &  & 1\\
\hline \\
\end{array}\right)\end{aligned}$$
then you can extract the submatrices as follows
$$\begin{array}{cc}
A=P^{\top}XP & B=P^{\top}XQ\\
C=Q^{\top}XP & D=Q^{\top}XQ
\end{array}$$
The result is
$$\begin{array}{cc}
A=\begin{bmatrix}1+b_{1} & \frac{1}{a_{6}}\\
b_{6} & 1-\frac{a_{5}}{a_{6}}
\end{bmatrix} & B=\begin{bmatrix}1 & 0 & 0 & 0\\
0 & 0 & 0 & 1
\end{bmatrix}\\
C=\begin{bmatrix}1+b_{2} & -\frac{a_{1}}{a_{6}}\\
b_{3} & -\frac{a_{2}}{a_{6}}\\
b_{4} & -\frac{a_{3}}{a_{6}}\\
b_{5} & 1-\frac{a_{4}}{a_{6}}
\end{bmatrix} & D=\begin{bmatrix}1 & 1 & 0 & 0\\
1 & 1 & 1 & 0\\
0 & 1 & 1 & 1\\
0 & 0 & 1 & 1
\end{bmatrix}
\end{array}$$
and the composition of $X$ from the submatrices is
$$X=PAP^{\top}+PBQ^{\top}+QCP^{\top}+QDQ^{\top}$$
Considering the above decomposition, the Shur complement is
$$\begin{aligned}S & =A-B\,D^{-1}C\\
 & =\left(P^{\top}XP\right)-\left(P^{\top}XQ\right)\left(Q^{\top}XQ\right)^{-1}\left(Q^{\top}XP\right)\\
 & =P^{\top}\left(X-XQ\left(Q^{\top}XQ\right)^{-1}Q^{\top}X\right)P
\end{aligned}$$
Now for $Y$ the partition is contiguous I think
$$Y=\left(\begin{array}{cc|cccc}
1+b_{1} & \frac{1}{a_{6}} & 1 & 0 & 0 & 0\\
b_{6} & 1-\frac{a_{5}}{a_{6}} & 0 & 0 & 0 & 1\\
\hline 1+b_{2} & -\frac{a_{1}}{a_{6}} & 1 & 1 & 0 & 0\\
b_{3} & -\frac{a_{2}}{a_{6}} & 1 & 1 & 1 & 0\\
b_{4} & -\frac{a_{3}}{a_{6}} & 0 & 1 & 1 & 1\\
b_{6} & 1-\frac{a_{4}}{a_{6}} & 0 & 0 & 1 & 1
\end{array}\right)$$
which makes the extraction of the sub-matrices trivial.
