%% Experiment 8.1
%% Name: Aidan Sharpe
%% Objectives
% To verify the effect of open-loop poles and zeros upon the shape of the root locus. To verify the root locus as a tool for estimating the effect of open-loop gain upon the transient response of closed-loop systems.
%% Minimum Required Software Packages
% MATLAB, Simulink, and the Control System Toolbox.
%
%
%% Prelab
%% Problem 1
% Sketch two possibilities for the root locus of a unity negative-feedback system with the open-loop pole-zero configuration shown in Figure P8.21
%
% Answer:
%
%
%%
%
%% Problem 2
% If the open-loop system of Prelab 1 is G(s) = \frac{K(s+1.5)}{s(s+0.5)(s+10)}, estimate the precent overshoot at the following values of gain, K: 20, 50, 85, 200, 700.
% Answer:
%
%
%
%
%
%
%% Lab
%
%% Problem 1
% Using MATLAB's SISO Design Tool, set up a negative unity feedback system with G(s) = \frac{K(s+6)}{s(s+0.5)(s+10)} to produce a root locus. For convenience, set up the zero at -6 using SISO Design Tool’s compensator function by simply dragging a zero to -6 on the resulting root locus. Print the root locus for the zero at -6. Move the zero to the following locations and print out a root locus at each location: -2, -1.5, -1.37, and -1.2.

% Insert your code here

%
%% Problem 2
% Using MATLAB's SISO Design Tool, set up a negative unity feedback system with G(s) = \frac{K(s+1.5)}{s(s+0.5)(s+10)} to produce a root locus. Open the LTI Viewer for SISO Design Tool to show step responses. Using the values of K specified in Prelab 2, record the percent overshoot and settling time and print the root loci and step response for each value of K.

% Insert your code here

%
%
%
%
%% Postlab
%
%% Problem 1
% Discuss your findings from Prelab 1 and Lab 1. What conclusions can you draw?
%
%
%
%
%% Problem 2
% Make a table comparing percent overshoot and settling time from your calculations in Prelab 2 and your experimental values found in Lab 2. Discuss the reasons for any discrepancies. What conclustions can you draw?
%
%
%
%