필터 지우기
필터 지우기

Trying to Plot feedback system

조회 수: 1 (최근 30일)
random1072
random1072 2020년 10월 15일
답변: Star Strider 2020년 10월 15일
I am trying to plot my g in order to show the overshoot I am getting however I keep getting an error everytime I try to plot and not sure why. I already found my values just cannot plot.
g_0 = tf([20],[1,8,32,20]);
stepinfo(g_0)
g_1 = tf([40],[1,8,32,40]);
stepinfo(g_1)
g_2 = tf([60],[1,8,32,60]);
stepinfo(g_2)
g_3 = tf([70],[1,8,32,70]);
stepinfo(g_3)
g_4 = tf([77],[1,8,32,77]); % K of 77 give overshoot just under 16%
stepinfo(g_4)
g_5 = tf([78],[1,8,32,78]); % K of 78 gives overshoot just above 16%
stepinfo(g_5)
%Interpolate to get exact K value = 16% = 77.66181431
g= tf([77.6618143],[1,8,32,77.6618143]) % K is just over overshoot of 17%
stepinfo(g)
step(g)

답변 (1개)

Star Strider
Star Strider 2020년 10월 15일
The image is a bit difficult to read. The error appears to be thrown with the step call. This may likely be due to your having named a variable ‘step’.
Run this from a script or your Command Window:
which step -all
if the first entry is:
step is a variable.
you have found the problem. The solution is to name it something else that is relevant in the context of your code.
If that is not the problem, please provide more details.

카테고리

Help CenterFile Exchange에서 Graphics Performance에 대해 자세히 알아보기

제품

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by