-
load('experiment_tomography/mat/experiment.mat', 'tomo_align_no_dist');
+load('./mat/experiment_tomography.mat', 'tomo_align_no_dist');
t = tomo_align_no_dist.t;
MTr = tomo_align_no_dist.MTr;
@@ -446,8 +424,8 @@ Erz = atan2(-squeeze(MTr(1, 2,
-2.3 Conclusion
+
+
2.3 Conclusion
@@ -467,8 +445,8 @@ This residual error motion probably comes from a small misalignment somewhere.
-
-
3.1 Simulation Setup
+
+
3.1 Simulation Setup
We now activate the disturbances.
@@ -498,17 +476,17 @@ And we save the obtained data.
tomo_align_dist = struct('t', t, 'MTr', MTr);
-save('experiment_tomography/mat/experiment.mat', 'tomo_align_dist', '-append');
+save('./mat/experiment_tomography.mat', 'tomo_align_dist', '-append');
-
-
3.2 Analysis
+
+
3.2 Analysis
-
load('experiment_tomography/mat/experiment.mat', 'tomo_align_dist');
+load('./mat/experiment_tomography.mat', 'tomo_align_dist');
t = tomo_align_dist.t;
MTr = tomo_align_dist.MTr;
@@ -541,8 +519,8 @@ Erz = atan2(-squeeze(MTr(1, 2,
-3.3 Conclusion
+
+
3.3 Conclusion
@@ -561,8 +539,8 @@ Error motion is what expected from the disturbance measurements.
-
-
4.1 Simulation Setup
+
+
4.1 Simulation Setup
We first set the wanted translation of the Micro Hexapod.
@@ -616,17 +594,17 @@ And we save the obtained data.
tomo_not_align = struct('t', t, 'MTr', MTr);
-save('experiment_tomography/mat/experiment.mat', 'tomo_not_align', '-append');
+save('./mat/experiment_tomography.mat', 'tomo_not_align', '-append');
-
-
4.2 Analysis
+
+
4.2 Analysis
-
load('experiment_tomography/mat/experiment.mat', 'tomo_not_align');
+load('./mat/experiment_tomography.mat', 'tomo_not_align');
t = tomo_not_align.t;
MTr = tomo_not_align.MTr;
@@ -659,8 +637,8 @@ Erz = atan2(-squeeze(MTr(1, 2,
-4.3 Conclusion
+
+
4.3 Conclusion
@@ -679,8 +657,8 @@ The main motions are translations in the X direction of the mobile platform (cor
-
-
5.1 Simulation Setup
+
+
5.1 Simulation Setup
We set the reference path.
@@ -735,17 +713,17 @@ And we save the obtained data.
ty_scan = struct('t', t, 'MTr', MTr);
-save('experiment_tomography/mat/experiment.mat', 'ty_scan', '-append');
+save('./mat/experiment_tomography.mat', 'ty_scan', '-append');
-
-
5.2 Analysis
+
+
5.2 Analysis
-
load('experiment_tomography/mat/experiment.mat', 'ty_scan');
+load('./mat/experiment_tomography.mat', 'ty_scan');
t = ty_scan.t;
MTr = ty_scan.MTr;
@@ -778,8 +756,8 @@ Erz = atan2(-squeeze(MTr(1, 2,
-5.3 Conclusion
+
+
5.3 Conclusion
@@ -794,7 +772,7 @@ In order to reduce the errors, we can make a smoother reference path for the tra
Author: Dehaeze Thomas
-
Created: 2020-02-25 mar. 18:21
+
Created: 2020-03-13 ven. 17:39
diff --git a/docs/figs/comp_iff_dvf_simplified.pdf b/docs/figs/comp_iff_dvf_simplified.pdf
new file mode 100644
index 0000000..9d5b5c1
Binary files /dev/null and b/docs/figs/comp_iff_dvf_simplified.pdf differ
diff --git a/docs/figs/comp_iff_dvf_simplified.png b/docs/figs/comp_iff_dvf_simplified.png
new file mode 100644
index 0000000..cbd8e89
Binary files /dev/null and b/docs/figs/comp_iff_dvf_simplified.png differ
diff --git a/docs/figs/hac_lac_control_schematic.pdf b/docs/figs/hac_lac_control_schematic.pdf
new file mode 100644
index 0000000..c047068
Binary files /dev/null and b/docs/figs/hac_lac_control_schematic.pdf differ
diff --git a/docs/figs/hac_lac_control_schematic.png b/docs/figs/hac_lac_control_schematic.png
new file mode 100644
index 0000000..08eb497
Binary files /dev/null and b/docs/figs/hac_lac_control_schematic.png differ
diff --git a/docs/figs/nano_station_control_2dof_x.pdf b/docs/figs/nano_station_control_2dof_x.pdf
new file mode 100644
index 0000000..9873058
Binary files /dev/null and b/docs/figs/nano_station_control_2dof_x.pdf differ
diff --git a/docs/figs/nano_station_control_2dof_x.png b/docs/figs/nano_station_control_2dof_x.png
new file mode 100644
index 0000000..95d46cc
Binary files /dev/null and b/docs/figs/nano_station_control_2dof_x.png differ
diff --git a/docs/figs/nano_station_control_Fm.pdf b/docs/figs/nano_station_control_Fm.pdf
new file mode 100644
index 0000000..a471b93
Binary files /dev/null and b/docs/figs/nano_station_control_Fm.pdf differ
diff --git a/docs/figs/nano_station_control_Fm.png b/docs/figs/nano_station_control_Fm.png
new file mode 100644
index 0000000..b25a810
Binary files /dev/null and b/docs/figs/nano_station_control_Fm.png differ
diff --git a/docs/figs/nano_station_control_d.pdf b/docs/figs/nano_station_control_d.pdf
new file mode 100644
index 0000000..9c05e02
Binary files /dev/null and b/docs/figs/nano_station_control_d.pdf differ
diff --git a/docs/figs/nano_station_control_d.png b/docs/figs/nano_station_control_d.png
new file mode 100644
index 0000000..e5af89a
Binary files /dev/null and b/docs/figs/nano_station_control_d.png differ
diff --git a/docs/figs/nano_station_control_x.pdf b/docs/figs/nano_station_control_x.pdf
new file mode 100644
index 0000000..c5d82b4
Binary files /dev/null and b/docs/figs/nano_station_control_x.pdf differ
diff --git a/docs/figs/nano_station_control_x.png b/docs/figs/nano_station_control_x.png
new file mode 100644
index 0000000..6b5b4c5
Binary files /dev/null and b/docs/figs/nano_station_control_x.png differ
diff --git a/docs/figs/nano_station_ground_motion.pdf b/docs/figs/nano_station_ground_motion.pdf
new file mode 100644
index 0000000..e3fb4a0
Binary files /dev/null and b/docs/figs/nano_station_ground_motion.pdf differ
diff --git a/docs/figs/nano_station_ground_motion.png b/docs/figs/nano_station_ground_motion.png
new file mode 100644
index 0000000..ca4b605
Binary files /dev/null and b/docs/figs/nano_station_ground_motion.png differ
diff --git a/docs/figs/nano_station_inputs_outputs.pdf b/docs/figs/nano_station_inputs_outputs.pdf
new file mode 100644
index 0000000..9bd69d6
Binary files /dev/null and b/docs/figs/nano_station_inputs_outputs.pdf differ
diff --git a/docs/figs/nano_station_inputs_outputs.png b/docs/figs/nano_station_inputs_outputs.png
new file mode 100644
index 0000000..0fefc92
Binary files /dev/null and b/docs/figs/nano_station_inputs_outputs.png differ
diff --git a/docs/figs/nano_station_inputs_outputs_ground_motion.pdf b/docs/figs/nano_station_inputs_outputs_ground_motion.pdf
new file mode 100644
index 0000000..31ecff5
Binary files /dev/null and b/docs/figs/nano_station_inputs_outputs_ground_motion.pdf differ
diff --git a/docs/figs/nano_station_inputs_outputs_ground_motion.png b/docs/figs/nano_station_inputs_outputs_ground_motion.png
new file mode 100644
index 0000000..ab23b5b
Binary files /dev/null and b/docs/figs/nano_station_inputs_outputs_ground_motion.png differ
diff --git a/docs/figs/nass_simple_model.pdf b/docs/figs/nass_simple_model.pdf
new file mode 100644
index 0000000..d6e98da
Binary files /dev/null and b/docs/figs/nass_simple_model.pdf differ
diff --git a/docs/figs/nass_simple_model.png b/docs/figs/nass_simple_model.png
new file mode 100644
index 0000000..f76b2f6
Binary files /dev/null and b/docs/figs/nass_simple_model.png differ
diff --git a/docs/figs/simple_comp_vc_pz.pdf b/docs/figs/simple_comp_vc_pz.pdf
new file mode 100644
index 0000000..6cbc447
Binary files /dev/null and b/docs/figs/simple_comp_vc_pz.pdf differ
diff --git a/docs/figs/simple_comp_vc_pz.png b/docs/figs/simple_comp_vc_pz.png
new file mode 100644
index 0000000..09b80b1
Binary files /dev/null and b/docs/figs/simple_comp_vc_pz.png differ
diff --git a/docs/figs/simple_hac_lac_results.pdf b/docs/figs/simple_hac_lac_results.pdf
new file mode 100644
index 0000000..e745123
Binary files /dev/null and b/docs/figs/simple_hac_lac_results.pdf differ
diff --git a/docs/figs/simple_hac_lac_results.png b/docs/figs/simple_hac_lac_results.png
new file mode 100644
index 0000000..4ee2b66
Binary files /dev/null and b/docs/figs/simple_hac_lac_results.png differ
diff --git a/docs/figs/simple_hac_lac_results_soft.pdf b/docs/figs/simple_hac_lac_results_soft.pdf
new file mode 100644
index 0000000..a0806f1
Binary files /dev/null and b/docs/figs/simple_hac_lac_results_soft.pdf differ
diff --git a/docs/figs/simple_hac_lac_results_soft.png b/docs/figs/simple_hac_lac_results_soft.png
new file mode 100644
index 0000000..586a30b
Binary files /dev/null and b/docs/figs/simple_hac_lac_results_soft.png differ
diff --git a/docs/figs/simple_loop_gain_pz.pdf b/docs/figs/simple_loop_gain_pz.pdf
new file mode 100644
index 0000000..44228d8
Binary files /dev/null and b/docs/figs/simple_loop_gain_pz.pdf differ
diff --git a/docs/figs/simple_loop_gain_pz.png b/docs/figs/simple_loop_gain_pz.png
new file mode 100644
index 0000000..cc104db
Binary files /dev/null and b/docs/figs/simple_loop_gain_pz.png differ
diff --git a/docs/functions.html b/docs/functions.html
index cb5021f..ab576ca 100644
--- a/docs/functions.html
+++ b/docs/functions.html
@@ -4,7 +4,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-
+
Matlab Functions used for the NASS Project
@@ -202,50 +202,28 @@
@@ -259,276 +237,15 @@ for the JavaScript code in this tag.
Table of Contents
-
-
1 computePsdDispl
-
-
-
-
-
-
-This Matlab function is accessible here.
-
-
-
-
function [psd_object] = computePsdDispl(sys_data, t_init, n_av)
- i_init = find(sys_data.time > t_init, 1);
-
- han_win = hanning(ceil(length(sys_data.Dx(i_init:end, :))/n_av));
- Fs = 1/sys_data.time(2);
-
- [pdx, f] = pwelch(sys_data.Dx(i_init:end, :), han_win, [], [], Fs);
- [pdy, ~] = pwelch(sys_data.Dy(i_init:end, :), han_win, [], [], Fs);
- [pdz, ~] = pwelch(sys_data.Dz(i_init:end, :), han_win, [], [], Fs);
-
- [prx, ~] = pwelch(sys_data.Rx(i_init:end, :), han_win, [], [], Fs);
- [pry, ~] = pwelch(sys_data.Ry(i_init:end, :), han_win, [], [], Fs);
- [prz, ~] = pwelch(sys_data.Rz(i_init:end, :), han_win, [], [], Fs);
-
- psd_object = struct(...
- 'f', f, ...
- 'dx', pdx, ...
- 'dy', pdy, ...
- 'dz', pdz, ...
- 'rx', prx, ...
- 'ry', pry, ...
- 'rz', prz);
-end
-
-
-
-
-
-
-
2 computeSetpoint
-
-
-
-
-
-
-This Matlab function is accessible here.
-
-
-
-
function setpoint = computeSetpoint(ty, ry, rz)
-
-setpoint = zeros(6, 1);
-
-
-Ty = [1 0 0 0 ;
- 0 1 0 ty ;
- 0 0 1 0 ;
- 0 0 0 1 ];
-
-
-
-
-
-
-
-Ry = [ cos(ry) 0 sin(ry) 0 ;
- 0 1 0 0 ;
- -sin(ry) 0 cos(ry) 0 ;
- 0 0 0 1 ];
-
-
-
-
-Rz = [cos(rz) -sin(rz) 0 0 ;
- sin(rz) cos(rz) 0 0 ;
- 0 0 1 0 ;
- 0 0 0 1 ];
-
-
-
-
-
-
-TM = Ty*Ry*Rz;
-
-[thetax, thetay, thetaz] = RM2angle(TM(1:3, 1:3));
-
-setpoint(1:3) = TM(1:3, 4);
-setpoint(4:6) = [thetax, thetay, thetaz];
-
-
-function [thetax, thetay, thetaz] = RM2angle(R)
- if abs(abs(R(3, 1)) - 1) > 1e-6
- thetay = -asin(R(3, 1));
- thetax = atan2(R(3, 2)/cos(thetay), R(3, 3)/cos(thetay));
- thetaz = atan2(R(2, 1)/cos(thetay), R(1, 1)/cos(thetay));
- else
- thetaz = 0;
- if abs(R(3, 1)+1) < 1e-6
- thetay = pi/2;
- thetax = thetaz + atan2(R(1, 2), R(1, 3));
- else
- thetay = -pi/2;
- thetax = -thetaz + atan2(-R(1, 2), -R(1, 3));
- end
- end
-end
-end
-
-
-
-
-
-
-
3 converErrorBasis
-
-
-
-
-
-
-This Matlab function is accessible here.
-
-
-
-
function error_nass = convertErrorBasis(pos, setpoint, ty, ry, rz)
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-if size(pos, 2) == 6
- pos = pos';
-end
-
-if size(setpoint, 2) == 6
- setpoint = setpoint';
-end
-
-
-P_granite = [pos(1:3); 1];
-R_granite = [setpoint(1:3); 1];
-
-
-
-TMty = [1 0 0 0 ;
- 0 1 0 ty ;
- 0 0 1 0 ;
- 0 0 0 1 ];
-
-
-TMry = [ cos(ry) 0 sin(ry) 0 ;
- 0 1 0 0 ;
- -sin(ry) 0 cos(ry) 0 ;
- 0 0 0 1 ];
-
-
-TMrz = [cos(rz) -sin(rz) 0 0 ;
- sin(rz) cos(rz) 0 0 ;
- 0 0 1 0 ;
- 0 0 0 1 ];
-
-
-
-P_nass = TMrz\TMry\TMty\P_granite;
-R_nass = TMrz\TMry\TMty\R_granite;
-
-dx = R_nass(1)-P_nass(1);
-dy = R_nass(2)-P_nass(2);
-dz = R_nass(3)-P_nass(3);
-
-
-
-
-
-
-
-
-
-ux_nass = TMrz\TMry\TMty\[1; 0; 0; 0];
-ux_nass = ux_nass(1:3);
-uy_nass = TMrz\TMry\TMty\[0; 1; 0; 0];
-uy_nass = uy_nass(1:3);
-uz_nass = TMrz\TMry\TMty\[0; 0; 1; 0];
-uz_nass = uz_nass(1:3);
-
-
-
-rx_nass = pos(4);
-ry_nass = pos(5);
-rz_nass = pos(6);
-
-
-Mrx_error = [1 0 0 ;
- 0 cos(-rx_nass) -sin(-rx_nass) ;
- 0 sin(-rx_nass) cos(-rx_nass)];
-
-Mry_error = [ cos(-ry_nass) 0 sin(-ry_nass) ;
- 0 1 0 ;
- -sin(-ry_nass) 0 cos(-ry_nass)];
-
-Mrz_error = [cos(-rz_nass) -sin(-rz_nass) 0 ;
- sin(-rz_nass) cos(-rz_nass) 0 ;
- 0 0 1];
-
-
-Mr_error = Mrz_error*Mry_error*Mrx_error;
-
-
-R = Mr_error/[ux_nass, uy_nass, uz_nass];
-
-[thetax, thetay, thetaz] = RM2angle(R);
-
-error_nass = [dx; dy; dz; thetax; thetay; thetaz];
-
-
-function [thetax, thetay, thetaz] = RM2angle(R)
- if abs(abs(R(3, 1)) - 1) > 1e-6
- thetay = -asin(R(3, 1));
-
- thetax = atan2(R(3, 2)/cos(thetay), R(3, 3)/cos(thetay));
-
- thetaz = atan2(R(2, 1)/cos(thetay), R(1, 1)/cos(thetay));
-
- else
- thetaz = 0;
- if abs(R(3, 1)+1) < 1e-6
- thetay = pi/2;
- thetax = thetaz + atan2(R(1, 2), R(1, 3));
- else
- thetay = -pi/2;
- thetax = -thetaz + atan2(-R(1, 2), -R(1, 3));
- end
- end
-end
-
-end
-
-
-
-
-
-
4 computeReferencePose
-
+
1 computeReferencePose
+
@@ -620,8 +337,8 @@ This Matlab function is accessible
here
-
5 Compute the Sample Position Error w.r.t. the NASS
-
+
2 Compute the Sample Position Error w.r.t. the NASS
+
@@ -658,7 +375,7 @@ MTr = [WTm(1
:3,1
:3)<
Author: Dehaeze Thomas
-
Created: 2020-02-25 mar. 18:20
+
Created: 2020-03-06 ven. 15:09
diff --git a/docs/hac_lac.html b/docs/hac_lac.html
index 55fe05c..4b3c363 100644
--- a/docs/hac_lac.html
+++ b/docs/hac_lac.html
@@ -4,7 +4,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-
+
HAC-LAC applied on the Simscape Model
@@ -202,51 +202,39 @@
+
+
@@ -259,51 +247,44 @@ for the JavaScript code in this tag.
Table of Contents
-
-
1 Undamped System
-
-
+The position \(\bm{\mathcal{X}}\) of the Sample with respect to the granite is measured.
+
+
+
+It is then compare to the wanted position of the Sample \(\bm{r}_\mathcal{X}\) in order to obtain the position error \(\bm{\epsilon}_\mathcal{X}\) of the Sample with respect to a frame attached to the Stewart top platform.
+
+
+
+
-
-
1.1 Identification of the plant
-
-
-
-
1.1.1 Initialize the Simulation
-
+
+
1 Initialization
+
We initialize all the stages with the default parameters.
@@ -324,137 +305,199 @@ The nano-hexapod is a piezoelectric hexapod and the sample has a mass of 50kg.
initializeNanoHexapod('actuator', 'piezo');
-initializeSample('mass', 50);
+initializeSample('mass', 1);
-No disturbances.
+We set the references that corresponds to a tomography experiment.
-
initializeDisturbances('enable', false);
+initializeReferences('Rz_type', 'rotating', 'Rz_period', 1);
-
-We set the references to zero.
-
-
initializeReferences();
+initializeDisturbances();
-And all the controllers are set to 0.
+Open Loop.
initializeController('type', 'open-loop');
-
-
-
-
1.1.2 Identification
-
-First, we identify the dynamics of the system using the linearize
function.
+And we put some gravity.
-
-options = linearizeOptions;
-options.SampleTime = 0;
+initializeSimscapeConfiguration('gravity', true);
+
+
-
+
+We log the signals.
+
+
+
initializeLoggingConfiguration('log', 'all');
+
+
+
+
+
+
+
2 Low Authority Control - Direct Velocity Feedback \(\bm{K}_\mathcal{L}\)
+
+
+The first loop closed corresponds to a direct velocity feedback loop.
+
+
+
+The design of the associated decentralized controller is explained in this file.
+
+
+
+
+
2.1 Identification
+
+
+
mdl = 'nass_model';
clear io; io_i = 1;
-io(io_i) = linio([mdl, '/Controller'], 1, 'openinput'); io_i = io_i + 1;
-io(io_i) = linio([mdl, '/Tracking Error'], 1, 'openoutput', [], 'En'); io_i = io_i + 1;
+io(io_i) = linio([mdl, '/Controller'], 1, 'openinput'); io_i = io_i + 1;
+io(io_i) = linio([mdl, '/Micro-Station'], 3, 'openoutput', [], 'Dnlm'); io_i = io_i + 1;
-G = linearize(mdl, io, options);
-G.InputName = {'Fnl1', 'Fnl2', 'Fnl3', 'Fnl4', 'Fnl5', 'Fnl6'};
-G.OutputName = {'Edx', 'Edy', 'Edz', 'Erx', 'Ery', 'Erz'};
+G_dvf = linearize(mdl, io, 0);
+G_dvf.InputName = {'Fnl1', 'Fnl2', 'Fnl3', 'Fnl4', 'Fnl5', 'Fnl6'};
+G_dvf.OutputName = {'Dnlm1', 'Dnlm2', 'Dnlm3', 'Dnlm4', 'Dnlm5', 'Dnlm6'};
+
+
+
+
+
+
+
2.2 Plant
+
+
+
2.3 Root Locus
+
+
+
2.4 Controller and Loop Gain
+
+
+
K_dvf = s*15000/(1 + s/2/pi/10000);
+
+
K_dvf = -K_dvf*eye(6);
+
+
+
+
+
+
+
+
3 High Authority Control - \(\bm{K}_\mathcal{X}\)
+
+
+
+
3.1 Identification of the damped plant
+
+
+
+
+
initializeController('type', 'hac-dvf');
+
+
+
+
+
+mdl = 'nass_model';
+
+
+clear io; io_i = 1;
+io(io_i) = linio([mdl, '/Controller'], 1, 'input'); io_i = io_i + 1;
+io(io_i) = linio([mdl, '/Tracking Error'], 1, 'output', [], 'En'); io_i = io_i + 1;
+
+
+G = linearize(mdl, io, 0);
+G.InputName = {'Fnl1', 'Fnl2', 'Fnl3', 'Fnl4', 'Fnl5', 'Fnl6'};
+G.OutputName = {'Ex', 'Ey', 'Ez', 'Erx', 'Ery', 'Erz'};
+
+
+
+
+The minus sine is put here because there is already a minus sign included due to the computation of the position error.
+
load('mat/stages.mat', 'nano_hexapod');
-G_cart = minreal(G*inv(nano_hexapod.J'));
-G_cart.InputName = {'Fnx', 'Fny', 'Fnz', 'Mnx', 'Mny', 'Mnz'};
+
+Gx = -G*inv(nano_hexapod.J');
+Gx.InputName = {'Fx', 'Fy', 'Fz', 'Mx', 'My', 'Mz'};
+
+
+
+
+
+
+
3.2 Controller Design
+
+
+The controller consists of:
+
+
+- A pure integrator
+- A Second integrator up to half the wanted bandwidth
+- A Lead around the cross-over frequency
+- A low pass filter with a cut-off equal to two times the wanted bandwidth
+
+
+
+
wc = 2*pi*15;
+
+h = 1.5;
+
+Kx = (1/h) * (1 + s/wc*h)/(1 + s/wc/h) * wc/s * ((s/wc*2 + 1)/(s/wc*2)) * (1/(1 + s/wc/2));
+
+
+Kx = Kx.*diag(1./diag(abs(freqresp(Gx*Kx, wc))));
-
G_legs = minreal(inv(nano_hexapod.J)*G);
-G_legs.OutputName = {'e1', 'e2', 'e3', 'e4', 'e5', 'e6'};
+isstable(feedback(Gx*Kx, eye(6), -1))
-
-
-
-
-
-
1.1.4 Obtained Plants for Active Damping
-
-
-
-
-
-
1.2 Tomography Experiment
-
-
-
-
1.2.1 Simulation
-
-
-We initialize elements for the tomography experiment.
-
-
prepareTomographyExperiment();
+Kx = inv(nano_hexapod.J')*Kx;
-
-We change the simulation stop time.
-
+
+
isstable(feedback(G*Kx, eye(6), 1))
+
+
+
+
+
+
+
+
4 Simulation
+
load('mat/conf_simulink.mat');
-set_param(conf_simulink, 'StopTime', '3');
+set_param(conf_simulink, 'StopTime', '1.5');
@@ -466,186 +509,26 @@ And we simulate the system.
-
-Finally, we save the simulation results for further analysis
-
-
save('./active_damping/mat/tomo_exp.mat', 'En', 'Eg', '-append');
+save('./mat/tomo_exp_hac_lac.mat', 'simout');
-
-
1.2.2 Results
-
-
-We load the results of tomography experiments.
-
+
+
5 Results
+
-
load('./active_damping/mat/tomo_exp.mat', 'En');
-t = linspace(0, 3, length(En(:,1)));
+load('./mat/tomo_exp_hac_lac.mat', 'simout');
-
-
-
-
-
-
-
-
-
-
-
-
1.3 Verification of the transfer function from nano hexapod to metrology
-
-
-
-
1.3.1 Initialize the Simulation
-
-
-We initialize all the stages with the default parameters.
-
-
-
initializeGround();
-initializeGranite();
-initializeTy();
-initializeRy();
-initializeRz();
-initializeMicroHexapod();
-initializeAxisc();
-initializeMirror();
-
-
-
-
-The nano-hexapod is a piezoelectric hexapod and the sample has a mass of 50kg.
-
-
-
initializeNanoHexapod('actuator', 'piezo');
-initializeSample('mass', 50);
-
-
-
-
-No disturbances.
-
-
-
initializeDisturbances('enable', false);
-
-
-
-
-We set the references to zero.
-
-
-
initializeReferences();
-
-
-
-
-And all the controllers are set to 0.
-
-
-
initializeController('type', 'open-loop');
-
-
-
-
-
-
-
1.3.2 Identification
-
-
-First, we identify the dynamics of the system using the linearize
function.
-
-
-
-options = linearizeOptions;
-options.SampleTime = 0;
-
-
-mdl = 'nass_model';
-
-
-clear io; io_i = 1;
-io(io_i) = linio([mdl, '/Controller'], 1, 'openinput'); io_i = io_i + 1;
-io(io_i) = linio([mdl, '/Tracking Error'], 1, 'openoutput', [], 'En'); io_i = io_i + 1;
-
-
-G = linearize(mdl, io, options);
-G.InputName = {'Fnl1', 'Fnl2', 'Fnl3', 'Fnl4', 'Fnl5', 'Fnl6'};
-G.OutputName = {'Edx', 'Edy', 'Edz', 'Erx', 'Ery', 'Erz'};
-
-
-
-
-
load('mat/stages.mat', 'nano_hexapod');
-G_cart = minreal(G*inv(nano_hexapod.J'));
-G_cart.InputName = {'Fnx', 'Fny', 'Fnz', 'Mnx', 'Mny', 'Mnz'};
-
-
-
-
-
G_legs = minreal(inv(nano_hexapod.J)*G);
-G_legs.OutputName = {'e1', 'e2', 'e3', 'e4', 'e5', 'e6'};
-
-
-
-
-
-
-
-
-
1.3.4 Obtained Plants for Active Damping
-
-
Author: Dehaeze Thomas
-
Created: 2020-02-25 mar. 18:20
+
Created: 2020-03-13 ven. 17:39
diff --git a/docs/identification.html b/docs/identification.html
index b05bdd3..78b13f6 100644
--- a/docs/identification.html
+++ b/docs/identification.html
@@ -4,7 +4,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-
+
Identification
@@ -202,50 +202,28 @@
@@ -411,7 +389,7 @@ These functions are all defined
here.
Author: Dehaeze Thomas
-
Created: 2020-02-25 mar. 18:18
+
Created: 2020-03-06 ven. 15:09
diff --git a/docs/kinematics.html b/docs/kinematics.html
index dca11c0..7282706 100644
--- a/docs/kinematics.html
+++ b/docs/kinematics.html
@@ -4,7 +4,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-
+
Kinematics of the station
@@ -202,50 +202,28 @@
+
+
+
+
+
+
Motion and Force Requirements for the Nano-Hexapod
+
+
+
+
+
1 Soft Hexapod
+
+
+As the nano-hexapod is in series with the other stages, it must apply all the force required to move the sample.
+
+
+
+If the nano-hexapod is soft (voice coil), its actuator must apply all the force such that the sample has the wanted motion.
+
+
+
+In some sense, it does not use the fact that the other stage are participating to the displacement of the sample.
+
+
+
+Let’s take two examples:
+
+
+- Sinus Ty translation at 1Hz with an amplitude of 5mm
+- Long stroke hexapod has an offset of 10mm in X and the spindle is rotating
+Thus the wanted motion is a circle with a radius of 10mm
+If the sample if light (30Kg) => 60rpm
+If the sample if heavy (100Kg) => 1rpm
+
+
+
+From the motion, we compute the required acceleration by derive the displacement two times.
+Then from the Newton’s second law: \(m \vec{a} = \sum \vec{F}\) we can compute the required force.
+
+
+
+
+
1.1 Example
+
+
+The wanted motion is:
+
+\begin{align*}
+ x &= d \cos(\omega t) \\
+ y &= d \sin(\omega t)
+\end{align*}
+
+
+The corresponding acceleration is thus:
+
+\begin{align*}
+ \ddot{x} &= - d \omega^2 \cos(\omega t) \\
+ \ddot{y} &= - d \omega^2 \sin(\omega t)
+\end{align*}
+
+
+From the Newton’s second law:
+
+\begin{align*}
+ m \ddot{x} &= F_x \\
+ m \ddot{y} &= F_y
+\end{align*}
+
+
+Thus the applied forces should be:
+
+\begin{align*}
+ F_x &= - m d \omega^2 \cos(\omega t) \\
+ F_y &= - m d \omega^2 \sin(\omega t)
+\end{align*}
+
+
+And the norm of the force is:
+\[ |F| = \sqrt{F_x^2 + F_y^2} = m d \omega^2 \ [N] \]
+
+
+
+
+For a Light sample:
+
+
+
m = 30;
+d = 10e-3;
+w = 2*pi;
+F = m*d*w^2;
+ans = F
+
+
+
+
+11.844
+
+
+
+
+For the Heavy sample:
+
+
+
m = 80;
+d = 10e-3;
+w = 2*pi/60;
+F = m*d*w^2
+ans = F
+
+
+
+
+0.008773
+
+
+
+
+
+
+
Author: Dehaeze Thomas
+
Created: 2020-03-13 ven. 17:39
+
+
+
diff --git a/docs/positioning_error.html b/docs/positioning_error.html
index 60a2ac2..608ab94 100644
--- a/docs/positioning_error.html
+++ b/docs/positioning_error.html
@@ -4,7 +4,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-
+
Computation of the Positioning Error with respect to the nano-hexapod
@@ -202,50 +202,28 @@
@@ -775,7 +753,7 @@ Internal force, acting reciprocally between base and following origins is implem
Author: Dehaeze Thomas
-
Created: 2020-02-25 mar. 18:20
+
Created: 2020-03-06 ven. 15:09
diff --git a/docs/simscape_subsystems.html b/docs/simscape_subsystems.html
index 31032df..b259b53 100644
--- a/docs/simscape_subsystems.html
+++ b/docs/simscape_subsystems.html
@@ -4,7 +4,7 @@
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-
+
Subsystems used for the Simscape Models
@@ -202,50 +202,28 @@
@@ -261,169 +239,170 @@ for the JavaScript code in this tag.
-
-
Function description
-
+
+
Function description
+
function [] = initializeSimscapeConfiguration(args)
@@ -493,9 +472,9 @@ These functions are defined below.
-
-
Optional Parameters
-
+
+
Optional Parameters
+
arguments
args.gravity logical {mustBeNumericOrLogical} = true
@@ -505,9 +484,9 @@ These functions are defined below.
-
-
Structure initialization
-
+
+
Structure initialization
+
conf_simscape = struct();
@@ -515,9 +494,9 @@ These functions are defined below.
-
-
Add Type
-
+
+
Add Type
+
if args.gravity
conf_simscape.type = 1;
@@ -529,9 +508,9 @@ These functions are defined below.
-
-
Save the Structure
-
+
+
Save the Structure
+
save('./mat/conf_simscape.mat', 'conf_simscape');
@@ -548,9 +527,9 @@ These functions are defined below.
-
-
Function description
-
+
+
Function description
+
function [] = initializeLoggingConfiguration(args)
@@ -558,9 +537,9 @@ These functions are defined below.
-
-
Optional Parameters
-
+
+
Optional Parameters
+
arguments
args.log char {mustBeMember(args.log,{'none', 'all', 'forces'})} = 'none'
@@ -571,9 +550,9 @@ These functions are defined below.
-
-
Structure initialization
-
+
+
Structure initialization
+
conf_log = struct();
@@ -581,9 +560,9 @@ These functions are defined below.
-
-
Add Type
-
+
+
Add Type
+
switch args.log
case 'none'
@@ -608,9 +587,9 @@ These functions are defined below.
-
-
Save the Structure
-
+
+
Save the Structure
+
save('./mat/conf_log.mat', 'conf_log');
@@ -627,9 +606,9 @@ These functions are defined below.
-
-
Simscape Model
-
+
+
Simscape Model
+
The model of the Ground is composed of:
@@ -654,9 +633,9 @@ The model of the Ground is composed of:
-
-
Function description
-
+
+
Function description
+
function [ground] = initializeGround(args)
@@ -664,21 +643,22 @@ The model of the Ground is composed of:
-
-
Optional Parameters
-
+
+
Optional Parameters
+
arguments
- args.type char {mustBeMember(args.type,{'none', 'rigid'})} = 'rigid'
+ args.type char {mustBeMember(args.type,{'none', 'rigid'})} = 'rigid'
+ args.rot_point (3,1) double {mustBeNumeric} = zeros(3,1)
end
-
-
Structure initialization
-
+
+
Structure initialization
+
First, we initialize the granite
structure.
@@ -689,9 +669,9 @@ First, we initialize the
granite
structure.
-
-
Add Type
-
+
+
Add Type
+
switch args.type
case 'none'
@@ -718,9 +698,19 @@ ground.density = 2800;
-
-
Save the Structure
-
+
+
Rotation Point
+
+
+
ground.rot_point = args.rot_point;
+
+
+
+
+
+
+
Save the Structure
+
The ground
structure is saved.
@@ -740,9 +730,9 @@ The
ground
structure is saved.
-
-
Simscape Model
-
+
+
Simscape Model
+
The Simscape model of the granite is composed of:
@@ -771,9 +761,9 @@ The output
sample_pos
corresponds to the impact point of the X-ray.
-
-
Function description
-
+
+
Function description
+
function [granite] = initializeGranite(args)
@@ -781,9 +771,9 @@ The output
sample_pos
corresponds to the impact point of the X-ray.
-
-
Optional Parameters
-
+
+
Optional Parameters
+
arguments
args.type char {mustBeMember(args.type,{'rigid', 'flexible', 'none', 'modal-analysis', 'init'})} = 'flexible'
@@ -799,9 +789,9 @@ The output sample_pos
corresponds to the impact point of the X-ray.
-
-
Structure initialization
-
+
+
Structure initialization
+
First, we initialize the granite
structure.
@@ -833,9 +823,9 @@ First, we initialize the
granite
structure.
-
-
Material and Geometry
-
+
+
Material and Geometry
+
Properties of the Material and link to the geometry of the granite.
@@ -855,9 +845,9 @@ Z-offset for the initial position of the sample with respect to the granite top
-
-
Stiffness and Damping properties
-
+
+
Stiffness and Damping properties
+
granite.K = [4e9; 3e8; 8e8];
granite.C = [4.0e5; 1.1e5; 9.0e5];
@@ -866,9 +856,9 @@ granite.C = [4.0e5; 1.1e5; 9.0e5];
-
-
Equilibrium position of the each joint.
-
+
+
Equilibrium position of the each joint.
+
if args.Foffset && ~strcmp(args.type, 'none') && ~strcmp(args.type, 'rigid') && ~strcmp(args.type, 'init')
load('mat/Foffset.mat', 'Fgm');
@@ -881,9 +871,9 @@ granite.C = [4.0e5; 1.1e5; 9.0e5];
-
-
Save the Structure
-
+
+
Save the Structure
+
The granite
structure is saved.
@@ -895,17 +885,17 @@ The
granite
structure is saved.
-
-
5 Translation Stage
+
+
5 Translation Stage
-
-
Simscape Model
-
+
+
Simscape Model
+
The Simscape model of the Translation stage consist of:
@@ -935,9 +925,9 @@ It is used to impose the motion in the Y direction
-
-
Function description
-
+
+
Function description
+
function [ty] = initializeTy(args)
@@ -945,9 +935,9 @@ It is used to impose the motion in the Y direction
-
-
Optional Parameters
-
+
+
Optional Parameters
+
arguments
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible', 'modal-analysis', 'init'})} = 'flexible'
@@ -958,9 +948,9 @@ It is used to impose the motion in the Y direction
-
-
Structure initialization
-
+
+
Structure initialization
+
First, we initialize the ty
structure.
@@ -992,9 +982,9 @@ First, we initialize the
ty
structure.
-
-
Material and Geometry
-
+
+
Material and Geometry
+
Define the density of the materials as well as the geometry (STEP files).
@@ -1039,9 +1029,9 @@ ty.rotor.STEP =
'./STEPS/ty/Ty_Motor_Rotor.S
-
-
Stiffness and Damping properties
-
+
+
Stiffness and Damping properties
+
ty.K = [2e8; 1e8; 2e8; 6e7; 9e7; 6e7];
ty.C = [8e4; 5e4; 8e4; 2e4; 3e4; 2e4];
@@ -1050,9 +1040,9 @@ ty.C = [8e4; 5e4; 8e4; 2e4; 3e4; 2e4];
-
-
Equilibrium position of the each joint.
-
+
+
Equilibrium position of the each joint.
+
if args.Foffset && ~strcmp(args.type, 'none') && ~strcmp(args.type, 'rigid') && ~strcmp(args.type, 'init')
load('mat/Foffset.mat', 'Ftym');
@@ -1065,9 +1055,9 @@ ty.C = [8e4; 5e4; 8e4; 2e4; 3e4; 2e4];
-
-
Save the Structure
-
+
+
Save the Structure
+
The ty
structure is saved.
@@ -1079,17 +1069,17 @@ The
ty
structure is saved.
-
-
6 Tilt Stage
+
+
6 Tilt Stage
-
-
Simscape Model
-
+
+
Simscape Model
+
The Simscape model of the Tilt stage is composed of:
@@ -1119,9 +1109,9 @@ The Ry motion is imposed by the input.
-
-
Function description
-
+
+
Function description
+
function [ry] = initializeRy(args)
@@ -1129,9 +1119,9 @@ The Ry motion is imposed by the input.
-
-
Optional Parameters
-
+
+
Optional Parameters
+
arguments
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible', 'modal-analysis', 'init'})} = 'flexible'
@@ -1143,9 +1133,9 @@ The Ry motion is imposed by the input.
-
-
Structure initialization
-
+
+
Structure initialization
+
First, we initialize the ry
structure.
@@ -1178,9 +1168,9 @@ First, we initialize the
ry
structure.
-
-
Material and Geometry
-
+
+
Material and Geometry
+
Properties of the Material and link to the geometry of the Tilt stage.
@@ -1218,9 +1208,9 @@ Z-Offset so that the center of rotation matches the sample center;
-
-
Stiffness and Damping properties
-
+
+
Stiffness and Damping properties
+
ry.K = [3.8e8; 4e8; 3.8e8; 1.2e8; 6e4; 1.2e8];
ry.C = [1e5; 1e5; 1e5; 3e4; 1e3; 3e4];
@@ -1229,9 +1219,9 @@ ry.C = [1e5; 1e5; 1e5; 3e4; 1e3; 3e4];
-
-
Equilibrium position of the each joint.
-
+
+
Equilibrium position of the each joint.
+
if args.Foffset && ~strcmp(args.type, 'none') && ~strcmp(args.type, 'rigid') && ~strcmp(args.type, 'init')
load('mat/Foffset.mat', 'Fym');
@@ -1244,9 +1234,9 @@ ry.C = [1e5; 1e5; 1e5; 3e4; 1e3; 3e4];
-
-
Save the Structure
-
+
+
Save the Structure
+
The ry
structure is saved.
@@ -1258,17 +1248,17 @@ The
ry
structure is saved.
-
-
7 Spindle
+
+
7 Spindle
-
-
Simscape Model
-
+
+
Simscape Model
+
The Simscape model of the Spindle is composed of:
@@ -1294,9 +1284,9 @@ The Simscape model of the Spindle is composed of:
-
-
Function description
-
+
+
Function description
+
function [rz] = initializeRz(args)
@@ -1304,9 +1294,9 @@ The Simscape model of the Spindle is composed of:
-
-
Optional Parameters
-
+
+
Optional Parameters
+
arguments
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible', 'modal-analysis', 'init'})} = 'flexible'
@@ -1317,9 +1307,9 @@ The Simscape model of the Spindle is composed of:
-
-
Structure initialization
-
+
+
Structure initialization
+
First, we initialize the rz
structure.
@@ -1351,9 +1341,9 @@ First, we initialize the
rz
structure.
-
-
Material and Geometry
-
+
+
Material and Geometry
+
Properties of the Material and link to the geometry of the spindle.
@@ -1374,9 +1364,9 @@ rz.stator.STEP =
'./STEPS/rz/Spindle_Stator.STEP'<
-
-
Stiffness and Damping properties
-
+
+
Stiffness and Damping properties
+
rz.K = [7e8; 7e8; 2e9; 1e7; 1e7; 1e7];
rz.C = [4e4; 4e4; 7e4; 1e4; 1e4; 1e4];
@@ -1385,9 +1375,9 @@ rz.C = [4e4; 4e4; 7e4; 1e4; 1e4; 1e4];
-
-
Equilibrium position of the each joint.
-
+
+
Equilibrium position of the each joint.
+
if args.Foffset && ~strcmp(args.type, 'none') && ~strcmp(args.type, 'rigid') && ~strcmp(args.type, 'init')
load('mat/Foffset.mat', 'Fzm');
@@ -1400,9 +1390,9 @@ rz.C = [4e4; 4e4; 7e4; 1e4; 1e4; 1e4];
-
-
Save the Structure
-
+
+
Save the Structure
+
The rz
structure is saved.
@@ -1414,17 +1404,17 @@ The
rz
structure is saved.
-
-
8 Micro Hexapod
+
+
8 Micro Hexapod
-
-
Simscape Model
-
+
+
Simscape Model
+
-
-
Function description
-
+
+
Function description
+
function [micro_hexapod] = initializeMicroHexapod(args)
@@ -1451,9 +1441,9 @@ The
rz
structure is saved.
-
-
Optional Parameters
-
+
+
Optional Parameters
+
arguments
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible', 'modal-analysis', 'init'})} = 'flexible'
@@ -1495,9 +1485,9 @@ The rz
structure is saved.
-
-
Function content
-
+
+
Function content
+
micro_hexapod = initializeFramesPositions('H', args.H, 'MO_B', args.MO_B);
micro_hexapod = generateGeneralConfiguration(micro_hexapod, 'FH', args.FH, 'FR', args.FR, 'FTh', args.FTh, 'MH', args.MH, 'MR', args.MR, 'MTh', args.MTh);
@@ -1527,9 +1517,9 @@ Equilibrium position of the each joint.
-
-
Add Type
-
+
+
Add Type
+
switch args.type
case 'none'
@@ -1548,9 +1538,9 @@ Equilibrium position of the each joint.
-
-
Save the Structure
-
+
+
Save the Structure
+
The micro_hexapod
structure is saved.
@@ -1570,9 +1560,9 @@ The
micro_hexapod
structure is saved.
-
-
Simscape Model
-
+
+
Simscape Model
+
The Simscape model of the Center of gravity compensator is composed of:
@@ -1597,9 +1587,9 @@ The Simscape model of the Center of gravity compensator is composed of:
-
-
Function description
-
+
+
Function description
+
function [axisc] = initializeAxisc(args)
@@ -1607,9 +1597,9 @@ The Simscape model of the Center of gravity compensator is composed of:
-
-
Optional Parameters
-
+
+
Optional Parameters
+
arguments
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
@@ -1619,9 +1609,9 @@ The Simscape model of the Center of gravity compensator is composed of:
-
-
Structure initialization
-
+
+
Structure initialization
+
First, we initialize the axisc
structure.
@@ -1632,9 +1622,9 @@ First, we initialize the
axisc
structure.
-
-
Add Type
-
+
+
Add Type
+
switch args.type
case 'none'
@@ -1649,9 +1639,9 @@ First, we initialize the axisc
structure.
-
-
Material and Geometry
-
+
+
Material and Geometry
+
Properties of the Material and link to the geometry files.
@@ -1676,9 +1666,9 @@ axisc.gear.STEP =
'./STEPS/axisc/axisc_gear.STE
-
-
Save the Structure
-
+
+
Save the Structure
+
The axisc
structure is saved.
@@ -1698,9 +1688,9 @@ The
axisc
structure is saved.
-
-
Simscape Model
-
+
+
Simscape Model
+
The Simscape Model of the mirror is just a solid body.
The output mirror_center
corresponds to the center of the Sphere and is the point of measurement for the metrology
@@ -1722,9 +1712,9 @@ The output mirror_center
corresponds to the center of the Sphere an
-
-
Function description
-
+
+
Function description
+
function [] = initializeMirror(args)
@@ -1732,9 +1722,9 @@ The output
mirror_center
corresponds to the center of the Sphere an
-
-
Optional Parameters
-
+
+
Optional Parameters
+
arguments
args.type char {mustBeMember(args.type,{'none', 'rigid'})} = 'rigid'
@@ -1746,9 +1736,9 @@ The output mirror_center
corresponds to the center of the Sphere an
-
-
Structure initialization
-
+
+
Structure initialization
+
First, we initialize the mirror
structure.
@@ -1774,9 +1764,9 @@ First, we initialize the
mirror
structure.
-
-
Material and Geometry
-
+
+
Material and Geometry
+
We define the geometrical values.
@@ -1853,9 +1843,9 @@ Finally, we close the shape.
-
-
Save the Structure
-
+
+
Save the Structure
+
The mirror
structure is saved.
@@ -1867,17 +1857,17 @@ The
mirror
structure is saved.
-
-
11 Nano Hexapod
+
+
11 Nano Hexapod
-
-
Simscape Model
-
+
+
Simscape Model
+
-
-
Function description
-
+
+
Function description
+
function [nano_hexapod] = initializeNanoHexapod(args)
@@ -1904,9 +1894,9 @@ The
mirror
structure is saved.
-
-
Optional Parameters
-
+
+
Optional Parameters
+
arguments
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
@@ -1947,9 +1937,9 @@ The mirror
structure is saved.
-
-
Function content
-
+
+
Function content
+
nano_hexapod = initializeFramesPositions('H', args.H, 'MO_B', args.MO_B);
nano_hexapod = generateGeneralConfiguration(nano_hexapod, 'FH', args.FH, 'FR', args.FR, 'FTh', args.FTh, 'MH', args.MH, 'MR', args.MR, 'MTh', args.MTh);
@@ -1977,9 +1967,9 @@ nano_hexapod.dLi = dLi;
-
-
Add Type
-
+
+
Add Type
+
switch args.type
case 'none'
@@ -1994,9 +1984,9 @@ nano_hexapod.dLi = dLi;
-
-
Save the Structure
-
+
+
Save the Structure
+
save('./mat/stages.mat', 'nano_hexapod', '-append');
@@ -2013,9 +2003,9 @@ nano_hexapod.dLi = dLi;
-
-
Simscape Model
-
+
+
Simscape Model
+
The Simscape model of the sample environment is composed of:
@@ -2043,9 +2033,9 @@ This could be the case for cable forces for instance.
-
-
Function description
-
+
+
Function description
+
function [sample] = initializeSample(args)
@@ -2053,9 +2043,9 @@ This could be the case for cable forces for instance.
-