Изобретение относитс к области автоматики и вычислительной техники и может быть использовано дл постро ени арифметических устройств специализированных цифровых вычислитель ных машин и приборов, в которых требуетс получить результат алгебраиче кого сложени большого количества двоичных чисел, представленных параллельным дополнительньм или обратным кодом. По основному авт. св. № 1022153 известно устройство дл суммировани двоичных чисел, содержащее накаплива ющий сумматор, счетчик, первый и вто рой элементы запрета, первый и второй элементы И, причем входы накапли вающего сумматора подключены к разр дам входной шины устройства, а выходы соединены с младшими разр дами выходной шины устройства, выход первого элемента И соединен с входом вычитани счетчика, выходы разр дов которого соединены со старшими разр дами выходной шины устройства и с вы ходной шиной знака устройства, инфор мационный вход первого элемента запрета соединен с управл ющим входом второго элемента запрета, а управл юшзнй вход первого элемента запрета подключен к информационному входу второго элемента запрета, выход второго Элемента И соединен с входом сложени счетчика, первый вход перво го элемента И соединен с первым входом второго элемента И и с входом синхронизации устройства, вторые вхо ды первого и второго элементов И соединены с выходами соответственно первого и второго элементов запрета, управл ющий вход первого элемента запрета соединен с выходом переноса старшего разр да накапливающего сумматора , информационный вход первого элемента запрета соединен с входной шиной знака устройства lj . Дл работы этого устройства отрицательные числа должны быть представ лены параллельным обратным кодом. Цель изобретени - расширение функциональных возможностей устройства путем обеспечени возможности суммировани двоичных чисел, предста ленных как дополнительным, так и обратным кодом. Поставленна цель достигаетс тем, что устройство дл суммировани двоичных чисел содержит первый и второй элементы ИЛИ, третий, четвертый , п тый и шестой элементы И и элемент НЕ, причем вход выбора режима устройства соединен с первыми входами третьего, четвертого и п того элементов И, выходы которых соединены соответственно с первым, вторым и третьим входами первого элемента ИЛИ, выход которого соединен с входом переноса накапливающего сумматора, знаковый вход устройства соединен с вторыми входами третьего и четвертого элементов И, знаковьм выход счетчика и выходы разр дов счетчика соединены с входами шестого элемента И и с входами второго элемента ИЛИ, выход шестого элемента И соединен с вторым входом п того элемента И, третий вход которого подключен к выходу второго элемента запрета , выход второго элемента ИЛИ соединен с третьим входом четвертого элемента И и входом элемента НЕ, выход которого соединен с третьим входом третьего элемента И, четвертый вход которого подключен к выходу переполнени накапливающего сумматора. На чертеже представлена блок-схема устройства. Устройство содержит накапливающий сумматор 1, счетчик 2, элементы запрета 3, 4, элементы И 5-10, элементы ИЛИ 11, 12, элементы НЕ 13, знаковьй вход 14 устройства, разр дные входы 15 устройства, вход синхронизации 16 устройства, вход выбора режима 17 устройства, младшие разр дные выходы 18 устройства, старшие разр дные выходы 19 устройства,знаковый выход 20 устройства. Устройство работает следующим образом . Каждое число, поступающее на входы 15, 14 устройства, представлено п информационными и одним знаковым разр дами, а результат m+n информационными и также одним знаковым разр дами , где пит- количество разр дов сумматора 1 и счетчика 2 соответственно . Положительные числа кодируютс пр мыми, а отрицательные могут кодироватьс дополнительными или обратными кодами, в зависимости от сигнала на входе выбора режима 17. Устройство позвол ет суммировать массивы чисел путем алгебраического сложени очередного (k+1)-ro (п+1)разр дного , включа знаковый разр д. входного слагаемого, поступающего на входы 15, 14 устройства, с резуль татом сложени предыдущих k чисел, хран щихс в накапливающем сумматоре 1 и снетчике 2. Входные слагаемые могут быть положительными или отрица тельными. Устройство, содержащее m+n информационных разр дов, в самом неблагопри тном случае (суммируютс числа только одного знака и максимальные по модулю) допускает сложение 2m(п+1)-разр дных чисел, включа знаковьш разр д входных двоичных чисел. Если поступающие отрицательные числа представлены дополнительным ко дом, то на вход 17 выбора режима подаетс сигнал О, в результате на входе переноса сумматора 1 - всегда нуль. Если очередное поступившее на входы 15, 14 устройства число положи тельное, то оно складываетс в сумматоре 1 с младшими п разр дами накопленной суммы. Если при сложении возникает перенос на выходе переноса сумматора 1, то через элемент запрета 3 и элемент И 5 сигнал об.этом по синхросигналу с входа 16 поступает на суммирующий вход счетчика 2, и к (п+1)-му разр ду накопленной суммы будет прибавлена единица. Если же очередное поступившее на входы 15, 14. устройства число отрица тельное, то на знаковом входе 14 устройства 1, котора при отсутствии переноса на выходе сумматора 1 через элемент запрета 4 и элемент И 6 по синхросигналу с входа 16 поступит на вычитающий вход счетчика 2, имитиру сложение накопленной суммы с числом, в разр дах которого с (п+1)-го по т-й единицы. Значени разр дов с 1-го по п-й поступают по разр дным входам 15 устройства на вход сумматора 1. Если поступающие- отрицательные . числа представлены обратным кодом, то устройство функционирует аналогично , однако Hi вход 17 выбора режима подаетс 1, на вход переноса сумматора 1 поступает циклический перенос в следующих случа х: во всех разр дах счетчика 2 - нули, а, поступающее число - отрицательное, т.е. накопленна сумма равна 0,00 ...О, ...X, а поступающее число равно 1, 11... 1, XX...X, где X - безразличное состо ние разр да, а зап тыми отделены знаковый разр д и п-й разр д, при этом имеетс сигнал на выходе переноса сумматора 1, т.е. перенос в (п+1)-й разр д, в этом случае единичный сигнал будет, на выходе элемента И 7; поступающее число - отрицательное , и в разр дах накопленной суммы с (п+1)-го по т-й (либо в знаковом) есть хот бы одна единица, т.е. если поступающее число равно I, II ... I, XX ... X, а накопленна сумма равна Y, YY ... Y, XX ...X, где Y - разр ды , хот бы один из которых отличает от нул , в этом случае единичный сигнал будет на выходе элемента И 8; во всех разр дах счетчика 2 - единицы , а поступающее число - положительное , т.е. накопленна сумма равна I, II ... 1, XX ... X, а поступающее число равно О, 00 ...О, хх ... х при этом имеетс сигнал на выходе переноса сумматора 1, т.е. перенос в (п+1)-й разр д, в этом случае единичный сигнал будет на выходе элемента И 9. Положительный эффект изобретени заключаетс в расширении функциональных возможностей - нар ду с представлением отрицательных чисел дополнительными кодами устройство позвол ет представл ть отрицательные числа и обратным кодом.The invention relates to the field of automation and computer technology and can be used to build arithmetic devices of specialized digital computers and devices in which it is required to obtain the result of the algebraic addition of a large number of binary numbers represented by parallel additional or reverse code. According to the main author. St. No. 1022153, a device for summing binary numbers is known, which contains an accumulating adder, a counter, the first and second prohibition elements, the first and second elements AND, the inputs of the accumulator adder being connected to the device input bus bits, and the outputs are connected to the lowest output bits device bus, the output of the first element I is connected to the subtraction input of the counter, the outputs of the bits of which are connected to the higher bits of the device output bus and to the output bus of the device sign, the information input of the first element and the prohibition is connected to the control input of the second prohibition element, and the control input of the first prohibition element is connected to the information input of the second prohibition element, the output of the second element I is connected to the addition input of the counter, the first input of the first element I and to the synchronization input of the device, the second inputs of the first and second elements I are connected to the outputs of the first and second elements of the prohibition, respectively; the control input of the first prohibition element is connected to the transfer output of the old its discharge of the accumulator, the data input of the first element is connected to the input prohibition bus device lj sign. For this device to work, negative numbers must be represented by a parallel reverse code. The purpose of the invention is to enhance the functionality of the device by allowing the addition of binary numbers represented by both additional and reverse code. The goal is achieved by the fact that the device for summing binary numbers contains the first and second elements OR, the third, fourth, fifth and sixth elements AND and the element NOT, with the device mode selection input connected to the first inputs of the third, fourth and fifth elements AND, the outputs of which are connected respectively to the first, second and third inputs of the first element OR, the output of which is connected to the transfer input of the accumulating adder, the sign input of the device is connected to the second inputs of the third and fourth elements AND, W The counter output and outputs of the counter bits are connected to the inputs of the sixth And element and to the inputs of the second OR element, the output of the sixth And element is connected to the second input of the fifth And element, the third input of which is connected to the output of the second prohibition element, the output of the second element OR is connected to the third input of the fourth element AND and the input of the element NOT, the output of which is connected to the third input of the third element AND, the fourth input of which is connected to the overflow output of the accumulating adder. The drawing shows the block diagram of the device. The device contains accumulator 1, counter 2, prohibition elements 3, 4, elements AND 5-10, elements OR 11, 12, elements NOT 13, sign input 14 of the device, bit inputs 15 of the device, synchronization input 16 of the device, mode selection input 17 devices; lower bit outputs 18; devices; higher bit outputs 19 of the device; sign output 20 of the device. The device works as follows. Each number arriving at the inputs 15, 14 of the device is represented by n information and one sign bits, and the result m + n is information and also one sign bits, where pit is the number of bits of adder 1 and counter 2, respectively. Positive numbers are encoded direct, and negative numbers can be encoded with additional or reverse codes, depending on the signal at the input of mode selection 17. The device allows summing up arrays of numbers by algebraically adding the next (k + 1) -ro (n + 1) bit, including the sign bit of the input term entering the inputs 15, 14 of the device, with the result of adding the previous k numbers stored in accumulative adder 1 and the search bar 2. The input terms can be positive or negative. A device containing m + n information bits, in the most unfavorable case (numbers of only one sign and maximum in modulus are summed up), allows the addition of 2m (n + 1) -bit numbers, including the sign bits of the input binary numbers. If the incoming negative numbers are represented as additional code, then the mode selection signal O is applied to the mode selection input 17, and as a result, the transfer input of the adder 1 is always zero. If the next number arriving at the inputs 15, 14 of the device is positive, then it is added up in the adder 1 with the lower n bits of the accumulated sum. If adding a transfer occurs at the transfer output of the adder 1, then through the prohibition element 3 and the element 5 the signal from this signal is sent from the input 16 to the summing input of counter 2, and the (n + 1) th discharge of the accumulated amount will be added one. If the next number input to inputs 15, 14. of the device is negative, then on the sign input 14 of device 1, which in the absence of transfer at the output of adder 1 through prohibition element 4 and element 6 of the clock signal from input 16 will go to the subtracting input of counter 2 , imitating the addition of the accumulated sum with the number, in the bits of which c (n + 1) -th by the m-th unit. The values of bits 1 through 1 are received by the bit inputs 15 of the device to the input of the adder 1. If the incoming ones are negative. the numbers are represented by the reverse code, then the device functions in the same way, however, the Hi mode selection input 17 is fed 1, the transfer input of adder 1 receives cyclic transfer in the following cases: in all bits of counter 2 - zeros, and the incoming number is negative, m. e. the accumulated amount is equal to 0.00 ... O, ... X, and the incoming number is equal to 1, 11 ... 1, XX ... X, where X is an indifferent state of discharge, and the character bit is separated by a comma and the p-th bit, and there is a signal at the transfer output of the adder 1, i.e. the transfer to (n + 1) -th bit, in this case, the single signal will be at the output of the element And 7; the incoming number is negative, and there is at least one unit in the bits of the accumulated sum of the c (n + 1) th of the mth (or in the sign) if the incoming number is equal to I, II ... I, XX ... X, and the accumulated sum is equal to Y, YY ... Y, XX ... X, where Y - bits, at least one of which differs from zero In this case, a single signal will be at the output of the element And 8; in all bits of the counter 2 - units, and the incoming number is positive, i.e. the accumulated sum is equal to I, II ... 1, XX ... X, and the incoming number is O, 00 ... O, xx ... x and there is a signal at the transfer output of adder 1, i.e. the transfer to the (n + 1) -th bit, in this case, a single signal will be at the output of the element 9. The positive effect of the invention is in extending the functionality — in addition to representing negative numbers with additional codes, the device allows for negative numbers and code