Page:Alan Turing - Proposed Electronic Calculator (1945).pdf/31

This page has been proofread, but needs to be validated.

– 30 –

Outline of operation. TS 8 is transferred to TS 2 and then subtracted from zero, passing into the partial sums register TS 4, TS 5. By taking out TS 5 we obtain a minor cycle full of digits 1 or of digits 0 according as there was or was not a digit 1 in TS 8 originally. We then form (TS 5 & TS 15) v (~TS 5 & TS 16) by logical operations and pass it on to TS 24.

This table provides the main means of deciding between two alternative procedures, by setting up one or the other of two instructions, contained in TS 15 or TS 16.

PLUSIND (General Description). 1 is added to the position reference in TS 27, e.g. DL 7, 9 becomes DL 7, 10, but DL 7, 32 becomes DL 8, 1.

TRANS 45 (General Description). The following set of transfers is made

TS 22 - TS 20, TS 23 - TS 21.

BURY (General Description). The content of TS 1 with 1 added is transferred to the position indicated in TS 31, and 1 is added to the reference in TS 31. We then proceed to carry out the instruction in TS 1.

UNBURY (General Description). The minor cycle whose position is given in TS 31 is taken to be position of the next instruction.

MULTIP (General Description). The number in TS 18, 19 is multiplied by the number in TS 20, 21: the result is brought to standard form by shift of decimal point. An error is obtained for the product by using the errors in the given numbers and allowing for rounding off. The result is stored in TS 22, 23.

ADD is analogous to MULTIP.

As an example of a more complicated process, I have chosen the calculation of the value of a polynomial.

CALPOL (General Description). The minor cycles of DL 3 taken in pairs contain the coefficients of a polynomial in descending order. Evidently we are restricted to degrees not exceeding 15, and we assume the degree always to be 15, filling up with appropriate zero coefficients. The value of this polynomial will be calculated for the argument in TS 13, TS 14 and the result will be transferred to TS 25, 26. Before starting we require special contents in DL 1, 14 and DL 1, 15. There are

DL 1, 14 0000,0101,0000,0000,0100,0110,0000,0000

DL 1, 15 0000,0000,0000,0000,0000,0100,0000,0000

the expression in DL 1, 14 representing the order to transfer DL 3,1 to TS 6.

CALPOL/