summaryrefslogtreecommitdiff
path: root/3889/CH7/EX7.5/Ex7_5.sce
blob: 5404ba5a47184527f28698309cfd7e61bbf5ddd7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
//Example 7.5
//page 439
//Control Systems: Principles and Design 
//M Gopal, Second Edition, Tata McGraw-Hill
//Chapter:Compensator Design Using Root Locus

xdel(winsid())//close all graphics Windows
clear;
clc;
//transfer function
s=%s;
P=(s+1)/((s^2)*(s+9));

//Root locus plot using evans root locus
f=figure()
evans(P)
title("Root locus of (s+1)/((s^2)*(s+9))",'fontsize',5)
h=legend('');
h.visible="OFF"
zoom_rect([-5 -10 5 10])
a=gca();
a.x_location="origin"
a.y_location="origin"
a.parent.background=8; 
legends(['root locus';'';'asymptotic directions';'open loop poles'],[2,3,1,-2],with_box=%f,opt="ur",2.8)
K=poly(0,'K')
R= routh_t(P,K);
disp(R,'Routh Array')