8

We know that Fourier Transform of a signal exists if it is absolutely integrable and it exists for periodic signals if impulse functions are allowed.

If we consider the fourier transform of $\text{rect}(t)$ , we get $\text{sinc}(f)$ in frequency domain. Which has got zero frequency component as $1$. But we all know, DC value of $\text{rect}(t)$ is zero.

My question is:

  1. If a signal has got a zero frequency component in frequency domain ,There must be DC value in time domain. But why there is no DC value in case of $\text{rect}(t)$ in time domain?
  2. What is the difference between DC component and zero frequency component?
Gilles
  • 3,386
  • 3
  • 21
  • 28
spectre
  • 565
  • 1
  • 8
  • 15
  • You argue about properties of periodic signals, yet none of your examples is periodic. – Jazzmaniac Feb 17 '15 at 15:22
  • 9
    The DC value of rect(t) is not zero. – Jim Clay Feb 17 '15 at 15:49
  • yeah,What i am saying is , if a signal is bandlimited,then its DC value should be zero, which is not true in the above case@Jazzmaniac – spectre Feb 17 '15 at 15:51
  • can you please elaborate on that ?@JimClay – spectre Feb 17 '15 at 15:52
  • 2
    @JimClay: Its Fourier transform at DC is non-zero, but its DC-value is zero, in the sense that its average over time, as the interval approaches infinity, is zero. Please see my answer below for more detail. – Matt L. Feb 17 '15 at 16:03
  • @spectre, bandlimitedness has nothing to do with a vanishing DC component. You seem to be massively confused. After reading your question several times, I'm still not sure what your real question is and what is only expressing misguided assertions. To me, your question is incoherent. – Jazzmaniac Feb 17 '15 at 16:10
  • @Jazzmaniac: I think the confusion is the fact that the value of the Fourier transform at DC can be non-zero for a signal with zero DC component, where the DC component is defined as the time average of the signal (limits going to infinity). I've tried to clear that up in my answer below. – Matt L. Feb 17 '15 at 16:14
  • @spectre: in your question you misleadingly refer to "dc-component" of X(jw) of rect(t); where, instead, you should better say value of X(jw) being nonzero at w=0. Since a single point of a function (X(jw)) in classical integral theory has zero area it does not make any DC components in time. You must integrate over a nonzero interval in frequency domain of a formal X(jw) to get a valid signal in time. – Fat32 Feb 17 '15 at 22:46
  • @Jazzmaniac:my question is simple, If a signal has got some zero freq component in freq domain,there should be zero freq component in time also,right? – spectre Feb 18 '15 at 14:41
  • @MattL.:yeah, you got my question. – spectre Feb 18 '15 at 14:43
  • @spectre, you might think your question was simple, because you understood what you wanted to ask. However you never defined what exactly you meant with DC offset and left the reader guessing. I understand your question now, but it would have helped to be a little more elaborate about your terminology. – Jazzmaniac Feb 18 '15 at 22:57
  • @Jazzmaniac:sorry for inconvenience. – spectre Feb 19 '15 at 01:51

5 Answers5

11

Let's first have a look at the rectangular signal given as an example in your question. If you have a rectangle $s(t)$ in the time domain which is $1$ in the interval $[-T/2,T/2]$ and zero elsewhere, its Fourier transform is $S(f)=T\text{sinc}(Tf)$, where I use $\text{sinc}(x)=\sin(\pi x)/(\pi x)$. The value of its Fourier transform at $f=0$ equals $S(0)=T$, which corresponds to

$$\int_{-\infty}^{\infty}s(t)dt=T\tag{1}$$

Its time average (or mean, or DC value) is given by

$$\bar{s}=\lim_{T_0\rightarrow\infty}\frac{1}{T_0}\int_{-T_0/2}^{T_0/2}s(t)dt=0\tag{2}$$

It is clear that any function for which the integral in (1) is finite, must have a DC-value of zero. The integral in (1) is the value of the Fourier transform of the signal at DC, and this is probably what confuses you. The DC value of a signal, and the value of its Fourier transform at DC are not the same. Any signal with a finite Fourier transform at DC has a DC value of zero, i.e. $\bar{s}=0$. Any signal with a non-zero DC value $\bar{s}\neq 0$ has a Dirac delta impulse component in its Fourier transform at DC.

If you write a signal as

$$s(t)=\bar{s}+\tilde{s}(t)$$

where $\bar{s}$ is the DC component as computed from (2), and, consequently, $\tilde{s}(t)$ has a DC component of zero, then its Fourier transform is

$$S(f)=\bar{s}\delta(f)+\tilde{S}(f)$$

where $\tilde{S}(0)$ is finite.

EDIT: Also note that when the Fourier transform of a signal $s(t)$ has a certain non-zero value at a frequency $f_0$, then this does not entail that the signal has a pure sinusoidal component at that frequency. The same is true for DC. If the Fourier transform has a finite value at DC, the time-domain signal has no DC component, otherwise there would be a Dirac impulse at $f=0$, just as there would be a Dirac impulse at $f_0$ if the signal contained a sinusoid at the frequency.

Matt L.
  • 89,963
  • 9
  • 79
  • 179
  • thanks a lot for such a clear explanation,But my queastion is not solved,1) Are you saying zero freq component is not same as DC value? – spectre Feb 17 '15 at 16:15
  • @spectre: These are just names used incoherently by people. What I'm saying is that the DC value of a signal is not the same as the value of its Fourier transform at DC. You always need to check what people actually mean by the terms they use. As far as I know there is no clear definition for what is meant by "zero frequency component". I would guess that they mean the value of the Fourier transform at DC, and then the answer you're looking for would be: NO, those two are not the same. – Matt L. Feb 17 '15 at 16:18
  • But intuitively it doesnot make any sence right? – spectre Feb 17 '15 at 16:48
  • @spectre: As long as you use it with care, you are ok. DC value of a signal mathematically refers to average value of x(t) over infinite duration. However in practice intuitively you may call it just as if its the DC voltage of a 3.6 V li-ion rechargeable cell phone battery. Even though it wont exist forever long, it will provide that DC value in practice... then you are ok. – Fat32 Feb 17 '15 at 17:01
  • @spectre: Not sure about your intuition, but as soon as you have an isolated frequency component in your signal (either a sinusoid at a certain frequency, or a DC component), the Fourier transform has a Dirac impulse at that frequency. So if you look at it in this way it does make sense I guess. – Matt L. Feb 17 '15 at 17:01
  • @Downvoter: it's OK if you downvote, but please be constructive and leave a comment explaining why you think this answer is not useful. – Matt L. Feb 17 '15 at 17:05
  • @MattL Sorry, I downvoted and was in the process of explaining why, when I realized that I was mistaken and un-did the downvote. – Jim Clay Feb 17 '15 at 17:06
  • @BulentS.:I partially agree with you,But the DC you mentioned in not the actual DC we consider in theoretical analysis,as theoretically DC is a power signal.But practically there are no power signals right?.So i dont think we can't consider these practical DC and theoretical DC as equal as they have got same name. – spectre Feb 17 '15 at 17:27
  • @MattL.:I understand what you are saying,But I coudn't understand how you are relating this explanation with answer. – spectre Feb 17 '15 at 17:33
  • @spectre: In my answer I explained that "DC value" $\neq$ "value of Fourier transform at DC". So if you mean by "zero frequency component" the value of the Fourier transform at DC then the answer to your question is that "zero frequency component" and "DC value" are not the same. Or don't I get what you mean? – Matt L. Feb 17 '15 at 17:39
  • No,you are clear.But i don't understand why there is such a basic confusion exists in Fourier Tranform? – spectre Feb 17 '15 at 18:26
  • @spectre: I have checked Oppenheim's books. He does not specifically refer to DC component when dealing with CTFT X(jw) of x(t). He uses DC coefficient in the case of CT Fourier Series of periodic signals. And as an extension of that CTFT of a periodic signal will have a DC component if its CTFS coefficient a0 is nonzero. Which will be reflected in the CTFT X(jw) of x(t) as an impulse at the origin... – Fat32 Feb 17 '15 at 18:33
  • @spectre: It's not really a confusion in the theory of the Fourier transform, just sloppiness when it comes to words. The "DC-value" of a signal is pretty clear for most people. The fact that this does not correspond to the value of the FT at DC may be a minor source of confusion. – Matt L. Feb 17 '15 at 18:34
  • 2
    @spectre I think that there are two sources of confusion. Most of us are engineers, so we are used to dealing with the practical, not abstract theory. Integrating from $-\infty$ to $+\infty$ is theory, not reality. In any real scenario, rect(t) will have non-zero mean. The other difference is that most of us deal with discrete Fourier transforms, not continuous transforms. In the realm of the discrete Fourier transform the zero frequency bin would diminish as the mean diminished- i.e. the limit of the zero frequency component of the transform would also be zero. – Jim Clay Feb 17 '15 at 20:49
  • +1. Took me some time, but I eventually realized that, in the OP's context, this is the right answer. – Jim Clay Feb 17 '15 at 20:51
  • @JimClay: you may also look at my new expanded answer which is now more beautiful and more and broader than ever... :) – Fat32 Feb 17 '15 at 22:25
  • @MattL.I think that edited part answered my question.thanks – spectre Feb 19 '15 at 01:45
  • Note that for discrete fourier transform, the formula is normalized by the # of data points. This makes DC offset the same as the 0 component. – thang Feb 27 '15 at 00:26
  • Why is the average value of rectangular signal 0 ? When I integrate between -T/2 to T/2 , the integral results in value T which cancels with T in denominator yielding average value as 1. This is also intuitive that area under pulse is 1 x (T/2+T/2) = T. When this area is divided by T, the result is 1 even if T -> infinity. I donot understand!! – nurabha Apr 01 '19 at 06:56
  • @nurabha: If its width is finite, then, according to Eq. (2) in my answer, its average is zero. – Matt L. Apr 01 '19 at 07:16
  • isnt this contradicting with the examples shown is this video https://www.youtube.com/watch?v=03s-CdsfSTI ? – OuttaSpaceTime Jan 18 '22 at 21:54
9

There is no difference between DC component and zero frequency component. They are two different names for the same thing.

Your mistake is in thinking that sinc(t) does not have a non-zero mean. sinc(t) does have a non-zero mean.

Jim Clay
  • 12,101
  • 31
  • 55
  • if a signal has got DC value ,then it must be power signal and its FT should be impulse,As you said , if signal has got DC value ,why there is no impulse in freq domain? – spectre Feb 17 '15 at 15:05
  • please check the edit – spectre Feb 17 '15 at 15:18
  • @spectre It is not a power signal, it is an energy signal. See Bulent's answer. – Jim Clay Feb 17 '15 at 15:44
  • yes,what i am saying is why an energy signal has got DC component in freq domain , but it has got no DC component in time domain?@Jim clay – spectre Feb 17 '15 at 15:55
  • sorry ,thats my mistake ,I edited the quastion after this answer@MattL. – spectre Feb 17 '15 at 16:16
  • 2
    I think the important distinction to make is between a signal's DC value given by $\lim_{T\rightarrow\infty}\frac{1}{T}\int_{-T/2}^{T/2}s(t)dt$ and the value of its Fourier transform at DC. The signal's DC value can be zero, even though its FT at DC has a finite value. – Matt L. Feb 17 '15 at 20:22
3

I am going to offer a very simple intuitive explanation to add to the excellent and detailed mathematical answers already given. I believe the question being asked comes down to the confusion of observing that the transform of the rect function (a Sinc function) has a value of 1 when the frequency component is 0, but intuitively we know that a rect function has no DC component (it's average goes to zero as time goes to infinity).

To resolve this quite simply, realize that the transform for any non-repeating waveform is a continuous function in frequency. The transform of the rect function represents an energy density in frequency, and a non-zero frequency range is always required to quantify non-zero density in frequency. "DC" is a point on the frequency domain which has zero width, and therefore would have zero energy in this case. To really observe DC with "zero width" in frequency, implies that we would have to observe it for an infinite amount of time. This is consistent with our first explanation that the mean of the rect function in time approaches zero as time goes to infinity. Further, if we observe the mean of the rect function for any shorter duration of time than infinity, then we are observing over an actual width in frequency (approximately 1/T where T is the observation time), and we will also see that the mean over a finite time interval is also non-zero.

With that DC can only be represented in a Fourier Transform as an impulse at $f=0$.

Dan Boschen
  • 50,942
  • 2
  • 57
  • 135
2

For periodic signals (or integrating a finite window, with the outsides unspecified), the DC value of a 50% duty cycle rect function depends on the sum of the top level and the base level. It's only zero if the base is at a level inverse to the top.

hotpaw2
  • 35,346
  • 9
  • 47
  • 90
1

A brief answer.

Rect does NOT contain any DC component = No component at frequency = 0. But the fourier transform does tell there is a DC component at frequency = 0, and the rect function associated with that inverse fourier transform does have a DC component.

How the hell! How can the same rect function both have a DC component and not? It does not make sense. Well, the catch lies in the details.

In the first case, you are viewing a zero mean rect function - DC component 0.

To calculate the fourier transform of the same function, you need to have only positive values, so the entire rect function is shifted up (DC) to create the fourier transform graph that you see. Thus the DC component.

The shifting is usually done. I do not why.

Nice question!

P.S : To understand fourier transform as an engineer, there is one video which is better than 3blue1brown's. Check this out : https://www.youtube.com/watch?v=Oi0DrIf7Ipc&list=PL8mQv9_ssjDbntpOMevDqi1arvDjxfQsK&index=12 from 50:00 and the next couple videos in that playlist to understand how it works. You can design the DFT algorithm by yourself in python following this approach. Will hardly take you ten minutes.