COMPUTER SCIENCE CAFÉ
  • WORKBOOKS
  • BLOCKY GAMES
  • GCSE
    • CAMBRIDGE GCSE
  • IB
  • A LEVEL
  • LEARN TO CODE
  • ROBOTICS ENGINEERING
  • MORE
    • CLASS PROJECTS
    • Classroom Discussions
    • Useful Links
    • SUBSCRIBE
    • ABOUT US
    • CONTACT US
    • PRIVACY POLICY
  • WORKBOOKS
  • BLOCKY GAMES
  • GCSE
    • CAMBRIDGE GCSE
  • IB
  • A LEVEL
  • LEARN TO CODE
  • ROBOTICS ENGINEERING
  • MORE
    • CLASS PROJECTS
    • Classroom Discussions
    • Useful Links
    • SUBSCRIBE
    • ABOUT US
    • CONTACT US
    • PRIVACY POLICY
DATA REPRESENTATION
1.3 BINARY CODED DECIMAL
Picture
WHAT IS BINARY CODED DECIMAL ?
Binary coded decimal is another system used to represent numbers. Binary coded decimal is great for number systems such as those on a digital displays such as a clock. The binary coded decimal system also allows use to represent the calculation of decimal numbers.

The main principle of BCD is that 4 bits (1 nibble) are used to represent a single character/number. This means that a single BCD nibble can only represent 0 - 9. Because BCD can only represent 1 digit, anything larger than 9 would be more than 1 digit long therefore would need to be represented with multiple BCD nibbles. The below chart shows 94 in BCD.
Picture
A common error is to try and represent numbers greater than 9 using the 4 bits. Remember the key rule is BCD can only represent a single digit with one nibble(4 bits). For example:
194 in Binary = 11000010
194 in HEX = C2
194 in BCD = 0001 1001 0100
ADDITION WITH BCD (A-LEVEL ONLY)
Because a single BCD nibble can only represent 1 digit 0 to 9, but the nibble itself could represent up to 15. This presents a slight issue that if you add 1 to 9 the representation will not carry over to the Tens column, therefore when doing addition an intermediate test is needed to see if a carry over is needed. This methods adds 6 to each addition to check if a carry over has occurred. Check out the example below, adding 1 to 9 in BCD.
Picture
As can be seen in the calculation error above, the BCD value of 10 is not possible as a single BCD representation can only represent 1 - 9. We can fix this error by adding 6 to the result to test if a carry over is needed, this may seem strange but this is how it works.
Picture
The calculations above show how adding 6 to the BCD addition to test for if a carryover is needed. If the carryover is not needed then the test calculation is discarded as can be seen in the example of adding 7 + 2 below.
Picture
The above diagram shows that if a carryover is not needed then the process of adding 6 is discarded and the original result from the calculation is used. Below is an example showing the addition of two decimal numbers.
Picture
Picture
1: Convert the following Binary to BCD
  • 10110011
  • 10101011
  • 1011001110101011
2: Convert the following Hexadecimal to BCD
  • F7
  • FF
3: Convert the following Denary to BCD
  • 253
  • 128
4: A digital clock uses BCD to represent each number displayed, if the time was represented by 0000 1001 : 0101 0010 what time would the clock be showing?
5: Why is BCD an appropriate solution used to represent each individual digit on a clock?
6: Give another example of where BCD might be used and describe why it would be appropriate for your give situation.
7: Add the follows BCD representations, use the table provided to help you (show your workings).
1001 1001 + 1001 0110
Picture
NEXT: NEGATIVE NUMBERS
Picture
SUGGESTIONS
We would love to hear from you
SUBSCRIBE 
To enjoy more benefits
We hope you find this site useful. If you notice any errors or would like to contribute material then please contact us.