# Generalized Singularity Analysis of Snake-Like Robot
## 2 Notation
### Jacobian Matrices  
The Jacobian matrices of both the \(n\)-link snake-like robot including side-slipping and the one with non side-slipping are formulated by using (4)-(7) redundantly. First, the Jacobian matrix \(\mathbf{J}_{g}\) of the \(n\)-link snake-like robot with non side-slipping is formulated. A tangent speed \(\mathbf{q}\) is defined as:  
\[\mathbf{q}:= \begin{bmatrix}\omega_{1}&v_{x1}\end{bmatrix} ^{T}.\]  
The relative angular velocity vector \(\mathbf{\dot{\phi}}\) is defined as:  
\[\mathbf{\dot{\phi}}:= \begin{bmatrix}\dot{\phi}_{2}&\cdots&\dot{\phi}_{n}\end{bmatrix} ^ {T}.\]  
Thus, the Jacobian matrix \(\mathbf{J}_{g}\) of \(n\)-link snake-like robot with non side-slipping is formulated as follow:  
\[ \begin{aligned} \dot{\mathbf{\dot{\phi}}}=&\mathbf{J}_{g}\mathbf{q},\\ \mathbf{J}_{g}&=\begin{bmatrix}\mathbf{e}_{1}^{T}(\mathbf{A}_{2}-\mathbf{I}) \mathbf{A}_{1}\\ \mathbf{e}_{1}^{T}(\mathbf{A}_{3}-\mathbf{I})\mathbf{A}_{2}\mathbf{A}_{1}\\ \vdots\\ \mathbf{e}_{1}^{T}(\mathbf{A}_{n}-\mathbf{I})\prod_{m=1}^{n-1}\mathbf{A}_{m}\end{bmatrix} \in\mathbb{R}^{n-1\times 2},\end{aligned}  \tag{8}\]  
where, \(\mathbf{e}_{1}^{T}= \begin{bmatrix}1&0\end{bmatrix} \). Next, the Jacobian matrix \(\mathbf{J}_{s}\) of the \(n\)-link snake-like robot including side-slipping is formulated. While combinations of side-slipping exist infinite on the \(n\)-link snake-like robot, the Jacobian matrix \(\mathbf{J}_{s}\) consists of (4)-(7) due to its redundancy, since product of the kinematics formulates it. We denotes a set of non side-slipping links as:  
\[\mathbb{G} := \begin{pmatrix}g_{1},\cdots,g_{\eta}\end{pmatrix} \in\mathbb{N},\] \[\mathbb{N} := \begin{pmatrix}1,\cdots,n\end{pmatrix} .\]  
\(\mathbf{\phi}\) is decomposed into \(\mathbf{\phi}= \begin{bmatrix}\mathbf{\phi}_{s}^{T}&\mathbf{\phi}_{g}^{T}\end{bmatrix} ^ {T}\), where \(\mathbf{\phi}_{g}\) and \(\mathbf{\phi}_{s}\) are a relative angle vector of non side-slipping links and an one of side-slipping links respectively, and denoted as follows:  
\[\mathbf{\phi}_{g} :=\{\phi_{g(i)}|g(i)=\overline{\mathbb{G}\cap 1},\ g(i+1)>g(i)\},\] \[\mathbf{\phi}_{s} :=\{\phi_{s(i)}|s(i)=\overline{\mathbb{G}\cap\mathbb{N}},\ s(i+1)> s(i)\},\]where \(\dot{\phi}_{1}:=v_{y1}\), since \(\phi_{1}\) is unable to be defined as angle. Subscripts with respect to the set of non side-slipping links \(g(i)\) are denoted as follow:  
\[g(i-1):=\zeta,\qquad\qquad g(i):=\iota,\qquad\qquad g(i+1):=\kappa.\]  
The Jacobian matrix of the \(n\)-link snake-like robot including side-slipping is formulated as follows:  
\[ \begin{bmatrix}\dot{\phi}_{s}\\ \dot{\phi}_{s}\end{bmatrix}  = \begin{bmatrix}\mathbf{0}^{n-\eta\times 2}&I^{n-\eta\times n-\eta} \\ \mathbf{J}_{s}&\mathbf{*}^{\eta-1\times n-\eta}\end{bmatrix}\begin{bmatrix}\mathbf{q}\\ \dot{\mathbf{\phi}}_{s}\end{bmatrix} ,\] (9) \[\mathbf{J}_{s} =\begin{bmatrix}\mathbf{e}_{1}^{\intercal}(\mathbf{B}_{2}-\mathbf{I}  
**Theorem 1**.: _Except for \(\exists\phi_{i},\;l_{i-1}=d_{i}\cap\cos\phi_{i}=-1,\) (8) is rank deficient if and only if, \(\forall\phi_{i},\)_  
\[\left(\frac{d_{i}}{l_{i-1}}\cos\phi_{i}+1\right)\frac{1}{d_{i+1}}\sin\phi_{i+1} -\frac{1}{l_{i-1}}\sin\phi_{i}\left(\frac{l_{i}}{d_{i+1}}\cos\phi_{i+1}+1\right) =0. \tag{11}\]  
Proof. : From (8), since \(\mathbf{I}_{g}\in\mathbb{R}^{n-1\times 2}\), rank of (8) drops when \(\text{rank}\mathbf{J}_{g}<2\), and the snake-like robot poses the singular configuration. Row vectors of (8) are denoted as \(\mathbf{I}_{i}^{T}\;(i=1,\cdots,n-1)\). Since (8) possesses one independent row vector when \(\text{rank}\mathbf{J}_{g}\)=1, it can be written by using arbitrary constants \(\alpha_{i}\;(i=2,\cdots,n-1)\) as follows:  
\[\mathbf{J}_{g}= \begin{bmatrix}I_{\mathbf{1}}^{T}\\ \alpha_{2}I_{\mathbf{1}}^{T}\\ \vdots\\ \alpha_{n-1}I_{\mathbf{1}}^{T}\end{bmatrix} , \tag{12}\]  
where, \(\forall\alpha_{i}\
eq 0\).