Presentation is loading. Please wait.

Presentation is loading. Please wait.

Random variable. Let (, , P) is probability space.

Similar presentations


Presentation on theme: "Random variable. Let (, , P) is probability space."— Presentation transcript:

1 Random variable. Let (, , P) is probability space. is sample space,  is -algebra (all subsets of ), P is probability. Random variable X is measurable real function X:   R. Example. The toss of a dice. = {it occurs 1, it occurs 2, …, it occurs 6} are all subsets of  P is probability function defined on . We define random variable X: it occurs i  i. We distinguish between continous and discrete random variables. Range of discrete random variable is discrete (for example finite). Range of continous random variable is continous. (interval or the countable union of intervals)

2 Discrete random variable.
We define probability of each value from the range. The procedure is following: p is so called probability function. If the range of random variable X is {x1, x2, …, xn}, then The random variable is defined together by: rule (formula) probability function The next possibility is definition of random variable by distribution function F and by rule:

3 Example. The car must pass through four crossroads controlled by traffic lights. At every traffic light can be either green or red (orange is not considered). Denote the random variable X “number of crossroads crossed to the green (the next will be red)”. Write the probability function p and the distribution function F. The range of X is {0, 1, 2, 3, 4} p(0) = 0.5 p(1) = 0.52 = 0.25 p(2) = 0.53 = 0.125 p(3) = 0.54 = p(4) = 0.54 = p(x) = 0, x > 4. F(x) = pro

4 Example. There are 5 white balls and 7 red balls in the box. The random variable X is defined as the number of white balls among 5 balls selected. Create the probability and distribution functions. Range of X is {0, 1, 2, 3, 4, 5} , x = 0, 1, 2, 3, 4, 5

5 Continous random variable.
The distribution function F is used for the definition of the random variable. F (x) = P (X (w) < x) The properties of F(x) (for continuous and discrete random variables together: F(x) ≤ 1 P(x1 ≤ X (w) < x2) = F(x2) - F(x1) pro x1 < x2 F(x) is not decreasing function F(- ∞) = 0, F(∞) = 1 F(x) is continous from the left in points x = xi, i = 1,2,..., and continous in other points. In addition of of the probability function for discrete random variable we define density function: It is the real function defined and nonnegative on the interval <a, b>, , x, x+h <a, b>, f (x) = 0, x  <a, b>

6 The properties of f (x) and F (x) of the continuous random variable X:
x ∈ R  f (x) ≥ 0 , f(x) > 0, x <a, b> Example. The random variable X is defined by its distribution function F. Define f (x), plot F (x), f (x), compute P(0.4 ≤ X (w ) < 1.6). F (x) = 0, x  0, F (x) = x 2 / 4, 0 < x  2, F (x) = 1, x > 2.

7 f (x) = 0, x  0, f (x) = x / 2, 0 < x  2, f (x) = 0, x > 2.

8 Definition of random variable by moments.
The general definition of the moment mk: for the discrete random variable for the continous random variable Generally, random variable can have infinite number of nonzero moments. (k + ). It means that for its full definition infinite numbers of moments are necessary. In practice random variables with a few nonzeroes moments are used for general random variable only a a few moments are computed (most often 2). The general definition of the central moment nk (m is the first moment of random variable according to the definition above): for the discrete random variable for the continous random variable

9 The moments most often used.
The 1-st moment m1 defines the mean of the random variable X, m1  E ( X )  m for the discrete random variable for the continous random variable For the mean is: 1. E(c) = c , where c is constant 2. E(c.X) = c.E(X) 3. E(X±Y) = E(X) ± E(Y) 4. E(X.Y) = E(X).E(Y), if X and Y are inependent The 2-nd central moment defines variance of the random variable X, n2  s2 = var X for the discrete random variable for the continous random variable

10 For variance D (X)  s 2 is:
1. D(c) = 0, where c is constant 2. D(c.X) = c 2.D(X) 3. D(X + Y) = D(X) + D(Y), if X and Y are independent 4. σ is standard deviation The 3-rd central moment defines asymetry of random variable X, n3 is called skewness. n3 = E[(X – EX)3] / s3 The 4-the central moment n4 is called curtosis n4 = E[(X – EX)4] / s4

11 Quantiles. Let F(x) is distribution function of continous random variable X. Then xp, where F(xp) = p, p∈<0,1>, is called p-quantile. Quantils most often used: quartiles: x0.25, x 0.50, x 0.75 – it divides the range into four parts with the same probailities of occurence. deciles: x 0.1, x 0.2, ..., x it divides the range into ten parts with the same probailities of occurence. percentiles: x 0.01, x 0.02, ..., x it divides the range into hundred parts with the same probailities of occurence. median: x it divides the range into two parts with the same probailities of occurence.

12 Modus. for the discrete random variable it is value, where p(xi) is maximal. for the continous random variable it is value, where f (x) is locally maximal.

13 The motivation for statistics.
We follow the life of components in a computer that is in continuous operation in time. The life varies according to the environment, in which the computer is located (dust, moisture, ...) The random variable can be defined therefore as the durability. We consider the continous space, time interval. The random variable „ the durability of the component“ has some density function, some positive mean , some variance  2 . It is therefore defined some probability distribution, but it is unknown. We select randomly n computers and we find the durability of given component. In m independent selections (of n computers), we probably obtain m different vectors (each selection with n components). Therefore the selection of n computers X1, …, Xn can be considered as random variables. We assume n computers were selected independently All Xi are of the same probability ditribution.

14 The sequence of independent random variables X1, …, Xn, with the same
distribution is called random choice from that common distribution. The importance of the random choice. We are able to describe theoretical random variable X by the set randomly chosen samples. We define the sample mean  it is a random variable the sample variance  it is a random variable and it is unconstrained estimation of  standard error of mean (SE)  variation of means (it is decreasing to zero, as n is increasing to infinity) S2 is unconstrained estimation of 2 where X1, …, Xn is random choice from distribution with paramaters , 2.

15 Examples. The density function of random variable X is:
f (x) = 0, x < 0; f (x) = a sin x, 0 ≤ x < p ; f (x) = 0, x  p. Compute a, distribution function F(x) and P(p/2 < X < 2p ). The random variable X is defined by table. Compute the first moment and the second central moment. The density of the random variable X is: f (x) = x2 e-x /2, x (0, + ), f (x) = 0, otherwise. Define modus. The density of the random variable X is: f (x) = 2x, x<0, 1>, f (x) = 0 otherwise. Compute mean and variance. Define the first decile and the third quartile of random variable defined by the density function: f (x) = 1/2, x<0, 2>, f (x) = 0 otherwise. We shoot three times on goal. The hit probability at each shot is p = 0.7. Define: the probability function of the hit number for three independent results, b) The distribution function and its graph. The random variable X is defined by the distribution function: F (x) = 0, x < 3, F (x) = x/3 – 1, 3 ≤ x < 6, F (x) = 1, x  6. Define f(x), plot f(x), F(x) a P(1.5 ≤ X ≤ 4).

16 Define, for what A, B F (x) = A + B/(1 + x2)
a) is the distribution function of random variable, x∈(0, +∞), b) its density function. The result of random experiment is random variable with values 1/ n (n is natural number) and with probabilities inversely proportional to 3n. Define mean of this random variable. The function f (x) = C (2x – x2) is the probability density function for x ∈ <0,2>. Compute a) the constant C, b) distribution function F(x), c) mean, d) variance and standard deviation, e) the probability P(X<1).


Download ppt "Random variable. Let (, , P) is probability space."

Similar presentations


Ads by Google