0
For designing 2’s complement of a binary number we assume that input is read from LSB to MSB. We will keep the binary number as it is until we read first 1. Keep that 1 as it is then change remaining 1’s by 0’s and 0’s by 1’s.
For example,
Let the binary number be
1011
<-
Read from LSB
Keep the first from LSB as it is and toggle the remaining bits we will get
0101
Thus 2’s complement of 1011 is 0101. The required Mealy machine will be-
0
ADD COMMENT
Please log in to add an answer.