SU1725215A1 - Device for sorting numbers - Google Patents

Device for sorting numbers Download PDF

Info

Publication number
SU1725215A1
SU1725215A1 SU904840994A SU4840994A SU1725215A1 SU 1725215 A1 SU1725215 A1 SU 1725215A1 SU 904840994 A SU904840994 A SU 904840994A SU 4840994 A SU4840994 A SU 4840994A SU 1725215 A1 SU1725215 A1 SU 1725215A1
Authority
SU
USSR - Soviet Union
Prior art keywords
numbers
input
inputs
outputs
output
Prior art date
Application number
SU904840994A
Other languages
Russian (ru)
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 SU904840994A priority Critical patent/SU1725215A1/en
Application granted granted Critical
Publication of SU1725215A1 publication Critical patent/SU1725215A1/en

Links

Landscapes

  • Complex Calculations (AREA)

Abstract

Изобретение относитс  к автоматике и вычислительной технике. Цель изобретени  - повышение быстродействи . Устройство содержит блок выделени  минимального числа (БВМЧ) 1, регистр исключени  отсортированных чисел (РИОС) 2, блоки определени  числа единиц в двоичном коде (БОЧЕ) 3, 4, блок пам ти (БП) 5, выходные регистры 6 отсортированных чисел, элементы ИЛИ 7. Среди исходных чисел БВМЧ 1 определ ет и отмечает минимальное число (числа). БОЧЕ 4 и 3 определ ют соответственно, сколько минимальных чисел выделено БВМЧ - Ci и сколько их уже было отсортировано (сколько единиц записано в РИОС 2) - Ci. Полученные коды поступают на адресные входы БП 5, который формирует маску типа Окно, содержащую единицы в остальных разр дах. Выделенное минимальное число записываетс  в отмеченные выходные регистры 6. 1 табл., 2 ил. ЁThis invention relates to automation and computing. The purpose of the invention is to increase speed. The device contains a minimum number allocation unit (BVMCH) 1, a sorted number exclusion register (RIOS) 2, blocks for determining the number of ones in the binary code (ROOM) 3, 4, a memory block (BP) 5, output registers 6 sorted numbers, OR elements 7. Among the original numbers, BVMCH 1 defines and marks the minimum number (s). WELLS 4 and 3 determine, respectively, how many minimum numbers allocated BVMCH - Ci and how many of them have already been sorted (how many units are written in RIOS 2) - Ci. The received codes are sent to the address inputs of BP 5, which forms a Window-type mask containing units in the remaining bits. The allocated minimum number is written to the marked output registers 6. Tab. 1, 2 Il. Yo

Description

мm

IOIo

Изобретение относитс  к вычислительной технике и может быть использовано в машинах баз данных и системах поиска информации .The invention relates to computing and can be used in database machines and information retrieval systems.

Известны устройства дл  сортировки чисел, содержащие дешифраторы, группы элементов ИЛИ, узлы анализа и шифраторы . В основу работы данных устройств положен алгоритм последовательного сокращени  множества сортируемых чисел исключением из него на каждом очередном шаге наименьшего числа,Devices for sorting numbers are known that contain descramblers, groups of OR elements, analysis nodes and encoders. The operation of these devices is based on the algorithm of sequential reduction of the set of sorted numbers by excluding the smallest number from each successive step,

Недостатком устройств  вл етс  их непригодность дл  сортировки чисел большой разр дности. Указанный недостаток обусловлен использованием в устройствах принципа двойного преобразовани  кодов чисел - позиционных в распределительные, а распределительных - в позиционные. С ростом разр дности сортируемых чисел резко увеличиваютс  аппаратурные затраты на дешифрацию-шифрацию их кодов, что затрудн ет практическую реализацию устройств .A disadvantage of devices is their unsuitability for sorting large numbers. This disadvantage is due to the use in the devices of the principle of double conversion of codes of numbers — positional to distribution, and distributional - into positional. As the size of the sorted numbers increases, the hardware costs for decoding the encryption of their codes sharply increase, which makes it difficult to implement devices in practice.

Известно также устройство дл  сортировки чисел, содержащее формирователи импульсов, группу элементов ИЛИ, регистр исключени  отсортированных чисел и блок определени  числа единиц.It is also known to have a device for sorting numbers containing pulse shapers, a group of OR elements, an exclusion register of sorted numbers, and a unit for determining the number of ones.

Недостатком устройства  вл етс  его низкое быстродействие, обусловленное затратами нескольких тактов на выделение и выдачу каждого отсортированного числа.The disadvantage of the device is its low speed, due to the cost of several cycles for the allocation and issuance of each sorted number.

Наиболее близким по технической сущности к предлагаемому  вл етс  устройство дл  сортировки п чисел, содержащее блок выделени  наименьшего числа, п входных сумматоров, выходной сумматор, регистр исключени  отсортированных чисел, блок определени  числа единиц, счетчик, формирователи импулсов, элементы И, ИЛИ-НЕ и группу элементов ИЛИ.The closest in technical essence to the present invention is a device for sorting n numbers, containing the smallest number allocation unit, n input adders, output adder, sorted number exclusion register, unit for determining the number of ones, counter, impulse drivers, and AND, and NOT elements group of elements OR.

Недостатком известного устройства  вл етс  его низкое быстродействие, обусловленное разнесением во времени процесса поочередного выделени  наименьших чисел и процесса формировани  результирующего массива. Обработка исходного неупор доченного массива, содержащего среди п своих элементов Н попарно различных чисел, выполн етс  (устройством) за (Н + п) тактов, из которых Н тактов затрачиваетс  на собственную сортировку, а п тактов - на формирование и поэлементную выдачу результирующего массива.A disadvantage of the known device is its low speed, due to the separation in time of the process of alternately allocating the smallest numbers and the process of forming the resulting array. The processing of the initial disordered array containing among its elements H pairwise different numbers is performed (by the device) in (H + n) cycles, of which H cycles are spent on their own sorting, and n cycles - on the formation and elementwise output of the resulting array.

Цель изобретени  - повышение быстродействи  устройства за счет совмещени  во времени процессов выделени  наименьших чисел и формировани  из них упор доченного массива.The purpose of the invention is to increase the speed of the device by combining in time the processes of extracting the smallest numbers and forming an ordered array of them.

Поставленна  цель достигаетс  тем, что в устройство дл  сортировки чисел, содержащее блок выделени  минимального числа , регистр исключени  чисел, первый блокThe goal is achieved by the fact that in a device for sorting numbers, containing a minimum number allocation unit, an exception number register, a first unit

определени  числа единиц и группу элементов ИЛИ, причем входы 1-го числа устройства (i 1, 2п; п - количество сортируемыхdetermine the number of units and the group of elements OR, and the inputs of the 1st number of the device (i 1, 2п; n is the number of sorted

чисел) соединены соответственно с информационными входами i-й группы блока выделени  минимального числа, пр мые выходы разр дов регистра исключени  чисел - с входами первого блока определени  числа единиц, введены второй блок определени  числа единиц, блок пам ти иnumbers) are connected respectively to the information inputs of the i-th group of the minimum number allocation unit, the direct outputs of the number exclusion register — to the inputs of the first unit for determining the number of units; the second unit for determining the number of units, the memory unit, and

п выходных регистров, причем инверсный выход 1-го разр да регистра исключени  чисел соединен с i-м разрешающим входом блока выделени  минимального числа , 1-й адресный выход которого соединенn output registers, the inverse output of the 1st bit of the number exclusion register being connected to the ith permitting input of the minimum number allocation unit, the 1st address output of which is connected

с входом установки i-ro разр да регистра исключени  чисел в единичное состо ние, i-м входом второго блока определени  числа единиц и первым входом 1-го элемента ИЛИ группы, второй вход которого подключей к пр мому выходу 1-го разр да регистра исключени  чисел, вход установки в нулевое состо ние которого  вл етс  входом начальной установки устройства, информационные выходы блока выделени  минимального числа соединены с информационными входами всех выходных регистров, выходы первого и второго блоков определени  числа единиц - с адресными входами блока пам ти, i-й выходwith the input of the i-ro setting of the number exclusion register in the single state, the i-th input of the second unit for determining the number of units and the first input of the 1st element of the OR group, the second input of which is connected to the direct output of the 1st discharge register register numbers, the installation input in the zero state of which is the input of the initial installation of the device, the information outputs of the minimum number allocation unit are connected to the information inputs of all output registers, the outputs of the first and second units of determining the number of units are addressable memory block inputs, i-th output

которого соединен с входом разрешени  записи 1-го выходного регистра, выходы разр дов которого  вл ютс  информационными выходами i-й группы устройства, тактовый вход устройства соединен с тактовыми входами всех регистров, выходы всех элементов ИЛИ группы объединены монтажным И и  вл ютс  выходом окончани  работы устройства.which is connected to the recording resolution input of the 1st output register, the bit outputs of which are information outputs of the i-th group of the device, the clock input of the device is connected to the clock inputs of all registers, the outputs of all OR elements of the group are combined by assembly AND and are the end of work output devices.

На фиг.1 представлена схема устройства; на фиг.2 - вариант схемы блока выделени  минимального числа.Figure 1 presents the scheme of the device; Fig. 2 shows a variant of the minimum number allocation unit.

Устройство содержит (фиг.1) блок 1 выделени  минимального числа, регистр 2 исключени  отсортированных чисел, первый 3The device contains (Fig. 1) a minimum number allocation unit 1, a register 2 excluding sorted numbers, the first 3

и второй 4 блоки определени  числа единиц в двоичном коде, блок 5 пам ти, п выходных регистров 6 отсортированных чисел (п - размер обрабатываемых числовых массивов), группу из п двухвходовых элементов ИЛИ 7,and the second 4 blocks for determining the number of units in binary code, block 5 of memory, n output registers 6 sorted numbers (n is the size of the processed numeric arrays), a group of n two-input elements OR 7,

информационные входы сортируемых чисел Ai, A2, ..., Ар, вход НУ начальной установки устройства, информационные выходы отсортированных чисел Bi 62 ....-ЈВп, выход а окончани  работы устройства.informational inputs of the sorted numbers Ai, A2, ..., Ap, input LU of the initial installation of the device, informational outputs of the sorted numbers Bi 62 ....- ЈVp, exit and termination of the device operation.

Блок 1 выделени  минимального числа (фиг.2) содержит пр моугольную матрицу из n x k  чеек анализа, где k - разр дность сортируемых чисел. Кажда   чейка 1ц, где i 17n, I 1,k, имеет вход разрешени  Рц, выход разрешени  Рп, информационный вход аи и информационный выход. Ячейки анализа, образующие отдельную строку матрицу, соединены последовательно по входам и выходам разрешени . Входы разрешени   чеек Н 1,12 i,...,ln 1 первого столбца  вл ютс  разрешающими входами блока 1. Выходы разрешени   чеек Hie. l2kIn k последнего столбца  вл ютс  адресными выходами блока 1. Информационные входы  чеек 1-й строки образуют информационные входы сортируемого числа At - anai2...aik. Информационные выходы  чеек объединены по столбцам и образуют информационные выходы bi, D2,...,bk блока 1.The minimum number allocation unit 1 (Fig. 2) contains a rectangular matrix of n x k analysis cells, where k is the size of the sorted numbers. Each cell 1c, where i 17n, I 1, k, has a resolution input Rc, an output resolution Pn, an information input ai, and an information output. The analysis cells, forming a separate row matrix, are connected in series along the resolution inputs and outputs. The resolution inputs of the H 1.12 i, ..., ln 1 cells of the first column are the enable inputs of block 1. The resolution outputs of the Hie cells. The l2kIn k of the last column are the address outputs of block 1. The information inputs of the cells of the 1st row form the information inputs of the sorted number At - anai2 ... aik. The information outputs of the cells are combined in columns and form the information outputs bi, D2, ..., bk of block 1.

Ячейка )ц анализа состоит из повторител  8, элемента 9 равнозначности и элемента 10 импликации.The analysis cell consists of a repeater 8, an equivalence element 9, and an implication element 10.

Элементы 7-10 выполн ютс  по схеме, обеспечивающей реализацию функции МОНТАЖНОЕ И в точках соединени  выходов .Elements 7-10 are performed according to a scheme that provides the implementation of the INSTALLATION function at the connection points of the outputs.

В основу работы устройства положен алгоритм последовательного сокращени  множества сортируемых чисел. Алгоритм включает Н шагов, где Н - количество попарно различных чисел в исходном массиве. При этом на каждом h-м шаге из текущего множества еще не отсортированных чисел исключаетс  группа из С (ь) одинаковых наименьших чисел.The device is based on the algorithm of sequential reduction of the set of sorted numbers. The algorithm includes H steps, where H is the number of pairwise different numbers in the source array. At the same time, at each hth step, the group of C (s) identical smallest numbers is excluded from the current set of yet not sorted numbers.

Устройство работает следующим образом .The device works as follows.

Сортируемые числа, образующие неупор доченный массив, подаютс  через входы Ai, A2,...,An устройства в блок 1 выбора минимального числа. Одновременно на вход НУ устройства подаетс  сигнал начальной установки, по которому производитс  асинхронное обнуление всех разр дов регистра 2. С инверсных выходов регистра 2 на соответствующие входы блока 1 поступают единичные сигналы Pi, P2, .... Рп. разрешающие анализ в блоке 1 всех п сортируемых чисел.Sorted numbers that form a disordered array are fed through the inputs Ai, A2, ..., An of the device to block 1 for the selection of the minimum number. At the same time, the initial setup signal is applied to the input of the NU device, which asynchronously resets all bits of the register 2 is performed. From the inverse outputs of register 2, the corresponding inputs of block 1 receive single signals Pi, P2, ... Pn. resolving the analysis in block 1 of all n sorted numbers.

В блоке 1 среди чисел Ai, А2Ап отыскиваетс  минимальное число В(1) мин (Ai, А2, ..., An). Код этого числа передаетс  с информационных выходов блока 1 на информационные входы всех регистров 6. На адресных выходах блока 1 формируетс  набор сигналов vi, V2vn, в котором единичными значени ми отмечаютс  позиции выделенного числа В{1) в исходном массиве.In block 1, among the numbers Ai, A2An, the minimum number B (1) min (Ai, A2, ..., An) is found. The code of this number is transmitted from the information outputs of block 1 to the information inputs of all registers 6. At the address outputs of block 1, a set of signals vi, V2vn is formed, in which the single values indicate the positions of the selected number B {1) in the source array.

Сформированный набор сигналов vi, V2, ..., vn поступает на входы установки в 1 разр дов регистра 2 и на входы блока 4.The generated signal set vi, V2, ..., vn is fed to the inputs of the installation in 1 bits of register 2 and to the inputs of block 4.

Блоком 4 определ етс  количество единичных сигналов в наборе vi, V2vn. Получаемый при этом на выходах блока 4 код С (1) ci С2 ...c q, где q log2 (п+1), показывает , сколько наименьших чисел, равных В(1), содержитс  в исходном массиве. Одно0 временно блоком 3 подсчитываетс  количество единиц, наход щихс  в разр дах регистра 2. Код С(1) ciC2...Cq 0; формируемый на выходах блока 3, показывает, сколько чисел исходного массива уже отсор5 тировано.Block 4 determines the number of single signals in the set vi, V2vn. The code C (1) ci C2 ... c q obtained at the outputs of block 4, where q log2 (n + 1), shows how many smallest numbers equal to B (1) are contained in the original array. At one time, the block 3 calculates the number of units in the bits of register 2. Code C (1) ciC2 ... Cq 0; formed at the outputs of block 3, shows how many numbers of the original array have already been sampled.

Коды С (1) и С(1) с выходов блоков 4 и 3 поступают на адресные входы блока 5 пам ти . Блок 5 формирует п-разр дную маску типа окно, содержащую серию из С(1) еди0 ниц в разр дах с (С(1)+1)-го по (C(i) +C (ij-й и нули в остальных разр дах.Codes C (1) and C (1) from the outputs of blocks 4 and 3 are fed to the address inputs of memory block 5. Block 5 forms a n-bit window type mask containing a series of C (1) units in bits from (C (1) +1) through (C (i) + C (ijth and zeros in the rest bit dah

Блок 5 может быть выполнен в виде ПЗУ емкостью 4Ч n-разр дных слов. Пример прошивки ПЗУ дл  случа  п 4 приведенBlock 5 can be made in the form of a ROM with a capacity of 4 × n-bit words. An example of firmware ROM for the case n 4 is given

5 в таблице. Ячейки ПЗУ, адреса которых в таблице не указаны, могут содержать произвольную информацию.5 in the table. ROM cells whose addresses are not listed in the table may contain arbitrary information.

С выходов блока 5 разр ды сформированной маски поступают на входы разреше0 ни  записи регистров 6. При этом i-й разр д маски подаетс  на вход разрешени  записи регистра б| и разрешает либо запрещает прием информации этот регистр с информационных выходов блока 1.From the outputs of block 5, the bits of the mask that have been formed go to the inputs of register register 6 resolution. At the same time, the i-th mask mask is input to the register recording resolution b | and allows or denies the reception of information this register from the information outputs of block 1.

5 По очередному синхроимпульсу (цепи синхронизации на фиг.1 не показаны) код наименьшего числа В(1), выделенного блоком 1, принимаетс  в регистры 61 - 6cV разблокированные по записи единичными5 According to the next sync pulse (the synchronization circuits in Fig. 1 are not shown), the code of the smallest number B (1) allocated by block 1 is received in registers 61-6cV unlocked by the record ones

0 разр дами маски. Содержимое остальных регистров 6ci +i. 6n не мен етс . Одновременно набором сигналов vi, vavn,0 bit masks. The contents of the remaining registers 6ci + i. 6n does not change. Simultaneously by a set of signals vi, vavn,

поступающих с адресных выходов блока 1, устанавливаютс  в 1 разр ды регистра 2, соответствующие позици м выделенного числа В(1) в исходном массиве. Тем самым эти числа исключаютс  из дальнейшего рассмотрени  в блоке 1, поскольку количество нулевых сигналов на разрешающихincoming from address outputs of block 1, are set to 1 bits of register 2, corresponding to the positions of the selected number B (1) in the source array. Thus, these numbers are excluded from further consideration in block 1, since the number of zero signals per allowing

5five

00

входах Pi, P2Рп блока 1 возрастает наthe inputs of Pi, P2Pn block 1 increases by

величину ). В результате текущее множество сортируемых чисел сокращаетс  за счет исключени  из него С (1) одинаковых наименьших чисел.value). As a result, the current set of sorts being sorted is reduced by eliminating from it C (1) the same smallest numbers.

5 в очередном такте работа устройства повтор етс  аналогичным образом. При этом на выходах блоков 4 и 3 формируютс 5 in the next cycle, the operation of the device is repeated in a similar manner. In this case, at the outputs of blocks 4 and 3,

КОДЫ С(2) И С(2) С(1) + С(1) С (1)CODES WITH (2) AND WITH (2) WITH (1) + C (1) WITH (1)

соответственно, а на выходах блока 5 образуетс  маска с окном шириной в С (2) разр дов и левой границей, равной С(2) +1. При этом очередное число В(а) В(1), выделенное блоком 1, принимаетс  на регистры +1 - 6c i + С2- а в регистре 2 дополнительно устанавливаютс  в единичное состо ние С (2) разр дов, соответствующих позици м числа В(2) в исходном массиве.accordingly, and at the outputs of block 5, a mask is formed with a window with a width of C (2) bits and a left border equal to C (2) +1. In this case, the next number B (a) B (1), allocated by block 1, is accepted into registers +1 - 6c i + C2 - and in register 2 is additionally set to the C (2) unit state of the bits corresponding to the positions of the number B (2) in the source array.

Таким образом, в каждом h-м такте работы устройства текущее множество сортируемых чисел сокращаетс  исключением из него С (h) одинаковых наименьших чисел, а текущее множество уже отсортированных чисел пополн етс  этими числами. Формируемое блоком 5 окно смещаетс  от такта к такту вправо. Единичные сигналы, снимаемые с пр мых выходов регистра 2, отмечают позиции уже отсортированых чисел , а единичные сигналы на инверсных выходах регистра 2 - позиции еще не отсортированных чисел в исходном массиве. Отсортированные к концу h-го такта числа Вч 82 ... Вс(п) наход тс  в регистрах 6i -беде.Thus, in each hth operation cycle of the device, the current set of sorted numbers is reduced by excluding from it C (h) the same smallest numbers, and the current set of already sorted numbers is supplemented by these numbers. The window formed by block 5 shifts from beat to beat to the right. The single signals taken from the direct outputs of register 2 mark the positions of the already sorted numbers, and the single signals at the inverse outputs of register 2 mark the positions of the numbers that have not yet been sorted in the original array. The HF 82 ... Sun (n) numbers sorted by the end of the h-th cycle are in the registers 6i-poor.

Сортировка исходного массива заканчиваетс  в Н-м такте, где НЈ{1, 2, ...,п} - количеству попарно различных чисел среди Ai, A2, ...,АП. В этом такте на выходах блоков 4 и 3 формируютс  величины С(н) и С(н), причем С (н) + С(н) п. Одновренно на выходах всех элементов ИЛИ 1 - In по вл ютс  единичные сигналы, что приводит к выработке единичного признака а, свидетельствующего об окончании процесса сортировки. К концу Н-го такта по очередному синхроимпульсу последнее из Н чисел, выделенных блоком 1, принимаетс  в регистры 6он)+ 1 - 6П. В следующем такте на входы Ai, A2, ...-, An устройства можно подавать очередной массив сортируемых чисел.The sorting of the initial array ends in the Nth bar, where НЈ {1, 2, ..., n} is the number of pairwise different numbers among Ai, A2, ..., AP. In this cycle, the values of C (n) and C (n) are formed at the outputs of blocks 4 and 3, and C (n) + C (n) n. Simultaneously, at the outputs of all OR 1 - In elements, single signals appear, which leads to the development of a single sign a, indicating the end of the sorting process. By the end of the Nth clock, at the next sync pulse, the last of the H numbers allocated by block 1 is accepted into registers 6on + 1-6P. In the next clock cycle, the next array of sorted numbers can be fed to the inputs Ai, A2, ...-, An of the device.

Блок 1 выделени  минимального числа работает следующим образом.The minimum number allocation unit 1 operates as follows.

На горизонтальные р ды  чеек анализаTo horizontal rows of analysis cells

111 - Hk, l2T l2kIn1 - Ink ПОДЭЮТСЯ ДВОИЧные коды сортируемых чисел Ai, A2, ..., An так, что аи соответствует старшему, aik - младшему разр ду 1-го числа. Из всех п входных кодов анализируютс  только те, дл  которых на разрешающих входах блока 1 присутствуют сигналы логической 1.111 - Hk, l2T l2kIn1 - Ink SUBJECT BINARY codes of the sorted numbers Ai, A2, ..., An so that ai corresponds to the highest, aik - the youngest bit of the 1st. Of all the n input codes, only those for which the logical inputs 1 are present on the enable inputs of block 1 are analyzed.

В блоке 1 использован алгоритм поразр дного сравнени  чисел.In block 1, an algorithm for indating a comparison of numbers was used.

Если число Ai не участвует в сравнении, то на разрешающем входе Pi блока 1 присутствует сигнал логического О. Данный сигнал распростран етс  через повторители 8 всех  чеек анализа i-й строки и по вл етс  на выходе блока 1 в виде нулевого сигнала исключени  vj. В каждой  чейке анализа i-йIf the number Ai is not involved in the comparison, then the resolving input Pi of block 1 contains a logical O signal. This signal propagates through repeaters 8 of all the i-th row analysis cells and appears at the output of block 1 as a zero exclusion signal vj. In each cell of the i-th analysis

строки нулевой сигнал разрешени  Рн поступает на второй вход элемента 10 импликации , создава  услови  дл  по влени  на выходе этого элемента сигнала логическойthe zero resolution signal Rn is fed to the second input of the implication element 10, creating conditions for the appearance of the logical signal at the output of this element of the signal

1 ( 0 только при аи 0 и Рц 1). Таким образом, исключение числа А) из анализа в блоке 1 равносильно его замене максимальным числом, содержащим единицы во всех разр дах.1 (0 only with au 0 and Pc 1). Thus, excluding the number A) from the analysis in block 1 is equivalent to replacing it with a maximum number containing units in all bits.

0 Если хот  бы одно из участвующих в сравнении чисел содержит О в старшем разр де, то этот О передаетс  на выход элемента 10 импликации и по вл етс  на информационном выходе bi блока 1, поскольку вы5 ходы всех элементов 10 первого столбца соединены по схеме МОНТАЖНОЕ И,0 If at least one of the numbers involved in the comparison contains O in the higher order, then this O is transmitted to the output of the implication element 10 and appears at the information output bi of block 1, because the outputs of all elements 10 of the first column are connected according to the INSTALLATION AND ,

Если участвующее в сравнении число AI содержит единицу в старшем разр де (аи 1), а на выходе Ы блока 1 сформированIf the AI number involved in the comparison contains a one in the higher order (au, 1), and the output L of block 1 is formed

0 сигнал логического О (bi 0), то это означает , что AI не  вл етс  минимальным среди анализируемых чисел. В таком случае на выходе элемента 9 равнозначности  чейки in по вл етс  сигнал логическогоIf 0 is a logical O (bi 0) signal, this means that AI is not the minimum among the analyzed numbers. In such a case, at the output of the cell equivalence element 9, a logical signal appears

5 О (an®bi Ш) 0), который распростран етс  через повторители 8  чеек z - hk и по вл етс  на i-м адресном выходе блока 1 в виде нулевого сигнала VL По вление сигнала логического О на входах разре0 шени   чеек Ii2 - lik создает услови  дл  получени  на выходах элементов 10 импликации этих  чеек сигналов логической 1. Тем самым число АГ исключаетс  из дальнейшего анализа по оставшимс  младшим раз5 р дам.5 O (an ® bi)) 0), which propagates through repeaters of 8 cells z - hk and appears at the i-th address output of block 1 as a zero signal VL The appearance of a logical O signal at the inputs of the cell resolution Ii2 - lik creates the conditions for obtaining at the outputs of elements 10 the implication of these cells of the signals of logical 1. Thus, the number of AGs is excluded from further analysis by the least significant numbers.

Если все участвующие в сравнении числа содержат единицу в старшем разр де, то на информационном выходе bi блока 1 по вл етс  сигнал логической 1. В этом слу0 чае сравнение чисел продолжаетс  по оставшимс  младшим разр дам. При этом в  чейках h2 - hk, I22 - 2k, .... In2 - Ink анализа протекают процессы, аналогичные рассмотренному.If all the numbers involved in the comparison contain a one in the higher order, then the information output bi of block 1 is a logical 1 signal. In this case, the comparison of numbers continues on the least significant bits. In this case, in cells h2 - hk, I22 - 2k, ... In2 - Ink analysis, processes similar to those considered take place.

5 Таким образом, выделение минимального числа блоком 1 происходит в результате распространени  сигналов по строкам  чеек анализа слева направо. Значени  разр дов выделенного числа по вл ютс 5 Thus, the selection of the minimum number by block 1 occurs as a result of the propagation of signals along the rows of analysis cells from left to right. The values of the digits of the allocated number appear

0 на информационных выходах bi,b2bk0 on informational outputs bi, b2bk

блока 1, а позиции выделенного числа, занимаемые им в исходном массиве, отмечаютс  сигналами логической 1 на соответствую-, щих адресных выходах vi, V2vn блока 1.block 1, and the positions of the selected number occupied by it in the source array are marked by logical 1 signals at the corresponding address outputs vi, V2vn of block 1.

5 В качестве базового объекта выбрано устройство (4) дл  сортировки чисел - прототип за вл емого изобретени .5 The device (4) for sorting numbers is chosen as the base object - the prototype of the claimed invention.

Существенным техническим преимуществом за вл емого устройства перед базовым объектом  вл етс  более высокоеA significant technical advantage of the claimed device over the basic object is a higher

быстродейртвие. Указанное преимущество достигаетс  исключением из исходного массива группы одинаковых наименьших чисел на каждом шаге сортировки. Действительно, сортировка исходного массива, содержащего Н попарно различных чисел, выполн етс  базовым объектом за (Н+n) тактов. За вл емое устройство осуществл ет сортировку такого же массива за Н тактов, обеспечива  повышение быстродействи  в(Н+п)/Н(1 +п/Н) раз. Максимальный выигрыш в быстродействии в (п+1) раз достигаетс  в том случае, когда исходный массив состоит из п одинаковых чисел. В этом случае сортировка массива базовым объектом занимает (п+1) тактов, а за вл емым устройством - I такт. Минимальный выигрыш (в 2 раза) имеет место , когда исходный массив не содержит одинаковых чисел. В этом случае сортировка массива базовым объектом требует 2п тактов, а за вл емым устройством - п тактов.fast speed This advantage is achieved by the exclusion from the initial array of a group of identical smallest numbers at each sorting step. Indeed, the sorting of the original array containing H pairwise distinct numbers is performed by the base object in (H + n) cycles. The device performs the sorting of the same array by the N clock cycles, providing an increase in speed by (H + n) / H (1 + n / H) times. The maximum gain in speed (n + 1) is reached in the case when the initial array consists of n identical numbers. In this case, the sorting of the array by the base object takes (n + 1) clocks, and the device being inserted takes the I clock. The minimum gain (2 times) occurs when the source array does not contain the same numbers. In this case, the sorting of the array by the base object requires 2 steps, and the device claimed requires n steps.

Сравнение базового объекта и за вл емого устройства по длительности такта работы показывает следующее.Comparison of the base object and the claimed device by the duration of the operation cycle shows the following.

Длительность такта работы базового объекта составл етThe duration of the operation cycle of the base object is

Tg Т5 + Т1 + + Т15 + Т16,(1)Tg T5 + T1 + + T15 + T16, (1)

где Т5 - врем  срабатывани  блока выделени  минимального числа;where T5 is the response time of the minimum number allocation unit;

т - врем  суммировани  двух к-разр д- ных кодов на сумматоре;t is the time of summation of two c-bit codes on the adder;

TIO - врем  приема информации в регистр;TIO - time of receiving information in the register;

Т15- врем  срабатывани  блока определени  числа единиц;T15 is the response time of the unit for determining the number of units;

т тб - врем  приема информации в счетчик .t TB is the time of receiving information in the counter.

Дл  за вл емого устройства длительность такта работы определ етс  выражениемFor the device being claimed, the duration of the work cycle is determined by the expression

Тз Т1. + ГЗ + Г5 + Тб,Tz T1. + GZ + G5 + TB,

где п - врем  срабатывани  блока 1 выделени  минимального числа;where n is the response time of the minimum number allocation unit 1;

тз - врем  срабатывани  блока 3 определени  числа единиц;T3 is the response time of unit 3 for determining the number of units;

Т5 - врем  срабатывани  блока 5 пам ти;T5 is the response time of the memory unit 5;

Те - врем  приема информации в регистры 6. Those - the time of receiving information in the registers 6.

Из выражений (1) и (2) следует справедливость соотношени From expressions (1) and (2) it follows that the ratio

Tj-Тз ti,Tj-Tz ti,

показывающего, что длительность такта работы базового объекта превышает длительность такта работы за вл емого устройстваshowing that the duration of the operation cycle of the base object exceeds the duration of the operation cycle of the claimed device

по крайней мере на врем  г суммировани  двух k-разр дных чисел.at least the time r is the sum of two k-bits.

Таким образом, за вл емое устройство отличаетс  от базового объекта как мини5 мум вдвое меньшим количеством тактов, необходимых дл  сортировки исходного массива, и меньшей длительностью каждого такта. Вследствие этого за вл емое устройство обладает по крайней мере вдвое болееThus, the proposed device differs from the base object at a minimum of half as many clocks needed to sort the source array, and a shorter duration of each clock. As a result, the claimed device has at least twice as much

10 высоким быстродействием.10 high speed.

При необходимости поочередной выдачи отсортированных чисел за вл емое устройство может быть использовано совместно с любым известным устройствомIf it is necessary to issue sorted numbers one by one, the claimed device can be used together with any known device.

15 параллельно-последовательной буферизации . В этом случае на сортировку каждого массива будет затрачиватьс  ровно п тактов , т.е. на Н тактов меньше, нежели в базовом объекте.15 parallel-sequential buffering. In this case, exactly n clocks will be spent on sorting each array, i.e. H steps less than in the base object.

2020

Claims (1)

Формула изобретени  Устройство дл  сортировки чисел, содержащее блок выделени  минимального числа, регистр исключени  чисел, первыйClaims An apparatus for sorting numbers, comprising a minimum number allocation unit, an exception number register, the first 25 блок определени  числа единиц и группу элементов ИЛИ, причем входы 1-го числа25 unit for determining the number of units and the group of elements OR, and the inputs of the 1st number устройства 0 1,2, п, п - количествоdevices 0 1,2, p, p - number сортируемых чисел) соединены соответственно с информационными входами i-йnumbers to be sorted) are connected respectively to the informational inputs of the i-th 30 группы блока выделени  минимального числа, пр мые выходы разр дов, регистра исключени  чисел соединены с входами первого блока определени  числа единиц, отличающеес  тем, что, с цельюThe 30 groups of the minimum number allocation unit, the direct outputs of the bits, the number exclusion register are connected to the inputs of the first unit for determining the number of units, characterized in that 35 повышени  быстродействи , в него введены второй блок определени  числа единиц , блок пам ти и п входных регистров, причем инверсный выход 1-го разр да регистра исключени  чисел соединен с i-м35, a second unit for determining the number of units, a memory unit and n input registers are entered into it, the inverse output of the 1st bit of the number exclusion register being connected to the i-th 40 разрешающим входом блока выделени  минимального числа, i-й адресный выход которого соединен с входом установки 1-го разр да регистра исключени  чисел в единичное состо ние, i-м входом второго40 by the enabling input of the minimum number allocation unit, the i-th address output of which is connected to the installation input of the 1st bit of the number exclusion register in the unit state, the i-th input of the second 45 блока определени  числа единиц и первым входом 1-го элемента ИЛИ группы, второй вход которого подключен к пр мому выходу 1-го разр да регистра исключени  чисел, вход установки в нулевое45 of the unit for determining the number of units and the first input of the 1st element of the OR group, the second input of which is connected to the forward output of the 1st bit of the number exclusion register, the input of the setting to zero 50 состо ние которого  вл етс  входом начальной установки устройства, информационные выходы блока выделени  минимального числа соединены с информационными входами всех выходных50, the state of which is the input of the initial installation of the device, the information outputs of the minimum number allocation unit are connected to the information inputs of all output 55 регистров, выходы первого и второго блоков определени  числа единиц соединены с адресными входами блока пам ти, i-й выход которого соединен с входом разрешени  записи i-ro выходного регистра, выходы разр дов которого  вл ютс  информационными выходами i-й группы устройства , тактовый вход устройства соединен с тактовыми входами всех регистров,55 registers, the outputs of the first and second units of determining the number of units are connected to the address inputs of the memory block, the i-th output of which is connected to the write enable input of the i-ro output register, the bits of which are information outputs of the i-th group of the device, clock the device input is connected to the clock inputs of all registers, выходы всех элементов ИЛИ группы объединены монтажным И и  вл ютс  выходом окончани  работы устройства.the outputs of all the elements of the OR group are combined with the AND assembly and are the output of the end of the device operation. II -- ,, г-Лфgf 4four //I// I iiii . V . t . V. t п-Цp-c &&
SU904840994A 1990-05-28 1990-05-28 Device for sorting numbers SU1725215A1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
SU904840994A SU1725215A1 (en) 1990-05-28 1990-05-28 Device for sorting numbers

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
SU904840994A SU1725215A1 (en) 1990-05-28 1990-05-28 Device for sorting numbers

Publications (1)

Publication Number Publication Date
SU1725215A1 true SU1725215A1 (en) 1992-04-07

Family

ID=21521877

Family Applications (1)

Application Number Title Priority Date Filing Date
SU904840994A SU1725215A1 (en) 1990-05-28 1990-05-28 Device for sorting numbers

Country Status (1)

Country Link
SU (1) SU1725215A1 (en)

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
Авторское свидетельство СССР № 1179317, кл. G 06 F 7/08, 1985. Авторское свидетельство СССР №1474639,кл. G 06 F 7/08, 1987. *

Similar Documents

Publication Publication Date Title
SU1725215A1 (en) Device for sorting numbers
US4477918A (en) Multiple synchronous counters with ripple read
SU1667059A2 (en) Device for multiplying two numbers
US2825502A (en) Electronic calculators
SU1293727A1 (en) Polyfunctional calculating device
SU771660A1 (en) Binary-to-bunary-decimal code converter
SU1049900A1 (en) Device for sorting binary numbers
SU1128251A1 (en) Device for comparing binary numbers
SU1746373A1 (en) Function system generator
SU1667050A1 (en) Module for boolean function logic transformation
SU830377A1 (en) Device for determining maximum number code
SU1485229A1 (en) Multibit code selector
SU943707A1 (en) Device for sorting numbers
SU1432502A1 (en) Device for comparing numbers
SU1397933A1 (en) Device for permutation searching
SU783786A1 (en) Coder
RU1783511C (en) Device for sorting binary numbers
SU1596344A1 (en) Device for solving problems on graphs
SU652592A1 (en) Displacement- to-code converter
SU1109738A1 (en) Device for selecting ordered sequence of data
SU1365076A1 (en) Number-sorting device
SU1117648A1 (en) Stochastic (1,n)-port
SU1441484A1 (en) Apparatus for associative coding and compression of volume of information
SU1124319A1 (en) Device for generating all possible combinations,arrangements and permutations
SU1062678A1 (en) Communication device for computer system