# Real-Time Tension Distribution Design for Cable-Driven Parallel Robot
## 2 Problem Formulation
### a Selection Condition for Convergence of the Error \(e\)  
By applying the updated law in Equation (15), the error \(e\) might be minimized when the time derivative of the desired wrench \(\tau_{d}\) is zero or very small. However, if \(\tau_{d}\) varies over time, updating \(\hat{L}\) to reflect this variation requires additional analysis and the choice of a suitable \(\alpha\). Here, the derivative of \(E\) can be formulated as follows:  
\[\hat{E}=e^{T}\hat{e}=e^{T}(A^{T}\mathtt{Tanh}(\hat{L})+A^{T}\frac{\mathsf{d}}{ \mathsf{dt}}(\mathtt{Tanh}(\hat{L}))-\hat{\tau}) \tag{17}\]  
As \(\tau=\frac{\tau_{d}-(f_{\mathtt{min}}+\lambda)\hat{L}^{T}\mathbbm{1}}{\lambda}\), \(\hat{\tau}\) can be shown as follows:  
\[\hat{\tau}=\frac{\tau_{d}-(f_{\mathtt{min}}+\lambda)\hat{A}^{T}\mathbbm{1}}{\lambda} \tag{18}\]  
We can rewrite Equation (17) as follows:  
\[ \begin{split}\dot{E}&=e^{T}(A^{T}\mathtt{Tanh}(\hat{L })+A^{T}\frac{\mathsf{d}}{\mathsf{dt}}(\mathtt{Tanh}(\hat{L}))-\frac{1}{ \lambda}\tau_{d}\\ &+\frac{1}{\lambda}(f_{\mathtt{min}}+\lambda)\hat{A}^{T}\mathbbm{1} )\end{split}  \tag{19}\]  
where  
\[ \begin{split}\dot{\tau}_{d}=&\dot{M}(-k_{p}(q-q_{d}) -k_{d}\hat{q})+C\hat{q}+\hat{C}\hat{q}+\hat{C}\hat{q}\\ &+M(-k_{p}(\hat{q}-\hat{q}_{d})-k_{d}\hat{q})\\ &\frac{\mathsf{d}}{\mathsf{dt}}(\mathtt{Tanh}(\hat{L}))=(\mathbf{U}_ {m\times m}-\mathtt{Tanh2}(\hat{L}))\dot{L}\end{split} \]  
Furthermore, by incorporating Equation (15), it can be concluded that  
\[\dot{E}=e^{T}z-\alpha d \tag{20}\]  
where  
\[ \begin{split} z&=\hat{A}^{T}\mathtt{Tanh}(\hat{L})+ \frac{1}{\lambda}((f_{\mathtt{min}}+\lambda)\hat{A}^{T}\mathbbm{1})-\frac{1}{ \lambda}(C\bar{q}+\hat{C}+\hat{C}\hat{q})\\ &-\frac{1}{\lambda}(\dot{M}(-k_{p}(q-q_{d})-k_{d}\hat{q})+M(-k_{ p}(\hat{q}-\hat{q}_{d})-k_{d}\hat{q}))\\ &\qquad\qquad\qquad\qquad d=e^{T}A^{T}H_{Tan}H_{Tan}^{T}Ae\\ & H_{Tan}=\mathbf{U}_{m\times m}-\mathtt{Tanh2}(\hat{L})\end{split}  \tag{21}\]  
\(\bar{q}\) can be calculated using \(\bar{q}=M^{-1}(A^{T}f-C\bar{q}-G)\). Thus, utilizing the dynamic and kinematic model of the robot and the sensor-measured angular position and velocities, it is possible to determine \(z\). From Equation (20), due to the fact that \(d\) is a non-negative value, we can select an appropriate \(\alpha\) to make \(\hat{E}\) negative. Here, the value of \(d\) is crucial for selecting \(\alpha\). We do not need to update \(\hat{L}\) and \(\alpha\) if \(d\) is close to zero. Proof. : When \(d\) decreases in value, each element of vector \(H_{Tan}^{T}Ae\) in tension space becomes small. It is evident that there may exist two possible explanations when \(d\) is close to zero,as each element of this vector is calculated using two variables, namely, the corresponding element of vector \(Ae\) and the diagonal element of matrix \(H_{Tun}\). On the one hand, when the control wrench tracking error \(e\) is decreased to zero and the desired control wrench is achieved, \(d\) becomes zero. On the other hand, when \(d\) is close to zero, it is possible that diagonal elements of \(H_{Tun}\) may be close to zero as well, as the corresponding elements of \(Ae\) are not zero. Due to the fact that \(H_{Tun}\) is a diagonal matrix and each diagonal element of \(H_{Tun}\) is calculated as \(1-(\mathtt{tanh}(L_{i}))^{2}\), where \(\mathtt{tanh}()\) has the upper and lower boundaries as \(1\) and \(-1\), respectively, each element of \(H_{Tun}\) becomes small. This indicates that each cable's force is sufficiently close to the limitation boundary. The tension of the cable is actually unable to maintain the appropriate tension for realizing the desired wrench. Therefore, in each of these circumstances there is no need to update \(\hat{L}\) any further. If \(d\) is large enough, \(\alpha\) can be selected provided the following conditions are met:  
\[\alpha\left\{ \begin{array}{rl}&\geqslant 0\ \ \ \ \ (\bar{E}_{r}>0)\\ &\geqslant\frac{-\bar{E}_{r}}{d}\ \ \ \ (d>\delta,\bar{E}_{r}<0)\end{array} \right.\]  
where \(\delta\) denotes a tiny positive value.