#23 Merge all piece-heuristic function into a single class