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

Problem Description Use a script to calculate the peak time of the step response

ID: 3802651 • Letter: P

Question

Problem Description

Use a script to calculate the peak time of the step response of a second-order system of the shown form for a range of zero values (where the zero = -1/T).

(T*s + 1)/(s^2 + 2*zeta*wn + wn^2)

Instructions

To solve this problem, modify the solution template by adding formulas for calculating the peak time ( tp ) of the given transfer function's step response for a given vector of parameters T where each element of the vector ( T(i) ) corresponds to the transfer function having a single zero at -1/T(i). The variable tp that is returned should be a vector where each element is the peak time for the corresponding element in the vector T. You may assume that parameters of the transfer function ( zeta and wn ) are available for your calculations and that the system is underdamped (0 < zeta < 1) and wn > 0.

You may find the MATLAB function stepinfo helpful.

Solution

% Using the parameters of the given second-order system, calculate the peak time
% of the step response for the given set of zeros (based on the vector T). The
% given transfer function has the following form:
%
% (T*s+1)/(s^2 + 2*zeta*wn*s + wn^2)
%
% available variables:
%
% T = vector of time constants for the zero
% zeta = damping ratio (should be between 0 and 1)
% wn = (undamped) natural frequency (should be greater than 0)

% First verify the values of the damping coefficent and natural frequency
if (zeta >= 1) || (zeta <= 0)
msg = 'expecting the system to be underdamped';
error(msg)
end

if (wn <= 0)
msg = 'expecting wn > 0';
error(msg)
end

% Calculate the peak time of the step response for each element of the T vector.
% You may find the command 'stepinfo' helpful.
for i = 1:length(T)
tp(i) =
end %for

tp

Explanation / Answer

import java.awt.*;

public category conic extends EasyApp


Button bAdd = addButton("Change",420,40,60,30,this);

double A = 1;
double B = 0;
double C = 0;

public Parabola()

  

public void grid(Graphics g)
  
for (int y = 0; y &lt;=400; y = y + 20)
  
g.setColor(Color.black);
g.drawLine(200,0,200,400);
g.drawLine(199,0,199,400);
g.drawLine(0,199,400,199);
g.drawLine(0,200,400,200);
}
  
public void curve(Graphics g)
  
}

import java.awt.*;

public category conic extends EasyApp


Button bAdd = addButton("Change",420,40,60,30,this);

double A = 1;
double B = 0;
double C = 0;

public Parabola()

  

public void grid(Graphics g)
  
for (int y = 0; y &lt;=400; y = y + 20)
  
g.setColor(Color.black);
g.drawLine(200,0,200,400);
g.drawLine(199,0,199,400);
g.drawLine(0,199,400,199);
g.drawLine(0,200,400,200);
}
  
public void curve(Graphics g)
  
}

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