Challenge

Project - Position control of mass spring damper system

I have already submitted the project( Speed control of a DC motor) on Nov 20, 2022 and it has been graded. My score was 300/300 in this project. After the site updation, my file is missing from my profile and it shows that I have to resubmit . I have discussed this issue with one of technical engineer and i was told to submit the file here again. Please have a look. I have attached proof showing my project as graded.

Speed control of a DC Motor

The project is to Built a simulink model for the DC(schematic shown in question) Motor and to design a PID controller to maintain a desired speed for the motor.

Applying krichoffs law for the given schematic diagram we get

Vs = Ra*Ia + La*dia/dt +Vb --------------- (1)

Applying newtons's law for the given schematic diagram we get

Kt*Ia = J*d^2theta/dt^2 + B*dtheta/dt -------(2)

Taking Laplase Transform for both equation

Eq(1) => Vs(s) = Ra*Ia(s) + La*s*Ia(s) +Vb(s)

=> Ia(s)*(La*s + Ra) = Vs(s) - Vb(s)

=> Ia(s) = (Vs(s) - Vb(s))/(La*s + Ra) --------------(3)

Eq(2) => Kt*Ia(s) = J*s^2*theta(s) + B*s*theta(s)

=> s*theta(s)(J*s + B) = Kt*Ia(s)

=> s*theta(s) = Kt*Ia(s)/(J*s + B) = w(s) -------(4) since w = dtheta/dt

Using Eq (3) and Eq (4) we can built the normal simulation model of Dc motor without PID controller

State space representation

we know

X_dot = A*x + B*u

Y = C*x + D*u

From Eq(2) => J*d^2theta/dt^2 = -B*dtheta/dt + Kt*Ia

we know w = dtheta/dt, substitute in above equation

dw/dt = -(B/J)*w + (Kt/J) = w_theta -------------- (5)

from Eq(1) => La*dIa/dt = -Vb - Ra*Ia + Vs , Vb = Kb*dtheta/dt

=> dIa/dt = -(Kb/La)*dtheta/dt - (Ra/La)*Ia + (1/La)*Vs = Ia_theta---------- (6)

y(t) = w ---------- (7)

From Eq(5), Eq(6) and Eq(7)we will get state space representation of this model

X_dot = [w_theta ; Ia_theta]

x = [w;Ia]

A = [-(B/J) (Kt/J) ;-(Kb/La) -(Ra/La)]

B = [ 0; (1/La)]

C = [1;0]

Assuming a value for zeta and by using pole placement technique we will get the value of control gain.

Using above information we can built desired model of dc motor containing PID controller and we can control speed of dc motor to get a desired response.

Here we take zeta = 0.5;

analyzing the response of the system for input reference speed of value 50

that is Reference speed = 50

solver = ode 4, step size=0.01, simulation stop time = 6 sec

Script

% Designing a PID controller to regulate the speed of the DC Motor
J = 0.02; % moment of inertia
B_vis = 0.1; % viscous friction constant
Kb = 0.015; % back EMF constant
Kt = 0.02; % torque constant
Ra = 1.5; % armature resistance
La = 0.8; % armature inductance
%state equation
% X_dot = Ax + Bu
% Y = Cx + Du
A = [-B_vis/J Kt/J;-Kb/La -Ra/La]; %state matrix
B = [0;(1/La)]; %input matrix
%Design parameters
f=1;
wn=2*pi*f;
zeta = 0.5;
%finding pole of the dynamic system
p1 = -zeta*wn + wn*sqrt(zeta^2-1);
p2 = -zeta*wn - wn*sqrt(zeta^2-1);
P=[p1;p2];
%pole placement technique to find Kp and Kd
K = place(A,B,P);
% value of K is found in command window
Kp=K(1);
Kd=K(2);
Ki = 0; %assuming value of Ki
Command window
simulink model
Response
Kp = K(1)
Kd =K(2)
Case-1(Ki = 0)
Case-2(Ki = 10)
Case-3(Ki = 30)
Case-4(Ki = 50)
Case-5(Ki = 75)
Case-6(Ki = 100)
With Kp=K(1) , Kd = K(2) and changing the value of Ki from 0 to 100 we understood that the steady state error is decreasing but more overshoot for higher value of Ki
Now Kp = K(1) , Kd = 3.5
Case-1(Ki=0)
Case-2(Ki=10)
Case-3(Ki=30)
Case-4(Ki=40)
Case-5(Ki=50)
Case-6(Ki=75)
With Kp=K(1) , Kd=3.5 and Ki changing from 0 to 75 we understood that the response is more better than in previous case(Kp=K(1) , Kd=K(2)). That is here overshoot is decreased for the increased value kd with respect to Kd=K(2).
So we can conclude that there is certain value of Kp , Ki and Kd for which we get perfect response such that certain time domain characteristics are met.
Your portfolio, next

Ship work like this
in your own course.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.