Negative and Fractional number representation

 

Representing Numbers






Negative number Representation
Negative numbers are simply numbers that are less than zero.Computers use binary to represent and process numbers. For negative numbers, binary systems rely on specific encoding methods since binary naturally represents only non-negative values. Common representations include

Decimal Representation

In decimal (base-10) notation, negative numbers are represented with a minus sign.
Examples:

  • -8(a negative integer)
  • -6.14 (a negative decimal number)
  • -1/5 (a negative fraction)
Sign-Magnitude Representation
Sign-Magnitude Representation is a method used to represent signed numbers in binary form
Example:


  • A sign bit of 0 represents a positive number.
  • A sign bit of 1 represents a negative number.

Binary Representation 

The binary number system is a base-2 numeral system that uses only two symbols: 0 and 1. Each digit in this system is referred to as a bit. Binary numbers are fundamental in computer science and digital electronics because they can be directly implemented in electronic circuits using logic gates.

Conversion from Decimal to Binary

To convert a decimal number to its binary equivalent, you repeatedly divide the number by 2 and record the remainders. The binary representation is obtained by reading the remainders in reverse order. For example, to convert the decimal number 13 to binary:

  1. 13 ÷ 2 = 6, remainder 1

  2. 6 ÷ 2 = 3, remainder 0

  3. 3 ÷ 2 = 1, remainder 1

  4. 1 ÷ 2 = 0, remainder 1

Reading the remainders from bottom to top, we get 1101. Therefore, 13 in binary is 1101.

Binary Arithmetic Operations

Binary arithmetic operations include addition, subtraction, multiplication, and division. These operations are similar to their decimal counterparts but are performed using binary digits.

Binary Addition

Binary addition follows these rules:

  • 0 + 0 = 0

  • 0 + 1 = 1

  • 1 + 0 = 1

  • 1 + 1 = 10 (which is 0 with a carry of 1)

Fractional Number Representation
Fractional numbers, or numbers that are not whole, can be represented in a variety of ways, such as decimals or fractions. When dealing with computers, representing fractions becomes a bit more complex, especially when using binary.


Binary Representation (Floating Point)


The Floating point representation is a way to the encode numbers in a format that can handle very large and very small values. It is based on scientific notation where numbers are represented as a fraction and an exponent. In computing, this representation allows for trade-off between range and precision.

binary fraction

Binary Factor Analysis (BFA, also known as Boolean Factor Analysis) may help with understanding collections of binary data. Since we can take collections of text documents as binary data too, the BFA can be used to analyze such collections. Unfortunately, exact solving of BFA is not easy. This article shows what BFA is, and some possible methods of solving it.













Comments

Popular posts from this blog

Interpreting Personal Computer Specifications

Parts of computer system unit

HOW TO ACCESS WEBSITE