Update beam height (remove 25mm to match the experiments)
This commit is contained in:
parent
fb81352caf
commit
647b360342
@ -1,4 +1,4 @@
|
|||||||
function [granite] = initializeGranite(args)
|
function [granite] = initializeGranite(args)
|
||||||
|
|
||||||
arguments
|
arguments
|
||||||
args.type char {mustBeMember(args.type,{'rigid', 'flexible', 'none'})} = 'flexible'
|
args.type char {mustBeMember(args.type,{'rigid', 'flexible', 'none'})} = 'flexible'
|
||||||
@ -8,7 +8,7 @@
|
|||||||
args.x0 (1,1) double {mustBeNumeric} = 0 % Rest position of the Joint in the X direction [m]
|
args.x0 (1,1) double {mustBeNumeric} = 0 % Rest position of the Joint in the X direction [m]
|
||||||
args.y0 (1,1) double {mustBeNumeric} = 0 % Rest position of the Joint in the Y direction [m]
|
args.y0 (1,1) double {mustBeNumeric} = 0 % Rest position of the Joint in the Y direction [m]
|
||||||
args.z0 (1,1) double {mustBeNumeric} = 0 % Rest position of the Joint in the Z direction [m]
|
args.z0 (1,1) double {mustBeNumeric} = 0 % Rest position of the Joint in the Z direction [m]
|
||||||
args.sample_pos (1,1) double {mustBeNumeric} = 0.8 % Height of the measurment point [m]
|
args.sample_pos (1,1) double {mustBeNumeric} = 0.775 % Height of the measurment point [m]
|
||||||
end
|
end
|
||||||
|
|
||||||
granite = struct();
|
granite = struct();
|
||||||
@ -25,21 +25,24 @@
|
|||||||
granite.density = args.density; % [kg/m3]
|
granite.density = args.density; % [kg/m3]
|
||||||
granite.STEP = 'granite.STEP';
|
granite.STEP = 'granite.STEP';
|
||||||
|
|
||||||
|
% Z-offset for the initial position of the sample with respect to the granite top surface.
|
||||||
granite.sample_pos = args.sample_pos; % [m]
|
granite.sample_pos = args.sample_pos; % [m]
|
||||||
|
|
||||||
granite.K = args.K; % [N/m]
|
granite.K = args.K; % [N/m]
|
||||||
granite.C = args.C; % [N/(m/s)]
|
granite.C = args.C; % [N/(m/s)]
|
||||||
|
|
||||||
if exist('./mat', 'dir')
|
if exist('./mat', 'dir')
|
||||||
if exist('./mat/nass_model_stages.mat', 'file')
|
if exist('./mat/nass_model_stages.mat', 'file')
|
||||||
save('mat/nass_model_stages.mat', 'granite', '-append');
|
save('mat/nass_model_stages.mat', 'granite', '-append');
|
||||||
else
|
else
|
||||||
save('mat/nass_model_stages.mat', 'granite');
|
save('mat/nass_model_stages.mat', 'granite');
|
||||||
end
|
end
|
||||||
elseif exist('./matlab', 'dir')
|
elseif exist('./matlab', 'dir')
|
||||||
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
||||||
save('matlab/mat/nass_model_stages.mat', 'granite', '-append');
|
save('matlab/mat/nass_model_stages.mat', 'granite', '-append');
|
||||||
else
|
else
|
||||||
save('matlab/mat/nass_model_stages.mat', 'granite');
|
save('matlab/mat/nass_model_stages.mat', 'granite');
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
function [ground] = initializeGround(args)
|
function [ground] = initializeGround(args)
|
||||||
|
|
||||||
arguments
|
arguments
|
||||||
args.type char {mustBeMember(args.type,{'none', 'rigid'})} = 'rigid'
|
args.type char {mustBeMember(args.type,{'none', 'rigid'})} = 'rigid'
|
||||||
@ -19,16 +19,17 @@
|
|||||||
|
|
||||||
ground.rot_point = args.rot_point;
|
ground.rot_point = args.rot_point;
|
||||||
|
|
||||||
if exist('./mat', 'dir')
|
if exist('./mat', 'dir')
|
||||||
if exist('./mat/nass_model_stages.mat', 'file')
|
if exist('./mat/nass_model_stages.mat', 'file')
|
||||||
save('mat/nass_model_stages.mat', 'ground', '-append');
|
save('mat/nass_model_stages.mat', 'ground', '-append');
|
||||||
else
|
else
|
||||||
save('mat/nass_model_stages.mat', 'ground');
|
save('mat/nass_model_stages.mat', 'ground');
|
||||||
end
|
end
|
||||||
elseif exist('./matlab', 'dir')
|
elseif exist('./matlab', 'dir')
|
||||||
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
||||||
save('matlab/mat/nass_model_stages.mat', 'ground', '-append');
|
save('matlab/mat/nass_model_stages.mat', 'ground', '-append');
|
||||||
else
|
else
|
||||||
save('matlab/mat/nass_model_stages.mat', 'ground');
|
save('matlab/mat/nass_model_stages.mat', 'ground');
|
||||||
end
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
function [micro_hexapod] = initializeMicroHexapod(args)
|
function [micro_hexapod] = initializeMicroHexapod(args)
|
||||||
|
|
||||||
arguments
|
arguments
|
||||||
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
|
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
|
||||||
@ -91,17 +91,18 @@
|
|||||||
stewart.type = 2;
|
stewart.type = 2;
|
||||||
end
|
end
|
||||||
|
|
||||||
micro_hexapod = stewart;
|
micro_hexapod = stewart;
|
||||||
if exist('./mat', 'dir')
|
if exist('./mat', 'dir')
|
||||||
if exist('./mat/nass_model_stages.mat', 'file')
|
if exist('./mat/nass_model_stages.mat', 'file')
|
||||||
save('mat/nass_model_stages.mat', 'micro_hexapod', '-append');
|
save('mat/nass_model_stages.mat', 'micro_hexapod', '-append');
|
||||||
else
|
else
|
||||||
save('mat/nass_model_stages.mat', 'micro_hexapod');
|
save('mat/nass_model_stages.mat', 'micro_hexapod');
|
||||||
end
|
end
|
||||||
elseif exist('./matlab', 'dir')
|
elseif exist('./matlab', 'dir')
|
||||||
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
||||||
save('matlab/mat/nass_model_stages.mat', 'micro_hexapod', '-append');
|
save('matlab/mat/nass_model_stages.mat', 'micro_hexapod', '-append');
|
||||||
else
|
else
|
||||||
save('matlab/mat/nass_model_stages.mat', 'micro_hexapod');
|
save('matlab/mat/nass_model_stages.mat', 'micro_hexapod');
|
||||||
end
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
function [ry] = initializeRy(args)
|
function [ry] = initializeRy(args)
|
||||||
|
|
||||||
arguments
|
arguments
|
||||||
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
|
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
|
||||||
@ -32,6 +32,7 @@
|
|||||||
ry.stage.density = 7800; % [kg/m3]
|
ry.stage.density = 7800; % [kg/m3]
|
||||||
ry.stage.STEP = 'Tilt_Stage.STEP';
|
ry.stage.STEP = 'Tilt_Stage.STEP';
|
||||||
|
|
||||||
|
% Z-Offset so that the center of rotation matches the sample center;
|
||||||
ry.z_offset = 0.58178; % [m]
|
ry.z_offset = 0.58178; % [m]
|
||||||
|
|
||||||
ry.Ry_init = args.Ry_init; % [rad]
|
ry.Ry_init = args.Ry_init; % [rad]
|
||||||
@ -39,16 +40,18 @@
|
|||||||
ry.K = [3.8e8; 4e8; 3.8e8; 1.2e8; 6e4; 1.2e8];
|
ry.K = [3.8e8; 4e8; 3.8e8; 1.2e8; 6e4; 1.2e8];
|
||||||
ry.C = [1e5; 1e5; 1e5; 3e4; 1e3; 3e4];
|
ry.C = [1e5; 1e5; 1e5; 3e4; 1e3; 3e4];
|
||||||
|
|
||||||
if exist('./mat', 'dir')
|
if exist('./mat', 'dir')
|
||||||
if exist('./mat/nass_model_stages.mat', 'file')
|
if exist('./mat/nass_model_stages.mat', 'file')
|
||||||
save('mat/nass_model_stages.mat', 'ry', '-append');
|
save('mat/nass_model_stages.mat', 'ry', '-append');
|
||||||
else
|
else
|
||||||
save('mat/nass_model_stages.mat', 'ry');
|
save('mat/nass_model_stages.mat', 'ry');
|
||||||
end
|
end
|
||||||
elseif exist('./matlab', 'dir')
|
elseif exist('./matlab', 'dir')
|
||||||
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
||||||
save('matlab/mat/nass_model_stages.mat', 'ry', '-append');
|
save('matlab/mat/nass_model_stages.mat', 'ry', '-append');
|
||||||
else
|
else
|
||||||
save('matlab/mat/nass_model_stages.mat', 'ry');
|
save('matlab/mat/nass_model_stages.mat', 'ry');
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
function [rz] = initializeRz(args)
|
function [rz] = initializeRz(args)
|
||||||
|
|
||||||
arguments
|
arguments
|
||||||
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
|
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
|
||||||
@ -30,16 +30,18 @@
|
|||||||
rz.K = [7e8; 7e8; 2e9; 1e7; 1e7; 1e7];
|
rz.K = [7e8; 7e8; 2e9; 1e7; 1e7; 1e7];
|
||||||
rz.C = [4e4; 4e4; 7e4; 1e4; 1e4; 1e4];
|
rz.C = [4e4; 4e4; 7e4; 1e4; 1e4; 1e4];
|
||||||
|
|
||||||
if exist('./mat', 'dir')
|
if exist('./mat', 'dir')
|
||||||
if exist('./mat/nass_model_stages.mat', 'file')
|
if exist('./mat/nass_model_stages.mat', 'file')
|
||||||
save('mat/nass_model_stages.mat', 'rz', '-append');
|
save('mat/nass_model_stages.mat', 'rz', '-append');
|
||||||
else
|
else
|
||||||
save('mat/nass_model_stages.mat', 'rz');
|
save('mat/nass_model_stages.mat', 'rz');
|
||||||
end
|
end
|
||||||
elseif exist('./matlab', 'dir')
|
elseif exist('./matlab', 'dir')
|
||||||
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
||||||
save('matlab/mat/nass_model_stages.mat', 'rz', '-append');
|
save('matlab/mat/nass_model_stages.mat', 'rz', '-append');
|
||||||
else
|
else
|
||||||
save('matlab/mat/nass_model_stages.mat', 'rz');
|
save('matlab/mat/nass_model_stages.mat', 'rz');
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
function [ty] = initializeTy(args)
|
function [ty] = initializeTy(args)
|
||||||
|
|
||||||
arguments
|
arguments
|
||||||
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
|
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
|
||||||
@ -54,16 +54,18 @@
|
|||||||
ty.K = [2e8; 1e8; 2e8; 6e7; 9e7; 6e7]; % [N/m, N*m/rad]
|
ty.K = [2e8; 1e8; 2e8; 6e7; 9e7; 6e7]; % [N/m, N*m/rad]
|
||||||
ty.C = [8e4; 5e4; 8e4; 2e4; 3e4; 1e4]; % [N/(m/s), N*m/(rad/s)]
|
ty.C = [8e4; 5e4; 8e4; 2e4; 3e4; 1e4]; % [N/(m/s), N*m/(rad/s)]
|
||||||
|
|
||||||
if exist('./mat', 'dir')
|
if exist('./mat', 'dir')
|
||||||
if exist('./mat/nass_model_stages.mat', 'file')
|
if exist('./mat/nass_model_stages.mat', 'file')
|
||||||
save('mat/nass_model_stages.mat', 'ty', '-append');
|
save('mat/nass_model_stages.mat', 'ty', '-append');
|
||||||
else
|
else
|
||||||
save('mat/nass_model_stages.mat', 'ty');
|
save('mat/nass_model_stages.mat', 'ty');
|
||||||
end
|
end
|
||||||
elseif exist('./matlab', 'dir')
|
elseif exist('./matlab', 'dir')
|
||||||
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
||||||
save('matlab/mat/nass_model_stages.mat', 'ty', '-append');
|
save('matlab/mat/nass_model_stages.mat', 'ty', '-append');
|
||||||
else
|
else
|
||||||
save('matlab/mat/nass_model_stages.mat', 'ty');
|
save('matlab/mat/nass_model_stages.mat', 'ty');
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
Binary file not shown.
@ -3202,83 +3202,48 @@ function [xc,yc,R,a] = circlefit(x,y)
|
|||||||
|
|
||||||
** Initialize Micro-Station Stages
|
** Initialize Micro-Station Stages
|
||||||
*** =initializeGround=: Ground
|
*** =initializeGround=: Ground
|
||||||
:PROPERTIES:
|
#+begin_src matlab :tangle matlab/src/initializeGround.m :comments none :mkdirp yes :eval no
|
||||||
:header-args:matlab+: :tangle matlab/src/initializeGround.m
|
function [ground] = initializeGround(args)
|
||||||
:header-args:matlab+: :comments none :mkdirp yes :eval no
|
|
||||||
:END:
|
|
||||||
|
|
||||||
**** Function description
|
|
||||||
#+begin_src matlab
|
|
||||||
function [ground] = initializeGround(args)
|
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Optional Parameters
|
|
||||||
#+begin_src matlab
|
|
||||||
arguments
|
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) % Rotation point for the ground motion [m]
|
args.rot_point (3,1) double {mustBeNumeric} = zeros(3,1) % Rotation point for the ground motion [m]
|
||||||
end
|
end
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Structure initialization
|
|
||||||
First, we initialize the =granite= structure.
|
|
||||||
#+begin_src matlab
|
|
||||||
ground = struct();
|
ground = struct();
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Add Type
|
|
||||||
#+begin_src matlab
|
|
||||||
switch args.type
|
switch args.type
|
||||||
case 'none'
|
case 'none'
|
||||||
ground.type = 0;
|
ground.type = 0;
|
||||||
case 'rigid'
|
case 'rigid'
|
||||||
ground.type = 1;
|
ground.type = 1;
|
||||||
end
|
end
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Ground Solid properties
|
|
||||||
We set the shape and density of the ground solid element.
|
|
||||||
#+begin_src matlab
|
|
||||||
ground.shape = [2, 2, 0.5]; % [m]
|
ground.shape = [2, 2, 0.5]; % [m]
|
||||||
ground.density = 2800; % [kg/m3]
|
ground.density = 2800; % [kg/m3]
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Rotation Point
|
|
||||||
|
|
||||||
#+begin_src matlab
|
|
||||||
ground.rot_point = args.rot_point;
|
ground.rot_point = args.rot_point;
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Save the Structure
|
if exist('./mat', 'dir')
|
||||||
#+begin_src matlab
|
|
||||||
if exist('./mat', 'dir')
|
|
||||||
if exist('./mat/nass_model_stages.mat', 'file')
|
if exist('./mat/nass_model_stages.mat', 'file')
|
||||||
save('mat/nass_model_stages.mat', 'ground', '-append');
|
save('mat/nass_model_stages.mat', 'ground', '-append');
|
||||||
else
|
else
|
||||||
save('mat/nass_model_stages.mat', 'ground');
|
save('mat/nass_model_stages.mat', 'ground');
|
||||||
end
|
end
|
||||||
elseif exist('./matlab', 'dir')
|
elseif exist('./matlab', 'dir')
|
||||||
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
||||||
save('matlab/mat/nass_model_stages.mat', 'ground', '-append');
|
save('matlab/mat/nass_model_stages.mat', 'ground', '-append');
|
||||||
else
|
else
|
||||||
save('matlab/mat/nass_model_stages.mat', 'ground');
|
save('matlab/mat/nass_model_stages.mat', 'ground');
|
||||||
end
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** =initializeGranite=: Granite
|
*** =initializeGranite=: Granite
|
||||||
:PROPERTIES:
|
#+begin_src matlab :tangle matlab/src/initializeGranite.m :comments none :mkdirp yes :eval no
|
||||||
:header-args:matlab+: :tangle matlab/src/initializeGranite.m
|
function [granite] = initializeGranite(args)
|
||||||
:header-args:matlab+: :comments none :mkdirp yes :eval no
|
|
||||||
:END:
|
|
||||||
|
|
||||||
**** Function description
|
|
||||||
#+begin_src matlab
|
|
||||||
function [granite] = initializeGranite(args)
|
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Optional Parameters
|
|
||||||
#+begin_src matlab
|
|
||||||
arguments
|
arguments
|
||||||
args.type char {mustBeMember(args.type,{'rigid', 'flexible', 'none'})} = 'flexible'
|
args.type char {mustBeMember(args.type,{'rigid', 'flexible', 'none'})} = 'flexible'
|
||||||
args.density (1,1) double {mustBeNumeric, mustBeNonnegative} = 2800 % Density [kg/m3]
|
args.density (1,1) double {mustBeNumeric, mustBeNonnegative} = 2800 % Density [kg/m3]
|
||||||
@ -3287,18 +3252,11 @@ end
|
|||||||
args.x0 (1,1) double {mustBeNumeric} = 0 % Rest position of the Joint in the X direction [m]
|
args.x0 (1,1) double {mustBeNumeric} = 0 % Rest position of the Joint in the X direction [m]
|
||||||
args.y0 (1,1) double {mustBeNumeric} = 0 % Rest position of the Joint in the Y direction [m]
|
args.y0 (1,1) double {mustBeNumeric} = 0 % Rest position of the Joint in the Y direction [m]
|
||||||
args.z0 (1,1) double {mustBeNumeric} = 0 % Rest position of the Joint in the Z direction [m]
|
args.z0 (1,1) double {mustBeNumeric} = 0 % Rest position of the Joint in the Z direction [m]
|
||||||
args.sample_pos (1,1) double {mustBeNumeric} = 0.8 % Height of the measurment point [m]
|
args.sample_pos (1,1) double {mustBeNumeric} = 0.775 % Height of the measurment point [m]
|
||||||
end
|
end
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Structure initialization
|
|
||||||
First, we initialize the =granite= structure.
|
|
||||||
#+begin_src matlab
|
|
||||||
granite = struct();
|
granite = struct();
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Add Granite Type
|
|
||||||
#+begin_src matlab
|
|
||||||
switch args.type
|
switch args.type
|
||||||
case 'none'
|
case 'none'
|
||||||
granite.type = 0;
|
granite.type = 0;
|
||||||
@ -3307,71 +3265,43 @@ First, we initialize the =granite= structure.
|
|||||||
case 'flexible'
|
case 'flexible'
|
||||||
granite.type = 2;
|
granite.type = 2;
|
||||||
end
|
end
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Material and Geometry
|
|
||||||
|
|
||||||
Properties of the Material and link to the geometry of the granite.
|
|
||||||
#+begin_src matlab
|
|
||||||
granite.density = args.density; % [kg/m3]
|
granite.density = args.density; % [kg/m3]
|
||||||
granite.STEP = 'granite.STEP';
|
granite.STEP = 'granite.STEP';
|
||||||
#+end_src
|
|
||||||
|
|
||||||
Z-offset for the initial position of the sample with respect to the granite top surface.
|
% Z-offset for the initial position of the sample with respect to the granite top surface.
|
||||||
#+begin_src matlab
|
|
||||||
granite.sample_pos = args.sample_pos; % [m]
|
granite.sample_pos = args.sample_pos; % [m]
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Stiffness and Damping properties
|
|
||||||
|
|
||||||
#+begin_src matlab
|
|
||||||
granite.K = args.K; % [N/m]
|
granite.K = args.K; % [N/m]
|
||||||
granite.C = args.C; % [N/(m/s)]
|
granite.C = args.C; % [N/(m/s)]
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Save the Structure
|
if exist('./mat', 'dir')
|
||||||
#+begin_src matlab
|
|
||||||
if exist('./mat', 'dir')
|
|
||||||
if exist('./mat/nass_model_stages.mat', 'file')
|
if exist('./mat/nass_model_stages.mat', 'file')
|
||||||
save('mat/nass_model_stages.mat', 'granite', '-append');
|
save('mat/nass_model_stages.mat', 'granite', '-append');
|
||||||
else
|
else
|
||||||
save('mat/nass_model_stages.mat', 'granite');
|
save('mat/nass_model_stages.mat', 'granite');
|
||||||
end
|
end
|
||||||
elseif exist('./matlab', 'dir')
|
elseif exist('./matlab', 'dir')
|
||||||
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
||||||
save('matlab/mat/nass_model_stages.mat', 'granite', '-append');
|
save('matlab/mat/nass_model_stages.mat', 'granite', '-append');
|
||||||
else
|
else
|
||||||
save('matlab/mat/nass_model_stages.mat', 'granite');
|
save('matlab/mat/nass_model_stages.mat', 'granite');
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** =initializeTy=: Translation Stage
|
*** =initializeTy=: Translation Stage
|
||||||
:PROPERTIES:
|
#+begin_src matlab :tangle matlab/src/initializeTy.m :comments none :mkdirp yes :eval no
|
||||||
:header-args:matlab+: :tangle matlab/src/initializeTy.m
|
function [ty] = initializeTy(args)
|
||||||
:header-args:matlab+: :comments none :mkdirp yes :eval no
|
|
||||||
:END:
|
|
||||||
|
|
||||||
**** Function description
|
|
||||||
#+begin_src matlab
|
|
||||||
function [ty] = initializeTy(args)
|
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Optional Parameters
|
|
||||||
#+begin_src matlab
|
|
||||||
arguments
|
arguments
|
||||||
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
|
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
|
||||||
end
|
end
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Structure initialization
|
|
||||||
First, we initialize the =ty= structure.
|
|
||||||
#+begin_src matlab
|
|
||||||
ty = struct();
|
ty = struct();
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Add Translation Stage Type
|
|
||||||
#+begin_src matlab
|
|
||||||
switch args.type
|
switch args.type
|
||||||
case 'none'
|
case 'none'
|
||||||
ty.type = 0;
|
ty.type = 0;
|
||||||
@ -3380,11 +3310,7 @@ First, we initialize the =ty= structure.
|
|||||||
case 'flexible'
|
case 'flexible'
|
||||||
ty.type = 2;
|
ty.type = 2;
|
||||||
end
|
end
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Material and Geometry
|
|
||||||
Define the density of the materials as well as the geometry (STEP files).
|
|
||||||
#+begin_src matlab
|
|
||||||
% Ty Granite frame
|
% Ty Granite frame
|
||||||
ty.granite_frame.density = 7800; % [kg/m3] => 43kg
|
ty.granite_frame.density = 7800; % [kg/m3] => 43kg
|
||||||
ty.granite_frame.STEP = 'Ty_Granite_Frame.STEP';
|
ty.granite_frame.STEP = 'Ty_Granite_Frame.STEP';
|
||||||
@ -3420,60 +3346,38 @@ Define the density of the materials as well as the geometry (STEP files).
|
|||||||
% Ty Rotor Part
|
% Ty Rotor Part
|
||||||
ty.rotor.density = 5400; % [kg/m3]
|
ty.rotor.density = 5400; % [kg/m3]
|
||||||
ty.rotor.STEP = 'Ty_Motor_Rotor.STEP';
|
ty.rotor.STEP = 'Ty_Motor_Rotor.STEP';
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Stiffness and Damping properties
|
|
||||||
|
|
||||||
#+begin_src matlab
|
|
||||||
ty.K = [2e8; 1e8; 2e8; 6e7; 9e7; 6e7]; % [N/m, N*m/rad]
|
ty.K = [2e8; 1e8; 2e8; 6e7; 9e7; 6e7]; % [N/m, N*m/rad]
|
||||||
ty.C = [8e4; 5e4; 8e4; 2e4; 3e4; 1e4]; % [N/(m/s), N*m/(rad/s)]
|
ty.C = [8e4; 5e4; 8e4; 2e4; 3e4; 1e4]; % [N/(m/s), N*m/(rad/s)]
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Save the Structure
|
if exist('./mat', 'dir')
|
||||||
#+begin_src matlab
|
|
||||||
if exist('./mat', 'dir')
|
|
||||||
if exist('./mat/nass_model_stages.mat', 'file')
|
if exist('./mat/nass_model_stages.mat', 'file')
|
||||||
save('mat/nass_model_stages.mat', 'ty', '-append');
|
save('mat/nass_model_stages.mat', 'ty', '-append');
|
||||||
else
|
else
|
||||||
save('mat/nass_model_stages.mat', 'ty');
|
save('mat/nass_model_stages.mat', 'ty');
|
||||||
end
|
end
|
||||||
elseif exist('./matlab', 'dir')
|
elseif exist('./matlab', 'dir')
|
||||||
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
||||||
save('matlab/mat/nass_model_stages.mat', 'ty', '-append');
|
save('matlab/mat/nass_model_stages.mat', 'ty', '-append');
|
||||||
else
|
else
|
||||||
save('matlab/mat/nass_model_stages.mat', 'ty');
|
save('matlab/mat/nass_model_stages.mat', 'ty');
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** =initializeRy=: Tilt Stage
|
*** =initializeRy=: Tilt Stage
|
||||||
:PROPERTIES:
|
#+begin_src matlab :tangle matlab/src/initializeRy.m :comments none :mkdirp yes :eval no
|
||||||
:header-args:matlab+: :tangle matlab/src/initializeRy.m
|
function [ry] = initializeRy(args)
|
||||||
:header-args:matlab+: :comments none :mkdirp yes :eval no
|
|
||||||
:END:
|
|
||||||
|
|
||||||
**** Function description
|
|
||||||
#+begin_src matlab
|
|
||||||
function [ry] = initializeRy(args)
|
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Optional Parameters
|
|
||||||
#+begin_src matlab
|
|
||||||
arguments
|
arguments
|
||||||
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
|
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
|
||||||
args.Ry_init (1,1) double {mustBeNumeric} = 0
|
args.Ry_init (1,1) double {mustBeNumeric} = 0
|
||||||
end
|
end
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Structure initialization
|
|
||||||
First, we initialize the =ry= structure.
|
|
||||||
#+begin_src matlab
|
|
||||||
ry = struct();
|
ry = struct();
|
||||||
#+end_src
|
|
||||||
|
|
||||||
|
|
||||||
**** Add Tilt Type
|
|
||||||
#+begin_src matlab
|
|
||||||
switch args.type
|
switch args.type
|
||||||
case 'none'
|
case 'none'
|
||||||
ry.type = 0;
|
ry.type = 0;
|
||||||
@ -3482,11 +3386,7 @@ First, we initialize the =ry= structure.
|
|||||||
case 'flexible'
|
case 'flexible'
|
||||||
ry.type = 2;
|
ry.type = 2;
|
||||||
end
|
end
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Material and Geometry
|
|
||||||
Properties of the Material and link to the geometry of the Tilt stage.
|
|
||||||
#+begin_src matlab
|
|
||||||
% Ry - Guide for the tilt stage
|
% Ry - Guide for the tilt stage
|
||||||
ry.guide.density = 7800; % [kg/m3]
|
ry.guide.density = 7800; % [kg/m3]
|
||||||
ry.guide.STEP = 'Tilt_Guide.STEP';
|
ry.guide.STEP = 'Tilt_Guide.STEP';
|
||||||
@ -3502,67 +3402,42 @@ Properties of the Material and link to the geometry of the Tilt stage.
|
|||||||
% Ry - Plateau Tilt
|
% Ry - Plateau Tilt
|
||||||
ry.stage.density = 7800; % [kg/m3]
|
ry.stage.density = 7800; % [kg/m3]
|
||||||
ry.stage.STEP = 'Tilt_Stage.STEP';
|
ry.stage.STEP = 'Tilt_Stage.STEP';
|
||||||
#+end_src
|
|
||||||
|
|
||||||
Z-Offset so that the center of rotation matches the sample center;
|
% Z-Offset so that the center of rotation matches the sample center;
|
||||||
#+begin_src matlab
|
|
||||||
ry.z_offset = 0.58178; % [m]
|
ry.z_offset = 0.58178; % [m]
|
||||||
#+end_src
|
|
||||||
|
|
||||||
#+begin_src matlab
|
|
||||||
ry.Ry_init = args.Ry_init; % [rad]
|
ry.Ry_init = args.Ry_init; % [rad]
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Stiffness and Damping properties
|
|
||||||
|
|
||||||
#+begin_src matlab
|
|
||||||
ry.K = [3.8e8; 4e8; 3.8e8; 1.2e8; 6e4; 1.2e8];
|
ry.K = [3.8e8; 4e8; 3.8e8; 1.2e8; 6e4; 1.2e8];
|
||||||
ry.C = [1e5; 1e5; 1e5; 3e4; 1e3; 3e4];
|
ry.C = [1e5; 1e5; 1e5; 3e4; 1e3; 3e4];
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Save the Structure
|
if exist('./mat', 'dir')
|
||||||
#+begin_src matlab
|
|
||||||
if exist('./mat', 'dir')
|
|
||||||
if exist('./mat/nass_model_stages.mat', 'file')
|
if exist('./mat/nass_model_stages.mat', 'file')
|
||||||
save('mat/nass_model_stages.mat', 'ry', '-append');
|
save('mat/nass_model_stages.mat', 'ry', '-append');
|
||||||
else
|
else
|
||||||
save('mat/nass_model_stages.mat', 'ry');
|
save('mat/nass_model_stages.mat', 'ry');
|
||||||
end
|
end
|
||||||
elseif exist('./matlab', 'dir')
|
elseif exist('./matlab', 'dir')
|
||||||
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
||||||
save('matlab/mat/nass_model_stages.mat', 'ry', '-append');
|
save('matlab/mat/nass_model_stages.mat', 'ry', '-append');
|
||||||
else
|
else
|
||||||
save('matlab/mat/nass_model_stages.mat', 'ry');
|
save('matlab/mat/nass_model_stages.mat', 'ry');
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** =initializeRz=: Spindle
|
*** =initializeRz=: Spindle
|
||||||
:PROPERTIES:
|
#+begin_src matlab :tangle matlab/src/initializeRz.m :comments none :mkdirp yes :eval no
|
||||||
:header-args:matlab+: :tangle matlab/src/initializeRz.m
|
function [rz] = initializeRz(args)
|
||||||
:header-args:matlab+: :comments none :mkdirp yes :eval no
|
|
||||||
:END:
|
|
||||||
|
|
||||||
**** Function description
|
|
||||||
#+begin_src matlab
|
|
||||||
function [rz] = initializeRz(args)
|
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Optional Parameters
|
|
||||||
#+begin_src matlab
|
|
||||||
arguments
|
arguments
|
||||||
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
|
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
|
||||||
end
|
end
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Structure initialization
|
|
||||||
First, we initialize the =rz= structure.
|
|
||||||
#+begin_src matlab
|
|
||||||
rz = struct();
|
rz = struct();
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Add Spindle Type
|
|
||||||
#+begin_src matlab
|
|
||||||
switch args.type
|
switch args.type
|
||||||
case 'none'
|
case 'none'
|
||||||
rz.type = 0;
|
rz.type = 0;
|
||||||
@ -3571,12 +3446,7 @@ First, we initialize the =rz= structure.
|
|||||||
case 'flexible'
|
case 'flexible'
|
||||||
rz.type = 2;
|
rz.type = 2;
|
||||||
end
|
end
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Material and Geometry
|
|
||||||
|
|
||||||
Properties of the Material and link to the geometry of the spindle.
|
|
||||||
#+begin_src matlab
|
|
||||||
% Spindle - Slip Ring
|
% Spindle - Slip Ring
|
||||||
rz.slipring.density = 7800; % [kg/m3]
|
rz.slipring.density = 7800; % [kg/m3]
|
||||||
rz.slipring.STEP = 'Spindle_Slip_Ring.STEP';
|
rz.slipring.STEP = 'Spindle_Slip_Ring.STEP';
|
||||||
@ -3588,45 +3458,32 @@ Properties of the Material and link to the geometry of the spindle.
|
|||||||
% Spindle - Stator
|
% Spindle - Stator
|
||||||
rz.stator.density = 7800; % [kg/m3]
|
rz.stator.density = 7800; % [kg/m3]
|
||||||
rz.stator.STEP = 'Spindle_Stator.STEP';
|
rz.stator.STEP = 'Spindle_Stator.STEP';
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Stiffness and Damping properties
|
|
||||||
|
|
||||||
#+begin_src matlab
|
|
||||||
rz.K = [7e8; 7e8; 2e9; 1e7; 1e7; 1e7];
|
rz.K = [7e8; 7e8; 2e9; 1e7; 1e7; 1e7];
|
||||||
rz.C = [4e4; 4e4; 7e4; 1e4; 1e4; 1e4];
|
rz.C = [4e4; 4e4; 7e4; 1e4; 1e4; 1e4];
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Save the Structure
|
if exist('./mat', 'dir')
|
||||||
#+begin_src matlab
|
|
||||||
if exist('./mat', 'dir')
|
|
||||||
if exist('./mat/nass_model_stages.mat', 'file')
|
if exist('./mat/nass_model_stages.mat', 'file')
|
||||||
save('mat/nass_model_stages.mat', 'rz', '-append');
|
save('mat/nass_model_stages.mat', 'rz', '-append');
|
||||||
else
|
else
|
||||||
save('mat/nass_model_stages.mat', 'rz');
|
save('mat/nass_model_stages.mat', 'rz');
|
||||||
end
|
end
|
||||||
elseif exist('./matlab', 'dir')
|
elseif exist('./matlab', 'dir')
|
||||||
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
||||||
save('matlab/mat/nass_model_stages.mat', 'rz', '-append');
|
save('matlab/mat/nass_model_stages.mat', 'rz', '-append');
|
||||||
else
|
else
|
||||||
save('matlab/mat/nass_model_stages.mat', 'rz');
|
save('matlab/mat/nass_model_stages.mat', 'rz');
|
||||||
end
|
end
|
||||||
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
*** =initializeMicroHexapod=: Micro Hexapod
|
*** =initializeMicroHexapod=: Micro Hexapod
|
||||||
:PROPERTIES:
|
|
||||||
:header-args:matlab+: :tangle matlab/src/initializeMicroHexapod.m
|
|
||||||
:header-args:matlab+: :comments none :mkdirp yes :eval no
|
|
||||||
:END:
|
|
||||||
|
|
||||||
**** Function description
|
#+begin_src matlab :tangle matlab/src/initializeMicroHexapod.m :comments none :mkdirp yes :eval no
|
||||||
#+begin_src matlab
|
function [micro_hexapod] = initializeMicroHexapod(args)
|
||||||
function [micro_hexapod] = initializeMicroHexapod(args)
|
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Optional Parameters
|
|
||||||
#+begin_src matlab
|
|
||||||
arguments
|
arguments
|
||||||
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
|
args.type char {mustBeMember(args.type,{'none', 'rigid', 'flexible'})} = 'flexible'
|
||||||
% initializeFramesPositions
|
% initializeFramesPositions
|
||||||
@ -3660,10 +3517,7 @@ end
|
|||||||
args.AP (3,1) double {mustBeNumeric} = zeros(3,1)
|
args.AP (3,1) double {mustBeNumeric} = zeros(3,1)
|
||||||
args.ARB (3,3) double {mustBeNumeric} = eye(3)
|
args.ARB (3,3) double {mustBeNumeric} = eye(3)
|
||||||
end
|
end
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Function content
|
|
||||||
#+begin_src matlab
|
|
||||||
stewart = initializeStewartPlatform();
|
stewart = initializeStewartPlatform();
|
||||||
|
|
||||||
stewart = initializeFramesPositions(stewart, ...
|
stewart = initializeFramesPositions(stewart, ...
|
||||||
@ -3679,9 +3533,7 @@ end
|
|||||||
'MTh', args.MTh);
|
'MTh', args.MTh);
|
||||||
|
|
||||||
stewart = computeJointsPose(stewart);
|
stewart = computeJointsPose(stewart);
|
||||||
#+end_src
|
|
||||||
|
|
||||||
#+begin_src matlab
|
|
||||||
stewart = initializeStrutDynamics(stewart, ...
|
stewart = initializeStrutDynamics(stewart, ...
|
||||||
'K', args.Ki, ...
|
'K', args.Ki, ...
|
||||||
'C', args.Ci);
|
'C', args.Ci);
|
||||||
@ -3689,9 +3541,7 @@ end
|
|||||||
stewart = initializeJointDynamics(stewart, ...
|
stewart = initializeJointDynamics(stewart, ...
|
||||||
'type_F', 'universal_p', ...
|
'type_F', 'universal_p', ...
|
||||||
'type_M', 'spherical_p');
|
'type_M', 'spherical_p');
|
||||||
#+end_src
|
|
||||||
|
|
||||||
#+begin_src matlab
|
|
||||||
stewart = initializeCylindricalPlatforms(stewart, ...
|
stewart = initializeCylindricalPlatforms(stewart, ...
|
||||||
'Fpm', args.Fpm, ...
|
'Fpm', args.Fpm, ...
|
||||||
'Fph', args.Fph, ...
|
'Fph', args.Fph, ...
|
||||||
@ -3713,14 +3563,9 @@ end
|
|||||||
stewart = initializeStewartPose(stewart, ...
|
stewart = initializeStewartPose(stewart, ...
|
||||||
'AP', args.AP, ...
|
'AP', args.AP, ...
|
||||||
'ARB', args.ARB);
|
'ARB', args.ARB);
|
||||||
#+end_src
|
|
||||||
|
|
||||||
#+begin_src matlab
|
|
||||||
stewart = initializeInertialSensor(stewart, 'type', 'none');
|
stewart = initializeInertialSensor(stewart, 'type', 'none');
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Add Type
|
|
||||||
#+begin_src matlab
|
|
||||||
switch args.type
|
switch args.type
|
||||||
case 'none'
|
case 'none'
|
||||||
stewart.type = 0;
|
stewart.type = 0;
|
||||||
@ -3729,23 +3574,21 @@ end
|
|||||||
case 'flexible'
|
case 'flexible'
|
||||||
stewart.type = 2;
|
stewart.type = 2;
|
||||||
end
|
end
|
||||||
#+end_src
|
|
||||||
|
|
||||||
**** Save the Structure
|
micro_hexapod = stewart;
|
||||||
#+begin_src matlab
|
if exist('./mat', 'dir')
|
||||||
micro_hexapod = stewart;
|
|
||||||
if exist('./mat', 'dir')
|
|
||||||
if exist('./mat/nass_model_stages.mat', 'file')
|
if exist('./mat/nass_model_stages.mat', 'file')
|
||||||
save('mat/nass_model_stages.mat', 'micro_hexapod', '-append');
|
save('mat/nass_model_stages.mat', 'micro_hexapod', '-append');
|
||||||
else
|
else
|
||||||
save('mat/nass_model_stages.mat', 'micro_hexapod');
|
save('mat/nass_model_stages.mat', 'micro_hexapod');
|
||||||
end
|
end
|
||||||
elseif exist('./matlab', 'dir')
|
elseif exist('./matlab', 'dir')
|
||||||
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
if exist('./matlab/mat/nass_model_stages.mat', 'file')
|
||||||
save('matlab/mat/nass_model_stages.mat', 'micro_hexapod', '-append');
|
save('matlab/mat/nass_model_stages.mat', 'micro_hexapod', '-append');
|
||||||
else
|
else
|
||||||
save('matlab/mat/nass_model_stages.mat', 'micro_hexapod');
|
save('matlab/mat/nass_model_stages.mat', 'micro_hexapod');
|
||||||
end
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
#+end_src
|
#+end_src
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user