distance between A and B. solve with pythagorean theorem

235 Views Asked by At

distance between two person.

person A like to watch movie by 3 unit. person B like to watch movie by 4 unit.

in this case we can tell the distance between person A and B. person A is 1 unit away from person B.

we can just subtract 3 from 4.(or subtract 4 from 3 and make it absolute value)

what if there are 2 factor? person A like to watch movie by 3 unit. person B like to watch movie by 4 unit. person A like to read book by 4 point. person B like to read book by 3 point. they are sqrt(2) unit away

see the picture I attached for reason does it make sense?

distance

2

There are 2 best solutions below

0
On

Without getting too far into norms, this is working on the distance between two points using the $L_2$ norm, which is the Pythagorean Theorem for many variables: $\sqrt{(x_1-y_1)^2+(x_2-y_2)^2+(x_3-y_3)^2}$.

The only other "distance" that would make sense would be the Manhattan distance (which is the $L_1$ norm). This is the distance if you only walked on the grid lines: $|x_1-y_1|+|x_2-y_2|+|x_3-y_3|$ which is just the sum of the distances in each category. So the difference in books plus the difference in movies. For your example, it would be 2.

Both are acceptable ways to determine how close two things are.

1
On

Well done, you are correct! You see that little red triangle you created at the top? The hypotenuse will be your distance. We know that each side is 1 unit long and so by the Pythagorean theorem we can calculate our hypotenuse.

s^2 + s^2 = h^2 (pyth)

1^2 + 1^2 = h^2

2=h^2

sqr2 = h

Sorry for all the ^2 and so on. Still trying to figure out how to use the math functions on this site.

A graphical solution

Hope this helps :)