0:53

Let's hear it.

[SOUND].

Okay.

In order to see that it's periodic, we can zoom into it,

and here we see the sinusoid oscillation, the periodic oscillation of a sine wave.

If we zoom even more, we are going to start seeing the samples

that are present in this signal, this discreet signal.

So we have generated this signal at 44,100 hertz, so

we'll have that many samples per second.

Okay, so the first thing we might want to do to understand

the concept of periodicity is to measure what is the period length.

Now the idea of periodic means that there is

a period that is repeating a cycle of the sound.

Okay, so this is a cycle of this sinusoid,

and in here we can see what is the length of this selection I made.

And it says that it's 0.002.

So that means 2 milliseconds.

If we go to the terminal and have Python in, we can use it as a calculator.

So we can convert this period length into frequency.

So the inverse of the period, so

1 over 0.002, will be our frequency.

And of course it gives us 500 hertzs.

500 hertzs is the frequency of this sinusoid.

Okay, another thing we might want to check is okay,

this period has a series of sample.

So, how many samples does one period of this sinusoid has?

Well, in order to compute that, what we should do is start with the sampling rate.

The sampling rate is 44,100.

And multiply by the duration of this period.

So we multiply by 0.002.

And it gives me 88.2,

which is the number of samples of a period.

Of course it should be an integer number.

So I guess it's going to be 88 samples in one period, okay?

Now let's generate another sinusoid but of a different frequency.

So let's maybe open a new file, okay?

And let's create another sinusoid.

But instead of 500 hertz, let's put, for example, 5000 hertz.

Okay, so this is the sinusoid of 5000 hertz.

We can hear it too.

[SOUND].

Clearly, much higher, and we can also zoom,

and to see the periodicity.

But here we already see that is not so nice, in fact

the samples are not really shaping a smooth sinus little function.

This is because there is less samples per period,

therefore we don't have a various most version.

So how many samples are in one period?

Well, not that many.

In fact, here we can even count them.

And it's one, two, three, four, five, six, seven, eight.

So in fact we have like eight, nine samples for one period.

Not exactly because they don't coincide, of course, with a period.

Of course it makes sense because if we had seen that

the frequency of Pythagorean had 88 sample in one period.

Now that we have 10 times the frequency, 5,000, the number of samples

will be 10 times less, so it's going to be around 8 or 9 samples, that's pretty good.

Of course, this relationship between the number of samples and

the frequency is a very important one, and related with the sampling rate.

The bigger the sampling rate, of course, more samples we'll have.

And for higher frequencies, we'll have more samples.

At 44,100, as we go up in frequency, and if we go even higher,

like 10,000 or even 15,000, the number of samples will be very less.

And therefore,

the shapes will not look like a sinusoid even though it's a sinusoid.

6:27

But in this case, the period which we can measure and

it's going to be the same thing, 500.

It doesn't mean that there is one frequency at 500 hertz.

In fact, this wave form has many frequencies.

It has 500 hertz as a fundamental frequency and it has multiples of that.

So that it's a harmonic sound.

And how can we check that?

Well, we check that with a spectrum analysis.

And in Audacity, we have specifically to plot the spectrum, okay?

And here now it tells me that there is not enough data because I have to choose

a bigger part of the sound, so let's choose a bigger fragment of the sound.

And now we can plot, now we can visualize the spectrum of this shuttle.

And clearly we see that is a quite complex spectrum, in which it has many peaks.

In order to understand this,

I think it's good to compare it with the sinusoidal we started with.

So this was the sine wave we started.

And if we do the same thing that we have done now with the status, that is to

compute the spectrum, well we see now that it's clearly very different.

The spectrum of a sinusoid has only one measure peak.

And the frequency in this case, 400.

And the spectrum on this has many peaks

which correspond to all the frequencies present in this harmonic signal.

8:54

So now we have kind of a glissando, a chirp, and of course we can play it again.

[SOUND].

Okay, so it's a frequency that goes up, and again of course, we can zoom.

But we will see that the period keeps changing in time.

So here at the beginning,

we'll have a period that is going to be quite long.

It will be the 500 hertz, the 2 milliseconds.

And by the end, it will be much smaller.

It will be ten times smaller, okay?

And of course we can visualize that by analyzing the spectrum of this signal.

So if we select a portion at the beginning and analyze the spectrum,

we will see that it has around 500 hertz frequency.

And if we go to the end, so we go to

10:47

And we have talked about electronic periodic signals,

synthesized periodic signals.

These are signals that are quite good to play around with because we know how we

generate them, so therefore when we analyze them we know what to expect.

So in next demo class, we'll complicate that, so

we will actually analyze more complex signals, sounds, that might

have some parts of the periodic, might have some parts that are not periodic.

So they reflect more the reality of real sounds, so

I hope to see you next class, thank you very much.