1

I have two boolean expressions:

¬aΛ¬b V ¬aΛ¬c V aΛ¬bΛ¬c #1

¬aΛ¬b V ¬aΛ¬c V ¬bΛ¬c #2

I know they are identical because their truth tables are identical. My questions is, how can I make them equal expression-wise.

You may notice the ONLY difference between them is that #1 has an extra 'a' in it's last OR term. Various factoring methods to try to get rid of the extra 'a' have been unsuccessful.

V_TS
  • 149
  • 1
  • 11
  • For comparing them, you first need to simplify them by eliminating the common terms in these. For example you can eliminate ¬aΛ¬b V ¬aΛ¬c and needs only aΛ¬bΛ¬c and ¬bΛ¬c to compare. It reduces lots of time. – Waqas Shabbir Jan 20 '15 at 04:22
  • I added a more formal explanation of the argument I made before, see what you think. – Thomas Nelson Jan 20 '15 at 16:47

2 Answers2

3

I don't know exactly what you mean by "expression-wise" but if you break them down based on whether a is true or false it becomes easy to see.

If a is true (first two terms are false in both Eq1 and Eq2):
Eq1 => ~b & ~c
Eq2 => ~b & ~c

If a is false:
Eq1 => ~b | ~c
Eq2 => ~b | ~c | (~b & ~c) == Eq1

edit: You can make this same argument more formally using boolean identities:

(~a & ~b | ~a & ~c | ~b & ~c) == ((~a & ~b) | (~a & ~c) | (~b & ~c)) & (a | ~a)

since (a | ~a) == 1 and x & 1 = x

Then using distribution of & over | :

== (((~a & ~b) | (~a & ~c) | (~b & ~c)) & a) | (((~a & ~b) | (~a & ~c) | (~b & ~c)) & ~a)

Now you have each of the "cases" as an additional fact on either side of the main | . Applying distribution again will push this fact into the internal cases and eventually make the same cancelations I made above. Looking at just the first distribution into the left side:

((~a & ~b) | x) & a) == (a & ~a & b) | (a & x) == 0 | (a & x) == a & x

where x is the other two or expressions. Following this strategy will give you the same answer as above. If you get stuck I can take you further, but you should be able to take it from here.

Thomas Nelson
  • 693
  • 5
  • 17
  • 1
    You're correct that you can look at it as conditional on a, but what I meant by 'expression-wise' was that I'm seeking to apply a series of identities/transformations (e.g. DeMorgans, distributive, communative, etc.) to turn #1 into #2 – V_TS Jan 20 '15 at 04:52
0

For that in general, you need to convert the expressions to disjunctive normal form. To do that you make a disjunction of elementary conjunctions: for each 1 in the truth table write out a corresponding conjunction of all the variables or their inversions, and then make a disjunction of all those conjunctions. Conjunctive normal form also exists, but it is used more rarely.

Disjunctive normal forms get quite large for expressions of many variables. In that case you may want to use minimisation algorithms (e.g. Quine-McCluskey algorithm), but that is quite complex and computationally expensive (the problem of minimisation is NP-hard and the runtimes for those algorithms are usually exponentially worse than just computing the truth table).

If you just need a universal representation to compare any boolean expressions of the same variables, you may as well compare truth tables for those expressions:

  • either as a string of expression values (zero or one) for every possible combination of variables in lexicographic order,
  • or as a sorted list of numbers of the lines of the truth table where the expression is true. Lines are numbered in lexicographic order of the variables.
Kolmar
  • 14,086
  • 1
  • 22
  • 25