Claims (2)
первого дешифратора подключены к входам первых групп первого и второго матричных сумматоров, выходы второго дешифратора через первый и второй ключи подключены соответственно- ко входам второй группы.первого матричного сумматора и входам первой группы второго матричного сумматора , выходы третьего дешифратора через третий ключ подключены ко входам второй группы третьего матричного сумматора, выходы которого соединены со входами второй группы второго матричного сумматора, выходы первого и второго матричных сумматоров и. первого дешифратора соединены с выходом устройства, управл ющие входы ключей соединены со входом устройства. В полиадическом коде п-разр дное число А может быть представлено в виде: ,.-...anQK, (i) Qt+1 (,НХ1 1,г,...п) Тогда ,taiPlta5P,Pit.,.,H,...PnM. (г) где числа Pi, Рг,..- fn, - основани полиадического , кода. Пусть числа PI, Рг,...Рп, служат одновременно основанием системы остаточных классов (СОК) и полиадического кода. Пред ставление числа А в полиадическом коде можно записать в виде A (ai,Qi,-.-an). Диапазоны чисел однозначно представлены в построенных указанным образом СОК и полиадическом коде совпадают. Поэтому можно говорить о наличии однозначного соответстви между множеством представлений чисел в СОК A W,)o(i,...ti;,rAeo{: pesl ACmodPt), (Ul,2,...ti.)(А) и множеством представлений чисел в полиадическом коде . /(ai,aj.,...an) (5) Пусть известно представление числа А в полиадическом коде (5). Требуетс найти его представление в СОК. Так как основани в СОК посто нны, то представление чисел Qi,Qz.-- Qn в СОК известны q,(M.--i), (q.o,,.Q), Cl3--(0,O.QLQj), Q..(0,0,...0,). Тогда из формулы (1) следует, что цифры , ota оСа можно найти следующим образом: в(, а, (mod PI), (woolP2)j 5 a,4aiql -aiQ|(tr,od Pj), o( c(,Qi(+...taaQn x РП). Если вз ть схему преобразовател полиадического кода в код системы остаточных классов дл трех модулей (, Рг 3, РЗ 5), то, исход из выражений (6), дл выбранной системы модулей числа Qi, Q2 и РЗ можно представить в виде: Q 1 (1,1,1), Qa 2 (0,2,2), (0,01), а числа ai, dz. и d согласно выражению ( 7) можно представить в виде: d ttimodPi, c/i ai + az2modPz, ai + 2 a2-I-QjmodPa. Ha чертеже представлена схема преобразовател полиадического кода в код СОК. Преобразователь содержит входной регистр 1 с блоками 2 разр дов, дешифраторы 3, 4 и 5, которые предназначены дл преобразовани значени разр дов числа, представленного в полиадическом коде в код позици -число, выходы б, представл ющие остатки чисел по основани м выбранной системы , ключи 7, 8 и 9, предназначенные дл формировани произведений коэффициентов полиадического кода (cxi) и чисел Q (где 1 2, 3,...п); матричные сумматоры 10, 11 и 12, предназначенные дл суммирова ни. по соответствующему модулю значений произведений , полученных на выходе ключей, вход 13, соответствующий значению числа Qa, вход 14, соответствующий значению числа Рг, 15, соответствующий значению чисел Qz, Qj и Qj. Блоки 2 разр дов необходимы дл хранени чисел, представленных в полиадическом коде. Преобразователь работает следующим образом. Код числа А, дл которого необходимо получить представление в СОК, принимаетс на блоки 2 входного регистра 1, причем коэффициенты ai представлены в двоичной форме. Сигналы с выхода регистра поступают на вход дешифраторов 3, 4 и 5. На выходе дешифраторов образуетс код позици -число . Выходной сигнал дешифратора 5 есть остаток ai числа А по основанию Р| и поступает на выход и на вход матричных сумматоров 11 и 12. Выходной сигнал дешифратора 4 поступает на информационный вход ключей 7 и 9. Выходной сигнал дешифратора 3 поступает на информационный вход ключа 8. На управл ющие входы ключей 7, 8 и 9 поступают соответственно коды чисел Qa, Qj, Qz (входы 13, 14 и 15). На выходах ключей формируютс следующие сигналы: ключ 7 - сигнал, соответствующий значению Ч-гРг (mod Р) ключ 8 - сигнал, соответствующий значению QsQl (modPs) ключ 9 - сигнал, соответствующий значению ctzQz (modP;). Сигналы с выходов поступают на один из входов матричных сумматоров. Так, с выхода ключа 7 сигнал поступает на один из входов матричного сумматора 12. На вторые входы сумматора 12 поступает сигнал с выхода дешифратора 5. В сумматоре происходит сложение величинами QiQz по модулю Рг. Выходное значение сумматора 12 есть представление остатка числа А по модулю Сигналы с выхода ключей 8 и 9 поступают на вход сумматора 10, в котором формируетс сумма слагаемых ctjQs + -f ajQa (mod РЗ). Выходной сигнал сумматора 10 поступает на входы сумматора 11, а на другие входы этого сумматора поступает сигнал с выхода дещифратора 5. Выходной сигнал сумматора 11 есть представление числа А по модулю Pj. Таким образом, на выходе преобразовател формируютс сигналы, соответствующие представлению числа А в СОК. Если устройство реализовано на комбинационных элементах, то преобразование числа осуществл етс за один такт при любом количестве модулей, при этом входы 13, 14 и 15 замкнуты (на чертеже показано пунктиром) и управл ющий сигнал, соответствующий числам Qa, Qz, Qs поступает на вход 16. Если преобразователь реализован на интегральных схемах, то ему присуще простота и больща надежность. Врем преобразовани определ етс суммарной задержкой сигнала в блоках 3, 8, 10 и 11. Пример. Пусть известно представление числа А в полиадическом-коде А( 1,0,2). Найти представление числа в СОК. На вход регистра поданы коэффициенты Qi в двоичной форме А (01, 00, 010). На выходе преобразователь получает сигналы , соответствующие числу А в СОК, А (1, 1, 3). причем число А представлено в однопозиционном коде. Если требуетс представить значени остатков в двоичной форме, то необходимо на выходе преобразовател включить щифраторы, которые представл ют собой набор элементов ИЛИ, (преобразование числа дл приведенного примера на чертеже показано пунктирными лини ми ). Использование предлагаемого изобретени в вычислительных мащинах позвол ет повысить быстродействие за счет уменьшени времени выполнени операций сложени , вычитани и умножени , сокращает объем оборудовани . Реализаци преобразовател на интегральных схемах обеспечивает экономический эффект. Формула изобретени Преобразователь полиадического кода в код системы остаточных классов, содержащий входной регистр и матричные сумматоры , отличающийс тем, что, с целью повышени скорости вычислений, в него дополнительно введены дещифраторы и ключи , причем выходы первой, второй и третьей групп разр дов входного регистра подключены соответственно ко входам первого , второго и третьего дешифраторов, выходы первого дещифратора подключены к входам первых групп первого и второго матричных сумматоров, выходы второго дешифратора через первый и второй ключи подключены соответственно ко входам второй группы первого матричного сумматора и входам первой группы второго матричного сумматора, выходы третьего дешифратора через третий ключ подключены ко входам второй группы третьего матричного сумматора , выходы которого соединены со входами второй группы второго матричного сумматора , выходы первого и второго матричных сумматоров и первого дешифратора соединены с выходом устройства, управл ющие входы ключей соединены со входом устроиства . Источники информации,. прин тые во внимание при экспертизе 1.Авторское свидетельство СССР № 315176, кл. G 06 F 5/02, 1969. the first decoder is connected to the inputs of the first groups of the first and second matrix adders, the outputs of the second decoder through the first and second keys are connected respectively to the inputs of the second group. the first matrix adder and the inputs of the first group of the second matrix adder, the outputs of the third decoder through the third key are connected to the inputs of the second group of the third matrix adder, the outputs of which are connected to the inputs of the second group of the second matrix adder, the outputs of the first and second matrix adders and. the first decoder is connected to the output of the device, the control inputs of the keys are connected to the input of the device. In a polyadic code, an n-bit A can be represented as:,.-... anQK, (i) Qt + 1 (, НХ1 1, г, ... п) Then, taiPlta5P, Pit.,., H, ... PnM. (d) where the numbers Pi, Pr, ..- fn, are the bases of the polyadic code. Let the numbers PI, Pr, ... Pn, simultaneously serve as the basis of the system of residual classes (SOC) and the polyadic code. The representation of the number A in a polyadic code can be written as A (ai, Qi, -.- an). The ranges of numbers are uniquely represented in the SOC constructed in this way and the polyadic code are the same. Therefore, it is possible to speak about the presence of a unique correspondence between the set of representations of numbers in the SOK AW,) o (i, ... ti;, rAeo {: pesl ACmodPt), (Ul, 2, ... ti.) (A) and the set of representations numbers in the polyadic code. /(ai,aj.,...an) (5) Let the representation of the number A in the polyadic code (5) be known. It is required to find his presentation in the JUICE. Since the bases in the SOC are constant, then the representation of the numbers Qi, Qz .-- Qn in the SOC is known q, (M .-- i), (qo ,,. Q), Cl3 - (0, O.QLQj), Q .. (0,0, ... 0,). Then from formula (1) it follows that the numbers, ota of ° C can be found as follows: in (, a, (mod PI), (woolP2) j 5 a, 4aiql -aiQ | (tr, od Pj), o (c ( , Qi (+ ... taaQn x RP). If you take the polyadic code converter circuit into the code of the system of residual classes for three modules (, Pr 3, РЗ 5), then, based on expressions (6), for the selected system of modules Qi, Q2 and RZ can be represented as: Q 1 (1,1,1), Qa 2 (0,2,2), (0,01), and the numbers ai, dz. And d according to expression (7) can be Represented as: d ttimodPi, c / i ai + az2modPz, ai + 2 a2-I-QjmodPa. The drawing shows a diagram of a polyadic code converter into a JUICE code. contains an input register 1 with blocks of 2 bits, decoders 3, 4 and 5, which are designed to convert the value of the bits of the number represented in the polyadic code to the code position-number, outputs b, representing the remains of the numbers on the basis of the selected system, keys 7, 8, and 9, intended to form the products of the coefficients of the polyadic code (cxi) and the numbers Q (where 1 2, 3, ... n); matrix adders 10, 11, and 12, intended for summation. on the corresponding module of the values of products obtained at the output of the keys, input 13, corresponding to the value of the number Qa, input 14, corresponding to the value of the number Pr, 15, corresponding to the value of the numbers Qz, Qj and Qj. Blocks of 2 bits are necessary for storing numbers represented in the polyadic code. The Converter operates as follows. The code for the number A, for which it is necessary to obtain a representation in the SOC, is accepted into blocks 2 of input register 1, with coefficients ai represented in binary form. The signals from the register output are fed to the input of the decoders 3, 4, and 5. At the output of the decoders, a position-number code is formed. The output signal of the decoder 5 is the remainder ai of the number A at the base P | and goes to the output and to the input of matrix adders 11 and 12. The output signal of the decoder 4 is fed to the information input of keys 7 and 9. The output signal of the decoder 3 is fed to the information input of key 8. The control inputs of keys 7, 8 and 9 receive corresponding codes numbers Qa, Qj, Qz (inputs 13, 14 and 15). The following signals are generated at the key outputs: key 7 - signal corresponding to the value of H-rRg (mod P) key 8 - signal corresponding to the value of QsQl (modPs) key 9 - signal corresponding to the value of ctzQz (modP;). The signals from the outputs arrive at one of the inputs of matrix adders. So, from the output of the key 7, the signal goes to one of the inputs of the matrix adder 12. The second inputs of the adder 12 receive a signal from the output of the decoder 5. In the adder, the values QiQz modulo Pr are added. The output value of the adder 12 is a representation of the remainder of the number A modulo. The signals from the output of keys 8 and 9 are fed to the input of the adder 10, in which the sum of the terms ctjQs + -f ajQa (mod РЗ) is formed. The output signal of the adder 10 is fed to the inputs of the adder 11, and the other inputs of this adder receive a signal from the output of the descrambler 5. The output signal of the adder 11 is the representation of the number A modulo Pj. Thus, at the output of the converter, signals are formed that correspond to the representation of the number A in the SOC. If the device is implemented on combinational elements, then the number is converted per cycle with any number of modules, while the inputs 13, 14 and 15 are closed (shown in dotted lines) and the control signal corresponding to the numbers Qa, Qz, Qs is input to 16. If the converter is implemented on integrated circuits, then it is inherent simplicity and greater reliability. The conversion time is determined by the total signal delay in blocks 3, 8, 10, and 11. Example. Let the representation of the number A in the polyadic code A (1,0,2) be known. Find the representation of the number in the SOC. At the input of the register are the coefficients Qi in binary form A (01, 00, 010). At the output, the converter receives signals corresponding to the number A in the SOC, A (1, 1, 3). moreover, the number A is represented in a single-position code. If it is required to represent the values of the residuals in binary form, then it is necessary to include at the output of the transformer an encoder, which is a set of OR elements, (the number conversion for the given example in the drawing is shown in dotted lines). The use of the present invention in computing environments allows to increase the speed by reducing the execution time of the operations of addition, subtraction and multiplication, reducing the amount of equipment. The implementation of the converter on integrated circuits provides an economic effect. Claims of the polyadic code into the code of the system of residual classes containing the input register and matrix adders, characterized in that, in order to increase the speed of calculations, decryptors and keys are additionally introduced, the outputs of the first, second and third groups of bits of the input register are connected respectively, to the inputs of the first, second and third decoders, the outputs of the first decipher are connected to the inputs of the first groups of the first and second matrix adders, the outputs of the second decoder through the first and second keys are connected respectively to the inputs of the second group of the first matrix adder and the inputs of the first group of the second matrix adder, the outputs of the third decoder through the third key are connected to the inputs of the second group of the third matrix adder, the outputs of which are connected to the inputs of the second group of the second matrix adder, the outputs of the first and the second matrix adders and the first decoder are connected to the output of the device, the control inputs of the keys are connected to the input of the device. Information sources,. taken into account during the examination 1. USSR author's certificate No. 315176, cl. G 06 F 5/02, 1969.
2.Авторское свидетельство СССР № 525947, кл. G 06 F 5/02, 1974 (прототип ).2. USSR author's certificate number 525947, cl. G 06 F 5/02, 1974 (prototype).
OjOj
аг /ag /
сгзcps