filtering out harmonic trend

Matthias Brennwald matthias at brennwald.org
Tue Dec 4 13:10:09 CST 2007



On 04.12.2007, at 14:41, help-octave-request at octave.org wrote:

> Message: 8
> Date: Tue, 04 Dec 2007 13:39:22 +0100
> From: Francesco Potorti` <Potorti at isti.cnr.it>
> Subject: filtering out harmonic trend
> To: Octave users list <help-octave at bevo.che.wisc.edu>
> Message-ID: <E1IzX3a-0003G2-90 at tucano.isti.cnr.it>
> Content-Type: text/plain; charset=iso-8859-1
>
> I have a 200,000 samples measurement, which is a sort of noise with
> bandwidth in the order of the inverse of 500 samples.  Superimposed to
> this noise there is a very slow sinusoid with a period of about  
> 300,000
> samples.  This means that my measurements do not even see a complete
> cycle of this sinusoid.
>
> I want to estimate the sinusoid (in order to remove it from the
> measurement).  So I need some sort of very-low pass filter.  However,
> usign a simple causal low-pass filter would give me a delayed output.
> Can anyone suggest some keyword for a noncausal filter to look for?  I
> guess that it could be simple, because the bandwidths of signal and
> noise are so far away each other.

If the low-frequency signal is a 'clean' sinusoid, then I'd try  
fitting a sinusoid to the data, and then subtract this sinusoid from  
the data. If the sinusoid is a function of time t and of the form s 
(t) = A * sin(2*pi*f*t+phi), then the fit parameters would be A, f,  
and phi. You can use fmins (available in the optim package) to find  
the best-fit values for A, f, and phi by minimizing the squared  
difference of your data and s(t).


>
> -- 
> Francesco Potort? (ricercatore)        Voice: +39 050 315 3058 (op. 
> 2111)
> ISTI - Area della ricerca CNR          Fax:   +39 050 315 2040
> via G. Moruzzi 1, I-56124 Pisa         Email: Potorti at isti.cnr.it
> Web: http://fly.isti.cnr.it/           Key:   fly.isti.cnr.it/ 
> public.key




-------
Matthias Brennwald
Lägernstrasse 6
CH 8037 Zürich
+41 (0)44 364 17 03
matthias at brennwald.org





More information about the Help-octave mailing list