## 3 Motion Mapping
### Construction of Human Skeleton Model and Joint Mapping: GA-LVVJ
To achieve a more similar local posture of the left upper arm relative to the left upper torso as the reference, which means that the orientation of the left upper arm link in the frame of the left upper torso link of the robot should be consistent with that in the human skeleton model, the geometrical forms of the angles of these two adjacent joints (i.e., LShoulderPitch and LShoulderRoll) should be distinguished. As illustrated in Figure 5, the angle of LShoulderPitch, \(\theta_{\text{LSP}}\), should be calculated in accordance with the angle between \(\vec{N}_{\text{1-2-5}}\) and the projection of \(\vec{V}_{\text{5-6}}\) onto the \(x\)-\(z\) plane, which is also the angle between the \(x\)-\(y\) plane and the plane formed by \(\vec{R}_{\text{LUT}}\) and \(\vec{V}_{\text{5-6}}\), i.e.,  
Figure 2.1  
To obtain \(\theta_{\text{LSP}}\), an intermediate variable \(\theta_{\text{LSP}}\) is defined as follows:  
Figure 2.2  
Then, \(\theta_{\text{LSP}}\) is obtained as  
\[\theta_{\text{LSP}}= \begin{cases}-|\theta_{\text{LSP}}|,&\text{if }\theta_{\text{LSP}}\leq \frac{\pi}{2},\\ |\theta_{\text{LSP}}|,&\text{if }\theta_{\text{LSP}}>\frac{\pi}{2}.\end{cases}  \tag{6}\]  
The angle of LShoulderRoll, \(\theta_{\text{LSR}}\), should be calculated from the angle between \(\vec{V}_{\text{5-6}}\) and the \(x\)-\(z\) plane, i.e.,  
\[\theta_{\text{LSR}}=\frac{\pi}{2}-\arccos(\frac{\vec{V}_{\text{5-6}}\cdot\vec{ R}_{\text{LUT}}}{|\vec{V}_{\text{5-6}}||\vec{R}_{\text{LUT}}|}). \tag{7}\]  
(2) Joints of Elbow_Left: The axis of LElbowYaw is collinear with the vector \(\vec{V}_{\text{6-5}}\). Because LElbowRoll is the child joint of LElbowYaw, its axis changes with the rotation of LElbowYaw and is collinear with the normal vector to Plane 5-6-7, \(\vec{N}_{\text{5-6-7}}\), which is calculated as  
\[\vec{N}_{\text{5-6-7}}=\vec{V}_{\text{6-5}}\times\vec{V}_{\text{6-7}}. \tag{8}\]  
Figure 5: The link frame of the left upper torso of the human skeleton model and the shoulder joint angles for mapping. When LelbowYaw is at its initial angle, the axis of LelbowRoll is collinear with \(\vec{N}_{\text{2-5-6}}\). As depicted in Figure 6, \(\vec{N}_{\text{2-5-6}}\) and \(\vec{V}_{\text{6-5}}\) are translated to the origin of the link frame of the left upper arm, point 6, and the \(x\)- and \(z\)-axes of the frame are set collinear with \(\vec{N}_{\text{2-5-6}}\) and \(\vec{V}_{\text{6-5}}\), respectively. Then, a reference vector \(\vec{R}_{\text{LUA}}\) is set collinear with the \(y\)-axis to complete a right-handed frame; this vector is obtained as follows:  
\[\vec{R}_{\text{LUA}}=\vec{V}_{\text{6-5}}\times\vec{N}_{\text{2-5-6}}, \tag{9}\]  
where the subscript LUA is an abbreviation for \"left upper arm\". The angles of elbow joints should be calculated in the frames of upper arm links. As shown in Figure 6, the angle of LelbowYaw, \(\theta_{\text{LEY}}\), should be calculated from the angle between the projection of \(\vec{V}_{\text{6-7}}\) onto the \(x\)-\(y\) plane and the reverse of \(\vec{R}_{\text{LUA}}\), which is also the angle between the \(y\)-\(z\) plane and the plane formed by \(\vec{V}_{\text{6-5}}\) and \(\vec{V}_{\text{6-7}}\), i.e.,  
\[|\theta_{\text{LEY}}|=\arccos(\frac{\vec{N}_{\text{2-5-6}}\cdot(\vec{V}_{\text {6-5}}\times\vec{V}_{\text{6-7}})}{|\vec{N}_{\text{2-5-6}}||\vec{V}_{\text{6-5 }}\times\vec{V}_{\text{6-7}}|}). \tag{10}\]  
To obtain \(\theta_{\text{LEY}}\), intermediate variables \(\vartheta_{\text{LEY1}}\) and \(\vartheta_{\text{LEY2}}\) are needed, i.e.,  
\[\vartheta_{\text{LEY1}}=\arccos(\frac{\vec{V}_{\text{6-7}}\cdot\vec{N}_{\text{ 2-5-6}}}{|\vec{V}_{\text{6-7}}||\vec{N}_{\text{2-5-6}}|}), \tag{11}\]  
\[\vartheta_{\text{LEY2}}=\arccos(\frac{\vec{V}_{\text{6-7}}\cdot\vec{R}_{\text {LUA}}}{|\vec{V}_{\text{6-7}}||\vec{R}_{\text{LUA}}|}). \tag{12}\]  
Then, \(\theta_{\text{LEY}}\) is  
\[\theta_{\text{LEY}}=