# XOR Gates

1. Feb 17, 2009

### sos617@bham.a

Hi i am a theoretical physicist and am trying to understand electronics. (not a very bright idea)
basically my question is how can we use 2 input xor gates to give a high output when an odd number of bits are high in a four bit binary. also what would such a circuit look like.

2. Feb 17, 2009

### mgb_phys

Start with a piece of paper and work out which combinations of inputs you want the output on for.
For simplicity consider the 4bits as two pairs of bits.
Then you want an output when either there is only one of the first pair and none of the second or both of the second. (and vice versa)
hint - if either both or none of a pair is on then an XOR would be false.

You will probably also have to work out how to implement an AND (or NAND) from XOR.

3. Feb 28, 2009

### Kenneth Mann

Or, you may simply route two lines to one XOR, and the other two to another XOR (it doesn't matter which lines), and then take the two XOR outputs to a third XOR.

KM

Share this great discussion with others via Reddit, Google+, Twitter, or Facebook