# Communications Theory For Electrical Engineers Computer Science Essay

Published: Last Edited:

This essay has been submitted by a student. This is not an example of the work written by our professional essay writers.

As time passes the world digital electronics is continuing to evolve and most processes are done using digital electronics. Since most data consists of digital bits we need methods to transmit this data over long ranges. The reason that we are nowadays using Digital Modulation is that digital modulation provides more information capacity, better quality signal at the receiving end and quicker system availability. The things that we have to keep in mind when using Digital Modulation are the available bandwidth, the power our system takes and the noise level of our system.

Simple hardware can be used to transmit data digitally but nowadays hardware has evolved to preserve bandwidth which is a very precious media. Transmission of data is always improving giving us the ability to transmit data with a faster rate but at the same time conserving bandwidth.

Pseudo Random Binary Sequence

Pseudo Random Binary Sequence Theory

For the first part of the lab experiment we had to create a pseudo random binary sequence, pass the signal trough a low pass filter and then by sampling at certain intervals reproduce our signal. The benefits of this type of system is that by passing the Digital signal through a low pass filter we filter out any high frequencies and the signal takes less bandwidth. When passing a Digital signal through a low pass filter we can see a difference according to the cut off frequency of our filter.

http://ars.els-cdn.com/content/image/1-s2.0-S0378375802000770-gr2.gif

Figure - Square Wave before and after being passed through a low pass filter.

At the receiving end we rebuild the signal using a sample and hold. The sample and hold samples the signal and stores the data. We then can pass the data stored through a function which outputs a Digital 1 if the data value is greater than 0.5 or a Digital 0 if the data is less than 0.5. Using this function we are able to reconstruct our signal and use the data received.

Simulation for the Random Binary sequence

The random binary sequence was created by using a function in Matlab. First we use a function to rectify our signal. Since the Random binary sequence produced by the Matlab generator is between -1 and 1. Then we have another block that stores the random binary sequence and repeats it for 10 times.

The Binary signal is then passed through a low pass filter. The low pass filter attenuates high frequencies in the square wave signal. By filtering out high frequencies the binary signal we can see that the "square waves" in our signal will have rounded edges and oscillations at the top.

At the receiving end we have a sample and hold. The sample and hold samples the input signal when the pulse generator outputs a high signal. The pulse generator is set to output pulses with the same frequency as the random binary number sequence multiplied by 10. The sample and hold holds the sampled signal and then output it to a function which turns the signal to a low or high according to the signal voltage.

Figure - Generated Random Binary Sequenence before and after being filtered.

Figure - Fourier Spectrum for Random Binary Sequence.

Figure - Random Binary Sequence after filtering.By Comparing the Fourier Spectrum we can see the difference in the frequency components present in the two signals. For the Random binary sequence before filtering since we have a lot of high rising edges these contain a lot of frequency components. All these frequency components would drastically reduce our bandwidth which is a very limited resource.

Figure - Filtered signal and input pulses to Sample and hold.

From figure 5 we can see the pulses going into the sample and hold and the amount of samples being taken by the sample and hold to be able to reconstruct our signal. If the amount of samples is reduced we can have problems in reconstructing our original signal. The more samples taken the closer our reconstruction to the original will be.

Figure - The inputted signal (green) and the output (pink) after demodulating.

We can see from the random binary sequence transmission and demodulation that the components involved are very basic. Although transmission of binary signals take up a lot of bandwidth since they are a result of multiple frequencies, binary signals can easily be transmitted and reconstructed.

Binary Amplitude shift Keying (BASK) modulator and Demodulator Theory

The Binary Ask modulator is very basic and consists of outputting a sinusoidal signal only when we have a binary one. When the binary signal is Low then we output no signal. This is accomplished by having a carrier frequency multiplied by our binary signal. Using multiplication when the binary signal is one then we output the carrier. When the binary signal is low then no output signal is sent. This is a relative simple system but has the benefits of transmitting a digital signal without an infinite amount of frequency components. Although since we have our carrier being switched on and off we have some other frequency components apart of the fundamental still it takes less bandwidth then the previous modulator.

For demodulation we basically have two methods. The synchronous method consists of multiplying our signal by the carrier. By multiplying with the carrier since we have the carrier squared we have no negative values and that the signal is above zero. No negative values means that we can use a low pass filter and filtering the high frequency components while at the same time smoothing our signal. After the filter we achieve a signal similar to a square wave. All that is needed now is to use a comparator that outputs a high or low according to a reference that we set. This way we achieve a perfect binary signal similar to our input signal.

The asynchronous modulator basically doesn't need a carrier but just squares the input signal. This is has the same effect as multiplying by the carrier and so we can then use the rest of the demodulation technique used for the synchronous.

The simulation results below are the same for the synchronous demodulator and modulator and thus results for only one setup are presented.

Figure - Frequency spectrum of Modulated signal.

Figure - Frequency spectrum of Modulated signal after being multiplied by carrier.

Figure - Frequency spectrum of Demodulated signal after filtering.

Figure - Output frequency spectrum.

As can be seen from the graphs obtained it is as if we are switching on and off our carrier frequency according to the binary number. After multiplying the modulated signal by the carrier we square our signal and achieve only positive values. Furthermore we also obtain a frequency component at the same frequency of our binary signal. Then after we use the low pass filter to filter out the high frequency components and smoothing our signal. The low pass filter achieves a signal close to the desired square wave. The last step was to pass the signal to a function which outputs high when the input reaches a certain level the rest is zero.

From the scope graphs we can see how in the end the result was a square wave similar to the input with a phase shift.

Binary Phase shift keying (BPSK)

Binary Phase shift Keying (BPSK) modulator and Demodulator Theory

The BPSK contains bipolar data meaning that the input data contains both positive and negative voltages. The voltage level of the data switches the phase shift of the carrier from 0o to 180o. Thus this digital modulation scheme modulates data by changing the phase shift of the carrier according to the voltage of the binary data. The output signal contains a lot of frequency components due to the continuous switching of the carrier. Filtering of the input signal can reduce these frequency components and decrease the bandwidth of the message.

To produce the BPSK modulator what we need is to create a signal with equal positive and negative voltages. Then we need to multiply this signal by a carrier of equal magnitude. This way we end up with a signal consisting with the same signal as the carrier when the voltage was positive and the carrier with a phase shift of 180o when the voltage is negative.

Demodulation is done by multiplying the modulated signal by the carrier. By multiplying the carrier with the modulated signal we positive voltage signal were the signal was in phase with the carrier and negative voltage signals when the modulated signal was out of phase. Then what we have to do is to filter our signal to filter out high frequency components and use a function to output high or low according to the amplitude of the signal. In this case we output one if the signal is greater than zero and minus one if the signal is less than zero. Then we just add a one to our signal and we achieve the same modulating signal.

Simulation of the BPSK

Figure - Simulink block set showing Modulator and Demodulator for BPSK

Figure - Magnitude Spectrum for BPSK input signal

Figure - Modulated BPSK signal magnitude spectrum

After Modulation we can see how our modulated signal has a lot of frequency components mostly due to the signal switching on and off and the phase shift in parts of the signal.

After multiplying with the carrier we achieve a large low frequency component which is the frequency of our binary signal. By filtering we remove the other unwanted components and achieve a signal similar to our modulating signal.

Figure - BPSK modulated signal multiplied by carrier.

Figure - Demodulation - Signal multiplied by carrier and filtered.

Figure - Output signal Magnitude Spectrum.

From the scope graphs we see how as described in the theory section by multiplying with the carrier we achieve phase shifts in the carrier frequency. By demodulating appropriately then we achieve a output that is the same as our input.

For the BPSK we cannot demodulate asynchronously since we need to multiply the signal by a cos signal, if we were to square our signal we would have at parts cos2 and at parts sin2 which wouldn't give correct results.

Binary Frequency Shift Keying (BFSK)

Binary Frequency Shift Keying Modulator and Demodulator Theory.

FSK is a method were frequency modulation is used to transmit data. Digital information is transmitted by changes in the frequency of the carrier signal. The binary signal is unipolar meaning that it contains only ones and zeros. To produce this signal we can produce a carrier signal with a certain frequency when the signal is high and a carrier signal with a higher frequency when the signal is low.

To demodulate the signal then we use two band pass filters. One is set to filter everything apart of the low frequency and the other is set to filter everything apart of the higher frequency component. Then the procedure is the same as the other modulating schemes. We first square the signal and obtain a low frequency component with a frequency almost equal to the binary signal and then filter it to remove high frequency components. The result will be a signal similar to the binary sequence and so we use a function and values greater than a certain amount are set to one while others are set to zero. The two signals produced will be opposite to each other since one will be high for a binary one while the other will be low.

Binary Frequency Shift Keying Simulation

Figure - Simulink Block set for Binary Frequency shift key.

Figure - Scope for BFSK filtering out low frequencies in modulated signal.

Figure - Scope for BFSK Demodulating of high frequency in modulated signal.

Figure - Magnitude Spectrum for Modulated signal.

Figure - Signal passed through band pass filter and squared

Figure - Demodulated signal after low pass filter.

Figure - Output after demodulating the Signal.

As can be seen from the output after demodulating we manage to achieve the original signal. The frequency components in the transmitted signal aren't very high compared to previous digital modulators. This is an advantage of the BFSK since it takes up less bandwith than other Digital Modulation techniques.

QAM consists of two signals multiplied by two carriers and added together. One of the carriers is shifted by 90 degrees from the other. The input signal is bipolar and consists of 4 different voltage levels. Now when the input signal is multiplied by the carrier a phase shift occurs according to the voltage of the input signal. Thus we have 4 different type of voltage levels so 4 different types of phase shifts. Thus by finally adding these two signals which means adding cos( and sin( we achieve a sinusoidal signal with a certain amplitude and phase shift. Thus the QAM transmitted signal can consists of 16 different combinations.

For demodulating we multiply by the modulated signal with the carrier and also with the carrier shifted by 90 degrees. This is done separately and so we achieve two signals. When we multiply by the carrier we achieve a frequency component at the same frequency of our binary signal and frequency components at 2 times the carrier frequency. By using a low pass filter we can filter out the high frequency components and achieve a signal which is almost the same as the sent binary data.

Figure 27 - Modulated Signal for 16-Bit QAM

Figure - Modulating Signal for 16 Bit QAMFigure - Simulink Blockset for 16-Bit QAM Modulation and Demodulation

Figure - Output signal 1 after Demodulation.

Figure - Output Signal 2 after Demodulation.

Figure - Magnitude Spectrum for Modulated Signal.

Figure - Modulated Signal after being multiplied by carrier cos( signal.

Figure - Demodulating signal 1 after filtering out high frequency components.

Figure - Modulated signal after being multiplied by carrier sin(.

Figure - Demodulating signal 2 after filtering out high frequency components.

As can be seen from the simulation first we used a random signal generator which creates a signal which can have 4 different levels -2, -1, 1 and 2. Then we first inputted the signal into a repeater to repeat this signal for 100 times. The signal was then fed to a multiplier which multiplies the signal with the carrier. The carrier has a frequency of 10khz. The carrier of the second signal is the same as the other carrier but shifted by 90 degrees. Then the two signals are added together to achieve a signal which has both phase shift and amplitude modulation. The phase shift is caused by the different voltage levels of the input signal while the amplitude modulation is created when we add the two signals.

From figure 30 we can see that we have a frequency component at 10khz which is our carrier frequency. There are other frequency components around 10khz due to the different voltage levels and phase shifts. At the receiving end by multiplying our modulated signal with the carriers used before we achieve a signal with a low frequency component which is our signal and the carrier multiplied by 2. This can be seen in Figure 31 and 33 where we have a low frequency component and another component at 20khz. Using a low pass filter we remove the high frequency component and leave only our input signal. From Figure 28 and Figure 29 we can see how we managed to demodulate the signal and achieve almost the same input signal. A function can be used to further improve the clarity of the signal.

Conclusion

Throughout this lab session we have seen how using digital modulation we can transmit more data in the same bandwidth when compared to analogue modulation. Digital modulation is being used in a lot of modern technologies since it offers greater noise immunity and more flexibility. As we increase the data transmission rates we decrease the pulse width and thus have more frequency components reducing our bandwidth. This is always a tradeoff between bandwidth, data transmission rate and power output. Also as we increase the data rates we increase the complexity of transmitters and receivers. Thus as technology continues to evolve we will be able to transmit more data wirelessly improving our browsing and communicating experience.