# Tonal Bitcoin

Tonal Bitcoin is a representation of the Bitcoin network aimed toward the minority of people who use the Tonal number system. This is an alternative to decimal and the metric system, which improves usability drastically by allowing for infinite binary division (note that Bitcoin protocol support is still finite). For more information on the Tonal system in general, please see the book.

Please note, that all numbers of TBC and its divisions/multipliers are written in Tonal, not decimal. This means that instead of counting 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10-- you count: 0, 1, 2, 3, 4, 5, 6, 7, 8, , 9, , , , , , 10. Some higher-value digits may require installing a font.

Abbreviation Pronunciation Tonal (TBC) Decimal (BTC)
Tam-Bitcoin 1 0000 0000      2 814 749.767 106 56
ᵇTBC Bong-Bitcoin 1 0000      42.949 672 96
ᵐTBC Mill-Bitcoin 1000      2.684 354 56
ˢTBC San-Bitcoin 100      0.167 772 16
ᵗTBC Ton-Bitcoin 10      0.010 485 76
TBC Bitcoin* 1      0.000 655 36
TBCᵗ Bitcoin-ton 0.1    0.000 040 96
TBCˢ Bitcoin-san 0.01   0.000 002 56
TBCᵐ Bitcoin-mill 0.001  0.000 000 16
TBCᵇ Bitcoin-bong 0.0001 0.000 000 01

* Tonal Bitcoin and Decimal Bitcoin can be differentiated by the pronunciation of the numbers. "One bitcoin", "two bitcoin", etc is decimal, but "an bitcoin", "de bitcoin" is tonal.

The total number of Tonal Bitcoins ever (analogous to the 21mil BTC) is just over 7.75059 tam-bitcoin.

## Compatible Clients

While all Bitcoin clients will correctly approximate values in decimal bitcoin, actual Tonal compatibility is sparse.

• Spesmilo, despite its name, can be configured to display TBC

## Guessing TBC or BTC

Given variable 'value' in base units (uBTCents/TBCᵇ), one can guess whether it is properly Decimal Bitcoin or Tonal Bitcoin with the following pseudo-code:

```if ( ! ( this % 0x10000 ) )
Choose Tonal Bitcoin
if ( ! ( this % 1000000 ) )
Choose Decimal Bitcoin
if ( ! ( this % 0x100 ) )
Choose Tonal Bitcoin
```

### Python

```import math

s = "%0.2f BTC" % (math.ceil(n * 100) / 100.,)
if addSign and n >= 0:
s = "+" + s
return s

def Bitcoin2BTC(n):
return n / 100000000.

toTonalDict = dict(((57, u'\ue9d9'), (65, u'\ue9da'), (66, u'\ue9db'), (67, u'\ue9dc'), (68, u'\ue9dd'), (69, u'\ue9de'), (70, u'\ue9df'), (97, u'\ue9da'), (98, u'\ue9db'), (99, u'\ue9dc'), (100, u'\ue9dd'), (101, u'\ue9de'), (102, u'\ue9df')))

s = "%x" % n
n %= 1
if n:
s += '.'
while n:
n *= 16
s += "%x" % n
n %= 1
s = unicode(s).translate(toTonalDict)
s += " TBC"
if addSign and n >= 0:
s = "+" + s
return s

def Bitcoin2TBC(n):
return n / 65536.

if not n % 0x10000:
if not n % 1000000:
if not n % 0x100:
s = "%d uBTCents" % (n,);
if addSign and n > 0:
s = "+" + s;
return s;```