Question: Let k P N . Analytically, ( 1 + 2 ^ - k ) - 1 = 2 ^ - k . Numerically, however, it

Let k P N. Analytically, (1+2^-k)-1=2^-k. Numerically, however,
it is not true for sufficiently large k due to roundoff errors. For instance,
>>(1+2^(-100))-1
ans =0
Using a while-loop, find the smallest natural number k such that (1+2^(-k))-1 evaluates
to 0 in MATLAB. Then evaluate 2k for the value of k found.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!