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

Stochastic Hydrology: Indian Institute of Science

This document provides a summary of key concepts in stochastic hydrology from a lecture at the Indian Institute of Science. It discusses bivariate and marginal distributions, conditional distributions, and independent random variables. It provides examples to illustrate independent random variables and the distributions of functions of random variables. The document covers both discrete and continuous cases for functions of random variables.

Uploaded by

Prasad
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
79 views

Stochastic Hydrology: Indian Institute of Science

This document provides a summary of key concepts in stochastic hydrology from a lecture at the Indian Institute of Science. It discusses bivariate and marginal distributions, conditional distributions, and independent random variables. It provides examples to illustrate independent random variables and the distributions of functions of random variables. The document covers both discrete and continuous cases for functions of random variables.

Uploaded by

Prasad
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 56

INDIAN

INSTITUTE OF SCIENCE

STOCHASTIC HYDROLOGY
Lecture -3
Course Instructor : Prof. P. P. MUJUMDAR
Department of Civil Engg., IISc.
Summary of the previous lecture
Bivariate distribuAons, Joint pmf and pdf
Marginal density funcAons
CondiAonal distribuAons

2
Independent Random Variables

Intuitively, the rvs X and Y are independent
if the distribution of one rv does not in any
way influence distribution of the other rv.

Independence is a useful assumption for


hydrologic analysis in many situations.
However, there must be a sound physical
basis for the assumption.

3
Independent Random Variables
As an example, inflow to a reservoir (X) and the rainfall
in the command area (Y) may be taken as independent,
if the command area is far removed from the reservoir.

Rainfall

Inflow

Reservoir

Command area
4
Independent Random Variables
In water quality problems, for example, pollutant load (X)
and stream flow (Y) may be treated as independent
variables. However, stream flow (Y) and water quality
indicator, e.g., DO at a location, (Z) are not independent.

Non-point Source PolluAon

5
Independent Random Variables
When two rvs are independent, g(x/y)=g(x)
Distribution of X given Y is independent of Y and
hence the conditional pdf is equalt to the marginal pdf.

f ( x, y )
g (x y) = h(y) > 0
h( y )
f ( x, y )
g ( x) =
h( y )
f ( x, y ) = g ( x).h( y )
6
Independent Random Variables
The random variables X and Y are stochastically
independent if and only if their joint density is equal to
the product of their marginal densities.
Discrete case: the two r.v.s are independent if and only if
p(xi, yj) = p(xi) . p(yj) v i,j

7
Example-1
Consider the joint pdf
f(x,y) = x+y 0<x<1
0<y<1
=0 elsewhere

For independence of X and Y, the following


condition must be satisfied

f ( x, y) = g ( x).h( y)

8
Example-1(contd.)
1 1
g(x) = f ( x, y )dy = ( x + y ) dy
0 0

2 1
y 1
= xy + = x + 0 x 1
2 0 2
1 1
h(y) = f ( x, y )dx = ( x + y ) dx
0 0

2 1
x 1
= + xy = y + 0 y 1
2 0 2
9
Example-1(contd.)
1 1
g ( x) h( y ) = x + y +
2 2

f ( x, y) g ( x).h( y)
Therefore X and Y are not stochastically
independent.

10
Example-2
Consider the joint pdf
f(x,y) = e-(x+y) x>0
y>0
=0 elsewhere

For independence,

f ( x, y) = g ( x).h( y)

11
Example-2(contd.)

( x + y )
g(x) = f ( x, y)dy = e
0 0
dy


= e x e y dy = e x x>0
0


h(y) = f ( x, y )dx = e ( x + y ) dx
0 0

= e y e x dx = e y y>0
0

12
Example-2 (contd.)
g ( x ) h( y ) = e x e y
= e ( x + y )

f ( x, y) = g ( x).h( y)
Therefore X and Y are stochastically
independent

13
Functions of Random Variable
Situations often arise when we will be interested in the
distributions of functions of r.v.s. For example,

Given the joint distribution f(x, y),Rainfall


we will be interested in getting fx+y
(x+y)

x y
x+y
Rain Gauge
Stream
Gauge
Stream
14
Flow
Functions of Random Variable
X: discrete; Y = H(X), a funcAon of X.
The pmf of X is known
Enumerate possible values of Y for the
discrete values of X
Then obtain the probabiliAes of the possible
values of Y from the probabiliAes of the
corresponding values of X.
Example for discrete case
p(x) = 60/77x ; x = 2, 3, 4, 5
discrete values
y = x2-7x+5
x 2 3 4 5
y -5 -7 -7 -5
p(x) 30/77 20/77 15/77 12/77
Distribution of y:
p(Y=-7) = p(X=3)+p(X=4) = 20/77+ 15/77 = 35/77 = 5/11
p(Y=-5) = p(X=2)+p(X=5) = 30/77+ 12/77 = 42/77 = 6/11

16
General procedure for functions of continuous
random variables:
X continuous, Y=H(X) continuous function of X
We are interested in getting the pdf g(y).
a. Obtain G, the cdf of Y , where G(y) = P [Y < y] by
finding the event in the range space of X which is
equivalent to the event Y < y. Y = 2 X + 5
Yy
2X + 5 y
Given f(x), you will get y 5
P [Y < y] X
2
y 5
P [Y y ] = P X
2
17
General procedure for functions of continuous
random variables:

b. Differentiate G(y) w.r.t y to get g(y)


c. Since g(y) must be non-negative, determine
those values of y over which g(y) > 0
and check,

g ( y)dy = 1

18
Example-1
The rv X has a pdf
f(x) = x/2 0<x<2
=0 elsewhere
Let H(X) = 4X+1
Find the pdf of Y=H(X)

a. Get the CDF of Y


G(y) = P [Y < y]
= P [4X+1 < y]
y 1
= P X
4
19
Example-1(contd.)
( y 1) 4

G(y) = f ( x )dx
0
( y 1) 4
x
= dx
0
2
2 ( y 1) 4
x
=
4 0
2
( y 1)
=
64
20
Example-1(contd.)
2
dG ( y ) d ( y 1)
b. g(y) = =
dy dy 64

2 y 1
= ( y 1) =
64 32

c. From 0 < x < 1, we get

( y 1)
g ( y) = 1< y < 9 y=4x+1
32

21
Example-1(contd.)
9
( y 1)
Check :
1 32 dy = 1
9 2 9
( y 1) 1 ( y 1)
1 32 dy = 32 2
1

1 2
= (8 0)
64
=1

22
Example-2
The rv X has a pdf
f(x) = 3e-3x 0<x<
=0 elsewhere
Let H(X) = eX
To find the pdf of Y=H(X)

a. Get the CDF of Y

G(y) = P [Y < y]
= P [eX < y]
= P [X < lny]
23
Example-2(contd.)
ln y
G(y) = f ( x ) dx
0
ln y

= 3e 3 x dx
0

3 x ln y
3e
=
3 0
= e 3ln y (1)
ln y 3
= 1 e
= 1 y 3 24
Example-2(contd.)
dG ( y ) d
b. g(y) =
dy
=
dy
(
1 y 3 )
(
= 0 3 y 4 )
= 3 y 4

c. From 0 < x < , we get

g ( y) = 3 y 4 1< y <

25
Example-2 (contd.)

4
Check dy = 1
1
3 y
3
4 3( y )
1 3 y dy = 3
1

(
= 3 ( 1) )
1
= 1

= 1 0 = 1
26
Generalization for monotonous function

u(x) is a monotonically increasing function of x if u(x2)>u


(x1) v x2>x1(as x increases, u(x) increases)
u(x) is a monotonically decreasing function of x if u(x2)
<u(x1) v x2>x1(as x increases, u(x) decreases)

u(x) Monotonically u(x) Monotonically


increasing decreasing
u(x2) u(x1)
u(x1) u(x2)
x1 x2 x x1 x2 x

27
Generalization for monotonous function
Let X be a continuous rv with pdf f(x), where f
(x)0 for a<x<b.
Suppose that Y=H(X) is a strictly monotonic
(increasing or decreasing) function of X .
If this function is differentiable and continuous for
all x , then the rv Y = H(X) has a pdf g(y) given
by dx
g ( y ) = f ( x)
dy
x and f(x) are expressed in terms of y

28
Example-2
Consider the previously solved example-2
f(x) = 3e-3x 0<x<
=0 elsewhere
Let H(X) = eX
Find the pdf of Y=H(X)

x is expressed in terms of y
y = eX
x = lny
dx 1
=
dy y
29
Example-2(contd.)
3 x
f(x) = 3e
3ln y
= 3e
ln y 3
= 3e
= 3 y 3
dx
g ( y ) = f ( x)
dy
31
g ( y) = 3 y
y
4
= 3y
30
Example-2(contd.)
Y is a monotonically increasing function of X
Y = eX
as x tends to 0, y tends to 1
x tends to , y tends to

4
Therefore g ( y ) = 3 y 1 y
as obtained earlier.

31
Functions of two dimensional RVs
In the case of a continuous bivariate r.v., the
transformation from f(x,y) to g(u,v), where U=H1(X, Y)
and V=H2(X, Y) are one-to-one continuously
differentiable transformation is given by
g (u, v) = f ( x, y) J (u, v)
J(u, v) is the Jacobian of the transformation, given by
dx dx
du dv
J (u, v) =
dy dy
du dv
x , y and f(x, y) are expressed in terms of u and
v 32
Example-3
Consider the joint pdf
3 2 0<x<1
(
f ( x, y ) = x + y 2
2
) 0<y<1

U = X+Y and V=Y/2 what is the joint pdf of (u, v)

x and y are expressed in terms of u and v


y = 2v
x = u-2v

33
Example-3(contd.)
3 2
(
f ( x, y ) = x + y
2
2
)
3
( 2
= ( u 2v ) + ( 2v )
2
2
)
3 2
(
= u 4uv + 8v 2
2
)
du dv
1 dx dx 1 0 1
= = 1 = Or J = 2
J du dv 1 2
2
dy dy
34
Example-3(contd.)
g (u, v) = f ( x, y ) J (u, v)
3 2
(
= u 4uv + 8v 2 2
2
)
(
= 3 u 2 4uv + 8v 2 )
U = X+Y 0<x<1
Limits: V=Y/2 0<y<1

y=0, v=0 ; y=1, v=1/2

x = 0, u=2v ; x = 1, u=1+2v
35
Example-3(contd.)

g (u, v) = 3 u 2 4uv + 8v2 02v << uv << 1/2


( ) 1+2v

From this joint distribution, we may obtain the marginal


distributions of u and v by integrating over the other
variable.

36
Example-3(contd.)
In some cases only distribution of U=u(x, y) is
desired.
In such case define a dummy r.v. V=v(x,y),
find the joint pdf g(u, v) and then integrate over v to
get the marginal density of u

Consider the previous joint pdf


3 2 0<x<1
(
f ( x, y ) = x + y 2
2
) 0<y<1

U = X+Y and define a dummy variable V as V=Y

37
Moments of a distribution
Population: All possible values of a r.v.
E.g., If a r.v. is defined as a page in a book, all
pages in the book together constitute the
population
Sample: A subset of population
E.g., a chapter in the book
Realization: A (time)series of the r.v. actually
realized
Observation: A particular value of the r.v. in
the realization.
38
Moments of a distribution
f(x)
nth moment about the origin

n0 = x n f ( x)dx

E(X): Expected value of X dx E(x) x
: First moment about the origin

= E(X) = x f ( x)dx

nth moment about the expected value



n
n = (x )

f ( x)dx
39
Expected value:

E(X) = x f ( x)dx


E(c) = c c. f ( x) dx

E(cX) = cE(X)

E[c.g(X)] = c. E[g(X)]

E[g(X)] = g ( x) f ( x)dx

E[g1(X) + g2(X)] = E[g1(X)] + E[g2(X)]


40
Measures of central tendency
Mean:

= x f ( x)dx
n
Discrete case: = x p( x )
i =1
i i n: Sample space

x i
Sample estimate: x=
n
Mode: Value with highest frequency of occurrence

Median: Value such that 50% of area is on either side

41
Measures of spread or dispersion
f(x)

Same mean but


different spread
around the mean

x
Range:
xmax xmin

Variance: Second moment about the mean



2 = E ( X )2 = ( x ) 2
f ( x)dx
42
Measures of spread or dispersion
Sample estimate: 2
n

x
i x
n: No. of observations
s 2 = i =1
n 1 in the sample
Standard deviation:
=+ 2 Positive squareroot

s = + s2
Coefficient of variation:

cr = -- Population

s -- sample space
=
x 43
Measures of symmetry
Negative skew Symmetric
Cs<0 Cs=0
Positive skew
Cs>0

Coefficient of skewness:
Population Sample
3 n 3
s = 3/2

2 n xi x
Cs = i =1
( x )3 f ( x) dx (n 1)(n 2) s 3

=
( 2 )3/2 44
Measures of Peakedness
Lepto kurtic Normal
K>3 K=3

Platy kurtic
K<3

Coefficient of kurtosis:
Population Sample 4
n

n 2 xi x
4 i =1
K= 2 K=
2 (n 1)(n 2)(n 3) s 4

45
Example-1
Consider v as wind velocity and pdf is given as
1
f (v ) = 0v5
5
And Pressure w = 0.12v2, obtain E[w]
5
2 1
E[w] = 0.12v dv
0
5
3 5
0.12 v
= = 1
5 3 0

46
COMMONLY USED
DISTRIBUTIONS

47
Normal Distribution
f(x)

-
+
x
2
1
1 x
f ( x) = exp < x < +
2 2
Two parameters, &
X N(, 2)
F(x) approaches zero as x +
48
Normal Distribution
Coefficient of skewness, s = 0

Kurtosis coefficient, K = 3

y = a + bx - Linear form of x

y N(a+b, b22)
x

F(x) = f ( x )dx
2
x 1 x
1
2

=
2 e

dx < x < +
49
Normal Distribution
x
z= -- Linear form

1
a= ,b =

1 2
z : N + , 2

: N (0,1)
Pdf
1 z2 2
(z) = e < z < +
2
cdf of z
z
1 z2
(z) = e 2
dz
2
50
Normal Distribution
f(x)
99% of area 0.68
between +3
0.94
0.99

-3 -2 -1 0 1 2 3 x
Use of tables: f(x)
Area

z x
P[Z < z] = 0.5+Area from table 51
Normal Distribution
P[Z < z] f(x)
A1 from tables

(0.5 - A1) (0.5 - A1)

-z +z z

from table

e.g., P[Z < -0.7] = 0.5 0.258


= 0.242

52
Examples on Normal distribution
Obtain the area under the standard normal curve
between -0.78 and 0

Req. area

-0.78 0 z

Req. area = area between 0 and +0.78


= 0.2823

53
Examples on Normal distribution
Obtain the area under the standard normal curve
z < -0.98

Req. area
-0.98 0 z

Req. area = 0.5 area between 0 and +0.98


= 0.5 0.3365
= 0.1635

54
Examples on Normal distribution
Obtain z such that P[Z < z]=0.879

Since the value is greater than 0.5, z must be +ve

Area=0.879

0 z
area between 0 to z = 0.5 0.879
= 0.379
From the table, for the area of 0.379, corresponding
z = 1.17
55
Examples on Normal distribution
Obtain x such that P[X > x]=0.73 if =650; = 200

P[X < x]=0.27 Area=0.27

-z 0
P[Z < z]=0.27

area between 0 to -z = 0.5 0.27


= 0.23
From the table, z = -0.61

x x 650
z= 0.61 = x = 528
200
56

You might also like