+ All Categories
Home > Documents > Random Variables

Random Variables

Date post: 20-Jan-2016
Category:
Upload: daphne
View: 51 times
Download: 0 times
Share this document with a friend
Description:
Random Variables. 2.1 Discrete Random Variables 2.2 The Expectation of a Random Variable 2.3 The Variance of a Random Variable 2.4 Jointly Distributed Random Variables 2.5 Combinations and Functions of Random Variables. Random Variables. - PowerPoint PPT Presentation
Popular Tags:
32
Random Variables 2.1 Discrete Random Variables 2.2 The Expectation of a Random Variable 2.3 The Variance of a Random Variable 2.4 Jointly Distributed Random Variables 2.5 Combinations and Functions of Random Variables
Transcript
Page 1: Random Variables

Random Variables

2.1 Discrete Random Variables2.2 The Expectation of a Random Variable2.3 The Variance of a Random Variable2.4 Jointly Distributed Random Variables2.5 Combinations and Functions of Random Variables

Page 2: Random Variables

Random Variables

• Random Variable (RV): A numeric outcome that results from an experiment

• For each element of an experiment’s sample space, the random variable can take on exactly one value

• Discrete Random Variable: An RV that can take on only a finite or countably infinite set of outcomes

• Continuous Random Variable: An RV that can take on any value along a continuum (but may be reported “discretely”

• Random Variables are denoted by upper case letters (Y)

• Individual outcomes for RV are denoted by lower case letters (y)

Page 3: Random Variables

Probability Distributions

• Probability Distribution: Table, Graph, or Formula that describes values a random variable can take on, and its corresponding probability (discrete RV) or density (continuous RV)

• Discrete Probability Distribution: Assigns probabilities (masses) to the individual outcomes

• Continuous Probability Distribution: Assigns density at individual points, probability of ranges can be obtained by integrating density function

• Discrete Probabilities denoted by: p(y) = P(Y=y)• Continuous Densities denoted by: f(y)• Cumulative Distribution Function: F(y) = P(Y≤y)

Page 4: Random Variables

Discrete Probability Distributions

yyF

FF

ypbYPbF

yYPyF

yp

yyp

yYPyp

b

y

y

in increasinglly monotonica is )(

1)(0)(

)()()(

)()(

:(CDF)Function on Distributi Cumulative

1)(

0)(

)()(

:Function (Mass)y Probabilit

all

Page 5: Random Variables

Example – Rolling 2 Dice (Red/Green)

Red\Green 1 2 3 4 5 6

1 2 3 4 5 6 72 3 4 5 6 7 83 4 5 6 7 8 94 5 6 7 8 9 105 6 7 8 9 10 116 7 8 9 10 11 12

Y = Sum of the up faces of the two die. Table gives value of y for all elements in S

Page 6: Random Variables

Rolling 2 Dice – Probability Mass Function & CDF

y p(y) F(y)

2 1/36 1/36

3 2/36 3/36

4 3/36 6/36

5 4/36 10/36

6 5/36 15/36

7 6/36 21/36

8 5/36 26/36

9 4/36 30/36

10 3/36 33/36

11 2/36 35/36

12 1/36 36/36

y

t

tpyF

yyp

2

)()(

inresult can die 2 waysof #

tosumcan die 2 waysof #)(

Page 7: Random Variables

Rolling 2 Dice – Probability Mass Function

Dice Rolling Probability Function

0

0.02

0.04

0.06

0.08

0.1

0.12

0.14

0.16

0.18

2 3 4 5 6 7 8 9 10 11 12

y

p(y

)

Page 8: Random Variables

Rolling 2 Dice – Cumulative Distribution Function

Dice Rolling - CDF

0

0.1

0.2

0.3

0.4

0.5

0.6

0.7

0.8

0.9

1

1 2 3 4 5 6 7 8 9 10 11 12 13

y

F(y

)

Page 9: Random Variables

Expected Values of Discrete RV’s

• Mean (aka Expected Value) – Long-Run average value an RV (or function of RV) will take on

• Variance – Average squared deviation between a realization of an RV (or function of RV) and its mean

• Standard Deviation – Positive Square Root of Variance (in same units as the data)

• Notation:– Mean: E(Y) = – Variance: V(Y) = 2

– Standard Deviation:

Page 10: Random Variables

Expected Values of Discrete RV’s

2

2222

all

2

all all

2

all

22

all

2

222

all

all

:Deviation Standard

)1()(2

)()(2)(

)(2)()(

)())(()( :Variance

)()()( :)(function a ofMean

)()( :Mean

YEYE

ypyypypy

ypyyypy

YEYEYEYV

ypygYgEYg

yypYE

yyy

yy

y

y

Page 11: Random Variables

Expected Values of Linear Functions of Discrete RV’s

a

aypya

ypyaypaay

ypbabaybaYV

baypbyypa

ypbaybaYE

babaYYg

baY

y

yy

y

yy

y

22

all

22

all

22

all

2

all

2

all all

all

)()(

)()(

)()()(][

)()(

)()(][

)constants ,()( :FunctionsLinear

Page 12: Random Variables

Example – Rolling 2 Dice

y p(y) yp(y) y2p(y)

2 1/36 2/36 4/36

3 2/36 6/36 18/36

4 3/36 12/36 48/36

5 4/36 20/36 100/36

6 5/36 30/36 180/36

7 6/36 42/36 294/36

8 5/36 40/36 320/36

9 4/36 36/36 324/36

10 3/36 30/36 300/36

11 2/36 22/36 242/36

12 1/36 12/36 144/36

Sum 36/36=1.00

252/36=7.00

1974/36=54.833

4152.28333.5

8333.5)0.7(8333.54

)(

0.7)()(

2

212

2

2222

12

2

y

y

ypyYE

yypYE

Page 13: Random Variables

2.1 Discrete Random VariableDefinition of a Random Variable (1/2)

• Random variable – A numerical value to each outcome of a particular

experiment

S

0 21 3-1-2-3

R

Page 14: Random Variables

Definition of a Random Variable (2/2)

• Example 1 : Machine Breakdowns– Sample space : – Each of these failures may be associated with a repair

cost– State space : – Cost is a random variable : 50, 200, and 350

{ , , }S electrical mechanical misuse

{50,200,350}

Page 15: Random Variables

Probability Mass Function (1/2)

• Probability Mass Function (p.m.f.)– A set of probability value assigned to each of the

values taken by the discrete random variable– and – Probability :

ip

ix

0 1ip 1iip

( )i iP X x p

Page 16: Random Variables

Probability Mass Function (1/2)

• Example 1 : Machine Breakdowns– P (cost=50)=0.3, P (cost=200)=0.2,

P (cost=350)=0.5– 0.3 + 0.2 + 0.5 =1 50 200 350

0.3 0.2 0.5

ix

ip( )f x

0.5

0.3

50 200 350 Cost($)

0.2

Page 17: Random Variables

Cumulative Distribution Function (1/2)

• Cumulative Distribution Function– Function : – Abbreviation : c.d.f

( ) ( )F x P X x :

( ) ( )y y x

F x P X y

( )F x1.0

0.5

0.3

50 200 3500 ($cost)x

Page 18: Random Variables

Cumulative Distribution Function (2/2)

• Example 1 : Machine Breakdowns

50 ( ) (cost ) 0

50 200 ( ) (cost ) 0.3

200 350 ( ) (cost ) 0.3 0.2 0.5

350 ( ) (cost ) 0.3 0.2 0.5 1.0

x F x P x

x F x P x

x F x P x

x F x P x

Page 19: Random Variables

Cumulative Distribution Function (1/3)

• Cumulative Distribution Function

( ) ( ) ( )

( )( )

xF x P X x f y dy

dF xf x

dx

( ) ( ) ( )

( ) ( )

( ) ( )

P a X b P X b P X a

F b F a

P a X b P a X b

Page 20: Random Variables

2.3 The Expectation of a Random VariableExpectations of Discrete Random Variables (1/2)

• Expectation of a discrete random variable with p.m.f

• The expected value of a random variable is also called the mean of the random variable

( )i iP X x p

( ) i ii

E X p x

state space( ) ( )E X xf x dx

Page 21: Random Variables

Expectations of Discrete Random Variables (2/2)

• Example 1 (discrete random variable)– The expected repair cost is

(cost) ($50 0.3) ($200 0.2) ($350 0.5) $230E

Page 22: Random Variables

2.4 The variance of a Random VariableDefinition and Interpretation of Variance (1/2)

• Variance( )– A positive quantity that measures the spread of the

distribution of the random variable about its mean value– Larger values of the variance indicate that the

distribution is more spread out

– Definition:

• Standard Deviation– The positive square root of the variance– Denoted by

2

2 2

Var( ) (( ( )) )

( ) ( ( ))

X E X E X

E X E X

2

Page 23: Random Variables

Definition and Interpretation of Variance (2/2)

2

2 2

2 2

2 2

Var( ) (( ( )) )

( 2 ( ) ( ( )) )

( ) 2 ( ) ( ) ( ( ))

( ) ( ( ))

X E X E X

E X XE X E X

E X E X E X E X

E X E X

Two distribution with identical mean values but different variances

( )f x

x

Page 24: Random Variables

Examples of Variance Calculations (1/1)

• Example 1

2 2

2 2 2

2

Var( ) (( ( )) ) ( ( ))

0.3(50 230) 0.2(200 230) 0.5(350 230)

17,100

i ii

X E X E X p x E X

17,100 130.77

Page 25: Random Variables

2.5 Jointly Distributed Random VariablesJointly Distributed Random Variables (1/4)

• Joint Probability Distributions– Discrete

( , ) 0

satisfying 1

i j ij

iji j

P X x Y y p

p

Page 26: Random Variables

Jointly Distributed Random Variables (2/4)

• Joint Cumulative Distribution Function– Discrete

( , ) ( , )i jF x y P X x Y y

: :

( , )i j

iji x x j y y

F x y p

Page 27: Random Variables

Jointly Distributed Random Variables (3/4)

• Example 19 : Air Conditioner Maintenance– A company that services air conditioner units in

residences and office blocks is interested in how to schedule its technicians in the most efficient manner

– The random variable X, taking the values 1,2,3 and 4, is the service time in hours

– The random variable Y, taking the values 1,2 and 3, is the number of air conditioner units

Page 28: Random Variables

Jointly Distributed Random Variables (4/4)

• Joint p.m.f

• Joint cumulative distribution function

Y=number of units

X=service time

1 2 3 4

1 0.12 0.08 0.07 0.05

2 0.08 0.15 0.21 0.13

3 0.01 0.01 0.02 0.07

0.12 0.18

0.07 1.00

iji j

p

11 12 21 22(2,2)

0.12 0.18 0.08 0.15

0.43

F p p p p

Page 29: Random Variables

Conditional Probability Distributions (1/2)

• Conditional probability distributions– The probabilistic properties of the random variable X

under the knowledge provided by the value of Y– Discrete

|

( , )( | )

( )ij

i jj

pP X i Y jp P X i Y j

P Y j p

Page 30: Random Variables

Conditional Probability Distributions (2/2)

• Example 19– Marginal probability distribution of Y

– Conditional distribution of X

3( 3) 0.01 0.01 0.02 0.07 0.11P Y p

131| 3

3

0.01( 1| 3) 0.091

0.11Y

pp P X Y

p

Page 31: Random Variables

Covariance

• Covariance

– May take any positive or negative numbers.– Independent random variables have a covariance of zero– What if the covariance is zero?

Cov( , ) (( ( ))( ( )))

( ) ( ) ( )

X Y E X E X Y E Y

E XY E X E Y

Cov( , ) (( ( ))( ( )))

( ( ) ( ) ( ) ( ))

( ) ( ) ( ) ( ) ( ) ( ) ( )

( ) ( ) ( )

X Y E X E X Y E Y

E XY XE Y E X Y E X E Y

E XY E X E Y E X E Y E X E Y

E XY E X E Y

Page 32: Random Variables

Independence and Covariance

• Example 19 (Air conditioner maintenance)

( ) 2.59, ( ) 1.79E X E Y 4 3

1 1

( )

(1 1 0.12) (1 2 0.08)

(4 3 0.07) 4.86

iji j

E XY ijp

Cov( , ) ( ) ( ) ( )

4.86 (2.59 1.79) 0.224

X Y E XY E X E Y


Recommended