## 2 Dynamic Model
### Dynamic Model without Friction
\begin{array}{cccccccccccc}x_{1}&x_{2}&x_{3}&y_{1}&y_{2}&y_{3}& \alpha_{1}&\alpha_{2}&\alpha_{3}&x&y&\theta\end{array} \big{]}^{T}, \tag{10}\]  
\[Q=\big{[} \begin{array}{cccccccccccc}Q_{x1}&Q_{x2}&Q_{x3}&Q_{y1}&Q_{y2}&Q_{y3} &Q_{\alpha 1}&Q_{\alpha 2}&Q_{\alpha 3}&Q_{x}&Q_{y}&Q_{\theta}\end{array}  \big{]}^{T}, \tag{11}\]  
where \(q\) is the vector of generalized coordinates; \(Q\) is the vector of external loads corresponding to the generalized coordinates; and \(y_{1},y_{2},\) and \(y_{3}\) denote the displacement of the sliders in the \(y\)-direction. The values of \(Q_{y1},\)\(Q_{y2},\) and \(Q_{y3}\) are zero since there is no external load exerted to the sliders in the \(y\)-direction, whereas the values of \(Q_{\alpha 1},\)\(Q_{\alpha 2},\) and \(Q_{\alpha 3}\) are zero since they correspond to passive joints. If the end effector is not subject to any external loading, \(Q_{x},\)\(Q_{y},\) and \(Q_{\theta}\) are also zero. The last term on the right-hand side of Equation (9) represents the generalized constraint forces, which can be seen as joint reaction forces. These constraint forces are the products of the Lagrange multipliers \(\lambda\) and the Jacobian of position constraints \(\Gamma\). The following nine position constraint equations are required to maintain the closed chain of the mechanism:  
\[\Gamma=\big{[} \begin{array}{cccccccc}\Gamma_{1}&\Gamma_{2}&\Gamma_{3}& \Gamma_{4}&\Gamma_{5}&\Gamma_{6}&\Gamma_{7}&\Gamma_{8}&\Gamma_{9}\end{array}  \big{]}^{T}, \tag{12}\]where:  
\[ \begin{array}{l}\Gamma_{1}=y_{1}=0,\\ \Gamma_{2}=y_{2}=0,\\ \Gamma_{3}=y_{3}=0,\\ \Gamma_{4}=x+x_{p2}\cos\theta-x_{1}-l_{1}\cos\alpha_{1}=0,\\ \Gamma_{5}=y+x_{p2}\sin\theta-l_{1}\sin\alpha_{1}=0,\\ \Gamma_{6}=x-x_{2}-l_{2}\cos\alpha_{2}=0,\\ \Gamma_{7}=y-l_{2}\sin\alpha_{2}=0,\\ \Gamma_{8}=x+x_{p3}\cos\theta-x_{3}-l_{3}\cos\alpha_{3}=0,\\ \Gamma_{9}=y+x_{p3}\sin\theta-l_{3}\sin\alpha_{3}=0.\end{array}  \tag{13}\]  
The following equations of motion can be obtained by substituting Equations (10)-(13) into Equation (9):  
\[M(q)\ddot{q}+N(q,\dot{q})=Q+B(q,t)^{T}\lambda, \tag{14}\]  
where \(M\) is the inertia matrix; \(N\) is a force vector containing the Coriolis, centrifugal, and gravitational forces; \(Q\) is the external force vector; and the last term is the constraint force vector, which maintains the closed chain of the mechanism. The system inertia matrix \(M\), vector \(N\), and matrix \(B\) depend on the mechanism posture. Although the inertia matrix of each component of the mechanism relative to either its COM or its local frame is constant, the system inertia matrix \(M\) varies with the change of the mechanism posture. The position constraint equations can be differentiated twice with respect to time, as follows:  
\[\frac{d}{dt}(B\ddot{q})=\dot{B}\dot{q}+B\ddot{q}=0. \tag{15}\]  
Finally, Equation (14) can be combined with Equation (15) to obtain a descriptor form that is presented in the following differential-algebraic equations:  
\[\left[ \begin{array}{cc}M&B^{T}\\ B&0\end{array} \right]\left[ \begin{array}{c}\ddot{q}\\ \lambda\end{array} \right]=\left[ \begin{array}{c}Q-N\\ \dot{B}\dot{q}\end{array} \right]. \tag{16}\]  
Using the coordinate partitioning, we can rewrite Equation (16) as follows:  
\[\left[ \begin{array}{ccc}M_{aa}&M_{qp}&{B_{a}}^{T}\\ M_{pa}&M_{pp}&{B_{p}}^{T}\\ B_{a}&B_{p}&0\end{array} \right]\left[ \begin{array}{c}\ddot{q}_{a}\\ \ddot{q}_{p}\\ \lambda\end{array} \right]=\left[ \begin{array}{c}Q_{a}-N_{a}\\ Q_{p}-N_{p}\\ \dot{B}\dot{q}\end{array} \right], \tag{17}\]  
where the subscripts \(a\) and \(p\) correspond to the active and passive joints, respectively.