Talk:Approximate distance


Error should be more than Euclidian distance, so real distance feels less to it[edit]

I will try to give some arguments about this. Simple inspection by using points (0,0) and (3,4) gives: Euclidian distance is 5, since 3^2 + 4^2 = 5^2, but y > x, so aprox_distance = 3 + 4 - 1.5 = 7 - 1.5 = 5.5

This is one case of many. Another viewpoint is that the graph of the aprox_distance equation for any *d* gives the coordinates of points that satisfy this value for the equation, not euclidian distance, and the distance from (0,0) to these points is not less since we are using aprox_distance.

Finally some more math:

Case 1: x > y, so aprox_distance is |x| + |y| - |y|/2 . We want to prove that aprox_distance < euclidian distance, so:

Note that |y| - |y|/2 = |y|/2 .

|x| + |y|/2 < sqrt( x^2 + y^2) // we square both sides, noting that a > b also says that a^2 > b^2 for positive numbers,

|x|^2 +|x||y| + |y|^2 / 4 < x^2 + y^2 // but |x|^2 equals x^2, same for |y|, so we move terms and

|x||y| < y^2 * (3/4) // we divide by |y| so y^2/|y|=|y| and

|x| < |y|*(3/4) // multiply by 4

4|x| < 3|y| , but this is a contradiction since x > y, so aprox_distance is not less than euclidian distance. So, if our computed distance is more than our real distance, this means that we take less actual steps and our real distance gives less. Hope this gives more thought about the subject. —The preceding unsigned comment was added by Huachimingo (talkcontribs) .

Thanks very much for the heads-up. My misinterpretation of the graph led me astray at the end. I have fixed it. --Quasar (talk) 00:20, 20 August 2020 (CDT)