syerramilli / R-sysid

4 stars 2 forks source link

idinput rgs signals blowing up #14

Closed syerramilli closed 8 years ago

syerramilli commented 8 years ago

This happens when a frequency band is specified

syerramilli commented 8 years ago

The following line in gen.rgs() might be the source of the problem. v<-rnorm(n,mu,sigma)

Remember that the signal to be passed through the Butterworth filter should be a unit normal one. The transformed signal is then to be scaled.

ashwinrcs commented 8 years ago

What is the error that is being shown? and for what input? Also, do we have to first generate a signal with a specified mu and sigma -> scale it -> pass through filter -> re-scale it?

syerramilli commented 8 years ago

The generated signal is blowing up for some reason (read unbounded). You need to generate a unit normal signal, pass through filter and then rescale it

rplot

syerramilli commented 8 years ago

The function fails as we are taking a band-pass version even for a low-pass filter. This issues is resolved by adjusting the filter type according to the band.