diff --git a/figs/3dof_model_fully_parallel.pdf b/figs/3dof_model_fully_parallel.pdf new file mode 100644 index 0000000..b6607b1 Binary files /dev/null and b/figs/3dof_model_fully_parallel.pdf differ diff --git a/figs/3dof_model_fully_parallel.png b/figs/3dof_model_fully_parallel.png new file mode 100644 index 0000000..ccacca6 Binary files /dev/null and b/figs/3dof_model_fully_parallel.png differ diff --git a/figs/gravimeter_plant_schematic.pdf b/figs/gravimeter_plant_schematic.pdf new file mode 100644 index 0000000..60d3573 Binary files /dev/null and b/figs/gravimeter_plant_schematic.pdf differ diff --git a/figs/model_planar_2.pdf b/figs/model_planar_2.pdf new file mode 100644 index 0000000..edbf625 Binary files /dev/null and b/figs/model_planar_2.pdf differ diff --git a/figs/model_planar_2.png b/figs/model_planar_2.png new file mode 100644 index 0000000..7deff22 Binary files /dev/null and b/figs/model_planar_2.png differ diff --git a/figs/stewart_architecture_example.pdf b/figs/stewart_architecture_example.pdf new file mode 100644 index 0000000..ab3e103 Binary files /dev/null and b/figs/stewart_architecture_example.pdf differ diff --git a/figs/stewart_architecture_example.png b/figs/stewart_architecture_example.png new file mode 100644 index 0000000..1d81f4d Binary files /dev/null and b/figs/stewart_architecture_example.png differ diff --git a/index.html b/index.html index 140a64e..6cbde5a 100644 --- a/index.html +++ b/index.html @@ -3,7 +3,7 @@ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> - + Diagonal control using the SVD and the Jacobian Matrix @@ -39,58 +39,76 @@

Table of Contents

@@ -109,61 +127,61 @@ Then, a diagonal controller is used. These two methods are tested on two plants:

-
-

1 Gravimeter - Simscape Model

+
+

1 Gravimeter - Simscape Model

- +

-
-

1.1 Introduction

+
+

1.1 Introduction

In this part, diagonal control using both the SVD and the Jacobian matrices are applied on a gravimeter model:

    -
  • Section 1.2: the model is described and its parameters are defined.
  • -
  • Section 1.3: the plant dynamics from the actuators to the sensors is computed from a Simscape model.
  • -
  • Section 1.4: the plant is decoupled using the Jacobian matrices.
  • -
  • Section 1.5: the Singular Value Decomposition is performed on a real approximation of the plant transfer matrix and further use to decouple the system.
  • -
  • Section 1.6: the effectiveness of the decoupling is computed using the Gershorin radii
  • -
  • Section 1.7: the effectiveness of the decoupling is computed using the Relative Gain Array
  • -
  • Section 1.8: the obtained decoupled plants are compared
  • -
  • Section 1.9: the diagonal controller is developed
  • -
  • Section 1.10: the obtained closed-loop performances for the two methods are compared
  • -
  • Section 1.11: the robustness to a change of actuator position is evaluated
  • -
  • Section 1.12: the choice of the reference frame for the evaluation of the Jacobian is discussed
  • -
  • Section 1.13: the decoupling performances of SVD is evaluated for a low damped and an highly damped system
  • +
  • Section 1.2: the model is described and its parameters are defined.
  • +
  • Section 1.3: the plant dynamics from the actuators to the sensors is computed from a Simscape model.
  • +
  • Section 1.4: the plant is decoupled using the Jacobian matrices.
  • +
  • Section 1.5: the Singular Value Decomposition is performed on a real approximation of the plant transfer matrix and further use to decouple the system.
  • +
  • Section 1.6: the effectiveness of the decoupling is computed using the Gershorin radii
  • +
  • Section 1.7: the effectiveness of the decoupling is computed using the Relative Gain Array
  • +
  • Section 1.8: the obtained decoupled plants are compared
  • +
  • Section 1.9: the diagonal controller is developed
  • +
  • Section 1.10: the obtained closed-loop performances for the two methods are compared
  • +
  • Section 1.11: the robustness to a change of actuator position is evaluated
  • +
  • Section 1.12: the choice of the reference frame for the evaluation of the Jacobian is discussed
  • +
  • Section 1.13: the decoupling performances of SVD is evaluated for a low damped and an highly damped system
-
-

1.2 Gravimeter Model - Parameters

+
+

1.2 Gravimeter Model - Parameters

- +

-The model of the gravimeter is schematically shown in Figure 1. +The model of the gravimeter is schematically shown in Figure 1.

-
+

gravimeter_model.png

Figure 1: Model of the gravimeter

-
+

leg_model.png

Figure 2: Model of the struts

@@ -193,11 +211,11 @@ g = 0; % Gravity [m/s2]
-
-

1.3 System Identification

+
+

1.3 System Identification

- +

@@ -221,7 +239,7 @@ G.OutputName = {'Ax1',

-The inputs and outputs of the plant are shown in Figure 3. +The inputs and outputs of the plant are shown in Figure 3.

@@ -238,7 +256,7 @@ And 4 outputs (the two 2-DoF accelerometers): \end{equation} -

+

gravimeter_plant_schematic.png

Figure 3: Schematic of the gravimeter plant

@@ -294,11 +312,11 @@ State-space model with 4 outputs, 3 inputs, and 6 states.

-The bode plot of all elements of the plant are shown in Figure 4. +The bode plot of all elements of the plant are shown in Figure 4.

-
+

open_loop_tf.png

Figure 4: Open Loop Transfer Function from 3 Actuators to 4 Accelerometers

@@ -306,15 +324,15 @@ The bode plot of all elements of the plant are shown in Figure -

1.4 Decoupling using the Jacobian

+
+

1.4 Decoupling using the Jacobian

- +

-Consider the control architecture shown in Figure 5. +Consider the control architecture shown in Figure 5.

@@ -332,16 +350,16 @@ The Jacobian matrix \(J_{a}\) is used to compute the vertical acceleration, hori \end{equation}

-We thus define a new plant as defined in Figure 5. +We thus define a new plant as defined in Figure 5. \[ \bm{G}_x(s) = J_a^{-1} \bm{G}(s) J_{\tau}^{-T} \]

-\(\bm{G}_x(s)\) correspond to the \(3 \times 3\) transfer function matrix from forces and torques applied to the gravimeter at its center of mass to the absolute acceleration of the gravimeter’s center of mass (Figure 5). +\(\bm{G}_x(s)\) correspond to the \(3 \times 3\) transfer function matrix from forces and torques applied to the gravimeter at its center of mass to the absolute acceleration of the gravimeter’s center of mass (Figure 5).

-
+

gravimeter_decouple_jacobian.png

Figure 5: Decoupled plant \(\bm{G}_x\) using the Jacobian matrix \(J\)

@@ -379,7 +397,7 @@ State-space model with 3 outputs, 3 inputs, and 6 states.

-The diagonal and off-diagonal elements of \(G_x\) are shown in Figure 6. +The diagonal and off-diagonal elements of \(G_x\) are shown in Figure 6.

@@ -391,11 +409,11 @@ It is shown at the system is:

-The choice of the frame in this the Jacobian is evaluated is discussed in Section 1.12. +The choice of the frame in this the Jacobian is evaluated is discussed in Section 1.12.

-
+

gravimeter_jacobian_plant.png

Figure 6: Diagonal and off-diagonal elements of \(G_x\)

@@ -403,11 +421,11 @@ The choice of the frame in this the Jacobian is evaluated is discussed in Sectio
-
-

1.5 Decoupling using the SVD

+
+

1.5 Decoupling using the SVD

- +

@@ -556,11 +574,11 @@ Now, the Singular Value Decomposition of \(H_1\) is performed:

-The obtained matrices \(U\) and \(V\) are used to decouple the system as shown in Figure 7. +The obtained matrices \(U\) and \(V\) are used to decouple the system as shown in Figure 7.

-
+

gravimeter_decouple_svd.png

Figure 7: Decoupled plant \(\bm{G}_{SVD}\) using the Singular Value Decomposition

@@ -591,10 +609,10 @@ The 4th output (corresponding to the null singular value) is discarded, and we o

-The diagonal and off-diagonal elements of the “SVD” plant are shown in Figure 8. +The diagonal and off-diagonal elements of the “SVD” plant are shown in Figure 8.

-
+

gravimeter_svd_plant.png

Figure 8: Diagonal and off-diagonal elements of \(G_{svd}\)

@@ -602,11 +620,11 @@ The diagonal and off-diagonal elements of the “SVD” plant are shown
-
-

1.6 Verification of the decoupling using the “Gershgorin Radii”

+
+

1.6 Verification of the decoupling using the “Gershgorin Radii”

- +

@@ -619,7 +637,7 @@ The “Gershgorin Radii” of a matrix \(S\) is defined by:

-
+

gravimeter_gershgorin_radii.png

Figure 9: Gershgorin Radii of the Coupled and Decoupled plants

@@ -627,11 +645,11 @@ The “Gershgorin Radii” of a matrix \(S\) is defined by:
-
-

1.7 Verification of the decoupling using the “Relative Gain Array”

+
+

1.7 Verification of the decoupling using the “Relative Gain Array”

- +

@@ -645,11 +663,11 @@ where \(\times\) denotes an element by element multiplication and \(G(s)\) is an

-The obtained RGA elements are shown in Figure 10. +The obtained RGA elements are shown in Figure 10.

-
+

gravimeter_rga.png

Figure 10: Obtained norm of RGA elements for the SVD decoupled plant and the Jacobian decoupled plant

@@ -663,7 +681,7 @@ The RGA-number is also a measure of diagonal dominance: \end{equation} -
+

gravimeter_rga_num.png

Figure 11: RGA-Number for the Gravimeter

@@ -671,30 +689,30 @@ The RGA-number is also a measure of diagonal dominance:
-
-

1.8 Obtained Decoupled Plants

+
+

1.8 Obtained Decoupled Plants

- +

-The bode plot of the diagonal and off-diagonal elements of \(G_{SVD}\) are shown in Figure 12. +The bode plot of the diagonal and off-diagonal elements of \(G_{SVD}\) are shown in Figure 12.

-
+

gravimeter_decoupled_plant_svd.png

Figure 12: Decoupled Plant using SVD

-Similarly, the bode plots of the diagonal elements and off-diagonal elements of the decoupled plant \(G_x(s)\) using the Jacobian are shown in Figure 13. +Similarly, the bode plots of the diagonal elements and off-diagonal elements of the decoupled plant \(G_x(s)\) using the Jacobian are shown in Figure 13.

-
+

gravimeter_decoupled_plant_jacobian.png

Figure 13: Gravimeter Platform Plant from forces (resp. torques) applied by the legs to the acceleration (resp. angular acceleration) of the platform as well as all the coupling terms between the two (non-diagonal terms of the transfer function matrix)

@@ -702,12 +720,12 @@ Similarly, the bode plots of the diagonal elements and off-diagonal elements of
-
-

1.9 Diagonal Controller

+
+

1.9 Diagonal Controller

- -The control diagram for the centralized control is shown in Figure 14. + +The control diagram for the centralized control is shown in Figure 14.

@@ -716,19 +734,19 @@ The Jacobian is used to convert forces in the cartesian frame to forces applied

-
+

centralized_control_gravimeter.png

Figure 14: Control Diagram for the Centralized control

-The SVD control architecture is shown in Figure 15. +The SVD control architecture is shown in Figure 15. The matrices \(U\) and \(V\) are used to decoupled the plant \(G\).

-
+

svd_control_gravimeter.png

Figure 15: Control Diagram for the SVD control

@@ -764,11 +782,11 @@ U_inv = inv(U);

-The obtained diagonal elements of the loop gains are shown in Figure 16. +The obtained diagonal elements of the loop gains are shown in Figure 16.

-
+

gravimeter_comp_loop_gain_diagonal.png

Figure 16: Comparison of the diagonal elements of the loop gains for the SVD control architecture and the Jacobian one

@@ -776,11 +794,11 @@ The obtained diagonal elements of the loop gains are shown in Figure -

1.10 Closed-Loop system Performances

+
+

1.10 Closed-Loop system Performances

- +

@@ -854,18 +872,18 @@ ans =

-The obtained transmissibility in Open-loop, for the centralized control as well as for the SVD control are shown in Figure 17. +The obtained transmissibility in Open-loop, for the centralized control as well as for the SVD control are shown in Figure 17.

-
+

gravimeter_platform_simscape_cl_transmissibility.png

Figure 17: Obtained Transmissibility

-
+

gravimeter_cl_transmissibility_coupling.png

Figure 18: Obtain coupling terms of the transmissibility matrix

@@ -874,11 +892,11 @@ The obtained transmissibility in Open-loop, for the centralized control as well
-
-

1.11 Robustness to a change of actuator position

+
+

1.11 Robustness to a change of actuator position

- +

@@ -930,11 +948,11 @@ The new plant is computed, and the centralized and SVD control architectures are

-The closed-loop system are still stable in both cases, and the obtained transmissibility are equivalent as shown in Figure 19. +The closed-loop system are still stable in both cases, and the obtained transmissibility are equivalent as shown in Figure 19.

-
+

gravimeter_transmissibility_offset_act.png

Figure 19: Transmissibility for the initial CL system and when the position of actuators are changed

@@ -942,11 +960,11 @@ The closed-loop system are still stable in both cases, and the obtained transmis
-
-

1.12 Choice of the reference frame for Jacobian decoupling

+
+

1.12 Choice of the reference frame for Jacobian decoupling

- +

If we want to decouple the system at low frequency (determined by the stiffness matrix), we have to compute the Jacobian at a point where the stiffness matrix is diagonal. @@ -966,11 +984,11 @@ Ideally, we would like to have a decoupled mass matrix and stiffness matrix at t To do so, the actuators (springs) should be positioned such that the stiffness matrix is diagonal when evaluated at the CoM of the solid.

-
-

1.12.1 Decoupling of the mass matrix

+
+

1.12.1 Decoupling of the mass matrix

-
+

gravimeter_model_M.png

Figure 20: Choice of {O} such that the Mass Matrix is Diagonal

@@ -1025,7 +1043,7 @@ GM.OutputName = {'Dx', -
+

jac_decoupling_M.png

Figure 21: Diagonal and off-diagonal elements of the decoupled plant

@@ -1033,11 +1051,11 @@ GM.OutputName = {'Dx',
-
-

1.12.2 Decoupling of the stiffness matrix

+
+

1.12.2 Decoupling of the stiffness matrix

-
+

gravimeter_model_K.png

Figure 22: Choice of {O} such that the Stiffness Matrix is Diagonal

@@ -1069,7 +1087,7 @@ GK.OutputName = {'Dx', -
+

jac_decoupling_K.png

Figure 23: Diagonal and off-diagonal elements of the decoupled plant

@@ -1077,11 +1095,11 @@ GK.OutputName = {'Dx',
-
-

1.12.3 Combined decoupling of the mass and stiffness matrices

+
+

1.12.3 Combined decoupling of the mass and stiffness matrices

-
+

gravimeter_model_KM.png

Figure 24: Ideal location of the actuators such that both the mass and stiffness matrices are diagonal

@@ -1137,7 +1155,7 @@ GKM.OutputName = {'Dx', +

jac_decoupling_KM.png

Figure 25: Diagonal and off-diagonal elements of the decoupled plant

@@ -1145,8 +1163,8 @@ GKM.OutputName = {'Dx', -

1.12.4 Conclusion

+
+

1.12.4 Conclusion

Ideally, the mechanical system should be designed in order to have a decoupled stiffness matrix at the CoM of the solid. @@ -1160,11 +1178,11 @@ Or it can be decoupled at high frequency if the Jacobians are evaluated at the C

-
-

1.13 SVD decoupling performances

+
+

1.13 SVD decoupling performances

- + As the SVD is applied on a real approximation of the plant dynamics at a frequency \(\omega_0\), it is foreseen that the effectiveness of the decoupling depends on the validity of the real approximation.

@@ -1173,7 +1191,7 @@ Let’s do the SVD decoupling on a plant that is mostly real (low damping) a

-Start with small damping, the obtained diagonal and off-diagonal terms are shown in Figure 26. +Start with small damping, the obtained diagonal and off-diagonal terms are shown in Figure 26.

c = 2e1; % Actuator Damping [N/(m/s)]
@@ -1181,14 +1199,14 @@ Start with small damping, the obtained diagonal and off-diagonal terms are shown
 
-
+

gravimeter_svd_low_damping.png

Figure 26: Diagonal and off-diagonal term when decoupling with SVD on the gravimeter with small damping

-Now take a larger damping, the obtained diagonal and off-diagonal terms are shown in Figure 27. +Now take a larger damping, the obtained diagonal and off-diagonal terms are shown in Figure 27.

c = 5e2; % Actuator Damping [N/(m/s)]
@@ -1196,7 +1214,7 @@ Now take a larger damping, the obtained diagonal and off-diagonal terms are show
 
-
+

gravimeter_svd_high_damping.png

Figure 27: Diagonal and off-diagonal term when decoupling with SVD on the gravimeter with high damping

@@ -1205,15 +1223,15 @@ Now take a larger damping, the obtained diagonal and off-diagonal terms are show
-
-

2 Analytical Model

+
+

2 Analytical Model

-
-

2.1 Model

+
+

2.1 Model

-
+

gravimeter_model_analytical.png

Figure 28: Model of the gravimeter

@@ -1225,8 +1243,8 @@ Now take a larger damping, the obtained diagonal and off-diagonal terms are show
-
-

2.2 Stiffness and Mass matrices

+
+

2.2 Stiffness and Mass matrices

Stiffness matrix: @@ -1267,8 +1285,8 @@ Needs two Jacobians => complicated matrix

-
-

2.3 Equations

+
+

2.3 Equations

  • [ ] Ideally write the equation from \(\tau\) to \(\mathcal{L}\)
  • @@ -1284,8 +1302,8 @@ Needs two Jacobians => complicated matrix
-
-

2.4 Jacobians

+
+

2.4 Jacobians

Usefulness of Jacobians: @@ -1315,8 +1333,8 @@ J_{\{K\}} = \begin{bmatrix} 1 & 0 & 0 \\ 0 & 1 & -l_a \\ 0 & 1 & l_a \end{bmatri

-
-

2.5 Parameters

+
+

2.5 Parameters

l  = 1.0; % Length of the mass [m]
@@ -1340,8 +1358,8 @@ k3 = 15e3; % Actuator Stiffness [N/m]
 
-
-

2.6 Transfer function from \(\tau\) to \(\delta \mathcal{L}\)

+
+

2.6 Transfer function from \(\tau\) to \(\delta \mathcal{L}\)

Mass, Damping and Stiffness matrices expressed in \(\{M\}\): @@ -1448,8 +1466,8 @@ Kt = inv(Jm')*Km

-
-

2.7 Transfer function from \(\mathcal{F}_{\{M\}}\) to \(\mathcal{X}_{\{M\}}\)

+
+

2.7 Transfer function from \(\mathcal{F}_{\{M\}}\) to \(\mathcal{X}_{\{M\}}\)

Gm = inv(Jm)*Gt*inv(Jm');
@@ -1520,8 +1538,8 @@ Kt = inv(Jm')*Km
 
-
-

2.8 Transfer function from \(\mathcal{F}_{\{K\}}\) to \(\mathcal{X}_{\{K\}}\)

+
+

2.8 Transfer function from \(\mathcal{F}_{\{K\}}\) to \(\mathcal{X}_{\{K\}}\)

Jacobian: @@ -1614,12 +1632,12 @@ Gk = inv(Jk)*Gt*inv(

-
-

2.9 Analytical

+
+

2.9 Analytical

-
-

2.9.1 Parameters

+
+

2.9.1 Parameters

syms la ha m I c k positive
@@ -1683,14 +1701,882 @@ Kk = Jk'*Kt*Jk;
 
-
-

3 Stewart Platform - Simscape Model

+
+

3 Diagonal Stiffness Matrix for a planar manipulator

+
+
+

3.1 Model and Assumptions

+

- +Consider a parallel manipulator with: +

+
    +
  • \(b_i\): location of the joints on the top platform are called \(b_i\)
  • +
  • \(\hat{s}_i\): unit vector corresponding to the struts
  • +
  • \(k_i\): stiffness of the struts
  • +
  • \(\tau_i\): actuator forces
  • +
  • \(O_M\): center of mass of the solid body
  • +
+ +

+Consider two frames: +

+
    +
  • \(\{M\}\) with origin \(O_M\)
  • +
  • \(\{K\}\) with origin \(O_K\)
  • +
+ +

+As an example, take the system shown in Figure 29. +

+ + +
+

3dof_model_fully_parallel.png +

+

Figure 29: Example of 3DoF parallel platform

+
+
+
+ +
+

3.2 Objective

+
+

+The objective is to find conditions for the existence of a frame \(\{K\}\) in which the Stiffness matrix of the manipulator is diagonal. +If the conditions are fulfilled, a second objective is to fine the location of the frame \(\{K\}\) analytically. +

+
+
+ +
+

3.3 Conditions for Diagonal Stiffness

+
+

+The stiffness matrix in the frame \(\{K\}\) can be expressed as: +

+\begin{equation} \label{eq:stiffness_formula_planar} + K_{\{K\}} = J_{\{K\}}^T \mathcal{K} J_{\{K\}} +\end{equation} +

+where: +

+
    +
  • \(J_{\{K\}}\) is the Jacobian transformation from the struts to the frame \(\{K\}\)
  • +
  • \(\mathcal{K}\) is a diagonal matrix with the strut stiffnesses on the diagonal
  • +
+ +

+The Jacobian for a planar manipulator, evaluated in a frame \(\{K\}\), can be expressed as follows: +

+\begin{equation} \label{eq:jacobian_planar} +J_{\{K\}} = \begin{bmatrix} + {}^K\hat{s}_1^T & {}^Kb_{1,x} {}^K\hat{s}_{1,y} - {}^Kb_{1,x} {}^K\hat{s}_{1,y} \\ + {}^K\hat{s}_2^T & {}^Kb_{2,x} {}^K\hat{s}_{2,y} - {}^Kb_{2,x} {}^K\hat{s}_{2,y} \\ + \vdots & \vdots \\ + {}^K\hat{s}_n^T & {}^Kb_{n,x} {}^K\hat{s}_{n,y} - {}^Kb_{n,x} {}^K\hat{s}_{n,y} \\ +\end{bmatrix} +\end{equation} + +

+Let’s omit the mention of frame, it is assumed that vectors are expressed in frame \(\{K\}\). +It is specified otherwise. +

+ +

+Injecting \eqref{eq:jacobian_planar} into \eqref{eq:stiffness_formula_planar} yields: +

+\begin{equation} +\boxed{ +K_{\{K\}} = \left[ \begin{array}{c|c} + k_i \hat{s}_i \hat{s}_i^T & k_i \hat{s}_i (b_{i,x}\hat{s}_{i,y} - b_{i,y}\hat{s}_{i,x}) \cr + \hline + k_i \hat{s}_i (b_{i,x}\hat{s}_{i,y} - b_{i,y}\hat{s}_{i,x}) & k_i (b_{i,x}\hat{s}_{i,y} - b_{i,y}\hat{s}_{i,x})^2 +\end{array} \right] +} +\end{equation} + +

+In order to have a decoupled stiffness matrix, we have the following two conditions: +

+\begin{align} +k_i \hat{s}_i \hat{s}_i^T &= \text{diag. matrix} \label{eq:diag_cond_2D_1} \\ +k_i \hat{s}_i (b_{i,x}\hat{s}_{i,y} - b_{i,y}\hat{s}_{i,x}) &= 0 \label{eq:diag_cond_2D_2} +\end{align} + +

+Note that we don’t have any condition on the term \(k_i (b_{i,x}\hat{s}_{i,y} - b_{i,y}\hat{s}_{i,x})^2\) as it is only a scalar. +

+ +

+Condition \eqref{eq:diag_cond_2D_1}: +

+
    +
  • represents the coupling between translations and forces
  • +
  • does only depends on the orientation of the struts and the stiffnesses and not on the choice of frame
  • +
  • it is therefore a intrinsic property of the chosen geometry
  • +
+ +

+Condition \eqref{eq:diag_cond_2D_2}: +

+
    +
  • represents the coupling between forces/rotations and torques/translation
  • +
  • it does depend on the positions of the joints \(b_i\) in the frame \(\{K\}\)
  • +
+ +

+Let’s make a change of frame from the initial frame \(\{M\}\) to the frame \(\{K\}\): +

+\begin{align} +{}^Kb_i &= {}^Mb_i - {}^MO_K \\ +{}^K\hat{s}_i &= {}^M\hat{s}_i +\end{align} + +

+And the goal is to find \({}^MO_K\) such that \eqref{eq:diag_cond_2D_2} is fulfilled: +

+\begin{equation} +k_i ({}^Mb_{i,x}\hat{s}_{i,y} - {}^Mb_{i,y}\hat{s}_{i,x} - {}^MO_{K,x}\hat{s}_{i,y} + {}^MO_{K,y}\hat{s}_{i,x}) \hat{s}_i = 0 +\end{equation} +\begin{equation} +k_i ({}^Mb_{i,x}\hat{s}_{i,y} - {}^Mb_{i,y}\hat{s}_{i,x}) \hat{s}_i = {}^MO_{K,x} k_i \hat{s}_{i,y} \hat{s}_i - {}^MO_{K,y} k_i \hat{s}_{i,x} \hat{s}_i +\end{equation} + +

+And we have two sets of linear equations of two unknowns. +

+ +

+This can be easily solved by writing the equations in a matrix form: +

+\begin{equation} +\underbrace{k_i ({}^Mb_{i,x}\hat{s}_{i,y} - {}^Mb_{i,y}\hat{s}_{i,x}) \hat{s}_i}_{2 \times 1} = +\underbrace{\begin{bmatrix} +& \\ +k_i \hat{s}_{i,y} \hat{s}_i & - k_i \hat{s}_{i,x} \hat{s}_i \\ +& \\ +\end{bmatrix}}_{2 \times 2} +\underbrace{\begin{bmatrix} +{}^MO_{K,x}\\ +{}^MO_{K,y} +\end{bmatrix}}_{2 \times 1} +\end{equation} + +

+And finally, if the matrix is invertible: +

+\begin{equation} +\boxed{ +{}^MO_K = {\begin{bmatrix} +& \\ +k_i \hat{s}_{i,y} \hat{s}_i & - k_i \hat{s}_{i,x} \hat{s}_i \\ +& \\ +\end{bmatrix}}^{-1} k_i ({}^Mb_{i,x}\hat{s}_{i,y} - {}^Mb_{i,y}\hat{s}_{i,x}) \hat{s}_i +} +\end{equation} + +

+Note that a rotation of the frame \(\{K\}\) with respect to frame \(\{M\}\) would make not change on the “diagonality” of \(K_{\{K\}}\). +

+
+
+ +
+

3.4 Example 1 - Planar manipulator with 3 actuators

+
+

+Consider system of Figure 30. +

+ + +
+

3dof_model_fully_parallel.png +

+

Figure 30: Example of 3DoF parallel platform

+
+ +

+The stiffnesses \(k_i\), the joint positions \({}^Mb_i\) and joint unit vectors \({}^M\hat{s}_i\) are defined below: +

+
+
ki = [5,1,2]; % Stiffnesses [N/m]
+si = [[1;0],[0;1],[0;1]]; si = si./vecnorm(si); % Unit Vectors
+bi = [[-1;0.5],[-2;-1],[0;-1]]; % Joint's positions in frame {M}
+
+
+ +

+Let’s first verify that condition \eqref{diag_cond_2D_1} is true: +

+
+
ki.*si*si'
+
+
+ + + + +++ ++ + + + + + + + + + + + +
50
02
+ +

+Now, compute \({}^MO_K\): +

+
+
Ok = inv([sum(ki.*si(2,:).*si, 2), -sum(ki.*si(1,:).*si, 2)])*sum(ki.*(bi(1,:).*si(2,:) - bi(2,:).*si(1,:)).*si, 2);
+
+
+ +

+Let’s compute the new coordinates \({}^Kb_i\) after the change of frame: +

+
+
Kbi = bi - Ok;
+
+
+ +

+In order to verify that the new frame \(\{K\}\) indeed yields a diagonal stiffness matrix, we first compute the Jacobian \(J_{\{K\}}\): +

+
+
Jk = [si', (Kbi(1,:).*si(2,:) - Kbi(2,:).*si(1,:))'];
+
+
+ +

+And the stiffness matrix: +

+
+
K = Jk'*diag(ki)*Jk
+
+
+
+
+ +
+

3.5 Example 2 - Planar manipulator with 4 actuators

+
+

+Now consider the planar manipulator of Figure 31. +

+ + +
+

model_planar_2.png +

+

Figure 31: Planar Manipulator

+
+ +

+The stiffnesses \(k_i\), the joint positions \({}^Mb_i\) and joint unit vectors \({}^M\hat{s}_i\) are defined below: +

+
+
ki = [1,2,1,1];
+si = [[1;0],[0;1],[-1;0],[0;1]];
+si = si./vecnorm(si);
+h = 0.2;
+L = 2;
+bi = [[-L/2;h],[-L/2;-h],[L/2;h],[L/2;h]];
+
+
+ +

+Let’s first verify that condition \eqref{diag_cond_2D_1} is true: +

+
+
ki.*si*si'
+
+
+ + + + +++ ++ + + + + + + + + + + + +
20
03
+ +

+Now, compute \({}^MO_K\): +

+
+
Ok = inv([sum(ki.*si(2,:).*si, 2), -sum(ki.*si(1,:).*si, 2)])*sum(ki.*(bi(1,:).*si(2,:) - bi(2,:).*si(1,:)).*si, 2);
+
+
+ +

+Let’s compute the new coordinates \({}^Kb_i\) after the change of frame: +

+
+
Kbi = bi - Ok;
+
+
+ +

+In order to verify that the new frame \(\{K\}\) indeed yields a diagonal stiffness matrix, we first compute the Jacobian \(J_{\{K\}}\): +

+
+
Jk = [si', (Kbi(1,:).*si(2,:) - Kbi(2,:).*si(1,:))'];
+
+
+ +

+And the stiffness matrix: +

+
+
K = Jk'*diag(ki)*Jk
+
+
+
+
+
+ +
+

4 Diagonal Stiffness Matrix for a general parallel manipulator

+
+
+
+

4.1 Model and Assumptions

+
+

+Let’s consider a 6dof parallel manipulator with: +

+
    +
  • \(b_i\): location of the joints on the top platform are called \(b_i\)
  • +
  • \(\hat{s}_i\): unit vector corresponding to the struts
  • +
  • \(k_i\): stiffness of the struts
  • +
  • \(\tau_i\): actuator forces
  • +
  • \(O_M\): center of mass of the solid body
  • +
+ +

+Consider two frames: +

+
    +
  • \(\{M\}\) with origin \(O_M\)
  • +
  • \(\{K\}\) with origin \(O_K\)
  • +
+ +

+An example is shown in Figure 32. +

+ + +
+

stewart_architecture_example.png +

+

Figure 32: Parallel manipulator Example

+
+
+
+ +
+

4.2 Objective

+
+

+The objective is to find conditions for the existence of a frame \(\{K\}\) in which the Stiffness matrix of the manipulator is diagonal. +If the conditions are fulfilled, a second objective is to fine the location of the frame \(\{K\}\) analytically. +

+
+
+ +
+

4.3 Analytical formula of the stiffness matrix

+
+

+For a fully parallel manipulator, the stiffness matrix \(K_{\{K\}}\) expressed in a frame \(\{K\}\) is: +

+\begin{equation} + K_{\{K\}} = J_{\{K\}}^T \mathcal{K} J_{\{K\}} +\end{equation} +

+where: +

+
    +
  • \(K_{\{K\}}\) is the Jacobian transformation from the struts to the frame \(\{K\}\)
  • +
  • \(\mathcal{K}\) is a diagonal matrix with the strut stiffnesses on the diagonal
  • +
+ +

+The analytical expression of \(J_{\{K\}}\) is: +

+\begin{equation} +J_{\{K\}} = \begin{bmatrix} + {}^K\hat{s}_1^T & ({}^Kb_1 \times {}^K\hat{s}_1)^T \\ + {}^K\hat{s}_2^T & ({}^Kb_2 \times {}^K\hat{s}_2)^T \\ + \vdots & \vdots \\ + {}^K\hat{s}_n^T & ({}^Kb_n \times {}^K\hat{s}_n)^T +\end{bmatrix} +\end{equation} + +

+To simplify, we ignore the superscript \(K\) and we assume that all vectors / positions are expressed in this frame \(\{K\}\). +Otherwise, it is explicitly written. +

+ +

+Let’s now write the analytical expressing of the stiffness matrix \(K_{\{K\}}\): +

+\begin{equation} +K_{\{K\}} = \begin{bmatrix} + \hat{s}_1 & \dots & \hat{s}_n \\ + (b_1 \times \hat{s}_1) & \dots & (b_n \times \hat{s}_n) +\end{bmatrix} +\begin{bmatrix} + k_1 & & \\ + & \ddots & \\ + & & k_n +\end{bmatrix} +\begin{bmatrix} + \hat{s}_1^T & (b_1 \times \hat{s}_1)^T \\ + \hat{s}_2^T & (b_2 \times \hat{s}_2)^T \\ + \vdots & \dots \\ + \hat{s}_n^T & (b_n \times \hat{s}_n)^T +\end{bmatrix} +\end{equation} + +

+And we finally obtain: +

+\begin{equation} +\boxed{ +K_{\{K\}} = \left[ \begin{array}{c|c} + k_i \hat{s}_i \hat{s}_i^T & k_i \hat{s}_i (b_i \times \hat{s}_i)^T \cr + \hline + k_i \hat{s}_i (b_i \times \hat{s}_i)^T & k_i (b_i \times \hat{s}_i) (b_i \times \hat{s}_i)^T +\end{array} \right] +} +\end{equation} + +

+We want the stiffness matrix to be diagonal, therefore, we have the following conditions: +

+\begin{align} +k_i \hat{s}_i \hat{s}_i^T &= \text{diag. matrix} \label{eq:diag_cond_1} \\ +k_i (b_i \times \hat{s}_i) (b_i \times \hat{s}_i)^T &= \text{diag. matrix} \label{eq:diag_cond_2} \\ +k_i \hat{s}_i (b_i \times \hat{s}_i)^T &= 0 \label{eq:diag_cond_3} +\end{align} + +

+Note that: +

+
    +
  • condition \eqref{eq:diag_cond_1} corresponds to coupling between forces applied on \(O_K\) to translations of the payload. +It does not depend on the choice of \(\{K\}\), it only depends on the orientation of the struts and the stiffnesses. +It is therefore an intrinsic property of the manipulator.
  • +
  • condition \eqref{eq:diag_cond_2} corresponds to the coupling between forces applied on \(O_K\) and rotation of the payload. +Similarly, it does also correspond to the coupling between torques applied on \(O_K\) to translations of the payload.
  • +
  • condition \eqref{eq:diag_cond_3} corresponds to the coupling between torques applied on \(O_K\) to rotation of the payload.
  • +
  • conditions \eqref{eq:diag_cond_2} and \eqref{eq:diag_cond_3} do depend on the positions \({}^Kb_i\) and therefore depend on the choice of \(\{K\}\).
  • +
+ +

+Note that if we find a frame \(\{K\}\) in which the stiffness matrix \(K_{\{K\}}\) is diagonal, it will still be diagonal for any rotation of the frame \(\{K\}\). +Therefore, we here suppose that the frame \(\{K\}\) is aligned with the initial frame \(\{M\}\). +

+ +

+Let’s make a change of frame from the initial frame \(\{M\}\) to the frame \(\{K\}\): +

+\begin{align} +{}^Kb_i &= {}^Mb_i - {}^MO_K \\ +{}^K\hat{s}_i &= {}^M\hat{s}_i +\end{align} + +

+The goal is to find \({}^MO_K\) such that conditions \eqref{eq:diag_cond_2} and \eqref{eq:diag_cond_3} are fulfilled. +

+ +

+Let’s first solve equation \eqref{eq:diag_cond_3} that corresponds to the coupling between forces and rotations: +

+\begin{equation} +k_i \hat{s}_i (({}^Mb_i - {}^MO_K) \times \hat{s}_i)^T = 0 +\end{equation} + +

+Taking the transpose and re-arranging: +

+\begin{equation} +k_i ({}^Mb_i \times \hat{s}_i) \hat{s}_i^T = k_i ({}^MO_K \times \hat{s}_i) \hat{s}_i^T +\end{equation} + +

+As the vector cross product also can be expressed as the product of a skew-symmetric matrix and a vector, we obtain: +

+\begin{equation} +k_i ({}^Mb_i \times \hat{s}_i) \hat{s}_i^T = {}^M\bm{O}_{K} ( k_i \hat{s}_i \hat{s}_i^T ) +\end{equation} + +

+with: +

+\begin{equation} \label{eq:skew_symmetric_cross_product} +{}^M\bm{O}_K = \begin{bmatrix} +0 & -{}^MO_{K,z} & {}^MO_{K,y} \\ +{}^MO_{K,z} & 0 & -{}^MO_{K,x} \\ +-{}^MO_{K,y} & {}^MO_{K,x} & 0 +\end{bmatrix} +\end{equation} + +

+We suppose \(k_i \hat{s}_i \hat{s}_i^T\) invertible as it is diagonal from \eqref{eq:diag_cond_1}. +

+ +

+And finally, we find: +

+\begin{equation} +\boxed{ +{}^M\bm{O}_{K} = \left( k_i ({}^Mb_i \times \hat{s}_i) \hat{s}_i^T\right) \cdot {\left( k_i \hat{s}_i \hat{s}_i^T \right)}^{-1} +} +\end{equation} + +

+If the obtained \({}^M\bm{O}_{K}\) is a skew-symmetric matrix, we can easily determine the corresponding vector \({}^MO_K\) from \eqref{eq:skew_symmetric_cross_product}. +

+ +

+In such case, condition \eqref{eq:diag_cond_2} is fulfilled and there is no coupling between translations and rotations in the frame \(\{K\}\). +

+ +

+Then, we can only verify if condition \eqref{eq:diag_cond_3} is verified or not. +

+ +
+

+If there is no frame \(\{K\}\) such that conditions \eqref{eq:diag_cond_2} and \eqref{eq:diag_cond_3} are valid, it would be interesting to be able to determine the frame \(\{K\}\) in which is coupling is minimal. +

+ +
+
+
+ +
+

4.4 Example 1 - 6DoF manipulator (3D)

+
+

+Let’s define the geometry of the manipulator (\({}^Mb_i\), \({}^Ms_i\) and \(k_i\)): +

+
+
ki = [2,2,1,1,3,3,1,1,1,1,2,2];
+si = [[-1;0;0],[-1;0;0],[-1;0;0],[-1;0;0],[0;0;1],[0;0;1],[0;0;1],[0;0;1],[0;-1;0],[0;-1;0],[0;-1;0],[0;-1;0]];
+bi = [[1;-1;1],[1;1;-1],[1;1;1],[1;-1;-1],[1;-1;-1],[-1;1;-1],[1;1;-1],[-1;-1;-1],[1;1;-1],[-1;1;1],[-1;1;-1],[1;1;1]]-[0;2;-1];
+
+
+ +

+Cond 1: +

+
+
ki.*si*si'
+
+
+ + + + +++ ++ ++ + + + + + + + + + + + + + + + + + + + +
600
060
008
+ +

+Find Ok +

+
+
OkX = (ki.*cross(bi, si)*si')/(ki.*si*si');
+
+if all(diag(OkX) == 0) && all(all((OkX + OkX') == 0))
+    disp('OkX is skew symmetric')
+    Ok = [OkX(3,2);OkX(1,3);OkX(2,1)]
+else
+    error('OkX is *not* skew symmetric')
+end
+
+
+ + + + +++ + + + + + + + + + + + + + +
0
-2
1
+ +
+
% Verification of second condition
+si*cross(bi-Ok, si)'
+
+
+ + + + +++ ++ ++ + + + + + + + + + + + + + + + + + + + +
000
000
000
+ +

+Verification of third condition +

+
+
ki.*cross(bi-Ok, si)*cross(bi-Ok, si)'
+
+
+ + + + +++ ++ ++ + + + + + + + + + + + + + + + + + + + +
144-2
4142
-2212
+ +

+Let’s compute the Jacobian: +

+
+
Jk = [si', cross(bi - Ok, si)'];
+
+
+ +

+And the stiffness matrix: +

+
+
Jk'*diag(ki)*Jk
+
+
+ + + + +++ ++ ++ ++ ++ ++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
600000
060000
008000
000144-2
0004142
000-2212
+ +
+
figure;
+hold on;
+set(gca,'ColorOrderIndex',1)
+plot(b1(1), b1(2), 'o');
+set(gca,'ColorOrderIndex',2)
+plot(b2(1), b2(2), 'o');
+set(gca,'ColorOrderIndex',3)
+plot(b3(1), b3(2), 'o');
+set(gca,'ColorOrderIndex',1)
+quiver(b1(1),b1(2),0.1*s1(1),0.1*s1(2))
+set(gca,'ColorOrderIndex',2)
+quiver(b2(1),b2(2),0.1*s2(1),0.1*s2(2))
+set(gca,'ColorOrderIndex',3)
+quiver(b3(1),b3(2),0.1*s3(1),0.1*s3(2))
+
+plot(0, 0, 'ko');
+quiver([0,0],[0,0],[0.1,0],[0,0.1], 'k')
+
+plot(Ok(1), Ok(2), 'ro');
+quiver([Ok(1),Ok(1)],[Ok(2),Ok(2)],[0.1,0],[0,0.1], 'r')
+
+hold off;
+axis equal;
+
+
+
+
+ +
+

4.5 Example 2 - Stewart Platform

+
+
+
+

5 Stewart Platform - Simscape Model

+
+

+

-In this analysis, we wish to applied SVD control to the Stewart Platform shown in Figure 29. +In this analysis, we wish to applied SVD control to the Stewart Platform shown in Figure 33.

@@ -1703,33 +2589,33 @@ Some notes about the system: -

+

SP_assembly.png

-

Figure 29: Stewart Platform CAD View

+

Figure 33: Stewart Platform CAD View

The analysis of the SVD/Jacobian control applied to the Stewart platform is performed in the following sections:

    -
  • Section 3.1: The parameters of the Simscape model of the Stewart platform are defined
  • -
  • Section 3.2: The plant is identified from the Simscape model and the system coupling is shown
  • -
  • Section 3.3: The plant is first decoupled using the Jacobian
  • -
  • Section 3.4: The decoupling is performed thanks to the SVD. To do so a real approximation of the plant is computed.
  • -
  • Section 3.5: The effectiveness of the decoupling with the Jacobian and SVD are compared using the Gershorin Radii
  • -
  • Section 3.6:
  • -
  • Section 3.7: The dynamics of the decoupled plants are shown
  • -
  • Section 3.8: A diagonal controller is defined to control the decoupled plant
  • -
  • Section 3.9: Finally, the closed loop system properties are studied
  • +
  • Section 5.1: The parameters of the Simscape model of the Stewart platform are defined
  • +
  • Section 5.2: The plant is identified from the Simscape model and the system coupling is shown
  • +
  • Section 5.3: The plant is first decoupled using the Jacobian
  • +
  • Section 5.4: The decoupling is performed thanks to the SVD. To do so a real approximation of the plant is computed.
  • +
  • Section 5.5: The effectiveness of the decoupling with the Jacobian and SVD are compared using the Gershorin Radii
  • +
  • Section 5.6:
  • +
  • Section 5.7: The dynamics of the decoupled plants are shown
  • +
  • Section 5.8: A diagonal controller is defined to control the decoupled plant
  • +
  • Section 5.9: Finally, the closed loop system properties are studied
-
-

3.1 Simscape Model - Parameters

-
+
+

5.1 Simscape Model - Parameters

+

- +

open('drone_platform.slx');
@@ -1785,30 +2671,30 @@ Kc = tf(zeros(6));
 
-
+

stewart_simscape.png

-

Figure 30: General view of the Simscape Model

+

Figure 34: General view of the Simscape Model

-
+

stewart_platform_details.png

-

Figure 31: Simscape model of the Stewart platform

+

Figure 35: Simscape model of the Stewart platform

-
-

3.2 Identification of the plant

-
+
+

5.2 Identification of the plant

+

- +

-The plant shown in Figure 32 is identified from the Simscape model. +The plant shown in Figure 36 is identified from the Simscape model.

@@ -1824,10 +2710,10 @@ The outputs are the 6 accelerations measured by the inertial unit.

-
+

stewart_platform_plant.png

-

Figure 32: Considered plant \(\bm{G} = \begin{bmatrix}G_d\\G_u\end{bmatrix}\). \(D_w\) is the translation/rotation of the support, \(\tau\) the actuator forces, \(a\) the acceleration/angular acceleration of the top platform

+

Figure 36: Considered plant \(\bm{G} = \begin{bmatrix}G_d\\G_u\end{bmatrix}\). \(D_w\) is the translation/rotation of the support, \(\tau\) the actuator forces, \(a\) the acceleration/angular acceleration of the top platform

@@ -1866,7 +2752,7 @@ State-space model with 6 outputs, 12 inputs, and 24 states.

-The elements of the transfer matrix \(\bm{G}\) corresponding to the transfer function from actuator forces \(\tau\) to the measured acceleration \(a\) are shown in Figure 33. +The elements of the transfer matrix \(\bm{G}\) corresponding to the transfer function from actuator forces \(\tau\) to the measured acceleration \(a\) are shown in Figure 37.

@@ -1874,20 +2760,20 @@ One can easily see that the system is strongly coupled.

-
+

stewart_platform_coupled_plant.png

-

Figure 33: Magnitude of all 36 elements of the transfer function matrix \(G_u\)

+

Figure 37: Magnitude of all 36 elements of the transfer function matrix \(G_u\)

-
-

3.3 Decoupling using the Jacobian

-
+
+

5.3 Decoupling using the Jacobian

+

- -Consider the control architecture shown in Figure 34. + +Consider the control architecture shown in Figure 38. The Jacobian matrix is used to transform forces/torques applied on the top platform to the equivalent forces applied by each actuator.

@@ -1969,10 +2855,10 @@ The Jacobian matrix is computed from the geometry of the platform (position and -
+

plant_decouple_jacobian.png

-

Figure 34: Decoupled plant \(\bm{G}_x\) using the Jacobian matrix \(J\)

+

Figure 38: Decoupled plant \(\bm{G}_x\) using the Jacobian matrix \(J\)

@@ -1992,11 +2878,11 @@ Gx.InputName = {'Fx',

-
-

3.4 Decoupling using the SVD

-
+
+

5.4 Decoupling using the SVD

+

- +

@@ -2332,14 +3218,14 @@ Now, the Singular Value Decomposition of \(H_1\) is performed:

-The obtained matrices \(U\) and \(V\) are used to decouple the system as shown in Figure 35. +The obtained matrices \(U\) and \(V\) are used to decouple the system as shown in Figure 39.

-
+

plant_decouple_svd.png

-

Figure 35: Decoupled plant \(\bm{G}_{SVD}\) using the Singular Value Decomposition

+

Figure 39: Decoupled plant \(\bm{G}_{SVD}\) using the Singular Value Decomposition

@@ -2354,11 +3240,11 @@ The decoupled plant is then:

-
-

3.5 Verification of the decoupling using the “Gershgorin Radii”

-
+
+

5.5 Verification of the decoupling using the “Gershgorin Radii”

+

- +

@@ -2374,19 +3260,19 @@ The “Gershgorin Radii” of a matrix \(S\) is defined by: This is computed over the following frequencies.

-
+

simscape_model_gershgorin_radii.png

-

Figure 36: Gershgorin Radii of the Coupled and Decoupled plants

+

Figure 40: Gershgorin Radii of the Coupled and Decoupled plants

-
-

3.6 Verification of the decoupling using the “Relative Gain Array”

-
+
+

5.6 Verification of the decoupling using the “Relative Gain Array”

+

- +

@@ -2400,55 +3286,55 @@ where \(\times\) denotes an element by element multiplication and \(G(s)\) is an

-The obtained RGA elements are shown in Figure 37. +The obtained RGA elements are shown in Figure 41.

-
+

simscape_model_rga.png

-

Figure 37: Obtained norm of RGA elements for the SVD decoupled plant and the Jacobian decoupled plant

+

Figure 41: Obtained norm of RGA elements for the SVD decoupled plant and the Jacobian decoupled plant

-
-

3.7 Obtained Decoupled Plants

-
+
+

5.7 Obtained Decoupled Plants

+

- +

-The bode plot of the diagonal and off-diagonal elements of \(G_{SVD}\) are shown in Figure 38. +The bode plot of the diagonal and off-diagonal elements of \(G_{SVD}\) are shown in Figure 42.

-
+

simscape_model_decoupled_plant_svd.png

-

Figure 38: Decoupled Plant using SVD

+

Figure 42: Decoupled Plant using SVD

-Similarly, the bode plots of the diagonal elements and off-diagonal elements of the decoupled plant \(G_x(s)\) using the Jacobian are shown in Figure 39. +Similarly, the bode plots of the diagonal elements and off-diagonal elements of the decoupled plant \(G_x(s)\) using the Jacobian are shown in Figure 43.

-
+

simscape_model_decoupled_plant_jacobian.png

-

Figure 39: Stewart Platform Plant from forces (resp. torques) applied by the legs to the acceleration (resp. angular acceleration) of the platform as well as all the coupling terms between the two (non-diagonal terms of the transfer function matrix)

+

Figure 43: Stewart Platform Plant from forces (resp. torques) applied by the legs to the acceleration (resp. angular acceleration) of the platform as well as all the coupling terms between the two (non-diagonal terms of the transfer function matrix)

-
-

3.8 Diagonal Controller

-
+
+

5.8 Diagonal Controller

+

- -The control diagram for the centralized control is shown in Figure 40. + +The control diagram for the centralized control is shown in Figure 44.

@@ -2457,22 +3343,22 @@ The Jacobian is used to convert forces in the cartesian frame to forces applied

-
+

centralized_control.png

-

Figure 40: Control Diagram for the Centralized control

+

Figure 44: Control Diagram for the Centralized control

-The SVD control architecture is shown in Figure 41. +The SVD control architecture is shown in Figure 45. The matrices \(U\) and \(V\) are used to decoupled the plant \(G\).

-
+

svd_control.png

-

Figure 41: Control Diagram for the SVD control

+

Figure 45: Control Diagram for the SVD control

@@ -2506,23 +3392,23 @@ G_svd = feedback(G, inv(V')

-The obtained diagonal elements of the loop gains are shown in Figure 42. +The obtained diagonal elements of the loop gains are shown in Figure 46.

-
+

stewart_comp_loop_gain_diagonal.png

-

Figure 42: Comparison of the diagonal elements of the loop gains for the SVD control architecture and the Jacobian one

+

Figure 46: Comparison of the diagonal elements of the loop gains for the SVD control architecture and the Jacobian one

-
-

3.9 Closed-Loop system Performances

-
+
+

5.9 Closed-Loop system Performances

+

- +

@@ -2553,14 +3439,14 @@ ans =

-The obtained transmissibility in Open-loop, for the centralized control as well as for the SVD control are shown in Figure 43. +The obtained transmissibility in Open-loop, for the centralized control as well as for the SVD control are shown in Figure 47.

-
+

stewart_platform_simscape_cl_transmissibility.png

-

Figure 43: Obtained Transmissibility

+

Figure 47: Obtained Transmissibility

@@ -2568,7 +3454,7 @@ The obtained transmissibility in Open-loop, for the centralized control as well

Author: Dehaeze Thomas

-

Created: 2021-01-25 lun. 11:44

+

Created: 2021-02-05 ven. 13:54

diff --git a/index.org b/index.org index 49af4ca..82b910f 100644 --- a/index.org +++ b/index.org @@ -1897,6 +1897,540 @@ Kk = Jk'*Kt*Jk; #+RESULTS: \begin{equation} M_{\{K\}} = \left(\begin{array}{ccc} k & 0 & 0\\ 0 & 2\,k & 0\\ 0 & 0 & k\,\left(-{\mathrm{ha}}^2+\mathrm{ha}+2\,\mathrm{la}\right) \end{array}\right)\end{equation} +* Diagonal Stiffness Matrix for a planar manipulator +** Model and Assumptions +Consider a parallel manipulator with: +- $b_i$: location of the joints on the top platform are called $b_i$ +- $\hat{s}_i$: unit vector corresponding to the struts +- $k_i$: stiffness of the struts +- $\tau_i$: actuator forces +- $O_M$: center of mass of the solid body + +Consider two frames: +- $\{M\}$ with origin $O_M$ +- $\{K\}$ with origin $O_K$ + +As an example, take the system shown in Figure [[fig:3dof_model_fully_parallel]]. + +#+name: fig:3dof_model_fully_parallel +#+caption: Example of 3DoF parallel platform +[[file:figs/3dof_model_fully_parallel.png]] + +** Objective + +The objective is to find conditions for the existence of a frame $\{K\}$ in which the Stiffness matrix of the manipulator is diagonal. +If the conditions are fulfilled, a second objective is to fine the location of the frame $\{K\}$ analytically. + +** Conditions for Diagonal Stiffness +The stiffness matrix in the frame $\{K\}$ can be expressed as: +\begin{equation} \label{eq:stiffness_formula_planar} + K_{\{K\}} = J_{\{K\}}^T \mathcal{K} J_{\{K\}} +\end{equation} +where: +- $J_{\{K\}}$ is the Jacobian transformation from the struts to the frame $\{K\}$ +- $\mathcal{K}$ is a diagonal matrix with the strut stiffnesses on the diagonal + +The Jacobian for a planar manipulator, evaluated in a frame $\{K\}$, can be expressed as follows: +\begin{equation} \label{eq:jacobian_planar} +J_{\{K\}} = \begin{bmatrix} + {}^K\hat{s}_1^T & {}^Kb_{1,x} {}^K\hat{s}_{1,y} - {}^Kb_{1,x} {}^K\hat{s}_{1,y} \\ + {}^K\hat{s}_2^T & {}^Kb_{2,x} {}^K\hat{s}_{2,y} - {}^Kb_{2,x} {}^K\hat{s}_{2,y} \\ + \vdots & \vdots \\ + {}^K\hat{s}_n^T & {}^Kb_{n,x} {}^K\hat{s}_{n,y} - {}^Kb_{n,x} {}^K\hat{s}_{n,y} \\ +\end{bmatrix} +\end{equation} + +Let's omit the mention of frame, it is assumed that vectors are expressed in frame $\{K\}$. +It is specified otherwise. + +Injecting eqref:eq:jacobian_planar into eqref:eq:stiffness_formula_planar yields: +\begin{equation} +\boxed{ +K_{\{K\}} = \left[ \begin{array}{c|c} + k_i \hat{s}_i \hat{s}_i^T & k_i \hat{s}_i (b_{i,x}\hat{s}_{i,y} - b_{i,y}\hat{s}_{i,x}) \cr + \hline + k_i \hat{s}_i (b_{i,x}\hat{s}_{i,y} - b_{i,y}\hat{s}_{i,x}) & k_i (b_{i,x}\hat{s}_{i,y} - b_{i,y}\hat{s}_{i,x})^2 +\end{array} \right] +} +\end{equation} + +In order to have a decoupled stiffness matrix, we have the following two conditions: +\begin{align} +k_i \hat{s}_i \hat{s}_i^T &= \text{diag. matrix} \label{eq:diag_cond_2D_1} \\ +k_i \hat{s}_i (b_{i,x}\hat{s}_{i,y} - b_{i,y}\hat{s}_{i,x}) &= 0 \label{eq:diag_cond_2D_2} +\end{align} + +Note that we don't have any condition on the term $k_i (b_{i,x}\hat{s}_{i,y} - b_{i,y}\hat{s}_{i,x})^2$ as it is only a scalar. + +Condition eqref:eq:diag_cond_2D_1: +- represents the coupling between translations and forces +- does only depends on the orientation of the struts and the stiffnesses and not on the choice of frame +- it is therefore a intrinsic property of the chosen geometry + +Condition eqref:eq:diag_cond_2D_2: +- represents the coupling between forces/rotations and torques/translation +- it does depend on the positions of the joints $b_i$ in the frame $\{K\}$ + +Let's make a change of frame from the initial frame $\{M\}$ to the frame $\{K\}$: +\begin{align} +{}^Kb_i &= {}^Mb_i - {}^MO_K \\ +{}^K\hat{s}_i &= {}^M\hat{s}_i +\end{align} + +And the goal is to find ${}^MO_K$ such that eqref:eq:diag_cond_2D_2 is fulfilled: +\begin{equation} +k_i ({}^Mb_{i,x}\hat{s}_{i,y} - {}^Mb_{i,y}\hat{s}_{i,x} - {}^MO_{K,x}\hat{s}_{i,y} + {}^MO_{K,y}\hat{s}_{i,x}) \hat{s}_i = 0 +\end{equation} +\begin{equation} +k_i ({}^Mb_{i,x}\hat{s}_{i,y} - {}^Mb_{i,y}\hat{s}_{i,x}) \hat{s}_i = {}^MO_{K,x} k_i \hat{s}_{i,y} \hat{s}_i - {}^MO_{K,y} k_i \hat{s}_{i,x} \hat{s}_i +\end{equation} + +And we have two sets of linear equations of two unknowns. + +This can be easily solved by writing the equations in a matrix form: +\begin{equation} +\underbrace{k_i ({}^Mb_{i,x}\hat{s}_{i,y} - {}^Mb_{i,y}\hat{s}_{i,x}) \hat{s}_i}_{2 \times 1} = +\underbrace{\begin{bmatrix} +& \\ +k_i \hat{s}_{i,y} \hat{s}_i & - k_i \hat{s}_{i,x} \hat{s}_i \\ +& \\ +\end{bmatrix}}_{2 \times 2} +\underbrace{\begin{bmatrix} +{}^MO_{K,x}\\ +{}^MO_{K,y} +\end{bmatrix}}_{2 \times 1} +\end{equation} + +And finally, if the matrix is invertible: +\begin{equation} +\boxed{ +{}^MO_K = {\begin{bmatrix} +& \\ +k_i \hat{s}_{i,y} \hat{s}_i & - k_i \hat{s}_{i,x} \hat{s}_i \\ +& \\ +\end{bmatrix}}^{-1} k_i ({}^Mb_{i,x}\hat{s}_{i,y} - {}^Mb_{i,y}\hat{s}_{i,x}) \hat{s}_i +} +\end{equation} + +Note that a rotation of the frame $\{K\}$ with respect to frame $\{M\}$ would make not change on the "diagonality" of $K_{\{K\}}$. + +** Example 1 - Planar manipulator with 3 actuators +#+begin_src matlab :tangle no :exports none :results silent :noweb yes :var current_dir=(file-name-directory buffer-file-name) +<> +#+end_src + +#+begin_src matlab :exports none :results silent :noweb yes +<> +#+end_src + +Consider system of Figure [[fig:3dof_model_fully_parallel_example]]. + +#+name: fig:3dof_model_fully_parallel_example +#+caption: Example of 3DoF parallel platform +[[file:figs/3dof_model_fully_parallel.png]] + +The stiffnesses $k_i$, the joint positions ${}^Mb_i$ and joint unit vectors ${}^M\hat{s}_i$ are defined below: +#+begin_src matlab +ki = [5,1,2]; % Stiffnesses [N/m] +si = [[1;0],[0;1],[0;1]]; si = si./vecnorm(si); % Unit Vectors +bi = [[-1;0.5],[-2;-1],[0;-1]]; % Joint's positions in frame {M} +#+end_src + +Let's first verify that condition eqref:diag_cond_2D_1 is true: +#+begin_src matlab :results value replace +ki.*si*si' +#+end_src + +#+RESULTS: +| 5 | 0 | +| 0 | 2 | + +Now, compute ${}^MO_K$: +#+begin_src matlab +Ok = inv([sum(ki.*si(2,:).*si, 2), -sum(ki.*si(1,:).*si, 2)])*sum(ki.*(bi(1,:).*si(2,:) - bi(2,:).*si(1,:)).*si, 2); +#+end_src + +#+begin_src matlab :results value replace :exports none :tangle no +ans = Ok +#+end_src + +#+RESULTS: +| -1 | +| 0.5 | + +Let's compute the new coordinates ${}^Kb_i$ after the change of frame: +#+begin_src matlab +Kbi = bi - Ok; +#+end_src + +In order to verify that the new frame $\{K\}$ indeed yields a diagonal stiffness matrix, we first compute the Jacobian $J_{\{K\}}$: +#+begin_src matlab +Jk = [si', (Kbi(1,:).*si(2,:) - Kbi(2,:).*si(1,:))']; +#+end_src + +#+begin_src matlab :results value replace :exports none :tangle no +ans = Jk +#+end_src + +#+RESULTS: +| 1 | 0 | 0 | +| 0 | 1 | -1 | +| 0 | 1 | 1 | + +And the stiffness matrix: +#+begin_src matlab +K = Jk'*diag(ki)*Jk +#+end_src + +#+begin_src matlab :results value replace :exports none :tangle no +ans = K +#+end_src + +#+RESULTS: +| 5 | 0 | 0 | +| 0 | 2 | 0 | +| 0 | 0 | 2 | + +** Example 2 - Planar manipulator with 4 actuators +#+begin_src matlab :tangle no :exports none :results silent :noweb yes :var current_dir=(file-name-directory buffer-file-name) +<> +#+end_src + +#+begin_src matlab :exports none :results silent :noweb yes +<> +#+end_src + +Now consider the planar manipulator of Figure [[fig:model_planar_2]]. + +#+name: fig:model_planar_2 +#+caption: Planar Manipulator +#+attr_latex: :width 0.8\linewidth +[[file:figs/model_planar_2.png]] + +The stiffnesses $k_i$, the joint positions ${}^Mb_i$ and joint unit vectors ${}^M\hat{s}_i$ are defined below: +#+begin_src matlab +ki = [1,2,1,1]; +si = [[1;0],[0;1],[-1;0],[0;1]]; +si = si./vecnorm(si); +h = 0.2; +L = 2; +bi = [[-L/2;h],[-L/2;-h],[L/2;h],[L/2;h]]; +#+end_src + +Let's first verify that condition eqref:diag_cond_2D_1 is true: +#+begin_src matlab :results value replace +ki.*si*si' +#+end_src + +#+RESULTS: +| 2 | 0 | +| 0 | 3 | + +Now, compute ${}^MO_K$: +#+begin_src matlab +Ok = inv([sum(ki.*si(2,:).*si, 2), -sum(ki.*si(1,:).*si, 2)])*sum(ki.*(bi(1,:).*si(2,:) - bi(2,:).*si(1,:)).*si, 2); +#+end_src + +#+begin_src matlab :results value replace :exports none :tangle no +ans = Ok +#+end_src + +#+RESULTS: +| -0.33333 | +| 0.2 | + +Let's compute the new coordinates ${}^Kb_i$ after the change of frame: +#+begin_src matlab +Kbi = bi - Ok; +#+end_src + +In order to verify that the new frame $\{K\}$ indeed yields a diagonal stiffness matrix, we first compute the Jacobian $J_{\{K\}}$: +#+begin_src matlab +Jk = [si', (Kbi(1,:).*si(2,:) - Kbi(2,:).*si(1,:))']; +#+end_src + +#+begin_src matlab :results value replace :exports none :tangle no +ans = Jk +#+end_src + +#+RESULTS: +| 1 | 0 | 0 | +| 0 | 1 | -0.66667 | +| -1 | 0 | 0 | +| 0 | 1 | 1.3333 | + +And the stiffness matrix: +#+begin_src matlab +K = Jk'*diag(ki)*Jk +#+end_src + +#+begin_src matlab :results value replace :exports none :tangle no +ans = K +#+end_src + +#+RESULTS: +| 2 | 0 | 0 | +| 0 | 3 | -2.2204e-16 | +| 0 | -2.2204e-16 | 2.6667 | + +* Diagonal Stiffness Matrix for a general parallel manipulator +** Model and Assumptions +Let's consider a 6dof parallel manipulator with: +- $b_i$: location of the joints on the top platform are called $b_i$ +- $\hat{s}_i$: unit vector corresponding to the struts +- $k_i$: stiffness of the struts +- $\tau_i$: actuator forces +- $O_M$: center of mass of the solid body + +Consider two frames: +- $\{M\}$ with origin $O_M$ +- $\{K\}$ with origin $O_K$ + +An example is shown in Figure [[fig:stewart_architecture_example]]. + +#+name: fig:stewart_architecture_example +#+caption: Parallel manipulator Example +[[file:figs/stewart_architecture_example.png]] + +** Objective + +The objective is to find conditions for the existence of a frame $\{K\}$ in which the Stiffness matrix of the manipulator is diagonal. +If the conditions are fulfilled, a second objective is to fine the location of the frame $\{K\}$ analytically. + +** Analytical formula of the stiffness matrix +For a fully parallel manipulator, the stiffness matrix $K_{\{K\}}$ expressed in a frame $\{K\}$ is: +\begin{equation} + K_{\{K\}} = J_{\{K\}}^T \mathcal{K} J_{\{K\}} +\end{equation} +where: +- $K_{\{K\}}$ is the Jacobian transformation from the struts to the frame $\{K\}$ +- $\mathcal{K}$ is a diagonal matrix with the strut stiffnesses on the diagonal + +The analytical expression of $J_{\{K\}}$ is: +\begin{equation} +J_{\{K\}} = \begin{bmatrix} + {}^K\hat{s}_1^T & ({}^Kb_1 \times {}^K\hat{s}_1)^T \\ + {}^K\hat{s}_2^T & ({}^Kb_2 \times {}^K\hat{s}_2)^T \\ + \vdots & \vdots \\ + {}^K\hat{s}_n^T & ({}^Kb_n \times {}^K\hat{s}_n)^T +\end{bmatrix} +\end{equation} + +To simplify, we ignore the superscript $K$ and we assume that all vectors / positions are expressed in this frame $\{K\}$. +Otherwise, it is explicitly written. + +Let's now write the analytical expressing of the stiffness matrix $K_{\{K\}}$: +\begin{equation} +K_{\{K\}} = \begin{bmatrix} + \hat{s}_1 & \dots & \hat{s}_n \\ + (b_1 \times \hat{s}_1) & \dots & (b_n \times \hat{s}_n) +\end{bmatrix} +\begin{bmatrix} + k_1 & & \\ + & \ddots & \\ + & & k_n +\end{bmatrix} +\begin{bmatrix} + \hat{s}_1^T & (b_1 \times \hat{s}_1)^T \\ + \hat{s}_2^T & (b_2 \times \hat{s}_2)^T \\ + \vdots & \dots \\ + \hat{s}_n^T & (b_n \times \hat{s}_n)^T +\end{bmatrix} +\end{equation} + +And we finally obtain: +\begin{equation} +\boxed{ +K_{\{K\}} = \left[ \begin{array}{c|c} + k_i \hat{s}_i \hat{s}_i^T & k_i \hat{s}_i (b_i \times \hat{s}_i)^T \cr + \hline + k_i \hat{s}_i (b_i \times \hat{s}_i)^T & k_i (b_i \times \hat{s}_i) (b_i \times \hat{s}_i)^T +\end{array} \right] +} +\end{equation} + +We want the stiffness matrix to be diagonal, therefore, we have the following conditions: +\begin{align} +k_i \hat{s}_i \hat{s}_i^T &= \text{diag. matrix} \label{eq:diag_cond_1} \\ +k_i (b_i \times \hat{s}_i) (b_i \times \hat{s}_i)^T &= \text{diag. matrix} \label{eq:diag_cond_2} \\ +k_i \hat{s}_i (b_i \times \hat{s}_i)^T &= 0 \label{eq:diag_cond_3} +\end{align} + +Note that: +- condition eqref:eq:diag_cond_1 corresponds to coupling between forces applied on $O_K$ to translations of the payload. + It does not depend on the choice of $\{K\}$, it only depends on the orientation of the struts and the stiffnesses. + It is therefore an intrinsic property of the manipulator. +- condition eqref:eq:diag_cond_2 corresponds to the coupling between forces applied on $O_K$ and rotation of the payload. + Similarly, it does also correspond to the coupling between torques applied on $O_K$ to translations of the payload. +- condition eqref:eq:diag_cond_3 corresponds to the coupling between torques applied on $O_K$ to rotation of the payload. +- conditions eqref:eq:diag_cond_2 and eqref:eq:diag_cond_3 do depend on the positions ${}^Kb_i$ and therefore depend on the choice of $\{K\}$. + +Note that if we find a frame $\{K\}$ in which the stiffness matrix $K_{\{K\}}$ is diagonal, it will still be diagonal for any rotation of the frame $\{K\}$. +Therefore, we here suppose that the frame $\{K\}$ is aligned with the initial frame $\{M\}$. + +Let's make a change of frame from the initial frame $\{M\}$ to the frame $\{K\}$: +\begin{align} +{}^Kb_i &= {}^Mb_i - {}^MO_K \\ +{}^K\hat{s}_i &= {}^M\hat{s}_i +\end{align} + +The goal is to find ${}^MO_K$ such that conditions eqref:eq:diag_cond_2 and eqref:eq:diag_cond_3 are fulfilled. + +Let's first solve equation eqref:eq:diag_cond_3 that corresponds to the coupling between forces and rotations: +\begin{equation} +k_i \hat{s}_i (({}^Mb_i - {}^MO_K) \times \hat{s}_i)^T = 0 +\end{equation} + +Taking the transpose and re-arranging: +\begin{equation} +k_i ({}^Mb_i \times \hat{s}_i) \hat{s}_i^T = k_i ({}^MO_K \times \hat{s}_i) \hat{s}_i^T +\end{equation} + +As the vector cross product also can be expressed as the product of a skew-symmetric matrix and a vector, we obtain: +\begin{equation} +k_i ({}^Mb_i \times \hat{s}_i) \hat{s}_i^T = {}^M\bm{O}_{K} ( k_i \hat{s}_i \hat{s}_i^T ) +\end{equation} + +with: +\begin{equation} \label{eq:skew_symmetric_cross_product} +{}^M\bm{O}_K = \begin{bmatrix} +0 & -{}^MO_{K,z} & {}^MO_{K,y} \\ +{}^MO_{K,z} & 0 & -{}^MO_{K,x} \\ +-{}^MO_{K,y} & {}^MO_{K,x} & 0 +\end{bmatrix} +\end{equation} + +We suppose $k_i \hat{s}_i \hat{s}_i^T$ invertible as it is diagonal from eqref:eq:diag_cond_1. + +And finally, we find: +\begin{equation} +\boxed{ +{}^M\bm{O}_{K} = \left( k_i ({}^Mb_i \times \hat{s}_i) \hat{s}_i^T\right) \cdot {\left( k_i \hat{s}_i \hat{s}_i^T \right)}^{-1} +} +\end{equation} + +If the obtained ${}^M\bm{O}_{K}$ is a skew-symmetric matrix, we can easily determine the corresponding vector ${}^MO_K$ from eqref:eq:skew_symmetric_cross_product. + +In such case, condition eqref:eq:diag_cond_2 is fulfilled and there is no coupling between translations and rotations in the frame $\{K\}$. + +Then, we can only verify if condition eqref:eq:diag_cond_3 is verified or not. + +#+begin_note +If there is no frame $\{K\}$ such that conditions eqref:eq:diag_cond_2 and eqref:eq:diag_cond_3 are valid, it would be interesting to be able to determine the frame $\{K\}$ in which is coupling is minimal. +#+end_note + +** Example 1 - 6DoF manipulator (3D) +#+begin_src matlab :tangle no :exports none :results silent :noweb yes :var current_dir=(file-name-directory buffer-file-name) +<> +#+end_src + +#+begin_src matlab :exports none :results silent :noweb yes +<> +#+end_src + +Let's define the geometry of the manipulator (${}^Mb_i$, ${}^Ms_i$ and $k_i$): +#+begin_src matlab +ki = [2,2,1,1,3,3,1,1,1,1,2,2]; +si = [[-1;0;0],[-1;0;0],[-1;0;0],[-1;0;0],[0;0;1],[0;0;1],[0;0;1],[0;0;1],[0;-1;0],[0;-1;0],[0;-1;0],[0;-1;0]]; +bi = [[1;-1;1],[1;1;-1],[1;1;1],[1;-1;-1],[1;-1;-1],[-1;1;-1],[1;1;-1],[-1;-1;-1],[1;1;-1],[-1;1;1],[-1;1;-1],[1;1;1]]-[0;2;-1]; +#+end_src + +Cond 1: +#+begin_src matlab :results value replace +ki.*si*si' +#+end_src + +#+RESULTS: +| 6 | 0 | 0 | +| 0 | 6 | 0 | +| 0 | 0 | 8 | + +Find Ok +#+begin_src matlab +OkX = (ki.*cross(bi, si)*si')/(ki.*si*si'); + +if all(diag(OkX) == 0) && all(all((OkX + OkX') == 0)) + disp('OkX is skew symmetric') + Ok = [OkX(3,2);OkX(1,3);OkX(2,1)] +else + error('OkX is *not* skew symmetric') +end +#+end_src + +#+begin_src matlab :exports results :results value replace +ans = Ok +#+end_src + +#+RESULTS: +| 0 | +| -2 | +| 1 | + +#+begin_src matlab :results value replace +% Verification of second condition +si*cross(bi-Ok, si)' +#+end_src + +#+RESULTS: +| 0 | 0 | 0 | +| 0 | 0 | 0 | +| 0 | 0 | 0 | + +Verification of third condition +#+begin_src matlab :results value replace +ki.*cross(bi-Ok, si)*cross(bi-Ok, si)' +#+end_src + +#+RESULTS: +| 14 | 4 | -2 | +| 4 | 14 | 2 | +| -2 | 2 | 12 | + +Let's compute the Jacobian: +#+begin_src matlab +Jk = [si', cross(bi - Ok, si)']; +#+end_src + +And the stiffness matrix: +#+begin_src matlab :results value replace +Jk'*diag(ki)*Jk +#+end_src + +#+RESULTS: +| 6 | 0 | 0 | 0 | 0 | 0 | +| 0 | 6 | 0 | 0 | 0 | 0 | +| 0 | 0 | 8 | 0 | 0 | 0 | +| 0 | 0 | 0 | 14 | 4 | -2 | +| 0 | 0 | 0 | 4 | 14 | 2 | +| 0 | 0 | 0 | -2 | 2 | 12 | + +#+begin_src matlab +figure; +hold on; +set(gca,'ColorOrderIndex',1) +plot(b1(1), b1(2), 'o'); +set(gca,'ColorOrderIndex',2) +plot(b2(1), b2(2), 'o'); +set(gca,'ColorOrderIndex',3) +plot(b3(1), b3(2), 'o'); +set(gca,'ColorOrderIndex',1) +quiver(b1(1),b1(2),0.1*s1(1),0.1*s1(2)) +set(gca,'ColorOrderIndex',2) +quiver(b2(1),b2(2),0.1*s2(1),0.1*s2(2)) +set(gca,'ColorOrderIndex',3) +quiver(b3(1),b3(2),0.1*s3(1),0.1*s3(2)) + +plot(0, 0, 'ko'); +quiver([0,0],[0,0],[0.1,0],[0,0.1], 'k') + +plot(Ok(1), Ok(2), 'ro'); +quiver([Ok(1),Ok(1)],[Ok(2),Ok(2)],[0.1,0],[0,0.1], 'r') + +hold off; +axis equal; +#+end_src + +** TODO Example 2 - Stewart Platform * Stewart Platform - Simscape Model :PROPERTIES: :header-args:matlab+: :tangle stewart_platform/script.m diff --git a/index.pdf b/index.pdf index dc02775..254a71c 100644 Binary files a/index.pdf and b/index.pdf differ