[SciPy-user] problems with signal-functions impulse and step ...
Mon Apr 16 03:01:14 CDT 2007
Stefan van der Walt wrote:
> Hi Stef
> On Sun, Apr 15, 2007 at 10:35:12PM +0200, Stef Mientki wrote:
>> I wonder if I'm doing something wrong,
>> or if the signal library might have has some small bugs.
>> Do others have the same experience ?
>> #I create a highpass filter,
>> #which amplitude and phase characteristic looks good
>> filt_1 = signal.iirdesign( 0.06, 0.002, 1, 50, 0, 'butter')
>> # Now when I want to calculate the impuls response,
>> aa,bb = signal.impulse( filt_1, filt_1 )
> The function signature for signal.impulse is
> signal.impulse(system, X0=None, T=None, N=None)
> system -- an instance of the LTI class or a tuple with 2, 3, or 4
> elements representing (num, den), (zero, pole, gain), or
> (A, B, C, D) representation of the system.
> (By the way, IPython is extremely useful in investigating this sort of
> thing -- you simply type signal.impulse?<enter>)
> So, I think what you want to do is:
> aa,bb = signal.impulse(filt_1[:2])
but it doesn't seem to work either.
Although I'm just a beginner with Python (coming from MatLab),
I don't see the difference between:
aa,bb = signal.impulse(filt_1[:2])
aa,bb = signal.impulse(filt_1)
knowing that the first dimension of filt_1 = 2,
and indeed it gives the same problems ;-)
or am I missing something ?
Kamer van Koophandel - handelsregister 41055629 / Netherlands Chamber of Commerce - trade register 41055629
More information about the SciPy-user