0% found this document useful (0 votes)
27 views23 pages

Probability Review Stochastic

Probability Review Stochastic

Uploaded by

lllt
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
27 views23 pages

Probability Review Stochastic

Probability Review Stochastic

Uploaded by

lllt
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 23

Stochastic Processes

Probability Review

Noha Youssef

The American University in Cairo


[email protected]

1 / 23
Table of Contents

Introduction to Probability

Random Variables

Expectation and Variance

Conditional Expectation

Laws of Total Expectation and Variance

2 / 23
Probability

Definition 1.1: A sample space, Ω, is a set of possible outcomes


of a random experiment.
Definition 1.2: An event, A, is a subset of the sample space. This
means that event A is simply a collection of outcomes. Event
A occurs if the outcome of the random experiment is a member
of the set A.

3 / 23
Probability Rules
Axioms
1. P (φ) = 0
2. 0 ≤ P (A) ≤ 1

Complement
P (Ā) = 1 − P (A).

Addition Rule
P (A ∪ B) = P (A) + P (B) − P (A ∩ B). If A and B are mutually
exclusive then P (A ∪ B) = P (A) + P (B).

Conditional probability
P (A∩B)
P (A|B) = P (B) .

4 / 23
Cont’D

Multiplication Rule
P (A ∩ B) = P (A) × P (B|A) = P (B) × P (A|B).

The Partition Theorem


If B1 , B2 , · · · Bm form a partition of Ω, then
m
X m
X
P (A) = P (A ∩ Bi ) = P (A|Bi )P (Bi )
i=1 i=1

for any event A.

5 / 23
Cont’D
Bayes’Theorem

P (A|B)P (B)
P (B|A) = ,
P (A)
more generally if B1 , B2 , · · · Bm form a partition of Ω, then

P (A|Bj )P (Bj )
P (Bj |A) = Pm .
i=1 P (A|Bi )P (Bi )

Chain of events
For any events A1 , A2 , · · · , ...An ,

P (A1 ∩ A2 ∩ · · · An ) = P (A1 )P (A2 |A1 )P (A3 |A1 ∩ A2 ) · · ·


P (An |An−1 ∩ · · · ∩ A1 )

6 / 23
Example 1

a. Which of the following is equal to P (B ∩ C|A)?


P (B|C)
(a) P (B|C ∩ A) (b) P (A)

(c) P (B|C ∩ A)P (C|A) (d) P (B|C)P (C|A)

Solution

P (B ∩ C|A) = PA (B ∩ C)
= PA (B|C)PA (C)
= P (B|C ∩ A)P (C|A).

7 / 23
Examples
b. Which of the following is true
(a) P (B̄|A) = 1 − P (B|A) (b)P (B̄|A) = P (B) − P (B|A)
c. Which of the following is true?
(a)P (B̄ ∩ A) = P (A) − P (A ∩ B)
(b)P (B̄ ∩ A) = P (B) − P (A ∩ B)

Solution
(a)
P (B̄|A) = 1 − P (B|A)
(b)

P (B̄ ∩ A) = P (B̄|A)P (A)


= (1 − P (B|A))P (A)
= P (A) − P (B ∩ A).
8 / 23
Random Variable

Definition 1.3: A random variable, X, is defined as a function


from the sample space to the real numbers: X : Ω → R.
A random variable therefore assigns a real number to every possible
outcome of a random experiment.
A random variable is essentially a rule or mechanism for generating
random real numbers.

9 / 23
The Distribution Function

Definition 1.4: The cumulative distribution function of a random


variable X is given by FX (x) = P (X ≤ x), FX (x) is often referred
to as simply the distribution function.
Properties of the distribution function
1. FX (−∞) = P (X ≤ −∞) = 0, FX (+∞) = P (X ≤ ∞) = 1.
2. FX (x) is a non-decreasing function of x: if x1 < x2 , then
FX (x1 ) ≤ FX (x2 ).
3. If b > a, then P (a < X ≤ b) = FX (b) − FX (a).

10 / 23
Continuous Random Variable

Definition 1.5: The random variable X is continuous if the dis-


tribution function FX (x) is a continuous function. In practice, this
means that a continuous random variable takes values in a continu-
ous subset of R: e.g.X : Ω → [0, 1] or X : Ω → [0, ∞).
Let X be a continuous random variable with continuous distribution
function FX (x). The probability density function (p.d.f.) of X is
defined as
d(FX (x))
fX (x) = FX0 (x) = .
dx
The pdf, fX (x), gives the shape of the distribution of X.

11 / 23
Discrete Random Variable

Definition 1.6: The random variable X is discrete if X takes values


in a finite or countable subset of R: thus, X : Ω → {x1 , x2 , · · · }.
When X is a discrete random variable, the distribution function
FX (x) is a step function.

Let X be a discrete random variable with distribution function FX (x).


The probability function of X is defined as

fX (x) = P (X = x).

12 / 23
Cont’D
The mean, expected value, or expectation of a random variable X is
written as E(X) or µX . If we observe N random values of X, then
the mean of the N values will be approximately equal to E(X) for
large N . The expectation is defined differently for continuous and
discrete random variables.
Definition 1.7:
Let X be a continuous random variable with p.d.f. fX (x). The
expected value of X is
Z ∞
E(X) = xfX (x)dx
−∞

Definition 1.8:
Let X be a discrete random variable with probability function
fX (x). The expected value of X is
X X
E(X) = xf (x) = xP (X = x).
x x

13 / 23
Properties of Expectation

1. Let g and h be functions, and let a and b be constants. For


any random variable X,

E (ag(X) + bh(X)) = aE (g(X)) + bE (h(X)) .

2. Let X and Y be ANY random variables (discrete, continuous,


independent, or non-independent). Then
E(X + Y ) = E(X) + E(Y ).
More generally, for ANY random variables X1 , · · · , Xn ,
E(X1 + · · · + Xn ) = E(X1 ) + · · · + E(Xn ).
3. Let X and Y be independent random variables, and g, h be
functions. Then E(XY ) = E(X)E(Y ),
E(g(X)h(Y )) = E(g(X))E(h(Y )).

14 / 23
Cont’D

Notes:
1. E(XY ) = E(X)E(Y ) is ONLY generally true if X and Y are
INDEPENDENT.
2. If X and Y are independent, then E(XY ) = E(X)E(Y ).
However, the converse is not generally true: it is possible for
E(XY ) = E(X)E(Y ) even though X and Y are dependent.

15 / 23
Variance
The variance of a random variable X is a measure of how spread
out it is. The variance measures how far the values of X are from
their mean, on average.
Let X be any random variable. The variance of X is

V ar(X) = E(X − µX )2 = E(X 2 ) − E(X)2 .

The variance is the mean squared deviation of a random variable


from its own mean.
Properties of Variance
1. Let g be a function, and let a and b be constants. For any
random variable X, V ar(ag(X) + b) = a2 V ar(g(X))
2. Let X and Y be independent random variables. Then V ar(X +
Y ) = V ar(X) + V ar(Y ).
3. If X and Y are NOT independent, then V ar(X+Y ) = V ar(X)+
V ar(Y ) + 2cov(X, Y ).
16 / 23
Conditional Expectation

Definition 1.8
Consider a pair (X, Y ) of discrete random variables X and Y with
joint probability mass function p(x, y). The conditional expectation
E[X|Y = y] is defined as with and for
X
E[X|Y = y] = xpX|Y (x|y),
x

with
p(x, y)
pX|Y (x|y) = ,
pY (y)
and for
pY (y) 6= 0.

17 / 23
Cont’D

Definition 1.9
Consider a pair (X, Y ) of continuous random variables X and Y
with joint probability density function f (x, y). The conditional ex-
pectation E[X|Y = y] is defined as with and for
Z
E[X|Y = y] = xfX|Y f (x|y)dx,
x

with
f (x, y)
fX|Y (x|y) = ,
fY (y)
and for
fY (y) 6= 0.
Note that E[X|Y = y] changes with y. It follows that E[X|Y ]
is itself a random variable. Conditional expectation, EX|Y ), is a
random variable with randomness inherited from Y , not X.
18 / 23
Example
Consider the following joint density
1
f (x, y) =
x
for 0 < y ≤ x ≤ 1. Find E[Y |X].
Solution
First, we find the marginal density function of X by integrating
f (y, x) wrt y over 0 < y ≤ x.
Z x
1 1
f (x) = dy = y|x0 = 1
0 x x
It follows that
f (y, x) 1
f (y|x) = = .
f (x) x
The conditional expectation E[Y |X = x] is given by
Z x Z x
y y2 x x
E[Y |X = x] = yfY |X (y|x)dy = dy = | = .
0 0 x 2x 0 2
19 / 23
Example

Suppose that p(x, y), the joint probability mass function of X and Y ,
is given by p(1, 1) = 0.5, p(1, 2) = 0.1, p(2, 1) = 0.1, p(2, 2) = 0.3.
Find the distribution of E[X|Y ].
Solution
First we need to find the values E[X|Y ], bear in mind that by con-
ditioning we are restricting our sample space

y 1 2
1(0.5)+2(0.1) 7 1(0.1)+2(0.3) 7
E[X|Y = y] 0.5+0.1 = 6 0.1+0.3 = 4
P (Y = y) 0.6 0.4

20 / 23
Laws of Total Expectation and Variance

If all the expectations below are finite, then for ANY random vari-
ables X and Y , we have:
1. E(X) = EY (EX|Y (X|Y )), Law of Total Expectation.
2. V ar(X) = EY (V ar(X|Y )) + V arY (E(X|Y )), Law of Total
Variance.
The expectation or variance is computed over the distribution of the
random variable Y .

21 / 23
Proof for the discrete case

!
X X
EY EX|Y ((X|Y )) = xP (X = x|Y ) PY (Y = y)
Y x
!
X X P (X, Y )
= x PY (Y = y)
x
PY (Y = y)
Y
!
X X
= xP (X, Y )
Y x
!
X X
= x P (X, Y )
x y
X
= xP (X = x)
x
= E(X).

22 / 23
Homework

Find the unconditional expectation E(X) for Example 3.

23 / 23

You might also like