Information is stored digitally on a computer hard disk as a sequence of 0's and 1's. The sequence may encode a piture, sound, text or some other kind of information.
Suppose a sound recording to sampled into 8 bits at 1000, 2000, 3000, 4000, 5000 and 6000 Hz for 30 minutes.
This mean thatbits is written per second. There are 1800 seconds in 30 minutes sobits are written altogether.
There are 8 bits in a byte sobytes.
There are 1024 bytes in a kilobyte sokb.
There are 1,024 kb in a megabyte (MB) soMB.
Suppose a book has 500 pages, each page with 40 lines, each line with 50 characters.
Each character needs 8 bits to be encoded as binary code so the book will need altogetherbits to be written to disk.
Using the conversion factors above, 1 MBbytes, soMB.
Suppose a 10 cm by 20 cm picture is made up of pixels 0.1 mm across. It is to be stored as a colour image using three channel (red, green and blue), each with 256 shades.
There arepixels.
Sinceeach shade requires 8 bits and there are three channels so each pixel requires bits to encode and the picture requiresbits to encode.
HenceMB of disk space is required.