Calculating the touching point