help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: how does lsim deal with transfer function gain


From: Lukas Reichlin
Subject: Re: how does lsim deal with transfer function gain
Date: Sun, 9 Sep 2012 19:23:32 +0200

On 06.09.2012, at 17:03, zaxscdvfbg <address@hidden> wrote:

> If i have 
> 
> poles =[ .....]
> zeros = [.....]
> 
> numpoly=poly(zeros)
> denpoly=poly(poles)
> 
> sys=tf(numpoly,denpoly)

use

sys = zpk (zeros, poles, gain)

instead.

> 
> You may get for example
> 
> (s^2 + 45*s + 2)/(s^3+3245*s^2+45e5*s + 5.567e8)
> 
> The DC response in near zero because the ratio of the constants is
> (2/5.567e8)
> 
> Does lsim include a gain K automatically which might be K = 5.567e8/2  for
> this example??

lsim uses transfer function to state-space conversion for simulation. If 
transfer functions are badly scaled, some entries in the state-space matrices 
could be assumed to be zero as a minimal realization is sought.

> 
> I ask because sometimes it seems to do this and sometimes it does not.
> 
> Also if the cooefecient with the zeroth power of s is very large i get zero
> results output.
> 
> Might i need to break large transfer functions into cascaded second orders
> ??

No, you should scale your transfer functions properly. For larger systems, use 
state-space representations. Scale inputs, outputs and states. State 
transformations are handled by the prescale command, but input and output 
scalings are up to the user for obvious reasons.


> If so this sounds like a good candidate for an official function..
> 
> Thanks

Lukas

reply via email to

[Prev in Thread] Current Thread [Next in Thread]