Boolean function expression

92 Views Asked by At

I have an interesting problem.

How do I express the following as a boolean function?

HD ($2^4$, 1100) >=2

HD = Hamming distance

$2^4$= {0000,0001,0010.....all 16 binary values}

The answer is {0001,0010,0011,0101,0110,0111,1001,1010,1011}

So I am trying to express all the binary bits that have HD >=2 with 1100 in boolean function.

Please let me know the proper notations for representation too e.g. what's the proper notation to represent all 16, 4 bits in binary?

1

There are 1 best solutions below

8
On

I would write $\{0,1\}^4$ for the set of all bitstrings of length $4$, and the set you want as $$\{x \in \{0,1\}^4: d_H(x,0010) \ge 2\}$$ where I use $d_H$ for Hamming distance.

A Boolean function (in this context) is a function from $\{0,1\}^4$ to $\{0,1\}$ and is a different type of object.