Because over here, the original signal is positive and the basis function is

positive, and so their product is positive.

Over here, the basis function, the sine wave is negative but the signal was also

negative and so negative times negative, that gives me positive.

And so I get this double-humped, it's like two half-cycles of sine waves, both

positive, and the meaning of the integral is to just sum up the area under the

curve. And so if I add up all the area under

this curve it turns out that you get 1 for that.

Now, I want to do the same thing with the cosine wave, and so I also have the

lowest frequency cosine, which has the same period as the total duration of my

input signal. And so I'm going to multiply those two

together. And then sum up the area of the resulting

curve. So you see, it's the cosine function is

positive, and the signal is positive. And so I get a positive region here.

Then the cosine goes negative, but the signal, the red, is still positive, so

that's negative. Then they're both negative.

The cosine function is negative, and the signal is negative, so their product is

positive. And then the cosine goes positive but the

signal's still negative so their product is negative.

Now, when we add up the area, we count area above the axis as positive.

Area below the axis is negative. And so if I add this up, you can see

these two are the same as those two, so this cancels that and this cancels that.

So if I add that altogether, I get zero. So that's telling me that the cosine wave

is not like the original input signal. They're not alike, they're too dissimilar

for the recipe to call for any of this cosine wave.

And in fact, the reason for that is because of the symmetry.

if we look at the symmetry of the original signal it's symmetric, or

anti-symmetric, about this point, as positive to the left and negative to the

right. the sine wave has exactly the right

symmetry. That's positive to the left and negative

to the right of that point. The trouble with the cosine is that is

has the opposite symmetry. It looks the same on to the left as it

does to the right. So, this is the cosine basis fun-,

function is symmetric about this point; the sine basis function is antisymmetric.

The signal is antisymmetric. And so, there's going to be similarity

between the signal and the sine, but there's no similarity between the signal

and the cosine. So that's why you have to, check your

signal against both the sine and the cosine basis functions.

So let's carry on, and look at, a couple of more examples, of the next higher

frequency in the Fourier series. So here's the same original basis

function, the red. And so now I want to calculate the b2,

which is the sine component. And so I draw the sine.

And now I'm going to multiply these. So it's going to positive over here,

negative, positive, and negative. And then the, I want to then add up the

area under the curve, counting above the axis as positive and below the axis as

negative. And so you can see that this is going to

all cancel out and we'll get 0. So there's none of this second harmonic

sine wave in that square wave, and we knew that because when we built the

square wave, a little while ago, we saw that it only took on harmonics.

There were no even numbers. in the Fourier series for that.

Now let's just take a look at one more. we'll, we'll see what the Fourier

coefficient a2 is for the cosine. At the second harmonic of that

fundamental. And, so, here's the cosine curve.