Developers Club geek daily blog

1 year ago
In 1956 there was a need for creation of a practical sample of the digital computer which could be used in higher education institutions, laboratories. For such purposes the effective small computer expected mass use was required simple in mastering, reliable, inexpensive, but at the same time.

Unique Xietun on the basis of a ternary code

The requirements shown to such machine: speed of work had to be equal to several hundred operations per second, simplicity and convenience of programming, accuracy of calculations — 6-8 sure decimal signs, high-reliability in operation and in technical maintenance, moderate dimensions, economical consumption of energy, use of inexpensive and "not scarce" materials and parts "was welcomed". Such requirements for those times were "inconsistent", creation of the machine more convenient for work of programmers would cause increase in quantity of the equipment that, in turn, would entail decrease in reliability and value increase not only the machine, but also its operation.

Ensuring convenience to programmers in addition to the engineering way connected with complication of the machine was implemented in the program way (development of systems of standard subprogrammes, introduction of the compiling and interpreting systems programming programs), use of two-level system of memory, creation of schemes on magnetic elements.

Uses of ternary numeration system

In the 13th century the Italian mathematician Fibonacci put forward idea of use for calculations of ternary system. He formulated and solved "a problem about weights" (Bachet-Mendeleyev, famous under the name). A task essence is as follows: at what system of weights, having them on one, it is possible to weigh free of charge various loads of Q from 0 to the maximum load of Qmax that absolute value of the maximum load of Qmax would be the greatest among all probable versions. Two conditions for a solution of this task: if to put weights on a free bowl of authorities; if weights are allowed to be put on both bowls of authorities. In the first case "the optimum system of weights" is reduced to binary system of weights: 1, 2, 4, 8, 16, etc., and the "optimum" algorithm appearing at the same time or a method of measurement gives rise to the binary numeral system which is the cornerstone of "fashionable" computers. In the second case of the best the system of weights is: 1, 3, 9, 27, 81, etc. If it is possible to put weights only on one bowl of scales, then it is more convenient, quicker and more economically to make calculations in binary system and if it is possible to put weights on both bowls, then it is more reasonable to resort to ternary system.

Feature of ternary numeration system — the tselnochislenny basis is equal in it to three. That is all set of integral numbers can be written by means of only three digits, for example 0, 1, 2, 10, 11, 12 and so on (10 corresponds to digit 3 from usual to us decimal system).

Within a year specialists analyzed and studied already available computers and their technical capabilities, the decision — to apply not a binary, but ternary symmetric code in the machine was as a result made. It would become implementation of balanced numeration system. Development of a ternary computer was undertaken for the first time.

In comparison with the binary code with digits 0, 1, the ternary code with digits-1, 0, 1 provides optimum creation of arithmetics of signed numbers. At it application of the arithmetician has a number of advantages:

  • uniformity of a code of numbers
  • the varied length of operands
  • uniqueness of shift operation
  • three-atomicity of function number sign
  • optimum rounding of numbers simple cutting off of low orders
  • vzaimokompensiruyemost of rounding errors in computation process

Thanks to existence in ternary numeration system of "positive" and "negative" digits, in a code of number there is no special sign digit, and it very much simplifies logic of arithmetic operations. The ternary word is 1,6 times shorter binary, therefore and operations, for example addition operation in the ternary consecutive arithmetic device are executed also 1,6 times quicker, than in binary.

Benefit of ternary numeration system with digits-1, 0, 1 is:

rounding of number x to k of sure ternary signs which turns out discarding of all younger signs, since (k+1).

Consequence. The next whole numbers x,

X=E 1, E 2... E m+1... XE

the number is:

[X] bl = E1, E2... Em

where Ei — ternary digits. Then that the easy way of selection of the next integer part of number simplifies algorithms of calculation ex-potential and trigonometric functions.

this ternary system does not need special polarity bit, the sign of number is defined by a sign of the senior meaning ternary digit. It somewhat simplifies actions with directed numbers.

Contents of any register automatically are considered as a directed number. Shift operations and normalization — are universal and besides strongly simplify programming of action with scales and from a floating comma.

All this is "favorable" for creation of the subprogramme for execution of actions from a floating comma and calculation of elementary functions with the complete computing error which is not exceeding two units of the low order of a mantissa.

As well as the binary system, ternary system of calculation is founded on the position principle of coding of numbers, but i weight - y is equal to the digit position in it not 2 i, but 3 i. Discharges of a trekhznachna, but not a dvukhznachna: to 0 and 1 the third value-1 therefore both positive, and negative numbers are uniformly representable is still allowed.

Value n — a trimester integral number of N is defined similar to value n — bit:

Unique Xietun on the basis of a ternary code

where and i ∈ {1, 0,-1} — value of digit of i of discharge.
(proceeding from the materials which are stored in the virtual computer museum)

The ternary symmetric system of digit designates signs, instead of 1, 0,-1 write +, 0,-.

Decimal numbers will look here is how 13, 7,6,-6 in ternary record 13 = +++, 7 = +-+, = +-0,-6 =-+0. Change of a sign of number in a symmetric code of equally potritny inversion, happens mutual substitution "+" on "-" and vice versa.

The table with addition operations and multiplication in a ternary symmetric code is included below.

Unique Xietun on the basis of a ternary code

In a ternary symmetric code there is no problem of signed numbers.

Unlike binary, it is arithmetics of signed numbers. The sign of number is a digit of the senior from its meaning (nonzero) discharges. The problem of signed numbers which does not have in the binary code of a perfect solution in a ternary symmetric code cannot just be, and this already basic benefit.

Three types of signals created by Basic Element of future ternary computer were called thoriate. If to take bit for a measure of amount of information, then the data capacity of thoriate will be equal to about 1,6. Proceeding from it the ternary computer processes in unit of time more information, than binary.

The minimum addressed unit of memory of the projectible ternary computer became trayt, equal to six thoriates and accepting values from-364 to 364. Work with the range of negative values — the feature distinguishing trayt from binary byte which values extend from 0 to 255.

Thanks to the data capacity of a trayt with its help it is easily possible to code all capital and lower case characters of the Russian and Latin alphabets, mathematical and sample digits.

N. P. Brusentsov spoke:
History of the Xietun computer, as well as this machine, is unusual — everything was made contrary to the commonly accepted approaches and methods. It is possible to think that worked by the principle "Do not as all". But the principle was other — "The more naturally and more simply, the better".

Nikolay Petrovich Brusentsov's destiny — the creator the first and the only ternary machine Xietun in the world is difficult

Unique Xietun on the basis of a ternary code

Nikolay Petrovich Brusentsov in the city of Dniprodzerzhynsk (Ukraine) was born on February 7, 1925. His father Pyotr Nikolaevich Brusentsov was a son of the simple worker — the railroader, participated in construction of the Dniprodzerzhynsk coke-chemical plant, died at very young age of 37 years when Nikolay was only 14 years old. Mother Maria Dmitriyevna remained itself with three children. War began. In 1943 Nikolay was called up for military service and sent to courses of radio operators in Sverdlovsk. Later he became the radio operator of the 154th shooting division in department of investigation 2 divisions of 571 artillery regiments. It was awarded by the medal "For Courage" and an award of the Red Star.

In 1948, having graduated from school perfectly well, arrived on radio engineering faculty of the Moscow power institute. But, having got sick with tuberculosis, the first year of study carried out in treatment. Made up for lost time later and became one of successful students.

After the termination of institute Brusentsov was directed to work in special design bureau at the Moscow university, later in problem laboratory on development of a computer for use in educational institutions. Here he also got acquainted with Sergey Lvovich Sobolev. Sobolev burned with idea of creation of a small computer which would be inexpensive, of a malogabaritn, is reliable for institute laboratories. The seminar in which participated still M.R. Schur Drill, K. A. Semendyaev, E.A.Zhogolev was organized. At seminars sorted shortcomings of the existing machines, estimated an instruction set and structure, considered options of technical implementation, inclining to magnetic elements as transistors were not yet, lamps to a descent excluded, and cores and diodes could be got and to make everything.

Couple of words from Brusentsov's memories of a seminar:
Reports were devoted, on the one hand, to engineering questions of technical implementation of the machine, and with another — to development and optimization of its architecture, the analysis and synthesis of the experience which is available in this case. So, M.R. Schur Drill at four seminars in April-May, 1956 analyzed benefits and shortcomings of Arrow domestic cars, high-speed electronic computer, "Ural", M-20, Sergey Lvovich's employees on the Kurchatov institute G. A. Mikhaylov and B. I. Shitikov told about the machines TsM-1 and TsM-2 created by them, the graduate student of the A.D Tomsk university. Zakrevsky made the report "Application of algebra of logic to circuit synthesis of the computer". Questions of engineering implementation of digital devices on semiconductor and magnetic elements were considered in reports of staff of our department of electronics. I happened to be engaged in development of a functional circuit and instruction set of the machine with E.A. Zhogolev, and results on a measure of promotion were repeatedly represented to a seminar to ours, sometimes joint, reports: 17.9.56 — "The outline scheme of the machine", 15.10.56 — "Operations in ternary numeration system", 11.2.57 — "An instruction set for the single-address ternary machine", 8.4.57 — "The flowchart of the ternary machine", 24.2.58 — "The flowchart and an instruction set of the machine "Xietun".

Then Brusentsov had a thought to use ternary numeration system.

Nikolay Petrovich Brusentsov managed computer laboratory of faculty of calculus mathematics and cybernetics of Moscow State University of M. V. Lomonosov. The main directions it scientific activity were: architecture of digital machines, automated systems of training, the programming system for mini-and microcomputers. It published more than 100 scientific works, including monographs "Small Digital Xietun Computer" (1965, "Minicomputers" (1979), "Microcomputers" (1985), the manual "Basic Fortran" (1982).

Brusentsov Nikolay Petrovich, the winner of an award of Council of ministers of the USSR, possess 11 copyright certificates on inventions. He was awarded the order "Honour Sign", the Big gold medal of ENEA CCC.

In 2014 at the age of 90 years the famous designer of ternary computers, the scientist Brusentsov Nikolay Petrovich died. As his friends remembered, it was very modest, pleasant person in communication, always ready to come to the rescue.

In Computer center of MSU Xietun which became the first machine with alphanumeric input devices and an output in the USSR was created.

In development of a computer active part was taken by the Soviet mathematician Sergey Lvovich Sobolev, for that time he was the head of the department of calculus mathematics at mekhaniko-mathematical faculty of the Moscow university. The group of the beginning employees was engaged in creation and development of the machine Xietun, it were 8 graduates of MEI and MSU, 12 technicians and laboratory assistants. Work was done enough in a short space of time that directly testified to simplicity of ternary digital equipment, essential simplification, naturalness of architecture of ternary devices was reached. Such architecture — rationally constructed programming system which included the interpreting IP-2 systems (a floating comma of 8 decimal signs), IP-3 (a floating comma, 6 decimal signs), IP-4 (complex numbers, 8 decimal signs), IP-5 (a floating comma, 12 decimal signs), the autocode of POLIZ (language of reverse Polish notation) with an operating system and library of standard subprogrammes (a floating comma, 6 decimal signs) did the small machine Xietun idle time in mastering.

Unique Xietun on the basis of a ternary code

The machine Xietun with the minimum command set, 24 single-address commands, did calculations with fixed and from a floating comma, did addition operation with work which optimized calculation of polynoms, three conditional jump instructions on a result sign, operation of digit-by-digit multiplication, had an index register. An index register it was possible not only to add value, but also to read at modification of the address.

At the end of 1959 for the machine there was already a programming system and a set of application programs.

Machine parameters

The area of 25-30 sq.m in size was necessary for installation of the small machine Xietun, it was issued in the form of a cabinet with such parameters of 2,9 x 1,85 x 0,5 m, the control panel 1,6 x 0.6 x 1 m, a table for external devices 1,2 x 0,8 x 0,75 m.

Unique Xietun on the basis of a ternary code

As well as it was mentioned before number and commands are provided by a ternary code (with digits 1, 0,-1), Xietun operated with 18 bit and 9 bit ternary codes, a comma always after the second discharge that meant that all numbers on the module less than 4,5. Commands were represented by 9 ternary discharges, 5 seniors from them — address part, three is a code of operation and one, low order — as a sign of modification of the address. At execution of the commands containing in this discharge 1 or-1, their address part automatically changed respectively addition or subtraction of the number which is stored in special the 5th bit an index register.

Random access memory consisted of the device on ferrite cores with a capacity of 162 9-tritny cells, that is is separated into 3 pages on 54 cells for a page-by-page exchange with base memory. The base memory is a memory device on a magnetic drum, with a capacity of 36 or 72 pages (1944 9-tritny cells). Information transfer between memory devices was made by the zones containing 54 nine-bit codes. By means of a five-position paper punched tape via the photo-electric input device data were entered into the machine. Such input device worked with speed of 800 signs per second. The data output was performed thanks to printing and perforation on the paper strip with a speed of 7 signs per second (an output of both ternary codes, and the alphanumeric text with a task of any form of the form).

Unique Xietun on the basis of a ternary code
Punched tape

The cell representing ferrite - the diode magnetic amplifier assembled on a getinaksovy basis became structural unit of the computer, cells in turn were arranged in functional blocks (adders, decoders of a ternary code, registers of shift).

Unique Xietun on the basis of a ternary code

Unique Xietun on the basis of a ternary code
Ferrite cube

The special high-speed magnetic amplifier which consisted of the miniature transformer with the ferrite core and the semiconductor diode was developed. Amplifiers united with each other without means of electric parts, an exception - bonding wires. The innovation increased reliability of the machine and reduced energy consumption. In Xietun there were 3500 such magnetic amplifiers.

The machine from a network of a three-phase current 220/380B was powered, power consumption made 2,5 kVA.

Xietun consisted of six functional devices (Brusentsov N. P. Xietun computer Moscow state 259): the arithmetic device, a control device, a random access memory, the input device, the output device, a memory device on a magnetic drum.

Unique Xietun on the basis of a ternary code
Flowchart of the Xietun computer

Factory tests of the first serial sample of Xietun showed that the machine completely corresponds to the put technical parameters. Everything ran smoothly and effective time made 95% of test. For the first year from 4000 parts only three parts were replaced. 7 such small computers were let out, during 1963 were planned to make 10 more such machines. In 1964 the plant released 21 machines Xietun as demand of dews for them. But in 1965 Xietun was laid off.

Since 1959 Xietun in one and a half months displayed more calculations, than a computer the Urals-2 with binary numeral system. The small machine Xietun worked smoothly, but to officials such computer was not profitable — its cost value was only 30 000 rubles. The first Xietun model was in work of 15 years. The mass production was decided to postpone for 15 years, but it did not occur. As the creator of the machine Brusentsov spoke then: "Xietun disturbed people with inert thinking who held the high leading posts". Eventually Xietuns cut autogenous cutting and sent for utilization.

In 1967-1969 on the basis of the machine Xietun its advanced version — the ternary digital machine Xietun 70 — the machine was developed. "the nonconventional two-stack architecture oriented to providing favorable conditions for further development of its opportunities by method of the interpreting systems".

Own programming language — DSSP was developed for Setun-70. The principle of this programming language — "the word is the word", it meant that one word of the program corresponds to one word of a code. The two-stack architecture, dictionaries, support of the descending programming, high-level structures of data and operation, a compact code, and also mobility, flexibility, the soprogrammny mechanism is characteristic of DSSP.

DSSP exceeds Forth in many parameters. The DSSP language possesses significantly lower, than assembler language labor input in programming, without conceding to it in compactness of a code and high-speed performance, allows to check work of subprogrammes in an interactive mode and has a possibility of modification of programs practically without modification of other parts of a code.

There are no other computers on the basis of a ternary code and was not.

History creation of the machine Xietun

According to the creator Xietun Brusengcuov:
Now many countries try to create the ternary computer, but all attempts are unsuccessful: people so got used to binary logic that it is difficult to them to master ternary. However it is a controversial issue: it is unlikely for all these years nobody guessed any more before making the hardware of such computer. And if around the world in the computer industry use binary system, and on ternary still nobody passed, then, perhaps, there is no need for it and.

By tradition, there is a little advertizing in the cellar where it will prevent nobody. Our company started New Year's sale of servers and VPS within which it is possible to receive from 1 to 3 months of lease free of charge. You can get acquainted with event details here.

This article is a translation of the original post at
If you have any questions regarding the material covered in the article above, please, contact the original author of the post.
If you have any complaints about this article or you want this article to be deleted, please, drop an email here:

We believe that the knowledge, which is available at the most popular Russian IT blog, should be accessed by everyone, even though it is poorly translated.
Shared knowledge makes the world better.
Best wishes.

comments powered by Disqus