TranceAddict Forums

TranceAddict Forums (www.tranceaddict.com/forums)
- Chill Out Room
-- Nerds wanted - binary help


Posted by Michael19 on Aug-28-2005 14:46:

Exclamation Nerds wanted - binary help

right so lads. Need help with binary addition etc.


i know how to work normal binary. One thing i dont know is ones and twos complement subtraction though.


say the question is 110101 - 011011 base 2.


I change 011011 to 100100 dont i? is that all i need to do, just work it out then or is there more?


Need to know how to convert from octal and hexadecimal to binary aswell.

e.g
123(base 8) to octal and hexi - how do i do it?


any help would be brilliant.

cheers.


Posted by Sunsnail on Aug-28-2005 19:34:

its like
1 10 11 100 101 110 111 1000 1001 1010 1011 1100 1101 1111 10000 10001 10010 10011 10100 10101 10110 10111 11000 11001 11010 11011 11100 11101 11110 11111


Posted by Boomer187 on Aug-28-2005 19:38:

http://www.phys.ualberta.ca/~gingri...es/node119.html


???



maybe google it?


Posted by Resnick on Aug-28-2005 19:46:

Re: Nerds wanted - binary help

quote:
Originally posted by Michael19
right so lads. Need help with binary addition etc.


i know how to work normal binary. One thing i dont know is ones and twos complement subtraction though.


say the question is 110101 - 011011 base 2.


I change 011011 to 100100 dont i? is that all i need to do, just work it out then or is there more?


Need to know how to convert from octal and hexadecimal to binary aswell.

e.g
123(base 8) to octal and hexi - how do i do it?



any help would be brilliant.

cheers.


well base 8 is octal...i think u meant, from octal to binary/hex?

its prob easier to just convert to binary, then go to either octal or hex, so in hex, u group every 4 numbers, and in octal u group every 3

so 10101110 the last digit in octal is 6(110), and in hex its E(1110), and u just move along and do the whole thing so hex = AE, octal = 256

if u do octal - hex or other way, just convert to binary first

so 123 = 001 010 011 in octal, and = 0001 0010 0011 in hex,

ones complement as i recall, u just flip all digits, so 1101 = 0010

in 2's complement u do the same thing, except add 1 at the end

so 1110 = 0001 + 1 = 0010

and then u just add them together (but that might be wrong, thers some rules about the last digit or some crap, i dont remember )


Posted by THE_Chris on Aug-28-2005 19:53:

Convert to base 10, subtract, then convert back to base 2.


Posted by Michael19 on Aug-28-2005 20:18:

Re: Re: Nerds wanted - binary help

quote:
Originally posted by Resnick


if u do octal - hex or other way, just convert to binary first

so 123 = 001 010 011 in octal, and = 0001 0010 0011 in hex,




the question will ask me to convert a octal number binary.


how do i work out that 1=001 2 =010 3 =011 etc etc?



dont understand chris


Posted by Goashem on Aug-28-2005 20:44:

use two's complement, switch all the 1s to 0s and 0s to 1 and add a 1. and then add the numbers.


Posted by Chris d(-_-)b on Aug-28-2005 21:04:

1o1


Posted by Cloudburst on Aug-28-2005 21:41:

quote:
Originally posted by Goashem
use two's complement, switch all the 1s to 0s and 0s to 1 and add a 1. and then add the numbers.


That's how you do it.



Powered by: vBulletin
Copyright © 2000-2021, Jelsoft Enterprises Ltd.