CS 109 Lecture 11 April 20th, 2016

Similar documents
1 Probability Density Functions

Continuous Random Variables

Chapter 5 : Continuous Random Variables

Lecture 3 Gaussian Probability Distribution

7 - Continuous random variables

Math 426: Probability Final Exam Practice

Properties of Integrals, Indefinite Integrals. Goals: Definition of the Definite Integral Integral Calculations using Antiderivatives

AP Calculus Multiple Choice: BC Edition Solutions

CS667 Lecture 6: Monte Carlo Integration 02/10/05

Math 8 Winter 2015 Applications of Integration

Review of Probability Distributions. CS1538: Introduction to Simulations

A REVIEW OF CALCULUS CONCEPTS FOR JDEP 384H. Thomas Shores Department of Mathematics University of Nebraska Spring 2007

Chapters 4 & 5 Integrals & Applications

INTRODUCTION TO INTEGRATION

Normal Distribution. Lecture 6: More Binomial Distribution. Properties of the Unit Normal Distribution. Unit Normal Distribution

a < a+ x < a+2 x < < a+n x = b, n A i n f(x i ) x. i=1 i=1

Solution for Assignment 1 : Intro to Probability and Statistics, PAC learning

1 The Riemann Integral

Space Curves. Recall the parametric equations of a curve in xy-plane and compare them with parametric equations of a curve in space.

5 Probability densities

Problem. Statement. variable Y. Method: Step 1: Step 2: y d dy. Find F ( Step 3: Find f = Y. Solution: Assume

63. Representation of functions as power series Consider a power series. ( 1) n x 2n for all 1 < x < 1

Definite integral. Mathematics FRDIS MENDELU

Continuous Joint Distributions Chris Piech CS109, Stanford University

Pi evaluation. Monte Carlo integration

Problem Set 9. Figure 1: Diagram. This picture is a rough sketch of the 4 parabolas that give us the area that we need to find. The equations are:

MTH 122 Fall 2008 Essex County College Division of Mathematics Handout Version 10 1 October 14, 2008

Definite integral. Mathematics FRDIS MENDELU. Simona Fišnarová (Mendel University) Definite integral MENDELU 1 / 30

Unit #9 : Definite Integral Properties; Fundamental Theorem of Calculus

8 Laplace s Method and Local Limit Theorems

How do we solve these things, especially when they get complicated? How do we know when a system has a solution, and when is it unique?

MATH 144: Business Calculus Final Review

Section 6.1 INTRO to LAPLACE TRANSFORMS

CHM Physical Chemistry I Chapter 1 - Supplementary Material

We partition C into n small arcs by forming a partition of [a, b] by picking s i as follows: a = s 0 < s 1 < < s n = b.

Math 113 Fall Final Exam Review. 2. Applications of Integration Chapter 6 including sections and section 6.8

X Z Y Table 1: Possibles values for Y = XZ. 1, p

Tutorial 4. b a. h(f) = a b a ln 1. b a dx = ln(b a) nats = log(b a) bits. = ln λ + 1 nats. = log e λ bits. = ln 1 2 ln λ + 1. nats. = ln 2e. bits.

Improper Integrals, and Differential Equations

NUMERICAL INTEGRATION. The inverse process to differentiation in calculus is integration. Mathematically, integration is represented by.

The Regulated and Riemann Integrals

A. Limits - L Hopital s Rule ( ) How to find it: Try and find limits by traditional methods (plugging in). If you get 0 0 or!!, apply C.! 1 6 C.

The Fundamental Theorem of Calculus. The Total Change Theorem and the Area Under a Curve.

Math 116 Calculus II

How can we approximate the area of a region in the plane? What is an interpretation of the area under the graph of a velocity function?

Math 31S. Rumbos Fall Solutions to Assignment #16

Definition of Continuity: The function f(x) is continuous at x = a if f(a) exists and lim

Expectation and Variance

The Fundamental Theorem of Calculus

Chapter 0. What is the Lebesgue integral about?

Lesson 1: Quadratic Equations

Math 231E, Lecture 33. Parametric Calculus

Problem Set 3 Solutions

Continuous Random Variables Class 5, Jeremy Orloff and Jonathan Bloom

12 TRANSFORMING BIVARIATE DENSITY FUNCTIONS

The final exam will take place on Friday May 11th from 8am 11am in Evans room 60.

First midterm topics Second midterm topics End of quarter topics. Math 3B Review. Steve. 18 March 2009

Summary: Method of Separation of Variables

MATH SS124 Sec 39 Concepts summary with examples

Lecture 1: Introduction to integration theory and bounded variation

Monte Carlo method in solving numerical integration and differential equation

4.1. Probability Density Functions

Calculus in R. Chapter Di erentiation

Math 113 Exam 1-Review

Section 6: Area, Volume, and Average Value

7.2 The Definite Integral

We divide the interval [a, b] into subintervals of equal length x = b a n

Numerical integration

Numerical Analysis: Trapezoidal and Simpson s Rule

The First Fundamental Theorem of Calculus. If f(x) is continuous on [a, b] and F (x) is any antiderivative. f(x) dx = F (b) F (a).

4 7x =250; 5 3x =500; Read section 3.3, 3.4 Announcements: Bell Ringer: Use your calculator to solve

Topic 1 Notes Jeremy Orloff

Review of basic calculus

Lecture 21: Order statistics

Math 1B, lecture 4: Error bounds for numerical methods

SUMMER KNOWHOW STUDY AND LEARNING CENTRE

Math Calculus with Analytic Geometry II

Definite Integrals. The area under a curve can be approximated by adding up the areas of rectangles = 1 1 +

MATH , Calculus 2, Fall 2018

dt. However, we might also be curious about dy

p(t) dt + i 1 re it ireit dt =

Overview of Calculus I

Session Trimester 2. Module Code: MATH08001 MATHEMATICS FOR DESIGN

Method: Step 1: Step 2: Find f. Step 3: = Y dy. Solution: 0, ( ) 0, y. Assume

Big idea in Calculus: approximation

Taylor Polynomial Inequalities

P 3 (x) = f(0) + f (0)x + f (0) 2. x 2 + f (0) . In the problem set, you are asked to show, in general, the n th order term is a n = f (n) (0)

ODE: Existence and Uniqueness of a Solution

n f(x i ) x. i=1 In section 4.2, we defined the definite integral of f from x = a to x = b as n f(x i ) x; f(x) dx = lim i=1

Math 116 Final Exam April 26, 2013

Continuous Random Variables

Chapter 6 Notes, Larson/Hostetler 3e

Math 135, Spring 2012: HW 7

Thomas Whitham Sixth Form

13.4 Work done by Constant Forces

Lecture 3. Limits of Functions and Continuity

Math 100 Review Sheet

The Fundamental Theorem of Calculus, Particle Motion, and Average Value

4.4 Areas, Integrals and Antiderivatives

Orthogonal Polynomials

Transcription:

CS 09 Lecture April 0th, 06

Four Prototypicl Trjectories Review

The Norml Distribution is Norml Rndom Vrible: ~ Nµ, σ Probbility Density Function PDF: f x e σ π E[ ] µ Vr σ x µ / σ Also clled Gussin Note: fx is symmetric bout µ where < x f x < µ x

Simplicity is Humble µ probbility σ vlue * A Gussin mximizes entropy for given men nd vrince

Antomy of beutiful eqution N µ, exponentil the distnce to the men fx p e x µ probbility density t x constnt sigm shows up twice

And here we re N µ, CDF of Stndrd Norml: A function tht hs been solved for numericlly F x x µ The cumultive density function CDF of ny norml Tble of Φz vlues in textbook, p. 0 nd hndout

Symmetry of Phi ɸ- ɸ ɸ- µ 0 ɸ -

Intervl of Phi µ 0 ɸc ɸd c d

Intervl of Phi ɸd - ɸc µ 0 ɸc ɸd c d

Four Prototypicl Trjectories Gret in clss questions

Four Prototypicl Trjectories 68% rule only for Gussins?

68% Rule? Wht is the probbility tht norml vrible Nµ, hs vlue within one stndrd devition of its men? µ µ µ µ + µ P µ <<µ+ P < < P <Z< [ ] [0.843] 0.683 Only pplies to norml

68% Rule? Counter exmple: Uniform Uni, Vr p Vr p P µ <<µ+ pple p p pple p 0.58

Four Prototypicl Trjectories How do you smple from Gussin?

How Does Computer Smple Norml? Inverse Trnsform Smpling pick uniform number y between 0, CDF of the Stndrd Norml x -5 0 Find the x such tht x y 5 Further reding: Box Muller trnsform

Four Prototypicl Trjectories Where we left off

Norml Approximtes Binomil There is deep reson for the Binomil/Norml pproximtion

Stnford Admissions Stnford ccepts 480 students Ech ccepted student hs 68% chnce of ttending # students who will ttend. ~ Bin480, 0.68 Wht is P > 745? np 686.4 np p 539.65 np p 3.3 Use Norml pproximtion: Y ~ N686.4, 539.65 P Y > 745.5 P P > 745 P Y > 745.5 Y 686.4 745.5 686.4 > Φ.54 0. 0055 3.3 3.3 Using Binomil: P > 745 0.0053

Chnges in Stnford Admissions Stnford Dily, Mrch 8, 04 Clss of 08 Admit Rtes Lowest in University History by Alex Zivkovic Fewer students were dmitted to the Clss of 08 thn the Clss of 07, due to the increse in Stnford s yield rte which hs incresed over 5 percent in the pst four yers, ccording to Colleen Lim M.A. 80, Director of Undergrdute Admission. 68% 0 yers go 80% lst yer

Four Prototypicl Trjectories Next distribution: Exponentil

Exponentil Rndom Vrible is n Exponentil RV: ~ Expλ Rte: λ > 0 Probbility Density Function PDF: λe f x 0 E[ ] Cumultive distribution function CDF, F P x: Represents time until some event o λ Vr λx λ if x 0 where < x < if x < 0 λx F x e where x f x x Erthquke, request to web server, end cell phone contrct, etc. 0

time until some event occurs ~ Expλ Wht is P > s + t > s? After initil period of time s, P > t for witing nother t units of time until event is sme s t strt Memoryless no impct from preceding period s nd s P t s P s P s t s P s t s P > + > > > + > > + > t P t F e e e s F t s F s P t s P t s t s > + > + > + λ λ λ So, t P s t s P > > + > Exponentil is Memoryless

Four Prototypicl Trjectories E[] nd Vr for exponentil

A Little Clculus Review Product rule for derivtives: d u v Derivtive nd integrl of exponentil: d e dx du dx Integrtion by prts: u e u du v + u dv e u du e u d u v u v v du + u dv u dv u v v du

Compute n-th moment of Exponentil distribution Step : don t pnic, think hppy thoughts, recll... Step : find u nd v nd du nd dv: Step 3: substitute.k.. plug nd chug 0 ] [ dx e x E x n n λ λ x n e v x u λ dx e dv dx nx du n λx λ + dx e nx e x du v v u dx e x dv u x n x n x n λ λ λ λ ] [ 0 ] [ 0 + + n x n x n x n n E dx e x dx e nx e x E n n λ λ λ λ λ λ,... ] [ ] [ so, [] ] [ cse : Bse 0, λ λ λ λ E E E E And Now, Clculus Prctice

Visits to Website Sy visitor to your web site leves fter minutes On verge, visitors leve site fter 5 minutes Assume length of sty is Exponentilly distributed ~ Expλ /5, since E[] /λ 5 Wht is P > 0? P > 0 F0 e λ0 e 0.353 Wht is P0 < < 0? P0 < < 0 F0 F0 e 4 e 0.70

Replcing Your Lptop # hours of use until your lptop dies On verge, lptops die fter 5000 hours of use ~ Expλ /5000, since E[] /λ 5000 P You use your lptop 5 hours/dy. Wht is Pyour lptop lsts 4 yers? Tht is: P > 53654 7300 > 7300 F7300 e 7300/ 5000 e.46 0.3 Better pln hed... especilly if you re coterming: P > 95 F95 e.85 0.6 5yer pln P > 0950 F0950 e.9 0.9 6yer pln

Continuous Rndom Vribles Uniform Rndom Vrible Uni, All vlues of x between lph nd bet re eqully likely. Norml Rndom Vrible N µ, Ak Gussin. Defined by men nd vrince. Goldilocks distribution. Exponentil Rndom Vrible Exp Time until n event hppens. Prmeterized by lmbd sme s Poisson. Alph Bet Rndom Vrible How mysterious nd curious. You must wit few clsses J.

Four Prototypicl Trjectories Joint Distributions

Four Prototypicl Trjectories Events occur with other events

Discrete Joint Mss Function For two discrete rndom vribles nd Y, the Joint Probbility Mss Function is: p Y Mrginl distributions:,, b P, Y b p P p, Y, y Exmple: vlue of die D, Y vlue of die D y p b P Y b p x, b Y, Y x 6 6 p, Y, y y y 36 P 6

Probbility Tble Sttes ll possible outcomes with severl discrete vribles Often is not prmetric If #vribles is >, you cn hve probbility tble, but you cn t drw it on slide All vlues of A All vlues of B b PA, B b Remember, mens nd Every outcome flls into bucket

It s Complicted Demo Go to this URL: https://goo.gl/znrsqd

A Computer or Three In Every House Consider households in Silicon Vlley A household hs C computers: C Mcs + Y PCs Assume ech computer eqully likely to be Mc or PC Y 0 3 p Y y P C c 0.6 0.4 0.8 0.3 c 0 c c c 3 0 0.6 0.? 0.04 0. 0.4 0. 0 0.07 0. 0 0 3 0.04 0 0 0 p x

A Computer or Three In Every House Consider households in Silicon Vlley A household hs C computers: C Mcs + Y PCs Assume ech computer eqully likely to be Mc or PC Y 0 3 p Y y P C c 0.6 0.4 0.8 0.3 c 0 c c c 3 0 0.6 0. 0.07 0.04 0. 0.4 0. 0 0.07 0. 0 0 3 0.04 0 0 0 p x

A Computer or Three In Every House Consider households in Silicon Vlley A household hs C computers: C Mcs + Y PCs Assume ech computer eqully likely to be Mc or PC Y 0 3 p Y y P C c 0.6 0.4 0.8 0.3 c 0 c c c 3 0 0.6 0. 0.07 0.04 0.39 0. 0.4 0. 0 0.38 0.07 0. 0 0 0.9 3 0.04 0 0 0 0.04 p x 0.39 0.38 0.9 0.04.00 Mrginl distributions

Joint This is joint A joint is not mthemticin It did not strt doing mthemtics t n erly ge It is not the reson we hve joint distributions And, no, Chrlie Sheen does not look like joint o o But he does hve them He lso hs joint custody of his children with Denise Richrds

Four Prototypicl Trjectories Wht bout the continuous world?

Jointly Continuous Rndom vribles nd Y, re Jointly Continuous if there exists PDF f,y x, y defined over < x, y < such tht: P <, b < Y b f, b b Y x, y dy dx Let s look t one:

Jointly Continuous < <,, P, b b Y dx dy y x f b Y b b b f,y x, y x y

Cumultive Density Function CDF: Mrginl density functions: b Y Y dx dy y x f b F,,,,,,,, b F b f Y Y b dy y f f Y,, dx b x f b f Y Y,, Jointly Continuous

For two continuous rndom vribles nd Y, the Joint Cumultive Probbility Distribution is: Mrginl distributions: < < b b Y P b F b F Y, where,,,,,, P, < F Y P F Y,, P, b F b Y b Y P b F Y Y < Continuous Joint Distribution Functions

Joint Drt Distribution 900 y 0 x 900

Drts! y -Pixel Mrginl x Y-Pixel Mrginl N 900, 900 Y N 900 3, 900 5

Multiple Integrls Without Ters Let nd Y be two continuous rndom vribles where 0 nd 0 Y We wnt to integrte gx,y xy w.r.t. nd Y: First, do innermost integrl tret y s constnt: xy dx dy xy dx dy 0 y 0 x 0 y 0 x 0 y 0 y 0 x y dy y dy Then, evlute remining single integrl: y 0 y dy y 4 0 0

Computing Joint Probbilities Let F,Y x, y be joint CDF for nd Y P >, Y > b P >, Y > bc c c P > Y > b P Y b P + PY b P, Y b F FY b + F,Y, b

,,,,, P b F b F b F b F b Y b + < < b b The Generl Rule Given Joint CDF Let F,Y x, y be joint CDF for nd Y

Y is non-negtive continuous rndom vrible Probbility Density Function: f Y y Alredy knew tht: But, did you know tht:?!? Anlogously, in the discrete cse, where,,, n dy y f y Y E Y ] [ dy y P Y Y E > 0 ] [ n i i P E ] [ Lovely Lemm

In the discrete cse, where,,, n E[ ] How this lemm ws mde n i n P i i P i Ech row is n expnsion of P + P + P 3 + + P n + P + P 3 + + P n + P 3 + + P n +... P n P + P + + np n E[]

Four Prototypicl Trjectories Life gives you lemms, mke lemmnde!

Disk surfce is circle of rdius R f, Y Imperfections on Disk A single point imperfection uniformly distributed on disk if x + y R x, y π R where < x,y < 0 if x + y > R Z f x f,y x, ydy Z Zx R dy +y ppler Z p Z p R x R p p R p R x R x dy pple Only integrte over the support rnge Mrginl of Y is the sme by symmetry

Disk surfce is circle of rdius R Imperfections on Disk A single point imperfection uniformly distributed on disk Distnce to origin: D + Y Wht is E[D]? R Z Z R E[D] Z 0 pple pple 0 Z R π π R P D P D >d R d 3 R 3R 0 Z R 3 Z Z R 0 R P Dpplepple d Becuse of eqully likely outcomes