+ All Categories
Home > Documents > EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

Date post: 10-Apr-2015
Category:
Upload: donatello84
View: 87 times
Download: 2 times
Share this document with a friend
Description:
ANADOLU UNIVERSITY ENGINEERING AND ARCHITECTURE FACULTY ELECTRICAL AND ELECTRONICS ENGINEERING DEPARTMENT( SPRING – 2010 )EEM 496 COMMUNICATION SYSTEMS LABORATORYEXPERIMENT#3 WHITE GAUSSIAN NOISESTUDENTS : YASİN ÇIBUK 31732325994OSMAN GÜLERCAN 16169230356( 13.04.2009 )INTRODUCTIONIn this experiment, our aim is that to study the delta function in both time and frequency domains, to obtain the autocorrelation and power spectral density of MATLAB generated White Gaussian Noise (WGN),
37
ANADOLU UNIVERSITY ENGINEERING AND ARCHITECTURE FACULTY ELECTRICAL AND ELECTRONICS ENGINEERING DEPARTMENT ( SPRING – 2010 ) EEM 496 COMMUNICATION SYSTEMS LABORATORY EXPERIMENT#3 WHITE GAUSSIAN NOISE STUDENTS : YASİN ÇIBUK 31732325994 OSMAN GÜLERCAN 16169230356
Transcript
Page 1: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

ANADOLU UNIVERSITY

ENGINEERING AND ARCHITECTURE FACULTY

ELECTRICAL AND ELECTRONICS ENGINEERING

DEPARTMENT

( SPRING – 2010 )

EEM 496

COMMUNICATION SYSTEMS LABORATORY

EXPERIMENT#3 WHITE GAUSSIAN NOISE

STUDENTS : YASİN ÇIBUK 31732325994

OSMAN GÜLERCAN 16169230356

( 13.04.2009 )

Page 2: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

INTRODUCTION

In this experiment, our aim is that to study the delta function in both time and frequency domains, to obtain the autocorrelation and power spectral density of MATLAB generated White Gaussian Noise (WGN), to obtain the pdf of WGN, to download MATLAB generated WGN into the Agilent E4438C vector signal generator .

MAIN TEXTFirstly, we generated WGN with using MATLAB and downloaded it to into the Agilent E4438C vector signal generator . For different values of ‘n’ and ‘var’ we measured power spectral density, chanel power, occopied BW, rms value as shown below table. In addition, we saw the the autocorrelation, power spectrum, time variation of WGN.

signal POWER SPECTRAL DENSITY(dBm/Hz)

CHANEL POWER(dBm/MHz)

OCCUPIED BW(MHz)

RMS VALUE(mV)

n=10^2, var=-20 -83.35 -20.360 2.0682 349.5n=10^3, var=-20 -80.56 -17.57 2.2927 289.3n=10^4, var=-20 -81.56 -18.90 2.95 232.5n=10^5, var=-20 -81.5 -19.50 2.95 211.3n=10^6, var=-20 -82.5 -19.90 2.97 216.3n=10^2, var=-15 -85.03 -22.00 2.066 338.1n=10^3, var=-15 -79.1 -16.08 2.96 292.7n=10^4, var=-15 -81.5 -18.50 2.95 238.8n=10^5, var=-15 -81.9 -19.50 2.98 248.5n=10^6, var=-15 -83.7 -20.20 2.95 202.5n=10^2, var=-10 -82.4 -19.35 2.068 386.9n=10^3, var=-10 -81.54 -18.53 2.9943 237.6n=10^4, var=-10 -81.54 -18.54 2.9525 266.1n=10^5, var=-10 -82.54 -19.97 2.9613 228.2n=10^6, var=-10 -83.73 -20.82 2.97 202.6n=10^2, var=-5 -79.98 -16.98 2.0687 352.1n=10^3, var=-5 -79.86 -16.85 2.9915 314.1n=10^4, var=-5 -81.74 -18.71 2.9470 245n=10^5, var=-5 -82.82 -19.90 2.9673 191.5n=10^6, var=-5 -83.92 -20.32 2.9443 177.1n=10^2, var=0 -84.88 -21.85 2.0659 446.9n=10^3, var=0 -79.48 -16.46 2.9638 466n=10^4, var=0 -81.73 -18.79 2.93 248.4n=10^5, var=0 -81.17 -18.82 2.95 241.8n=10^6, var=0 -82.22 -19.73 2.9506 216.7n=10^2, var=-15attenuation= 20dB

-68.94 -5.9 2.04

n=10^6, var=-15attenuation= 20dB

-68.77 -5.82 2.0105

Page 3: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

For the same delta funtion but, for different values ‘n’ and ’var’ we can see the Picture of ‘delta function’, ‘fourier transform of delta funtion’, ‘autocorrelation of WGN’ , power spectrum of WGN, ‘time variation of WGN’.

For the n=100 , variance =0 dB

0 200 400 600 800 10000

0.5

1

t (Time)

Am

plit

ud

e

Delta Function

0 100 200 300 400 5000

0.5

1

f (Frequency)

Am

plit

ud

e

Fourier Transform of Delta Function

-1000 -500 0 500 1000-1

0

1

(Time)

No

rma

lize

d A

mp

litu

de Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

Page 4: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

0 20 40 60 80 100-5

0

5

t (Time)

Am

plit

ud

e

Time Variation of White Gaussian Noise

-3 -2 -1 0 1 2 30

0.05

0.1

Amplitude

No

ise

pd

f

Page 5: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

For n=100 , var=-5

-1000 -500 0 500 1000-2

0

2

(Time)

No

rma

lize

d A

mp

litu

de Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

0 20 40 60 80 100-2

0

2

t (Time)

Am

plit

ud

e

Time Variation of White Gaussian Noise

-2 -1 0 1 20

0.05

0.1

Amplitude

No

ise

pd

f

Page 6: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

For n=100 , var=-10

-1000 -500 0 500 1000-1

0

1

(Time)

No

rma

lize

d A

mp

litu

de Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

Page 7: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

0 20 40 60 80 100-1

0

1

t (Time)

Am

plit

ud

e

Time Variation of White Gaussian Noise

-1 -0.5 0 0.5 10

0.05

0.1

Amplitude

No

ise

pd

f

For n=100 , var=-15

Page 8: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

-1000 -500 0 500 1000-1

0

1

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

0 20 40 60 80 100-1

0

1

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-0.4 -0.2 0 0.2 0.4 0.60

0.05

0.1

Amplitude

No

ise

pd

f

Page 9: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

For n=100 , var=-20

-1000 -500 0 500 1000-2

0

2

(Time)

No

rm

alize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rm

alize

d P

ow

er D

en

sit

y

Power Spectrum of WGN

0 20 40 60 80 100-0.5

0

0.5

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-0.4 -0.2 0 0.2 0.40

0.05

0.1

Amplitude

No

ise

pd

f

Page 10: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

For n=1000 , var=0

0 200 400 600 800 10000

0.5

1

t (Time)

Am

plitu

de

Delta Function

0 100 200 300 400 5000

0.5

1

f (Frequency)

Am

plitu

de

Fourier Transform of Delta Function

-1000 -500 0 500 1000-2

0

2

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

Page 11: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

0 200 400 600 800 1000-5

0

5

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-3 -2 -1 0 1 2 30

0.05

Amplitude

No

ise

pd

f

For n=1000 , var=-5

-1000 -500 0 500 1000-2

0

2

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

Page 12: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

0 200 400 600 800 1000-2

0

2

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-2 -1 0 1 20

0.05

0.1

Amplitude

No

ise

pd

f

For n=1000 , var=-10

-1000 -500 0 500 1000-2

0

2

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

Page 13: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

0 200 400 600 800 1000-2

0

2

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-1 -0.5 0 0.5 1 1.50

0.05

0.1

Amplitude

No

ise

pd

f

For n=1000 , var=-15

-1000 -500 0 500 1000-2

0

2

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

Page 14: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

0 200 400 600 800 1000-1

0

1

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-1 -0.5 0 0.5 10

0.05

0.1

Amplitude

No

ise

pd

f

For n=1000 , var=-20

-1000 -500 0 500 1000-2

0

2

(Time)

No

rm

alize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rm

alize

d P

ow

er D

en

sit

y

Power Spectrum of WGN

Page 15: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

0 200 400 600 800 1000-0.5

0

0.5

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-0.4 -0.2 0 0.2 0.40

0.05

0.1

Amplitude

No

ise

pd

f

For n=10^4 , variance=0

0 200 400 600 800 10000

0.5

1

t (Time)

Am

plitu

de Delta Function

0 100 200 300 400 5000

0.5

1

f (Frequency)

Am

plitu

de Fourier Transform of Delta Function

Page 16: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

-1000 -500 0 500 1000-2

0

2

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

0 2000 4000 6000 8000 10000-5

0

5

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-6 -4 -2 0 2 40

0.05

0.1

Amplitude

No

ise

pd

f

Page 17: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

For n=10^4 , variance=-5

-1000 -500 0 500 1000-1

0

1

(Time)

No

rm

alize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rm

alize

d P

ow

er D

en

sit

y

Power Spectrum of WGN

0 2000 4000 6000 8000 10000-5

0

5

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-3 -2 -1 0 1 2 30

0.05

0.1

Amplitude

No

ise

pd

f

Page 18: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

For n=10^4 , variance=-10

-1000 -500 0 500 1000-2

0

2

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

0 2000 4000 6000 8000 10000-2

0

2

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-1.5 -1 -0.5 0 0.5 1 1.50

0.05

0.1

Amplitude

No

ise

pd

f

Page 19: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

For n=10^4 , variance=-15

-1000 -500 0 500 1000-2

0

2

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

0 2000 4000 6000 8000 10000-1

0

1

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-1 -0.5 0 0.5 10

0.05

0.1

Amplitude

No

ise

pd

f

Page 20: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

For n=10^4 , variance=-20

-1000 -500 0 500 1000-1

0

1

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

0 2000 4000 6000 8000 10000-0.5

0

0.5

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-0.5 0 0.50

0.05

0.1

Amplitude

No

ise

pd

f

Page 21: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

For n=10^5 , variance=0

0 200 400 600 800 10000

0.5

1

t (Time)

Am

plitu

de

Delta Function

0 100 200 300 400 5000

0.5

1

f (Frequency)

Am

plitu

de

Fourier Transform of Delta Function

-1000 -500 0 500 1000-1

0

1

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

0 2 4 6 8 10

x 104

-5

0

5

t (Time)

Am

plitu

de Time Variation of White Gaussian Noise

-5 0 50

0.05

0.1

Amplitude

No

ise

pd

f

Page 22: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

For n=10^5 , variance=-5

-1000 -500 0 500 1000-2

0

2

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

0 2 4 6 8 10

x 104

-5

0

5

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-3 -2 -1 0 1 2 30

0.05

0.1

Amplitude

No

ise

pd

f

Page 23: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

For n=10^5 , variance=-10

-1000 -500 0 500 1000-2

0

2

(Time)

No

rm

alize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rm

alize

d P

ow

er D

en

sit

y

Power Spectrum of WGN

0 2 4 6 8 10

x 104

-2

0

2

t (Time)

Am

plit

ud

e

Time Variation of White Gaussian Noise

-1.5 -1 -0.5 0 0.5 1 1.50

0.05

0.1

Amplitude

No

ise

pd

f

Page 24: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

for n=10^5 , variance=-15

-1000 -500 0 500 1000-2

0

2

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

0 2 4 6 8 10

x 104

-1

0

1

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-1 -0.5 0 0.5 10

0.05

0.1

Amplitude

No

ise

pd

f

Page 25: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

For n=10^5 , variance=-20

-1000 -500 0 500 1000-1

0

1

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

0 2 4 6 8 10

x 104

-0.5

0

0.5

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-0.5 0 0.50

0.05

0.1

Amplitude

No

ise

pd

f

Page 26: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

For n=10^6 , variance=0

0 200 400 600 800 10000

0.5

1

t (Time)

Am

plitu

de

Delta Function

0 100 200 300 400 5000

0.5

1

f (Frequency)

Am

plitu

de

Fourier Transform of Delta Function

-1000 -500 0 500 1000-1

0

1

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

Page 27: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

0 2 4 6 8 10

x 105

-10

0

10

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-6 -4 -2 0 2 4 60

0.05

0.1

Amplitude

No

ise

pd

f

For n=10^5 , variance=-5

-1000 -500 0 500 1000-2

0

2

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

Page 28: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

0 2 4 6 8 10

x 105

-5

0

5

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-4 -2 0 2 40

0.05

0.1

Amplitude

No

ise

pd

f

For n=10^5 , variance=-10

-1000 -500 0 500 1000-1

0

1

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

Page 29: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

0 2 4 6 8 10

x 105

-2

0

2

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-2 -1 0 1 20

0.05

0.1

Amplitude

No

ise

pd

f

For n=10^5 , variance=-15

-1000 -500 0 500 1000-1

0

1

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

Page 30: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

0 2 4 6 8 10

x 105

-1

0

1

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-1 -0.5 0 0.5 10

0.05

0.1

Amplitude

No

ise

pd

f

For n=10^5 , variance=-20

-1000 -500 0 500 1000-2

0

2

(Time)

No

rma

lize

d A

mp

litu

de

Autocorrelation of WGN

-1000 -500 0 500 10000

2

4

f (Frequency)No

rma

lize

d P

ow

er

De

ns

ity

Power Spectrum of WGN

Page 31: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

0 2 4 6 8 10

x 105

-0.5

0

0.5

t (Time)

Am

plitu

de

Time Variation of White Gaussian Noise

-0.5 0 0.50

0.05

0.1

Amplitude

No

ise

pd

f

Page 32: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

MATLAB CODE

% This program attempts to verify that the frequency spectrum of White Gaussian Noise is white (i.e. flat) % First, study the delta function. This is one and a (large) number of zeros close all; clear all; clc; clf n = 1000; xt_delta = [ones(1,1) zeros(1,n)]; figure(1) subplot(2,1,1); plot(1:length(xt_delta),xt_delta,'LineWidth',4,'Color','green') xlabel('t (Time)','FontSize',12,'FontWeight','bold'); ylabel('Amplitude','FontSize',12,'FontWeight','bold'); title('Delta Function','FontSize',12,'FontWeight','bold') axis ([-15 n 0 1.1]); set(gcf,'Color',[1 1 1]); set(gca,'FontSize',16); Xf_delta = fft(xt_delta,512); Power_Xf = Xf_delta.* conj(Xf_delta) / 512; Power_Xf = Power_Xf / max(Power_Xf); f = 1000*(0:256)/512; subplot(2,1,2); plot(f,Power_Xf(1:257),'LineWidth',4,'Color','Red'); axis ([-(max(f)-min(f))*0.05 max(f)*1.1 0 1.1]); xlabel('f (Frequency)','FontSize',12,'FontWeight','bold'); ylabel('Amplitude','FontSize',12,'FontWeight','bold'); title('Fourier Transform of Delta Function','FontSize',12,'FontWeight','bold') set(gcf,'Color',[1 1 1]); set(gca,'FontSize',16); % Whiteness of White Gaussian Noise % As n (number of noise samples) and no_run are increased, uniformity increases n = 1000; m = 1000; no_run = 100; % m should be the same as n, otherwise correlation deviates towards the edges rn_tot=zeros(1,2*m-1); for j=1:no_run, noise = wgn(1,n,0.01); rn = xcorr(noise,m-1,'unbiased'); rn_tot = rn_tot + rn; end; rn_tot = rn_tot/no_run; figure(2) subplot(2,1,1); plot(-m+1:m-1,rn_tot) xlabel('\tau (Time)','FontSize',12,'FontWeight','bold'); ylabel('Normalized Amplitude','FontSize',12,'FontWeight','bold'); title('Autocorrelation of WGN','FontSize',12,'FontWeight','bold') set(gcf,'Color',[1 1 1]); set(gca,'FontSize',16); noise_spect = fftshift(abs(fft(rn_tot))); subplot(2,1,2); plot(-m+1:m-1,noise_spect); xlabel('f (Frequency)','FontSize',12,'FontWeight','bold'); ylabel('Normalized Power Density','FontSize',12,'FontWeight','bold'); title('Power Spectrum of WGN','FontSize',12,'FontWeight','bold'); set(gcf,'Color',[1 1 1]); set(gca,'FontSize',16);

% The pdf of White Gaussian Noise% n is the number of noise samples and var (variance) is the noise power in dBWn = 1000000; var = -10; noise = wgn(1,n,var); figure(3)subplot(2,1,1); plot(1:n,noise);xlabel('t (Time)','FontSize',12,'FontWeight','bold');ylabel('Amplitude','FontSize',12,'FontWeight','bold');title('Time Variation of White Gaussian Noise','FontSize',12,'FontWeight','bold');set(gcf,'Color',[1 1 1]); set(gca,'FontSize',16);[nn,xout] = hist(noise,50);subplot(2,1,2); bar(xout,nn/n);xlabel('Amplitude','FontSize',12,'FontWeight','bold');ylabel('Noise pdf','FontSize',12,'FontWeight','bold');set(gcf,'Color',[1 1 1]); set(gca,'FontSize',16);

% Constructing the noise waveform to be loaded into ESG 4438C vector signal generator% Note that both I and Q are identical in this casewaveform(1:2:2*length(noise)) = noise;waveform(2:2:2*length(noise)) = noise;

Page 33: EEM496 Communication Systems Laboratory - Report3 - White Gaussian Noise

waveform = waveform / max(abs(waveform));waveform = round(32767*waveform);waveform = uint16(mod(65536 + waveform,65536));if strcmp( computer, 'PCWIN' )waveform = bitor(bitshift(waveform,-8),bitshift(waveform,8));endfilename = 'C:\MATLAB7\work\noise_waveform';[FID, message] = fopen(filename,'w'); % Open a file to write dataif FID == -1 error('Cannot Open File'); endfwrite(FID,waveform,'unsigned short'); % write to the filefclose(FID);

Yasin’s CONCLUSION

In this experiment, firstly, we learned the changing of occupied BW, rms value, power

spectral density, chanel power according to ‘n’ that if the value of ‘n’ increases when the

variance is constant, the rms value decreases. The relation between occupied BW and ‘n’ is

that when the ‘n’ increases, occupied BW increases. Next, we learned the changing of

occupied BW, rms value, power spectral density, chanel power according to ‘variance’. If the

variance increases, the power spectral density and chanel power increase. But ,the rms value

decreases and the occupied BW does not change. After that, we saw that if the variance

decrease or increase how to change the time variation of WGN according to variance. Finally,

we learned the affect of ‘n’ and ‘variance’ to autocorrelation.

Osman’s CONCLUSION

In his laboratory, we studied delta function both time and frequency domains, the

autocorrelation and power spectral density of MATLAB generated White Gaussian Noise (WGN)

and also the pdf of WGN. First, we changed the value of ‘n’ from 100 to 10^6 that if the ‘n’

increased, the rms value decreased and BW also increased. Second, we changed the variable ‘var’

from -20 to 0 by 5 step, and we learned that if the variance is increased, the channel power and the

power spectral density increase too. Finally, we have uploaded all of these Matlab files to the

Agilent E4438C vector signal generator by using FTP. Then we showed and saved all signals both

in time and frequency domains. To sum up; we learned the change of occupied BW, rms value,

autocorrelation and power spectral density of the WGN and its pdf according to ‘n’ and ‘var’.


Recommended