calculate farthest place