Experiment No 7
GENERATION OF OQPSK WAVEFORM USING SCILAB
Aim: - Study of OQPSK waveforms using Scilab code.
Tools Used: - SciLab
Objective:
• To understand Offset Quadrature phase shift keying (OQPSK) output waveform.
• To write Scilab code to generate QPSK waveform for the given binary data.
• To compare offset QPSK with non-offset QPSK.
Theory: - The optimum Eb/No performance achievable with BPSK led to a search for mechanisms to
improve the bandwidth efficiency of PSK schemes without any loss of performance. It was found
that since cos2πfct and sin2πfct (where fc is the carrier frequency) are coherently orthogonal signals,
two binary bit streams modulating the two carrier signals in quadrature can be demodulated
separately. (In analog communication, this idea has been used for a long time to multiplex two
signals on the same carrier, so as to occupy the same bandwidth, e.g., the two chrominance signals in
color television are modulated onto the color subcarrier this way). Such a modulation scheme,
increasing the bandwidth efficiency of binary PSK by two, is known as QPSK
The input binary bit stream {ak}, (ak = ±1) k = 1, 2, 3 . . . arrives at a rate of 1/T baud and is separated
into two streams aI (t) and aQ (t) consisting of even and odd bits, respectively. The two pulse trains
modulate the in-phase and quadrature components of the carrier and the sums (t), the modulated
QPSK signal, can be represented as:
2 2
√
s ( t ) =a I ( t )
T √
cos ( 2 π f c t ) +a Q ( t )
T
sin ( 2 π f c t )
The extent of amplitude fluctuations exhibited by QPSK signals may be reduced by using offset
QPSK. In this variant of QPSK, the bit stream responsible for generating the quadrature component
is delayed (i.e., offset) by half a symbol interval with respect to the bit stream responsible for
generating the in-phase component. Unlike QPSK, the phase transitions likely to occur in offset
QPSK are confined to ±90 degrees, as indicated in the signal space diagram. However, ±90 degree
phase transitions in offset QPSK occur twice as frequently but with half the intensity encountered in
QPSK.
Page 1 of 4
Output / Results: -
The binary data 0 0 0 1 1 0 1 1 is applied to the input of an OQPSK modulator.
a. Draw the OQPSK output waveforms.
b. Write a Scilab code to generate the same waveforms.
Page 2 of 4
clc;
clear all;
close;
b = [0 0 0 1 1 0 1 1] // input bits
len = length(b); // Length of input bits
Ts = 2; // Symbol Time Interval
t = 0:0.001:1
f=1 //frequency of signal
b_PNRZ = [];
for i = [Link]len // converting into polar NRZ
if(b(i)==0)
b_PNRZ = [b_PNRZ, -1]
else
b_PNRZ = [b_PNRZ, 1]
end
end
ps = 0.5; // Symbol Power
I_carrier = sqrt(ps) * cos(2*%pi*f*t) // In phase carrier
Q_carrier = sqrt(ps) * sin(2*%pi*f*t) // 90 deg out of phase carrier
z=0
subplot(3,1,1)
a= gca();
a.data_bounds = [0 -2; len 2]
a.x_location = "origin"
[Link] = [1 1]
title("RIDHANG PANCHAL (TE_E&TC_A_47) - ODD DATA")
plot((t + z),b_PNRZ(1),'r') // Plotting the Odd dara
z = 1;
for i = [Link]len
if(modulo(i,2)==0)
I_off = 0;
Q_off = -1;
else
I_off = -1;
Q_off = 0;
end
subplot(3, 1, 1)
a = gca();
a.data_bounds = [0 -2; len 2]
a.x_location = "origin"
[Link] = [1 1]
title("RIDHANG PANCHAL (TE_E&TC_A_47) - ODD Data")
plot((t + z),b_PNRZ(i+Q_off),'r') // Plotting the Odd dara
subplot(3, 1, 2)
a = gca();
a.data_bounds = [0 -2; len 2]
a.x_location = "origin"
[Link] = [1 1]
title("RIDHANG PANCHAL (TE_E&TC_A_47) - EVEN Data")
plot((t + z),b_PNRZ(i+I_off),'r') // Plotting the Even dara
subplot(3, 1, 3)
a = gca();
a.data_bounds = [0 -2; len 2]
a.x_location = "origin"
[Link] = [1 1]
title("RIDHANG PANCHAL (TE_E&TC_A_47) - OFFSET QPSK Output")
plot((t + z),I_carrier * b_PNRZ(i+I_off) + Q_carrier * b_PNRZ(i+Q_off),'r') // Plotting the final output
Page 3 of 4
z = z+1;
end
Conclusion: -
1) What are the advantages of QPSK modulation?
A QPSK (Quadrature Phase Shift Keying) modulation sends two bits of digital information at a time,
called as dibits. Instead of the conversion of digital bits into a series of digital stream, it converts
them into bit pairs. This decreases the data bit rate to half, which allows space for the other [Link]
bandwidth requirement also becomes half and the spectral efficiency is doubled, if compared to
BPSK.
2) How offset QPSK is better than non-offset QPSK?
In OQPSK, the maximum phase shift that can occur is of 90 deg which is better compared to
conventional QPSK in which a change of 180 deg can occur.
Practical Learning Outcomes:
After performing the practical, the learner is able to: Marked √
Understand Offset Quadrature phase shift keying (OQPSK) output
waveform. √
Write Scilab code to generate QPSK waveform for the given binary
data. √
Compare offset QPSK with non-offset QPSK. √
Outcome PLO 1 PLO 2 PLO 3 Performance Attendance Total Score E&TC DEPARTMENT- TCET
Date of
Performance: 06/04/2021
Date of Correction: 13/04/2021
Weighta
20 20 20 20 20 100
ge Roll No: 47
Marks: ______/100
Signature of Faculty:
Page 4 of 4