Home > Back-end >  Binary functions using only addition and bitwise NOT
Binary functions using only addition and bitwise NOT

Time:10-26

So, I working on a minecraft redstone computer project, implementing my own CPU in HEX(analog redstone). I managed to implement an arithmetic ADD and bitwise NOT functions, and also conditional jumping. The functions are 4-bit bitwise. But with hex redstone it is hard to make other logical functions compact. So, my question is, can it be turing complete with only those functions? And, if yes, how can I implement other logical functions (like AND, OR, XOR) using only those?

CodePudding user response:

You can use the 4 bit ADD to implement 2 bit AND and XOR simultaneously:

 0a0b
 0c0d
=====
 efgh

Where:

e = a & c
f = a ^ c
g = b & d
h = b ^ d

You can implement OR using standard De Morgan.

  • Related