Math 300 , Spring 2008, Day 29, W, April 9 Hit reload

Mini-exam handed out today; Due beginning of class Wed. Day 31, Apr. 16
HW: repeated from Day 28--if you haven't done them
Ash 7-1 p. 221 1, 3 are hard integrations without p. 95.
#2  Sketch the graph, Do the calculus, get the obvious answer.
#1, #3 (use p. 95)
#15
Ash 7-2, p. 233
#2 (you did E(X) already, Day 28. Only hard thing is simplifying the polynomials.
 Useful
to know b3 - a3 = (b - a)(b2 + ab+ a2).
This is a special case of  bn - an = (b - a)(bn-1 + abn-2+ ...+ an-2b + an-1).
(Which we saw used to develop the geometric series, with b = 1, a = x)

HW: Normal review, Ash 4.4  p. 136 Note, Ash uses X*, instead of the more conventional Z, for std. normal.
Do the bold ones, read the others to make sure you can do them.
# 1, 2, 3, 4, 5, 6, 7, 9, 17, 14(X = # who show: It's binomial--use Normal approx. to binomial.)

A) Practice the Fundamental Theorem using the : http://www.math.temple.edu/~cow/
Calculus Book II > 1.Integration > 4.Fundamental Theorem > 1.Differentiation and the Fundamental Theorem . do 1, 2, 8.   8 requires the chain rule.
"Help" will explain the topic well.  You should check your "fundamental theorem" answers to these 3 by doing the integration shown, then taking the derivative.  (For instance, in 8, integrating 2t gives the indefinite integral t2.  Evaluating between x2 and 2 gives (x2 )2 - (2)2= x4  - 4.  Taking the derivative gives 4x3.  Your "fundamental theorem" answer must match this one.
Then do #10.  Then read the Help to know how to attack problems where both limits of integration move, and do #6.  Practice a few more, from anywhere in the list of 20.
B)  For X = # on a fair 10-sided die, consider the transformations Y = X - 4, W = Y2, and find and sketch the probability functions pX(x), pY(y), pW(w), as done below.
Do the above, read the rest of the webpage, start reading 4.6.
HW: 4.6: Read as much of 4.6 as you can stand. I have misprints: p.142, bottom formulas are fY and FY,  not X as I have.  The axes in the graphs on p. 148 are rubbery.
A)  X is uniform on [0, 1].  Let Y = cX + d. (assume c > 0)   a) On what interval does Y have positive probability?
b)  Write FY(y0) = P(Y < y0), substitute Y = cX + d, and solve to get P(X.....)  Find a formula for this, using the CDF for X. (no integrals needed.  Use technique (a) below. )  Answers?  Check by drawing a picture, or pictures, compare with Ash pp. 106-7.
c) Take the derivative with respect to y, thus finding fY(yo).  For F and f, be sure to give the intervals where your functions are in force.
d) Now use the Density method to go straight from fX(x)  to fY(y).  Sketch it for c = 2, d = 3, and show where x= 0, .5, and 1 map to.

B)  Repeat A for the uniform distribution,  only assume c < 0  (so values flip direction.)  For  c = -2, d = 3,  show where x= 0, .5, and 1 map to, before you begin.  Use the CDF method, then try the Density method (use technique (c) for coping with the minus.)

C) Applying technique (b) below: After the fundamental theorem --chain rule version--is understood, look at the derivation below  for standardizing X normal.  We got FZ(zo) = .  Instead of continuing with the change of variables, Take the derivative of this with respect to z (drop the 0-subscript to do so).
You should get, after everything is done, the formula for fZ(z).

= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
Continuing with E(X), Var(X)
Find E(X) for exponential (as p. 214).  Requires integration by parts (or Ash's handy formula p. 95).
Find Var(X)= E(X2) - µ2 for exponential (p.226, and p. 95)
Find E(X) for Normal (0, 1). (not hard.)
Find Var(X) for normal (0,1), integrating by parts. (We'll use the fact that area under f(x) = 1, which we haven't proved.)
Proofs written out, handout

Gamma, wait till n'th hit, parameter lambda
The waiting time X can be thought of as the sum of the waiting time till first hit + interval till 2nd +...+ interval till n'th.
X = X1+X2+...+Xn
 Since it's a Poisson process, all these Xi are independent exponential.  (Cf. Neg. binomial).
So E(X) = n times expected for exponential, Var(X) = n times Var for exponential. ..

Return to Ch. 4, Sec.4.4, (4.5 optional) 4.6.
Normal distributionN(mu, sigma)

 f(x) = normal formulaF(x) = integral of f. There is no "closed form" formula in elementary functions for F(x).

The parameters are the mean and standard deviation for the normal distribution. You've been told that but we have not proved it. We just proved that the mean and the standard deviation for the Standard Normal distribution Z were 0 and 1.  The proofs from the general formula "become" the same proofs if you make the change of variable (substitution) and change the limits of integration too. (Pp. 224-26).  (Ash uses X* for what is more commonly called Z.)

- - - - - - - - - - - - - - - - - - -

If we have a Normal variable X, and we "standardize", you've been told to take on faith that you get a "standard normal" variable Z--the same distribution but with 0, 1 as parameters.  Now (soon) we'll prove it.

How do we find the distribution of a function of a random variable?

Review Discrete:  just intuitively, a die:  X

1/6 1/6 1/6 1/6 1/6 1/6
 V   V   V   V   V   V     x    (these are supposed to represent the lumps of probability)
 1   2   3   4   5   6

Y = X-3
1/6 1/6 1/6 1/6 1/6 1/6
 V   V   V   V   V   V     y     Every x point maps to a y point, and drags its probability along with it.
-2  -1   0   1   2   3

W = Y2                                     Every y point maps to a w point,
1/6 2/6         2/6                 1/6       and drags its probability along with it.
     V           V
 V   V           V                   V   w     Sometimes two points map to the same point.
 0   1   2   3   4   5   6   7   8   9

This gives you an idea of what the issues are; we'll develop the continuous analog of the above as the "Density method"

First step always: Determine which regions of y (or w or whatever) have no probabality by looking at range of x's, what happens in transformation.  Above, 1< x <6, so (1-3)< y <(6-3); -2< y < 3.   w >0 because it's a square; w < 9 since 32 =9 .

CDF method:  Look at the discrete case, W = (X-3)2    Start with wanting FW(wo).  = P(W < wo)
What X-interval maps into W < wo ?   (X-3)2 < wo  so  -sqrt(wo) +3 <  X < sqrt(wo)+3.
Find that probability using the distribution of X.  P(-sqrt( wo) +3 <  X < sqrt(wo)+3 ) =
    sum of 1/6'ths for all values in this interval.  Or =
      P(X < sqrt(wo)+3) -  P(X <  -sqrt(wo)+3)
          For this discrete case, list the values of w and calculate these probabilities.

W = (X-3)2
1/6 2/6         2/6                 1/6
     V           V
 V   V           V                   V   w
 0   1   2   3   4=wo5   6   7   8   9

1/6 1/6 1/6 1/6 1/6 1/6
 V   V   V   V   V   V     x    If wo = 4, (-2+3)< X < (2+3), by inspection, so FW(wo)=5/6 ; others similarly.
 1   2   3   4   5   6

How do we find the distribution of a function of a continuous random variable? (Sec. 4.6)

Y = g(X). Two methods:

1) CDF method: Find FY(y0) = P(Y < y0) = P(g(X) < y0)
Do what you need to, to rewrite this as P(X <? g-1?(y0) ) (If g doesn't have an inverse over the whole range this could be more complicated. And the inequality might reverse.)

This can (usually) be written as an integral with upper limit x= g-1 (y0), f(x)dx. Change variables to y, inside the integral and in the limits, until you get an integral with y0 as the upper limit. That's your FY(y0).
Example: Normal distribution, standardize it. .= g(X).   This is a nice linear transformation, 1-to-1, and the normal distribution has the same formula everywhere, and no places where f(x) = 0). 
 FZ(z0) = P(Z < z0) = P(g(X) < z0) = P( ) = P() =

   Change variables to  and you'll get  We recognize this is the CDF of the standard normal.  You can take the derivative to get the pdf.

2) Density method: (Assume first that Y = g(X) is 1-1)  Suppose X has density fX(x). We want the density of Y, fY(y).   In the continuous case, Areas get dragged along from one axis to the other.  Mark off a bunch of values on the x-axis.  

xi -->yi , xi+1 -->yi+1 ,  Width of the interval in x is dx =  xi+1 - xi ,
                         width of the interval it maps to in y is dy =  yi+1 - yi
But the Area above that interval in x has to be the same as the area above the corresponding interval in y:  Each area is approximately a rectangle:  (This is analogous to the lumps of probability in the discrete case.)
  fY(yi) dy = Area = fX(xi) dx.  Solve for  fY(yi), and use y = g(x) or x = g-1(y) to get everything in terms of y.

Expand:  A thin rectangle at xo of width dx and height fX(xo) gets mapped by y = g(x) into a rectangle at yo of width dy and height fY(yo). (If g is one-to-one, that's all that gets mapped into the new rectangle.)

Set the rectangles equal: fY(yo)dy = fX(xo) dx

Solve for fY(yo):
              fY(yo) = fX(xo) dx/dy. You have to find dx/dy, and change variables to get everything in terms of y.
Since y = g(x), dy/dx = g'(x). You can put it under 1 to get dx/dy. Or find x = g-1 (y) and take the derivative of x with respect to y.

Example: Linear transformations first. Normal.
Let X be .  Let .  A rectangle at xo of width dx and height fX(xo) gets mapped by into a rectangle at zo of width dz and height fZ(zo). fZ(zo)dz = fX(xo) dx      fZ(zo) = fX(xo) dx/dz.

, so .

fX(xo) = , rewrite in terms of z, not hard.
Then fX(xo) dx/dz =, the pdf for Z !

Additional techniques: First step always: Determine which regions of y (or w or whatever) have no probabality by looking at range of x's, what happens in transformation. 
(a)  CDF Method variation:  If the CDF has a nice formula FX(x), after you get to P(X < something ), you can just substitute x = something into FX(x,)  getting FX(something). If FX does not have the same formula everywhere, you'll have to follow each piecewise formula in the transformation.

(b) CDF method variation  If you end up with an integral, instead of changing variables inside the integral,  you can find the density by taking the derivative.  This requires a more sophisticated use of the Fundamental Theorem of the Calculus, with the chain rule, since the upper limit of the integral will not be simple.

Practice here: http://www.math.temple.edu/~cow/
Calculus Book II > 1.Integration > 4.Fundamental Theorem > 1.Differentiation and the Fundamental Theorem
Read the Help, then try problems. Try these: 1, 2, 8, then any you like.  Type x3 as x^3. sqrt(x) or x^.5.
(c) Density method--If the transformation function "flips" things (x1< x2 , but y1 > y2), dy/dx will be negative. Since we care only about area, a positive number, throw away the minus sign = take the absolute value of the derivative.

(d) Caution for either method: If the transformation function is not 1-1, you'll have two (or more?) x's  mapping onto the same y.  Be sure to account for both.  In the Density method,  two fX(x) dx areas mapping to the same place.
    Add them to get fY(y) dy.  (Like you had to add the results in the W = X2 case in the dice above).

Don't panic--we'll be at this for a little while.


Sievers home
 Math300-Sp08/Day8p29.htm 
2pm
4/9/08

This page belongs to Sally Sievers who is solely responsible for its content. Please see our statement of responsibility.