0
votes
3answers
21 views

How to borrow from zeroes in binary subtraction (no complements)b?

I know you can use complements to subtract, but I want to subtract these two binary numbers without that. I am unsure of how to borrow numbers from zero, check it out: 1000000 -101100 How do I ...
0
votes
1answer
69 views

Inserting values left to right in a binary search tree

What does it mean to build a binary search tree by inserting values from left to right starting from an empty tree? The "left to right" part confuses me..I know how to build one by normally inserting ...
1
vote
4answers
127 views

17539 decimal to binary not getting the same result

I'm trying to convert 17539 to binary. My math says its 110000010010001, but online calculators like this and this say it equals to 100010010000011. Who is making something wrong.
1
vote
2answers
179 views

Number of binary strings with $n$ ones and $m$ zeros

$f(n,m)$ is the number of binary strings with up to $n$ ones and up to $m$ zeros. Prove that the number of possible strings is: $${n+m+2 \choose n+1} -1$$ I got to the point that: $$\sum_{a=0}^n ...
2
votes
1answer
92 views

number of binary sets - combinatorics

Just ran into this question: let $f(n,m)$ be the number of binary strings where there are at most $n$ 1's and at most $m$ 0's. the empty string also counts as a string. show that ...
-1
votes
1answer
567 views

Semigroups, monoids, & groups!

I need help determining if these are semigroups, monoids, or groups? a) $\mathbb Z ^+$, where $\#$ is defined as ordinary multiplication b) $\mathbb Z ^+$, where $a \# b$ is defined as $\gcd(a,b)$ ...
0
votes
2answers
200 views

Constructing a tree from an algebraic equation

How do I take an algebraic expression and construct a tree out of it? Sample equation: ((2 + x) - (x * 3)) - ((x - 2) * (3 + y)) If somebody can teach me in steps, that would be really helpful!
1
vote
3answers
1k views

Way of simplifying binary multiplication

Is there a way to simplify multiplication of binary numbers regardless of digits? Or do we always have to resort to 10-base multiplication? As computers do multiplication, there should be ways to ...
5
votes
1answer
115 views

What function $f$ such that $a_1 \oplus\, \cdots\,\oplus a_n = 0$ implies $f(a_1) \oplus\, \cdots\,\oplus f(a_n) \neq 0$

For a certain algorithm, I need a function $f$ on integers such that $a_1 \oplus a_2 \oplus \, \cdots\,\oplus a_n = 0 \implies f(a_1) \oplus f(a_2) \oplus \, \cdots\,\oplus f(a_n) \neq 0$ (where the ...
1
vote
0answers
131 views

1s surpassing 0s in binary strings of odd length

Let $A(k)$ be the number of distinct binary strings of length $2k+1,$ for which the number of $1$s surpasses the number of $0$s for the first time at digit number $2k +1$, i.e., in the final digit in ...