# Joint Stiffness Identification Based on Robot Configuration Optimization Away from Singularities
## 4 Method for the Joint Stiffness Identification
### Method for Obtaining the Robot EE Displacement  
The joint stiffness identification procedure is shown in Figure 6. First, a robot configuration with good dexterity based on \(\kappa(J_{AW})^{-1}\) is selected. Then, the robot EE displacement values are obtained by the procedure for point cloud processing. Eventually, the values of the joint stiffness are obtained when the number of tests is reached.  
The measurement of the robot EE displacement is obtained by the EE target block displacement. The 3D scanner is used to obtain high-precision initial 3D point clouds of the surface of the target block at the end of the robot. The initial 3D point clouds need to be fitted to obtain the expression for the point cloud planes to set up the deformation coordinate system. The 3D point clouds usually contain noise points that will affect the accuracy of the deformation coordinate system. The processing of 3D point cloud data mainly includes segmentation, noise reduction, and plane fitting of the point clouds. The segmentation processing of the point clouds obtains three mutually vertical planar point clouds of YOZ, XOZ, and XOY. The noise reduction processing is to remove the noise points in the 3D point clouds. The plane fitting processing obtains the expressions of the  
Figure 6: Procedure for the joint stiffness identification.  
point cloud planes. One experiment for an illustrative example was chosen to describe the procedure for obtaining the EE displacement (see Figure 7). \(z_{1}\), \(z_{2}\), and \(z_{3}\) represent the fitted YOZ, XOZ, and XOY plane equations of the target block, respectively.  
As shown in Figure 8, the coordinate system of the target block is established. Based on the normal vectors of the fitted YOZ, XOZ, and XOY planes and the intersection of the three planes as the origin, the deformation coordinate system is established:  
\[\mathbf{O}_{i}=\begin{bmatrix}a_{i1}&a_{i2}&a_{i3}&o_{iox}\\ b_{i1}&b_{i2}&b_{i3}&o_{ioy}\\ c_{i1}&c_{i2}&c_{i3}&o_{ioz}\\ 0&0&0&1\end{bmatrix} \tag{26}\]  
where \(i=0\) means the deformation coordinate system before loading; \(i=1\) means the deformation coordinate system after loading; \(a\), \(b\), and \(c\) represent the plane normal vectors; and \(o\) indicates the intersection point (origin) of the three planes.  
The transformation matrix \(\mathbf{T}\) from \(\mathbf{O}_{0}\) to \(\mathbf{O}_{1}\) is  
\[\mathbf{T}=\mathbf{O}_{1}\mathbf{O}_{0}^{-1}=\begin{bmatrix}\mathbf{R}&\mathbf{P}\\ \mathbf{0}&\mathbf{1}\end{bmatrix} \tag{27}\]  
where  
\[\mathbf{P}=\begin{bmatrix}dx&dy&dz\end{bmatrix}^{T} \tag{28}\]  
\[\mathbf{R}(\gamma,\beta,\alpha)=\begin{bmatrix}r_{11}&r_{12}&r_{13}\\ r_{21}&r_{22}&r_{23}\\ r_{31}&r_{32}&r_{33}\end{bmatrix} \tag{29}\]  
Figure 7: Procedure for obtaining the EE displacement.  
The two-argument arc tangent function \(A\)tan2 is used to obtain the rotation angles (\(\gamma\), \(\beta\), and \(\alpha\)) of coordinate axes \(x\), \(y\), and \(z\):  
\[\mathbf{P}=\left\{\begin{array}{l}\gamma=A\tan 2(r_{32}/\cos\beta,r_{33}/\cos \beta)\\ \beta=A\tan 2\Big{(}-r_{31},\sqrt{r_{11}^{2}+r_{21}^{2}}\Big{)}\\ \alpha=A\tan 2(r_{21}/\cos\beta,r_{11}/\cos\beta)\end{array}\right. \tag{30}\]  
The robot EE deformation is obtained as follows:  
\[\delta\mathbf{d}=\begin{bmatrix}dx&dy&dz&\gamma&\beta&\alpha\end{bmatrix}^{T} \tag{31}\]