How to design very narrow band, very sharp low pass filters - Only DC needed? I am using a DSP processor to sample signals at 108kHz and I only want to get the DC part out of it. Such a high sampling rate is used because I want to use oversampling to reduce quantization noises.

Two filters are to be designed: 


One has 10Hz stop-band frequency; new data are read every 0.1 second;
One has 0.1Hz stop-band frequency; new data are read every 10 second;


What I did

I used several stages of decimation and downsample the signals to 300Hz. Then I use FIRs to filter the signal:


For the 10Hz bandwidth: 128 stage filters are used
For the 0.1Hz bandwidth: 768 stage filters are used.


My question

Performance is the most important to me: The sharper low-pass filters are, the better. 


Could I ask for suggestions in implementing such a filter?
Is it possible to design a 0.01Hz low pass filter? If so, the new data can be read every 100 seconds?
I heard that using IIRs could be a solution, is it?


Thank you very much!

Is averaging the best DC filter?

I tried to compare with matlab:

Setting 1:
%Use Matlab fir1 function


  
    size = 1080000;
    h = fir1(size, 0.00000000001);
    fvtool(h)
    
  


Setting 2:
%Build an averaging FIR 


  
    size = 1080000;
    h = ones(1,size);
    h = h *1/size;
    fvtool(h)
    
  


The theory should be both two settings have similar performance. However, it seems that fir1 has narrower stopband than the simple average filter. It seems that the average DC filter will include more noises.
If all you want to do is get an estimate of the DC component of your data then you can simply obtain the average value of your signal over a unit of time. This can be easily shown by looking at the expression for calculating the Fourier coefficients for 'f=0' (DC component).

The easiest way to do this is via a moving average filter (http://en.wikipedia.org/wiki/Moving_average) which would work over a buffer. 

In terms of an FIR filter, this looks like 'h = ones(1,Nbuff)./Nbuff' (so, 'h=[0.5,0.5]' for a 2 sample buffer). 'Nbuff' stands for the order of the filter. This can be applied directly on the buffer you obtain from your CODEC through a convolution function as provided by your processor's command set.

You could also use an 'online algorithm' (an IIR filter essentially) which maintains an updated estimate of the mean of the signal on a per-sample basis. For this purpose please see: http://en.wikipedia.org/wiki/Algorithms_for_calculating_variance#Online_algorithm You could also design a "typical" IIR filter that can be as strict as you like, provided that your processor and sampling period can accommodate the computations required. 

(Of course you can adapt between working in terms of frames and working in terms of individual samples)

Just a note, I have a feeling that you are struggling with the concept of Group Delay. The cut off frequency of your filter does not exactly mean that "new data can be read every 100 seconds". New data will be fed to your filter constantly, at the sampling rate of the system, but the phase delay caused on each harmonic component of your signal between the input and the output of the system might vary. How this varies, depends on the type of the system (whether it is FIR / IIR) and its form. Here is a starting point: http://en.wikipedia.org/wiki/Group_delay_and_phase_delay

Hope this helps.