# Math Problem

#### BloodySurgeon

##### Full Member
Moderator Emeritus
10+ Year Member
Does anyone know a quick or easy formula for 2^n? Without a calculator I need to make certain calculations like 2^32 etc. and the technique I have takes too long. This post will prob. be moved but don't know any math forum or people to ask and im desperate.

#### TleilaxuMD

##### Membership Revoked
Removed
10+ Year Member
this is not a homework forum.

##### Membership Revoked
Removed
10+ Year Member
i dont know any technicques, try may be www.physicsforums.com

but 2^32=(2^8)^4, which is 256 squared twice, which you could do on a piece of paper. while something like 2^31 or 2^33 would be derived 2^32 or similar idea. but i'm sure there are some clever ways to avoid this...

also 2^n could be approximated by taylor's formula, i think it's summation of f'(c)*(x-c)^n/n! where c would be the number to which you want to take the exponent, but this formula doesnt work here because the function doesnt converge. it would've worked much better for things like logx or sinx...

#### Sol Rosenberg

##### Long Live the New Flesh!
15+ Year Member
Can you elaborate more about the real problem that you are trying to solve? I'd bet dollars to doughnuts that you don't actually have to evaluate 2 to that large a power. There's no way of doing this gracefully without a calculator (though when you work with powers of 2 a lot, you tend to memorize certain ones, like 2^16 = 65536, so 2^32 = 65536^2)

#### sejin8642

##### Full Member
10+ Year Member
5+ Year Member
Does anyone know a quick or easy formula for 2^n? Without a calculator I need to make certain calculations like 2^32 etc. and the technique I have takes too long. This post will prob. be moved but don't know any math forum or people to ask and im desperate.

I don't understand what you are asking for...what does "formula for 2^n" mean? You mean you want to know how the graph looks like or do you just want to find a value like 2^45 really quickly?

#### Disinence2

##### Emergency Medicine
10+ Year Member
7+ Year Member
I don't understand what you are asking for...what does "formula for 2^n" mean? You mean you want to know how the graph looks like or do you just want to find a value like 2^45 really quickly?

He wants a way to find the answer without a calculator. The real question is why can't you just use a calculator! My cell phone will do this sort of thing.

#### TheRealDrDorian

##### Dr. Acula
10+ Year Member
Does anyone know a quick or easy formula for 2^n? Without a calculator I need to make certain calculations like 2^32 etc. and the technique I have takes too long. This post will prob. be moved but don't know any math forum or people to ask and im desperate.

No offense, but if you can't find the answer to this on google, then you shouldn't be making a new thread on SDN for this.

#### BloodySurgeon

##### Full Member
Moderator Emeritus
10+ Year Member
Its a test for a license in networking and I have to do some sort of programming with binary coding etc. I will need to work with numbers high numbers but will not be permitted a calculator and will be rigorously timed. If I can find a quick way to do 2^n then I can solve any problem in a minute or less (which usually takes me around 5 mins). The methods listed earlier is pretty much what I use to do, however, figuring 256 x 256 x .... takes too long. I actually had to memorize a few of them like 2^32 is 4,294,967 296 and that worked out fine but prone for mistake for stressful test day.

#### NickRiviera

##### MS-Never
10+ Year Member
Memorize your 2^n's like engineers have to

##### Membership Revoked
Removed
10+ Year Member
Its a test for a license in networking and I have to do some sort of programming with binary coding etc. I will need to work with numbers high numbers but will not be permitted a calculator and will be rigorously timed. If I can find a quick way to do 2^n then I can solve any problem in a minute or less (which usually takes me around 5 mins). The methods listed earlier is pretty much what I use to do, however, figuring 256 x 256 x .... takes too long. I actually had to memorize a few of them like 2^32 is 4,294,967 296 and that worked out fine but prone for mistake for stressful test day.

if the test is multiple choice, i would try to look for tricks that might let you decide the total number of digits in the product, what the last digit is, 2nd to last, etc.
you know that to do this on paper, you add the sum of 2*256, 5*256, but each product is placed 1 spot to the left,etc.
1)total # of digits: if you start with 256*256, the 1st of the 5 digit product will consist of 2*256->5, but also of 5*256->1, so the 1st digit will be 6. you may try to work out the 2nd digit as well: it will consist of 2*256->1, 5*256->2(5*2=0, add 2 from the 5*5), and 6*256->1, so the 2nd digit is 1+2+1=4. now from 64*** x 64*** you may get that 6x64 contributes 4 to the 1st digit, and the other digits do not contribute because 6>4. you may notice that when you started with 3 digits(256), the product had 5(or 2n-1) digits, because the first digit did not produce a 10. in the 2nd example when you start with 64***, the product would have 10(or 2n) digits, because 6*6>10

2)it is much easier to get the last digit of your products, but rarely useful. 256^n will always have 6 as it's last digit, just because 6*6 produces 6 as the last digit. but if you started with some number that ended in 4, for example 254*254, then the product ends in 6, and if you keep squaring it, you will again be stuck with 6.

#### green453

##### Full Member
10+ Year Member
I shouldn't be telling you had to do this, because this is SDN, not a CS help forum, and I didn't even read your entire post (because I'm lazy), but what I think you want to do is this:

Don't get out of binary until you have to. Do everything in binary and as a last step, convert to hex (4 bits = 1 nybble = 1 hex digit, right?) and then convert to binary. If you have a lot of trouble changing bases from hex to dec then you are probably screwed either way. But, that is how I would do it.

#### johnnydrama

##### I'm no Superman
15+ Year Member
2^10 = 1024. 2^32 = (2^10)^3 * 4 ~ 4 billion (actual answer 4.3 billion).