diff --git a/Figures/G_ws_pz.pdf b/Figures/G_ws_pz.pdf new file mode 100644 index 0000000..f4aa94d Binary files /dev/null and b/Figures/G_ws_pz.pdf differ diff --git a/Figures/G_ws_pz.png b/Figures/G_ws_pz.png new file mode 100644 index 0000000..aba5764 Binary files /dev/null and b/Figures/G_ws_pz.png differ diff --git a/Figures/G_ws_pz.svg b/Figures/G_ws_pz.svg new file mode 100644 index 0000000..0d21b18 --- /dev/null +++ b/Figures/G_ws_pz.svg @@ -0,0 +1,233 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Figures/G_ws_vc.pdf b/Figures/G_ws_vc.pdf new file mode 100644 index 0000000..eda05d0 Binary files /dev/null and b/Figures/G_ws_vc.pdf differ diff --git a/Figures/G_ws_vc.png b/Figures/G_ws_vc.png new file mode 100644 index 0000000..f730aa8 Binary files /dev/null and b/Figures/G_ws_vc.png differ diff --git a/Figures/G_ws_vc.svg b/Figures/G_ws_vc.svg new file mode 100644 index 0000000..80f922c --- /dev/null +++ b/Figures/G_ws_vc.svg @@ -0,0 +1,349 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Figures/Gc_ws_pz.pdf b/Figures/Gc_ws_pz.pdf new file mode 100644 index 0000000..cb97deb Binary files /dev/null and b/Figures/Gc_ws_pz.pdf differ diff --git a/Figures/Gc_ws_pz.png b/Figures/Gc_ws_pz.png new file mode 100644 index 0000000..60f3dae Binary files /dev/null and b/Figures/Gc_ws_pz.png differ diff --git a/Figures/Gc_ws_pz.svg b/Figures/Gc_ws_pz.svg new file mode 100644 index 0000000..8245d76 --- /dev/null +++ b/Figures/Gc_ws_pz.svg @@ -0,0 +1,235 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Figures/Gc_ws_vc.pdf b/Figures/Gc_ws_vc.pdf new file mode 100644 index 0000000..4376991 Binary files /dev/null and b/Figures/Gc_ws_vc.pdf differ diff --git a/Figures/Gc_ws_vc.png b/Figures/Gc_ws_vc.png new file mode 100644 index 0000000..eac4120 Binary files /dev/null and b/Figures/Gc_ws_vc.png differ diff --git a/Figures/Gc_ws_vc.svg b/Figures/Gc_ws_vc.svg new file mode 100644 index 0000000..1ae0a2c --- /dev/null +++ b/Figures/Gc_ws_vc.svg @@ -0,0 +1,354 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Figures/poles_w_pz.pdf b/Figures/poles_w_pz.pdf new file mode 100644 index 0000000..2f4e221 Binary files /dev/null and b/Figures/poles_w_pz.pdf differ diff --git a/Figures/poles_w_pz.png b/Figures/poles_w_pz.png new file mode 100644 index 0000000..db1f7eb Binary files /dev/null and b/Figures/poles_w_pz.png differ diff --git a/Figures/poles_w_pz.svg b/Figures/poles_w_pz.svg new file mode 100644 index 0000000..61b70dd --- /dev/null +++ b/Figures/poles_w_pz.svg @@ -0,0 +1,231 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Figures/poles_w_vc.pdf b/Figures/poles_w_vc.pdf new file mode 100644 index 0000000..daceb2c Binary files /dev/null and b/Figures/poles_w_vc.pdf differ diff --git a/Figures/poles_w_vc.png b/Figures/poles_w_vc.png new file mode 100644 index 0000000..b11dd02 Binary files /dev/null and b/Figures/poles_w_vc.png differ diff --git a/Figures/poles_w_vc.svg b/Figures/poles_w_vc.svg new file mode 100644 index 0000000..ddf24fb --- /dev/null +++ b/Figures/poles_w_vc.svg @@ -0,0 +1,215 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/mat/parameters.mat b/mat/parameters.mat index 41134f2..1c28b4f 100644 Binary files a/mat/parameters.mat and b/mat/parameters.mat differ diff --git a/rotating_frame.html b/rotating_frame.html index a2f1cd0..aa7c36c 100644 --- a/rotating_frame.html +++ b/rotating_frame.html @@ -3,7 +3,7 @@ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> - + Control in a rotating frame @@ -204,7 +204,7 @@ @licstart The following is the entire license notice for the JavaScript code in this tag. -Copyright (C) 2012-2018 Free Software Foundation, Inc. +Copyright (C) 2012-2019 Free Software Foundation, Inc. The JavaScript code in this tag is free software: you can redistribute it and/or modify it under the terms of the GNU @@ -275,75 +275,86 @@ for the JavaScript code in this tag.

Table of Contents

-
-

1 Introduction

+
+

1 Introduction

The objective of this note it to highlight some control problems that arises when controlling the position of an object using actuators that are rotating with respect to a fixed reference frame.

-In section 2, a simple system composed of a spindle and a translation stage is defined and the equations of motion are written. +In section 2, a simple system composed of a spindle and a translation stage is defined and the equations of motion are written. The rotation induces some coupling between the actuators and their displacement, and modifies the dynamics of the system. This is studied using the equations, and some numerical computations are used to compare the use of voice coil and piezoelectric actuators.

-Then, in section 3, two different control approach are compared where: +Then, in section 3, two different control approach are compared where:

  • the measurement is made in the fixed frame
  • @@ -351,27 +362,27 @@ Then, in section 3, two different control approach are

-In section 4, the analytical study will be validated using a multi body model of the studied system. +In section 4, the analytical study will be validated using a multi body model of the studied system.

-Finally, in section 5, the control strategies are implemented using Simulink and Simscape and compared. +Finally, in section 5, the control strategies are implemented using Simulink and Simscape and compared.

-
-

2 System

+
+

2 System Description and Analysis

- +

-
-

2.1 System description

+
+

2.1 System description

-The system consists of one 2 degree of freedom translation stage on top of a spindle (figure 1). +The system consists of one 2 degree of freedom translation stage on top of a spindle (figure 1).

@@ -384,7 +395,7 @@ The measurement is either the \(x-y\) displacement of the object located on top

-
+

rotating_frame_2dof.png

Figure 1: Schematic of the mecanical system

@@ -418,19 +429,19 @@ Indices \(u\) and \(v\) corresponds to signals in the rotating reference frame (
-
-

2.2 Equations

+
+

2.2 Equations

- -Based on the figure 1, we can write the equations of motion of the system. + +Based on the figure 1, we can write the equations of motion of the system.

Let's express the kinetic energy \(T\) and the potential energy \(V\) of the mass \(m\):

\begin{align} -\label{org93a4d45} +\label{org7c77780} T & = \frac{1}{2} m \left( \dot{x}^2 + \dot{y}^2 \right) \\ V & = \frac{1}{2} k \left( x^2 + y^2 \right) \end{align} @@ -439,7 +450,7 @@ V & = \frac{1}{2} k \left( x^2 + y^2 \right) The Lagrangian is the kinetic energy minus the potential energy.

\begin{equation} -\label{org19136da} +\label{orgc4495ac} L = T-V = \frac{1}{2} m \left( \dot{x}^2 + \dot{y}^2 \right) - \frac{1}{2} k \left( x^2 + y^2 \right) \end{equation} @@ -448,7 +459,7 @@ L = T-V = \frac{1}{2} m \left( \dot{x}^2 + \dot{y}^2 \right) - \frac{1}{2} k \le The partial derivatives of the Lagrangian with respect to the variables \((x, y)\) are:

\begin{align*} -\label{org4fc9f2b} +\label{org5e103d6} \frac{\partial L}{\partial x} & = -kx \\ \frac{\partial L}{\partial y} & = -ky \\ \frac{d}{dt}\frac{\partial L}{\partial \dot{x}} & = m\ddot{x} \\ @@ -518,11 +529,11 @@ We can then subtract and add the previous equations to obtain the following equa

\begin{equation} -\label{orgf3ca0ca} +\label{orgb342505} m \ddot{d_u} + (k - m\dot{\theta}^2) d_u = F_u + 2 m\dot{d_v}\dot{\theta} + m d_v\ddot{\theta} \end{equation} \begin{equation} -\label{org5e2eb96} +\label{org97a2349} m \ddot{d_v} + (k - m\dot{\theta}^2) d_v = F_v - 2 m\dot{d_u}\dot{\theta} - m d_u\ddot{\theta} \end{equation} @@ -548,8 +559,8 @@ The resulting effect of those forces should then be higher when using softer act
-
-

2.3 Numerical Values for the NASS

+
+

2.3 Numerical Values for the NASS

Let's define the parameters for the NASS. @@ -612,8 +623,8 @@ Let's define the parameters for the NASS.

-
-

2.4 Euler and Coriolis forces - Numerical Result

+
+

2.4 Euler and Coriolis forces - Numerical Result

First we will determine the value for Euler and Coriolis forces during regular experiment. @@ -624,10 +635,10 @@ First we will determine the value for Euler and Coriolis forces during regular e

-The obtained values are displayed in table 1. +The obtained values are displayed in table 1.

- +
@@ -661,22 +672,22 @@ The obtained values are displayed in table 1. -
-

2.5 Negative Spring Effect - Numerical Result

+
+

2.5 Negative Spring Effect - Numerical Result

The negative stiffness due to the rotation is equal to \(-m{\omega_0}^2\).

-The values for the negative spring effect are displayed in table 2. +The values for the negative spring effect are displayed in table 2.

This is definitely negligible when using piezoelectric actuators. It may not be the case when using voice coil actuators.

-
Table 1: Euler and Coriolis forces for the NASS
+
@@ -704,15 +715,15 @@ This is definitely negligible when using piezoelectric actuators. It may not be -
-

2.6 Limitations due to coupling

+
+

2.6 Limitations due to coupling

To simplify, we consider a constant rotating speed \(\dot{\theta} = {\omega_0}\) and thus \(\ddot{\theta} = 0\).

-From equations \eqref{orgf3ca0ca} and \eqref{org5e2eb96}, we obtain: +From equations \eqref{orgb342505} and \eqref{org97a2349}, we obtain:

\begin{align*} (m s^2 + (k - m{\omega_0}^2)) d_u &= F_u + 2 m {\omega_0} s d_v \\ @@ -750,6 +761,7 @@ The two previous equations can be written in a matrix form:

\begin{equation} +\label{orga4820eb} \begin{bmatrix} d_u \\ d_v \end{bmatrix} = \frac{1}{(m s^2 + (k - m{\omega_0}^2))^2 + (2 m {\omega_0} s)^2} \begin{bmatrix} @@ -766,26 +778,26 @@ Then, coupling is negligible if \(|-m \omega^2 + (k - m{\omega_0}^2)| \gg |2 m {

-
-

2.6.1 Numerical Analysis

+
+

2.6.1 Numerical Analysis

We plot on the same graph \(\frac{|-m \omega^2 + (k - m {\omega_0}^2)|}{|2 m \omega_0 \omega|}\) for the voice coil and the piezo:

    -
  • with the light sample (figure 2).
  • -
  • with the heavy sample (figure 3).
  • +
  • with the light sample (figure 2).
  • +
  • with the heavy sample (figure 3).
-
+

coupling_light.png

Figure 2: Relative Coupling for light mass and high rotation speed

-
+

coupling_heavy.png

Figure 3: Relative Coupling for heavy mass and low rotation speed

@@ -801,17 +813,17 @@ Coupling is higher for actuators with small stiffness.
-
-

2.7 Limitations due to negative stiffness effect

+
+

2.7 Limitations due to negative stiffness effect

If \(\max{\dot{\theta}} \ll \sqrt{\frac{k}{m}}\), then the negative spring effect is negligible and \(k - m\dot{\theta}^2 \approx k\).

-Let's estimate what is the maximum rotation speed for which the negative stiffness effect is still negligible (\(\omega_\text{max} = 0.1 \sqrt{\frac{k}{m}}\)). Results are shown table 3. +Let's estimate what is the maximum rotation speed for which the negative stiffness effect is still negligible (\(\omega_\text{max} = 0.1 \sqrt{\frac{k}{m}}\)). Results are shown table 3.

-
Table 2: Negative Spring effect
+
@@ -860,10 +872,10 @@ The system can even goes unstable when \(m \omega^2 > k\), that is when the cent

-From this analysis, we can determine the lowest practical stiffness that is possible to use: \(k_\text{min} = 10 m \omega^2\) (table 4) +From this analysis, we can determine the lowest practical stiffness that is possible to use: \(k_\text{min} = 10 m \omega^2\) (table 4)

-
Table 3: Maximum rotation speed at which negative stiffness is negligible (\(0.1\sqrt{\frac{k}{m}}\))
+
@@ -890,17 +902,166 @@ From this analysis, we can determine the lowest practical stiffness that is poss
Table 4: Minimum possible stiffness
-
-
-

3 Control Strategies

-
+
+

2.8 Effect of rotation speed on the plant

+

- +As shown in equation \eqref{orga4820eb}, the plant changes with the rotation speed \(\omega_0\). +

+ +

+Then, we compute the bode plot of the direct term and coupling term for multiple rotating speed. +

+ +

+Then we compare the result between voice coil and piezoelectric actuators.

-
-

3.1 Measurement in the fixed reference frame

+ +
+

2.8.1 Voice coil actuator

+
+ +
+

G_ws_vc.png +

+

Figure 4: Bode plot of the direct transfer function term (from \(F_u\) to \(D_u\)) for multiple rotation speed - Voice coil

+
+ + +
+

Gc_ws_vc.png +

+

Figure 5: Bode plot of the coupling transfer function term (from \(F_u\) to \(D_v\)) for multiple rotation speed - Voice coil

+
+
+
+ +
+

2.8.2 Piezoelectric actuator

+
+ +
+

G_ws_pz.png +

+

Figure 6: Bode plot of the direct transfer function term (from \(F_u\) to \(D_u\)) for multiple rotation speed - Piezoelectric actuator

+
+ + +
+

Gc_ws_pz.png +

+

Figure 7: Bode plot of the coupling transfer function term (from \(F_u\) to \(D_v\)) for multiple rotation speed - Piezoelectric actuator

+
+
+
+ +
+

2.8.3 Analysis

+
+

+When the rotation speed is null, the coupling terms are equal to zero and the diagonal terms corresponds to one degree of freedom mass spring system. +

+ +

+When the rotation speed in not null, the resonance frequency is duplicated into two pairs of complex conjugate poles. +

+ +

+As the rotation speed increases, one of the two resonant frequency goes to lower frequencies as the other one goes to higher frequencies. +

+ +

+The poles of the coupling terms are the same as the poles of the diagonal terms. The magnitude of the coupling terms are increasing with the rotation speed. +

+ +

+As shown in the previous figures, the system with voice coil is much more sensitive to rotation speed. +

+
+
+ +
+

2.8.4 Campbell diagram

+
+

+The poles of the system are computed for multiple values of the rotation frequency. +

+ +
+
m = mlight;
+k = kvc;
+c = 0.1*sqrt(k*m);
+
+ws = linspace(0, 10, 100); % [rad/s]
+
+polesvc = zeros(2, length(ws));
+
+for i = 1:length(ws)
+  polei = pole(1/((m*s^2 + c*s + (k - m*ws(i)^2))^2 + (2*m*ws(i)*s)^2));
+  polesvc(:, i) = sort(polei(imag(polei) > 0));
+end
+
+
+ +
+
m = mlight;
+k = kpz;
+c = 0.1*sqrt(k*m);
+
+ws = linspace(0, 1000, 100); % [rad/s]
+
+polespz = zeros(2, length(ws));
+
+for i = 1:length(ws)
+  polei = pole(1/((m*s^2 + c*s + (k - m*ws(i)^2))^2 + (2*m*ws(i)*s)^2));
+  polespz(:, i) = sort(polei(imag(polei) > 0));
+end
+
+
+ +

+We then plot the real and imaginary part of the poles as a function of the rotation frequency (figures 8 and 9). +

+ +

+When the real part of one pole becomes positive, the system goes unstable. +

+ +

+For the voice coil (figure 8), the system is unstable when the rotation speed is above 5 rad/s. The real and imaginary part of the poles of the system with piezoelectric actuators are changing much less (figure 9). +

+ + +
+

poles_w_vc.png +

+

Figure 8: Real and Imaginary part of the poles of the system as a function of the rotation speed - Voice Coil and light sample

+
+ + + +
+

poles_w_pz.png +

+

Figure 9: Real and Imaginary part of the poles of the system as a function of the rotation speed - Voice Coil and light sample

+
+
+
+
+
+ + +
+

3 Control Strategies

+
+

+ +

+
+
+

3.1 Measurement in the fixed reference frame

First, let's consider a measurement in the fixed referenced frame. @@ -923,14 +1084,14 @@ Finally, the control low \(K\) links the position errors \([\epsilon_u, \epsilon

-The block diagram is shown on figure 4. +The block diagram is shown on figure 10.

-
+

control_measure_fixed_2dof.png

-

Figure 4: Control with a measure from fixed frame

+

Figure 10: Control with a measure from fixed frame

@@ -943,22 +1104,22 @@ One question we wish to answer is: is \(G(\theta) J(\theta) = G(\theta_0) J(\the

-
-

3.2 Measurement in the rotating frame

+
+

3.2 Measurement in the rotating frame

Let's consider that the measurement is made in the rotating reference frame.

-The corresponding block diagram is shown figure 5 +The corresponding block diagram is shown figure 11

-
+

control_measure_rotating_2dof.png

-

Figure 5: Control with a measure from rotating frame

+

Figure 11: Control with a measure from rotating frame

@@ -968,17 +1129,23 @@ The loop gain is \(L = G K\).

-
-

4 Multi Body Model - Simscape

+
+

4 Multi Body Model - Simscape

- +

-
-

4.1 Parameter for the Simscape simulations

-
+
+

4.1 Initialize

+
+
+

4.2 Parameter for the Simscape simulations

+
+

+First we define the parameters that must be defined in order to run the Simscape simulation. +

w = 2*pi; % Rotation speed [rad/s]
 
@@ -992,6 +1159,9 @@ cTuv = 0; 
 
mlight = 5; % Mass for light sample [kg]
 mheavy = 55; % Mass for heavy sample [kg]
@@ -1003,17 +1173,24 @@ kvc = 1e3; 1e8; % Piezo Stiffness [N/m]
 
 d = 0.01; % Maximum excentricity from rotational axis [m]
+
+freqs = logspace(-2, 3, 1000); % Frequency vector for analysis [Hz]
 
-
-

4.2 Identification in the rotating referenced frame

-
+
+

4.3 Identification in the rotating referenced frame

+

-We initialize the inputs and outputs of the system to identify. +We initialize the inputs and outputs of the system to identify:

+
    +
  • Inputs: \(f_u\) and \(f_v\)
  • +
  • Outputs: \(d_u\) and \(d_v\)
  • +
+
%% Options for Linearized
 options = linearizeOptions;
@@ -1068,21 +1245,38 @@ Gvc_heavy.InputName  = {{'Du', 'Dv'};
 
+
+
+
+

4.4 Coupling ratio between \(f_{uv}\) and \(d_{uv}\)

+

-Finally, we plot the coupling ratio in both case (figure 6). -We obtain the same result than the analytical case (figures 2 and 3). +From the previous identification, we plot the coupling ratio in both case (figure 12). +We obtain the same result than the analytical case (figures 2 and 3).

-
+

coupling_ration_light_heavy.png

+
+
+
+

4.5 Plant Control

+
+

+The goal is the study control problems due to the coupling that appears because of the rotation. +

+

+First, we identify the system when the rotation speed is null and then when the rotation speed is equal to 60rpm. +

- - +

+The actuators are voice coil with some damping. +

@@ -1135,9 +1329,9 @@ Plot the ratio between the main transfer function and the coupling term:
-
-

4.2.1 Low rotation speed and High rotation speed

-
+
+

4.5.1 Low rotation speed and High rotation speed

+
rot_speed = 2*pi/60; angle_e = 0;
 G_low = linearize(mdl, io, 0.1);
@@ -1161,9 +1355,9 @@ bode(G_low, G_high
-

4.3 Identification in the fixed frame

-
+
+

4.6 Identification in the fixed frame

+

Let's define some options as well as the inputs and outputs for linearization.

@@ -1243,9 +1437,9 @@ bode(Ge)
-
-

4.4 Identification from actuator forces to displacement in the fixed frame

-
+
+

4.7 Identification from actuator forces to displacement in the fixed frame

+
%% Options for Linearized
 options = linearizeOptions;
@@ -1302,48 +1496,48 @@ exportFig('G_
 
-
-

4.5 Effect of the rotating Speed

-
+
+

4.8 Effect of the rotating Speed

+

- +

-
-

4.5.1 TODO Use realistic parameters for the mass of the sample and stiffness of the X-Y stage

+
+

4.8.1 TODO Use realistic parameters for the mass of the sample and stiffness of the X-Y stage

-
-

4.5.2 TODO Check if the plant is changing a lot when we are not turning to when we are turning at the maximum speed (60rpm)

+
+

4.8.2 TODO Check if the plant is changing a lot when we are not turning to when we are turning at the maximum speed (60rpm)

-
-

4.6 Effect of the X-Y stage stiffness

-
+
+

4.9 Effect of the X-Y stage stiffness

+

- +

-
-

4.6.1 TODO At full speed, check how the coupling changes with the stiffness of the actuators

+
+

4.9.1 TODO At full speed, check how the coupling changes with the stiffness of the actuators

-
-

5 Control Implementation

+
+

5 Control Implementation

- +

-
-

5.1 Measurement in the fixed reference frame

+
+

5.1 Measurement in the fixed reference frame

Author: Thomas Dehaeze

-

Created: 2019-01-23 mer. 15:21

+

Created: 2019-01-24 jeu. 14:05

Validate

diff --git a/rotating_frame.org b/rotating_frame.org index b1b8ab9..9eb1755 100644 --- a/rotating_frame.org +++ b/rotating_frame.org @@ -33,7 +33,7 @@ In section [[sec:simscape]], the analytical study will be validated using a mult Finally, in section [[sec:control]], the control strategies are implemented using Simulink and Simscape and compared. -* System +* System Description and Analysis :PROPERTIES: :HEADER-ARGS:matlab+: :tangle system_numerical_analysis.m :END: @@ -290,6 +290,7 @@ Similarly we can obtain $d_v$ function of $F_u$ and $F_v$: The two previous equations can be written in a matrix form: #+begin_important +#+NAME: eq:coupledplant \begin{equation} \begin{bmatrix} d_u \\ d_v \end{bmatrix} = \frac{1}{(m s^2 + (k - m{\omega_0}^2))^2 + (2 m {\omega_0} s)^2} @@ -308,8 +309,7 @@ We plot on the same graph $\frac{|-m \omega^2 + (k - m {\omega_0}^2)|}{|2 m \ome - with the light sample (figure [[fig:coupling_light]]). - with the heavy sample (figure [[fig:coupling_heavy]]). -#+HEADER: :exports none :results silent -#+begin_src matlab +#+begin_src matlab :exports none :results silent f = logspace(-1, 3, 1000); figure; @@ -335,8 +335,7 @@ We plot on the same graph $\frac{|-m \omega^2 + (k - m {\omega_0}^2)|}{|2 m \ome #+RESULTS: [[file:Figures/coupling_light.png]] -#+HEADER: :exports none :results silent -#+begin_src matlab +#+begin_src matlab :exports none :results silent figure; hold on; plot(f, abs(-mheavy*(2*pi*f).^2 + kvc - mheavy * wheavy^2)./abs(2*mheavy*wheavy*2*pi*f), 'DisplayName', 'Voice Coil') @@ -405,6 +404,342 @@ From this analysis, we can determine the lowest practical stiffness that is poss |-------------+-------+-------| | k min [N/m] | 2199 | 89 | +** Effect of rotation speed on the plant +As shown in equation [[eq:coupledplant]], the plant changes with the rotation speed $\omega_0$. + +Then, we compute the bode plot of the direct term and coupling term for multiple rotating speed. + +Then we compare the result between voice coil and piezoelectric actuators. + +*** Voice coil actuator + +#+begin_src matlab :exports none :results silent + m = mlight; + k = kvc; +#+end_src + +#+begin_src matlab :exports none :results silent + ws = [0, 1, 10, 60]*2*pi/60; % [rmp] + + Gs = {zeros(1, length(ws))}; + Gcs = {zeros(1, length(ws))}; + + for i = 1:length(ws) + w = ws(i); + Gs(i) = {(m*s^2 + (k-m*w^2))/((m*s^2 + (k - m*w^2))^2 + (2*m*w*s)^2)}; + Gcs(i) = {(2*m*w*s)/((m*s^2 + (k - m*w^2))^2 + (2*m*w*s)^2)}; + end +#+end_src + +#+begin_src matlab :exports none :results silent + freqs = logspace(-2, 1, 1000); + + figure; + ax1 = subaxis(2,1,1); + hold on; + for i = 1:length(ws) + plot(freqs, abs(squeeze(freqresp(Gs{i}, freqs, 'Hz'))), 'DisplayName', sprintf('w = %.0f [rpm]', ws(i)*60/2/pi)); + end + hold off; + xlim([freqs(1), freqs(end)]); + set(gca, 'XScale', 'log'); set(gca, 'YScale', 'log'); + set(gca, 'XTickLabel',[]); + ylabel('Magnitude [m/N]'); + legend('Location', 'southwest'); + + ax2 = subaxis(2,1,2); + hold on; + for i = 1:length(ws) + plot(freqs, 180/pi*angle(squeeze(freqresp(Gs{i}, freqs, 'Hz')))); + end + hold off; + yticks(-180:90:180); + ylim([-180 180]); + xlim([freqs(1), freqs(end)]); + set(gca, 'XScale', 'log'); set(gca, 'YScale', 'lin'); + xlabel('Frequency [Hz]'); ylabel('Phase [deg]'); + linkaxes([ax1,ax2],'x'); +#+end_src + +#+HEADER: :tangle no :exports results :results file :noweb yes +#+HEADER: :var filepath="Figures/G_ws_vc.png" :var figsize="wide-tall" +#+begin_src matlab + <> +#+end_src + +#+NAME: fig:G_ws_vc +#+CAPTION: Bode plot of the direct transfer function term (from $F_u$ to $D_u$) for multiple rotation speed - Voice coil +#+RESULTS: +[[file:Figures/G_ws_vc.png]] + +#+begin_src matlab :exports none :results silent + freqs = logspace(-2, 1, 1000); + + figure; + ax1 = subaxis(2,1,1); + hold on; + for i = 1:length(ws) + plot(freqs, abs(squeeze(freqresp(Gcs{i}, freqs, 'Hz'))), 'DisplayName', sprintf('w = %.0f [rpm]', ws(i)*60/2/pi)); + end + hold off; + xlim([freqs(1), freqs(end)]); + set(gca, 'XScale', 'log'); set(gca, 'YScale', 'log'); + set(gca, 'XTickLabel',[]); + ylabel('Magnitude [m/N]'); + legend('Location', 'southwest'); + + ax2 = subaxis(2,1,2); + hold on; + for i = 1:length(ws) + plot(freqs, 180/pi*angle(squeeze(freqresp(Gcs{i}, freqs, 'Hz')))); + end + hold off; + yticks(-180:90:180); + ylim([-180 180]); + xlim([freqs(1), freqs(end)]); + set(gca, 'XScale', 'log'); set(gca, 'YScale', 'lin'); + xlabel('Frequency [Hz]'); ylabel('Phase [deg]'); + linkaxes([ax1,ax2],'x'); +#+end_src + +#+HEADER: :tangle no :exports results :results file :noweb yes +#+HEADER: :var filepath="Figures/Gc_ws_vc.png" :var figsize="wide-tall" +#+begin_src matlab + <> +#+end_src + +#+NAME: fig:Gc_ws_vc +#+CAPTION: Bode plot of the coupling transfer function term (from $F_u$ to $D_v$) for multiple rotation speed - Voice coil +#+RESULTS: +[[file:Figures/Gc_ws_vc.png]] + +*** Piezoelectric actuator + +#+begin_src matlab :exports none :results silent + m = mlight; + k = kpz; +#+end_src + +#+begin_src matlab :exports none :results silent + ws = [0, 1, 10, 60]*2*pi/60; % [rmp] + + Gs = {zeros(1, length(ws))}; + Gcs = {zeros(1, length(ws))}; + + for i = 1:length(ws) + w = ws(i); + Gs(i) = {(m*s^2 + (k-m*w^2))/((m*s^2 + (k - m*w^2))^2 + (2*m*w*s)^2)}; + Gcs(i) = {(2*m*w*s)/((m*s^2 + (k - m*w^2))^2 + (2*m*w*s)^2)}; + end +#+end_src + +#+begin_src matlab :exports none :results silent + freqs = logspace(2, 3, 1000); + + figure; + ax1 = subaxis(2,1,1); + hold on; + for i = 1:length(ws) + plot(freqs, abs(squeeze(freqresp(Gs{i}, freqs, 'Hz'))), 'DisplayName', sprintf('w = %.0f [rpm]', ws(i)*60/2/pi)); + end + hold off; + xlim([freqs(1), freqs(end)]); + set(gca, 'XScale', 'log'); set(gca, 'YScale', 'log'); + set(gca, 'XTickLabel',[]); + ylabel('Magnitude [m/N]'); + legend('Location', 'southwest'); + + ax2 = subaxis(2,1,2); + hold on; + for i = 1:length(ws) + plot(freqs, 180/pi*angle(squeeze(freqresp(Gs{i}, freqs, 'Hz')))); + end + hold off; + yticks(-180:90:180); + ylim([-180 180]); + xlim([freqs(1), freqs(end)]); + set(gca, 'XScale', 'log'); set(gca, 'YScale', 'lin'); + xlabel('Frequency [Hz]'); ylabel('Phase [deg]'); + linkaxes([ax1,ax2],'x'); +#+end_src + +#+HEADER: :tangle no :exports results :results file :noweb yes +#+HEADER: :var filepath="Figures/G_ws_pz.png" :var figsize="wide-tall" +#+begin_src matlab + <> +#+end_src + +#+NAME: fig:G_ws_pz +#+CAPTION: Bode plot of the direct transfer function term (from $F_u$ to $D_u$) for multiple rotation speed - Piezoelectric actuator +#+RESULTS: +[[file:Figures/G_ws_pz.png]] + +#+begin_src matlab :exports none :results silent + figure; + ax1 = subaxis(2,1,1); + hold on; + for i = 1:length(ws) + plot(freqs, abs(squeeze(freqresp(Gcs{i}, freqs, 'Hz'))), 'DisplayName', sprintf('w = %.0f [rpm]', ws(i)*60/2/pi)); + end + hold off; + xlim([freqs(1), freqs(end)]); + set(gca, 'XScale', 'log'); set(gca, 'YScale', 'log'); + set(gca, 'XTickLabel',[]); + ylabel('Magnitude [m/N]'); + legend('Location', 'southwest'); + + ax2 = subaxis(2,1,2); + hold on; + for i = 1:length(ws) + plot(freqs, 180/pi*angle(squeeze(freqresp(Gcs{i}, freqs, 'Hz')))); + end + hold off; + yticks(-180:90:180); + ylim([-180 180]); + xlim([freqs(1), freqs(end)]); + set(gca, 'XScale', 'log'); set(gca, 'YScale', 'lin'); + xlabel('Frequency [Hz]'); ylabel('Phase [deg]'); + linkaxes([ax1,ax2],'x'); +#+end_src + +#+HEADER: :tangle no :exports results :results file :noweb yes +#+HEADER: :var filepath="Figures/Gc_ws_pz.png" :var figsize="wide-tall" +#+begin_src matlab + <> +#+end_src + +#+NAME: fig:Gc_ws_pz +#+CAPTION: Bode plot of the coupling transfer function term (from $F_u$ to $D_v$) for multiple rotation speed - Piezoelectric actuator +#+RESULTS: +[[file:Figures/Gc_ws_pz.png]] + +*** Analysis +When the rotation speed is null, the coupling terms are equal to zero and the diagonal terms corresponds to one degree of freedom mass spring system. + +When the rotation speed in not null, the resonance frequency is duplicated into two pairs of complex conjugate poles. + +As the rotation speed increases, one of the two resonant frequency goes to lower frequencies as the other one goes to higher frequencies. + +The poles of the coupling terms are the same as the poles of the diagonal terms. The magnitude of the coupling terms are increasing with the rotation speed. + +As shown in the previous figures, the system with voice coil is much more sensitive to rotation speed. + +*** Campbell diagram + +The poles of the system are computed for multiple values of the rotation frequency. + +#+begin_src matlab :results silent :exports code + m = mlight; + k = kvc; + c = 0.1*sqrt(k*m); + + ws = linspace(0, 10, 100); % [rad/s] + + polesvc = zeros(2, length(ws)); + + for i = 1:length(ws) + polei = pole(1/((m*s^2 + c*s + (k - m*ws(i)^2))^2 + (2*m*ws(i)*s)^2)); + polesvc(:, i) = sort(polei(imag(polei) > 0)); + end +#+end_src + +#+begin_src matlab :results silent :exports code + m = mlight; + k = kpz; + c = 0.1*sqrt(k*m); + + ws = linspace(0, 1000, 100); % [rad/s] + + polespz = zeros(2, length(ws)); + + for i = 1:length(ws) + polei = pole(1/((m*s^2 + c*s + (k - m*ws(i)^2))^2 + (2*m*ws(i)*s)^2)); + polespz(:, i) = sort(polei(imag(polei) > 0)); + end +#+end_src + +We then plot the real and imaginary part of the poles as a function of the rotation frequency (figures [[fig:poles_w_vc]] and [[fig:poles_w_pz]]). + +When the real part of one pole becomes positive, the system goes unstable. + +For the voice coil (figure [[fig:poles_w_vc]]), the system is unstable when the rotation speed is above 5 rad/s. The real and imaginary part of the poles of the system with piezoelectric actuators are changing much less (figure [[fig:poles_w_pz]]). + +#+begin_src matlab :results silent :exports none + figure; + % Amplitude + ax1 = subplot(1,2,1); + hold on; + plot(ws, real(polesvc(1, :))) + set(gca,'ColorOrderIndex',1) + plot(ws, real(polesvc(2, :))) + plot(ws, zeros(size(ws)), 'k--') + hold off; + xlabel('Rotation Frequency [rad/s]'); + ylabel('Pole Real Part'); + ax2 = subplot(1,2,2); + hold on; + plot(ws, imag(polesvc(1, :))) + set(gca,'ColorOrderIndex',1) + plot(ws, -imag(polesvc(1, :))) + set(gca,'ColorOrderIndex',1) + plot(ws, imag(polesvc(2, :))) + set(gca,'ColorOrderIndex',1) + plot(ws, -imag(polesvc(2, :))) + hold off; + xlabel('Rotation Frequency [rad/s]'); + ylabel('Pole Imaginary Part'); +#+end_src + +#+HEADER: :tangle no :exports results :results file :noweb yes +#+HEADER: :var filepath="Figures/poles_w_vc.png" :var figsize="wide-tall" +#+begin_src matlab + <> +#+end_src + +#+NAME: fig:poles_w_vc +#+CAPTION: Real and Imaginary part of the poles of the system as a function of the rotation speed - Voice Coil and light sample +#+RESULTS: +[[file:Figures/poles_w_vc.png]] + + +#+begin_src matlab :results silent :exports none + figure; + % Amplitude + ax1 = subplot(1,2,1); + hold on; + plot(ws, real(polespz(1, :))) + set(gca,'ColorOrderIndex',1) + plot(ws, real(polespz(2, :))) + plot(ws, zeros(size(ws)), 'k--') + hold off; + xlabel('Rotation Frequency [rad/s]'); + ylabel('Pole Real Part'); + ax2 = subplot(1,2,2); + hold on; + plot(ws, imag(polespz(1, :))) + set(gca,'ColorOrderIndex',1) + plot(ws, -imag(polespz(1, :))) + set(gca,'ColorOrderIndex',1) + plot(ws, imag(polespz(2, :))) + set(gca,'ColorOrderIndex',1) + plot(ws, -imag(polespz(2, :))) + hold off; + xlabel('Rotation Frequency [rad/s]'); + ylabel('Pole Imaginary Part'); +#+end_src + +#+HEADER: :tangle no :exports results :results file :noweb yes +#+HEADER: :var filepath="Figures/poles_w_pz.png" :var figsize="wide-tall" +#+begin_src matlab + <> +#+end_src + +#+NAME: fig:poles_w_pz +#+CAPTION: Real and Imaginary part of the poles of the system as a function of the rotation speed - Voice Coil and light sample +#+RESULTS: +[[file:Figures/poles_w_pz.png]] + + * Control Strategies <> ** Measurement in the fixed reference frame @@ -445,6 +780,7 @@ The loop gain is $L = G K$. :END: <> +** Initialize #+begin_src matlab :exports none :results silent :noweb yes <> load('./mat/parameters.mat'); @@ -455,6 +791,7 @@ The loop gain is $L = G K$. #+end_src ** Parameter for the Simscape simulations +First we define the parameters that must be defined in order to run the Simscape simulation. #+begin_src matlab :exports code :results silent w = 2*pi; % Rotation speed [rad/s] @@ -467,6 +804,7 @@ The loop gain is $L = G K$. cTuv = 0; % Damping of the Tuv stage [N/(m/s)] #+end_src +Then, we defined parameters that will be used in the following analysis. #+begin_src matlab :exports code :results silent mlight = 5; % Mass for light sample [kg] mheavy = 55; % Mass for heavy sample [kg] @@ -478,11 +816,15 @@ The loop gain is $L = G K$. kpz = 1e8; % Piezo Stiffness [N/m] d = 0.01; % Maximum excentricity from rotational axis [m] + + freqs = logspace(-2, 3, 1000); % Frequency vector for analysis [Hz] #+end_src ** Identification in the rotating referenced frame +We initialize the inputs and outputs of the system to identify: +- Inputs: $f_u$ and $f_v$ +- Outputs: $d_u$ and $d_v$ -We initialize the inputs and outputs of the system to identify. #+begin_src matlab :exports code :results silent %% Options for Linearized options = linearizeOptions; @@ -531,11 +873,11 @@ Then we identify the system with an heavy mass and low speed. Gvc_heavy.OutputName = {'Du', 'Dv'}; #+end_src -Finally, we plot the coupling ratio in both case (figure [[fig:coupling_ration_light_heavy]]). +** Coupling ratio between $f_{uv}$ and $d_{uv}$ + +From the previous identification, we plot the coupling ratio in both case (figure [[fig:coupling_ration_light_heavy]]). We obtain the same result than the analytical case (figures [[fig:coupling_light]] and [[fig:coupling_heavy]]). #+begin_src matlab :results silent :exports none - freqs = logspace(-2, 3, 1000); - figure; hold on; plot(freqs, abs(squeeze(freqresp(Gvc_light('Du', 'Fu'), freqs, 'Hz')))./abs(squeeze(freqresp(Gvc_light('Dv', 'Fu'), freqs, 'Hz')))); @@ -560,6 +902,108 @@ We obtain the same result than the analytical case (figures [[fig:coupling_light #+RESULTS: [[file:Figures/coupling_ration_light_heavy.png]] +** Plant Control + +The goal is the study control problems due to the coupling that appears because of the rotation. + +#+begin_src matlab :exports none :results silent + %% Options for Linearized + options = linearizeOptions; + options.SampleTime = 0; + + %% Name of the Simulink File + mdl = 'rotating_frame'; + + %% Input/Output definition + io(1) = linio([mdl, '/fu'], 1, 'input'); + io(2) = linio([mdl, '/fv'], 1, 'input'); + + io(3) = linio([mdl, '/du'], 1, 'output'); + io(4) = linio([mdl, '/dv'], 1, 'output'); +#+end_src + +First, we identify the system when the rotation speed is null and then when the rotation speed is equal to 60rpm. + +The actuators are voice coil with some damping. + +#+begin_src matlab :exports none :results silent + w = 0; % Rotation speed [rad/s] + m = mlight; % mass of the sample [kg] + kTuv = kvc; + % cTuv = 0.1*sqrt(kTuv*m); + cTuv = 0; + + G = linearize(mdl, io, 0.1); + G.InputName = {'Fu', 'Fv'}; + G.OutputName = {'Du', 'Dv'}; +#+end_src + +#+begin_src matlab :exports none :results silent + w = 0.1; % Rotation speed [rad/s] + m = mlight; % mass of the sample [kg] + kTuv = kvc; + % cTuv = 0.1*sqrt(kTuv*m); + cTuv = 0; + + Gt = linearize(mdl, io, 0.1); + Gt.InputName = {'Fu', 'Fv'}; + Gt.OutputName = {'Du', 'Dv'}; +#+end_src + +#+begin_src matlab :exports none :results silent + figure; + bode(G, 'r-', Gt, 'b--') + legend({'G - w = 0', 'G - w = 60rpm'}, 'Location', 'southwest'); +#+end_src + +#+HEADER: :tangle no :exports results :results file :noweb yes +#+HEADER: :var filepath="Figures/coupling_ration_light_heavy.png" :var figsize="wide-tall" +#+begin_src matlab + <> +#+end_src + + +#+begin_src matlab :exports none :results silent + figure; + % Amplitude + ax1 = subaxis(2,1,1); + hold on; + plot(freqs, abs(squeeze(freqresp(Gvc_light('du', 'fu'), freqs, 'Hz'))), '-'); + set(gca,'xscale','log'); set(gca,'yscale','log'); + ylabel('Amplitude [m/N]'); + set(gca, 'XTickLabel',[]); + hold off; + % Phase + ax2 = subaxis(2,1,2); + hold on; + plot(freqs, 180/pi*unwrap(angle(squeeze(freqresp(Gvc_light('du', 'fu'), freqs, 'Hz')))), '-'); + set(gca,'xscale','log'); + yticks(-180:180:180); + xlabel('Frequency [Hz]'); ylabel('Phase [deg]'); + hold off; + linkaxes([ax1,ax2],'x'); +#+end_src + +#+begin_src matlab :exports none :results silent + figure; + % Amplitude + ax1 = subaxis(2,1,1); + hold on; + plot(freqs, abs(squeeze(freqresp(-Gvc_light('dv', 'fv'), freqs, 'Hz'))), '-'); + set(gca,'xscale','log'); set(gca,'yscale','log'); + ylabel('Amplitude [m/N]'); + set(gca, 'XTickLabel',[]); + hold off; + % Phase + ax2 = subaxis(2,1,2); + hold on; + plot(freqs, 180/pi*unwrap(angle(squeeze(freqresp(-Gvc_light('dv', 'fv'), freqs, 'Hz')))), '-'); + set(gca,'xscale','log'); + yticks(-180:180:180); + xlabel('Frequency [Hz]'); ylabel('Phase [deg]'); + hold off; + linkaxes([ax1,ax2],'x'); +#+end_src