# Order of magnitude

Order of magnitude is a concept used to discuss the scale of numbers in relation to one another.
Two numbers are "within an order of magnitude" of each other if their ratio is between 1/10 and 10. In other words, the two numbers are within about a factor of 10 of each other.
For example, 1 and 1.02 are within an order of magnitude. So are 1 and 2, 1 and 9, or 1 and 0.2. However, 1 and 15 are not within an order of magnitude, since their ratio is 15/1 = 15 > 10. The reciprocal ratio, 1/15, is less than 0.1, so the same result is obtained.
Differences in order of magnitude can be measured on a base-10 logarithmic scale in "decades" (i.e., factors of ten). For example, there is one order of magnitude between 2 and 20, and two orders of magnitude between 2 and 200. Each division or multiplication by 10 is called an order of magnitude. This phrasing helps quickly express the difference in scale between 2 and 2,000,000: they differ by 6 orders of magnitude.
Examples of numbers of different magnitudes can be found at Orders of magnitude (numbers).
Below are examples of different methods of partitioning the real numbers into specific "orders of magnitude" for various purposes. There is not one single accepted way of doing this, and different partitions may be easier to compute but less useful for approximation, or better for approximation but more difficult to compute.

## Calculating the order of magnitude

Generally, the order of magnitude of a number is the smallest power of 10 used to represent that number. To work out the order of magnitude of a number $N$, the number is first expressed in the following form:
    $N=a\times 10^{b}$
where ${\frac {1}{\sqrt {10}}}\leq a<{\sqrt {10}}$, or approximately $0.316\lesssim a\lesssim 3.16$. Then, $b$ represents the order of magnitude of the number. The order of magnitude can be any integer. The table below enumerates the order of magnitude of some numbers using this definition:
| Number $N$ | Expression in $N=a\times 10^{b}$ | Order of magnitude $b$ |
| 0.2 | 2 × 10$^{−1}$ | −1 |
| 1 | 1 × 10$^0$ | 0 |
| 5 | 0.5 × 10$^1$ | 1 |
| 6 | 0.6 × 10$^1$ | 1 |
| 31 | 3.1 × 10$^1$ | 1 |
| 32 | 0.32 × 10$^2$ | 2 |
| 999 | 0.999 × 10$^3$ | 3 |
| 1000 | 1 × 10$^3$ | 3 |
The geometric mean of $10^{b-1/2}$ and $10^{b+1/2}$ is $10^{b}$, meaning that a value of exactly $10^{b}$ (i.e., $a=1$) represents a geometric halfway point within the range of possible values of $a$.
Some use a simpler definition where $0.5\leq a<5$. This definition has the effect of lowering the values of $b$ slightly:
| Number $N$ | Expression in $N=a\times 10^{b}$ | Order of magnitude $b$ |
| 0.2 | 2 × 10$^{−1}$ | −1 |
| 1 | 1 × 10$^0$ | 0 |
| 5 | 0.5 × 10$^1$ | 1 |
| 6 | 0.6 × 10$^1$ | 1 |
| 31 | 3.1 × 10$^1$ | 1 |
| 32 | 3.2 × 10$^1$ | 1 |
| 999 | 0.999 × 10$^3$ | 3 |
| 1000 | 1 × 10$^3$ | 3 |

## Uses

Orders of magnitude are used to make approximate comparisons. If numbers differ by one order of magnitude, x is about ten times different in quantity than y. If values differ by two orders of magnitude, they differ by a factor of about 100. Two numbers of the same order of magnitude have roughly the same scale: the larger value is less than ten times the smaller value. The growing amounts of Internet data have led to addition of new SI prefixes over time, most recently in 2022.
| In words | Prefix (Symbol) | Decimal | Power of ten | Order of magnitude |
| nonillionth | quecto- (q) | 0.000000000000000000000000000001 | 10$^{−30}$ | −30 |
| octillionth | ronto- (r) | 0.000000000000000000000000001 | 10$^{−27}$ | −27 |
| septillionth | yocto- (y) | 0.000000000000000000000001 | 10$^{−24}$ | −24 |
| sextillionth | zepto- (z) | 0.000000000000000000001 | 10$^{−21}$ | −21 |
| quintillionth | atto- (a) | 0.000000000000000001 | 10$^{−18}$ | −18 |
| quadrillionth | femto- (f) | 0.000000000000001 | 10$^{−15}$ | −15 |
| trillionth | pico- (p) | 0.000000000001 | 10$^{−12}$ | −12 |
| billionth | nano- (n) | 0.000000001 | 10$^{−9}$ | −9 |
| millionth | micro- (μ) | 0.000001 | 10$^{−6}$ | −6 |
| thousandth | milli- (m) | 0.001 | 10$^{−3}$ | −3 |
| hundredth | centi- (c) | 0.01 | 10$^{−2}$ | −2 |
| tenth | deci- (d) | 0.1 | 10$^{−1}$ | −1 |
| one | | 1 | 10$^0$ | 0 |
| ten | deca- (da) | 10 | 10$^1$ | 1 |
| hundred | hecto- (h) | 100 | 10$^2$ | 2 |
| thousand | kilo- (k) | 1000 | 10$^3$ | 3 |
| million | mega- (M) | 1000000 | 10$^6$ | 6 |
| billion | giga- (G) | 1000000000 | 10$^9$ | 9 |
| trillion | tera- (T) | 1000000000000 | 10$^{12}$ | 12 |
| quadrillion | peta- (P) | 1000000000000000 | 10$^{15}$ | 15 |
| quintillion | exa- (E) | 1000000000000000000 | 10$^{18}$ | 18 |
| sextillion | zetta- (Z) | 1000000000000000000000 | 10$^{21}$ | 21 |
| septillion | yotta- (Y) | 1000000000000000000000000 | 10$^{24}$ | 24 |
| octillion | ronna- (R) | 1000000000000000000000000000 | 10$^{27}$ | 27 |
| nonillion | quetta- (Q) | 1000000000000000000000000000000 | 10$^{30}$ | 30 |
| In words | Prefix (Symbol) | Decimal | Power of ten | Order of magnitude |

### Calculating the order of magnitude by truncation

The order of magnitude of a number is, intuitively speaking, the number of powers of 10 contained in the number. More precisely, the order of magnitude of a number can be defined in terms of the common logarithm, usually as the integer part of the logarithm, obtained by truncation. For example, the number 4000000 has a logarithm (in base 10) of 6.602; its order of magnitude is 6. When truncating, a number of this order of magnitude is between 10$^6$ and 10$^7$. In a similar example, with the phrase "seven-figure income", the order of magnitude is the number of figures minus one, so it is very easily determined without a calculator to be 6. An order of magnitude is an approximate position on a logarithmic scale.

### Order-of-magnitude estimate

An order-of-magnitude estimate of a variable, whose precise value is unknown, is an estimate rounded to the nearest power of ten. For example, an order-of-magnitude estimate for a variable between about 3 billion and 30 billion (such as the human population of the Earth) is 10 billion. To round a number to its nearest order of magnitude, one rounds its logarithm to the nearest integer. Thus 4000000, which has a logarithm (in base 10) of 6.602, has 7 as its nearest order of magnitude, because "nearest" implies rounding rather than truncation. For a number written in scientific notation, this logarithmic rounding scale requires rounding up to the next power of ten when the multiplier is greater than the square root of ten (about 3.162). For example, the nearest order of magnitude for 1.7×10$^8$ is 8, whereas the nearest order of magnitude for 3.7×10$^8$ is 9. An order-of-magnitude estimate is sometimes also called a zeroth order approximation.

## Non-decimal orders of magnitude

An order of magnitude is an approximation of the logarithm of a value relative to some contextually understood reference value, usually 10, interpreted as the base of the logarithm and the representative of values of magnitude one. Logarithmic distributions are common in nature and considering the order of magnitude of values sampled from such a distribution can be more intuitive. When the reference value is 10, the order of magnitude can be understood as the number of digits minus one in the base-10 representation of the value. Similarly, if the reference value is one of some powers of 2 since computers store data in a binary format, the magnitude can be understood in terms of the amount of computer memory needed to store that value.

### Irrational orders of magnitude

Other orders of magnitude may be calculated using bases other than integers. In the field of astronomy, the nighttime brightnesses of celestial bodies are ranked by "magnitudes" in which each increasing level is brighter by a factor of ${\sqrt[{5}]{100}}\approx 2.512$ greater than the previous level. Thus, a level being 5 magnitudes brighter than another indicates that it is a factor of $({\sqrt[{5}]{100}})^{5}=100$ times brighter: that is, two base 10 orders of magnitude.
This series of magnitudes forms a logarithmic scale with a base of ${\sqrt[{5}]{100}}$.

### Base 1,000,000 orders of magnitude

The different decimal numeral systems of the world use a larger base to better envision the size of the number, and have created names for the powers of this larger base. The table shows what number the order of magnitude aim at for base 10 and for base 1000000. It can be seen that the order of magnitude is included in the number name in this example, because bi- means 2, tri- means 3, etc. (these make sense in the long scale only), and the suffix -illion tells that the base is 1000000. But the number names billion, trillion themselves (here with other meaning than in the first chapter) are not names of the orders of magnitudes, they are names of "magnitudes", that is the numbers 1000000000000 etc.
| Order of magnitude | Is log$_{10}$ of | Is log$_{1000000}$ of | Short scale | Long scale |
| 1 | 10 | 1000000 | million | million |
| 2 | 100 | 1000000000000 | trillion | billion |
| 3 | 1000 | 1000000000000000000 | quintillion | trillion |
| 4 | 10000 | (1 000 000)$^4$ | septillion | quadrillion |
| 5 | 100000 | (1 000 000)$^5$ | nonillion | quintillion |
SI units in the table at right are used together with SI prefixes, which were devised with mainly base 1000 magnitudes in mind. The IEC standard prefixes with base 1024 were invented for use in electronic technology.