09.12.2012 Views

Concrete mathematics : a foundation for computer science

Concrete mathematics : a foundation for computer science

Concrete mathematics : a foundation for computer science

SHOW MORE
SHOW LESS

Create successful ePaper yourself

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

138 ASYMPTOTICS<br />

Table 438 Asymptotic approximations, valid as n + 00 and z + 0.<br />

5- H, = lnn+y+&-A+& +O (‘). 2<br />

?A!-<br />

(9.28)<br />

. (9.29)<br />

B, = 2[n even](-1 )n,/2 ’ &(l+2pn+3~n+O(4mn)). (9.30)<br />

-4 n(n) = & + ilntj2 + 2!n<br />

-+&$+o(&& (Inni<br />

(9.31)<br />

ez = ‘+r+;+~+~+o(r5i. (9.32)<br />

ln(l+z) = z-f+$-~+0(z5). (9.33)<br />

1<br />

~ = 1 +z+z2+23+t4+0(25).<br />

1-z<br />

(9.34)<br />

(1 +z)a = 1 +cxz+ (;)d+ (;)z3+ (;)24+o(z’l (9.35)<br />

An asymptotic approximation is said to have absolute error 0( g(n)) if<br />

it has the <strong>for</strong>m f(n)+O(g(n)) w h ere f(n) doesn’t involve 0. The approximation<br />

has relative error O(g(n)) if it has the <strong>for</strong>m f(n)(l + O(g(n))) where<br />

f(n) doesn’t involve 0. For example, the approximation <strong>for</strong> H, in Table 438<br />

has absolute error O(n 6); the approximation <strong>for</strong> n! has relative error O(n4).<br />

(The right-hand side of (9.29) doesn’t actually have the required <strong>for</strong>m f(n) x<br />

(1 + O(n “)), but we could rewrite it<br />

dGi (f)n(l + & + & - ‘) (1 + O(nP4))<br />

5 1 840n3<br />

if we wanted to; a similar calculation is the subject of exercise 12.) The (Relative error<br />

absolute error of this approximation is O(n” 3.5e ~-“). Absolute error is related<br />

to the number of correct decimal digits to the right of the decimal point if<br />

is nice <strong>for</strong> taking<br />

reciprocals, because<br />

,,(, + 0(c)) =<br />

the 0 term is ignored; relative error corresponds to the number of correct<br />

“significant figures!’<br />

We can use truncation of power series to prove the general laws<br />

1 +0(E).)<br />

ln(l + O(f(n))) = O(f(n)) , if f(n) < 1; (9.36)<br />

e”‘f’n)l = 1 +O(f(n)) , if f(n) = O(1). (9.37)

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

Saved successfully!

Ooh no, something went wrong!