To convert a given numbers to a binary system, we will use the Euclidean algorithm.
(more information: https://en.wikipedia.org/wiki/Euclidean_division)
More specifically, we will divide by 2 and we will be interested in the remainders.
Note : With a separate picture, I will show how this division looks like if you do it "in a column".
1) "479"
1 case : "479_{10}\\to x_2"
"479\\div 2=239\\left(remainder\\,\\,\\,\\boxed{1}\\right)\\\\[0.3cm]\n239\\div 2=119\\left(remainder\\,\\,\\,\\boxed{1}\\right)\\\\[0.3cm]\n119\\div 2=59\\left(remainder\\,\\,\\,\\boxed{1}\\right)\\\\[0.3cm]\n59\\div 2=29\\left(remainder\\,\\,\\,\\boxed{1}\\right)\\\\[0.3cm]\n29\\div 2=14\\left(remainder\\,\\,\\,\\boxed{1}\\right)\\\\[0.3cm]\n14\\div 2=7\\left(remainder\\,\\,\\,\\boxed{0}\\right)\\\\[0.3cm]\n7\\div 2=3\\left(remainder\\,\\,\\,\\boxed{1}\\right)\\\\[0.3cm]\n3\\div 2=\\boxed{1}\\left(remainder\\,\\,\\,\\boxed{1}\\right)\\\\[0.3cm]"It remains to write down the results obtained: writes down the numbers in reverse order, that is, it starts with the quotient from the last step, and then writes down only the remainders.
Conclusion,
"\\boxed{479_{10}\\to(111011111)_2}"
When converting from a binary number to a decimal number, we do "as if the opposite": we multiply "1" or "0" by "2" to the degree that corresponds to the (position-1) of the specified "0" or "1".
2 case : "(111011111)_2\\to x_{10}"
"(111011111)_2=1\\cdot 2^{9-1}+1\\cdot2^{8-1}+1\\cdot2^{7-1}+0\\cdot2^{6-1}+1\\cdot2^{5-1}+\\\\[0.3cm]\n+1\\cdot2^{4-1}+1\\cdot2^{3-1}+1\\cdot2^{2-1}+1\\cdot2^{1-1}=\\\\[0.3cm]\n=2^8+2^7+2^6+2^4+0+2^3+2^2+2^1+2^0=\\\\[0.3cm]\n=256+128+64+16+8+4+2+1=\\\\[0.3cm]\n=384+80+15=464+15=479"
2) "8735"
1 case : "8735_{10}\\to x_2"
"8735\\div 2=4367\\left(remainder\\,\\,\\,\\boxed{1}\\right)\\\\[0.3cm]\n4367\\div 2=2183\\left(remainder\\,\\,\\,\\boxed{1}\\right)\\\\[0.3cm]\n2183\\div 2=1091\\left(remainder\\,\\,\\,\\boxed{1}\\right)\\\\[0.3cm]\n1091\\div 2=545\\left(remainder\\,\\,\\,\\boxed{1}\\right)\\\\[0.3cm]\n545\\div 2=272\\left(remainder\\,\\,\\,\\boxed{1}\\right)\\\\[0.3cm]\n272\\div 2=136\\left(remainder\\,\\,\\,\\boxed{0}\\right)\\\\[0.3cm]\n136\\div 2=68\\left(remainder\\,\\,\\,\\boxed{0}\\right)\\\\[0.3cm]\n68\\div 2=34\\left(remainder\\,\\,\\,\\boxed{0}\\right)\\\\[0.3cm]\n34\\div 2=17\\left(remainder\\,\\,\\,\\boxed{0}\\right)\\\\[0.3cm]\n17\\div 2=8\\left(remainder\\,\\,\\,\\boxed{1}\\right)\\\\[0.3cm]\n8\\div 2=4\\left(remainder\\,\\,\\,\\boxed{0}\\right)\\\\[0.3cm]\n4\\div 2=2\\left(remainder\\,\\,\\,\\boxed{0}\\right)\\\\[0.3cm]\n2\\div 2=\\boxed{1}\\left(remainder\\,\\,\\,\\boxed{0}\\right)\\\\[0.3cm]"
Conclison,
"8735_{10}\\to(01001000011111)_2"
Note : the first "0" is not taken into account.
"\\boxed{8735_{10}\\to(1001000011111)_2}"
2 case : "(1001000011111)_2\\to x_{10}"
"(1001000011111)_2=1\\cdot2^{13-}+1\\cdot2^{10-1}+1\\cdot2^{5-1}+\\\\[0.3cm]\n+1\\cdot2^{4-1}+1\\cdot2^{3-1}+1\\cdot2^{2-1}+1\\cdot2^{1-1}=\\\\[0.3cm]\n=2^{13}+2^9+2^4+2^3+2^2+2^1+2^0=\\\\[0.3cm]\n=8192+512+16+8+4+2+1=8735"
Comments
Leave a comment