# Modelling a Noisy Communication Signal in MATLAB for the Analog to Digital Conversion Process

A critical thing to realize while modeling the signal that is going to be digitally processed is the SNR. In a receiver, the noise floor (hence the noise variance and hence its power) are determined by the temperature and the Bandwidth. For a system with a constant bandwidth, relatively constant temperature, the noise power remains relatively constant as well. This implies that the noise variance is a constant.

In MATLAB, the easiest way to create a noisy signal is by using awgn(sig,SNR,'measured'). Or, this has been the method that I have used extensively to generate a noisy signal. Earlier, I failed to realize that this was not correctly modeling the signal that I wanted to process. Using awgn will produce noise after measuring the signal power.

Let me explain with an example. Say that we have generated a signal in MATLAB with variance of 0.5. Suppose we wanted SNR of 0dB, in MATLAB we would simply have y = awgn(sig,0,'measured').

If we measured the var(sig-y) we would end up with an answer of 0.5.

Let us follow the rest of the explanation in the pdf attached

The following short MATLAB script generates the noisy signal:

% Inputs: SNR Value, the Variance of the Noise of the reciever and the

% original sig

% Outputs: The noisy signal and the noise with the required noise variance

function [sign, noise] = sig_model(SNR, noise_var, sig)

sig_std = std(sig);

y = sqrt(noise_var)*sqrt(10^(SNR/10))*sig/sig_std;

sig_variance = var(sig)

scaled_signal_variance = var(y)

sign = awgn(y,SNR,'measured');

noise = sign-y;

noise_variance = var(noise)

Above script will generate the model of the analog signal that will hit the front end of the ADC. In the next blog, I will investigate the effects of the ADC process on this noisy signal.

**Previous post by Parth Vakil:**

Hello and Introduction

**Next post by Parth Vakil:**

Instantaneous Frequency Measurement

## Comments:

- Comments
- Write a Comment Select to add a comment

Look for Guassian Distribution and related stuff. As u r doing MSEE, for Communication there is a prereq. "Random Variables and Stochastic Processes" , that deals with all ur questions, mean, variance, etc.

What u said is true if a signal is distorted by Guassian noise, that is usually the case and a presumption in your case

To post reply to a comment, click on the 'reply' button attached to each comment. To post a new comment (not a reply to a comment) check out the 'Write a Comment' tab at the top of the comments.

Registering will allow you to participate to the forums on ALL the related sites and give you access to all pdf downloads.