Finalized all but personal heuristic. Altered to run on ranger.