08.10.2016 Views

Foundations of Data Science

2dLYwbK

2dLYwbK

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Thus, u n = (n − 1) u n−2 .<br />

The moment generating function is given by<br />

∞∑ u n s n ∞∑ n! s n<br />

g (s) = =<br />

n! 2 n 2 n! n! = ∑ ∞<br />

2<br />

n=0<br />

n=0<br />

n even<br />

i=0<br />

s 2i ∞<br />

2 i i! = ∑<br />

For the general Gaussian, the moment generating function is<br />

(<br />

g (s) = e su+ σ<br />

2<br />

2<br />

i=0<br />

1<br />

i!<br />

( ) s<br />

2 i<br />

= e s2 2 .<br />

Thus, given two independent Gaussians with mean u 1 and u 2 and variances σ 2 1 and σ 2 2,<br />

the product <strong>of</strong> their moment generating functions is<br />

)<br />

s 2<br />

e s(u 1+u 2 )+(σ 2 1 +σ2 2)s 2 ,<br />

the moment generating function for a Gaussian with mean u 1 + u 2 and variance σ 2 1 + σ 2 2.<br />

Thus, the convolution <strong>of</strong> two Gaussians is a Gaussian and the sum <strong>of</strong> two random variables<br />

that are both Gaussian is a Gaussian random variable.<br />

2<br />

12.9 Miscellaneous<br />

12.9.1 Lagrange multipliers<br />

Lagrange multipliers are used to convert a constrained optimization problem into an unconstrained<br />

optimization. Suppose we wished to maximize a function f(x) subject to a<br />

constraint g(x) = c. The value <strong>of</strong> f(x) along the constraint g(x) = c might increase for<br />

a while and then start to decrease. At the point where f(x) stops increasing and starts<br />

to decrease, the contour line for f(x) is tangent to the curve <strong>of</strong> the constraint g(x) = c.<br />

Stated another way the gradient <strong>of</strong> f(x) and the gradient <strong>of</strong> g(x) are parallel.<br />

By introducing a new variable λ we can express the condition by ∇ x f = λ∇ x g and<br />

g = c. These two conditions hold if and only if<br />

∇ xλ<br />

(<br />

f (x) + λ (g (x) − c)<br />

)<br />

= 0<br />

The partial with respect to λ establishes that g(x) = c. We have converted the constrained<br />

optimization problem in x to an unconstrained problem with variables x and λ.<br />

12.9.2 Finite Fields<br />

For a prime p and integer n there is a unique finite field with p n elements. In Section<br />

4.6 we used the field GF(2 n ), which consists <strong>of</strong> polynomials <strong>of</strong> degree less than n with<br />

coefficients over the field GF(2). In GF(2 8 )<br />

(x 7 + x 5 + x) + (x 6 + x 5 + x 4 ) = x 7 + x 6 = x 4 = x<br />

423

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!