I often have to generate a sequence of powers of ten so I created this simple utility that does it for me. It lets you generate however many powers of ten you need, starting from any value. It works in the browser and is powered by alien technology from the future.

## Powers Of Ten Generator Options

## Powers Of Ten Generator Examples (click to try!)

^{0}= 1. Then it calculates other terms via the formula 10

^{n}, starting with n=1. Since the increasing option is active, the value of n increases by 1 with each iteration. So we get a list 10

^{0}= 1, 10

^{1}= 10, 10

^{2}= 100, and so on.

1, 10, 100, 1000, 10000, 100000, 1000000, 10000000, 100000000, 1000000000, 10000000000, 100000000000, 1000000000000, 10000000000000, 100000000000000, 1000000000000000, 10000000000000000, 100000000000000000, 1000000000000000000, 10000000000000000000, 100000000000000000000, 1000000000000000000000, 10000000000000000000000, 100000000000000000000000, 1000000000000000000000000

^{6}. Then, we decrease the exponent to n = 5, n = 4, n = 3, …. When the exponents decreases, so do the series terms. When the value of n becomes negative, the powers of ten become fractions. The smaller the value n, the closer the term is to zero (when n is -1, 10

^{-1}is 0.1; when n is -2, 10

^{-2}is 0.01; when n is -3, 10

^{-3}is 0.001, …).

1000000 (million) 100000 (one hundred thousand) 10000 (ten thousand) 1000 (thousand) 100 (hundred) 10 (ten) 1 (one) 0.1 (one tenth) 0.01 (one hundredth) 0.001 (one thousandth) 0.0001 (one ten thousandth) 0.00001 (one hundred thousandth) 0.000001 (one millionth)

^{2}) becomes 64 in base-16, the next value 1,000 (10

^{3}) becomes 3e8, then 10,000 (10

^{4}) becomes 2710, and so on. We also activate the Print Names option to immediately understand the number in the hex base.

64 (hundred) 3e8 (thousand) 2710 (ten thousand) 186a0 (one hundred thousand) f4240 (million) 989680 (ten million) 5f5e100 (one hundred million) 3b9aca00 (billion) 2540be400 (ten billion) 174876e800 (one hundred billion) e8d4a51000 (trillion)

## How Does This Powers Of Ten Generator Work?

This powers of ten generator works entirely in your browser and is written in JavaScript. It calculates a list of powers of ten and prints `count`

values (specified in options) in the output. Each list element is calculated via the math formula `10`

, where ^{n}`n`

is an integer (positive or negative). As this power series grows at an exponential rate, it uses the external `BigNumber`

module to work with arbitrarily large numbers. To generate the powers of ten, it first creates a BigNumber instance that's initialized to the value ten: `ten = new BigNumber(10)`

. Then, it repeatedly calls the `ten.pow(n)`

function where `n`

is the generator loop counter. If the increasing sequence option is active, the counter `n`

increases by 1 in each iteration, if the decreasing sequence option is active, the counter `n`

decreases by 1 in each iteration. The starting counter value `n`

is calculated from the input value `start`

(specified in options). To calculate it, the tool uses another external module called `Decimal`

. This module exports the base 10 logarithm method `log10`

. Calculating `log10(start)`

finds the starting counter `n`

for the loop. Each sequence element is put in the variable `powOfTen`

that is then converted to the selected `base`

. The base conversion is done using the `toString(base)`

function. The resulting value is then `push`

ed to the `powersArray`

. If the Print Number Names option is active, then it also adds the number's name after the number itself. All number names are stored in the `magnitudeNames`

lookup array. When `count`

power of ten values are calculated, the loop finishes. The calculated powers are `join`

ed together by the `separator`

symbol and get printed on the screen.

### Created by Browserling

This powers of ten generator was created by me and my team at Browserling. Behind the scenes, it's actually powered by our programmer tools that are used by millions of people every month. Browserling itself is an online cross-browser testing service powered by alien technology. Check it out!

Secret message: If you love my tools, then I love you, too! Use coupon code TOOLLING to get a discount at my company.