mlpotter Posted October 28, 2011 Share Posted October 28, 2011 Hi all Im currently studying for an HND in mechatronics engineering. Working on an asignments for PLC's Im stuck on a part of one question! Its "what can BCD numbers do that pure Binary or Hexadecimal numbers cannot?" Im struggling like hell to find an answer on the net, can anyone help? Link to comment Share on other sites More sharing options...
Xittenn Posted October 28, 2011 Share Posted October 28, 2011 Wiki's article on Binary Coded Decimal offers up several answers to this question. I don't think there is one thing in particular that BCD does that the others do not that fits this question precisely. The few things that are mentioned however do serve as the main factors for choosing to use this numerical representation for computational purposes. I'm particularly fond of its uses in representing certain values more precisely than other similar methods of numerical representation. Someone with more experience might help so . . . . Link to comment Share on other sites More sharing options...
TonyMcC Posted October 28, 2011 Share Posted October 28, 2011 Hi all Im currently studying for an HND in mechatronics engineering. Working on an asignments for PLC's Im stuck on a part of one question! Its "what can BCD numbers do that pure Binary or Hexadecimal numbers cannot?" Im struggling like hell to find an answer on the net, can anyone help? In the sense that any number system can be used for mathematical operations given suitable hardware and software, one answer is "nothing" (IMO). There can be a benefit in that it can be a help to a human wishing to convert the numbers in this system straight into decimal. And it is easy for a human to convert a decimal number into BCD. http://en.wikipedia.org/wiki/Binary-coded_decimal Link to comment Share on other sites More sharing options...
mlpotter Posted October 28, 2011 Author Share Posted October 28, 2011 thatnsk for the reply ill take a look! Link to comment Share on other sites More sharing options...
Iggy Posted October 28, 2011 Share Posted October 28, 2011 I would guess, although I don't specifically know, the question is looking for this: http://speleotrove.com/decimal/decifaq1.html#inexact It can accurately represent decimal fractions where binary and hex cannot. Link to comment Share on other sites More sharing options...
TonyMcC Posted October 28, 2011 Share Posted October 28, 2011 I would guess, although I don't specifically know, the question is looking for this: http://speleotrove.com/decimal/decifaq1.html#inexact It can accurately represent decimal fractions where binary and hex cannot. Yes - I had overlooked that. Link to comment Share on other sites More sharing options...
mlpotter Posted October 28, 2011 Author Share Posted October 28, 2011 that seems to refre to binary floating point not binary coded decimal! Link to comment Share on other sites More sharing options...
Xittenn Posted October 28, 2011 Share Posted October 28, 2011 .2 is irrational in binary but rational in BCD. This means that computations that require precise decimal representation become less precise with the use of binary as rounding is involved. This extends to floating point mathematics under each respective representation! "precise decimal representation" == common base 10 decimal numbers ie. .2 Link to comment Share on other sites More sharing options...
mlpotter Posted October 28, 2011 Author Share Posted October 28, 2011 is this the same for hex as well? Link to comment Share on other sites More sharing options...
Iggy Posted October 28, 2011 Share Posted October 28, 2011 (edited) .2 is irrational in binary but rational in BCD. This means that computations that require precise decimal representation become less precise with the use of binary as rounding is involved. This extends to floating point mathematics under each respective representation! "precise decimal representation" == common base 10 decimal numbers ie. .2 yeah... that is this the same for hex as well? hex and any base not a multiple of 10 Edited October 28, 2011 by Iggy Link to comment Share on other sites More sharing options...
mlpotter Posted October 28, 2011 Author Share Posted October 28, 2011 sorry could someone put this in slightly more simple terms, its friday night im on late shift til 11 and the brain is fried! Link to comment Share on other sites More sharing options...
Xittenn Posted October 28, 2011 Share Posted October 28, 2011 If it is irrational in binary how would it be rational in hex? Hex codes for binary so if it requires an infinite set of binary decimal places than it will require an infinite set of hex decimal places to code for it . .. . . Link to comment Share on other sites More sharing options...
Iggy Posted October 28, 2011 Share Posted October 28, 2011 sorry could someone put this in slightly more simple terms, its friday night im on late shift til 11 and the brain is fried! the answer to this... Its "what can BCD numbers do that pure Binary or Hexadecimal numbers cannot?" would seem to be that BCD can accurately represent decimal fractions (without rounding) while binary and hex cannot. Do you understand what that means? Link to comment Share on other sites More sharing options...
mlpotter Posted October 28, 2011 Author Share Posted October 28, 2011 yeah thanks! feeling a bit thick tonight! its been a long week, two huge assignments due in Monday as well as work, kids, wife etc! thanks all for the help! Link to comment Share on other sites More sharing options...
Iggy Posted October 28, 2011 Share Posted October 28, 2011 no trouble. Good luck. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now