Sunteți pe pagina 1din 2

TERNARY NUMERAL SYSTEM

Numbers one to twenty-seven in standard ternary


2
10
11
12
20
21
22 100
Ternary 1
1
10
11 100 101 110 111 1000 1001
Binary
Decimal 1
2
3
4
5
6
7
8
9
Ternary 101 102 110 111 112 120 121 122 200
Binary 1010 1011 1100 1101 1110 1111 10000 10001 10010
Decimal 10
11
12
13
14
15
16
17
18
Ternary 201 202 210 211 212 220 221 222 1000
Binary 10011 10100 10101 10110 10111 11000 11001 11010 11011
Decimal 19
20
21
22
23
24
25
26
27
Powers of three in ternary
1
10
100
1 000
10 000
Ternary
1
11
1001
1 1011
101 0001
Binary
1
3
9
27
81
Decimal
0
1
2
3
Power
3
3
3
3
34
Ternary 100 000
1111
Binary
0011
243
Decimal
Power
35

1 000 000
10 1101
1001
729
36

10 000 000
1000 1000
1011
2 187
37

100 000 000


1 1001 1010
0001
6 561
38

1 000 000 000


100 1100 1110
0011
19 683
39

As for rational numbers, ternary offers a convenient way to represent one third (as
opposed to its cumbersome representation as an infinite string of recurring digits in
decimal); but a major drawback is that, in turn, ternary does not offer a finite
representation for one half (neither for one quarter, one sixth, one eighth, one tenth,
etc.), because 2 is not a prime factor of the base.

Ternary
Binary
Decimal
Fraction

0.1
0.1
0.5
1/2

0.1
0.01
0.3
1/3

Fractions in ternary
0.02
0.0121
0.01
0.01
0.0011
0.001
0.25
0.2
0.16
1/4
1/5
1/6

0.010212
0.001
0.142857
1/7

0.00211
0.002
0.002
Ternary 0.01 0.01 0.0022
Binary 0.001 0.000111 0.00011 0.0001011101 0.0001 0.000100111011
0.1
0.09
0.083
0.076923
Decimal 0.125 0.1

TERNARY NUMERAL SYSTEM


Fraction 1/8

1/9

1/10

1/11

1/12

1/13

[edit] Sum of the digits in ternary as opposed to binary


We know that the value of a binary number with n bits that are all 1 is 2n-1.
Similarly, for a number N(b,d) with base b and d digits, all of which are the maximum
digit value b - 1, we can write
N(b,d) = (b-1) bd-1 + (b-1) bd-2 + + (b-1) b1 + (b-1) b0,
N(b,d) = (b-1) (bd-1 + bd-2 + + b1 + 1),
N(b,d) = (b-1) M.
b M = bd + bd-1 + + b2 + b1, and
- M = - bd-1 - bd-2 - - b1 - 1, so
b M - M = bd - 1, or
M = ( bd - 1 ) / ( b - 1 ).
Then, N(b,d) = (b-1) M,
N(b,d) = (b-1) ( bd - 1 ) / ( b - 1 ), and
N(b,d) = bd - 1.
For a 3 digit Ternary number, N(3,3) = 33 - 1 = 26 = 2 x 32 + 2 x 31 + 2 x 30 = 18 + 6
+ 2.

S-ar putea să vă placă și