Challenge

Project - Position control of mass spring damper system

Q1Following are matlab programme of position control of spring mass damper system

% % spring mass damping equation
% mx+cx+kx=f(t)
% x=1/m(f(t)-cx-kx)
m=3.6 % kg
k=400 % N/m
c=100; % Ns/m;
% % Desired poles,
fn=1.0;
wn=2*pi*fn;
wn=6.28; % sqrt(k/m)
zeta=0.5 % underdamped% reserved poles
p1=-zeta*wn+wn*sqrt(zeta^2-1);
p2=-zeta*wn-wn*sqrt(zeta^2-1);
P=[p1;p2];
% % design of PID controller
A=[0 1 ;-k/m -c/m];
B=[0;1/m];
K=place(A,B,P);
kp=-258.0218
kd=-77.3920

Solution

The transfer function used in model as spring damper system.In which nominator is 1 se and denominator [3.6 100 400]set.

PID controller is used in model to control reference force on mass in system.In PID propertional gain kp and derivative gain kd find out by using pole placement method through 'place' command..ki value consider manually.

Pulse Generature is used for giving pulse signl.is used as reference force input.In setting amplitude st 1,period 5 sec and pilse width is 50.It connect to Sum block positive sign.

The output of the Transfer function give displacement.the displacement back to the PID controller and substract from reference signal.Scope block is used to plot signal.

simulink model as below:

REsponse as below

Conclusion

completed the project of transfer function used as spring damper system in model.Add PID controller in model to control force on mass so that its position follows referece signal.

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.