DSPRelated.com
Forums

How does sampling frequency affects a digital filter ?

Started by mel March 13, 2006
Hello,

          I am writing a digital filter but it seems that according to
the sampling frequency my filter should change ... how does this
happens ? being a digital filter there is no such a thing as sampling
frequency, right ?

          One more thing ... it seems that the cut off frequency should
affect my filter too ... the cut off frequency is the bandwidth of the
transmitting channel, right ? How should it affect the filter ?

          Sorry if these questions sounds dumb,

          thanks in advance, samuel

mel wrote:
> Hello, > > I am writing a digital filter but it seems that according to > the sampling frequency my filter should change ... how does this > happens ? being a digital filter there is no such a thing as sampling > frequency, right ?
Interesting question! I am not sure it is what you mean, but I interpret it as "If the signal is specified in discrete-time domain, the signal is never sampled and there is no such thing as a sampling frequency." I agree, this is a valid question.
> One more thing ... it seems that the cut off frequency should > affect my filter too ... the cut off frequency is the bandwidth of the > transmitting channel, right ? How should it affect the filter ?
The key here is that the filter in frequency domain is specified in terms of "normalized frequencies." If we agree to use "time" as name for the running variable in signal domain, and "fequency" in Fourier domain (we could have used space and wavenumber, or something else), the discrete-time signal has a limited-width spectrum. To make sense of it all, and relate it to the more intuitive case of a sampled signal, we speak of a "normalized sampling frequency" with sampling period 1. If we do that, all the T factors in the forward and inverse Fourier transforms disappear, and we still can speak a comprehensible language. In that case, the filter cut-off frequency is still well-defined, relative to the normalized sampling frequency. f_c = F_c/F_s = f_c*T/(f_s*T) = f_c*1/1*1 = f_c. In fact, most filter design packages work in this normalized domain, introfducing the T factor only when needed.
> Sorry if these questions sounds dumb,
No, they certainly are not. These are the kinds of questions that either make you shy DSP as a dicipline, or make you gain insight. Rune
My take:

being a digital filter there is no such a thing as sampling
frequency, right ?

Krishna>> In a digital filter, every thing gets normalized per your
sampling frequency. i.e if
you had a low pass filter with cutoff at 3kHz when you were sampling at
10kHz, the
cut off frequency will change to 6kHz if were to sample @ 20kHz.

it seems that the cut off frequency should
affect my filter too ... the cut off frequency is the bandwidth of the
transmitting channel, right ? How should it affect the filter ?

Krishna>> huh? 

Regards,
Krishna

My take:

being a digital filter there is no such a thing as sampling
frequency, right ?

Krishna>> In a digital filter, every thing gets normalized per your
sampling frequency. i.e if
you had a low pass filter with cutoff at 3kHz when you were sampling at
10kHz, the
cut off frequency will change to 6kHz if were to sample @ 20kHz.

it seems that the cut off frequency should
affect my filter too ... the cut off frequency is the bandwidth of the
transmitting channel, right ? How should it affect the filter ?

Krishna>> huh? 

Regards,
Krishna

mel wrote:

> Hello, > > I am writing a digital filter but it seems that according to > the sampling frequency my filter should change ... how does this > happens ? being a digital filter there is no such a thing as sampling > frequency, right ?
As Rune pointed out this is a bit unclear, but here goes... In the digital domain there is no such thing as sampling frequency. In the continuous-time domain there is no such thing as sampling frequency. Sampling frequency comes into play when you go to stitch together your continuous-time system with your discrete-time one. So yes, you do have to take the sampling rate into account when you're designing your digital filter, and to maintain essentially the same response in the continuous-time domain you would have to change your digital filter if the sampling rate changed.
> > One more thing ... it seems that the cut off frequency should > affect my filter too ... the cut off frequency is the bandwidth of the > transmitting channel, right ? How should it affect the filter ? >
What cut off frequency are you talking about? If you mean the cut off frequency of the digital filter then changing the sampling rate without changing the filter would change the cut off frequency of the system in the continuous time domain. -- Tim Wescott Wescott Design Services http://www.wescottdesign.com Posting from Google? See http://cfaj.freeshell.org/google/
Hello,


          Well, thanks for the kind answer and for your time ... I know
I haven't been much clear about this, but I have never studied dsp on
colege ( cs major, not electrical engineering ), so I am not very used
to the technical terms. All I have are books, interest and google =) (
and now comp.dsp ! ).

          Ok. So what I am trying to do is write a DVB broadcaster for
HDTV. I am doing ok for now, but now that I have come to the end of the
transmitter and have to acctually transmit the signal, I am having a
bit of dificulties ( on digital filters and QPSK modulation ) ...

          About the sampling rate being applied to a digital filter. I
agree with Tim : sampling rate just makes sense on a conversion of a
continuous time domain signal to a discrete time domain signal.
          If you are saying to me that "sampling rate == symbol rate"
then I can agree that sampling rate applies to digital filters : the
sampling rate of a digital filter makes sense because you are now
making a conversion of a discrete time domain ( digital ) to a
continous time domain ( analog symbols ) on a defined symbol rate .
         So ( please, let me know if I am right on this ) : sampling
rate makes sense on transitions of continous to discrete and discrete
to continous, right ?


          About cut off frequency, I must admit that I have no idea
what this is. I have a guess : the cut off frequency of a digital
filter is the maximum frequency ( on the frequency domain ) of a sinal
that the filter will let pass. Is this the idea ? So I can say that the
cut off frequency of my filter should be the same of the cut off
frequency of my channel, right ?


         One more thing about digital filters : I have to design a root
raised cosine filter, with rool off = 0,20 0,25 and 0,35, with several
symbol rates ( from 1msps to 30msps ). If changing these parameters
will change my FIR coeficients, i will have many diferent coeficients (
for all combinations of these parameters ). All these diferent filters
won't fit in my design, so how is the usual way to deal with several
configurations of a FIR ?


          Thanks for your time and patience, cya, mel

mel wrote:

> Hello, > > > Well, thanks for the kind answer and for your time ... I know > I haven't been much clear about this, but I have never studied dsp on > colege ( cs major, not electrical engineering ), so I am not very used > to the technical terms. All I have are books, interest and google =) ( > and now comp.dsp ! ). > > Ok. So what I am trying to do is write a DVB broadcaster for > HDTV. I am doing ok for now, but now that I have come to the end of the > transmitter and have to acctually transmit the signal, I am having a > bit of dificulties ( on digital filters and QPSK modulation ) ... > > About the sampling rate being applied to a digital filter. I > agree with Tim : sampling rate just makes sense on a conversion of a > continuous time domain signal to a discrete time domain signal. > If you are saying to me that "sampling rate == symbol rate" > then I can agree that sampling rate applies to digital filters : the > sampling rate of a digital filter makes sense because you are now > making a conversion of a discrete time domain ( digital ) to a > continous time domain ( analog symbols ) on a defined symbol rate .
Now how did symbol rate get in here? Symbols happen on digital communications links, and are _not_ the same thing as samples (which happen in digital signal processing applications). You can sample a continuous-time signal to demodulate digital data from it, but you generally sample well above the symbol rate if you want the demodulation to be good. Ditto for transmitting, if you want the output to be nicely filtered.
> So ( please, let me know if I am right on this ) : sampling > rate makes sense on transitions of continous to discrete and discrete > to continous, right ? >
Yes
> > About cut off frequency, I must admit that I have no idea > what this is. I have a guess : the cut off frequency of a digital > filter is the maximum frequency ( on the frequency domain ) of a sinal > that the filter will let pass. Is this the idea ? So I can say that the > cut off frequency of my filter should be the same of the cut off > frequency of my channel, right ? >
"Cut off" sounds abrupt. Real filters aren't. So the "Cut off" frequency for a filter is the frequency at which you see some significant level of attenuation of the signal -- usually 3dB (1/2 power) or 6dB (1/2 amplitude). Note that a signal that's only "cut off" by 6dB is pretty darn loud -- so filters also must be specified for how quickly they drop off. In analog radio applications this is measured by "shape factor", which is the ratio between the 60dB and 6dB (or 3dB) cutoff points; frankly I'm not sure if there _is_ an industry standard way to express this in DSP terms.
> > One more thing about digital filters : I have to design a root > raised cosine filter, with rool off = 0,20 0,25 and 0,35, with several > symbol rates ( from 1msps to 30msps ). If changing these parameters > will change my FIR coeficients, i will have many diferent coeficients ( > for all combinations of these parameters ). All these diferent filters > won't fit in my design, so how is the usual way to deal with several > configurations of a FIR ? > > > Thanks for your time and patience, cya, mel >
-- Tim Wescott Wescott Design Services http://www.wescottdesign.com Posting from Google? See http://cfaj.freeshell.org/google/
so what is the difference between sample rate and symbol rate ? plz
give me a clear explanation for newbie!
many thx

iamzhiyan@gmail.com wrote:
> so what is the difference between sample rate and symbol rate ? plz > give me a clear explanation for newbie! > many thx >
That's a difficult question to answer, because I don't know what you mean by 'sample' vs. 'symbol'. I do know what _I_ mean when I say 'sample' and 'symbol', and it's pretty close to what other people mean. Your easy mixing of them runs counter to much of my intuition and training, however. When you convert a continuous-time signal to a discrete time one, you go from a constantly varying signal to a signal that takes on discrete values at discrete points in time. The values of the signal at these discrete points in time are 'samples'. When you are working on a digital communication system you encode your message into a set of values at discrete times (like samples), but you further restrict these values to a limited set of discrete values. For example, for a binary modulation scheme you would choose values from the set {0, 1}, for quaternary you might choose {0, 1, 2, 3}. You're not restricted to numerical values, however -- you may choose a binary scheme with the values {ralph, bob}, or a quaternary scheme with the values {apple, orange, grape, toilet}. When you go to transmit your data, you must further translate from your set of values to something that can be modulated and demodulated easily. This is usually done by assigning a fixed symbol rate*, then assigning some easy-to-deduce parameter to each symbol time. For example, FSK is accomplished by sending a tone at one frequency for a 0 (or ralph) and another frequency for a 1 (or bob). In the sense that digital communications systems deal with streams of symbols that are ultimately discrete in time you can consider the symbols to be 'samples'. But when you are pondering filters and ADCs and DACs the 'samples' that you are talking about are pretty far removed from the 'symbols' in your communications system -- or should be. There _are_ communications formats (like most phase-shift keying schemes) where the modulation stage can be treated as a change in coding followed by a sample rate conversion. For example one could implement QPSK by converting {0, 1, 2, 3} into {1, i, -1, -i}, then doing a sample rate conversion to some convenient rate, filtering, frequency shifting and transmitting. This is a very small part of the whole communication system however. So: What do you mean by 'symbol', what do you mean by 'sample', why do you think that changing your symbol rate implies that you should change your sample rate, etc., etc., etc. * Morse code is a spectacularly successful example of a modulation scheme that does not use a fixed symbol rate. -- Tim Wescott Wescott Design Services http://www.wescottdesign.com Posting from Google? See http://cfaj.freeshell.org/google/
first ,thanks for ur patience,Tim...one more question
In the sense that digital communications systems deal with streams of
symbols that are ultimately discrete in time you can consider the
symbols to be 'samples'.
in BPSK i have the streams of symbols{1,0,1,0,0,0,1,1,0}
i can say the third symbol is 1, the duration of this symbol T=3D1/symbol
rate=3D1/sample frequency =3D1/sample rate ,right?
in QPSK i have the streams of symbols{01,11,00,01,01,11}
i can say the third symbol is 00, the duration of this symbol
T=3D1/symbol rate=3D/2=D7sample frequency =3D1/2=D7sample rate ,right?since=
 it
has I/Q channel.

thanks!