numbers - finding values of x and y using Octal Base system -


in finding values of x , y, if (x567) + (2yx5) = (71yx) ( in base 8) proceeded under.

i assumed x=abc , y=def , followed.

   (abc+010 def+101 110+abc 111+101)=(111 001 def abc) //adding ()+()=() , equating lhs=rhs.     abc=111-010=101 5 in base 8 , def=001-101 -4     x=5 , y=-4  

now question answer mentioned in book x=4 , y=3.

is above method correct.if so,then what's issue here ??

you can't compare digits beginning significant digit, because don't know carry digit below. digit cannot have negative value.

you can start least significant digit, because there no carry:

7 + 5 = 14 

so x = 4 carry of 1 @ next digit. can rewrite equation to:

(4567) + (2y45) = (71y4) 

now can @ second least significant digit (the carry in mind):

6 + 4 + 1 (carry) = 13 

so y = 3, carry of 1.

the whole equation is:

(4567) + (2345) = (7134) 

which true octal system.


Comments

Popular posts from this blog

python - mat is not a numerical tuple : openCV error -

c# - MSAA finds controls UI Automation doesn't -

wordpress - .htaccess: RewriteRule: bad flag delimiters -