There was a discussion on the iPodLinux Forums recently about discrepancies in DVD capacities (which seem to only hold 4.3GB of information when they are advertised as holding 4.7GB). I decided to organize my responses a little better and add in some totally hypothetical questions. Here’s the result.
“I bought a new 100GB hard drive, but my computer says that it’s only 93GB big? Did the company cheat me out of 7GB?”
Nope (though the advertising might have been a little cheap). The issue is the term GB, or gigabyte. In common everyday use, it can refer to two different standards of measurement: the gigabyte (which we commonly think we are using) and the gibibyte.
“What the heck is a gibibyte and why does it mean that I can’t sue the company?”
The difference between the two is this: 1 gigabyte equals 10003 bytes and 1 gibibyte (GiB) equals 10243 bytes. Thus, gigabytes and gibibytes are not quite the same thing. When we are talking about file sizes and RAM sizes, we are actually using gibibytes, although it is the standard cultural convention to refer to them as gigabytes. On the other hand, gigabytes are used to talk about the sizes of block devices like hard drives and optical disks. Furthermore, most operating systems actually use GiB when referring to hard drive capacities!
So, companies can freely refer to drive sizes in terms of gigabytes to make their drives seem bigger. But when you open up the box and put your drive into your computer and find out that you had less space than you expected, you probably won’t be happy.
So, how can we convert between the two? It’s just simple dimensional analysis. I’ve got two 160GB hard drives in my computer (hopefully 1 160GB and 1 320GB soon). Let’s use 160GB as an example.
( 160GB ) ( 10003B / 1GB ) ( 1GiB / 10243B ) = 149GiB, which is about a match to what I have.
There are some other factors that cause discrepancies in the size of your drive, including the way it was manufactured (one of my drives is just a hair over 150GiB and the other is about 149GiB). Also, filesystems inherently use some disk space, which can result in a slight loss of drive capacity, too.
For further information, take a look at these Wikipedia articles:
http://en.wikipedia.org/wiki/Gigabyte
http://en.wikipedia.org/wiki/Gibibyte