How can I fix this error?

sys=tf([1 1 1 1],[1 1]);

t=0:0.1:10;

step(sys,t)

??? Error using ==> DynamicSystem.step at 84 Cannot simulate the time response of models with more zeros than poles. I know that my system is unstable but how can I receive an “unstable” graph for this system on my axes?

ANSWER

Just FYI the following code won’t provide the same graph has the step function, it just plots the function having s as the variable, the step fuction just works for proper systems (n poles >= n zeros).

“Impulse response”:

syms s
TFC=evalc('tf([1 1 1 1],[1 1])');
[a b] = strread(TFC, '%s %s', 'delimiter',char(10));
num=sym(char(a(2)));
den=sym(char(a(3)));
ezplot(num/den,[0 100])

“Step response”

SEE COMPLETE ANSWER CLICK THE LINK

Simple! That is me, a simple person. I am passionate about knowledge and reading. That’s why I have decided to write and share a bit of my life and thoughts to.