changed heuristic slightly and added the planned containment feature