Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Heart assist devices are mechanical pumps used in patients with cardiovascular d

ID: 2291735 • Letter: H

Question

Heart assist devices are mechanical pumps used in patients with cardiovascular dis- eases who are awaiting heart transplantation. These pumps need to be tolerant of mismatches between physiological demand and pump operating settings. Consider- ing the pulsatile nature of the system, proper control over the device is critical. The device can be modeled with the following transfer function: P(s) R(s) C(s) H P(s) Y(s) a) Use Bode plot sketches to design a lag compensator C(s) so that the closed loop system satisfies the following specifications i. The steady-state error to a unit step reference input is less than or equal to 0.01 ii. PM 2 40 degrees (b) Verify and refine your design using Matlab; include a Bode plot and a step response plot showing that you have met both specifications

Explanation / Answer

(a)

MATLAB CODE

clc;
PMR=40 %required phase margin is 40degree or greater
ess=0.01 %Steady state Error requirement
num=[1] %numerator of uncompensated system
den=[1 11 10] %Denominator of uncompensated system
G=tf(num,den) % Transfer Function of Uncompensated sysetm
Kc=10/ess
bode(G) %To obtain the BODE PLOT of uncompensated systm
[Gm,PM,Wgc,Wpc]=margin(G) %To find the Frequency Domain specifucations of Uncompensated system
%%Compensator Design Procedure
if PM >PMR
disp('lag compensator is needed')
phi_m=PMR-PM+5 %error value to update whether the compensator is given the desired specifications to the original plant
alpha=(1-sin(phi_m))/(1+sin(phi_m))
MAG=-20*log(1/sqrt(alpha))
T=1/(sqrt(alpha)*1.39)% Time constant value of compensator
Gc=Kc*tf([1 1/T],[1 1/(T*alpha)]) %Transfer Function of a LAG COMPENSATOR
C=G*Gc %Compensated system
bode(C) %To obtain the transfer function of Compensated sysstem
[Gmc,PMc,Wgcc,Wpcc]=margin(C) % Frequency Domain specifucations of Compensated system
else
disp('lead compensator is needed')  
  
end  

(b)

clc;
PMR=40 %required phase margin is 40degree or greater
ess=0.01 %Steady state Error requirement
num=[1] %numerator of uncompensated system
den=[1 11 10] %Denominator of uncompensated system
G=tf(num,den) % Transfer Function of Uncompensated sysetm
Kc=10/ess
bode(G) %To obtain the BODE PLOT of uncompensated systm
[Gm,PM,Wgc,Wpc]=margin(G) %To find the Frequency Domain specifucations of Uncompensated system
%%Compensator Design Procedure
if PM >PMR
disp('lag compensator is needed')
phi_m=PMR-PM+5 %error value to update whether the compensator is given the desired specifications to the original plant
alpha=(1-sin(phi_m))/(1+sin(phi_m))
MAG=-20*log(1/sqrt(alpha))
T=1/(sqrt(alpha)*1.39)% Time constant value of compensator
Gc=Kc*tf([1 1/T],[1 1/(T*alpha)]) %Transfer Function of a LAG COMPENSATOR
C=G*Gc %Compensated system
bode(C) %To obtain the transfer function of Compensated sysstem
[Gmc,PMc,Wgcc,Wpcc]=margin(C) % Frequency Domain specifucations of Compensated system
else
disp('lead compensator is needed')  
  
end  
step(C)
stepinfo(C)

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote