## 2 Materials and Methods
### Motion Tracking Algorithm  
In this paper, we use two nine-axis sensors (Adafruit BNO055 Absolute Orientation Sensors), as shown in the top photo of Figure 3, one on the wrist and the other on the upper arm near the elbow (marked by red circles). The bottom left photo shows that the sensor coordinates transformed to world coordinates, and the bottom right photo shows the world coordinates transformed to Unity coordinates. Once the alignment with the user's orientation is done, the Unity would show the same movement as the real person does. In the built-in microcontroller of the sensor, a world coordinate with the \(Y\)-axis facing the north pole of the geomagnetic field and the \(Z\)-axis perpendicular to the earth plane is defined, and the corresponding quaternion \(q_{t}=[\text{w},\text{x},\text{y},\text{z}]\) is generated based on this world coordinate. \(q_{t}\) represents the action of rotating the sensor from the base state to the current position, which can be further expressed as Equation (1). \[q_{t}=\left[\cos(\frac{\theta}{2}),\sin(\frac{\theta}{2})\stackrel{{ \rightarrow}}{{\text{u}}}\right] \tag{1}\]  
Figure 2: Flowchart of the presented algorithm. The physical meaning of \(v^{\prime}=qvq^{*}=qvq^{-1}\) is to rotate a certain three-dimensional vector \(\overrightarrow{v}\) around a unit vector rotation axis \(\overrightarrow{u}\) by \(\theta\) degrees into a new vector \(\overrightarrow{v}^{\prime}\), where \(\overrightarrow{v}\) is represented by the quaternion \(v=\left[0,\overrightarrow{v}\right]\), and \(\overrightarrow{v}^{\prime}\) is represented by \(v^{\prime}=\left[0,\overrightarrow{v}^{\prime}\right]\). When the quaternion at initial state, \(q^{(0)}\), is \(1+0i+0j+0k\), the object coincides with the world coordinate, which is \(\overrightarrow{v}^{\prime}=\overrightarrow{v}\). In Figure 3, the coordinates of the nine-axis sensor in the base state coincide with the world coordinates, and the attitude vectors of the upper arm and forearm \(\overrightarrow{v}^{S}_{upper}\) and \(\overrightarrow{v}^{S}_{forearm}\) align the \(X\)-axis and \(-Y\)-axis of the sensor coordinates, respectively, and can be expressed as quaternions as Equations (2) and (3). \[v^{S}_{upper}=\left[0,\overrightarrow{v}^{S}_{upper}\right]=\left(0,0,-1,0\right) \tag{2}\]  
\[v^{S}_{forearm}=\left[0,\overrightarrow{v}^{S}_{forearm}\right]=\left(0,1,0,0\right) \tag{3}\]  
The quaternions \(q_{upper}\) and \(q_{forearm}\) of the upper arm and forearm are multiplied by the arm orientation vector as in Equations (4) and (5), respectively, to obtain the quaternions \(v^{G}_{upper}\) and \(v^{G}_{forearm}\) of the arm after rotation. \[v^{G}_{upper}=q_{upper}.v^{S}_{upper}.q^{*}_{upper} \tag{4}\]  
\[v^{G}_{forearm}=q_{forearm}.v^{S}_{forearm}.q^{*}_{forearm} \tag{5}\]  
Figure 3: 3D coordinate conversion flowchart: (**top**) wearable device, (**bottom left**) sensor coordinates to world coordinates, (**bottom right**) world coordinates to Unity coordinates. where \(v^{G}_{upper}=\left[0,\overset{G}{\
abla}_{upper}^{G}\right]\), \(v^{G}_{forearm}=\left[0,\overset{G}{\
abla}_{forearm}^{G}\right]\), and the orientation vectors of the arms in the world coordinates are Equations (6) and (7). \[\overset{\
eg}{\
abla}_{upper}^{G}=\left(x^{G}_{upper},y^{G}_{upper},z^{G}_{ upper}\right) \tag{6}\]  
\[\overset{\
eg}{\
abla}_{forearm}^{G}=\left(x^{G}_{forearm},y^{G}_{forearm},z^{G}_ {forearm}\right) \tag{7}\]  
The world coordinates are transformed to the virtual Unity coordinates. In the paper, the \(Y\) and \(Z\) axes of the world coordinates are aligned to the Unity coordinates, and Equations (8) and (9) are the arm pose vectors \(\overset{\
eg}{\
abla}_{upper}^{U}\) and \(\overset{\
eg}{\
abla}_{forearm}^{U}\) in the virtual three-dimensional space (virtual Unity). \[\overset{\
eg}{\
abla}_{upper}^{U}=\left(x^{G}_{upper},z^{G}_{upper},y^{G}_{ upper}\right) \tag{8}\]  
Figure 2:0  
There is no wearable sensor on the torso, so it is not possible to determine the orientation of the model in the Unity coordinates.