improved heuristics