Discover the full meanings behind common abbreviations and Full Forms

Technology & Computing

Binary-Coded Decimal

(BCD)

Binary-Coded Decimal

Description

Binary-coded Decimal in Simple Terms

When you hear the term “binary,” you think of computers; 0s and 1s counting. It’s accurate! Computers work in those strings of 0s and 1s known as binary numbers. Nonetheless, computer systems sometimes have to present numbers in a different fashion referred to as Binary Coded Decimal aka BCD

This paper is going to provide you with what BCD stands for, how it functions, why and where it is used. Notably when you’re not a computer expert, fret less. We will make everything apparent!

What is Binary-Coded Decimal (BCD)?

Binary-Coded Decimal (BCD) represents a technique for representing every decimal digit (0 to 9) with its group of binary bits.

Most of the time, computers store numbers in straight binary form: the whole number is converted into a binary form. BCD, however, changes each digit in a decimal number into its binary code individually.

For example:

In straight binary form, the number 45 looks like 101101.

When written out in BCD, a 4 looks like 0100 and a 5 looks like 0101.

In BCD, 45 looks like 0100 0101.

Why BCD is worth using:

The Renegade: So why not just use binary as normal?” “Why are you going back to BCD of all things?”

Here’s why:

Easy to Convert to Human-Readable Form

Keeping binary-coded decimal separate from each other makes changing of a number from decimal to binary and vice versa much easier to do. This is good for digital displays; think digital clocks, or calculators that show numbers to people.

Eases Decimal Arithmetic

Some systems such as older computers or embedded the devices find it more convenient to carry out decimal math with BCD. Thus it does not have the rounding errors that can happen in pure binary.

Financial and Commercial Systems

In the mathematical representation of money, it is very vital to use an accurate decimal format; BCD ensures that decimal digits are displayed exactly.

How is BCD working?

E.g. the number 0 consists of 4 bits:

Decimal Digit BCD (4-bit) 0 0000 1 0001 2 0010 3 0011 4 0100 5 0101 6 0110 7 0111 8 1000 9 1001

In BCD, the numbers 10 to 15 (binary 1010 to 1111) are not valid.

For example Let's say you want to show the number 259 in BCD.

Digit The numbers from ten to fifteen would not be valid if expressed in4 = ‘2’ → in binary: ‘1010’(BCD).6 ‘5’ = ‘0101’.9 = ‘9’ = ‘1001’.

Therefore, in BCD, the number two hundred fifty-nine will be equal to2 5 a n d 2 a n d a n d B C D : 2 5 The nought-th twos and fives and nines

Kinds of BCD

Packed: bcd that is packed

Two decimal digits can be stored within each byte (8 bits); for instance, 0100 0101 means “45,” with the 4 in the first 4 bits and 5 in the last 4 bits.

Unpacked: unpacked BCD

The rightmost 4 bits of each byte present a decimal digit, while the four leftmost higher-order bits are zero or indifferent.

Unpacked BCD needs more space than Packed BCD.

Applications of BCD

Calculators: Most basic calculators use BCD because it can represent decimal digits.

Numerical representation of time in figures on digital watches and clocks

Finance Applications: To avoid errors like those that can occur in the calculation of money in decimal

Embedded systems: e.g. vending machines, or point of sale terminals

Mainframe Computers and Legacy Systems: BCD is still used in some old systems

Pros and Cons of BCD

ProsCons

Easy conversion to decimal digitsMore memory consumption than pure binary

It avoids those mistakes caused by rounding off decimal figures More useful in everyday calculations Not so good in mathematics in general

Comparison

What Binary BCD

Data StorageIs more compact and efficientTakes up more room

Conversion Change to decimalNotably harder to convertEasy to convert

Math ComputationQuick and easy for computersSomewhat easier for decimal math computation

UseGeneral computation applicationDecimal-based application

End

BCD is a manner of representation of decimal numbers for computers to understand easily and yet as near to their human usage as possible, that is, digit by digit. BCD consumes more space and time for certain arithmetic operations than pure binary does, but it is very handy in situations that mandate exact decimal accuracy and simple conversion into figures that can be read.

Every time one uses a calculator or looks at a digital clock, they should think of BCD as the technology that may be ensuring those numbers appear perfect behind the scenes.