Tag logic minimization

Technique for reducing complex logic functions