adding distance travelled functions