RU2079879C1 - Matrix processor - Google Patents

Matrix processor Download PDF

Info

Publication number
RU2079879C1
RU2079879C1 RU94030340A RU94030340A RU2079879C1 RU 2079879 C1 RU2079879 C1 RU 2079879C1 RU 94030340 A RU94030340 A RU 94030340A RU 94030340 A RU94030340 A RU 94030340A RU 2079879 C1 RU2079879 C1 RU 2079879C1
Authority
RU
Russia
Prior art keywords
output
input
adder
sign
multiplexer
Prior art date
Application number
RU94030340A
Other languages
Russian (ru)
Other versions
RU94030340A (en
Inventor
Евгений Иванович Духнич
Сергей Олегович Деревенсков
Original Assignee
Евгений Иванович Духнич
Сергей Олегович Деревенсков
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Евгений Иванович Духнич, Сергей Олегович Деревенсков filed Critical Евгений Иванович Духнич
Priority to RU94030340A priority Critical patent/RU2079879C1/en
Publication of RU94030340A publication Critical patent/RU94030340A/en
Application granted granted Critical
Publication of RU2079879C1 publication Critical patent/RU2079879C1/en

Links

Images

Landscapes

  • Complex Calculations (AREA)

Abstract

FIELD: computer engineering. SUBSTANCE: device has m registers, m sign decoders, (2m-1) adders- subtracters, (m-1) XOR gates, three shift registers, (m+3) multiplexers, where m is dimension of matrix to be processed. EFFECT: increased field of application. 4 dwg

Description

Изобретение относится к вычислительной технике и предназначено для построения на его основе специализированных ЭВМ. The invention relates to computer technology and is intended to build on its basis specialized computers.

Известны специализированные устройства, выполняющие триангуляцию матрицы (патент РФ N 1800463), решение систем линейных алгебраических уравнений (патент РФ N 1832301), решение систем линейных алгебраических уравнений с треугольной матрицей (патент РФ N 1803921), а также устройства для вращения вектора по алгоритму Волдера (авт. свид. СССР N 445042). Known specialized devices that perform matrix triangulation (RF patent N 1800463), solving systems of linear algebraic equations (RF patent N 1832301), solving systems of linear algebraic equations with a triangular matrix (RF patent N 1803921), as well as devices for rotating the vector according to the Walder algorithm (ed. certificate. USSR N 445042).

Основными недостатками этих устройств являются узкий функциональный состав выполняемых операций при значительных аппаратурных затратах, а также необходимость для вычисления модуля m-мерного вектора использовать последовательность из (m-1)-й операции плоского вращения. The main disadvantages of these devices are the narrow functional composition of the operations performed at a significant hardware cost, as well as the need to use the sequence of the (m-1) th plane rotation operation to calculate the m-dimensional vector module.

Наиболее близким по технической реализации является устройство для определения модуля трехмерного вектора (авт. свид. СССР N 1205139), реализующее итерационный алгоритм перемещения трехмерного вектора с помощью последовательности из n преобразований отражения до его совпадения с осью абсцисс. The closest in technical implementation is a device for determining the module of a three-dimensional vector (ed. Certificate of the USSR N 1205139), which implements an iterative algorithm for moving a three-dimensional vector using a sequence of n reflection transformations until it coincides with the abscissa axis.

Одним из основных недостатков этого устройства является большое время определения модуля m-мерного вектора, которое равно порядка m/2 циклов по n итераций. Кроме того, при помощи этого устройства невозможно осуществить решение систем линейных алгебраических уравнений с треугольной матрицей (выполнить "обратный ход" для решения систем линейных алгебраических уравнений) и осуществить преобразование матрицы по методу Гаусса или Гаусса-Жордана. Между тем названные операции составляют математическое содержание значительной части практических задач. One of the main disadvantages of this device is the long time it takes to determine the modulus of the m-dimensional vector, which is equal to the order of m / 2 cycles in n iterations. In addition, using this device, it is impossible to solve systems of linear algebraic equations with a triangular matrix (perform a "reverse move" to solve systems of linear algebraic equations) and to transform the matrix according to the Gauss or Gauss-Jordan method. Meanwhile, these operations comprise the mathematical content of a significant part of practical problems.

Целью изобретения является расширение класса решаемых устройством задач путем введения в функциональный состав устройства операций для решения систем линейных алгебраических уравнений с треугольной матрицей и преобразования матрицы по методу Гаусса и Гаусса-Жордана, а также операции вычисления модуля m-мерного вектора за один цикл работы устройства. The aim of the invention is to expand the class of problems solved by the device by introducing operations into the functional composition of the device to solve systems of linear algebraic equations with a triangular matrix and transforming the matrix by the Gauss and Gauss-Jordan methods, as well as the operation of calculating the m-dimensional vector module in one cycle of the device.

Указанная цель достигается тем, что в устройство, содержащее три регистра, три дешифратора знака, шесть сумматоров-вычитателей, три сдвигателя, причем управляющие входы сдвигателей соединены с входом задания двоичного кода номера итерации, выход первого регистра соединен с информационным входом первого сдвигателя, дополнительно введены m-3 регистров, m-3 дешифраторов знака, 2m-7 сумматоров-вычитателей, m-1 схема ИСКЛЮЧАЮЩЕЕ ИЛИ, m+3 мультиплексора, где m размерность обрабатываемой матрицы, блок умножения, блок изменения знака числа, причем информационные входы всех регистров являются входами операндов спецпроцессора, входы синхронизации всех регистров соединены с входом синхронизации спецпроцессора, управляющий вход блока умножения подключен к входу задания двоичного кода номера итерации спецпроцессора, выход первого сдвигателя через блок изменения знака числа, управляющий вход которого соединен с выходом первого дешифратора знака, подключен к первому входу цепочки сумматоров-вычитателей, у которых вход первого слагаемого (уменьшаемого) j-го элемента (j 1,2,m-1) соединен с выходом (j-1)-го элемента, а вход второго слагаемого (вычитаемого) с выходом (j+1)-го регистра, выход последнего элемента цепочки подключен к информационному входу блока умножения, выход которого соединен с информационным входом второго сдвигателя, вход второго слагаемого (вычитаемого) первого выходного сумматора-вычитателя соединен с выходом второго сдвигателя, вход первого слагаемого (уменьшаемого) l-го выходного сумматора-вычитателя (l= 1,2,m) соединен с выходом l-го регистра, выход l-го выходного сумматора-вычитателя, кроме первого, подключен к l-му выходу спецпроцессора, вход l-го дешифратора знака является l-м входом анализа знака операнда спецпроцессора, выход первого дешифратора знака подключен к управляющему входу первого выходного сумматора-вычитателя, выход первого регистра через третий сдвигатель соединен с первым информационным входом m-го мультиплексора, второй информационный вход которого соединен с выходом блока умножения, а выход с входами второго слагаемого (вычитаемого) каждого выходного сумматора-вычитателя, кроме первого и второго, выход первого выходного сумматора-вычитателя соединен с вторым информационным входом (m+3)-го мультиплексора, первый информационный вход которого соединен с выходом первого регистра, а выход с первым выходом спецпроцессора, выход j-го дешифратора знака (j 2,3,m) соединен с вторым входом (j-1)-й схемы ИСКЛЮЧАЮЩЕЕ ИЛИ, второй вход которого соединен с выходом первого дешифратора знака, выход (j-1)-й схемы ИСКЛЮЧАЮЩЕЕ ИЛИ подключен к первому информационному входу (j-1)-го мультиплексора, второй информационный вход которого соединен с выходом j-го дешифратора знака, выход j-го мультиплексора (j=1,2,m-1) подключен к управляющему входу j-го сумматора-вычитателя в цепочке и к управляющему входу (j+1)-го выходного сумматора-вычитателя, кроме первого и второго, выход второго мультиплексора подключен к второму информационному входу (m+2)-го мультиплексора, первый информационный вход которого соединен с выходом первого мультиплексора, а выход с управляющим входом второго выходного сумматора-вычитателя, первый информационный вход (m+1)-го мультиплексора соединен с выходом m-го мультиплексора, второй информационный вход с входом задания двоичного кода веса обрабатываемого разряда спецпроцессора, а выход с входом второго слагаемого (вычитаемого) второго выходного сумматора-вычитателя, управляющие входы всех мультиплексоров соединены с входом задания двоичного кода режима работы спецпроцессора. This goal is achieved by the fact that in a device containing three registers, three sign decoders, six adders-subtracters, three shifters, the control inputs of the shifters connected to the input of the binary code of the iteration number, the output of the first register connected to the information input of the first shifter, additionally introduced m-3 registers, m-3 sign decoders, 2m-7 adders-subtracters, m-1 circuit EXCLUSIVE OR, m + 3 multiplexers, where m is the dimension of the processed matrix, the multiplication block, the block changing the sign of the number, and info The rotation inputs of all the registers are inputs of the operands of the special processor, the synchronization inputs of all the registers are connected to the synchronization input of the special processor, the control input of the multiplication unit is connected to the input of the binary code of the iteration number of the special processor, the output of the first shifter through the number sign change unit, the control input of which is connected to the output of the first decoder sign is connected to the first input of the chain of adders-subtracters, in which the input of the first term (decreasing) of the j-th element (j 1,2, m-1) is connected to the output the ode of the (j-1) -th element, and the input of the second term (subtracted) with the output of the (j + 1) -th register, the output of the last element of the chain is connected to the information input of the multiplication unit, the output of which is connected to the information input of the second shifter, the input of the second of the summand (subtracted) of the first output adder-subtractor is connected to the output of the second shifter, the input of the first term (diminished) of the lth output adder-subtractor (l = 1,2, m) is connected to the output of the lth register, the output of the lth output the adder-subtractor, except the first, is connected to the l-th at the output of the special processor, the input of the l-th character decoder is the l-th input of the sign analysis of the operand of the special processor, the output of the first character decoder is connected to the control input of the first output adder-subtractor, the output of the first register through the third shifter is connected to the first information input of the m-th multiplexer, the second information input of which is connected to the output of the multiplication unit, and the output with the inputs of the second term (subtracted) of each output adder-subtractor, except the first and second, the output of the first output sum the opa-subtractor is connected to the second information input of the (m + 3) -th multiplexer, the first information input of which is connected to the output of the first register, and the output to the first output of the special processor, the output of the j-th decryptor of the sign (j 2,3, m) is connected to the second input of the (j-1) -th EXCLUSIVE OR circuit, the second input of which is connected to the output of the first sign decoder, the output of the (j-1) -th EXCLUSIVE OR circuit is connected to the first information input of the (j-1) -th multiplexer, the second information the input of which is connected to the output of the jth decryptor of the sign, the output of the jth multipl a ksora (j = 1,2, m-1) is connected to the control input of the j-th adder-subtractor in the chain and to the control input of the (j + 1) -th output adder-subtractor, in addition to the first and second, the output of the second multiplexer is connected to the second information input of the (m + 2) th multiplexer, the first information input of which is connected to the output of the first multiplexer, and the output with the control input of the second output adder-subtractor, the first information input of the (m + 1) th multiplexer is connected to the output of the mth multiplexer, second information input with job input binary code of the weight of the processed discharge of the special processor, and the output with the input of the second term (subtracted) of the second output adder-subtractor, the control inputs of all multiplexers are connected to the input of the binary code of the special processor's operating mode.

Блок изменения знака числа является известным техническим решением и, в частности, может быть выполнен в виде сумматора-вычитателя, на вход первого слагаемого (уменьшаемого) которого постоянно подается значение, равное нулю, вход второго слагаемого (вычитаемого) является информационным входом блока изменения знака числа, управляющий вход сумматора-вычитателя управляющим входом блока изменения знака числа, а выход сумматора-вычитателя выходом блока. The unit for changing the sign of the number is a well-known technical solution and, in particular, can be made in the form of an adder-subtracter, the input of the first term (decreasing) of which is constantly supplied with a value equal to zero, the input of the second term (subtracting) is the information input of the block of changing the sign of the number , the control input of the adder-subtracter by the control input of the unit for changing the sign of the number, and the output of the adder-subtractor by the output of the block.

Блок умножения является известным техническим решением и предназначен для умножения входного числа в зависимости от номера итерации на одну из констант. Блок умножения на константу может, в частности, быть выполнен в виде устройства, состоящего из постоянного запоминающего устройства для хранения констант и умножителя, причем адресный вход запоминающего устройства является управляющим входом блока умножения, выход запоминающего устройства соединен с входом первого сомножителя, вход второго сомножителя которого является информационным входом блока умножения, а выход выходом блока умножения. The multiplication block is a well-known technical solution and is designed to multiply the input number depending on the iteration number by one of the constants. The constant multiplication unit can, in particular, be made in the form of a device consisting of a permanent storage device for storing constants and a multiplier, the address input of the storage device being a control input of the multiplying unit, the output of the storage device being connected to the input of the first factor, the input of the second factor of which is the information input of the multiplication block, and the output is the output of the multiplication block.

На фиг. 1 представлена схема матричного спецпроцессора, где 11.1m регистры операндов, 21.2m - дешифраторы знака, 31.32m-1 сумматоры-вычитатели, 41, 42, 43 сдвигатели, 5 -вход задания двоичного кода номера итерации, 61. 6m-1 схемы ИСКЛЮЧАЮЩЕЕ ИЛИ, 71.7m+3 мультиплексоры, 8 блок умножения, 9 блок изменения знака числа, 101.10m входы операндов, 11 вход синхронизации, 121. 12m выходы спецпроцессора, 131.13m входы анализа знака операнда, 14 вход задания двоичного кода веса обрабатываемого разряда, 15 вход задания двоичного кода режима работы спецпроцессора.In FIG. 1 is a diagram of a matrix special processor, where 1 1 .1 m registers of operands, 2 1 .2 m - sign decoders, 3 1 .3 2m-1 adders-subtractors, 4 1 , 4 2 , 4 3 shifters, 5 - binary input iteration number code, 6 1 . 6 m-1 circuits EXCLUSIVE OR, 7 1 .7 m + 3 multiplexers, 8 multiplication unit, 9 number sign changing unit, 10 1 .10 m operand inputs, 11 synchronization input, 12 1 . 12 m outputs of the special processor, 13 1 .13 m inputs of the analysis of the operand sign, 14 input of the binary code for the weight of the processed discharge, 15 input of the binary code for the operating mode of the special processor.

На фиг. 2 представлена схема для преобразования вектора в конвейерном режиме, на котором U1. Un устройства, изображенные на фиг. 1, X входной вектор размерности m, Y результирующий вектор той же размерности, X(j) вектор, обрабатываемый устройством Uj, Z - шина знаков операндов на n итерациях, Z(j) шина знаков операндов на j-й итерации.In FIG. 2 is a diagram for converting a vector in a conveyor mode on which U 1 . U n the devices shown in FIG. 1, X is an input vector of dimension m, Y is a resulting vector of the same dimension, X (j) is a vector processed by the device U j , Z is the bus of signs of operands at n iterations, Z (j) is the bus of signs of operands at the jth iteration.

На фиг. 3 представлена схема для триангуляции матрицы A(mxm), столбцы которой поданы на устройства U1.Um, каждое из которых является устройством, изображенным на фиг. 2.In FIG. 3 is a diagram for triangulating the matrix A (mxm), the columns of which are supplied to the devices U 1 .U m , each of which is the device shown in FIG. 2.

На фиг. 4 представлена схема для решения систем линейных алгебраических уравнений с треугольной матрицей, где U1.U3 устройства, каждое из которых является устройством, изображенным на фиг. 2, aij - элементы матрицы системы до обработки,

Figure 00000002
элементы матрицы системы после обработки, bi,
Figure 00000003
элементы столбца свободных членов до и после обработки соответственно.In FIG. 4 is a diagram for solving systems of linear algebraic equations with a triangular matrix, where U 1 .U 3 are devices, each of which is the device shown in FIG. 2, a ij are the elements of the matrix of the system before processing,
Figure 00000002
elements of the matrix of the system after processing, b i ,
Figure 00000003
free member column elements before and after processing, respectively.

Спецпроцессор содержит m регистров 11.1m, 2m-1 сумматоров-вычитателей 31.32m-1, m дешифраторов знака 21.2m, m-1 схему ИСКЛЮЧАЮЩЕЕ ИЛИ 61.6m-1, m+3 мультиплексора 71.7m+3, три сдвигателя 41, 42, 43, блок изменения знака числа 9, блок умножения 8 на одну из n констант, m входов операндов 101.10m, m входов анализа знака операнда 131.13m, выходов 121.12m, вход задания двоичного кода номера итерации 5, вход задания двоичного кода режима работы 15, вход задания двоичного кода веса обрабатываемого разряда 14, причем входы регистров 11.1m являются входами операндов 101.10m, а выходы подключены к входам первого слагаемого (уменьшаемого) выходных сумматоров-вычитателей 3m. 32m-1 соответственно, входы дешифраторов знака 21.2m являются соответственно входами анализа знака операнда 131.13m, выходы дешифраторов знака 22.2m соединены с вторыми входами схем ИСКЛЮЧАЮЩЕЕ ИЛИ 61.6m-1 соответственно, первые входы этих схем подключены к выходу дешифратора знака 21, а выходы соединены с первыми информационными входами мультиплексоров 71.7m-1 соответственно, вторые информационные входы этих мультиплексоров соединены с выходами дешифраторов знака 22.2m соответственно, вход задания двоичного кода номера итерации 5 подключен к управляющим входам сдвигателей 41, 42, 43 и блока умножения 8, выход регистра 11 подключен через сдвигатель 41 и блок изменения знака числа 9 к входу первого слагаемого (уменьшаемого) сумматора-вычитателя 31, вход второго слагаемого (вычитаемого) которого соединен с выходом регистра 22, управляющий вход с выходом мультиплексора 71, а выход с входом первого слагаемого (уменьшаемого) сумматора-вычитателя 32, сумматоры-вычитатели 31.3m-1 соединены в цепочку, j-й элемент которой входом первого слагаемого (уменьшаемого) подсоединен к выходу (j-1)-го элемента, входом второго слагаемого (вычитаемого) к выходу (j+1)-го регистра, управляющим входом к выходу мультиплексора 7j, а входом к входу первого слагаемого (уменьшаемого) (j+1)-го элемента, выход сумматора-вичитателя 3m-1 соединен с информационным входом блока умножения 8, выход которого через сдвигатель 42 подключен к входу второго слагаемого (вычитаемого) сумматора-вычитателя 3m и непосредственно к первому информационному входу мультиплексора 7m, выход сумматор-вычислителя 7m подключен к второму информационному входу мультиплексора 7m+3, первый информационный вход которого соединен с выходом первого регистра, а выход с первым выходом спецпроцессора 121, второй информационный вход мультиплексора 7m соединен через сдвигатель 43 с выходом регистра 11, а выход подключен к первому информационному входу мультиплексора 7m+1 и к входам второго слагаемого (вычитаемого) сумматоров-вычитателей 3m+2.32m-1, второй информационный вход мультиплексора 7m+1 подключен к входу задания двоичного кода веса обрабатываемого разряда 14, а выход к входу второго слагаемого (вычитаемого) сумматора-вычитателя 3m+1, управляющие входы сумматоров-вычитателей 3m+2.32m-1 подключены к выходам мультиплексоров 72.7m-1 соответственно, а управляющий вход сумматора-вычитателя 3m+1 подключен к выходу мультиплексора 7m+2, первый информационный вход которого соединен с выходом мультиплексора 71, а второй с выходом мультиплексора 72, управляющие входы всех мультиплексоров соединены с входом задания двоичного кода режима работы спецпроцессора 15, выходы сумматоров-вычитателей 3m+1.32m-1 являются выходами спецпроцессора 102.10m соответственно, выход дешифратора знака 21 соединен с управляющим входом блока изменения знака числа 9 и управляющим входом сумматора-вычитателя 3m, входы синхронизации регистров 11.1m соединены с входом синхронизации спецпроцессора 11.The special processor contains m registers 1 1 .1 m , 2m-1 adders-subtracters 3 1 .3 2m-1 , m sign decoders 2 1 .2 m , m-1 circuit EXCLUSIVE OR 6 1 .6 m-1 , m + 3 multiplexer 7 1 .7 m + 3 , three shifters 4 1 , 4 2 , 4 3 , a unit for changing the sign of the number 9, a unit for multiplying 8 by one of n constants, m inputs of the operands 10 1 .10 m , m inputs of the analysis of the sign of the operand 13 1 .13 m , outputs 12 1 .12 m , input of setting the binary code of the iteration number 5, input of setting the binary code of operating mode 15, input of setting the binary code of the weight of the processed bit 14, and the inputs of the registers 1 1 .1 m are inputs of the operands 10 1 .10 m , and the outputs are connected to the inputs of the first term (decreasing) of the output adders-subtractors 3 m . 3 2m-1, respectively, the inputs of the sign decoders 2 1 .2 m are respectively the inputs of the sign analysis of the operand 13 1 .13 m , the outputs of the sign decoders 2 2 .2 m are connected to the second inputs of the EXCLUSIVE OR 6 1 .6 m-1 circuits, respectively the first inputs of these circuits are connected to the output of the sign decoder 2 1 , and the outputs are connected to the first information inputs of the multiplexers 7 1 .7 m-1, respectively, the second information inputs of these multiplexers are connected to the outputs of the decoders of the sign 2 2 .2 m respectively iteration numbers 5 connected to the control inputs of the shifters 4 1 , 4 2 , 4 3 and the multiplication unit 8, the output of the register 1 1 is connected through the shifter 4 1 and the sign-changing unit of the number 9 to the input of the first term (decrementable) of the adder-subtractor 3 1 , the input of the second term (subtracted ) which is connected to the output of the register 2 2 , the control input with the output of the multiplexer 7 1 , and the output with the input of the first term (decreasing) of the adder-subtractor 3 2 , the adders-subtractors 3 1 .3 m-1 are connected in a chain, the j-th element which the input of the first term (decreasing) is connected to the output of the (j-1) th e element, by the input of the second term (subtracted) to the output of the (j + 1) th register, controlling the input to the output of the multiplexer 7 j , and by the input to the input of the first term (reduced) (j + 1) of the element, the output of the adder 3 m-1 is connected to the information input of the multiplication unit 8, the output of which through the shifter 4 2 is connected to the input of the second term (subtracted) of the adder-subtractor 3 m and directly to the first information input of the multiplexer 7 m , the output of the adder-calculator 7 m is connected to the second information multiplexer input 7 m + 3 , p the first information input of which is connected to the output of the first register, and the output with the first output of the special processor 12 1 , the second information input of the multiplexer 7 m is connected via a shifter 4 3 with the output of the register 1 1 , and the output is connected to the first information input of the multiplexer 7 m + 1 and to the inputs of the second term (subtracted) of the adders-subtracters 3 m + 2 .3 2m-1 , the second information input of the multiplexer 7 m + 1 is connected to the input of the binary code of the weight of the processed discharge 14, and the output to the input of the second term (subtracted) of the adder-subtract 3 m + 1 receiver, control inputs of 3 m + 2 .3 2m-1 adders-subtractors are connected to the outputs of multiplexers 7 2 .7 m-1, respectively, and the control input of the 3 m + 1 adder-subtracters is connected to the output of the 7 m + multiplexer 2 , the first information input of which is connected to the output of the multiplexer 7 1 , and the second to the output of the multiplexer 7 2 , the control inputs of all multiplexers are connected to the input of the binary code for the operating mode of the special processor 15, the outputs of the adders-subtractors 3 m + 1 .3 2m-1 are special processor outputs February 10 .10 m respectively, decoder output Entry 2 1 is connected to a control input of the sign change unit 9 and the control input of the adder-subtractor 3 m, clock inputs of registers January 1 .1 m connected to the input 11 special processor synchronization.

Спецпроцессор может работать в одном из трех режимов. The special processor can work in one of three modes.

Работу спецпроцессора в режимах 1 и 2 можно описать следующими выражениями:

Figure 00000004

где i номер итерации.The operation of the special processor in modes 1 and 2 can be described by the following expressions:
Figure 00000004

where i is the iteration number.

Значения величин a и сj определяются режимом работы спецпроцессора.The values of a and c j are determined by special processor operation.

В режиме 1

Figure 00000005

В этом режиме алгоритм (1) описывает одного из n преобразований отражения, в результате которых за один цикл работы устройства исходных вектор X0 совмещается с первой из m координатных осей, первый элемент вектора становится равным модулю вектора, а остальные координаты вектора будут равны нулю.In mode 1
Figure 00000005

In this mode, algorithm (1) describes one of n reflection transformations, as a result of which, in one cycle of operation of the source device, the vector X 0 is combined with the first of m coordinate axes, the first element of the vector becomes equal to the vector module, and the remaining coordinates of the vector will be zero.

В режиме 2

Figure 00000006

В этом режиме алгоритм (1) описывает одно из n преобразований вектора по методу Гаусса (или Гаусса-Жордана), в результате которых исходных исходный вектор X0(x (0) 1 , x (0) 2 , ..., x (0) m преобразуется в вектор Y(x (0) 1 , 0, ..., 0).
Режим 3 является вспомогательным и предназначен для выполнения операции деления на этом же устройстве, что необходимо для решения систем линейных алгебраических уравнений с треугольной матрицей.In mode 2
Figure 00000006

In this mode, algorithm (1) describes one of the n transformations of the vector by the Gauss (or Gauss-Jordan) method, as a result of which the original vector X 0 (x (0) one , x (0) 2 , ..., x (0) m transforms into vector Y (x (0) one , 0, ..., 0).
Mode 3 is auxiliary and is designed to perform the division operation on the same device, which is necessary for solving systems of linear algebraic equations with a triangular matrix.

Работу спецпроцессора в режиме 3 можно описать следующими выражениями:

Figure 00000007

где
Figure 00000008

В этом режиме исходный вектор X0(x (0) 1 , 0, x (0) 3 ) преобразуется в вектор Y(x (0) 1 , x (0) 3 /x (0) 1 , 0). Остальные координаты входного и выходного вектора в этом режиме не используются и могут быть произвольными.The operation of the special processor in mode 3 can be described by the following expressions:
Figure 00000007

Where
Figure 00000008

In this mode, the original vector X 0 (x (0) one , 0, x (0) 3 ) is transformed into the vector Y (x (0) one , x (0) 3 / x (0) one , 0). The remaining coordinates of the input and output vector in this mode are not used and can be arbitrary.

Рассмотрим работу спецпроцессора на i-ой итерации. Операнды-компоненты вектора Xi заносятся в регистры 11.1m по входам 101.10m соответственно и фиксируются в этих регистрах по сигналу синхронизации, поступающему по входу 11 спецпроцессора. На входы 131.13m подаются операнды, по знакам которых дешифраторы знака 21.2m и схемы ИСКЛЮЧАЮЩЕЕ ИЛИ 61.6m-1 вырабатывают сигналы управления сумматорами-вычитателями согласно соотношениям (2), (3), (5).Consider the work of a special processor on the i-th iteration. The operands of the components of the vector X i are recorded in the registers 1 1 .1 m at the inputs 10 1 .10 m, respectively, and are fixed in these registers according to the synchronization signal received at the input 11 of the special processor. The operands are fed to the inputs 13 1 .13 m , according to the signs of which the decoders of the sign 2 1 .2 m and the EXCLUSIVE OR 6 1 .6 m-1 circuits generate control signals for the adders-subtractors according to the relations (2), (3), (5) .

Мультиплексоры 71.7m-1 и 7m+2 служат для коммутации выработанных сигналов управления сумматорами-вычитателями в соответствии с режимом, двоичный код которого задается по входу 15. Сдвигатели 41 и 42 служат для сдвига числа на i разрядов, поэтому на выходе блока изменения знака числа 9 получится величина -2-i•x1•C1, к которой на сумматоре-вычитателе 31 прибавится (вычтется) величина x2•c2. Таким образом, на выходе сумматора-вычитателя 3m-1 получится выражение -2-i•x1•c1+x2•c2 + + xm•cm, которое поступит на вход блока умножения 8. Блок умножения предназначен для умножения входного числа в зависимости от номера инерции на одну из n констант -2•(m-1+2-i)-1. На выходе блока умножения будет получено значение a, которое через сдвигатель 42, формирующий значение a•2-i, подается на сумматор-вычитатель 3m. Полученное таким образом значение a соответствует режиму 1. Для режимов 2 и 3 значение a, равное x1•2-i, формируется на выходе сдвигателя 43. Мультиплексор 7m выбирает одно из этих значений в зависимости от режима. С выхода мультиплексора 7m значение a поступает на входы второго слагаемого (вычитаемого) сумматоров-вычитателей 7m+2.72m-1 непосредственно, a на соответствующий вход сумматора-вычитателя 3m+1 через мультиплексор 7m+1, на второй информационный вход которого подается значение d с входа задания двоичного кода веса обрабатываемого разряда 14. Мультиплексор 7m+1 в режимах 1 и 2 подключает на вход второго слагаемого (вычитаемого) сумматора-вычитателя 3m+1 значение a, а в режиме 3 значение d согласно (4). В режимах 1 и 2 сумматоры-вычитателя 3m.32m-1 построчно реализуют соотношения (1), а в режиме 3 сумматоры-вычитатели 3m.3m+2 построчно реализуют соотношения (4). Значения Y2. Ym, получаемые на выходах сумматоров-вычислителей 3m+1.32m-1 соответственно, подаются непосредственно на выходы спецпроцессора, а значение Y1 поступает на выход спецпроцессора через мультиплексор 7m+3, который соединяет соответствующий выход с выходом сумматора-вычитателя 3m в режиме 1 и с выходом регистра 11 в режимах 2 и 3. Все мультиплексоры управляются от входа задания двоичного кода режима работы спецпроцессора 15.Multiplexers 7 1 .7 m-1 and 7 m + 2 serve for switching the generated control signals of adders-subtractors in accordance with the mode, the binary code of which is set at input 15. The motors 4 1 and 4 2 serve to shift the number by i bits, therefore at the output of the sign change block of the number 9, the value -2 -i • x 1 • C 1 will be obtained, to which the value x 2 • c 2 will be added (subtracted) to the adder-subtractor 3 1 . Thus, at the output of the adder-subtractor 3 m-1 we get the expression -2 -i • x 1 • c 1 + x 2 • c 2 + + x m • c m , which will be input to the multiplication unit 8. The multiplication unit is designed to multiplying the input number depending on the inertia number by one of the n constants -2 • (m-1 + 2 -i ) -1 . At the output of the multiplication block, the value a will be obtained, which is fed to the adder-subtractor 3 m through the shifter 4 2 forming the value a • 2 -i . The value of a obtained in this way corresponds to mode 1. For modes 2 and 3, the value of a, equal to x 1 • 2 -i , is formed at the output of the shifter 4 3 . The 7 m multiplexer selects one of these values depending on the mode. From the output of the 7 m multiplexer, the value a goes to the inputs of the second term (subtracted) of the adders-subtractors 7 m + 2 .7 2m-1 directly, and to the corresponding input of the adder-subtractor 3 m + 1 through the multiplexer 7 m + 1 , to the second information the input of which is supplied with the value d from the input of the binary code of the weight of the processed discharge 14. The multiplexer 7 m + 1 in modes 1 and 2 connects the value a to the input of the second term (subtracted) adder-subtractor 3 m + 1 and the value d according to mode 3 (4). In modes 1 and 2, adders-subtractors 3 m .3 2m-1 implement relations (1) line by line, and in mode 3 adders-subtracters 3 m .3 m + 2 implement relations (4) line by line. Values of Y 2 . Y m obtained at the outputs of adders-calculators 3 m + 1 .3 2m-1, respectively, are fed directly to the outputs of the special processor, and the value Y 1 is transmitted to the output of the special processor through the multiplexer 7 m + 3 , which connects the corresponding output to the output of the adder-subtractor 3 m in mode 1 and with the output of register 1 1 in modes 2 and 3. All multiplexers are controlled from the input of the binary code of the operating mode of the special processor 15.

На этом работа в i-ой итерации заканчивается. Следующую итерацию можно выполнить в последовательном режиме в этом же устройстве, если предварительно соединить выходы 12j с входами 10j(j=1,2,m), или в конвейерном режиме с помощью n устройств, как это показано на фиг.2. Значения, подаваемые на входы 131.13m j-го устройства (j=1,2,n) зависят от режима работы устройства, а также от того, обрабатывается ли на устройстве столбец матрицы, в котором производится обнуление внедиагональных элементов на текущем шаге (главный столбец), или на устройстве обрабатывается один из прочих столбцов матрицы (зависимый столбец) для сохранения линейности преобразования.This is where the work in the i-th iteration ends. The next iteration can be performed in sequential mode in the same device, if you previously connect the outputs 12 j with the inputs 10 j (j = 1,2, m), or in the pipelined mode using n devices, as shown in figure 2. The values supplied to the inputs 13 1 .13 m of the j-th device (j = 1,2, n) depend on the operation mode of the device, as well as on whether the matrix column is processed on the device, in which the off-diagonal elements are zeroed at the current step (main column), or one of the other columns of the matrix (dependent column) is processed on the device to preserve the linearity of the transformation.

В режимах 1 и 2 при обработке главного столбца входы 131.13m j-го устройства соединяются с входами 10110m этого устройства соответственно, а при обработке зависимого столбца с входами 101.10m устройства, обрабатывающего главный столбец. В режиме 3 входы 131 и 133 j-го устройства соединяются соответственно с входами 101 и 103 этого устройства. Сигналы, подаваемые на входы 131.13m j-го устройства образуют шины Z(j) и общую шину Z, показанные на фиг.2.In modes 1 and 2, when processing the main column, the inputs 13 1 .13 m of the jth device are connected to the inputs 10 1 10 m of this device, respectively, and when processing the dependent column with the inputs 10 1 .10 m of the device processing the main column. In mode 3, the inputs 13 1 and 13 3 of the j-th device are connected respectively to the inputs 10 1 and 10 3 of this device. The signals supplied to the inputs 13 1 .13 m of the j-th device form the bus Z (j) and the common bus Z, shown in figure 2.

На фиг. 3 представлена схема соединения m устройств, каждое из которых представляет собой устройство, показанное на фиг.2. Эта схема предназначена для приведения матрицы A ({aij}) размерности (mxm) к верхнетреугольному виду путем ортогональных преобразований отражения (в режиме 1) или путем разложения матрицы на треугольные множители по методу Гаусса (в режиме 2). При этом устройство U1 обрабатывает главный столбец, а устройства U2.Um зависимые столбцы матрицы. Входы Z каждого устройства соединены по описанным выше правилам и образуют шину Z на фиг.3. В результате преобразования все элементы первого столбца матрицы, кроме

Figure 00000009
, будут равны нулю, а элемент
Figure 00000010
будет равен модулю вектора (в режиме 1) или a11 (в режиме 2). После исключения (обнуления) поддиагональных элементов первого столбца та же процедура проводится с матрицей порядка (m-1) для исключения поддиагональных элементов второго столбца.In FIG. 3 is a connection diagram of m devices, each of which is a device as shown in FIG. This scheme is designed to reduce the matrix A ({a ij }) of dimension (mxm) to the upper triangular form by orthogonal reflection transformations (in mode 1) or by decomposing the matrix into triangular factors by the Gauss method (in mode 2). In this case, the device U 1 processes the main column, and the device U 2 .U m dependent columns of the matrix. The inputs Z of each device are connected according to the rules described above and form the bus Z in figure 3. As a result of the conversion, all elements of the first column of the matrix, except
Figure 00000009
, will be equal to zero, and the element
Figure 00000010
will be equal to the modulus of the vector (in mode 1) or a 11 (in mode 2). After the elimination (zeroing) of the subdiagonal elements of the first column, the same procedure is performed with the order matrix (m-1) to exclude the subdiagonal elements of the second column.

После (m-1)-го аналогичного шага полученная матрица будет верхнетреугольной, после подобных манипуляций в режиме 1 со строками матрицы - двухдиагональной. After the (m-1) -th similar step, the resulting matrix will be upper triangular, after similar manipulations in mode 1 with the matrix rows - bi-diagonal.

Если в режиме 2 на каждом шаге не уменьшать размерность пространства, а использовать высвобождающиеся модули для исключения также и наддиагональных элементов, то полученная матрица будет диагональной начальной (метод Гаусса-Жордана). If in mode 2 at each step you do not reduce the dimensionality of the space, but use the released modules to exclude also off-diagonal elements, then the resulting matrix will be the diagonal initial (Gauss-Jordan method).

Для триангуляции матрицы при решении систем линейных алгебраических уравнений необходимо добавить устройство Um+1, обрабатывающее зависимый столбец в выбранном режиме, для обработки столбца свободных членов аналогично столбцам матрицы.To triangulate the matrix when solving systems of linear algebraic equations, it is necessary to add a device U m + 1 that processes the dependent column in the selected mode, to process the column of free terms similarly to the columns of the matrix.

На фиг. 4 представлена схема для выполнения "обратного хода" (получения решения из треугольной или диагональной матрицы) при решении систем линейных алгебраических уравнений. Устройства U1, U2, U3 представляют собой устройства, показанные на фиг.2. Устройство U1 работает в режиме 3, на его вход X подается вектор (аmm, O, bm), где amm элемент матрицы системы, bm элемент столбца свободных членов, на выходе Y устройства получается вектор, первым элементом которого является значение элемента вектора решения xm=bm/amm. В случае диагональной матрицы для получения вектора решения достаточно проделать m подобных операций. В случае треугольной матрицы после получения xm необходимо перейти к матрице размерности (m-1), преобразовав при этом вектор свободных членов. Для этого служат устройство U2, обрабатывающее зависимый столбец-вектор (xm, b1, bm-1), и устройство U3, обрабатывающее главный столбец-вектор (1, а1m, am-1m). В результате на выводах устройства U2 получается вектор Y (xm, b1-a1mxm, bm-1-am-1mxm).In FIG. Figure 4 shows the scheme for performing the "reverse stroke" (obtaining a solution from a triangular or diagonal matrix) when solving systems of linear algebraic equations. Devices U 1 , U 2 , U 3 are the devices shown in FIG. 2. The device U 1 operates in mode 3, a vector (a mm , O, b m ) is supplied to its input X, where a mm is an element of the matrix of the system, b m is an element of the column of free members, at the output Y of the device, a vector is obtained, the first element of which is the value element of the solution vector x m = b m / a mm . In the case of a diagonal matrix, to obtain a solution vector, it suffices to do m similar operations. In the case of a triangular matrix, after obtaining x m, it is necessary to go to a matrix of dimension (m-1), transforming the vector of free terms. To do this, use the device U 2 that processes the dependent vector column (x m , b 1 , b m-1 ), and the device U 3 that processes the main column-vector (1, a 1m , a m-1m ). As a result, at the terminals of device U 2 , the vector Y is obtained (x m , b 1 -a 1m x m , b m-1 -a m-1m x m ).

Устройство может также быть использовано для обращения матрицы путем решения m систем линейных алгебраических уравнений с одинаковой матрицей и m различными столбцами свободных членов, а также для нахождения определителя матрицы и решения некоторых других задач линейной алгебры. The device can also be used to invert the matrix by solving m systems of linear algebraic equations with the same matrix and m different columns of free terms, as well as to find the determinant of the matrix and solve some other problems of linear algebra.

Эффективность изобретения заключается в расширении класса решаемых устройством задач, достигаемом за счет незначительного увеличения затрат оборудования. The effectiveness of the invention lies in expanding the class of tasks solved by the device, achieved by a slight increase in equipment costs.

Claims (1)

Матричный спецпроцессор, содержащий три регистра, три дешифратора знака, шесть сумматоров-вычитателей, три сдвигателя, причем управляющие входы сдвигателей соединены с входом задания двоичного кода номера итерации спецпроцессора, выход первого регистра соединен с информационным входом первого сдвигателя, отличающийся тем, что в него введены m-3 регистров, m-3 дешифраторов знака, 2m-7 сумматоров-вычитателей, m-1 схем исключающее или, m+3 мультиплексоров, где m размерность обрабатываемой матрицы, блок умножения, блок изменения знака числа, причем информационные входы всех регистров являются входами операндов спецпроцессора, входы синхронизации всех регистров соединены с входом синхронизации спецпроцессора, управляющий вход блока умножения подключен к входу задания двоичного кода номера итерации спецпроцессора, выход первого сдвигателя через блок изменения знака числа, управляющий вход которого соединен с выходом первого дешифратора знака, подключен к первому входу цепочки сумматоров-вычитателей, у которой вход первого слагаемого (уменьшаемого) j-го элемента (j=1,2,m-1) соединен с выходом (j-1)-го элемента, а вход второго слагаемого (вычитаемого) с выходом (j+1)-го регистра, выход последнего элемента цепочки подключен к информационному входу блока умножения, выход которого соединен с информационным входом второго сдвигателя, вход второго слагаемого (вычитаемого) первого выходного сумматора-вычитателя соединен с выходом второго сдвигателя, вход первого слагаемого (уменьшаемого) i-го выходного сумматора-вычитателя (j 1, 2, m) соединен с выходом i-го регистра, выход i-го выходного сумматора вычитателя, кроме первого, подключен к i-му выходу спецпроцессора, вход i-го дешифратора знака является i-м входом анализа знака операнда спецпроцессора, выход первого дешифратора знака подключен к управляющему входу первого выходного сумматора-вычитателя, выход первого регистра через третий сдвигатель соединен с первым информационным входом m-го мультиплексора, второй информационный вход которого соединен с выходом блока умножения, а выход с входами второго слагаемого (вычитаемого) каждого выходного сумматора-вычитателя, кроме первого и второго, выход первого выходного сумматора-вычитателя соединен с вторым информационным входом (m + 3)-го мультиплексора, первый информационный вход которого соединен с выходом первого регистра, а выход с первым выходом спецпроцессора, выход j-го дешифратора знака (j 2,3,m) соединен с вторым входом (j 1)-й схемы ИСКЛЮЧАЮЩЕЕ ИЛИ, второй вход которой соединен с выходом первого дешифратора знака, выход (j 1)-й схемы ИСКЛЮЧАЮЩЕЕ ИЛИ подключен к первому информационному входу (j 1)-го мультиплексора, второй информационный вход которого соединен с выходом j-го дешифратора знака, выход j-го мультиплексора (j 1,2,m 1) подключен к управляющему входу j-го сумматора-вычитателя в цепочке и к управляющему входу (j + 1)-го выходного сумматора-вычитателя, кроме первого и второго, выход второго мультиплексора подключен к второму информационному входу (m + 2)-го мультиплексора, первый информационный вход которого соединен с выходом первого мультиплексора, а выход с управляющим входом второго выходного сумматора-вычитателя, первый информационный вход (m + 1)-го мультиплексора соединен с выходом m-го мультиплексора, второй информационный вход с входом задания двоичного кода веса обрабатываемого разряда спецпроцессора, а выход с входом второго слагаемого (вычитаемого) второго выходного сумматора-вычитателя, управляющие входы всех мультиплексоров соединены с входом задания двоичного режима работы спецпроцессора. A matrix special processor containing three registers, three sign decoders, six adders-subtracters, three shifters, the control inputs of the shifters connected to the input of the binary code for the iteration number of the special processor, the output of the first register connected to the information input of the first shifter, characterized in that m-3 registers, m-3 sign decoders, 2m-7 adders-subtracters, m-1 excluding circuits, or m + 3 multiplexers, where m is the dimension of the processed matrix, the multiplication block, the block changes the sign of the number, the information inputs of all registers are inputs of the operands of the special processor, the synchronization inputs of all registers are connected to the synchronization input of the special processor, the control input of the multiplication unit is connected to the input of the binary code of the iteration number of the special processor, the output of the first shifter is through the sign change unit, the control input of which is connected to the output of the first decoder sign is connected to the first input of the chain of adders-subtracters, in which the input of the first term (decreasing) of the j-th element (j = 1,2, m-1) is connected with the output of the (j-1) -th element, and the input of the second term (subtracted) with the output of the (j + 1) -th register, the output of the last element of the chain is connected to the information input of the multiplication block, the output of which is connected to the information input of the second shifter, input the second term (subtracted) of the first output adder-subtractor is connected to the output of the second shifter, the input of the first term (reduced) of the i-th output adder-subtractor (j 1, 2, m) is connected to the output of the i-th register, the output of the i-th output subtractor adder, except the first, sub n to the i-th output of the special processor, the input of the i-th character decoder is the i-th input of the sign analysis of the operand of the special processor, the output of the first character decoder is connected to the control input of the first output adder-subtractor, the output of the first register through the third shifter is connected to the first information input m -th multiplexer, the second information input of which is connected to the output of the multiplication unit, and the output with the inputs of the second term (subtracted) of each output adder-subtractor, except the first and second, the output of the first output the adder-subtractor is connected to the second information input of the (m + 3) -th multiplexer, the first information input of which is connected to the output of the first register, and the output to the first output of the special processor, the output of the j-th decryptor of the sign (j 2,3, m) is connected to the second input of the (j 1) th circuit EXCLUSIVE OR, the second input of which is connected to the output of the first sign decoder, the output of the (j 1) th circuit EXCLUSIVE OR is connected to the first information input of the (j 1) th multiplexer, the second information input of which is connected with the output of the j-th decryptor of the sign, the output of the j-th mule multiplexer (j 1,2, m 1) is connected to the control input of the j-th adder-subtractor in the chain and to the control input of the (j + 1) -th output adder-subtractor, in addition to the first and second, the output of the second multiplexer is connected to the second information the input of the (m + 2) th multiplexer, the first information input of which is connected to the output of the first multiplexer, and the output with the control input of the second output adder-subtracter, the first information input of the (m + 1) th multiplexer is connected to the output of the mth multiplexer, second information input with input m sets the binary code of the weight of the processed discharge of the special processor, and the output with the input of the second term (subtracted) of the second output adder-subtractor, the control inputs of all multiplexers are connected to the input of the binary mode of operation of the special processor.
RU94030340A 1994-08-23 1994-08-23 Matrix processor RU2079879C1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
RU94030340A RU2079879C1 (en) 1994-08-23 1994-08-23 Matrix processor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
RU94030340A RU2079879C1 (en) 1994-08-23 1994-08-23 Matrix processor

Publications (2)

Publication Number Publication Date
RU94030340A RU94030340A (en) 1996-06-10
RU2079879C1 true RU2079879C1 (en) 1997-05-20

Family

ID=20159752

Family Applications (1)

Application Number Title Priority Date Filing Date
RU94030340A RU2079879C1 (en) 1994-08-23 1994-08-23 Matrix processor

Country Status (1)

Country Link
RU (1) RU2079879C1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
RU2473961C1 (en) * 2011-12-12 2013-01-27 Виктор Николаевич Бабенко Vector normalising apparatus

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
Авторское свидетельство СССР N 1800463, кл. G 06 F 15/347, 1993. Авторское свидетельство СССР N 1205139, кл. G 06 F 7/541, 1986. *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
RU2473961C1 (en) * 2011-12-12 2013-01-27 Виктор Николаевич Бабенко Vector normalising apparatus

Also Published As

Publication number Publication date
RU94030340A (en) 1996-06-10

Similar Documents

Publication Publication Date Title
US6349318B1 (en) Arithmetic processor for finite field and module integer arithmetic operations
Vuillemin et al. Programmable active memories: Reconfigurable systems come of age
US5226171A (en) Parallel vector processing system for individual and broadcast distribution of operands and control information
Antelo et al. High performance rotation architectures based on the radix-4 CORDIC algorithm
US6539368B1 (en) Neural processor, saturation unit, calculation unit and adder circuit
Yang et al. A new RSA cryptosystem hardware design based on Montgomery's algorithm
US5081573A (en) Parallel processing system
US4635292A (en) Image processor
EP0849664A2 (en) Apparatus for computing transcendental functions quickly
US6026421A (en) Apparatus for multiprecision integer arithmetic
US6295597B1 (en) Apparatus and method for improved vector processing to support extended-length integer arithmetic
US6009450A (en) Finite field inverse circuit
EP0295788A2 (en) Apparatus and method for an extended arithmetic logic unit for expediting selected operations
US5363322A (en) Data processor with an integer multiplication function on a fractional multiplier
Stelling et al. Implementing multiply-accumulate operation in multiplication time
Antelo et al. Very-high radix CORDIC rotation based on selection by rounding
RU2079879C1 (en) Matrix processor
US20030093449A1 (en) Asynchronous parallel arithmetic processor utilizing coefficient polynomial arithmetic (CPA)
Baumhof A new VLSI vector arithmetic coprocessor for the PC
Mi et al. Behavioral Implementation of SVD on FPGA
RU2080650C1 (en) Device for calculation of absolute value of m- dimensional vector
Boateng et al. A Smith-Waterman Algorithm Accelerator Based on Residue Number System
US20050246406A9 (en) Emod a fast modulus calculation for computer systems
Vardhan et al. A critical look at modular adders using residue number system
RU2029356C1 (en) Device for computation of modulus of m-dimensional vector