added precomputed distance heuristic