Matlab aula 23/02/2023

This commit is contained in:
2023-02-23 12:49:28 -03:00
parent 0b4a0ad127
commit 605612d31f

30
Aula_20230223.m Normal file
View File

@@ -0,0 +1,30 @@
%% Symbolic (não testei)
syms s real
G = 1/s/(s+2);
D = 160*(s+4)/(s+30);
Tr = simplify(D*G/(1+D*G))
Trl = simplify(1-D*G/(1+D*G))
%% TF
clear; clc;
s = tf('s');
G = 1/s/(s+2);
D = 160*(s+4)/(s+30);
Tr = D*G/(1+D*G)
minreal(1-Tr) %Tipo 1
Kv = 38400/3600
Tw = -G/(1+D*G)
minreal(Tw) %Tipo 0
step(Tr)
%step(Tw)
%% Caso 2
clear; clc;
s = tf('s');
H = 20/(s+20);
G = 1/s/(s+2);
D = 160*(s+4)/(s+30);
Tr = D*G/(1+D*G*H);
minreal(1-Tr) %Tipo 1
Tw = -G/(1+D*G*H);
minreal(Tw) %Tipo 0
step(Tr)
%step(Tw)