RU2522875C2 - Device for determining number of ones in ordered binary number - Google Patents

Device for determining number of ones in ordered binary number Download PDF

Info

Publication number
RU2522875C2
RU2522875C2 RU2012121404/08A RU2012121404A RU2522875C2 RU 2522875 C2 RU2522875 C2 RU 2522875C2 RU 2012121404/08 A RU2012121404/08 A RU 2012121404/08A RU 2012121404 A RU2012121404 A RU 2012121404A RU 2522875 C2 RU2522875 C2 RU 2522875C2
Authority
RU
Russia
Prior art keywords
input
inputs
stage
output
bits
Prior art date
Application number
RU2012121404/08A
Other languages
Russian (ru)
Other versions
RU2012121404A (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 RU2012121404/08A priority Critical patent/RU2522875C2/en
Publication of RU2012121404A publication Critical patent/RU2012121404A/en
Application granted granted Critical
Publication of RU2522875C2 publication Critical patent/RU2522875C2/en

Links

Images

Landscapes

  • Complex Calculations (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

FIELD: physics, computer engineering.
SUBSTANCE: invention is related to computer engineering, particularly to data processing devices, and can be used in designing automation equipment and functional units of control systems. The device comprises three-state buffers with non-inverting and inverting enable inputs, n bits of an input binary number, (k+1) bits of an output binary code (k=[log2n] floor), wherein the three-state buffers are combined into a pyramid structure consisting of (m-1) steps (m=]log2n[ceiling) and an output unit containing k three-state buffers with an inverting enable input and k three-state buffers with a non-inverting enable input, wherein each i-th step (i=1,…, (m-1)) contains 2i-1 three-state buffers with an inverting enable input and 2i-1 three-state buffers with a non-inverting enable input.
EFFECT: simple device owing to use of same-type elements, a regular structure and links, easy increase of capacity of input information.
2 dwg, 1 tbl

Description

Изобретение относится к вычислительной технике, в частности к устройствам обработки данных, и может быть использовано для построения средств автоматики, функциональных узлов систем управления.The invention relates to computer technology, in particular to data processing devices, and can be used to build automation, functional units of control systems.

Известен шифратор (RU №2023345 С1, МПК Н03М 7/00, G06F 7/38, заявлен 03.07.1991, опубликован 15.11.1994), содержащий первый и второй дешифраторы границы нулей, блок шифрации прямого кода, узел сравнения, блок элементов НЕ, блок элементов И, элемент И-НЕ.A known encoder (RU No. 2023345 C1, IPC Н03М 7/00, G06F 7/38, announced July 3, 1991, published November 15, 1994) containing the first and second decryptors of zero boundaries, a direct code encryption block, a comparison node, a block of elements NOT, block of AND elements, AND element NOT.

Недостатком данного устройства является отсутствие средств для наращивания разрядности входного числа.The disadvantage of this device is the lack of funds for increasing the capacity of the input number.

К причинам, препятствующим достижению указанного ниже технического результата, относятся большие аппаратные затраты и нерегулярность структуры.The reasons that impede the achievement of the technical result indicated below include high hardware costs and an irregular structure.

Известно устройство для упорядочения единиц (SU №1751746 А1, МПК G06F 7/38, 7/06, заявлено 26.11.1990, опубликовано 30.07.1992, Бюл. №28), содержащее по (n-1)-й группе элементов И и ИЛИ (где n - четное число, разрядность операнда, n=2K), две группы К-разрядных входов упорядоченных единиц и n-разрядный выход упорядоченных единиц.A device for arranging units is known (SU No. 1751746 A1, IPC G06F 7/38, 7/06, claimed on 11/26/1990, published on 07/30/1992, Bull. No. 28), containing the (n-1) th group of elements And and OR (where n is an even number, the length of the operand, n = 2K), two groups of K-bit inputs of ordered units and an n-bit output of ordered units.

Недостатком данного устройства является формирование на выходах упорядоченного кода, а не количества единиц.The disadvantage of this device is the formation at the outputs of an ordered code, and not the number of units.

Известно устройство для подсчета количества единиц в двоичном числе (SU №1751749 А1, МПК G06F 7/52, заявлено 10.12.1990, опубликовано 30.07.1992, Бюл. №28), содержащее 2К-1 разрядов входного двоичного числа, блок подсчета количества единиц, формирующий по входному коду упорядоченный код единиц, коммутатор, выходы которого являются выходами остатка устройства, первая и вторая группы информационных входов коммутатора соединены с выходами разрядов с первого по (К-1)-й и с (К+1)-го по (2К-1)-й соответственно блока подсчета количества единиц, выход К-го разряда блока подсчета количества единиц соединен с управляющим входом коммутатора и является выходом частного устройства.A device is known for counting the number of units in a binary number (SU No. 1751749 A1, IPC G06F 7/52, announced December 10, 1990, published July 30, 1992, Bull. No. 28), containing 2K-1 bits of the input binary number, unit for counting the number of units forming the ordered code of units by the input code, a switch whose outputs are the outputs of the remainder of the device, the first and second groups of information inputs of the switch are connected to the outputs of the bits from the first to (K-1) -th and from (K + 1) -th to ( 2K-1) -th, respectively, of the unit for counting the number of units, the output of the K-th category of the sub-unit an even number of units is connected to the control input of the switch and is the output of a private device.

Недостатком данного устройства является формирование на выходах устройства только остатка от деления, а не кода количества единиц.The disadvantage of this device is the formation at the outputs of the device only the remainder of the division, and not the code of the number of units.

К причинам, препятствующим достижению указанного ниже технического результата, относится отсутствие средств для формирования кода числа единиц.The reasons that impede the achievement of the technical result indicated below include the lack of funds for generating a code for the number of units.

Известно устройство для определения количества единиц (нулей) в двоичном числе (заявка RU №2011114163/08, МПК G06F 7/50, Н03K 21/00, заявлено 11.04.2011), содержащее блок управляемой инверсии, состоящий из n-элементов «ИСКЛЮЧАЮЩЕЕ ИЛИ» (n - количество разрядов входного числа), элементы ИЛИ и модули, состоящие из элемента ИСКЛЮЧАЮЩЕЕ ИЛИ и элемента И, которые объединены в группы, состоящие из ярусов, и объединены в k-каскадов (k=]log2n[), так, что каждый i-й каскад содержит g(i)=n/2i групп (i=1,…, k), каждая группа i-го каскада разделена на j ярусов (j=1,…, i), при этом первый ярус каждой группы i-го каскада содержит i модулей, а каждый j-й ярус каждой группы i-го каскада (j=2,…, i,) содержит (i-j) модулей и элемент «ИЛИ».A device is known for determining the number of units (zeros) in a binary number (application RU No. 20111114163/08, IPC G06F 7/50, Н03K 21/00, announced April 11, 2011), containing a controlled inversion unit consisting of n-elements “EXCLUSIVE OR "(N is the number of bits of the input number), OR elements, and modules consisting of an EXCLUSIVE OR element and an AND element that are combined into groups of tiers and combined into k-stages (k =] log 2 n [), so so that each ith cascade contains g (i) = n / 2 i groups (i = 1, ..., k), each group of the ith cascade is divided into j tiers (j = 1, ..., i), while first tier each th group i-th stage comprises a module i and each j-th stage every group i-th stage (j = 2, ..., i,) comprises (ij) module and an element "OR".

Недостатком данного устройства является определение количества единиц от двоичного числа, а не от упорядоченного кода единиц.The disadvantage of this device is the determination of the number of units from a binary number, and not from an ordered unit code.

К причинам, препятствующим достижению указанного ниже технического результата, относятся большие аппаратные затраты.The reasons that impede the achievement of the following technical result include high hardware costs.

Техническим результатом изобретения является упрощение устройства за счет использования однотипных элементов, регулярной структуры и связей, что особенно важно при реализации устройства в виде БИС, а также простое увеличение разрядности входной информации.The technical result of the invention is to simplify the device by using the same elements, regular structure and connections, which is especially important when implementing the device in the form of LSI, as well as a simple increase in the bit depth of the input information.

Указанный технический результат при осуществлении изобретения достигается тем, что в устройство для определения количества единиц в упорядоченном двоичном числе введены буферы с тремя состояниями с прямым и инверсным входами разрешения, n разрядов входного двоичного числа, (k+1) разрядов выходного двоичного кода (k=[log2n] меньшее целое), причем буферы с тремя состояниями объединены в пирамидальную структуру, состоящую из (m-1) ступеней (m=]log2n[большее целое), и в выходной блок, содержащий k буферов с тремя состояниями с инверсным входом разрешения и k буферов с тремя состояниями с прямым входом разрешения, при этом каждая i-я ступень (i=1, (m-1)) содержит 2i-1 буферов с тремя состояниями с инверсным входом разрешения и 2i-1 буферов с тремя состояниями с прямым входом разрешения, причем в каждой i-й ступени и в выходном блоке информационные входы буферов с тремя состояниями с инверсным входом разрешения образуют первую группу входов, информационные входы буферов с тремя состояниями с прямым входом разрешения образуют вторую группу входов, а прямые и инверсные входы разрешения буферов с тремя состояниями, в которых соединены между собой, и являются входами управления соответственно i-й ступени и выходного блока, выходы одноименных буферов с тремя состояниями с прямым и инверсным входами разрешения соединены между собой в каждой i-й ступени и в выходном блоке и являются соответственно их выходами, младшие с первого по (2m-1-1) и старшие с (2m-1+1) по (n-1) разряды входного двоичного числа соединены с соответствующими разрядами первой и второй групп входов (m-1)-й ступени, а (2m-1)-й разряд входного двоичного числа соединен с входом управления (m-1)-й ступени и k-м разрядом первой группы входов выходного блока, младшие с первого по (2j-1-1) и старшие с (2j+1+1) по (2j-1) разряды выходов каждой j-й ступени соединены с соответствующими разрядами первой и второй групп входов (j-1)-й ступени (j=(m-1),…,), а (2j-1)-й разряд выхода каждой j-й ступени соединен с входом управления (j-1)-й ступени и (j-1)-м разрядом первой группы входов выходного блока, выход первой ступени соединен с первым разрядом первой группы входов выходного блока, с первого по k-й разряды второй группы входов выходного блока соединены с логическим нулем, n-й разряд входного двоичного числа соединен с входом управления выходного блока и является (k+1)-м разрядом выходного двоичного кода, с первого по k-й разряды выходов выходного блока являются соответственно с первого по k-й разрядами выходного двоичного кода.The specified technical result in the implementation of the invention is achieved by the fact that buffers with three states with direct and inverse resolution inputs, n bits of the input binary number, (k + 1) bits of the output binary code (k = [log 2 n] is a smaller integer), and the buffers with three states are combined into a pyramidal structure consisting of (m-1) steps (m =] log 2 n [larger integer), and into an output block containing k buffers with three states with inverse input enabled ia and k buffers with three states with a direct resolution input, with each i-th stage (i = 1, (m-1)) containing 2 i -1 buffers with three states with an inverse resolution input and 2 i -1 buffers with three states with a direct permission input, and in each i-th stage and in the output block, the information inputs of buffers with three states with an inverse permission input form the first group of inputs, the information inputs of buffers with three states with a direct permission input form the second group of inputs, and the direct and inverse buffer resolution inputs with tr the states in which they are interconnected and are the control inputs of the i-th stage and the output block, respectively, the outputs of the buffers of the same name with three states with direct and inverse resolution inputs are interconnected in each i-th stage and in the output block, respectively their outputs, the lowest from the first to (2 m-1 -1) and the highest from (2 m-1 + 1) to (n-1) bits of the input binary number are connected to the corresponding bits of the first and second groups of inputs (m-1) -th stage, and the (2 m-1 ) -th bit of the input binary number is connected to the control input of the (m-1) -th stage and the k-th discharge of the first group of inputs of the output block, the lowest from the first to (2 j-1 -1) and the oldest from (2 j + 1 +1) to (2 j -1) the bits of the outputs of each j-th stage are connected to the corresponding bits of the first and second groups of inputs of the (j-1) -th stage (j = (m-1), ...,), and the (2 j-1 ) -th bit of the output of each j -th stage is connected to the control input of the (j-1) -th stage and (j-1) -th bit of the first group of inputs of the output block, the output of the first stage is connected to the first bit of the first group of inputs of the output block, from the first to k-th bits the second group of inputs of the output unit are connected to zeroth, the nth bit of the input binary number is connected to the control input of the output block and is the (k + 1) th bit of the output binary code, from the first to the kth bits of the outputs of the output block are, respectively, from the first to the kth bits of the output binary code.

На фиг.1 представлена схема предлагаемого устройства для определения количества единиц в упорядоченном двоичном числе при n=16. На фиг.2 приведен граф проверки разрядов и формирование выходного двоичного кода В4,…, В0.Figure 1 presents a diagram of the proposed device for determining the number of units in an ordered binary number with n = 16. Figure 2 shows the graph check bits and the formation of the output binary code B4, ..., B0.

На фиг.1 приняты следующие обозначения: пирамидальная структура устройства содержит первую 1, вторую 2 и третью 3 ступени, выходной блок 4, n разрядов D1,…, D16 (при n=16) входного двоичного числа 5, (k+1) разрядов В0,…, В4 выходного двоичного кода 6, буферы с тремя состояниями с инверсным входом разрешения 7, буферы с тремя состояниями с прямым входом разрешения 8, входы управления ступеней обозначены А.In Fig. 1, the following notation is used: the pyramidal structure of the device contains the first 1, second 2, and third 3 steps, the output unit 4, n bits D1, ..., D16 (for n = 16) of the input binary number 5, (k + 1) bits B0, ..., B4 of the output binary code 6, buffers with three states with an inverse input of resolution 7, buffers with three states with a direct input of resolution 8, control inputs of the steps are marked A.

Устройство для определения количества единиц в упорядоченном двоичном числе содержит буферы с тремя состояниями с инверсным 7 и прямым 8 входами разрешения, n разрядов D1,…, D16 (при n=16) входного двоичного числа, (k+1) разрядов В0,…, В4 (при k=4) выходного двоичного кода (k=[log2n] меньшее целое).A device for determining the number of units in an ordered binary number contains buffers with three states with inverse 7 and direct 8 resolution inputs, n bits D1, ..., D16 (for n = 16) of the input binary number, (k + 1) bits B0, ..., B4 (for k = 4) of the output binary code (k = [log 2 n] is a smaller integer).

Буферы с тремя состояниями объединены в пирамидальную структуру, состоящую из (m-1) ступеней (m=]log2n[большее целое) - первой 1, второй 2 и третьей 3 ступеней при (m-1)=3. Выходной блок 4 содержит четыре буфера с тремя состояниями с инверсным входом разрешения 7 и четыре буфера с тремя состояниями с прямым входом разрешения 8 (при k=4). Первая ступень 1 содержит один буфер 7 с тремя состояниями с инверсным входом разрешения и один буфер 8 с тремя состояниями с прямым входом разрешения. Вторая ступень 2 содержит три буфера 7 с тремя состояниями с инверсным входом разрешения и три буфера 8 с тремя состояниями с прямым входом разрешения. Третья ступень 3 содержит семь буферов 7 с тремя состояниями с инверсным входом разрешения и семь буферов 8 с тремя состояниями с прямым входом разрешения. Каждая следующая i-я ступень (i=4,…, (m-1)) содержит 2i-1 буферов 7 с тремя состояниями с инверсным входом разрешения и 2i-1 буферов 8 с тремя состояниями с прямым входом разрешения.Buffers with three states are combined into a pyramidal structure consisting of (m-1) steps (m =] log 2 n [larger integer) - the first 1, second 2, and third 3 steps with (m-1) = 3. Output block 4 contains four buffers with three states with an inverse input of resolution 7 and four buffers with three states with a direct input of resolution 8 (for k = 4). The first stage 1 contains one buffer 7 with three states with an inverse resolution input and one buffer 8 with three states with a direct resolution input. The second stage 2 contains three buffers 7 with three states with an inverse resolution input and three buffers 8 with three states with a direct resolution input. The third stage 3 contains seven buffers 7 with three states with an inverse resolution input and seven buffers 8 with three states with a direct permission input. Each next i-th stage (i = 4, ..., (m-1)) contains 2 i -1 buffers 7 with three states with an inverse resolution input and 2 i -1 buffers 8 with three states with a direct resolution input.

В первой 1, второй 2, третьей 3 и каждой следующей i-й ступени и в выходном блоке 4 информационные входы буферов 7 с тремя состояниями с инверсным входом разрешения образуют первую группу входов, информационные входы буферов 8 с тремя состояниями с прямым входом разрешения образуют вторую группу входов, а прямые и инверсные входы разрешения буферов с тремя состояниями в которых соединены между собой и являются входами управления А соответственно первой 1, второй 2, третьей 3 и каждой i-й ступени и выходного блока 4.In the first 1, second 2, third 3, and each subsequent i-th stage and in the output unit 4, the information inputs of buffers 7 with three states with an inverse resolution input form the first group of inputs, the information inputs of buffers 8 with three states with a direct resolution input form the second a group of inputs, and direct and inverse inputs of the resolution of buffers with three states in which are interconnected and are control inputs A, respectively, of the first 1, second 2, third 3 and each i-th stage and output block 4.

Выходы одноименных буферов с тремя состояниями с прямым 8 и инверсным 7 входами разрешения соединены между собой в каждой i-й ступени и в выходном блоке 4 и являются соответственно их выходами.The outputs of the buffers of the same name with three states with direct 8 and inverse 7 resolution inputs are interconnected in each i-th stage and in output block 4 and are their outputs, respectively.

Младшие с первого по седьмой D1,…, D7 и старшие с девятого по пятнадцатый D9,…, D15 разряды входного двоичного числа 5 (при n=16) соединены с соответствующими разрядами первой и второй групп входов самой старшей третьей ступени 3, а восьмой D8 разряд входного двоичного числа 5 соединен с входом управления А третьей ступени 3 и четвертым разрядом первой группы входов выходного блока 4.The lowest from the first to the seventh D1, ..., D7 and the highest from the ninth to the fifteenth D9, ..., D15 bits of the input binary number 5 (with n = 16) are connected to the corresponding bits of the first and second groups of inputs of the oldest third stage 3, and the eighth D8 the bit of the input binary number 5 is connected to the control input A of the third stage 3 and the fourth bit of the first group of inputs of the output block 4.

Младший первый и старший третий разряды выходов второй ступени 2 соединены с соответствующими разрядами первой и второй групп входов первой ступени 1, а второй разряд выхода второй ступени 2 соединен с входом управления А первой ступени 1 и вторым разрядом первой группы входов выходного блока 4. Выход первой ступени 1 соединен с первым разрядом первой группы входов выходного блока 4.The junior first and senior third bits of the outputs of the second stage 2 are connected to the corresponding bits of the first and second groups of inputs of the first stage 1, and the second bit of the output of the second stage 2 is connected to the control input A of the first stage 1 and the second bit of the first group of inputs of the output unit 4. The output of the first stage 1 is connected to the first discharge of the first group of inputs of the output unit 4.

Младшие с первого по третий и старшие с пятого по седьмой разряды выходов третьей ступени 3 соединены с соответствующими разрядами первой и второй групп входов второй ступени 2, а четвертый разряд выхода третьей ступени 3 соединен с входом управления А второй ступени 2 и третьим разрядом первой группы входов выходного блока 4.The first to third, and the fifth to seventh bits of the outputs of the third stage 3 are connected to the corresponding bits of the first and second groups of inputs of the second stage 2, and the fourth discharge of the output of the third stage 3 is connected to the control input A of the second stage 2 and the third discharge of the first group of inputs output block 4.

Для следующих старших ступеней младшие с первого по (2j-1-1) и старшие с (2j-1+1) по (2j-1) разряды выходов каждой j-й ступени соединены с соответствующими разрядами первой и второй групп входов (j-1)-M ступени (j=(m-1),…, 3)), а (2j-1)-й разряд выхода каждой j-й ступени соединен с входом управления (j-1)-и ступени и (j-1)-M разрядом первой группы входов выходного блока 4.For the next higher stages, the lowest from the first to (2 j-1 -1) and the highest from (2 j-1 +1) to (2 j -1) output bits of each j-th stage are connected to the corresponding bits of the first and second groups of inputs (j-1) -M stage (j = (m-1), ..., 3)), and the (2 j-1 ) -th bit of the output of each j-th stage is connected to the control input of the (j-1) -and stage and (j-1) -M discharge of the first group of inputs of the output unit 4.

С первого по k-й разряды второй группы входов выходного блока 4 соединены с логическим нулем. Шестнадцатый D16 (n-й) разряд входного двоичного числа 5 соединен с входом управления А выходного блока 4 и является пятым ((k+1)-м) разрядом выходного двоичного кода 6, с первого по четвертый (k-й) разряды выходов выходного блока 4 являются соответственно с первого по четвертый (k-й) разрядами выходного двоичного кода 6.From the first to the kth bits of the second group of inputs of the output unit 4 are connected to a logical zero. The sixteenth D16 (n-th) bit of the input binary number 5 is connected to the control input A of the output block 4 and is the fifth ((k + 1) -th) bit of the output binary code 6, from the first to the fourth (k-th) bit of the outputs of the output block 4 are respectively the first to fourth (k-th) bits of the output binary code 6.

В вершинах графа на фиг.2 указаны проверяемые разряды входного упорядоченного числа 5. На дугах, связывающих вершины графа, отмечены логические условия, при которых происходит выборка следующего разряда.At the vertices of the graph in Fig. 2, the checked digits of the input ordered number are indicated 5. On the arcs connecting the vertices of the graph, the logical conditions are noted under which the next digit is sampled.

Предлагаемое устройство для определения количества единиц в упорядоченном двоичном числе работает следующим образом. На его первый - шестнадцатый разряды входного двоичного числа 5 подаются входные сигналы D1,…, D16 упорядоченного двоичного числа с единицами расположенными подряд, начиная с младших разрядов D1. В зависимости от значения восьмого разряда D8 на выход третьей ступени 3 передаются семь младших разряды D1,…, D7 (при D8=0) или семь старших разрядов D9,…, D15 (при D8=1). Значение разряда D8=0 указывает на то, что количество единиц меньше восьми, а значение D8=1 равно или больше восьми. Значение разряда D8 поступает также на четвертый вход первой группы выходного блока 4 и формирует разряд В3.The proposed device for determining the number of units in an ordered binary number works as follows. At its first - sixteenth bits of the input binary number 5, the input signals D1, ..., D16 of an ordered binary number with units in a row starting from the least significant bits of D1 are supplied. Depending on the value of the eighth bit D8, the seven lower-order bits D1, ..., D7 (with D8 = 0) or seven high-order bits D9, ..., D15 (with D8 = 1) are transmitted to the output of the third stage 3. The value of the discharge D8 = 0 indicates that the number of units is less than eight, and the value of D8 = 1 is equal to or greater than eight. The value of the discharge D8 is also supplied to the fourth input of the first group of the output unit 4 and forms a discharge B3.

Значение четвертого выхода третьей ступени 3 указывает на то, что количество единиц меньше четырех (при нулевом значении выбранных разрядов D12 или D4) и равно или больше четырех (при единичном значении D12 или D4), в выделенных третьей ступенью 3 соответствующих семи разрядах. Этот четвертый выход третей ступени 3 поступает на третий вход первой группы выходного блока 4 и формирует разряд В2, а также поступает на вход управления А второй ступени 2. В зависимости от значения этого сигнала на выходы второй ступени 2 передаются три младших или три старших разряда.The value of the fourth output of the third stage 3 indicates that the number of units is less than four (with a zero value of the selected digits D12 or D4) and equal to or greater than four (with a single value of D12 or D4), in the 3 selected by the third stage 3 corresponding seven digits. This fourth output of the third stage 3 goes to the third input of the first group of the output unit 4 and forms bit B2, and also goes to the control input A of the second stage 2. Depending on the value of this signal, the three junior or three senior bits are transmitted to the outputs of the second stage 2.

Значение второго выхода второй ступени 2 указывает на то, что количество единиц равно одной (при нулевом значении выбранного разряда D14 или D10 или D6 или D2) и равно или больше двух (при единичном значении D14 или D10 или D6 или D2), в выделенных второй ступенью 2 соответствующих трех разрядах. Этот второй выход поступает на второй вход первой группы выходного блока 4 и формирует разряд В1, а также поступает на вход управления А первой ступени 1. В зависимости от значения этого сигнала на выход первой ступени 1 передается младший первый или старший третий разряд (разряды D15 или D13 или D11 или D9 или D7 или D5 или D3 или D1 входного двоичного числа 5). На выходе первой ступени 1 формируется сигнал В0, поступающий на первый вход первой группы выходного блока 4, значение этого сигнала указывает на четное количество единиц (нулевое единичное значение) или нечетное количество единиц (единичное значение) в исходном упорядоченном двоичном числе 5.The value of the second output of the second stage 2 indicates that the number of units is equal to one (at zero value of the selected discharge D14 or D10 or D6 or D2) and equal to or more than two (at a unit value of D14 or D10 or D6 or D2), in the highlighted second stage 2 corresponding to three digits. This second output goes to the second input of the first group of the output unit 4 and forms a discharge B1, and also goes to the control input A of the first stage 1. Depending on the value of this signal, the junior first or senior third digit is transferred to the output of the first stage 1 (bits D15 or D13 or D11 or D9 or D7 or D5 or D3 or D1 of the input binary number 5). At the output of the first stage 1, a signal B0 is generated, which arrives at the first input of the first group of output block 4, the value of this signal indicates an even number of units (zero unit value) or an odd number of units (unit value) in the original ordered binary number 5.

Если в исходном двоичном числе 5 количество единиц равно шестнадцати, то разряд D16=1. При этом на всех выходах всех ступеней устройства будут также сформированы единичные значения. Для обнуления значений всех разрядов выходного кода В сигнал D16=1 поступает на вход управления А выходного блока 4, который устанавливает на выходах блока 4 нулевые значения, так как при этом на его выходы передается значение со второй группы входов блока 4, на которых установлен логический ноль. Шестнадцатый разряд D16 входного упорядоченного двоичного числа 5 является старшим разрядом В4 выходного двоичного кода 6.If in the original binary number 5 the number of units is sixteen, then the digit D16 = 1. Moreover, at all outputs of all stages of the device, unit values will also be generated. To reset the values of all bits of the output code B, the signal D16 = 1 is fed to the control input A of the output block 4, which sets the outputs of block 4 to zero values, since the values from the second group of inputs of block 4, on which the logic zero. The sixteenth bit D16 of the input ordered binary number 5 is the highest bit B4 of the output binary code 6.

Таким образом, на выходах 6 выходного блока 4 формируется двоичный код В4, В3, В2, В1, В0 числа единиц во входном упорядоченном двоичном числе 5.Thus, at the outputs 6 of the output unit 4, a binary code B4, B3, B2, B1, B0 of the number of units in the input ordered binary number 5 is generated.

Если количество n разрядов D входного упорядоченного двоичного числа 5 не кратно степени 2, то старшие разряды дополняются нулевыми значениями. В таблице 1 приведены значения количества ступеней (m-1) и количества выходных разрядов (k+1) в устройстве в зависимости от количества n входных разрядов.If the number n digits D of the input ordered binary number 5 is not a multiple of degree 2, then the higher digits are supplemented by zero values. Table 1 shows the values of the number of steps (m-1) and the number of output bits (k + 1) in the device depending on the number n of input bits.

Вышеизложенные сведения позволяют сделать вывод, что предлагаемое устройство для определения количества единиц в упорядоченном двоичном числе содержит однотипные элементы - буферы с тремя состояниями, обладает регулярностью структуры и связей, что особенно важно при реализации устройства в виде БИС, и соответствует заявляемому техническому результату - упрощение устройства и простое увеличение разрядности входной информации.The above information allows us to conclude that the proposed device for determining the number of units in an ordered binary number contains elements of the same type - buffers with three states, has regular structure and relationships, which is especially important when implementing the device in the form of LSI, and corresponds to the claimed technical result - simplification of the device and a simple increase in the bit depth of the input information.

Таблица 1Table 1 Устройство для определения количества единиц в упорядоченном двоичном числеDevice for determining the number of units in an ordered binary number Количество разрядов, nNumber of digits, n 4four 88 1212 1616 2424 3232 Меньшее целое, k=[log2n]Smaller integer, k = [log 2 n] 22 33 33 4four 4four 55 Большее целое, m=]log2n[Larger integer, m =] log 2 n [ 22 33 4four 4four 55 55 Количество ступеней, m-1Number of steps, m-1 1one 22 33 33 4four 4four Количество разрядов выхода, k+1The number of bits of the output, k + 1 33 4four 4four 55 55 66

Claims (1)

Устройство для определения количества единиц в упорядоченном двоичном числе, содержащее буферы с тремя состояниями с прямым и инверсным входами разрешения, n разрядов входного двоичного числа, (k+1) разрядов выходного двоичного кода (k=[log2n] меньшее целое), причем буферы с тремя состояниями объединены в пирамидальную структуру, состоящую из (m-1) ступеней (m=]log2n[большее целое), и в выходной блок, содержащий k буферов с тремя состояниями с инверсным входом разрешения и k буферов с тремя состояниями с прямым входом разрешения, при этом каждая i-я ступень (i=l,…, (m-1)) содержит 2i-1 буферов с тремя состояниями с инверсным входом разрешения и 2i-1 буферов с тремя состояниями с прямым входом разрешения, причем в каждой i-й ступени и в выходном блоке информационные входы буферов с тремя состояниями с инверсным входом разрешения образуют первую группу входов, информационные входы буферов с тремя состояниями с прямым входом разрешения образуют вторую группу входов, а прямые и инверсные входы разрешения буферов с тремя состояниями в которых соединены между собой и являются входами управления соответственно i-й ступени и выходного блока, выходы одноименных буферов с тремя состояниями с прямым и инверсным входами разрешения соединены между собой в каждой i-й ступени и в выходном блоке и являются соответственно их выходами, младшие с первого по (2m-1-1) и старшие с (2m-1+1) по (n-1) разряды входного двоичного числа соединены с соответствующими разрядами первой и второй групп входов (m-1)-й ступени, а (2m-1)-й разряд входного двоичного числа соединен с входом управления (m-1)-й ступени и k-м разрядом первой группы входов выходного блока, младшие с первого по (2j-1-1) и старшие с (2j-1+1) по (2j-1) разряды выходов каждой j-й ступени соединены с соответствующими разрядами первой и второй групп входов (j-1)-й ступени (j=(m-l),…, 2)), a (2j-1)-й разряд выхода каждой j-й ступени соединен с входом управления (j-1)-й ступени и (j-1)-м разрядом первой группы входов выходного блока, выход первой ступени соединен с первым разрядом первой группы входов выходного блока, с первого по k-й разряды второй группы входов выходного блока соединены с логическим нулем, n-й разряд входного двоичного числа соединен с входом управления выходного блока и является (k+1)-м разрядом выходного двоичного кода, с первого по k-й разряды выходов выходного блока являются соответственно с первого по k-й разрядами выходного двоичного кода. A device for determining the number of units in an ordered binary number, containing buffers with three states with direct and inverse resolution inputs, n bits of the input binary number, (k + 1) bits of the output binary code (k = [log 2 n] is a smaller integer), and buffers with three states are combined into a pyramidal structure consisting of (m-1) steps (m =] log 2 n [larger integer), and into an output block containing k buffers with three states with an inverse resolution input and k buffers with three states with direct permission input, with each i-st stump (i = l, ..., ( m- 1)) contains 2 i -1 tristate buffers with an inverted enable input and 2 i -1 tristate buffers direct enable input, wherein in each i-th stage and the output block, the information inputs of buffers with three states with an inverse permission input form the first group of inputs, the information inputs of buffers with three states with a direct permission input form the second group of inputs, and the direct and inverse inputs of the resolution buffers with three states in which are interconnected and are inputs management with Responsibly of the i-th stage and the output block, the outputs of the buffers of the same name with three states with direct and inverse resolution inputs are interconnected in each i-th stage and in the output block and are respectively their outputs, the lowest from the first to (2 m-1 - 1) and the highest from (2 m-1 + 1) to (n-1) bits of the input binary number are connected to the corresponding bits of the first and second groups of inputs of the (m-1) -th stage, and (2 m-1 ) -th the bit of the input binary number is connected to the control input of the (m-1) -th stage and the k-th bit of the first group of inputs of the output block, the least first in (2 j-1 -1) and the highest from (2 j-1 +1) to (2 j -1) output bits of each j-th stage are connected to the corresponding bits of the first and second groups of inputs (j-1) - -th stage (j = (ml), ..., 2)), a (2 j-1 ) -th output bit of each j-th stage is connected to the control input of the (j-1) -th stage and (j-1) - m bit of the first group of inputs of the output block, the output of the first stage is connected to the first bit of the first group of inputs of the output block, from the first to kth bits of the second group of inputs of the output block are connected to a logic zero, the n-th bit of the input binary number is connected to the control input of the output block and is the (k + 1) -th bit of the output binary code, from the first to the k-th bits of the outputs of the output block are, respectively, the first to the k-th bits of the output binary code.
RU2012121404/08A 2012-05-24 2012-05-24 Device for determining number of ones in ordered binary number RU2522875C2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
RU2012121404/08A RU2522875C2 (en) 2012-05-24 2012-05-24 Device for determining number of ones in ordered binary number

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
RU2012121404/08A RU2522875C2 (en) 2012-05-24 2012-05-24 Device for determining number of ones in ordered binary number

Publications (2)

Publication Number Publication Date
RU2012121404A RU2012121404A (en) 2013-11-27
RU2522875C2 true RU2522875C2 (en) 2014-07-20

Family

ID=49625064

Family Applications (1)

Application Number Title Priority Date Filing Date
RU2012121404/08A RU2522875C2 (en) 2012-05-24 2012-05-24 Device for determining number of ones in ordered binary number

Country Status (1)

Country Link
RU (1) RU2522875C2 (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
RU2633110C1 (en) * 2016-12-09 2017-10-11 федеральное государственное автономное образовательное учреждение высшего образования "Национальный исследовательский ядерный университет "МИФИ" (НИЯУ МИФИ) Device for determining number of senior units (zeros) in binary number
RU2717934C1 (en) * 2019-12-19 2020-03-27 федеральное государственное автономное образовательное учреждение высшего образования "Национальный исследовательский ядерный университет МИФИ" (НИЯУ МИФИ) Device for on-bit range boundary detecting
RU2728957C1 (en) * 2020-01-15 2020-08-03 федеральное государственное автономное образовательное учреждение высшего образования "Национальный исследовательский ядерный университет "МИФИ" (НИЯУ МИФИ) Device for detecting groups of bits in a binary sequence
RU2759002C1 (en) * 2021-03-11 2021-11-08 федеральное государственное автономное образовательное учреждение высшего образования "Национальный исследовательский ядерный университет МИФИ" (НИЯУ МИФИ) Device of parallel-sequential structure for detecting the boundaries of the range of single bits
RU2791464C1 (en) * 2022-03-18 2023-03-09 федеральное государственное бюджетное образовательное учреждение высшего образования "Ульяновский государственный технический университет" Device for selecting the smallest of binary numbers

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
RU2680762C1 (en) * 2018-04-13 2019-02-26 федеральное государственное автономное образовательное учреждение высшего образования "Национальный исследовательский ядерный университет МИФИ" (НИЯУ МИФИ) Device of group structure for detection of groups of zero and one bits and determination of their quantity
RU2711054C1 (en) * 2019-08-06 2020-01-14 федеральное государственное автономное образовательное учреждение высшего образования "Национальный исследовательский ядерный университет МИФИ" (НИЯУ МИФИ) Device of parallel-serial structure for detection of groups of zero and single bits and determination of their number

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
SU1363477A1 (en) * 1986-02-07 1987-12-30 Харьковский политехнический институт им.В.И.Ленина Device for counting unit number
SU1751749A1 (en) * 1990-12-10 1992-07-30 Одесский Политехнический Институт Device for counting ones in double-numbers
US5339447A (en) * 1989-11-17 1994-08-16 Texas Instruments Incorporated Ones counting circuit, utilizing a matrix of interconnected half-adders, for counting the number of ones in a binary string of image data
RU2030783C1 (en) * 1991-07-03 1995-03-10 Дагестанский Политехнический Институт Device for determination of number of units in binary eight-digit code
US6904114B2 (en) * 2003-04-25 2005-06-07 J. Barry Shackleford Ones counter employing two dimensional cellular array
WO2007002802A1 (en) * 2005-06-28 2007-01-04 Qualcomm Incorporated System and method of counting leading zeros and counting leading ones in a digital signal processor
RU2446442C1 (en) * 2011-04-11 2012-03-27 Федеральное государственное бюджетное образовательное учреждение высшего профессионального образования "Национальный исследовательский ядерный университет "МИФИ" (НИЯУ МИФИ) Device for determining number of ones (zeros) in binary number

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
SU1363477A1 (en) * 1986-02-07 1987-12-30 Харьковский политехнический институт им.В.И.Ленина Device for counting unit number
US5339447A (en) * 1989-11-17 1994-08-16 Texas Instruments Incorporated Ones counting circuit, utilizing a matrix of interconnected half-adders, for counting the number of ones in a binary string of image data
SU1751749A1 (en) * 1990-12-10 1992-07-30 Одесский Политехнический Институт Device for counting ones in double-numbers
RU2030783C1 (en) * 1991-07-03 1995-03-10 Дагестанский Политехнический Институт Device for determination of number of units in binary eight-digit code
US6904114B2 (en) * 2003-04-25 2005-06-07 J. Barry Shackleford Ones counter employing two dimensional cellular array
WO2007002802A1 (en) * 2005-06-28 2007-01-04 Qualcomm Incorporated System and method of counting leading zeros and counting leading ones in a digital signal processor
RU2446442C1 (en) * 2011-04-11 2012-03-27 Федеральное государственное бюджетное образовательное учреждение высшего профессионального образования "Национальный исследовательский ядерный университет "МИФИ" (НИЯУ МИФИ) Device for determining number of ones (zeros) in binary number

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
RU2633110C1 (en) * 2016-12-09 2017-10-11 федеральное государственное автономное образовательное учреждение высшего образования "Национальный исследовательский ядерный университет "МИФИ" (НИЯУ МИФИ) Device for determining number of senior units (zeros) in binary number
RU2717934C1 (en) * 2019-12-19 2020-03-27 федеральное государственное автономное образовательное учреждение высшего образования "Национальный исследовательский ядерный университет МИФИ" (НИЯУ МИФИ) Device for on-bit range boundary detecting
RU2728957C1 (en) * 2020-01-15 2020-08-03 федеральное государственное автономное образовательное учреждение высшего образования "Национальный исследовательский ядерный университет "МИФИ" (НИЯУ МИФИ) Device for detecting groups of bits in a binary sequence
RU2759002C1 (en) * 2021-03-11 2021-11-08 федеральное государственное автономное образовательное учреждение высшего образования "Национальный исследовательский ядерный университет МИФИ" (НИЯУ МИФИ) Device of parallel-sequential structure for detecting the boundaries of the range of single bits
RU2791464C1 (en) * 2022-03-18 2023-03-09 федеральное государственное бюджетное образовательное учреждение высшего образования "Ульяновский государственный технический университет" Device for selecting the smallest of binary numbers

Also Published As

Publication number Publication date
RU2012121404A (en) 2013-11-27

Similar Documents

Publication Publication Date Title
RU2522875C2 (en) Device for determining number of ones in ordered binary number
RU2446442C1 (en) Device for determining number of ones (zeros) in binary number
US20080215584A1 (en) Shared-Memory Multiprocessor System and Method for Processing Information
JPH10232765A (en) Arithmetic method for arithmetic unit, storage medium and arithmetic unit
CN103226543B (en) FFT processor with pipeline structure
RU2680762C1 (en) Device of group structure for detection of groups of zero and one bits and determination of their quantity
US20150070957A1 (en) Semiconductor device and method of writing/reading entry address into/from semiconductor device
RU2717934C1 (en) Device for on-bit range boundary detecting
US10078646B2 (en) Hardware efficient fingerprinting
RU2633110C1 (en) Device for determining number of senior units (zeros) in binary number
RU2717631C1 (en) Unit for single-bit range detection
Christakis et al. High speed binary counter based on 1D Cellular Automata
JP6094321B2 (en) Buffer circuit and semiconductor integrated circuit
Majumder et al. Investigation on Quine McCluskey method: A decimal manipulation based novel approach for the minimization of Boolean function
RU2672626C1 (en) Zeros and ones number by groups in the binary number determining device
Dattatraya et al. Modified Carry Select Adder using Binary Adder as a BEC-1
Soundharya et al. GDI based area delay power efficient carry select adder
Chen et al. An improved 32-bit carry-lookahead adder with Conditional Carry-Selection
Smrithi et al. A fast architecture for maximum/minimum data finder with address from a set of data
CN113031911A (en) Multiplier, data processing method, device and chip
Norollah et al. An efficient sorting architecture for area and energy constrained edge computing devices
JP3727301B2 (en) Adder circuit and semiconductor device provided with adder circuit
CN105843837B (en) Hardware efficient rabin fingerprinting
Kathuria et al. Novel tree based priority encoder design technique
Alia et al. On the lower bound to the VLSI complexity of number conversion from weighted to residue representation

Legal Events

Date Code Title Description
MM4A The patent is invalid due to non-payment of fees

Effective date: 20190525