Skip to content
BetterDL

Associative law

Also called: associative, associativity, associative laws, associative property

The Boolean laws (A + B) + C = A + (B + C) and (AB)C = A(BC): with only one kind of operator, the grouping does not matter.

The associative law says that when every operator is the same, it does not matter which pair you do first:

  • (A + B) + C = A + (B + C)
  • (AB)C = A(BC)

That is why we can simply write and with no brackets at all.

In hardware, it means a 3-input AND gate does the same job as two 2-input AND gates chained together, and you can split a wide OR into a tree of smaller ORs. The function stays the same; only the gate count and timing change.

The law only applies when the operators are all the same. Mixing them is a different matter: (A + B)C is not A + (BC). Moving brackets across a mix of AND and OR needs the distributive law, and getting this wrong is a common slip. See operator precedence.

Worked examples

Example

Regrouping a chain

Show that (A + B) + (C + D) can be written as A + (B + C) + D.

  1. 1.

    Every operator is OR, so the associative law applies.

  2. 2.

    Remove all the brackets: .

  3. 3.

    Regroup any way you like: A + (B + C) + D.

  4. 4.

    All of these are 1 when at least one input is 1.

Example

Where it fails

Check (A + B)C against A + (BC) at A = 1, B = 0, C = 0.

  1. 1.

    (A + B)C = (1 + 0) · 0 = 0.

  2. 2.

    A + (BC) = 1 + 0 = 1.

  3. 3.

    They differ, so you cannot move brackets across a mix of + and ·.

Common mistakes

  • Using the associative law on mixed operators, such as turning into .

  • Mixing it up with the commutative law, which is about order rather than grouping.

Practice Associative law

Interactive questions with instant feedback and a worked solution for every wrong answer.

Learn it step by step

Associative law is taught in Boolean Algebra.