Maybe you should take a more serious look at the balanced ternary number system. (described in TAOCP, vol. 2 ch. 4.1, p207, you've probably already read about it)

Knuth says it is "perhaps the prettiest number system of all," and it has some properties that are quite beautiful. For those who aren't familiar with balanced ternary notation, it's similar to what you would expect of base 3 - except, instead of the digits 0, 1 and 2, one uses -1, 0 and 1 (-1 being denoted by a 1 with a bar over it).

Like negabinary, this system is unsigned; instead, the sign is captured in the representation of the number itself. And, according to Knuth, a balanced ternay representation of a number requires only about 63% as many digit positions as its binary representation.

There were even a number of computers built based on the balanced ternary system. Instead of using "off" and "on" in an electrical system, I assume one would use "positive," "negative," and "off" voltages, which is really an interesting concept.


In reply to Re: Negabinary Number System by Cirollo
in thread Negabinary Number System by srawls

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.