now uses hash, and seems correct
astar seems to work fine.......