?? ex_1.m
字號:
%ex_1
clear all;
a=[8 2 3 1 5];
b=[1 3 2];
%
p=roots(a) %求系統極點
z=roots(b) %求系統零點
p=p'; %將極點列向量轉置為行向量
z=z'; %將零點列向量轉置為行向量
x=max(abs([p z])); %確定縱坐標范圍
x=x+0.1;
y=x; %確定橫坐標范圍
figure(1)
clf
hold on
axis([-x x -y y]); %確定坐標軸顯示范圍
axis('square')
plot([-x x],[0 0]) %畫橫坐標軸
plot([0 0],[-y y]) %畫縱坐標軸
plot(real(p),imag(p),'x') %畫極點
plot(real(z),imag(z),'o') %畫零點
title('連續系統零極點圖') %標注標題
text(0.2,x-0.2,'虛軸')
text(y-0.2,0.2,'實軸')
%
[z,p]=tf2zp(b,a)
figure(2)
zplane(z,p),title('連續系統零極點圖')
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -