06.03.2017 Views

Mathematics for Computer Science

e9ck2Ar

e9ck2Ar

SHOW MORE
SHOW LESS

Create successful ePaper yourself

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

“mcs” — 2017/3/3 — 11:21 — page 579 — #587<br />

14.7. Asymptotic Notation 579<br />

You’ve seen this neat trick <strong>for</strong> evaluating a geometric sum:<br />

S D 1 C z C z 2 C : : : C z n<br />

zS D z C z 2 C : : : C z n C z nC1<br />

S zS D 1 z nC1<br />

znC1<br />

S D 1<br />

1 z<br />

(where z ¤ 1/<br />

Use the same approach to find a closed-<strong>for</strong>m expression <strong>for</strong> this sum:<br />

T D 1z C 2z 2 C 3z 3 C : : : C nz n<br />

Problem 14.3.<br />

Sammy the Shark is a financial service provider who offers loans on the following<br />

terms.<br />

Sammy loans a client m dollars in the morning. This puts the client m dollars<br />

in debt to Sammy.<br />

Each evening, Sammy first charges a service fee which increases the client’s<br />

debt by f dollars, and then Sammy charges interest, which multiplies the<br />

debt by a factor of p. For example, Sammy might charge a “modest” ten<br />

cent service fee and 1% interest rate per day, and then f would be 0:1 and p<br />

would be 1:01.<br />

(a) What is the client’s debt at the end of the first day?<br />

(b) What is the client’s debt at the end of the second day?<br />

(c) Write a <strong>for</strong>mula <strong>for</strong> the client’s debt after d days and find an equivalent closed<br />

<strong>for</strong>m.<br />

(d) If you borrowed $10 from Sammy <strong>for</strong> a year, how much would you owe him?<br />

Homework Problems<br />

Problem 14.4.<br />

Is a Harvard degree really worth more than an MIT degree? Let us say that a person<br />

with a Harvard degree starts with $40,000 and gets a $20,000 raise every year after<br />

graduation, whereas a person with an MIT degree starts with $30,000, but gets a<br />

20% raise every year. Assume inflation is a fixed 8% every year. That is, $1.08 a<br />

year from now is worth $1.00 today.

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

Saved successfully!

Ooh no, something went wrong!