Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions ControlSys/FeedbackLoopResponse.m
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
% By: Johnathan Machler
% Date: 01.23.19

pkg load control
pkg load symbolic
% pkg load control
% pkg load symbolic

G1 = tf([0 4], [0 1]);
G2 = tf([0 1],[1 2]);
Expand All @@ -12,5 +12,8 @@

rlocus(Sys);
v=[-6 6 -6 6]; axis(v);axis('square');grid on;

[Num,Den] = tfdata(Sys,'v');
syms s t
ilaplace(Sys, s, t) % Takes inverse laplace transform of symbolic expression
Sys_syms = poly2sym(Num,s)/poly2sym(Den,s); % Convert tf to symbolic expression
ilaplace(Sys_syms, s, t) % Takes inverse laplace transform of symbolic expression
2 changes: 1 addition & 1 deletion ControlSys/PI_Controller.m
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@

gc =tf([0.3 5 5],[1 0]);
gp = tf([1],[0.01 0.11 0.1]);
ol = series(gc,gp); # Compensator/ Controller in series with plant
ol = series(gc,gp); %Compensator/ Controller in series with plant
step(feedback(ol,1))
title('PID controller');