Simulate matched filter system with SRRC filtering

Key focus: Let’s learn how to simulate matched filter receiver with square root raised cosine (SRRC) filter, for a pulse amplitude modulation (PAM) system.

Simulation Model

A basic pulse amplitude modulation (PAM) system as DSP implementation, is shown in Figure 1 by adding an upsampler (), pulse shaping function () at the transmitter and a matched filter (), downsampler () combination at the receiver.

DSP implementation of a PAM modulation system with pulse shaping and matched filtering
Figure 1: DSP implementation of a PAM modulation system with pulse shaping and matched filtering

In this model, a random stream of source bits is first segmented into -bit wide symbols that can take any value from the set . The simulation code directly starts by generating a random set of symbols, that goes into the modulation mapper. Pulse amplitude modulation (MPAM) mapping and de-mapping, described in sections 5.3.1 and 5.4.1, are considered here for simulation. An MPAM modulator maps the -bit information symbols to one of the distinct signaling levels. The MPAM modulated symbols are shown in Figure 2.

This article is part of the book Wireless Communication Systems in Matlab, ISBN: 978-1720114352 available in ebook (PDF) format (click here) and Paperback (hardcopy) format (click here).

%Program: MPAM modulation
N = 10ˆ5; %Number of symbols to transmit
MOD_TYPE = 'PAM'; %modulation type
M = 4; %modulation level for the chosen modulation MOD_TYPE
d = ceil(M.*rand(1,N)); %random numbers from 1 to M for input to PAM
u = modulate(MOD_TYPE,M,d);%MPAM modulation
figure; stem(real(u)); %plot modulated symbols
Figure 2: M-PAM modulated Symbols

Each MPAM modulated symbol should last for some duration called symbol time, denoted as . Each modulated symbol will go through a discrete time pulse shaping filter whose impulse response is spaced sample, where denotes the sampling period. To do this, the incoming symbols from the modulation mapper need to be converted to discrete time impulse train by upsampling them by a factor (as per the upsampling equation given here ). The upsampler inserts zeros between each modulated symbols. In practice, is chosen as integral multiples of 4. The upsampler/oversampled output is shown in Figure 3.

%Program: Upsampling
L=4; %Oversampling factor (L samples per symbol period)
v=[u;zeros(L-1,length(u))];%insert L-1 zero between each symbols
%Convert to a single stream
v=v(:).';%now the output is at sampling rate
stem(real(v)); title('Oversampled symbols v(n)');
Figure 3: Modulated symbols upsampled by 4 (left) and the SRRC pulse shaping filter output (right)

In order to fill-in proper values in place of the inserted zeros, interpolation is performed by a pulse shaping filter by convolving the output of the upsampler and the pulse shaping function. The pulse shaping function needs to satisfy Nyquist criterion for zero ISI, otherwise, aliasing effect will wreak havoc. If the amplitude response of the channel is flat and if the noise is white, then the amplitude response of the pulse shaping function can be split equally between the transmitter and receiver. For this simulation the desired Nyquist pulse shape is a raised-cosine pulse shape and the task of raised-cosine filtering is equally split between the transmit and receive filters. This gives rise to square-root raised-cosine (SRRC) filters at the transmitter and receiver. This is a matched filter system, where the receive filter is matched with the transmit pulse shaping filter.

A matched filtering system is a theoretical framework and it is not a specific type of filter. It offers improved noise cancellation by improving the signal noise ratio at the output of the receive filter. The implementation starts with the design of an SRRC filter with roll-off factor . The SRRC filter length is influenced by the parameter – the span of the filter length in units of symbols and the oversampling factor .

Filters will not produce instantaneous output and they take sometime to produce the output. That is, the output of the filter is shifted in time with respect to the input. For symmetric FIR filters of length , the filter delay is . Apart from returning the SRRC pulse function, the filter design function given in this section returns the filter delay. Filter delays are useful in determining the appropriate sampling instances at the receiver. The modulated symbols at the transmitter are passed through the designed filter and the response of the filter is plotted in Figure 3 (right).

%Program: SRRC pulse shaping
%----Pulse shaping-----
beta = 0.3;% roll-off factor for Tx SRRC filter
Nsym=8;%SRRC filter span in symbol durations
L=4; %Oversampling factor (L samples per symbol period)
[p,t,filtDelay] = srrcFunction(beta,L,Nsym);%design filter
s=conv(v,p,'full');%Convolve modulated syms with p[n] filter
figure; plot(real(s),'r'); title('Pulse shaped symbols s(n)');
Figure 4: Received signal with AWGN noise (left) and the output of the matched filter (right)

The pulse shaped signal samples are sent through an AWGN channel, where the transmitted samples are added with noise samples that are generated according to the required (refer AWGN noise model given in this post). The received signal that is corrupted with AWGN noise is shown in Figure 4 (left).

%Program: Adding AWGN noise for given SNR value
EbN0dB = 10; %EbN0 in dB for AWGN channel
snr = 10*log10(log2(M))+EbN0dB; %Converting given Eb/N0 dB to SNR
%log2(M) gives the number of bits in each modulated symbol
r = add_awgn_noise(s,snr,L); %AWGN , add noise for given SNR, r=s+w
%L is the oversampling factor used in simulation
figure; plot(real(r),'r');title('Received signal r(n)');

For the receiver system, we assume that the ADC in the receiver produces an integer number of samples per symbol (i.e, is an integer). In practice, this is not always the case and thus a resampling filter is often included in real world designs. In the discrete time model, the received samples are passed through a matched filter, whose impulse response is matched to the impulse response of the pulse shaping filter as . Since the SRRC pulse is symmetric, we will be using the same SRRC pulse shaping function for the matched filter. The received samples are convolved with the matched filter and the output of the matched filter is shown in Figure 4 (right).

Refer the book Wireless Communication Systems in Matlab for the program on how to perform matched filtering

Next, we assume that the receiver has perfect knowledge of symbol timing instants and therefore, we will not be implementing a symbol timing synchronization subsystem in the receiver. At the receiver, the matched filter symbols are first passed through a downsampler that samples the filter output at correct timing instances.

The sampling instances are influenced by the delay of the FIR filters (SRRC filters in Tx and Rx). For symmetric FIR filters of length , the filter delay is . Since the communication link contains two filters, the total filter delay is . Therefore, the first valid sample occurs at position in the matched filter’s output vector ( is added due to the fact that Matlab array indices starts from 1). The downsampler that follows, starts to sample the signal from this position and returns every symbol. The downsampled output, shown in Figure 5, is then passed through a demodulator that decides on the symbols using an optimum detection technique and remaps them back to the intended message symbols.

Figure 5: Downsampling – output of symbol rate sampler
%Program: Symbol rate sampler and demodulation
%------Symbol rate Sampler-----
uCap = vCap(2*filtDelay+1:L:end-(2*filtDelay))/L;
%downsample by L from 2*filtdelay+1 position result by normalized L,
%as the matched filter result is scaled by L
figure; stem(real(uCap)); hold on;
title('After symbol rate sampler $\hat{u}$(n)',...
'Interpreter','Latex');
dCap = demodulate(MOD_TYPE,M,uCap); %demodulation

Rate this article: Note: There is a rating embedded within this post, please visit this post to rate it.

Books by the author


Wireless Communication Systems in Matlab
Second Edition(PDF)

Note: There is a rating embedded within this post, please visit this post to rate it.
Checkout Added to cart

Digital Modulations using Python
(PDF ebook)

Note: There is a rating embedded within this post, please visit this post to rate it.
Checkout Added to cart

Digital Modulations using Matlab
(PDF ebook)

Note: There is a rating embedded within this post, please visit this post to rate it.
Checkout Added to cart
Hand-picked Best books on Communication Engineering
Best books on Signal Processing

Topics in this chapter

Pulse Shaping, Matched Filtering and Partial Response Signaling
● Introduction
● Nyquist Criterion for zero ISI
● Discrete-time model for a system with pulse shaping and matched filtering
 □ Rectangular pulse shaping
 □ Sinc pulse shaping
 □ Raised-cosine pulse shaping
 □ Square-root raised-cosine pulse shaping
● Eye Diagram
● Implementing a Matched Filter system with SRRC filtering
 □ Plotting the eye diagram
 □ Performance simulation
● Partial Response Signaling Models
 □ Impulse response and frequency response of PR signaling schemes
● Precoding
 □ Implementing a modulo-M precoder
 □ Simulation and results

Precoding for partial response signaling schemes

Introduction to precoding

Intersymbol interference (ISI) is a common problem in telecommunication systems, such as terrestrial television broadcasting, digital data communication systems, and cellular mobile communication systems. Dispersive effects in high-speed data transmission and multipath fading are the main reasons for ISI. To maximize the capacity, the transmission bandwidth must be extended to the entire usable bandwidth of the channel and that also leads to ISI.

To mitigate the effect of ISI, equalization techniques can be applied at the receiver side. Under the assumption of correct decisions, a zero-forcing decision feedback equalization (ZF-DFE) completely removes the ISI and leaves the white noise uncolored. It was also shown that ZF-DFE in combination with powerful coding techniques, allows transmission to approach the channel capacity [1]. DFE is adaptive and works well in the presence of spectral nulls and hence suitable for various PR channels that has spectral nulls. However, DFE suffers from error propagation and is not flexible enough to incorporate itself with powerful channel coding techniques such as trellis-coded modulation (TCM) and low-density parity codes (LDPC).

This article is part of the book Wireless Communication Systems in Matlab, ISBN: 978-1720114352 available in ebook (PDF) format (click here) and Paperback (hardcopy) format (click here).

These problems can be practically mitigated by employing precoding techniques at the transmitter side. Precoding eliminates error propagation effects at the source if the channel state information is known precisely at the transmitter. Additionally, precoding at transmitter allows coding techniques to be incorporated in the same way as for channels without ISI. In this text, a partial response (PR) signaling system is taken as an example to demonstrate the concept of precoding.

Precoding system using filters

In a PR signaling scheme, a filter is used at the transmitter to introduce a controlled amount of ISI into the signal. The introduced ISI can be compensated for, at the receiver by employing an inverse filter . In the case of PR1 signaling, the filters would be

Generally, the filter is chosen to be of FIR type and therefore its inverse at the receiver will be of IIR type. If the received signal is affected by noise, the usage of IIR filter at the receiver is prone to error propagation. Therefore, instead of compensating for the ISI at the receiver, a precoder can be implemented at the transmitter as shown in Figure 1.

Figure 1: A pre-equalization system incorporating a modulo-M precoder

Since the precoder is of IIR type, the output can become unbounded. For example, let’s filter a binary data sequence through the precoder used for PR1 signaling scheme .

% Matlab code snippet
>> d=[1,0,1,0,1,0,1,0,1,0]
>> filter(1,[1 1],d)
ans = 1  -1  2  -2  3  -3  4  -4  5  -5

The result indicates that the output becomes unbounded and some additional measure has to be taken to limit the output. Assuming M-ary signaling schemes like MPAM is used for transmission, the unbounded output of the precoder can be bounded by incorporating modulo-M operation.

Rate this article: Note: There is a rating embedded within this post, please visit this post to rate it.

Reference

[1] R. Price, Nonlinear Feedback Equalized PAM versus Capacity for Noisy Filter Channels, in Proceedings of the Int. Conference on Comm. (ICC ’72), 1972, pp. 22.12-22.17

Books by the author


Wireless Communication Systems in Matlab
Second Edition(PDF)

Note: There is a rating embedded within this post, please visit this post to rate it.
Checkout Added to cart

Digital Modulations using Python
(PDF ebook)

Note: There is a rating embedded within this post, please visit this post to rate it.
Checkout Added to cart

Digital Modulations using Matlab
(PDF ebook)

Note: There is a rating embedded within this post, please visit this post to rate it.
Checkout Added to cart
Hand-picked Best books on Communication Engineering
Best books on Signal Processing

Topics in this chapter

Pulse Shaping, Matched Filtering and Partial Response Signaling
● Introduction
● Nyquist Criterion for zero ISI
● Discrete-time model for a system with pulse shaping and matched filtering
 □ Rectangular pulse shaping
 □ Sinc pulse shaping
 □ Raised-cosine pulse shaping
 □ Square-root raised-cosine pulse shaping
● Eye Diagram
● Implementing a Matched Filter system with SRRC filtering
 □ Plotting the eye diagram
 □ Performance simulation
● Partial Response Signaling Models
 □ Impulse response and frequency response of PR signaling schemes
● Precoding
 □ Implementing a modulo-M precoder
 □ Simulation and results

Partial response schemes: impulse & frequency response

Impulse response and frequency response of PR signaling schemes

Consider a minimum bandwidth system in which the filter is represented as a cascaded combination of a partial response filter and a minimum bandwidth filter . Since is a brick-wall filter, the frequency response of the whole system is equivalent to frequency response of the FIR filter , whose transfer function, for various partial response schemes, was listed in Table 1 in the previous post (shown below).

Table 1: Partial response signaling schemes

The hand-crafted Matlab function (given in the book) generates the overall partial response signal for the given transfer function . The function records the impulse response of the filter by sending an impulse through it. These samples are computed at each symbol sampling instants. In order to visualize the pulse shaping functions and to compute the frequency response, the impulse response of are oversampled by a factor . This converts the samples from symbol rate domain to sampling rate domain. The oversampled impulse response of filter is convolved with a sinc filter that satisfies the Nyquist first criterion. This results in the overall response of the equivalent filter (refer Figure 2 in the previous post).

This article is part of the book Wireless Communication Systems in Matlab, ISBN: 978-1720114352 available in ebook (PDF) format (click here) and Paperback (hardcopy) format (click here).

The Matlab code to simulate both the impulse response and the frequency response of various PR signaling schemes, is given next (refer book for the Matlab code). The simulated results are plotted in the following Figure.

Figure: Impulse response and frequency response of various Partial response (PR) signaling schemes

Rate this post: Note: There is a rating embedded within this post, please visit this post to rate it.

Books by the author


Wireless Communication Systems in Matlab
Second Edition(PDF)

Note: There is a rating embedded within this post, please visit this post to rate it.
Checkout Added to cart

Digital Modulations using Python
(PDF ebook)

Note: There is a rating embedded within this post, please visit this post to rate it.
Checkout Added to cart

Digital Modulations using Matlab
(PDF ebook)

Note: There is a rating embedded within this post, please visit this post to rate it.
Checkout Added to cart
Hand-picked Best books on Communication Engineering
Best books on Signal Processing

Topics in this chapter

Pulse Shaping, Matched Filtering and Partial Response Signaling
● Introduction
● Nyquist Criterion for zero ISI
● Discrete-time model for a system with pulse shaping and matched filtering
 □ Rectangular pulse shaping
 □ Sinc pulse shaping
 □ Raised-cosine pulse shaping
 □ Square-root raised-cosine pulse shaping
● Eye Diagram
● Implementing a Matched Filter system with SRRC filtering
 □ Plotting the eye diagram
 □ Performance simulation
● Partial Response Signaling Models
 □ Impulse response and frequency response of PR signaling schemes
● Precoding
 □ Implementing a modulo-M precoder
 □ Simulation and results

Partial response (PR) signaling Model

Consider the generic baseband communication system model and its equivalent representation, shown in Figure 1, where the various blocks in the system are represented as filters. To have no ISI at the symbol sampling instants, the equivalent filter should satisfy Nyquist’s first criterion.

Figure 1: A generic communication system model and its equivalent representation

If the system is ideal and noiseless, it can be characterized by samples of the desired impulse response . Let’s represent all the non-zero sample values of the desired impulse response, taken at symbol sampling spacing , as , for .

This article is part of the book
Wireless Communication Systems in Matlab (second edition), ISBN: 979-8648350779 available in ebook (PDF) format and Paperback (hardcopy) format.

The partial response signaling model, illustrated in Figure 2, is expressed as a cascaded combination of a tapped delay line filter with tap coefficients set to and a filter with frequency response . The filter forces the desired sample values. On the other hand, the filter bandlimits the system response and at the same time it preserves the sample values from the filter . The choice of filter coefficients for the filter and the different choices for for satisfying Nyquist first criterion, result in different impulse response , but renders identical sample values in Figure 2 [1].

Figure 2: A generic partial response (PR) signaling model

To have a system with minimum possible bandwidth, the filter is chosen as

The inverse Fourier transform of results in a sinc pulse. The corresponding overall impulse response of the system is given by

If the bandwidth can be relaxed, other ISI free pulse-shapers like raised cosine can be considered for the filter.

Given the nature of real world channels, it is not always desirable to satisfy Nyquist’s first criterion. For example, the channel in magnetic recording, exhibits spectral null at certain frequencies and therefore it defines the channel’s upper frequency limit. In such cases, it is very difficult to satisfy Nyquist first criterion. An alternative viable solution is to allow a controlled amount of ISI between the adjacent samples at the output of the equivalent filter shown in Figure 2. This deliberate injection of controlled amount of ISI is called partial response (PR) signaling or correlative coding.

Partial Response Signaling Schemes

Several classes of PR signaling schemes and their corresponding transfer functions represented as (where is the delay operator) are shown in Table 1. The unit delay is equal to a delay of 1 symbol duration () in a continuous time system.

Rate this article: Note: There is a rating embedded within this post, please visit this post to rate it.

References

[1] Peter Kabal and Subbarayan Pasupathy, Partial-response signaling, IEEE Transactions on Communications, Vol. 23, No. 9, pp. 921-934, September 1975.↗

Topics in this chapter

Pulse Shaping, Matched Filtering and Partial Response Signaling
● Introduction
● Nyquist Criterion for zero ISI
● Discrete-time model for a system with pulse shaping and matched filtering
 □ Rectangular pulse shaping
 □ Sinc pulse shaping
 □ Raised-cosine pulse shaping
 □ Square-root raised-cosine pulse shaping
● Eye Diagram
● Implementing a Matched Filter system with SRRC filtering
 □ Plotting the eye diagram
 □ Performance simulation
● Partial Response Signaling Models
 □ Impulse response and frequency response of PR signaling schemes
● Precoding
 □ Implementing a modulo-M precoder
 □ Simulation and results

Books by the author


Wireless Communication Systems in Matlab
Second Edition(PDF)

Note: There is a rating embedded within this post, please visit this post to rate it.
Checkout Added to cart

Digital Modulations using Python
(PDF ebook)

Note: There is a rating embedded within this post, please visit this post to rate it.
Checkout Added to cart

Digital Modulations using Matlab
(PDF ebook)

Note: There is a rating embedded within this post, please visit this post to rate it.
Checkout Added to cart
Hand-picked Best books on Communication Engineering
Best books on Signal Processing

Correlative Coding – Modified Duobinary Signaling

Modified Duobinary Signaling is an extension of duobinary signaling. It has the advantage of zero PSD at low frequencies (especially at DC ) that is suitable for channels with poor DC response. It correlates two symbols that are 2T time instants apart, whereas in duobinary signaling, symbols that are 1T apart are correlated.

The general condition to achieve zero ISI is given by

As discussed in a previous article, in correlative coding , the requirement of zero ISI condition is relaxed as a controlled amount of ISI is introduced in the transmitted signal and is counteracted in the receiver side

In the case of modified duobinary signaling, the above equation is modified as

which states that the ISI is limited to two alternate samples. Here a controlled or “deterministic” amount of ISI is introduced and hence its effect can be removed upon signal detection at the receiver.

Modified Duobinary Signaling:

The following figure shows the modified duobinary signaling scheme (click to enlarge).

Modified DuoBinary Signaling

Encoding Process:

1) an = binary input bit; an ∈ {0,1}.
2) bn = NRZ polar output of Level converter in the precoder and is given by,

where ak is the precoded output (before level converter).

3) yn can be represented as

Note that the samples bn are uncorrelated ( i.e either +d for “1” or -d for “0” input). On the other-hand,the samples yn are correlated ( i.e. there are three possible values +2d,0,-2d depending on ak and ak-2). Meaning that the modified duobinary encoding correlates present sample ak and the previous input sample ak-2.

4) From the diagram,impulse response of the modified duobinary encoder is computed as

Decoding Process:

5) The receiver consists of a modified duobinary decoder and a postcoder (inverse of precoder). The decoder implements the following equation (which can be deduced from the equation given under step 3 (see above))

This equation indicates that the decoding process is prone to error propagation as the estimate of present sample relies on the estimate of previous sample. This error propagation is avoided by using a precoder before modified-duobinary encoder at the transmitter and a postcoder after the modified-duobinary decoder. The precoder ties the present sample and the sample that precedes the previous sample ( correlates these two samples) and the postcoder does the reverse process.

6) The entire process of modified-duobinary decoding and the postcoding can be combined together as one algorithm. The following decision rule is used for detecting the original modified-duobinary signal samples {an} from {yn}

Matlab code:

Check this book for full Matlab code.
Wireless Communication Systems in Matlab – by Mathuranathan Viswanathan

Simulation Results:

To know more on the simulation and results – visit this page – “Partial response signalling schemes – impulse and frequency responses”

Impulse response and frequency response of various Partial response (PR) signaling schemes

Rate this post: Note: There is a rating embedded within this post, please visit this post to rate it.

See also :

[1] Correlative Coding – Duobinary Signaling
[2] Introduction to Inter Symbol Interference

Recommended Books

Correlative coding – Duobinary Signaling

The condition for zero ISI (Inter Symbol Interference) is

which states that when sampling a particular symbol (at time instant nT=0), the effect of all other symbols on the current sampled symbol is zero.

As discussed in the previous article, one of the practical ways to mitigate ISI is to use partial response signaling technique ( otherwise called as “correlative coding”). In partial response signaling, the requirement of zero ISI condition is relaxed as a controlled amount of ISI is introduced in the transmitted signal and is counteracted in the receiver side.

By relaxing the zero ISI condition, the above equation can be modified as,

which states that the ISI is limited to two adjacent samples. Here we introduce a controlled or “deterministic” amount of ISI and hence its effect can be removed upon signal detection at the receiver.

Duobinary Signaling:

The following figure shows the duobinary signaling scheme.

Figure 1: DuoBinary signaling scheme

Encoding Process:

1) an = binary input bit; an ∈ {0,1}.
2) bn = NRZ polar output of Level converter in the precoder and is given by,

3) yn can be represented as

Note that the samples bn are uncorrelated ( i.e either +d for “1” or -d for “0” input). On the other-hand, the samples yn are correlated ( i.e. there are three possible values +2d,0,-2d depending on an and an-1). Meaning that the duobinary encoding correlates present sample an and the previous input sample an-1.

4) From the diagram,impulse response of the duobinary encoder is computed as

Decoding Process:

5) The receiver consists of a duobinary decoder and a postcoder (inverse of precoder).The duobinary decoder implements the following equation (which can be deduced from the equation given under step 3 (see above))

This equation indicates that the decoding process is prone to error propagation as the estimate of present sample relies on the estimate of previous sample. This error propagation is avoided by using a precoder before duobinary encoder at the transmitter and a postcoder after the duobinary decoder. The precoder ties the present sample and previous sample ( correlates these two samples) and the postcoder does the reverse process.

6) The entire process of duobinary decoding and the postcoding can be combined together as one algorithm. The following decision rule is used for detecting the original duobinary signal samples {an} from {yn}

Matlab Code:

Check this book for full Matlab code and simulation results.
Wireless Communication Systems in Matlab – by Mathuranathan Viswanathan

Simulation and results

To know more on the simulation and results – visit this page – “Partial response signalling schemes – impulse and frequency responses”

Impulse response and frequency response of various Partial response (PR) signaling schemes

Rate this article: Note: There is a rating embedded within this post, please visit this post to rate it.

See also :

[1] Correlative Coding – Modified Duobinary Signaling
[2] Derivation of expression for a Gaussian Filter with 3 dB bandwidth
[3] Nyquist and Shannon Theorem
[4] Correlative coding – Duobinary Signaling
[5] Square Root Raised Cosine Filter (Matched/split filter implementation)
[6] Introduction to Inter Symbol Interference

External Resources:

[1] The care and feeding of digital, pulse-shaping filters – By Ken Gentile↗
[2] Inter Symbol Interference and Root Raised Cosine Filtering – Complex2real↗