0% found this document useful (0 votes)
392 views

360 Matlab Projects

This document outlines 26 Matlab projects involving the generation of random samples and plotting of probability mass functions (PMFs) and cumulative distribution functions (CDFs) for various discrete and continuous random variables. The projects include generating samples from distributions with given PMFs and CDFs, common distributions like binomial and geometric, combinations of random variables, and a communication system simulation. It also includes a coupon collector problem simulation.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
392 views

360 Matlab Projects

This document outlines 26 Matlab projects involving the generation of random samples and plotting of probability mass functions (PMFs) and cumulative distribution functions (CDFs) for various discrete and continuous random variables. The projects include generating samples from distributions with given PMFs and CDFs, common distributions like binomial and geometric, combinations of random variables, and a communication system simulation. It also includes a coupon collector problem simulation.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Department of Electrical Engineering

EE 360 S2 2013/2014 Random Signal Analysis


Matlab Projects
Mohammad M. Banat


JUST

1. Generate 10,000 sample of the discrete random variable specified by the following PMF,
andsketchitstheoreticalandexperimentalPMFandCDF:
0.02, 35 50
( ) 0.024, 50 75
0.004, 75 100
X
X
P x X
X
s <

= s <

s <


2. Generate 10,000 samples of the discrete random variable specified by the following CDF,
andsketchitstheoreticalandexperimentalPMFandCDF:
2
0, 0
( ) , 1 10
100
1, 10
X
X
x
F x X
X
s

= s s

>

3. Generate 10,000 samples of a binomial random variable, and sketch its theoretical and
experimentalPMFandCDF.Assume 0.35 p = and 10 n = .
4. Generate 10,000 samples of a geometric random variable, and sketch its theoretical and
experimentalPMFandCDF.Assume 0.6 p = .
5. Let X beaBernoullirandomvariablewiththesamplespace { } 0,1 ,andwith Pr(0) 0.42 = .
Let Y be a random variable representing the number of Bernoulli trials before a 101
patternisreceived.Generate10,000samplesof Y andusethegeneratedsamplestosketch
itsPMFandCDF.
6. A continuous random variable has the PDF ( ) ( )
x
X
f x e u x

= . Determine, theoretically,the
first6intervals,eachhavingaprobabilityof0.15.Assigntheremainingvaluestoaseventh
interval with a probability 0.1. Generate 10,000 samples of a discrete random variable Y
whosevaluesarethestartingpointsoftheintervalsabove,andwhosePMFisgivenbythe
intervalprobabilities.SketchthePMFandCDFof Y .


Department of Electrical Engineering

EE 360 S2 2013/2014 Random Signal Analysis
Matlab Projects
Mohammad M. Banat


JUST

Considerthefollowingthreediscreterandomvariableswithequallylikelyoutcomes:
1
2
3
4 12
10 10
0 8
X
X
X
s s
s s
s s

Use the information above to generate 10,000 samples and sketch the PMFs and CDFs of the
randomvariablesinquestions711.
7.
1 2 3
3
X X X
Y
+ +
= .
8.
1 2
3
2
X X
Y
X
=
+
.
9.
1 2 3
largest of , , Y X X X = .
10.
1 2 3
Smallest of , , Y X X X = .
11.
1 2 3
1,
0, otherwise
X X X
Y
< <
=

.
Consider the two uniformly distributed continuous random variables,
1
0 1 X s < and
2
0 3 X s s . Use the information above to generate 10,000 samples and sketch the PDFs and
CDFsoftherandomvariablesinquestions1216.
12.
1 2
Y X X = + .
13.
1
X
Y e = .
14.
2 1
Y X X = .
15.
2
1
0.5 Y X = .
16.
1 2 1
2 1
0.1, 2
0.5, 2
0, otherwise
X X X
Y X X
< <

= >

.


Department of Electrical Engineering

EE 360 S2 2013/2014 Random Signal Analysis
Matlab Projects
Mohammad M. Banat


JUST

In a digital communication system, the signaltonoise ratio falls in the range 0 10 s s . Let
data be transmitted in blocks of 4 bits (zeros and ones) each. Let the probabilities of
transmitting a one or a zero be equal. Let the receiver make a bit error with a probability
1
2
e
P

=
+
. Generate 100,000 block transmissions, then sketch the probabilities in questions
1724asfunctionof .Youcanusethefollowingvaluesof :0,3,5,8,10.
17. Pr(two consecutive bit errors in the same block) .
18. Pr(at least one bit error in a block) .
19. Pr(no more than one bit error in a block) .
20. Pr(exactly two bit errors in a block) .
21. Pr(error-free block) .
22. Pr(decimal equivalent of a block increases) .
23. Pr(decimal equivalent of a block decreases) .
24. Pr(at least one bit error in the first two bits of a block) .
CouponCollectorProblem:
AreaderfindsatrandomacouponoftypeA,BorCwitheverybookhebuysfromabookstore.
Let the random variable X represent the number of books the reader should buy in order to
collectatleastonecouponofeachtypeforthefirsttime.
25. Generate10,000samplesof X ,andsketchthePMFandCDFof X .

You might also like