Binary prefix
From Wikipedia, the free encyclopedia
In computing, binary prefixes can be used to quantify large numbers where powers of two are more useful than powers of ten. Each successive prefix is multiplied by 1024 (210) rather than the 1000 (103) used by the SI prefix system. Despite the ambiguity, binary prefixes are often written and pronounced identically to the SI prefixes, rather than using the IEC system described below.
Contents |
[edit] History
Using the prefixes kilo-, mega-, giga-, etc., and their symbols k, M, G, etc. (see below for the peculiarities of "K"), in the binary sense can cause serious confusion.
In January 1999, the International Electrotechnical Commission introduced the prefixes kibi-, mebi-, gibi-, etc., and the symbols Ki, Mi, Gi, etc. to specify binary multiples of a quantity. <ref>Amendment 2 to IEC International Standard IEC 60027-2: Letter symbols to be used in electrical technology — Part 2: Telecommunications and electronics [1]</ref>
They have since been officially adopted by many other organizations, most notably the Institute of Electrical and Electronics Engineers (see standard IEEE 1541) and the European Union (as harmonization document HD 60027-2:2003-03<ref name="EUHD">HD 60027-2:2003 Information about the harmonization document (obtainable on order)</ref>). However, they have not yet been widely adopted by manufacturers and individuals; many continue to use the SI prefixes in a binary sense, despite the lack of support from official bodies. As a result, there is no unambiguous notation for decimal multiples of bits and bytes.
[edit] Binary prefixes using SI symbols
| Name | Symbol | Value | Base 16 | Base 10 |
|---|---|---|---|---|
| kilo | k/K | 210 = 1,024 | = 162.5 | > 103 |
| mega | M | 220 = 1,048,576 | = 165 | > 106 |
| giga | G | 230 = 1,073,741,824 | = 167.5 | > 109 |
| tera | T | 240 = 1,099,511,627,776 | = 1610 | > 1012 |
| peta | P | 250 = 1,125,899,906,842,624 | = 1612.5 | > 1015 |
| exa | E | 260 = 1,152,921,504,606,846,976 | = 1615 | > 1018 |
| zetta | Z | 270 = 1,180,591,620,717,411,303,424 | = 1617.5 | > 1021 |
| yotta | Y | 280 = 1,208,925,819,614,629,174,706,176 | = 1620 | > 1024 |
The one-letter abbreviations are identical to SI prefixes, except for "K", which is used interchangeably with "k" (in SI, "K" stands for the kelvin, and only "k" stands for 1,000).
These prefixes are in common use in contexts where accuracy is not important, such as file and memory sizes, but conflict with SI definitions. The names and values of the SI prefixes were defined in the 1960 SI standard, with powers-of-1000 values. As of 2005, standard dictionaries do not recognize the binary meanings for these prefixes.
BIPM (which maintains SI) expressly prohibits the binary prefix usage, and recommends the use of the IEC prefixes as an alternative (computing units are not included in SI).<ref>The International System of Units, 8th edition, 2006 — Side note in section 3.1 — SI prefixes</ref>
Some have suggested that "k" be used for 1,000, and "K" for 1,024, but this cannot be extended to the higher order prefixes and has never been widely recognised.
Although the prefixes denoting fractions of a bit or byte might theoretically find application in areas such as cryptography, data compression, and data transfer rates, they are not used in practice.
Informally, the prefixes are often used on their own. Thus one might hear about "a 40K file" (40 binary kilobytes) or "a 2M Internet connection" (2 decimal megabits per second). What units are being used, and whether the multipliers are decimal or binary, depends on context and cannot be determined by the units alone.
[edit] IEC standard prefixes
In 1999, the International Electrotechnical Commission (IEC) published Amendment 2 to "IEC 60027-2: Letter symbols to be used in electrical technology — Part 2: Telecommunications and electronics". This standard, which was approved in 1998, introduced the prefixes kibi-, mebi-, gibi-, tebi-, pebi-, exbi-, to be used in specifying binary multiples of a quantity. The names come from the first two letters of the original SI prefixes followed by bi which is short for "binary". It also clarifies that, from the point of view of the IEC, the SI prefixes only have their base-10 meaning and never have a base-2 meaning.
This amendment was included in the next edition of the standard: "IEC 60027-2 (2000-11) Ed. 2.0"
The second edition defined them only up to exbi-, but in 2005, the third edition of the standard added prefixes zebi- and yobi-, thus matching all standard SI prefixes with their binary counterparts.
| Name | Symbol | Base 2 | Base 16 | Base 10 | ||
|---|---|---|---|---|---|---|
| kibi | Ki | 210 | 162.5 | 0x400 | = 1,024 | > 103 |
| mebi | Mi | 220 | 165 | 0x10 0000 | = 1,048,576 | > 106 |
| gibi | Gi | 230 | 167.5 | 0x4000 0000 | = 1,073,741,824 | > 109 |
| tebi | Ti | 240 | 1610 | 0x100 0000 0000 | = 1,099,511,627,776 | > 1012 |
| pebi | Pi | 250 | 1612.5 | 0x4 0000 0000 0000 | = 1,125,899,906,842,624 | > 1015 |
| exbi | Ei | 260 | 1615 | 0x1000 0000 0000 0000 | = 1,152,921,504,606,846,976 | > 1018 |
| zebi | Zi | 270 | 1617.5 | 0x40 0000 0000 0000 0000 | = 1,180,591,620,717,411,303,424 | > 1021 |
| yobi | Yi | 280 | 1620 | 0x1 0000 0000 0000 0000 0000 | = 1,208,925,819,614,629,174,706,176 | > 1024 |
Example: 300 GB ~ 279.5 GiB (= 0x117.6592E GiB = 0x45D96.4B8 MiB = 0x1176592E KiB = 0x45D964B800 bytes).
[edit] Approximate ratios between binary and decimal prefixes
Notice that as the order of magnitude increases, the percentage difference between the binary and decimal values of a prefix increases, from 2.4% (with the kilo prefix) to over 20% (with the yotta prefix).
| Name | Bin ÷ Dec | Dec ÷ Bin | Example | Percentage difference |
|---|---|---|---|---|
| kilobyte : kibibyte | 1.024 | 0.976 | 100 kB ≅ 97.6 KiB | +2.4% or −2.3% |
| megabyte : mebibyte | 1.049 | 0.954 | 100 MB ≅ 95.4 MiB | +4.9% or −4.6% |
| gigabyte : gibibyte | 1.074 | 0.931 | 100 GB ≅ 93.1 GiB | +7.4% or −6.9% |
| terabyte : tebibyte | 1.100 | 0.909 | 100 TB ≅ 90.9 TiB | +10% or −9.1% |
| petabyte : pebibyte | 1.126 | 0.888 | 100 PB ≅ 88.8 PiB | +12.6% or −11.2% |
| exabyte : exbibyte | 1.153 | 0.867 | 100 EB ≅ 86.7 EiB | +15.3% or −13.3% |
| zettabyte : zebibyte | 1.181 | 0.847 | 100 ZB ≅ 84.7 ZiB | +18.1% or −15.3% |
| yottabyte : yobibyte | 1.209 | 0.827 | 100 YB ≅ 82.7 YiB | +20.9% or −17.3% |
[edit] Adoption
As of 2005 this naming convention has not gained widespread use, but its use is growing. It is strongly supported by many standardization bodies and technical organizations, such as IEEE, CIPM, NIST, and SAE.<ref name="NIST">Prefixes for Binary Multiples — The NIST Reference on Constants, Units, and Uncertainty</ref><ref>Rules for SAE Use of SI (Metric) Units — Section C.1.12 — SI prefixes</ref> In particular, on March 19, 2005 the IEEE standard IEEE 1541-2002 (Prefixes for Binary Multiples) has been elevated to a full-use standard by the IEEE Standards Association after a two-year trial period.
The binary prefixes which are defined in IEC 60027-2 (Letter symbols to be used in electrical technology – Part 2: Telecommunications and electronics) have been adopted by the European Committee for Electrotechnical Standardization (CENELEC) as the harmonization document HD 60027-2:2003-03<ref name="EUHD">HD 60027-2:2003 Information about the harmonization document (obtainable on order)</ref>. Right now this document is going to be adopted as a European standard<ref>prEN 60027-2:2006 Information about the EN standardization process</ref>.
[edit] Consumer Confusion
Some modern-day PC users regard both RAM and disk as similar kinds of storage and expect their capacities to be measured in the same way. This expectation is reinforced by operating systems that usually report disk space using the binary standard. This results in an apparent loss to the purchaser of a "30 GB" hard drive, because rather than reporting "30 GB", Microsoft Windows, for example, reports HDD capacity in two forms, "30,064,771,072" and "28 GB". This creates confusion and has led to legal disputes, sometimes made worse by other technical issues such as failure to distinguish between unformatted and formatted capacities and to account for the overhead inherent in disk file systems.
[edit] Usage notes
The phrase "decimal unit" will be used to denote "SI designation understood in its standard, decimal, power-of-1000 sense" and "binary unit" will mean "SI designation understood in its traditional computer-industry, binary, power-of-1024 sense." B will be used as the symbol for byte as per computer-industry standard (IEEE 1541 and IEC 60027; B is also the symbol for bel, a non-SI unit used in hard drive noise measurements).
Certain units are always understood as decimal even in computing contexts. For example, hertz (Hz), which is used to measure clock rates of electronic components, and bit/s, used to measure bit rate. So a 1 GHz processor performs 1,000,000,000 clock ticks per second, a 128 kbit/s MP3 stream consumes 128,000 bits (16 kB, 15.625 KiB) per second, and a 1 Mbit/s Internet connection can transfer 1,000,000 bits (125 kB, approx 122 KiB) per second, assuming an 8-bit byte, and no overhead.<ref>Binary vs. Decimal Measurements</ref>
[edit] Pronunciation
It is suggested that in English, the first syllable of the name of the binary-multiple prefix should be pronounced in the same way as the first syllable of the name of the corresponding SI prefix, and that the second syllable should be pronounced as "bee." <ref name="NIST"/>
[edit] Computer memory
Measurements of most types of electronic memory such as RAM and ROM and Flash (large scale disk-like flash is sometimes an exception) are given in binary units, as they are made in power-of-two sizes. This is the most natural configuration for memory, as all combinations of their address lines map to a valid address, allowing easy aggregation into a larger contiguous block of memory.
[edit] Hard disk drives
Most hard disk manufacturers state capacity in decimal units. This usage has a long tradition, even predating the SI system of decimal prefixes adopted in 1960. The decimal-based capacity in hard disk drives follows the method used for serially accessed storage media which predated direct access storage media like hard disk drives. As a stream of data has no inherent chunk or block size, it follows to measure how many thousands, millions, or billions of bytes have been stored, in the same way most quantities are measured (rather than multiples of 1,024, 1,048,576, or 1,073,741,824 bytes). When the first hard disk drives were developed, the decimal measurement continued the tradition of punch cards and tapes. Thus, today, most devices that are addressed or seen as "storage" use the decimal system to identify capacity.
[edit] Flash drives
USB Flash Drive and Flash-based memory cards like CompactFlash and Secure Digital are typically classified in "powers of two" multiples of decimal megabytes, for example: 32MB, 64MB, 128MB, 256MB, 512MB. Although the devices usually have at least the expected byte capacity as defined by the "decimal" calculation (256 million bytes for a 256MB classified device), each manufacturer allocates different portions of the device's ultimate capacity for such things as wear levelling.
[edit] Floppy drives
The confused usage of decimal prefixes may have started in floppy drives where the drive and media manufacturers stated their unformatted capacity while various systems houses published differing formatted capacities as a consequence of their varying controller designs. It appears that some system manufactures and OS vendors began reporting in what we now know as Ki bytes. A very confusing hybrid system developed with the double sided high density 3½" floppy disk, in which a "megabyte" means a thousand 1024-byte "kilobytes". Thus, as of 2005, manufacturers universally use the designation "1.44 MB diskette" for a product which holds neither 1.44×220 bytes nor 1.44×106 bytes, but rather 1.44×1000×1024 bytes (approximately 1.406 MiB, or 1.475 MB). This is probably because some marketing person decided that this was best advertised as a double capacity version of the prior generation 720 KB product (of course, it was 720 KiB).
[edit] CD
CD capacities are always given in binary units. A "700 MB" (or "80 minute") CD has a nominal capacity of about 700 MiB.<ref>Data capacity of CDs</ref> But DVD capacities are given in decimal units. A "4.7 GB" DVD has a nominal capacity of about 4.38 GiB.<ref>Understanding Recordable and Rewritable DVD</ref>
[edit] Buses
Bus bandwidth is given in decimal units. This is not because hard drive capacities use the decimal versions, nor because bit rates do, but because clock speeds do. For example, "PC3200" memory runs on a double pumped 200 MHz bus, transferring 8 bytes per cycle, and hence has a bandwidth of 200,000,000×2×8 = 3,200,000,000 byte/s.
[edit] Legal disputes
The implicit use of decimal units to describe the capacity of storage devices has become a source of confusion as these devices are increasingly marketed to non-technical consumers. When a user buys a device advertised using decimal units, and installs it in a system that shows the available space in binary units, a misinformed user may be disturbed by the apparent discrepancy. As a result, there have been several lawsuits against companies who sell hard drives, flash memory devices, and computer systems that list drive capacities.
Several significant lawsuits have been filed:
- On June 23, 2003, a Business Tort action entitled Matthew Leffert vs. Amazon.com, INC., was filed in the Superior Court for the City and County of San Francisco, Case No. CGC-03-421769. In this case, the plaintiff complained of false advertising in relation to how MP3 player storage is marketed.
- The case was dismissed on March 14, 2005.
- In September of 2003, Lanchau Dan, Adam Selkowitz, Tim Swan and John Zahabian filed a lawsuit against Dell, Inc., Apple Computer Inc., Gateway, Inc., Hewlett-Packard Co., IBM Corp., Sharp Corporation, Sony Corp. and Toshiba Corp claiming their advertising deceptively exaggerates the real capacity of their hard drives.
- On February 20, 2004, Willem Vroegh filed a lawsuit against Lexar Media, Dane–Elec Memory, Fuji Photo Film USA, Eastman Kodak Company, Kingston Technology Company, Inc., Memorex Products, Inc.; PNY Technologies Inc., SanDisk Corporation, Verbatim Corporation, and Viking InterWorks alleging that their descriptions of the capacity of their flash memory cards were false and misleading.
- As of 2005, at least one of these companies has settled out of court.
- On July 7, 2005, an action entitled Orin Safier v. Western Digital Corporation, et al., was filed in the Superior Court for the City and County of San Francisco, Case No. CGC-05-442812. The case was subsequently moved to the Northern District of California, Case No. 05-03353 BZ.
[edit] See also
[edit] Specific units of IEC 60027-2 A.2
These units have individual articles:
|
|
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
[edit] References
<references />
[edit] External links
- What is a Megabyte ...? Markus Kuhn's 1996–1999 paper on bits, bytes, prefixes and symbols
- Prefixes for binary multiples — NIST
- Get Ready for the mebi, gibi and tebi — NIST
- Description of binary prefixes — IEC
- Another description of binary prefixes
- White-paper on the controversy over drive capacities
- There is no such thing as a 1.44 MB standard format floppy disc
- A summary of the organizations, software, and so on that have implemented the new binary prefixes
- A plea for sanity
- KiloBytes vs. kilobits vs. Kibibytes (Binary prefixes)
- Here Come Zebi- and Yobi- IEC press release announcing new prefixes
- JavaScript SI/Binary Prefix Converterbg:Двоична представка
cs:Binární předpona da:Binært præfiks de:Binärpräfix es:Prefijo binario fr:Préfixe binaire ko:이진 접두어 it:Prefissi per multipli binari hu:Bináris prefixum nl:Veelvouden van bytes ja:2進接頭辞 no:Binærprefiks pl:Przedrostek dwójkowy pt:Prefixo binário ro:Prefixe binare ru:Двоичные приставки sk:Binárny prefix sr:Јобибит uk:Двійкові префікси

