One of the most fundamental ways of representing signals is using sinusoidals waves. A basic sine wave of frequency @@0@@, amplitude @@1@@, phase @@2@@ and displacement @@3@@ can be represented by:

@@0@@

Let's plot a sine wave of @@0@@, @@1@@ and sample frequency @@2@@ hertz

Note that the unit of @@0@@ is @@1@@ radians

Now let's define a function to return the signal of a generic sine wave

Let's also define a funciton to return the values for a generic time line. Remember that sample period @@0@@, giving in terms of the sampling frequency @@1@@.

@@2@@

In the plot above, we have a sine wave of @@0@@ hz sampled at @@1@@ hz. In this section we will introduce the Nyquist Theorem intuitively. This theorem states that the maximum frequency that can be properly represented is half of the sampling frequency, i.e.,

@@2@@

Note that this theorem holds for continuous values. When dealing with discretized values we need to sample the signal by a factor greater than 2. Let's observe how the plot behaves when decreasing the sampling frequency, @@3@@.

As we observe bellow, the @@0@@ hz is the smallest frequency that is able to represent properly the sine wave of @@1@@ hz. This is because the sampling periodicity has to match, i.e. be in phase with, the maximum and minimum points of the maximum frequency to be measured in order to properly capture its magnetude.

If the sampling starts in phase with the maximum and minimum points of the maximum frequency to be measured, its possible to fully capture a signal by sampling it with double of the frequency of its maximum frequecy. See the plots bellow.