diff --git a/demonstration/Micro_Station_Displacement.slx b/demonstration/Micro_Station_Displacement.slx index f585019..17076da 100644 Binary files a/demonstration/Micro_Station_Displacement.slx and b/demonstration/Micro_Station_Displacement.slx differ diff --git a/demonstration/sample_pos_init.m b/demonstration/sample_pos_init.m index e958e61..65cae45 100644 --- a/demonstration/sample_pos_init.m +++ b/demonstration/sample_pos_init.m @@ -3,7 +3,7 @@ clear; close all; clc; %% Initialize simulation configuration opts_sim = struct(... - 'Tsim', 1 ... + 'Tsim', 1 ... ); initializeSimConf(opts_sim); @@ -14,10 +14,10 @@ load('./mat/sim_conf.mat', 'sim_conf') time_vector = 0:sim_conf.Ts:sim_conf.Tsim; % Translation Stage -ty = 0.05*ones(length(time_vector), 1); +ty = 0*ones(length(time_vector), 1); % Tilt Stage -ry = 2*pi*(3/360)*ones(length(time_vector), 1); +ry = 2*pi*(0/360)*ones(length(time_vector), 1); % ry = 2*pi*(3/360)*sin(2*pi*time_vector); % Spindle diff --git a/demonstration/sample_pos_sim.m b/demonstration/sample_pos_sim.m index 6c36ede..3d332e3 100644 --- a/demonstration/sample_pos_sim.m +++ b/demonstration/sample_pos_sim.m @@ -2,4 +2,4 @@ clear; close all; clc; %% -sim('Micro_Station_Displacement.slx'); \ No newline at end of file +sim('Micro_Station_Displacement.slx'); diff --git a/identification/id_G_d_plots.m b/identification/id_G_d_plots.m index a2ff795..f8b97a8 100644 --- a/identification/id_G_d_plots.m +++ b/identification/id_G_d_plots.m @@ -2,7 +2,7 @@ clear; close all; clc; %% Load the identified transfer functions -save('./mat/G.mat', 'G_light_vc', 'G_light_pz', 'G_heavy_vc', 'G_heavy_pz'); +load('./mat/G.mat', 'G_light_vc', 'G_light_pz', 'G_heavy_vc', 'G_heavy_pz'); %% Load Configuration file load('./mat/config.mat', 'save_fig', 'freqs'); diff --git a/identification/id_flexible_rigid.m b/identification/id_flexible_rigid.m index 249bfed..9bcecac 100644 --- a/identification/id_flexible_rigid.m +++ b/identification/id_flexible_rigid.m @@ -13,7 +13,7 @@ options = linearizeOptions; options.SampleTime = 0; %% Name of the Simulink File -mdl = 'simscape_id_micro_station'; +mdl = 'sim_micro_station'; %% Micro-Hexapod % Input/Output definition @@ -32,11 +32,11 @@ G_ms_flexible = linearize(mdl, io, 0); % Input/Output names G_ms_flexible.InputName = {'Fmx', 'Fmy', 'Fmz',... - 'Fgx', 'Fgy', 'Fgz'}; + 'Fgx', 'Fgy', 'Fgz'}; G_ms_flexible.OutputName = {'Dmx', 'Dmy', 'Dmz', ... - 'Tyx', 'Tyy', 'Tyz', ... - 'Ryx', 'Ryy', 'Ryz', ... - 'Dgx', 'Dgy', 'Dgz'}; + 'Tyx', 'Tyy', 'Tyz', ... + 'Ryx', 'Ryy', 'Ryz', ... + 'Dgx', 'Dgy', 'Dgz'}; %% Run the linearization initializeTy(struct('rigid', true)); diff --git a/identification/id_main.m b/identification/id_main.m index fd73bea..6be661e 100644 --- a/identification/id_main.m +++ b/identification/id_main.m @@ -30,3 +30,13 @@ run id_stages.m % Plot de obtained transfer functions run id_stages_plots.m + +%% Identification of the variation of the plant +run id_plant_variation.m + +run id_plant_variation_plots.m + +%% Study the effect of the flexibility of each Stage +run id_flexible_rigid.m + +run id_flexible_rigid_plots.m diff --git a/identification/id_micro_station.m b/identification/id_micro_station.m index dd7e2df..8f7aef4 100644 --- a/identification/id_micro_station.m +++ b/identification/id_micro_station.m @@ -11,7 +11,7 @@ options = linearizeOptions; options.SampleTime = 0; %% Name of the Simulink File -mdl = 'simscape_id_micro_station'; +mdl = 'sim_micro_station'; %% Micro-Hexapod % Input/Output definition diff --git a/identification/id_nano_station.m b/identification/id_nano_station.m index cd343e6..fa4cc01 100644 --- a/identification/id_nano_station.m +++ b/identification/id_nano_station.m @@ -2,8 +2,9 @@ clear; close all; clc; %% +K = tf(zeros(6)); K_iff = tf(zeros(6)); -save('./mat/controllers.mat', 'K_iff', '-append'); +save('./mat/controllers.mat', 'K', 'K_iff', '-append'); %% Light Sample initializeSample(struct('mass', 1)); diff --git a/initialize/initializeGranite.m b/initialize/initializeGranite.m index 3f57082..91db88a 100644 --- a/initialize/initializeGranite.m +++ b/initialize/initializeGranite.m @@ -1,10 +1,17 @@ -function [] = initializeGranite() +function [granite] = initializeGranite() %% granite = struct(); granite.m = 2000; % [kg] - granite.k.ax = 1e8; % [N/m] x-y-z Stiffness of the granite - granite.c.ax = 1e4; % [N/(m/s)] + + granite.k.x = 1e8; % [N/m] + granite.c.x = 1e4; % [N/(m/s)] + + granite.k.y = 1e8; % [N/m] + granite.c.y = 1e4; % [N/(m/s)] + + granite.k.z = 1e8; % [N/m] + granite.c.z = 1e4; % [N/(m/s)] %% Save save('./mat/stages.mat', 'granite', '-append'); diff --git a/initialize/initializeMicroHexapod.m b/initialize/initializeMicroHexapod.m index 899d61f..2457810 100644 --- a/initialize/initializeMicroHexapod.m +++ b/initialize/initializeMicroHexapod.m @@ -1,4 +1,4 @@ -function [] = initializeMicroHexapod(opts_param) +function [micro_hexapod] = initializeMicroHexapod(opts_param) %% Default values for opts opts = struct(); diff --git a/initialize/initializeSample.m b/initialize/initializeSample.m index 51e30d2..deff75b 100644 --- a/initialize/initializeSample.m +++ b/initialize/initializeSample.m @@ -1,4 +1,4 @@ -function [] = initializeSample(opts_param) +function [sample] = initializeSample(opts_param) %% Default values for opts sample = struct('radius', 100, ... 'height', 300, ... @@ -13,7 +13,17 @@ function [] = initializeSample(opts_param) sample.(opt{1}) = opts_param.(opt{1}); end end + + %% + sample.k.x = 1e8; + sample.c.x = sqrt(sample.k.x*sample.mass)/10; - %% Save if no output argument + sample.k.y = 1e8; + sample.c.y = sqrt(sample.k.y*sample.mass)/10; + + sample.k.z = 1e8; + sample.c.z = sqrt(sample.k.y*sample.mass)/10; + + %% Save save('./mat/stages.mat', 'sample', '-append'); end diff --git a/nass_library.slx b/nass_library.slx new file mode 100644 index 0000000..f8f61b5 Binary files /dev/null and b/nass_library.slx differ