0

I am currently working on a application where there is a requirement to generate binary combination of input signals in a truth table.

The signal can be either '0' , '1' or 'X' (don't care). The requirement is to generate the input combination dynamically so that all the possible combinations are covered with minimal entries. What makes it difficult is the don't care ('X') condition.

Examples: if we consider 3 bit signal "X X X" covers all combinations and it is the minimal


X | X | X

but if user changes "X X X" to "X X 0" then the application has to insert new entry "X X 1", so that all possible combinations are covered.


X | X | 0

X | X | 1

again if the user changes "X X 0" to "X 1 0", then I have to generate new entry X 0 0


X | 1 | 0

X | X | 1

X | 0 | 0

Now if the user changes entry X 0 0 to X X X then all other entries have to be removed. Ultimately the table should be minimal with all combinations covered.

I have to do this programmatically in Java, is there a mathematical way of doing this?

Thanks

Jk1
  • 11,233
  • 9
  • 54
  • 64
Dinesh
  • 311
  • 2
  • 12
  • How will the user change those values? Which parts of the table are allowed to be changed? Any? Just first row? Or what? – LeleDumbo Oct 11 '12 at 14:33
  • This will implemented as Java JTable. At the start of the application the table will have one row where all the values are 'X' (don't care). Then the user changes one of the values from 'X' to '0' or '1', which will force the application to generate 1's complement of First row. The table now has two rows. The user has choice to change any of values in the table. – Dinesh Oct 12 '12 at 07:34
  • In simple words, a way to determine all possible binary input combinations(including don't care values 'X') are covered in a truth table, if not add/remove combinations to make it complete and minimal. – Dinesh Oct 12 '12 at 09:26

0 Answers0