What is data representation in computer


Computer does not understand human language. Any data, viz., letters, symbols, pictures, audio, videos, etc., fed to computer should be converted to machine language first. Computers represent data in the following three forms −

Number System

We are introduced to concept of numbers from a very early age. To a computer, everything is a number, i.e., alphabets, pictures, sounds, etc., are numbers. Number system is categorized into four types −

  • Binary number system consists of only two values, either 0 or 1

  • Octal number system represents values in 8 digits.

  • Decimal number system represents values in 10 digits.

  • Hexadecimal number system represents values in 16 digits.

Number System System Base Digits
Binary 2 0 1
Octal 8 0 1 2 3 4 5 6 7
Decimal 10 0 1 2 3 4 5 6 7 8 9
Hexadecimal 16 0 1 2 3 4 5 6 7 8 9 A B C D E F

Bits and Bytes

Bits − A bit is a smallest possible unit of data that a computer can recognize or use. Computer usually uses bits in groups.

Bytes − group of eight bits is called a byte. Half a byte is called a nibble.

The following table shows conversion of Bits and Bytes −

Byte Value Bit Value
1 Byte 8 Bits
1024 Bytes 1 Kilobyte
1024 Kilobytes 1 Megabyte
1024 Megabytes 1 Gigabyte
1024 Gigabytes 1 Terabyte
1024 Terabytes 1 Petabyte
1024 Petabytes 1 Exabyte
1024 Exabytes 1 Zettabyte
1024 Zettabytes 1 Yottabyte
1024 Yottabytes 1 Brontobyte
1024 Brontobytes 1 Geopbytes

Text Code

Text code is format used commonly to represent alphabets, punctuation marks and other symbols. Four most popular text code systems are −

  • EBCDIC
  • ASCII
  • Extended ASCII
  • Unicode

EBCDIC

Extended Binary Coded Decimal Interchange Code is an 8-bit code that defines 256 symbols. Given below is the EBCDIC Tabular column

ASCII

American Standard Code for Information Interchange is an 8-bit code that specifies character values from 0 to 127.

ASCII Tabular column

ASCII Code Decimal Value Character
0000 0000 0 Null prompt
0000 0001 1 Start of heading
0000 0010 2 Start of text
0000 0011 3 End of text
0000 0100 4 End of transmit
0000 0101 5 Enquiry
0000 0110 6 Acknowledge
0000 0111 7 Audible bell
0000 1000 8 Backspace
0000 1001 9 Horizontal tab
0000 1010 10 Line Feed

Extended ASCII

Extended American Standard Code for Information Interchange is an 8-bit code that specifies character values from 128 to 255.

Extended ASCII Tabular column

Unicode

Unicode Worldwide Character Standard uses 4 to 32 bits to represent letters, numbers and symbol.

Unicode Tabular Column

computer_concepts_introduction_to_computer.htm

This is a basic concept in computer science


Computers use binary - the digits 0 and 1 - to store data. A binary digit, or bit, is the smallest unit of data in computing. It is represented by a 0 or a 1. Binary numbers are made up of binary digits (bits), eg the binary number 1001. The circuits in a computer's processor are made up of billions of transistors. A transistor is a tiny switch that is activated by the electronic signals it receives. The digits 1 and 0 used in binary reflect the on and off states of a transistor. Computer programs are sets of instructions. Each instruction is translated into machine code - simple binary codes that activate the CPU. Programmers write computer code and this is converted by a translator into binary instructions that the processor can execute. All software, music, documents, and any other information that is processed by a computer, is also stored using binary.[1]

To include strings, integers, characters and colours. This should include considering the space taken by data, for instance the relation between the hexadecimal representation of colours and the number of colours available.

This video is superb place to understand this topic

How a file is stored on a computer[edit]

How an image is stored in a computer[edit]


An image is a matrix of pixel values. Essentially, every image can be represented as a matrix of pixel values[2]


The way in which data is represented in the computer.[edit]

To include strings, integers, characters and colours. This should include considering the space taken by data, for instance the relation between the hexadecimal representation of colours and the number of colours available[3].

Integer: Each integer is represented in binary. Where a single number will usually be represented in one byte. Characters: Each character is usually one byte, represented in binary.

Unicode is a standardization of assigning values to a specific character, this is needed as there are hundreds of different characters in different languages and if done by each community there would likely be overlaps.

Strings: A concatenation of characters. Will be represented in binary, as each 8 bit character following each other. Each word will be around 16-32 bits. Colors: Is represented in hexadecimal number system. Will be 6 hexadecimal values 2 for each prime colour, in the order of Red, Green, Blue (RGB.) For example the colour red will be FF 00 00. When viewed on a screen it will usually have a hash tag before the value, e.g. #FF 00 00. A maximum of around 16.8 million different colours may be input.(16 to the power of 6 or 2 to the power of 24.). Please see this EXCELLENT chart to better understand how hexidecimal is used to express colors

This helpful material is used with gratitude from a computer science wiki under a Creative Commons Attribution 3.0 License[4]

Sound[edit]

See Also[edit]

Standards[edit]

* Outline the way in which data is represented in the computer.

References[edit]

 Data Representation refers to the methods used to represent information stored in a computer. Computers store lots of different types of information: discrete information like  numbers and letters, or continuous information like sounds and images. They use numeric codes to represent that data. The information is stored in a series of zeroes and ones known as binary code. Data is transmitted within a computer by electrical signals that are either on or off. On = 1, off =0.

Resources:
BBC Bitesize - Data Representation    ​BBC Bitesize - Binary
Data Representation - Unplugged
 - teaching data representation without computers
CS Field Guide - Data representation
​Binary numbers videos
​Flowcharts

ASCII and Unicode Code
Computers can't understand letters (or base 10 numbers) so any letters typed into a computer need to be converted into binary code.  This is usually done using the ASCII (pronounced ask-ee) format which stands for American Standard Code for Information Interchange. Each letter is assigned a number which is then converted to binary.  A for example is 65 or 01000001. Lowercase a is 97 or 011000001.
ASCII code however,  can only store 128 characters, which is enough for most words in English but not enough for other languages such as Cyrillic or Mandarin where more characters are needed. For these you would need to use another code known as Unicode. 

2017

Neuester Beitrag

Stichworte