Aaron Cook explains how to use Karnaugh maps to simplify conditional code, starting by converting the code into Boolean algebra and setting up the map's table.
quantumrarity.com
Using Karnaugh Maps to Simplify Code : The Portfolio Website of Aaron Cook