## 4 Inverse Dynamics + PD Controller  
The control of the 8 DOF robot-platform system is the coordinating movement control of the 6 DOF robot with the tool and the 2 DOF platform with the workpiece so as to ensure the tool tracking on the given form-shaping tool path in the task space. Movement of the robot system is carried out thanks to the joint driving system. The control effects are applied to the joints, so the joints are directly the control objects; the joint positions always follow to the desired positions so that the position deviations (error) are less than a specified value consistent with the required accuracy.  
The Inverse Dynamics + PD controller is the common controller, popular for industrial robots, based on the rule of inverse dynamics control combined with the outer loop linear PD control.  
Using the differential equations of motion of robot system (8), choosing the control rule as follows (27).  
\[\left[\mathrm{U}\right]=\left[\mathrm{U}\right]_{(8\times 1)}=\left[\mathrm{M }(\mathrm{q})\right]_{(8\times 8)}\mathrm{u}_{(8\times 1)}+\left[\mathrm{C}( \mathrm{q},\dot{\mathrm{q}})\dot{\mathrm{q}}\right]_{(8\times 1)}+\left[ \mathrm{G}(\mathrm{q})\right]_{(8\times 1)}+\left[\mathrm{Q}(\mathrm{q})\right]_{(8 \times 1)} \tag{27}\]  
u is the chosen control signal that has the PD structure (28).  
\[\mathrm{U}=\ddot{\mathrm{q}}_{\mathrm{d}(8\times 1)}+\mathrm{K_{v(8\times 8)} \dot{e}_{(8\times 1)}+K_{p(8\times 8)}e_{(8\times 1)}} \tag{28}\]  
In which e, e, e are the vectors that represent deviations of the joint positions, velocities and accelerations at an instant machining time (29).  
\[\left\{\begin{array}{l}\mathrm{e}=\mathrm{e}_{(8\times 1)}=\mathrm{q}_{d}- \mathrm{q}=\left[\mathrm{e}_{1},\mathrm{e}_{2},\ldots,\mathrm{e}_{8}\right]^{ \mathrm{T}}\\ \dot{\mathrm{e}}=\dot{\mathrm{e}}_{(8\times 1)}=\ddot{\mathrm{q}}_{d}-\dot{ \mathrm{q}}=\left[\dot{\mathrm{e}}_{1},\dot{\mathrm{e}}_{2},\ldots,\dot{ \mathrm{e}}_{8}\right]^{\mathrm{T}}\\ \ddot{\mathrm{e}}=\ddot{\mathrm{e}}_{(8\times 1)}=\ddot{\mathrm{q}}_{d}-\ddot{ \mathrm{q}}=\left[\ddot{\mathrm{e}}_{1},\ddot{\mathrm{e}}_{2},\ldots,\ddot{ \mathrm{e}}_{8}\right]^{\mathrm{T}}\end{array}\right. \tag{29}\]\(\mathrm{q}_{d},\dot{\mathrm{q}}_{d},\ddot{\mathrm{q}}_{d}\) are the vectors of the desired joint positions, velocities, and accelerations in accordance with the requirements of machining engineering, which are the set trajectories (7) calculated by the kinematic problem.  
\(\mathrm{q},\dot{\mathrm{q}},\ddot{\mathrm{q}}\) are the vectors of the actual joint positions, velocities, and accelerations.  
\(\mathrm{K}_{\mathrm{P}(8\times 8)}\), \(\mathrm{K}_{\mathrm{V}(8\times 8)}\) are the diagonal matrix of the proportional gain coefficients, the derivative of each separate joint corresponding to the controller, respectively, (30) and (31).  
\[\mathrm{K}_{\mathrm{P}}=\mathrm{diag}\big{[}k_{\mathrm{P}1},k_{\mathrm{P}2}, \ldots,k_{\mathrm{P}8}\big{]};k_{\mathrm{pi}}>0 \tag{30}\]  
\[\mathrm{K}_{\mathrm{V}}=\mathrm{diag}\{k_{\mathrm{V}1},k_{\mathrm{V}2}, \ldots,k_{\mathrm{V}8}\};k_{\mathrm{Vi}}>0 \tag{31}\]  
Substituting (27) and (28) into (8) we find out the erroneous differential equation of the control system (32),  
\[\big{[}\ddot{\mathrm{e}}\big{]}_{(8\times 1)}+[\mathrm{K}_{\mathrm{V}}]_{(8 \times 8)}\big{[}\dot{\mathrm{e}}\big{]}_{(8\times 1)}+\big{[}\mathrm{K}_{ \mathrm{P}}\big{]}_{(8\times 8)}\big{[}\mathrm{e}\big{]}_{(8\times 1)}=0 \tag{32}\]  
or write in a separate form of independent equations for the joints (33).  
\[\ddot{\mathrm{e}}_{\mathrm{i}}+\mathrm{K}_{\mathrm{Vi}}\dot{\mathrm{e}}_{ \mathrm{i}}+\mathrm{K}_{\mathrm{pi}}\mathrm{e}_{\mathrm{i}}=0;\ \mathrm{i}=1,\ldots,8 \tag{33}\]  
The Inverse Dynamics + PD controller model is demonstrated in Figure 3. The simulation results are shown in Section 6.