I posted a related thread, in the same forum regarding matlab, but I want to discuss this here separately.(adsbygoogle = window.adsbygoogle || []).push({});

Few minutes ago I became very confused baffled and surprised at the same time.

consider function [itex]2^{x}[/itex].

Now consider the sum of this function for n iterations.(from 0 to n)

[itex]\sum_{x=0}^n 2^{x}[/itex].

Using my humble knowledge of c++ I found that you need 19 iterations (including zero as iteration) for a number 524287.

so 1+2+4+8+16...+262144=524287

By case, found that this sum is 1 less than the [itex]2^{19}[/itex].

so [itex]524287=2^{19}-1[/itex]

Why? I am not best mathematician you will come across but this i found very interesting.

**Physics Forums | Science Articles, Homework Help, Discussion**

Join Physics Forums Today!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

# Exponential function 2^x-sum.

Loading...

**Physics Forums | Science Articles, Homework Help, Discussion**