0% found this document useful (0 votes)
29 views

Lab Report 3

1) The document describes lab objectives which include modeling a DC motor using differential equations, creating Simulink models from differential equations, and deriving transfer functions from differential equations. 2) The lab tasks involve creating a Simulink model of a DC motor, deriving transfer functions relating speed, position, and pendulum position to voltage using Laplace transforms and MATLAB code, and simulating the transfer functions in Simulink and LabVIEW. 3) The conclusion states that the lab helped students represent differential equations as Simulink models and derive transfer functions from the equations using Laplace transforms, which were then simulated in MATLAB, Simulink, and LabVIEW.

Uploaded by

Huzaifah Tariq
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
29 views

Lab Report 3

1) The document describes lab objectives which include modeling a DC motor using differential equations, creating Simulink models from differential equations, and deriving transfer functions from differential equations. 2) The lab tasks involve creating a Simulink model of a DC motor, deriving transfer functions relating speed, position, and pendulum position to voltage using Laplace transforms and MATLAB code, and simulating the transfer functions in Simulink and LabVIEW. 3) The conclusion states that the lab helped students represent differential equations as Simulink models and derive transfer functions from the equations using Laplace transforms, which were then simulated in MATLAB, Simulink, and LabVIEW.

Uploaded by

Huzaifah Tariq
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 11

Department of Electrical Engineering

Faculty Member:_Dr. Iftikhar Rana______ Dated: ___19/02/2020____

Semester:__________6th ______________ Section: ______A_________

EE-379: Control Systems

Lab 3: System Modeling

CLO3/PLO4/BT Level B4 PLO4/PLO5, CLO5/ CLO6/


BT PLO8 PLO9
levelA3,A4
Name Reg. No Viva / Analysis Modern Ethics Individual
Quiz / Lab of data Tool and and Team
Performa in Lab Usage Safety Work
nce Report

5 Marks 5 Marks 5 Marks 5 Marks 5 Marks


Huzaifah Tariq 210430

Faraz Nazir 213780

Objectives of Lab 3
EE-379: Control Systems Page 1
The objectives of this lab are:

 Learn the modeling of a DC motor using first principles.


 Given a set of differential equations that describe a system, learn how to create a model in
Simulink.

 Given a set of differential equations describing a system, learn how to find the transfer
function of the system.

Introduction:
A system’s behavior is usually described simply by creating a mathematical model using
transfer function and differential equations. It makes the system easier to understand and is usually
the first step when designing a new system. A transfer function is a very useful technique to
represent a system in terms of its input-output relationship. LabView allows us to simulate all these
functions and observe their practical significance.

Lab Tasks
Task 1:
Simulink Model

 Model:

 Parameters:

EE-379: Control Systems Page 2


Task 2:
EE-379: Control Systems Page 3
Transfer Functions using Laplace Transform

EE-379: Control Systems Page 4


Task 3:
(a) Transfer Function between speed and voltage

 MATLAB Code:

Je=1.84e-6;
e=0.000271;
m=0.027;
r=0.0826;
Kg=1;
Jm=1.80e-4;
ng=1;
nm=0.69;
L=0.0955;
g=9.8;
Kt=0.0334;
R=8.7;

EE-379: Control Systems Page 5


a= Je+(m*(r)^2)+ng*(Kg^2)*Jm;
b=m*L*r;
c=(4/3)*m*(L^2);
d=m*g*L;
f=(nm*ng*Kt*Kg)/R;
num = [f*c 0 -f*d];
den = [a*c-b^2 e*c -a*d -e*d];
Transfer_Function = tf(num,den)

 Output:

(b) Transfer Function between position and voltage

 MATLAB Code:

Je=1.84e-6;
e=0.000271;
m=0.027;
r=0.0826;
Kg=1;
Jm=1.80e-4;
ng=1;
nm=0.69;
L=0.0955;
g=9.8;
Kt=0.0334;
R=8.7;
a= Je+(m*(r)^2)+ng*(Kg^2)*Jm;
b=m*L*r;
c= (4/3)*m*(L^2);
d=m*g*L;
f=(nm*ng*Kt*Kg)/R;

EE-379: Control Systems Page 6


num = [f*c 0 -f*d];
den = [a*c-b^2 e*c -a*d -e*d 0];
Transfer_Function = tf(num,den)
 Output:

(c) Transfer Function between position of pendulum and voltage of motor

 MATLAB Code:

Je=1.84e-6;
e=0.000271;
m=0.027;
r=0.0826;
Kg=1;
Jm=1.80e-4;
ng=1;
nm=0.69;
L=0.0955;
g=9.8;
Kt=0.0334;
R=8.7;
a= Je+(m*(r)^2)+ng*(Kg^2)*Jm;
b=m*L*r;
c= (4/3)*m*(L^2);
d=m*g*L;
f=(nm*ng*Kt*Kg)/R;
num = [(b^2)*f 0 0];
den = [a*b*c (e*b*c-b) -a*b*d -e*d*b];
Transfer_Function = tf(num,den)

EE-379: Control Systems Page 7


 Output:

Task 4:
Transfer Functions in Simulink

EE-379: Control Systems Page 8


 Parameters:

Task 5:
Transfer Functions in Lab VIEW

 Between speed and voltage:

EE-379: Control Systems Page 9


 Between position and voltage:

 Between position of pendulum and voltage of motor:

EE-379: Control Systems Page 10


 Block Diagram:

Conclusion:
In this lab, we learn how to represent a set of differential equations as a model in Simulink.
Moreover, we also create transfer functions from these equations using Laplace Transform. The
created transfer functions were then simulated using MATLAB code, Simulink model as well as in Lab
VIEW. We also learned how to create general functions and define their respective parameters in the
software.

EE-379: Control Systems Page 11

You might also like