Path: utzoo!attcan!uunet!modcomp!joe From: joe@modcomp.UUCP Newsgroups: comp.lang.c Subject: Re: non-binary hardware (was: Absolute Message-ID: <8000007@modcomp> Date: 12 Sep 88 02:16:00 GMT References: <297@sdti.UUCP> Lines: 43 Nf-ID: #R:sdti.UUCP:297:modcomp:8000007:000:1634 Nf-From: modcomp.UUCP!joe Sep 11 22:16:00 1988 u-dmfloy@sunset.utah.edu.UUCP writes [edited]: > I've been toying with an idea [on trinary and up logic]. I've done some > preliminary research and it's real sketchy. I've looked at several > alternative trinary logic levels. No one has given me a convincing > argument about which is correct yet. > > For example; Trinary 'AND': > > 0 1 2 0 1 2 > ========= ========= > 0 | 0 0 0 0 | 0 0 0 > 1 | 0 1 2 1 | 0 1 2 > 2 | 0 2 2 2 | 0 2 1 > > > Both have merits. I suppose you could define them as AND2 and AND1. > > Let's see what all of you have to say. I haven't been able to divine what your underlying theories are from just the logic charts you presented, so I remain unconvinced that either is valid. My own pet theory is that n-ary logic should be based on analog logic. By that reasoning, AND returns the lowest of the m input values and OR returns the highest. Inversion should simply flip across the n-ary range. For example, let's look at trinary: AND 0 1 2 OR 0 1 2 INVERSION ========= ========= ===== 0 | 0 0 0 0 | 0 1 2 0 | 2 1 | 0 1 1 1 | 1 1 2 1 | 1 2 | 0 1 2 2 | 2 2 2 2 | 0 It should be possible to build XOR gates, adders, and so on with this logic. However, I haven't tried it. Any takers? More to the point, what have you computer scientists out in net-land, who surely have studied this subject to death decades ago, have to say? -- Joe Korty "flames, flames, go away uunet!modcomp!joe come back again, some other day"