Finished to rework all file
This commit is contained in:
1 parent
d24ebeb2fc
commit
925ac9c3c5
64 files changed
+3567
-437556
No files matched your search
File diff suppressed because it is too large.
Load diff
Binary file not shown.
|
After Width: | Height: | Size: 159 KiB |
File renamed without changes.
+981
-2428
File diff suppressed because it is too large.
Load diff
@@ -45,7 +45,7 @@ In this document, Finite Element Models (FEM) of parts of the Nano-Hexapod are d
|
||||
A first geometry of a Flexible joint is modelled and its characteristics are identified from the Stiffness matrix as well as from the Simscape model.
|
||||
- Section [[sec:flexor_025]]:
|
||||
An optimized flexible joint is developed for the Nano-Hexapod and is then imported in a Simscape model.
|
||||
- Section [[sec:strut_fem]]:
|
||||
- Section [[sec:strut_encoder]]:
|
||||
A super element of a complete strut is exported.
|
||||
|
||||
* APA300ML
|
||||
@@ -1482,7 +1482,10 @@ Its parameters are compared with the Flexible Joint with a size of 0.25mm in the
|
||||
| Torsion Stiffness Rz [Nm/rad] | 260.2 | 538.0 |
|
||||
|
||||
* Complete Strut with Encoder
|
||||
<<sec:strut_fem>>
|
||||
:PROPERTIES:
|
||||
:header-args:matlab+: :tangle matlab/strut_encoder.m
|
||||
:END:
|
||||
<<sec:strut_encoder>>
|
||||
** Introduction
|
||||
|
||||
Now, the full nano-hexapod strut is modelled using Ansys.
|
||||
@@ -1491,7 +1494,13 @@ The 3D as well as the interface nodes are shown in Figure [[fig:strut_encoder_po
|
||||
|
||||
#+name: fig:strut_encoder_points3
|
||||
#+caption: Interface points
|
||||
[[file:figs/strut_fem_nodes.jpg]]
|
||||
[[file:figs/strut_encoder_nodes.jpg]]
|
||||
|
||||
A side view is shown in Figure [[fig:strut_encoder_nodes_side]].
|
||||
|
||||
#+name: fig:strut_encoder_nodes_side
|
||||
#+caption: Interface points - Side view
|
||||
[[file:figs/strut_encoder_nodes_side.jpg]]
|
||||
|
||||
The flexible joints used have a 0.25mm width size.
|
||||
|
||||
@@ -1504,8 +1513,13 @@ The flexible joints used have a 0.25mm width size.
|
||||
<<matlab-init>>
|
||||
#+end_src
|
||||
|
||||
#+begin_src matlab
|
||||
addpath('./data/strut_encoder/');
|
||||
#+begin_src matlab :tangle no
|
||||
addpath('matlab/');
|
||||
addpath('matlab/strut_encoder/');
|
||||
#+end_src
|
||||
|
||||
#+begin_src matlab :eval no
|
||||
addpath('strut_encoder/');
|
||||
#+end_src
|
||||
|
||||
#+begin_src matlab
|
||||
@@ -1515,51 +1529,10 @@ The flexible joints used have a 0.25mm width size.
|
||||
** Import Mass Matrix, Stiffness Matrix, and Interface Nodes Coordinates
|
||||
We first extract the stiffness and mass matrices.
|
||||
#+begin_src matlab
|
||||
K = readmatrix('mat_K.CSV');
|
||||
M = readmatrix('mat_M.CSV');
|
||||
K = readmatrix('strut_encoder_mat_K.CSV');
|
||||
M = readmatrix('strut_encoder_mat_M.CSV');
|
||||
#+end_src
|
||||
|
||||
Then, we extract the coordinates of the interface nodes.
|
||||
#+begin_src matlab
|
||||
[int_xyz, int_i, n_xyz, n_i, nodes] = extractNodes('out_nodes_3D.txt');
|
||||
#+end_src
|
||||
|
||||
#+begin_src matlab
|
||||
save('./mat/strut_encoder.mat', 'int_xyz', 'int_i', 'n_xyz', 'n_i', 'nodes', 'M', 'K');
|
||||
#+end_src
|
||||
|
||||
** Output parameters
|
||||
#+begin_src matlab
|
||||
load('./mat/strut_encoder.mat', 'int_xyz', 'int_i', 'n_xyz', 'n_i', 'nodes', 'M', 'K');
|
||||
#+end_src
|
||||
|
||||
#+begin_src matlab :exports results :results value table replace :tangle no
|
||||
data2orgtable([length(n_i); length(int_i); size(M,1) - 6*length(int_i); size(M,1)], {'Total number of Nodes', 'Number of interface Nodes', 'Number of Modes', 'Size of M and K matrices'}, {}, ' %.0f ');
|
||||
#+end_src
|
||||
|
||||
#+RESULTS:
|
||||
| Total number of Nodes | 8 |
|
||||
| Number of interface Nodes | 8 |
|
||||
| Number of Modes | 6 |
|
||||
| Size of M and K matrices | 54 |
|
||||
|
||||
#+begin_src matlab :exports results :results value table replace :tangle no :post addhdr(*this*)
|
||||
data2orgtable([[1:length(int_i)]', int_i, int_xyz], {}, {'Node i', 'Node Number', 'x [m]', 'y [m]', 'z [m]'}, ' %f ');
|
||||
#+end_src
|
||||
|
||||
#+caption: Coordinates of the interface nodes
|
||||
#+RESULTS:
|
||||
| Node i | Node Number | x [m] | y [m] | z [m] |
|
||||
|--------+-------------+---------+--------+----------|
|
||||
| 1.0 | 504411.0 | 0.0 | 0.0 | 0.0405 |
|
||||
| 2.0 | 504412.0 | 0.0 | 0.0 | -0.0405 |
|
||||
| 3.0 | 504413.0 | -0.0325 | 0.0 | 0.0 |
|
||||
| 4.0 | 504414.0 | -0.0125 | 0.0 | 0.0 |
|
||||
| 5.0 | 504415.0 | -0.0075 | 0.0 | 0.0 |
|
||||
| 6.0 | 504416.0 | 0.0325 | 0.0 | 0.0 |
|
||||
| 7.0 | 504417.0 | 0.004 | 0.0145 | -0.00175 |
|
||||
| 8.0 | 504418.0 | 0.004 | 0.0166 | -0.00175 |
|
||||
|
||||
#+begin_src matlab :exports results :results value table replace :tangle no
|
||||
data2orgtable(K(1:10, 1:10), {}, {}, ' %.1g ');
|
||||
#+end_src
|
||||
@@ -1595,11 +1568,41 @@ Then, we extract the coordinates of the interface nodes.
|
||||
| 8e-05 | 8e-05 | 0.0005 | -2e-08 | -7e-09 | -5e-09 | 0.003 | -0.02 | 0.08 | -5e-06 |
|
||||
| -5e-10 | -3e-08 | -3e-08 | 6e-12 | 6e-13 | 1e-12 | 1e-06 | 0.0001 | -5e-06 | 2e-06 |
|
||||
|
||||
|
||||
Then, we extract the coordinates of the interface nodes.
|
||||
#+begin_src matlab
|
||||
[int_xyz, int_i, n_xyz, n_i, nodes] = extractNodes('strut_encoder_out_nodes_3D.txt');
|
||||
#+end_src
|
||||
|
||||
#+begin_src matlab :exports results :results value table replace :tangle no
|
||||
data2orgtable([length(n_i); length(int_i); size(M,1) - 6*length(int_i); size(M,1)], {'Total number of Nodes', 'Number of interface Nodes', 'Number of Modes', 'Size of M and K matrices'}, {}, ' %.0f ');
|
||||
#+end_src
|
||||
|
||||
#+RESULTS:
|
||||
| Total number of Nodes | 8 |
|
||||
| Number of interface Nodes | 8 |
|
||||
| Number of Modes | 6 |
|
||||
| Size of M and K matrices | 54 |
|
||||
|
||||
#+begin_src matlab :exports results :results value table replace :tangle no :post addhdr(*this*)
|
||||
data2orgtable([[1:length(int_i)]', int_i, int_xyz], {}, {'Node i', 'Node Number', 'x [m]', 'y [m]', 'z [m]'}, ' %f ');
|
||||
#+end_src
|
||||
|
||||
#+caption: Coordinates of the interface nodes
|
||||
#+RESULTS:
|
||||
| Node i | Node Number | x [m] | y [m] | z [m] |
|
||||
|--------+-------------+---------+--------+----------|
|
||||
| 1.0 | 504411.0 | 0.0 | 0.0 | 0.0405 |
|
||||
| 2.0 | 504412.0 | 0.0 | 0.0 | -0.0405 |
|
||||
| 3.0 | 504413.0 | -0.0325 | 0.0 | 0.0 |
|
||||
| 4.0 | 504414.0 | -0.0125 | 0.0 | 0.0 |
|
||||
| 5.0 | 504415.0 | -0.0075 | 0.0 | 0.0 |
|
||||
| 6.0 | 504416.0 | 0.0325 | 0.0 | 0.0 |
|
||||
| 7.0 | 504417.0 | 0.004 | 0.0145 | -0.00175 |
|
||||
| 8.0 | 504418.0 | 0.004 | 0.0166 | -0.00175 |
|
||||
|
||||
Using =K=, =M= and =int_xyz=, we can use the =Reduced Order Flexible Solid= simscape block.
|
||||
|
||||
|
||||
|
||||
|
||||
** Piezoelectric parameters
|
||||
Parameters for the APA300ML:
|
||||
|
||||
@@ -1630,7 +1633,7 @@ The dynamics is identified from the applied force to the measured relative displ
|
||||
%% Input/Output definition
|
||||
clear io; io_i = 1;
|
||||
io(io_i) = linio([mdl, '/Fa'], 1, 'openinput'); io_i = io_i + 1;
|
||||
io(io_i) = linio([mdl, '/L'], 1, 'openoutput'); io_i = io_i + 1;
|
||||
io(io_i) = linio([mdl, '/L'], 1, 'openoutput'); io_i = io_i + 1;
|
||||
|
||||
Gh = -linearize(mdl, io);
|
||||
#+end_src
|
||||
@@ -1648,10 +1651,9 @@ The same dynamics is identified for a payload mass of 10Kg.
|
||||
freqs = logspace(0, 4, 5000);
|
||||
|
||||
figure;
|
||||
tiledlayout(2, 1, 'TileSpacing', 'None', 'Padding', 'None');
|
||||
tiledlayout(3, 1, 'TileSpacing', 'None', 'Padding', 'None');
|
||||
|
||||
% ax1 = subplot(2,1,1);
|
||||
ax1 = nexttile;
|
||||
ax1 = nexttile([2,1]);
|
||||
hold on;
|
||||
plot(freqs, abs(squeeze(freqresp(Gh, freqs, 'Hz'))), '-');
|
||||
plot(freqs, abs(squeeze(freqresp(Ghm, freqs, 'Hz'))), '-');
|
||||
@@ -1662,7 +1664,6 @@ The same dynamics is identified for a payload mass of 10Kg.
|
||||
hold off;
|
||||
|
||||
ax2 = nexttile;
|
||||
% ax2 = subplot(2,1,2);
|
||||
hold on;
|
||||
plot(freqs, 180/pi*angle(squeeze(freqresp(Gh, freqs, 'Hz'))), '-', ...
|
||||
'DisplayName', '$m = 0kg$');
|
||||
@@ -1670,17 +1671,25 @@ The same dynamics is identified for a payload mass of 10Kg.
|
||||
'DisplayName', '$m = 10kg$');
|
||||
set(gca, 'XScale', 'log'); set(gca, 'YScale', 'lin');
|
||||
yticks(-360:90:360);
|
||||
% ylim([-360 0]);
|
||||
ylim([-180 180]);
|
||||
xlabel('Frequency [Hz]'); ylabel('Phase [deg]');
|
||||
hold off;
|
||||
axis padded 'auto x'
|
||||
|
||||
% linkaxes([ax1,ax2],'x');
|
||||
% xlim([freqs(1), freqs(end)]);
|
||||
% legend('location', 'southwest');
|
||||
#+end_src
|
||||
|
||||
#+begin_src matlab :tangle no :exports results :results file replace
|
||||
exportFig('figs/dynamics_encoder_full_strut.pdf', 'width', 'wide', 'height', 'tall');
|
||||
#+end_src
|
||||
|
||||
#+name: fig:dynamics_encoder_full_strut
|
||||
#+caption: Dynamics from the force actuator to the measured motion by the encoder
|
||||
#+RESULTS:
|
||||
[[file:figs/dynamics_encoder_full_strut.png]]
|
||||
|
||||
* To Order :noexport:
|
||||
:PROPERTIES:
|
||||
:header-args:matlab+: :tangle no
|
||||
:END:
|
||||
** TODO Identification of the stiffness properties of the APA300ML
|
||||
*** APA Alone
|
||||
#+begin_src matlab :exports none
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
+175
-3
@@ -11,8 +11,8 @@ open('APA300ML.slx');
|
||||
% Import Mass Matrix, Stiffness Matrix, and Interface Nodes Coordinates
|
||||
% We first extract the stiffness and mass matrices.
|
||||
|
||||
K = readmatrix('mat_K.CSV');
|
||||
M = readmatrix('mat_M.CSV');
|
||||
K = readmatrix('APA300ML_mat_K.CSV');
|
||||
M = readmatrix('APA300ML_mat_M.CSV');
|
||||
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ M = readmatrix('mat_M.CSV');
|
||||
|
||||
% Then, we extract the coordinates of the interface nodes.
|
||||
|
||||
[int_xyz, int_i, n_xyz, n_i, nodes] = extractNodes('out_nodes_3D.txt');
|
||||
[int_xyz, int_i, n_xyz, n_i, nodes] = extractNodes('APA300ML_out_nodes_3D.txt');
|
||||
|
||||
% Piezoelectric parameters
|
||||
% In order to make the conversion from applied voltage to generated force or from the strain to the generated voltage, we need to defined some parameters corresponding to the piezoelectric material:
|
||||
@@ -590,3 +590,175 @@ ylabel('$F_s/F$ [m/N]');
|
||||
ylim([1e-7, 1e2]);
|
||||
|
||||
linkaxes([ax1,ax2,ax3,ax4,ax5,ax6],'x');
|
||||
|
||||
% Integral Force Feedback
|
||||
% In this section, Integral Force Feedback control architecture is applied on the APA300ML.
|
||||
|
||||
% First, the plant (dynamics from voltage actuator to voltage sensor is identified).
|
||||
|
||||
Kiff = tf(0);
|
||||
|
||||
|
||||
|
||||
% The payload mass is set to 10kg.
|
||||
|
||||
m = 10;
|
||||
|
||||
%% Name of the Simulink File
|
||||
mdl = 'APA300ML_IFF';
|
||||
|
||||
%% Input/Output definition
|
||||
clear io; io_i = 1;
|
||||
io(io_i) = linio([mdl, '/w'], 1, 'openinput'); io_i = io_i + 1;
|
||||
io(io_i) = linio([mdl, '/F'], 1, 'openinput'); io_i = io_i + 1;
|
||||
io(io_i) = linio([mdl, '/Fd'], 1, 'openinput'); io_i = io_i + 1;
|
||||
io(io_i) = linio([mdl, '/z'], 1, 'openoutput'); io_i = io_i + 1;
|
||||
io(io_i) = linio([mdl, '/APA300ML'], 1, 'openoutput'); io_i = io_i + 1;
|
||||
|
||||
G_ol = linearize(mdl, io);
|
||||
G_ol.InputName = {'w', 'f', 'F'};
|
||||
G_ol.OutputName = {'x1', 'Fs'};
|
||||
|
||||
G = G_ol({'Fs'}, {'f'});
|
||||
|
||||
|
||||
|
||||
% The obtained dynamics is shown in Figure [[fig:piezo_amplified_iff_plant]].
|
||||
|
||||
|
||||
freqs = logspace(1, 5, 1000);
|
||||
|
||||
figure;
|
||||
tiledlayout(3, 1, 'TileSpacing', 'None', 'Padding', 'None');
|
||||
|
||||
ax1 = nexttile([2,1]);
|
||||
hold on;
|
||||
plot(freqs, abs(squeeze(freqresp(G, freqs, 'Hz'))));
|
||||
hold off;
|
||||
set(gca, 'XScale', 'log'); set(gca, 'YScale', 'log');
|
||||
ylabel('Amplitude'); set(gca, 'XTickLabel',[]);
|
||||
hold off;
|
||||
|
||||
ax2 = nexttile;
|
||||
hold on;
|
||||
plot(freqs, 180/pi*unwrap(angle(squeeze(freqresp(G, freqs, 'Hz')))));
|
||||
set(gca, 'XScale', 'log'); set(gca, 'YScale', 'lin');
|
||||
yticks(-360:90:360);
|
||||
ylim([-390 30]);
|
||||
xlabel('Frequency [Hz]'); ylabel('Phase [deg]');
|
||||
hold off;
|
||||
linkaxes([ax1,ax2],'x');
|
||||
xlim([freqs(1), freqs(end)]);
|
||||
|
||||
|
||||
|
||||
% #+name: fig:piezo_amplified_iff_plant
|
||||
% #+caption: IFF Plant
|
||||
% #+RESULTS:
|
||||
% [[file:figs/piezo_amplified_iff_plant.png]]
|
||||
|
||||
% The controller is defined below and the loop gain is shown in Figure [[fig:piezo_amplified_iff_loop_gain]].
|
||||
|
||||
Kiff = -1e3/s;
|
||||
|
||||
freqs = logspace(1, 5, 1000);
|
||||
|
||||
figure;
|
||||
tiledlayout(3, 1, 'TileSpacing', 'None', 'Padding', 'None');
|
||||
|
||||
ax1 = nexttile([2,1]);
|
||||
hold on;
|
||||
plot(freqs, abs(squeeze(freqresp(G*Kiff, freqs, 'Hz'))));
|
||||
hold off;
|
||||
set(gca, 'XScale', 'log'); set(gca, 'YScale', 'log');
|
||||
ylabel('Amplitude'); set(gca, 'XTickLabel',[]);
|
||||
hold off;
|
||||
|
||||
ax2 = nexttile;
|
||||
hold on;
|
||||
plot(freqs, 180/pi*unwrap(angle(squeeze(freqresp(G*Kiff, freqs, 'Hz')))));
|
||||
set(gca, 'XScale', 'log'); set(gca, 'YScale', 'lin');
|
||||
yticks(-360:90:360);
|
||||
ylim([-180 180]);
|
||||
xlabel('Frequency [Hz]'); ylabel('Phase [deg]');
|
||||
hold off;
|
||||
linkaxes([ax1,ax2],'x');
|
||||
xlim([freqs(1), freqs(end)]);
|
||||
|
||||
|
||||
|
||||
% #+name: fig:piezo_amplified_iff_loop_gain
|
||||
% #+caption: IFF Loop Gain
|
||||
% #+RESULTS:
|
||||
% [[file:figs/piezo_amplified_iff_loop_gain.png]]
|
||||
|
||||
% Now the closed-loop system is identified again and compare with the open loop system in Figure [[fig:piezo_amplified_iff_comp]].
|
||||
|
||||
% It is the expected behavior as shown in the Figure [[fig:souleille18_results]] (from cite:souleille18_concep_activ_mount_space_applic).
|
||||
|
||||
|
||||
clear io; io_i = 1;
|
||||
io(io_i) = linio([mdl, '/w'], 1, 'openinput'); io_i = io_i + 1;
|
||||
io(io_i) = linio([mdl, '/F'], 1, 'openinput'); io_i = io_i + 1;
|
||||
io(io_i) = linio([mdl, '/Fd'], 1, 'openinput'); io_i = io_i + 1;
|
||||
io(io_i) = linio([mdl, '/z'], 1, 'openoutput'); io_i = io_i + 1;
|
||||
io(io_i) = linio([mdl, '/APA300ML'], 1, 'output'); io_i = io_i + 1;
|
||||
|
||||
Giff = linearize(mdl, io);
|
||||
Giff.InputName = {'w', 'f', 'F'};
|
||||
Giff.OutputName = {'x1', 'Fs'};
|
||||
|
||||
freqs = logspace(0, 3, 1000);
|
||||
|
||||
figure;
|
||||
tiledlayout(2, 3, 'TileSpacing', 'None', 'Padding', 'None');
|
||||
|
||||
ax1 = nexttile;
|
||||
hold on;
|
||||
plot(freqs, abs(squeeze(freqresp(G_ol('x1', 'w'), freqs, 'Hz'))));
|
||||
plot(freqs, abs(squeeze(freqresp(Giff('x1', 'w'), freqs, 'Hz'))));
|
||||
hold off;
|
||||
set(gca, 'XScale', 'log'); set(gca, 'YScale', 'log');
|
||||
set(gca, 'XTickLabel',[]); ylabel('$x_1/w$ [m/m]')
|
||||
|
||||
ax2 = nexttile;
|
||||
hold on;
|
||||
plot(freqs, abs(squeeze(freqresp(G_ol('x1', 'f'), freqs, 'Hz'))));
|
||||
plot(freqs, abs(squeeze(freqresp(Giff('x1', 'f'), freqs, 'Hz'))));
|
||||
hold off;
|
||||
set(gca, 'XScale', 'log'); set(gca, 'YScale', 'log');
|
||||
set(gca, 'XTickLabel',[]); ylabel('$x_1/f$ [m/N]');
|
||||
|
||||
ax3 = nexttile;
|
||||
hold on;
|
||||
plot(freqs, abs(squeeze(freqresp(G_ol('x1', 'F'), freqs, 'Hz'))));
|
||||
plot(freqs, abs(squeeze(freqresp(Giff('x1', 'F'), freqs, 'Hz'))));
|
||||
hold off;
|
||||
set(gca, 'XScale', 'log'); set(gca, 'YScale', 'log');
|
||||
set(gca, 'XTickLabel',[]); ylabel('$x_1/F$ [m/N]');
|
||||
|
||||
ax4 = nexttile;
|
||||
hold on;
|
||||
plot(freqs, abs(squeeze(freqresp(G_ol('Fs', 'w'), freqs, 'Hz'))));
|
||||
plot(freqs, abs(squeeze(freqresp(Giff('Fs', 'w'), freqs, 'Hz'))));
|
||||
hold off;
|
||||
set(gca, 'XScale', 'log'); set(gca, 'YScale', 'log');
|
||||
xlabel('Frequency [Hz]'); ylabel('$F_s/w$ [N/m]');
|
||||
|
||||
ax5 = nexttile;
|
||||
hold on;
|
||||
plot(freqs, abs(squeeze(freqresp(G_ol('Fs', 'f'), freqs, 'Hz'))));
|
||||
plot(freqs, abs(squeeze(freqresp(Giff('Fs', 'f'), freqs, 'Hz'))));
|
||||
hold off;
|
||||
set(gca, 'XScale', 'log'); set(gca, 'YScale', 'log');
|
||||
xlabel('Frequency [Hz]'); ylabel('$F_s/f$ [N/N]');
|
||||
|
||||
ax6 = nexttile;
|
||||
hold on;
|
||||
plot(freqs, abs(squeeze(freqresp(G_ol('Fs', 'F'), freqs, 'Hz'))));
|
||||
plot(freqs, abs(squeeze(freqresp(Giff('Fs', 'F'), freqs, 'Hz'))));
|
||||
hold off;
|
||||
set(gca, 'XScale', 'log'); set(gca, 'YScale', 'log');
|
||||
xlabel('Frequency [Hz]'); ylabel('$F_s/F$ [N/N]');
|
||||
|
||||
linkaxes([ax1,ax2,ax3,ax4,ax5,ax6],'x');
|
||||
+8
-3
@@ -11,8 +11,8 @@ open('flexor_025.slx');
|
||||
% Import Mass Matrix, Stiffness Matrix, and Interface Nodes Coordinates
|
||||
% We first extract the stiffness and mass matrices.
|
||||
|
||||
K = readmatrix('mat_K.CSV');
|
||||
M = readmatrix('mat_M.CSV');
|
||||
K = readmatrix('flex025_mat_K.CSV');
|
||||
M = readmatrix('flex025_mat_M.CSV');
|
||||
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ M = readmatrix('mat_M.CSV');
|
||||
|
||||
% Then, we extract the coordinates of the interface nodes.
|
||||
|
||||
[int_xyz, int_i, n_xyz, n_i, nodes] = extractNodes('out_nodes_3D.txt');
|
||||
[int_xyz, int_i, n_xyz, n_i, nodes] = extractNodes('flex025_out_nodes_3D.txt');
|
||||
|
||||
% Identification of the parameters using Simscape
|
||||
% The flexor is now imported into Simscape and its parameters are estimated using an identification.
|
||||
@@ -133,3 +133,8 @@ set(gca, 'XScale', 'log'); set(gca, 'YScale', 'log');
|
||||
xlabel('Frequency [Hz]'); ylabel('Amplitude [rad/Nm]');
|
||||
hold off;
|
||||
legend('location', 'southwest');
|
||||
|
||||
% Comparison with a stiffer Flexible Joint
|
||||
% The stiffness matrix with the flexible joint with a "hinge" size of 0.50mm is loaded.
|
||||
|
||||
K_050 = readmatrix('flex050_mat_K.CSV');
|
||||
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,103 @@
|
||||
%% Clear Workspace and Close figures
|
||||
clear; close all; clc;
|
||||
|
||||
%% Intialize Laplace variable
|
||||
s = zpk('s');
|
||||
|
||||
addpath('strut_encoder/');
|
||||
|
||||
open('strut_encoder.slx');
|
||||
|
||||
% Import Mass Matrix, Stiffness Matrix, and Interface Nodes Coordinates
|
||||
% We first extract the stiffness and mass matrices.
|
||||
|
||||
K = readmatrix('strut_encoder_mat_K.CSV');
|
||||
M = readmatrix('strut_encoder_mat_M.CSV');
|
||||
|
||||
|
||||
|
||||
% #+caption: First 10x10 elements of the Mass matrix
|
||||
% #+RESULTS:
|
||||
% | 0.04 | -0.005 | 0.007 | 2e-06 | 0.0001 | -5e-07 | -1e-05 | -9e-07 | 8e-05 | -5e-10 |
|
||||
% | -0.005 | 0.03 | 0.02 | -0.0001 | 1e-06 | -3e-07 | 3e-05 | -0.0001 | 8e-05 | -3e-08 |
|
||||
% | 0.007 | 0.02 | 0.08 | -6e-06 | -5e-06 | -7e-07 | 4e-05 | -0.0001 | 0.0005 | -3e-08 |
|
||||
% | 2e-06 | -0.0001 | -6e-06 | 2e-06 | -4e-10 | 2e-11 | -8e-09 | 3e-08 | -2e-08 | 6e-12 |
|
||||
% | 0.0001 | 1e-06 | -5e-06 | -4e-10 | 3e-06 | 2e-10 | -3e-09 | 3e-09 | -7e-09 | 6e-13 |
|
||||
% | -5e-07 | -3e-07 | -7e-07 | 2e-11 | 2e-10 | 5e-07 | -2e-08 | 5e-09 | -5e-09 | 1e-12 |
|
||||
% | -1e-05 | 3e-05 | 4e-05 | -8e-09 | -3e-09 | -2e-08 | 0.04 | 0.004 | 0.003 | 1e-06 |
|
||||
% | -9e-07 | -0.0001 | -0.0001 | 3e-08 | 3e-09 | 5e-09 | 0.004 | 0.02 | -0.02 | 0.0001 |
|
||||
% | 8e-05 | 8e-05 | 0.0005 | -2e-08 | -7e-09 | -5e-09 | 0.003 | -0.02 | 0.08 | -5e-06 |
|
||||
% | -5e-10 | -3e-08 | -3e-08 | 6e-12 | 6e-13 | 1e-12 | 1e-06 | 0.0001 | -5e-06 | 2e-06 |
|
||||
|
||||
|
||||
% Then, we extract the coordinates of the interface nodes.
|
||||
|
||||
[int_xyz, int_i, n_xyz, n_i, nodes] = extractNodes('strut_encoder_out_nodes_3D.txt');
|
||||
|
||||
% Piezoelectric parameters
|
||||
% Parameters for the APA300ML:
|
||||
|
||||
|
||||
d33 = 3e-10; % Strain constant [m/V]
|
||||
n = 80; % Number of layers per stack
|
||||
eT = 1.6e-8; % Permittivity under constant stress [F/m]
|
||||
sD = 2e-11; % Elastic compliance under constant electric displacement [m2/N]
|
||||
ka = 235e6; % Stack stiffness [N/m]
|
||||
C = 5e-6; % Stack capactiance [F]
|
||||
|
||||
na = 2; % Number of stacks used as actuator
|
||||
ns = 1; % Number of stacks used as force sensor
|
||||
|
||||
% Identification of the Dynamics
|
||||
|
||||
m = 0.01;
|
||||
|
||||
|
||||
|
||||
% The dynamics is identified from the applied force to the measured relative displacement.
|
||||
|
||||
%% Name of the Simulink File
|
||||
mdl = 'strut_encoder';
|
||||
|
||||
%% Input/Output definition
|
||||
clear io; io_i = 1;
|
||||
io(io_i) = linio([mdl, '/Fa'], 1, 'openinput'); io_i = io_i + 1;
|
||||
io(io_i) = linio([mdl, '/L'], 1, 'openoutput'); io_i = io_i + 1;
|
||||
|
||||
Gh = -linearize(mdl, io);
|
||||
|
||||
|
||||
|
||||
% The same dynamics is identified for a payload mass of 10Kg.
|
||||
|
||||
m = 10;
|
||||
|
||||
Ghm = -linearize(mdl, io);
|
||||
|
||||
freqs = logspace(0, 4, 5000);
|
||||
|
||||
figure;
|
||||
tiledlayout(3, 1, 'TileSpacing', 'None', 'Padding', 'None');
|
||||
|
||||
ax1 = nexttile([2,1]);
|
||||
hold on;
|
||||
plot(freqs, abs(squeeze(freqresp(Gh, freqs, 'Hz'))), '-');
|
||||
plot(freqs, abs(squeeze(freqresp(Ghm, freqs, 'Hz'))), '-');
|
||||
hold off;
|
||||
set(gca, 'XScale', 'log'); set(gca, 'YScale', 'log');
|
||||
ylabel('Amplitude'); set(gca, 'XTickLabel',[]);
|
||||
axis padded 'auto x'
|
||||
hold off;
|
||||
|
||||
ax2 = nexttile;
|
||||
hold on;
|
||||
plot(freqs, 180/pi*angle(squeeze(freqresp(Gh, freqs, 'Hz'))), '-', ...
|
||||
'DisplayName', '$m = 0kg$');
|
||||
plot(freqs, 180/pi*angle(squeeze(freqresp(Ghm, freqs, 'Hz'))), '-', ...
|
||||
'DisplayName', '$m = 10kg$');
|
||||
set(gca, 'XScale', 'log'); set(gca, 'YScale', 'lin');
|
||||
yticks(-360:90:360);
|
||||
ylim([-180 180]);
|
||||
xlabel('Frequency [Hz]'); ylabel('Phase [deg]');
|
||||
hold off;
|
||||
axis padded 'auto x'
|
||||
Binary file not shown.
File renamed without changes.
File renamed without changes.
|
500 Internal Server Error
An error occurred: An error occurred Gitea Version: 28.1.0 |