Académique Documents
Professionnel Documents
Culture Documents
D’ELECTRICITE ET DE MECANIQUE
COMPTE RENDU
Travaux pratiques
Elaboré par :
COUKI Ayman 1ére Année GESET
Encadré par :
Prof : B.Rached
2. Introduction :
Le travail se déroulera à travers un processus méthodique, structuré en six étapes, appliqué à
chaque système étudié. Ces étapes fournissent une approche systématique pour élaborer des
modèles cohérents et précis, éclairant ainsi les caractéristiques intrinsèques des systèmes
dynamiques. Les différentes phases du travail incluent :
Inductance (L) : 2 mH
Condensateur (C) : 10 uF
Rapport de transformation : 1 : 3
𝐼 = 𝑥1
{
𝑒𝑐 = 𝑥2
𝑑𝐼 𝑅. 𝑛2 𝑛. 𝑒𝑐
=− 𝑥1 − 𝑥 +𝑒
{𝑑𝑡 𝐿 𝐶 2
𝑑𝑒𝑐 𝑛
= 𝑥1
𝑑𝑡 𝐿
c) Equation d’état :
𝑑𝑥
= 𝐴. 𝑋 + 𝐵. 𝑈
𝑑𝑡
0 𝑛/𝐿 1
(𝑥̇𝑥̇ 1 ) = ( ). (𝑥1) + ( ) . 𝑒
2 −𝑛/𝐶 − (𝑅. 𝑛2 )/𝐿 𝑥2 0
R = 1000;
L = 0.002;
C = 0.000001;
n = 1/3;
e = u(t);
I = x(1);
ec = x(2);
end
La fonction main :
figure;
subplot(2,1,1);
plot(t,X(:,1))
xlabel('Temps(s)'); ylabel('X1')
title ('etat X1');
subplot(2,1,2);
plot(t,X(:,2))
xlabel('Temps(s)'); ylabel('X2')
title ('etat X2');
end
La simulation :
b) Par équation d’état :
Le programme :
La fonction main :
function mainEE()
R = 1000;
L = 0.002;
C = 0.000001;
n = 1/3;
tspan=[0 10];
amp = 20.0;
freq = 2.0;
U = @(t) amp*sin(2*pi*freq*t);
[t,X]=ode45(@(t,X) modelElq_EE(t,X,U(t),A,B),tspan,X0);
y=C*X' + D*U(t)';
figure;
subplot(2,1,1);
plot(t,X(:,1))
xlabel('Temps(s)'); ylabel('X1')
title ('etat X1');
subplot(2,1,2);
plot(t,X(:,2))
xlabel('Temps(s)'); ylabel('X2')
title ('etat X2');
figure
plot (t,y)
xlabel('temps(s)');
ylabel('Y');
title('sortie Y');
end
La simulation :
4. Système mécanique :
Tm : Couple appliqué
b) Equation différentielle :
𝜃𝑚 = 𝑥(1)
𝜃𝑙 = 𝑥(3)
𝜃̇𝑚 = 𝑥(3)
̇
{ 𝜃𝑙 = 𝑥(4)
𝑛2 . 𝐾̈ 𝑛. 𝐾 𝐵𝑚. 𝑛2 . 𝐵 𝑛. 𝐵 𝑇𝑚
𝜃̈𝑚 = − 𝜃𝑚 + 𝜃𝑙 + 𝜃̇𝑚 + 𝜃̇𝑙 +
𝐽𝑚 𝐽𝑚 𝐽𝑚 𝐽𝑚 𝐽𝑚
2 2
𝑛 .𝐾 𝑛. 𝐾 𝑛 .𝐵 𝑛. 𝐵 + 𝐵𝑙
𝜃̈𝑙 = 𝜃𝑚 − 𝜃𝑙 + 𝜃̇𝑚 + 𝜃̇𝑙
{ 𝐽𝑙 𝐽𝑙 𝐽𝑙 𝐽𝑚
c) Equation d’état :
𝑑𝑥
= 𝐴. 𝑋 + 𝐵. 𝑈
𝑑𝑡
0 0 1 0
0 0 0 1 𝜃𝑚 0
𝑛2 . 𝐾 𝑛. 𝐾 𝐵𝑚. 𝑛2 . 𝐵 𝑛. 𝐵 𝜃𝑙 0
𝑑𝑥
= −
𝐽𝑚 𝐽𝑚 𝐽𝑚 𝐽𝑚 . ̇ + 1 . 𝑇𝑚
𝑑𝑡 𝜃𝑚
2 𝑛. 𝐾 𝐽𝑚
𝑛 .𝐾 𝑛2 . 𝐵 𝑛. 𝐵 + 𝐵𝑙 𝜃𝑙̇
− ( ) (0)
( 𝐽𝑙 𝐽𝑙 𝐽𝑙 𝐽𝑚 )
4.2. Simulation du Modèle dans MATLAB.
a) Par équation différentielle :
Le programme :
teta_m = x(1);
teta_l = x(2);
dteta_m = x(3);
dteta_l = x(4);
La fonction main :
function mainMec()
x0 = [0; 0; 0; 0];
tspan = [0 1];
amp = 20.0;
freq = 50.0;
u = @(t) amp*sin(2*pi*freq*t);
[t,X]=ode45(@(t,x) modelMec(t,x,u),tspan,x0);
figure;
subplot(2,2,1);
plot(t,X(:,1))
xlabel('Temps(s)'); ylabel('X1')
title ('etat X1');
subplot(2,2,2);
plot(t,X(:,2))
xlabel('Temps(s)'); ylabel('X2')
title ('etat X2');
subplot(2,2,2);
plot(t,X(:,2))
xlabel('Temps(s)'); ylabel('X2')
title ('etat X2');
subplot(2,2,3);
plot(t,X(:,3))
xlabel('Temps(s)'); ylabel('X3')
title ('etat X3');
subplot(2,2,4);
plot(t,X(:,4))
xlabel('Temps(s)'); ylabel('X4')
title ('etat X4');
end
La simulation :
b) Par équation d’état :
Le programme :
La fonction main :
function mainMec_EE()
K=300;
Bm=0.1;
Bl=0.05;
Jm=0.005;
Jl=0.01;
n=1.8;
B=0.05;
tspan = [0 1];
amp = 20.0;
freq = 50.0;
U = @(t) amp*sin(2*pi*freq*t);
[t,X]=ode45(@(t,X) modelElq_EE(t,X,U(t),A,B),tspan,X0);
y=C*X' + D*U(t)';
figure;
subplot(2,2,1);
plot(t,X(:,1))
xlabel('Temps(s)'); ylabel('X1')
title ('etat X1');
subplot(2,2,2);
plot(t,X(:,2))
xlabel('Temps(s)'); ylabel('X2')
title ('etat X2');
subplot(2,2,3);
plot(t,X(:,3))
xlabel('Temps(s)'); ylabel('X3')
title ('etat X3');
subplot(2,2,4);
plot(t,X(:,4))
xlabel('Temps(s)'); ylabel('X4')
title ('etat X4');
figure
plot (t,y)
xlabel('temps(s)');
ylabel('Y');
title('sortie Y');
end
La simulation :
5. Système Hydraulique :
1
R=
𝐶𝑑_𝑅𝑖 ∗𝑠𝑞𝑟𝑡(2∗𝑔)
b) Equation différentielle :
𝐽1 = 𝑥1
{
𝐽2 = 𝑥2
𝑑𝐽1 1 1 1
= −( + ) 𝑥1 + 𝑥 + 𝑄𝑖/𝐶1
{ 𝑑𝑡 𝐶1. 𝑅0 𝐶1. 𝑅1 𝐶1. 𝑅1 2
𝑑𝐽2 1 1 1
= 𝑥1 − ( + )𝑥
𝑑𝑡 𝐶2. 𝑅1 𝐶2. 𝑅1 𝐶2. 𝑅2 2
a) Equation d’état :
𝑑𝑥
= 𝐴. 𝑋 + 𝐵. 𝑈
𝑑𝑡
1 1 1
−( + ) 1/𝐶1
(𝑥̇𝑥̇ 1 ) = ( 𝐶1.𝑅01 𝐶1.𝑅1 1
𝐶1.𝑅1
1 ). (𝑥𝑥1 ) + ( ) . 𝑄𝑖
2
− ( 𝐶2.𝑅1 + 𝐶2.𝑅2 ) 2 0
𝐶2.𝑅1
J1 = x(1);
J2 = x(2);
function mainHyd()
x0 = [0;0];
tspan = [0 5];
amp = 20.0;
freq = 50.0;
u = @(t) amp*sin(2*pi*freq*t);
[t,X]=ode45(@(t,x) modelHyd(t,x,u),tspan,x0);
figure;
subplot(2,1,1);
plot(t,X(:,1))
xlabel('Temps(s)'); ylabel('X1')
title ('etat X1');
subplot(2,1,2);
plot(t,X(:,2))
xlabel('Temps(s)'); ylabel('X2')
title ('etat X2');
end
La simulation :
b) Par équation d’état :
Le programme :
La fonction main :
function mainHyd_EE()
Cd_R0 = 0.7;
Cd_R1 = 0.6;
Cd_R2 = 0.6;
A1 = 2; A2 = 3;
h1 = 1; h2 = 2;
C1 = A1*h1;
C2 = A2*h2;
g = 9.81;
R0 = 1/(Cd_R0*sqrt(2*g));
R1 = 1/(Cd_R1*sqrt(2*g));
R2 = 1/(Cd_R2*sqrt(2*g));
tspan = [0 10];
amp = 20.0; freq = 50.0;
U = @(t) amp*sin(2*pi*freq*t);
[t,X]=ode45(@(t,X) modelHyd_EE(t,X,U(t),A,B),tspan,X0);
y=C*X' + D*U(t)';
figure;
subplot(2,1,1);
plot(t,X(:,1))
xlabel('Temps(s)'); ylabel('X1')
title ('etat X1');
subplot(2,1,2);
plot(t,X(:,2))
xlabel('Temps(s)'); ylabel('X2')
title ('etat X2');
end
La simulation :