In this chapter we present example algorithms as expressed in wiring diagrams and intended for a logically reversible computer. Originally inspired by models of human memory and cognition, the programming as expressed in these wiring diagrams applies to a parallel computer in which many nanoprocessors work concurrently. Nanoprocessors are especially small and simple microprocessors based on toggle memory; they were presented in a practical way assuming CMOS technology and VLSI, although the logic may be transferred to better technology as it evolves, such as molecular logic. The end result is assumed to be an electrically and logically reversible system easily programmed using a standard wiring diagram to solve a variety of problems.
By tracing the examples below, an interested reader can learn reversible programming in a wiring diagram. The arithmetic in this chapter differs from the simple addition and subtraction of Chapter 8 in that it employs iteration within a wiring diagram. To accomplish an iterative calculation, a program segment must be designed properly so that is can be replicated adjacent to similar segments as many times as necessary.
Nanoprocessor words must first be loaded with a desired set of operands to be processed in parallel. In an attempt to achieve clarity, in this chapter arithmetic is limited to two binary operands in each word of nanoprocessor memory. Binary results for given operands ...