# Questions tagged [binary]

For questions about representing numbers in base 2 or performing arithmetic on them.

155 questions
Filter by
Sorted by
Tagged with
47 views

### Binary range identification in terms of subset

Given a range of "K" bit numbers, we want to identify the whole range by using a subset within that range, with the following criteria - If there are > "n" consecutive 0s, it ...
35 views

### Absolute difference between largest IEEE754 number and its predecesor

In simple precision format, the largest possible positive number is $A = 0 ~~~ 11111110 ~~~ 111\ldots 111$ Its predecessor is $B = 0 ~~~ 11111110 ~~~ 111 \ldots 110$ But what is the absolute ...
22 views

### Binary Comparison Between Two Integers

Say I have two integers,i and j, which for the sake of example will be 2 and 5, represented by $010_2$ and $101_2$ respectively. I have a third bit set to 0. If $j \geq i$, then this bit should change ...
29 views

### Classifying vectors that only contains 1001110101 numbers - Is Support Vector Machine the solution?

Assume that you are given a vector 0b1101001001011001 etc. And you are going to classify it. One can use Support Vector Machine, but is that method good for ...
65 views

### How do I multiply 2 signed 4 bit numbers in a logic circuit?

I've been experimenting with making a binary calculator lately, and I've got the addition and subtraction working. I now want to start making a multiplier, but I have no idea where to even start. I ...
85 views

### Why is 2's complement used for representing negative numbers?

So I was reading the use complement operation in the digital logic and found, it is used to give additive inverse of the number and subtracting a number (like we do) is difficult for computer. So it ...
54 views

### 1's and 2's complement of 0

In the Morris Mano's book on Digital Circuits Edition 3, it is defined that r's complement for N=0 is 0 and r-1 complement is not even defined. But lets say r = base = 2 Then 2'd complement of 0, ...
40 views

### Binary combinatorics with rank

I am looking at finding acceptable binary values with maximum 2 consecutive 1s and 0s, from a range of maximum 6 bits (2^6 values). Also, I want to rank and unrank these subset of values (in ...
27 views

### DFA for "K" bit value with max "n" consecutive "0"s and "1"s

I had posted earlier a question regarding ranking max "n" consecutive "0"s and "1"s in a "K"-bit string - Order in a subset I got clarification regarding how ...
126 views

### How do you convert this x86 assembly program to binary

I'm trying to convert a x86 assembly language program to binary. I have read a 1979 Intel 8086 manual and so understand the basic architecture, however I am still unsure as to how to convert this. ...
1 vote
64 views

### Order in a subset

Lets consider a range of "K" binary digit numbers. In that range, we want to take a subset of those values which have (<="n" consecutive 0s) AND (<="n" consecutive ...
34 views

### Exact Definition of simple bit pattern?

I didn't find an exact description for this, but I know that any integer type is a simple bit pattern, it seems to me that the simple bit pattern should have a more exact description as I understand ...
1 vote
125 views

### How does Decimal to Binary conversion algorithm work?

I'm reading a book which says that to transform a number from decimal representation to binary representation you have to follow these steps: Take the integer part (the one before the point) of the ...
57 views

### ASCII invariant string for base64 Encoding

I know the basics about base64 encoding, but thinking about it abstractly I have a theoretical question. If we consider base64 a mathematical function(in our case computable), Does there exists an ...
58 views

### How a computer works?

I know that a computer can be mechanical, screws/nuts or even water/pipes. Of course, it would be slow and big, but it doesn't have to be electric, transistors, etc. How can a machine like this do all ...
1 vote
66 views

### Difficulty Understanding a Quick Method for Finding the Two's Complement of a Binary Number

This is more for my curiosity than anything else as I understand how to find the two's complement of a binary number via the standard approach which is to convert all 0s to 1s and 1s to 0s and then ...