added shortest path calculation!