# BCD Coding and addition examples

Introduction to BCD :-

BCD stands for Binary Encoded Digital. In BCD every decimal number is represented by four binary bits. Example: 190 in decimal is equivalent to 0001 1001 0000 in binary encoded decimal

0 to 9 in decimal can be represented in binary using four digits and all integers can be represented by these 10 digits.

#### BCD addition and Decimal Arithmetic:

In BCD addition of two numbers involve following rules:-

- Maximum value of the sum for two digits = 9 (max digit 1) + 9 (max digit 2) + 1 (previous addition carry) = 19
- If sum of two BCD digits is less than or equal to 9 (1001) without carry then the result is a correct BCD number.
- If sum of two BCD digits is greater than or equal to 10 (1010) the result is in-
correct BCD number. Perform steps 4 for correct BCD sum. - Add 6 (0110) to the result.

Let use above rules in example below.

Refer complete digital basics tutorial on fullchipdesign from this link.